Skip to content

Commit 340a3da

Browse files
committed
demo(vue): update
1 parent c5c8fd3 commit 340a3da

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

demo-snippets/package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
"@nativescript-community/ui-material-button": "file:../packages/button",
1010
"@nativescript-community/ui-material-cardview": "file:../packages/cardview",
1111
"@nativescript-community/ui-material-core": "file:../packages/core",
12+
"@nativescript-community/ui-material-core-tabs": "file:../packages/core-tabs",
1213
"@nativescript-community/ui-material-dialogs": "file:../packages/dialogs",
1314
"@nativescript-community/ui-material-floatingactionbutton": "file:../packages/floatingactionbutton",
1415
"@nativescript-community/ui-material-progress": "file:../packages/progress",
@@ -45,6 +46,9 @@
4546
"@nativescript-community/ui-material-core": {
4647
"injected": true
4748
},
49+
"@nativescript-community/ui-material-core-tabs": {
50+
"injected": true
51+
},
4852
"@nativescript-community/ui-material-dialogs": {
4953
"injected": true
5054
},

demo-snippets/vue/BottomNavigation.vue

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
</ActionBar>
66

77
<GridLayout rows="*, 0" backgroundColor="red">
8-
<MDBottomNavigation selectedIndex="1" :iosCustomPositioning="false">
8+
<MDBottomNavigation selectedIndex="1" :iosCustomPositioning="false" backgroundColor="blue">
99
<!-- The bottom tab UI is created via MDTabStrip (the containier) and MDTabStripItem (for each tab)-->
1010
<MDTabStrip>
1111
<MDTabStripItem>
@@ -24,16 +24,17 @@
2424

2525
<!-- The number of MDTabContentItem components should corespond to the number of MDTabStripItem components -->
2626
<MDTabContentItem>
27-
<Frame id="test">
28-
<Page>
29-
<GridLayout backgroundColor="red" @loaded="onLoaded('red')" @tap="navigateToTabsSample">
30-
<Label text="Home Page" class="h2 text-center"></Label>
27+
<Frame id="test" backgroundColor="transparent">
28+
<Page backgroundColor="transparent">
29+
<GridLayout backgroundColor="transparent" @loaded="onLoaded('red')">
30+
<Label text="Home Page" class="h2 text-center" @tap="navigateToTabsSample"></Label>
31+
<Button text="show alert" @tap="showTestAlert" verticalAlignment="center"></Button>
3132
</GridLayout>
3233
</Page>
3334
</Frame>
3435
</MDTabContentItem>
3536
<MDTabContentItem>
36-
<GridLayout backgroundColor="green" @loaded="onLoaded('green')">
37+
<GridLayout backgroundColor="transparent" @loaded="onLoaded('green')">
3738
<Label text="Account Page" class="h2 text-center"></Label>
3839
</GridLayout>
3940
</MDTabContentItem>
@@ -72,6 +73,9 @@ export default Vue.extend({
7273
},
7374
navigateToTabsSample() {
7475
this.$navigateTo(Tabs);
76+
},
77+
showTestAlert() {
78+
alert('test');
7579
}
7680
}
7781
});

0 commit comments

Comments
 (0)