File tree Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change 130
130
}
131
131
"
132
132
>
133
- {{ toast.cancel. label }}
133
+ {{ isAction( toast.cancel) ? toast.cancel?. label : toast.cancel }}
134
134
</button >
135
135
</template >
136
136
<template v-if =" toast .action " >
148
148
}
149
149
"
150
150
>
151
- {{ toast.action. label }}
151
+ {{ isAction( toast.action) ? toast.action?. label : toast.action }}
152
152
</button >
153
153
</template >
154
154
</template >
@@ -172,8 +172,6 @@ const emit = defineEmits<{
172
172
// Default lifetime of a toasts (in ms)
173
173
const TOAST_LIFETIME = 4000
174
174
175
- // Default gap between toasts
176
-
177
175
const SWIPE_THRESHOLD = 20
178
176
179
177
const TIME_BEFORE_UNMOUNT = 200
@@ -348,7 +346,7 @@ function onPointerMove(event: PointerEvent) {
348
346
}
349
347
350
348
watchEffect (() => {
351
- offset .value = heightIndex .value * props ! .gap ! + toastsHeightBefore .value
349
+ offset .value = heightIndex .value * props ? .gap ! + toastsHeightBefore .value
352
350
})
353
351
354
352
watchEffect ((onInvalidate ) => {
@@ -400,11 +398,11 @@ watchEffect((onInvalidate) => {
400
398
})
401
399
})
402
400
403
- watchEffect (() => {
404
- if (props .toast .delete ) {
405
- deleteToast ()
406
- }
407
- })
401
+ // watchEffect(() => {
402
+ // if (props.toast.delete) {
403
+ // deleteToast()
404
+ // }
405
+ // })
408
406
409
407
onMounted (() => {
410
408
if (toastRef .value ) {
You can’t perform that action at this time.
0 commit comments