v0.1.2flutter_split_view
基于可用空间自动将屏幕拆分为两个视图的 Flutter 小部件。此功能基于 Navigator 2.0。
30喜欢 77近 30 天下载150Pub 分数
AndroidiOSWebmacOSWindowsLinux
基于 Navigator 2.0 的 Flutter 小部件,可根据可用空间自动将屏幕拆分为两个视图。
以下为英文项目原文快照,最新内容请访问 GitHub。
A Navigator 2.0 based Flutter widget that automatically splits the screen into two views based on available space.

MaterialApp(
title: 'SplitView Demo',
home: SplitView.material(
child: MainPage(),
),
);
Cupertino:
CupertinoApp(
title: 'SplitView Demo',
home: SplitView.cupertino(
child: MainPage(),
),
);
SplitView.of(context).push(SecondPage());
Push with an optional title, which will be used as the back button's title in Cupertino:
SplitView.of(context).push(
SecondPage(),
title: 'Second',
);
SplitView.of(context).pop();
Pop until the n-th page:
SplitView.of(context).popUntil(1);
SplitView.of(context).setSecondary(SecondPage());
This will clear the stack and push the new page, making it the second page in the stack.
SplitView.of(context).isSecondaryVisible;
依赖清单 3 项
{"sdk":"flutter"}{"sdk":"flutter"}^1.0.0先按使用场景筛选,再比较项目活跃情况,最后到原始仓库核对使用要求。
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗