Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Pandora
ByToast
提交
a3b10122
B
ByToast
项目概览
Pandora
/
ByToast
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
B
ByToast
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
a3b10122
编写于
5月 13, 2020
作者:
bluesofy
🎏
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
🎏
UI微调
上级
3b6d02f3
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
19 addition
and
31 deletion
+19
-31
CHANGELOG.md
CHANGELOG.md
+5
-0
README.md
README.md
+1
-1
example/lib/main.dart
example/lib/main.dart
+1
-1
example/pubspec.lock
example/pubspec.lock
+4
-4
example/pubspec.yaml
example/pubspec.yaml
+4
-4
example/test/widget_test.dart
example/test/widget_test.dart
+1
-18
lib/core/toast_style.dart
lib/core/toast_style.dart
+2
-2
pubspec.yaml
pubspec.yaml
+1
-1
未找到文件。
CHANGELOG.md
浏览文件 @
a3b10122
## 1.0.2 - 2020/05/13
*
Slightly Adjust the UI
## 1.0.1 - 2020/05/10
*
Format Dart
...
...
README.md
浏览文件 @
a3b10122
...
...
@@ -9,7 +9,7 @@ A Toast Widget for Flutter.
### Add Dependency
```
yaml
dependencies
:
bytoast
:
^1.0.
1
bytoast
:
^1.0.
2
```
### Usage
...
...
example/lib/main.dart
浏览文件 @
a3b10122
...
...
@@ -56,7 +56,7 @@ class _MyHomePageState extends BasePageState<MyHomePage> {
case
2
:
ByToast
.
withIcon
(
context
,
'Succe
ed Tip
s'
,
'Succe
s
s'
,
Image
.
asset
(
'images/ic_tips_ok.webp'
,
alignment:
Alignment
.
center
),
isOnTop:
true
,
);
...
...
example/pubspec.lock
浏览文件 @
a3b10122
...
...
@@ -18,10 +18,10 @@ packages:
bytoast:
dependency: "direct main"
description:
name: bytoast
url: "https://pub.flutter-io.cn"
source:
hosted
version: "1.0.
1
"
path: ".."
relative: true
source:
path
version: "1.0.
2
"
charcode:
dependency: transitive
description:
...
...
example/pubspec.yaml
浏览文件 @
a3b10122
...
...
@@ -15,7 +15,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
version
:
1.0.
0+100
version
:
1.0.
2+102
environment
:
sdk
:
"
>=2.7.0
<3.0.0"
...
...
@@ -30,9 +30,9 @@ dependencies:
cupertino_icons
:
^0.1.3
# ByToast
bytoast
:
^1.0.1
#
bytoast:
#
path: ../
# bytoast: ^1.0.2
bytoast
:
path
:
../
dev_dependencies
:
flutter_test
:
...
...
example/test/widget_test.dart
浏览文件 @
a3b10122
...
...
@@ -5,25 +5,8 @@
// gestures. You can also use WidgetTester to find child widgets in the widget
// tree, read text, and verify that the values of widget properties are correct.
import
'package:bytoaste_example/main.dart'
;
import
'package:flutter/material.dart'
;
import
'package:flutter_test/flutter_test.dart'
;
void
main
(
)
{
testWidgets
(
'Counter increments smoke test'
,
(
WidgetTester
tester
)
async
{
// Build our app and trigger a frame.
await
tester
.
pumpWidget
(
MyApp
());
// Verify that our counter starts at 0.
expect
(
find
.
text
(
'0'
),
findsOneWidget
);
expect
(
find
.
text
(
'1'
),
findsNothing
);
// Tap the '+' icon and trigger a frame.
await
tester
.
tap
(
find
.
byIcon
(
Icons
.
add
));
await
tester
.
pump
();
// Verify that our counter has incremented.
expect
(
find
.
text
(
'0'
),
findsNothing
);
expect
(
find
.
text
(
'1'
),
findsOneWidget
);
});
testWidgets
(
'Show Toast'
,
(
WidgetTester
tester
)
async
{});
}
lib/core/toast_style.dart
浏览文件 @
a3b10122
...
...
@@ -7,9 +7,9 @@ class ToastStyle {
static
const
Alignment
bottom
=
Alignment
(
0.0
,
0.5
);
static
const
EdgeInsetsGeometry
textPadding
=
EdgeInsets
.
only
(
left:
32
,
right:
32
,
top:
8
,
bottom:
8
);
EdgeInsets
.
only
(
left:
32
,
right:
32
,
top:
10
,
bottom:
10
);
static
const
EdgeInsetsGeometry
textWithIconPadding
=
EdgeInsets
.
only
(
left:
16
,
right:
16
,
top:
12
,
bottom:
12
);
EdgeInsets
.
only
(
left:
20
,
right:
20
,
top:
14
,
bottom:
14
);
// Duration
static
const
Duration
shortDuration
=
Duration
(
milliseconds:
2400
);
...
...
pubspec.yaml
浏览文件 @
a3b10122
name
:
bytoast
description
:
A Toast Widget for Flutter. Pure Dart Code. Both Android and iOS. Can Show Simple Text Toast or with Image or Customize.
version
:
1.0.
1
version
:
1.0.
2
homepage
:
https://github.com/PandoraMaze/ByToast
environment
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录