akshathjain / sliding_up_panel Goto Github PK
View Code? Open in Web Editor NEWA draggable Flutter widget that makes implementing a SlidingUpPanel much easier!
Home Page: https://pub.dartlang.org/packages/sliding_up_panel
License: Other
A draggable Flutter widget that makes implementing a SlidingUpPanel much easier!
Home Page: https://pub.dartlang.org/packages/sliding_up_panel
License: Other
Would be great to make tweaks to these parameters. Thanks!
when i change slideDirection
to SlideDirection.DOWN
or SlideDirection.DOWN
i have different layout on screen
http://s6.uplod.ir/i/00953/sz9fo2k942ih.png
http://s6.uplod.ir/i/00953/cf5v1l6xalbp.png
SlidingUpPanel(
slideDirection:SlideDirection.DOWN,
maxHeight: MediaQuery.of(context).size.height / 2,
renderPanelSheet: false,
backdropEnabled: true,
boxShadow: [
BoxShadow(color: Colors.black, blurRadius: 2),
],
panel: Container(
decoration: BoxDecoration(
color: Colors.blueGrey,
borderRadius: BorderRadius.all(Radius.circular(10.0)),
),
margin: const EdgeInsets.fromLTRB(10.0, 10.0, 10.0, 0.0),
child: Center(
child: TextField(
)
),
),
collapsed: Container(
decoration: BoxDecoration(
color: Colors.white,
/*borderRadius: BorderRadius.only(
bottomLeft: Radius.circular(10.0),
bottomRight: Radius.circular(10.0)),*/
boxShadow: [
BoxShadow(
blurRadius: 20.0,
color: Colors.grey,
),
]),
margin: const EdgeInsets.all(10.0),
child: Center(
child: Text("This is the SlidingUpPanel when open"),
),
),
)
Hi,
I am unable to get the borders to round correctly on my application. Instead, it creates a colour that matches my background colour to fill the corners with.
As in other similar libraries, this one has that issue, that the size is defined by MediaQuery.of(context).size.width
and on the very beggining the issue that may happen is that there is no width defined, or it's wrong. And the process of calculating this value differs in release and debug modes. Issue also reproducable with the example provided. It is obvious on iPhone 5s and pretty noticable on iPhone 6 and family.
If your collapsed widget has any type of gesture detector you won't be able to interact with the top part of the panel. It should be just wrapped inside a conditional IgnorePointer.
Debugger says
The method 'call' was called on null
When the panel is already hidden and hide() is called on it.
Great work on this great widget! However, I'd love to have the option to drag the panel from the top to the bottom as well. I'll submit a PR to address this issue now.
It would be nice if we could close the panel that has scrollable content without needing the empty space. The idea is quite simple: when you can't scroll up the content anymore, the panel should start to close (just like it is with Google Map). The execution though, is quite hard. I tried creating a package from ground up with this feature in mind, but I couldn't do it.
Right now the y position user needs to bring the panel down for it to disappear is fixed(or maybe a fraction of the maxHeight). Developer should be able to set this according to his/her own needs imho.
Add an option that allows the user to configure whether or not there's a parallax effect as the panel
is opened. Essentially, this means that as the panel
opens, the body
slides up as well.
The parallax effect should be configurable with a parameter (such as parallaxOffset
) that takes in a double
ranging from 0.0 to 1.0 where 0.0 indicates no parallax and 1.0 indicates that the body
should be offset by the same amount as the panel's offset from its collapsed state (i.e. a scrolling effect).
Can you update for better perfomance?
Thanks
How can I add something scrollable like a ListView as the body?
Currently the closed panel hides the content and disables scrolling on the content.
Also a padding beneath the closed panel needs to be added for that.
Is such thing possible yet?
The PanelController should be able to get/set the animation value (ranging from 0.0 to 1.0). For example:
PanelController pc = new PanelController();
pc.setAnimation(0.5); //will make the the sliding panel halfway open
Hi, how can we set the default pannel to be opened;
I use this Widget as my Home page which i need to open this Pannel as default.
So how can we set it?
BottomNavigationBar and AppBar are not greyed out and can be interacted with.
I want similar behavor like samsung app store .. it scroll pannel with list. How can we do that?
Video link is provided =>
https://www.facebook.com/carloseugeniotorres/videos/2239865416068500/
If you want a particular section of the body, or your FloatingActionButton to be reactive to whether the panel is closed or not, you need either to have some stream or listener from the panelController to retrieve the panel state, or at least a basic onOpen / onClose callback to work with.
Hello, I'm trying to extend the Panel to "full height" when it is open
SlidingUpPanel(
minHeight: UiPlayerShrinked._kPlayerBodyHeight,
maxHeight: MediaQuery.of(context).size.height,
controller: _pc,
onPanelOpened: () => updateIsPlayerExtendedShowing(true),
onPanelClosed: () => updateIsPlayerExtendedShowing(false),
collapsed: buildShrinkedPlayer(playingBeat, context),
panel: Scaffold(
body: Text('Scaffold'),
),
Although there are a couple of problems:
First is this error:
flutter: #11 _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout
package:flutter/…/rendering/proxy_box.dart:105
flutter: #12 RenderObject.layout
package:flutter/…/rendering/object.dart:1644
flutter: #13 _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout
package:flutter/…/rendering/proxy_box.dart:105
flutter: #14 RenderObject.layout
package:flutter/…/rendering/object.dart:1644
flutter: #15 _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout
package:flutter/…/rendering/proxy_box.dart:105
flutter: #16 RenderObject.layout
package:flutter/…/rendering/object.dart:1644
flutter: #17 _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout
package:flutter/…/rendering/proxy_box.dart:105
flutter: #18 RenderObject.layout
package:flutter/…/rendering/object.dart:1644
flutter: #19 _RenderProxyBox&RenderBox&RenderObjectWithChildMixin&RenderProxyBoxMixin.performLayout
package:flutter/…/rendering/proxy_box.dart:105
flutter: #20 RenderObject.layout
package:flutter/…/rendering/object.dart:1644
flutter: #21 RenderConstrainedOverflowBox.performLayout
package:flutter/…/rendering/shifted_box.dart:571
flutter: #22 RenderObject._layoutWithoutResize
package:flutter/…/rendering/object.dart:1519
flutter: #23 PipelineOwner.flushLayout
package:flutter/…/rendering/object.dart:766
flutter: #24 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding.drawFrame
package:flutter/…/rendering/binding.dart:347
flutter: #25 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding&WidgetsBinding.drawFrame
package:flutter/…/widgets/binding.dart:701
flutter: #26 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding&PaintingBinding&SemanticsBinding&RendererBinding._handlePersistentFrameCallback
package:flutter/…/rendering/binding.dart:286
flutter: #27 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._invokeFrameCallback
package:flutter/…/scheduler/binding.dart:1012
flutter: #28 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding.handleDrawFrame
package:flutter/…/scheduler/binding.dart:952
flutter: #29 _WidgetsFlutterBinding&BindingBase&GestureBinding&ServicesBinding&SchedulerBinding._handleDrawFrame
package:flutter/…/scheduler/binding.dart:864
flutter: #33 _invoke (dart:ui/hooks.dart:219:10)
flutter: #34 _drawFrame (dart:ui/hooks.dart:178:3)
flutter: (elided 5 frames from class _AssertionError and package dart:async)
flutter:
flutter: The following RenderObject was being processed when the exception was fired:
flutter: RenderCustomMultiChildLayoutBox#09649 relayoutBoundary=up8 NEEDS-LAYOUT NEEDS-PAINT
flutter: creator: CustomMultiChildLayout ← AnimatedBuilder ← DefaultTextStyle ← AnimatedDefaultTextStyle ←
flutter: _InkFeatures-[GlobalKey#ad7ea ink renderer] ← NotificationListener<LayoutChangedNotification> ←
flutter: PhysicalModel ← AnimatedPhysicalModel ← Material ← PrimaryScrollController ← _ScaffoldScope ←
flutter: Scaffold ← ⋯
flutter: parentData: <none> (can use size)
flutter: constraints: BoxConstraints(0.0<=w<=414.0, h=896.0)
flutter: size: Size(414.0, 896.0)
flutter: This RenderObject had the following descendants (showing up to depth 5):
flutter: _RenderLayoutBuilder#0aed1 relayoutBoundary=up9
flutter: _RenderScrollSemantics#2b11b relayoutBoundary=up10
flutter: RenderPointerListener#b3ac8 relayoutBoundary=up11
flutter: RenderSemanticsGestureHandler#4a540 relayoutBoundary=up12
flutter: RenderPointerListener#d0ada relayoutBoundary=up13
flutter: RenderConstrainedBox#adef0 relayoutBoundary=up9
flutter: RenderSemanticsAnnotations#3a36e relayoutBoundary=up10
flutter: RenderAnnotatedRegion<SystemUiOverlayStyle>#61585 relayoutBoundary=up11
flutter: RenderPhysicalModel#e90d0 relayoutBoundary=up12
flutter: _RenderInkFeatures#4d6ad relayoutBoundary=up13
flutter: RenderFlex#a74c8 relayoutBoundary=up9 NEEDS-PAINT
flutter: RenderStack#834eb relayoutBoundary=up10 NEEDS-PAINT
flutter: RenderLimitedBox#3e5ec relayoutBoundary=up11
flutter: RenderConstrainedBox#de0f0 relayoutBoundary=up12
flutter: RenderLimitedBox#78b88 relayoutBoundary=up11
flutter: RenderConstrainedBox#e7caa relayoutBoundary=up12
flutter: RenderSemanticsGestureHandler#5ff96 relayoutBoundary=up11 NEEDS-PAINT
flutter: RenderPointerListener#86019 relayoutBoundary=up12 NEEDS-PAINT
flutter: RenderConstrainedBox#54ac0 relayoutBoundary=up13 NEEDS-PAINT
flutter: RenderDecoratedBox#24077 relayoutBoundary=up10
flutter: RenderConstrainedBox#227f5 relayoutBoundary=up11
flutter: RenderPadding#c4b38 relayoutBoundary=up12
flutter: RenderFlex#64816 relayoutBoundary=up13
flutter: RenderStack#02564 relayoutBoundary=up9
flutter: RenderTransform#35b38 relayoutBoundary=up10
flutter: RenderTransform#c3d02 relayoutBoundary=up11
flutter: ════════════════════════════════════════════════════════════════════════════════════════════════════
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: A RenderFlex overflowed by 10 pixels on the bottom.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: 'package:flutter/src/material/scaffold.dart': Failed assertion: line 423 pos 16: 'bodyMaxHeight <= math.max(0.0, looseConstraints.maxHeight - contentTop)': is not true.
flutter: Another exception was thrown: Updated layout information required for _RenderLayoutBuilder#0aed1 relayoutBoundary=up9 NEEDS-LAYOUT to calculate semantics.
[C61.1 903ABA02-99A7-41A4-B22F-87E88066A736 192.168.1.117:62932<->18.194.48.246:443]
Connected Path: satisfied (Path is satisfied), interface: en0
Duration: 30.893s, DNS @0.000s took 0.001s, TCP @0.003s took 0.031s, TLS took 0.069s
bytes in/out: 5047/1673, packets in/out: 8/6, rtt: 0.031s, retransmitted packets: 0, out-of-order packets: 0
The second issue is that there is no "safe area". I'm actually trying to emulate a "view" when the panel is open, with AppBar and Body but I can't achieve that because the content is pushed to the very edges
Hi, is it possible to have the controller being able to set the panel content? As i want to avoid using setState()
SlidingUpPanel
is awesome. But I don't know how to programmingly open and close SlidingUpPanel
. Any idea?
Issue related to new property DefaultPanelState
. Fix immediately.
If you wrap Scaffold with SlidingUpPanel, showSnackBar on that Scaffold not working
https://github.com/akshathjain/sliding_up_panel#darkening-the-body-as-the-panel-opens
I am using a ListView as body and it is a list of items. However when the panel is collapsed the body is not above the panel. The last item in the ListView is covered by the collapsed panel. ��
How can I shift it up so the ListView is above the collapsed panel, as to show the last item?
Or also leaving the choice to use a full tap or just a tapDown could be dope.
How to make Slide up Panel to have middle anchors?
When the user presses anywhere except the panel, the panel should hide. But right now nothing happens.
Also, the backdrop overlay only covers the body of the Scaffold. BottomNavigationBar and AppBar are not greyed out.
Like when you hit the android back button and the navigator automatically closes a ModalBottomSheeet. It would be cool to close (or open?) the panel automatically when the user press the system back button.
For the onPanelSlide
, onPanelClosed
and onPanelOpened
.
For example:
PanelController pc = PanelController();
pc.addOnPanelSlideListener((double position){
print(position);
});
First of all, it's great implementation. I have been looking for a widget like this for a while and I had implemented it from scratch but it was no where as smooth as your implementation. I have been playing around with different properties but i am not able to implement it with infinite height or with height that's larger than screen size. I am trying implement it with floating effect, so how would i implement when height is larger than screen size? i want it to scroll/drag as long as there are items. Thanks in advance!
What about adding features to adjust opacity? I think that will help people who want to use gradient background
how can i close panel when i press on back button on phone?
this code don't work
class _LoginForm extends State<LoginForm> with SingleTickerProviderStateMixin {
PanelController _pc = new PanelController();
...
return WillPopScope(
onWillPop: () {
if(_pc.isPanelShown()){
_pc.hide();
}
},
child: Scaffold(
Some tutorial or artical on medium on this would be amazing!:)
The PanelController should have a listener that subscribes to the animation controller and is called every time the animation changes (i.e. the panel slides open/closed). This can be useful for adding custom animations that are based on the panel position. For example:
PanelController pc = new PanelController();
pc.addOnPanelSlideListener((double position){
print(position); //0.0 to 1.0 where 0.0 is full collapsed and 1.0 is fully open
});
So, currently i'm use this plugin and I need to manage the controller from other class, so I'm sharing this public example for anyone who wants to use https://github.com/hectorAguero/slidingpanelexample
Currently I'm works with some similar in a app, but after call a PageRoute(LoginPage to HomePage), I have problems with the controller inside the model class , I don't put that code in the example because I dont have more time now, so all the example works.
The code, doesn't have comments, sorry for that.
Any comment is welcomed
Hi,
The current version has an issue with brightness mode.
steps to reproduce
return MaterialApp(
debugShowCheckedModeBanner: false,
title: 'SlidingUpPanel Example',
theme: ThemeData(primarySwatch: Colors.blue, brightness: Brightness.dark),
home: HomePage(),
);
all the text is gone. maybe it does not respect the dark mode.
Hi! Really love the package! What are your thoughts on making the container here an AnimatedContainer?
I have the use case where my panel can hava data in it or be empty (it's holding a sport player's information). The user can click on a player in main UI list to fetch the data and on load I wanted the panel to animate up to a minimum height of 60 (whereas it's empty value is 40). Using setState and animated container, it's as simple as changing the minHeight property on the SlidingUpPanel
:
minHeight: playerSummary?.player == null ? 40 : 60,
Thanks so much for this, very helpful!
Is there a way to open the panel on tap instead of dragging it? I have a scroll view inside it so dragging causes only the view inside to scroll and I can't open the panel itself.
I know I can open it with a button and call _pc.open(), but ideally I'd want to open on backdrop tap, so any area of the header will open it. And I tried to close it with backdropTapClosesPanel: true but it won't work somehow.
In addition to maxHeight and minHeight, there should be a defaultHeight. When the panel opens up, it should open in defaultHeight. And if maxHeight is bigger than defaultHeight and the user pulls the panel towards top, it should snap to maxHeight. This can be taken even further to make the panel full screen if pulled all the way. What do you think of this feature? It gives the end user much more flexibility and ease of use imho.
when SingleChildScrollView added to child of panel, it will scroll to end, and then slide up.
i with slide up, and then, scroll.
Hi there, I have a quick question if there's any wrap panel's content height? I want the panel's height to be dynamic to it's child. I tried to get the height of the panel's child widget then set it to the maxHeight so that when the panel opens, the maxheight will be adjusted but this doesn't work because the widget isn't available yet when the calculation performed.
The only way of doing this is in the onPanelOpened callback to calculate and adjust the height of the panel. The problem here is that the animation it adjusted the new height doesn't look good. It jump to the new height and fix itself in position. Have any ways to achieve this?
Thank you. :)
This is the
`Dart
import 'package:flutter/material.dart';
import 'package:sliding_up_panel/sliding_up_panel.dart';
class BottomSheet extends StatefulWidget {
@OverRide
_BottomSheetState createState() => _BottomSheetState();
}
class _BottomSheetState extends State {
final double _initFabHeight = 120.0;
double _fabHeight;
double _panelHeightOpen = 575.0;
double _panelHeightClosed = 95.0;
@OverRide
void initState() {
super.initState();
_fabHeight = _initFabHeight;
}
@OverRide
Widget build(BuildContext context) {
return Material(
child: Stack(
alignment: Alignment.topCenter,
children: [
SlidingUpPanel(
maxHeight: _panelHeightOpen,
minHeight: _panelHeightClosed,
parallaxEnabled: true,
parallaxOffset: .5,
body: _body(),
panel: _panel(),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(18.0),
topRight: Radius.circular(18.0)),
onPanelSlide: (double pos) => setState(() {
_fabHeight = pos * (_panelHeightOpen - _panelHeightClosed) +
_initFabHeight;
}),
),
// the fab
Positioned(
right: 20.0,
bottom: _fabHeight,
child: FloatingActionButton(
child: Icon(
Icons.gps_fixed,
color: Theme.of(context).primaryColor,
),
onPressed: () {},
backgroundColor: Colors.white,
),
),
//the SlidingUpPanel Titel
Positioned(
top: 42.0,
child: Container(
padding: const EdgeInsets.fromLTRB(24.0, 18.0, 24.0, 18.0),
child: Text(
"SlidingUpPanel Example",
style: TextStyle(fontWeight: FontWeight.w500),
),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(24.0),
boxShadow: [
BoxShadow(
color: Color.fromRGBO(0, 0, 0, .25), blurRadius: 16.0)
],
),
),
),
],
),
);
}
Widget _panel() {
return Text("hahaha");
}
Widget _body() {
return SizedBox.expand(
child: Text("lalals"),
);
}
}
`
The gifs on the pub.dev page are misleading; in google maps, the "Explore " text stays on top and does not transition to close. I needed this behavior, so it would be a great addition.
https://raw.githubusercontent.com/akshathjain/sliding_up_panel/master/screenshots/example.gif
is any solution about setting max height of preview panel? i mean when i run application of show scrren i want to have custom height of panel
Code as follow:
return Material(
child: Scaffold(
body: Stack(
alignment: Alignment.topCenter,
children: <Widget>[
SlidingUpPanel(
isDraggable: false,
color: Colors.cyan,
controller: _pc,
maxHeight: MediaQuery.of(context).size.height * 0.87,
minHeight: MediaQuery.of(context).size.height * 0.7,
parallaxEnabled: true,
parallaxOffset: .5,
body: _body(),
panel: _panel(),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(18.0),
topRight: Radius.circular(18.0),
),
),
Align(
alignment: Alignment.bottomCenter,
child: _getCheckoutLayer(),
),
],
),
),
);
Widget _panel() {
return Container(
margin: const EdgeInsets.only(top: 18.0),
color: Colors.cyan,
child: NotificationListener<ScrollNotification>(
onNotification: (scrollNotification) {
if (scrollNotification is ScrollStartNotification) {
} else if (scrollNotification is ScrollUpdateNotification) {
if (scrollNotification.metrics.pixels > _currentPosition) {
if (_pc.isPanelClosed()) {
_pc.open();
setState(() {
firstStateEnabled = false;
});
}
}
} else if (scrollNotification is ScrollEndNotification) {
if (scrollNotification.metrics.pixels == 0) {
if (_pc.isPanelOpen()) {
_pc.close();
setState(() {
firstStateEnabled = true;
});
}
}
}
_currentPosition = scrollNotification.metrics.pixels;
return true;
},
child: CustomScrollView(
physics: ClampingScrollPhysics(),
slivers: [
_itemAmount(),
_items(1),
_items(2),
_items(3),
_items(4),
_items(5),
_items(6),
_itemRemark(),
_itemBottom(),
],
),
),
);
}
Widget _itemRemark() {
return SliverStickyHeader(
header: Container(
color: Colors.cyan,
height: 60.0,
padding: EdgeInsets.only(
left: 16.0,
top: 20.0,
bottom: 10.0,
),
alignment: Alignment.centerLeft,
child: Text(
'備註',
style: const TextStyle(
color: Colors.white,
fontSize: 22,
fontWeight: FontWeight.bold,
),
),
),
sliver: SliverList(
delegate: SliverChildBuilderDelegate(
(context, i) {
return Container(
padding: EdgeInsets.only(
left: 15,
right: 15,
),
child: Container(
padding: const EdgeInsets.all(8.0),
decoration: BoxDecoration(
border: Border.all(color: Colors.white),
borderRadius: BorderRadius.circular(12.0)),
child: TextField(
textInputAction: TextInputAction.done,
maxLines: 5,
decoration: InputDecoration.collapsed(hintText: ''),
style: TextStyle(color: Colors.white),
),
),
);
},
childCount: 1,
),
),
);
}
I'm running a Sliding Up Panel as the body of a scaffold, with its body consisting of a column surrounded by some padding, but the content (on smaller devices) goes off the screen. If I take the Sliding Up Panel out and have the column as the body of the scaffold it works just fine fitting to the constraints of the screen.
(I've made the collapsed panel very small, to view the content behind it)
Not sure if I'm implementing this wrong / it's intended behaviour or a bug.
return Scaffold(
appBar: AppBar(
backgroundColor: Colors.blueGrey[800],
title: Text('Time Since Last'),
actions: <Widget>[
IconButton(
icon: Icon(Icons.settings),
onPressed: () {
Navigator.pushNamed(context, CategoryEdit.id, arguments: ScreenArguments(title: title, emoji: categoryIcon, documentId: documentId));
},
),
],
),
body: SlidingUpPanel(
backdropEnabled: true,
borderRadius: radius,
minHeight: 4.0,
maxHeight: height * 0.75,
panel: SlideUpPanel(radius: radius, title: title, documentId: documentId),
collapsed: CollapsedPanel(radius: radius),
body: isLoading
? Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
SpinKitDoubleBounce(
color: Colors.white,
),
SizedBox(height: 42.0),
],
)
: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: <Widget>[
Text(
title.toString(),
style: TextStyle(fontSize: 26.0, fontWeight: FontWeight.bold, decoration: TextDecoration.underline),
textAlign: TextAlign.center,
),
tslDays > 100
? Text(timeAgoBuilder(lastTsl), style: TextStyle(fontSize: 48.0, fontWeight: FontWeight.bold))
: RichText(
text: TextSpan(
children: <TextSpan>[
TextSpan(
text: tslDays < 10 ? ' 0$tslDays' : ' $tslDays',
style: TextStyle(fontSize: 40.0, fontWeight: FontWeight.bold),
),
TextSpan(
text: ' Days\n',
style: TextStyle(fontSize: 16.0),
),
TextSpan(
text: tslHours < 10 ? ' 0$tslHours' : ' $tslHours',
style: TextStyle(fontSize: 40.0, fontWeight: FontWeight.bold),
),
TextSpan(
text: ' Hours\n',
style: TextStyle(fontSize: 16.0),
),
TextSpan(
text: tslMinutes < 10 ? ' 0$tslMinutes' : ' $tslMinutes',
style: TextStyle(fontSize: 40.0, fontWeight: FontWeight.bold),
),
TextSpan(
text: ' Minutes\n',
style: TextStyle(fontSize: 16.0),
),
TextSpan(
text: tslSeconds < 10 ? ' 0$tslSeconds' : ' $tslSeconds',
style: TextStyle(fontSize: 40.0, fontWeight: FontWeight.bold),
),
TextSpan(
text: ' Seconds\n',
style: TextStyle(fontSize: 16.0),
),
],
),
),
ButtonTheme(
minWidth: double.infinity,
child: RaisedButton(
color: Colors.red[900],
onPressed: () {
HapticFeedback.lightImpact();
showDialog(
context: context,
barrierDismissible: true,
builder: (BuildContext context) {
return resetTslDialog();
},
);
},
elevation: 5.0,
//shape: StadiumBorder(),
child: Text('RESET'),
),
),
Container(
height: 42.0,
color: Colors.deepOrange,
),
],
),
),
),
);
Hi,
Thanks for great package. Has anyone notice that Talkback behaves weird with sliding panel. The body widget is hard to focus. I have a listview widget in the sliding panel body. When I focus on the listview, it doesn't get focused, however if I swipe right it goes through the list.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.