mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-06-08 12:04:50 +08:00
@@ -42,11 +42,14 @@ class _LiveSearchChildPageState extends State<LiveSearchChildPage>
|
||||
physics: const AlwaysScrollableScrollPhysics(),
|
||||
slivers: [
|
||||
SliverPadding(
|
||||
padding: EdgeInsets.only(
|
||||
padding: .only(
|
||||
top: padding,
|
||||
left: padding,
|
||||
right: padding,
|
||||
bottom: MediaQuery.viewPaddingOf(context).bottom + 100,
|
||||
bottom:
|
||||
MediaQuery.viewPaddingOf(context).bottom +
|
||||
MediaQuery.viewInsetsOf(context).bottom +
|
||||
100,
|
||||
),
|
||||
sliver: Obx(() => _buildBody(_controller.loadingState.value)),
|
||||
),
|
||||
|
||||
@@ -45,7 +45,7 @@ class LiveSearchController extends GetxController
|
||||
}
|
||||
}
|
||||
|
||||
void submit() {
|
||||
void submit([_]) {
|
||||
if (editingController.text.isNotEmpty) {
|
||||
if (IdUtils.digitOnlyRegExp.hasMatch(editingController.text)) {
|
||||
PageUtils.toLiveRoom(int.parse(editingController.text));
|
||||
|
||||
@@ -49,7 +49,7 @@ class _LiveSearchPageState extends State<LiveSearchPage> {
|
||||
onPressed: _controller.onClear,
|
||||
),
|
||||
),
|
||||
onSubmitted: (value) => _controller.submit(),
|
||||
onSubmitted: _controller.submit,
|
||||
onChanged: (value) {
|
||||
if (value.isEmpty) {
|
||||
_controller.hasData.value = false;
|
||||
|
||||
Reference in New Issue
Block a user