1
1
<template >
2
2
<Page >
3
+
3
4
<ActionBar :title =" title" >
4
- <NavigationButton text =" Back" android.systemIcon =" ic_menu_back" @tap =" onNavigationButtonTap" ></ NavigationButton >
5
+ <NavigationButton text =" Back" android.systemIcon =" ic_menu_back" @tap =" onNavigationButtonTap" / >
5
6
</ActionBar >
6
- <StackLayout >
7
- <MDButton id =" show_snack" text =" show snack" @tap =" onTap" />
8
- <MDButton id =" show_snack_action" text =" show snack action" @tap =" onTap" />
9
- <MDButton id =" show_snack_action_color" text =" show snack action color" @tap =" onTap" />
10
- </StackLayout >
7
+ <GridLayout rows =" *, auto" backgroundColor =" blue" >
8
+ <StackLayout ref =" innerView" >
9
+ <MDButton id =" show_snack" text =" show snack" @tap =" onTap" />
10
+ <MDButton id =" show_snack_action" text =" show snack action" @tap =" onTap" />
11
+ <MDButton id =" show_snack_action_color" text =" show snack action color" @tap =" onTap" />
12
+ </StackLayout >
13
+ <MDBottomNavigationBar row =" 1" activeColor =" red" >
14
+ <MDBottomNavigationTab title =" First" icon =" res://ic_home" activeColor =" green" />
15
+ <MDBottomNavigationTab title =" Second" icon =" res://ic_view_list" isSelectable =" false" />
16
+ <MDBottomNavigationTab title =" Third" icon =" res://ic_menu" inactiveColor =" brown" />
17
+ </MDBottomNavigationBar >
18
+ </GridLayout >
11
19
</Page >
12
20
</template >
13
21
@@ -27,7 +35,7 @@ export default Vue.extend({
27
35
data() {
28
36
return {
29
37
name: ' SnackBar' ,
30
- title: title
38
+ title: title ,
31
39
};
32
40
},
33
41
methods: {
@@ -40,21 +48,21 @@ export default Vue.extend({
40
48
console .log (' onTap' , objId , obj );
41
49
switch (objId ) {
42
50
case ' show_snack' : {
43
- showSnack ({ message: ' this is test snack!' , textColor:' yellow' , view:this .nativeView });
51
+ showSnack ({ message: ' this is test snack!' , textColor: ' yellow' , view: this . $refs . innerView .nativeView });
44
52
break ;
45
53
}
46
54
case ' show_snack_action' : {
47
- showSnack ({ message: ' this is test snack with action!' , actionText:' done' });
55
+ showSnack ({ message: ' this is test snack with action!' , actionText: ' done' });
48
56
break ;
49
57
}
50
58
case ' show_snack_action_color' : {
51
- showSnack ({ message: ' this is test snack with action colored!' , actionText:' delete' , actionTextColor:' red' }).then (r => {
59
+ showSnack ({ message: ' this is test snack with action colored!' , actionText: ' delete' , actionTextColor: ' red' }).then (( r ) => {
52
60
console .log (' showSnack result' , r );
53
61
});
54
62
break ;
55
63
}
56
64
}
57
- }
58
- }
65
+ },
66
+ },
59
67
});
60
- </script >
68
+ </script >
0 commit comments