Commit 27565f23 authored by 林生雨's avatar 林生雨

fix UI

parent 81c03efc
...@@ -597,7 +597,7 @@ class LevelOneItem extends StatelessWidget { ...@@ -597,7 +597,7 @@ class LevelOneItem extends StatelessWidget {
cards.diary.content, cards.diary.content,
textScaleFactor: 1.0, textScaleFactor: 1.0,
maxLines: 5, maxLines: 5,
strutStyle: StrutStyle(forceStrutHeight: true, height: 2), strutStyle: StrutStyle(forceStrutHeight: true, height: 1.6),
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
style: TextStyle( style: TextStyle(
decoration: TextDecoration.none, decoration: TextDecoration.none,
......
...@@ -66,7 +66,7 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin { ...@@ -66,7 +66,7 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin {
@override @override
void initState() { void initState() {
super.initState(); super.initState();
if (inProduction&& if (inProduction &&
Platform.isIOS && Platform.isIOS &&
CacheManager.getInstance().get(MEMORY_CACHE).get(BASE_URL) == null) { CacheManager.getInstance().get(MEMORY_CACHE).get(BASE_URL) == null) {
func = (str) { func = (str) {
...@@ -348,8 +348,9 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin { ...@@ -348,8 +348,9 @@ class PlanState extends BaseState<PlanPage> with TickerProviderStateMixin {
handle: handle:
NestedScrollView.sliverOverlapAbsorberHandleFor(context), NestedScrollView.sliverOverlapAbsorberHandleFor(context),
sliver: baseSliverAppBar(null, sliver: baseSliverAppBar(null,
height: kToolbarHeight + stateBarHeight - 39, height: 0,
needpic: false)), needpic: false,
paddingTop: -(kToolbarHeight - stateBarHeight))),
SliverList( SliverList(
delegate: SliverChildBuilderDelegate((BuildContext c, int i) { delegate: SliverChildBuilderDelegate((BuildContext c, int i) {
if (i == 0) { if (i == 0) {
......
...@@ -70,7 +70,7 @@ class TopListState extends State<TopList> with AutomaticKeepAliveClientMixin { ...@@ -70,7 +70,7 @@ class TopListState extends State<TopList> with AutomaticKeepAliveClientMixin {
slivers: <Widget>[ slivers: <Widget>[
SliverToBoxAdapter( SliverToBoxAdapter(
child: Container( child: Container(
height: widget.topHeight-(Platform.isIOS ? 12 : 6), height: widget.topHeight - 12,
), ),
), ),
// extend.SliverOverlapInjector( // extend.SliverOverlapInjector(
......
...@@ -497,7 +497,7 @@ Widget baseTabBarItem(String text, ...@@ -497,7 +497,7 @@ Widget baseTabBarItem(String text,
} }
Widget baseSliverAppBar(String url, Widget baseSliverAppBar(String url,
{double height, double elevation, bool needpic = true}) { {double height, double elevation, bool needpic = true, double paddingTop}) {
return SliverAppBar( return SliverAppBar(
pinned: true, pinned: true,
centerTitle: true, centerTitle: true,
...@@ -505,7 +505,7 @@ Widget baseSliverAppBar(String url, ...@@ -505,7 +505,7 @@ Widget baseSliverAppBar(String url,
expandedHeight: height ?? 200, expandedHeight: height ?? 200,
automaticallyImplyLeading: false, automaticallyImplyLeading: false,
bottom: PreferredSize( bottom: PreferredSize(
preferredSize: Size.fromHeight(Platform.isIOS ? -12 : -6), preferredSize: Size.fromHeight(paddingTop ?? -12),
child: SizedBox( child: SizedBox(
height: 0, height: 0,
), ),
...@@ -524,7 +524,7 @@ Widget baseSliverAppBar(String url, ...@@ -524,7 +524,7 @@ Widget baseSliverAppBar(String url,
Widget baseSliverBack(VoidCallback tap, context) { Widget baseSliverBack(VoidCallback tap, context) {
final double topPadding = MediaQuery.of(context).padding.top; final double topPadding = MediaQuery.of(context).padding.top;
return Positioned( return Positioned(
top: topPadding + 12, top: topPadding + 6.5,
left: 7, left: 7,
child: GestureDetector( child: GestureDetector(
behavior: HitTestBehavior.opaque, behavior: HitTestBehavior.opaque,
...@@ -548,7 +548,7 @@ Widget baseSliverBack(VoidCallback tap, context) { ...@@ -548,7 +548,7 @@ Widget baseSliverBack(VoidCallback tap, context) {
Widget baseSliverTitle(String text, double width, LiveData liveData, context) { Widget baseSliverTitle(String text, double width, LiveData liveData, context) {
final double topPadding = MediaQuery.of(context).padding.top; final double topPadding = MediaQuery.of(context).padding.top;
return Positioned( return Positioned(
top: topPadding + 13, top: topPadding + 9.5,
child: StreamBuilder( child: StreamBuilder(
stream: liveData.stream, stream: liveData.stream,
initialData: liveData.data ?? 0.0, initialData: liveData.data ?? 0.0,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment