2
2
<ion-page >
3
3
<ion-header >
4
4
<ion-toolbar >
5
+ <ion-buttons slot =" start" >
6
+ <ion-button @click =" onCancelClicked" >
7
+ <ion-icon slot =" icon-only" :icon =" arrowBack" ></ion-icon >
8
+ </ion-button >
9
+ </ion-buttons >
10
+
5
11
<ion-title >{{ modalTitle }}</ion-title >
6
12
<ion-buttons slot =" end" v-if =" allowDelete" >
7
13
<ion-button color =" error" @click =" onDeleteClicked" >
8
- <ion-icon :icon =" trash" ></ion-icon >
14
+ <ion-icon slot = " icon-only " :icon =" trash" ></ion-icon >
9
15
</ion-button >
10
16
</ion-buttons >
11
17
</ion-toolbar >
36
42
></ion-input >
37
43
</ion-item >
38
44
</ion-list >
45
+
46
+ <ion-button
47
+ style =" margin-top : 10px "
48
+ color =" success"
49
+ expand =" block"
50
+ @click =" onSubmitClicked"
51
+ >Save</ion-button
52
+ >
39
53
</ion-content >
40
- <ion-footer >
41
- <ion-button @click =" onCancelClicked" >Cancel</ion-button >
42
- <ion-button color =" success" @click =" onSubmitClicked" >Save</ion-button >
43
- </ion-footer >
44
54
</ion-page >
45
55
</template >
46
56
@@ -54,14 +64,13 @@ import {
54
64
IonContent ,
55
65
IonInput ,
56
66
IonItem ,
57
- IonFooter ,
58
67
IonButton ,
59
68
IonList ,
60
69
IonListHeader ,
61
70
IonButtons ,
62
71
IonIcon ,
63
72
} from " @ionic/vue" ;
64
- import { trash } from " ionicons/icons" ;
73
+ import { trash , arrowBack } from " ionicons/icons" ;
65
74
export default {
66
75
props: [" modalController" , " server" ],
67
76
components: {
@@ -72,7 +81,6 @@ export default {
72
81
IonContent,
73
82
IonInput,
74
83
IonItem,
75
- IonFooter,
76
84
IonButton,
77
85
IonList,
78
86
IonListHeader,
@@ -119,7 +127,9 @@ export default {
119
127
};
120
128
121
129
const onDeleteClicked = () => {
122
- props .modalController .dismiss ({ delete: true });
130
+ if (confirm (" Delete server?" )) {
131
+ props .modalController .dismiss ({ delete: true });
132
+ }
123
133
};
124
134
125
135
return {
@@ -130,18 +140,8 @@ export default {
130
140
onSubmitClicked,
131
141
onDeleteClicked,
132
142
trash,
143
+ arrowBack,
133
144
};
134
145
},
135
146
};
136
147
</script >
137
-
138
- <style scoped>
139
- ion-footer {
140
- padding : 10px ;
141
- text-align : right ;
142
- }
143
-
144
- ion-footer ion-button {
145
- width : 120px ;
146
- }
147
- </style >
0 commit comments