@tplc/wot 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/common/AbortablePromise.ts +36 -0
- package/components/common/abstracts/_config.scss +7 -0
- package/components/common/abstracts/_function.scss +76 -0
- package/components/common/abstracts/_mixin.scss +339 -0
- package/components/common/abstracts/variable.scss +1346 -0
- package/components/common/base64.ts +30 -0
- package/components/common/canvasHelper.ts +49 -0
- package/components/common/clickoutside.ts +34 -0
- package/components/common/dayjs.ts +157 -0
- package/components/common/event.ts +8 -0
- package/components/common/props.ts +51 -0
- package/components/common/util.ts +751 -0
- package/components/composables/useCell.ts +13 -0
- package/components/composables/useChildren.ts +122 -0
- package/components/composables/useCountDown.ts +138 -0
- package/components/composables/useLockScroll.ts +39 -0
- package/components/composables/useParent.ts +41 -0
- package/components/composables/usePopover.ts +193 -0
- package/components/composables/useQueue.ts +52 -0
- package/components/composables/useRaf.ts +37 -0
- package/components/composables/useTouch.ts +44 -0
- package/components/composables/useTranslate.ts +22 -0
- package/components/wd-action-sheet/index.scss +204 -0
- package/components/wd-action-sheet/types.ts +128 -0
- package/components/wd-action-sheet/wd-action-sheet.vue +174 -0
- package/components/wd-backtop/index.scss +25 -0
- package/components/wd-backtop/types.ts +37 -0
- package/components/wd-backtop/wd-backtop.vue +48 -0
- package/components/wd-badge/index.scss +59 -0
- package/components/wd-badge/types.ts +53 -0
- package/components/wd-badge/wd-badge.vue +69 -0
- package/components/wd-button/index.scss +340 -0
- package/components/wd-button/types.ts +112 -0
- package/components/wd-button/wd-button.vue +176 -0
- package/components/wd-calendar/index.scss +244 -0
- package/components/wd-calendar/types.ts +235 -0
- package/components/wd-calendar/wd-calendar.vue +456 -0
- package/components/wd-calendar-view/index.scss +9 -0
- package/components/wd-calendar-view/month/index.scss +151 -0
- package/components/wd-calendar-view/month/month.vue +391 -0
- package/components/wd-calendar-view/month/types.ts +19 -0
- package/components/wd-calendar-view/monthPanel/index.scss +89 -0
- package/components/wd-calendar-view/monthPanel/month-panel.vue +388 -0
- package/components/wd-calendar-view/monthPanel/types.ts +48 -0
- package/components/wd-calendar-view/types.ts +134 -0
- package/components/wd-calendar-view/utils.ts +451 -0
- package/components/wd-calendar-view/wd-calendar-view.vue +111 -0
- package/components/wd-calendar-view/year/index.scss +148 -0
- package/components/wd-calendar-view/year/types.ts +19 -0
- package/components/wd-calendar-view/year/year.vue +220 -0
- package/components/wd-calendar-view/yearPanel/index.scss +24 -0
- package/components/wd-calendar-view/yearPanel/types.ts +38 -0
- package/components/wd-calendar-view/yearPanel/year-panel.vue +140 -0
- package/components/wd-card/index.scss +70 -0
- package/components/wd-card/types.ts +30 -0
- package/components/wd-card/wd-card.vue +40 -0
- package/components/wd-cell/index.scss +189 -0
- package/components/wd-cell/types.ts +96 -0
- package/components/wd-cell/wd-cell.vue +135 -0
- package/components/wd-cell-group/index.scss +55 -0
- package/components/wd-cell-group/types.ts +41 -0
- package/components/wd-cell-group/wd-cell-group.vue +45 -0
- package/components/wd-checkbox/index.scss +285 -0
- package/components/wd-checkbox/types.ts +68 -0
- package/components/wd-checkbox/wd-checkbox.vue +185 -0
- package/components/wd-checkbox-group/index.scss +20 -0
- package/components/wd-checkbox-group/types.ts +59 -0
- package/components/wd-checkbox-group/wd-checkbox-group.vue +103 -0
- package/components/wd-circle/index.scss +18 -0
- package/components/wd-circle/types.ts +54 -0
- package/components/wd-circle/wd-circle.vue +318 -0
- package/components/wd-col/index.scss +19 -0
- package/components/wd-col/types.ts +15 -0
- package/components/wd-col/wd-col.vue +91 -0
- package/components/wd-col-picker/index.scss +241 -0
- package/components/wd-col-picker/types.ts +170 -0
- package/components/wd-col-picker/wd-col-picker.vue +550 -0
- package/components/wd-collapse/index.scss +55 -0
- package/components/wd-collapse/types.ts +63 -0
- package/components/wd-collapse/wd-collapse.vue +160 -0
- package/components/wd-collapse-item/index.scss +79 -0
- package/components/wd-collapse-item/types.ts +36 -0
- package/components/wd-collapse-item/wd-collapse-item.vue +182 -0
- package/components/wd-config-provider/types.ts +1023 -0
- package/components/wd-config-provider/wd-config-provider.vue +82 -0
- package/components/wd-count-down/index.scss +14 -0
- package/components/wd-count-down/types.ts +41 -0
- package/components/wd-count-down/utils.ts +52 -0
- package/components/wd-count-down/wd-count-down.vue +60 -0
- package/components/wd-count-to/index.scss +6 -0
- package/components/wd-count-to/types.ts +110 -0
- package/components/wd-count-to/wd-count-to.vue +134 -0
- package/components/wd-curtain/index.scss +80 -0
- package/components/wd-curtain/types.ts +45 -0
- package/components/wd-curtain/wd-curtain.vue +174 -0
- package/components/wd-datetime-picker/index.scss +243 -0
- package/components/wd-datetime-picker/types.ts +225 -0
- package/components/wd-datetime-picker/wd-datetime-picker.vue +827 -0
- package/components/wd-datetime-picker-view/index.scss +0 -0
- package/components/wd-datetime-picker-view/types.ts +137 -0
- package/components/wd-datetime-picker-view/wd-datetime-picker-view.vue +514 -0
- package/components/wd-divider/index.scss +32 -0
- package/components/wd-divider/types.ts +12 -0
- package/components/wd-divider/wd-divider.vue +29 -0
- package/components/wd-drop-menu/index.scss +89 -0
- package/components/wd-drop-menu/types.ts +38 -0
- package/components/wd-drop-menu/wd-drop-menu.vue +128 -0
- package/components/wd-drop-menu-item/index.scss +66 -0
- package/components/wd-drop-menu-item/types.ts +78 -0
- package/components/wd-drop-menu-item/wd-drop-menu-item.vue +230 -0
- package/components/wd-fab/index.scss +115 -0
- package/components/wd-fab/types.ts +61 -0
- package/components/wd-fab/wd-fab.vue +257 -0
- package/components/wd-form/index.scss +10 -0
- package/components/wd-form/types.ts +93 -0
- package/components/wd-form/wd-form.vue +185 -0
- package/components/wd-form-item/index.scss +17 -0
- package/components/wd-form-item/types.ts +22 -0
- package/components/wd-form-item/wd-form-item.vue +65 -0
- package/components/wd-gap/index.scss +9 -0
- package/components/wd-gap/types.ts +23 -0
- package/components/wd-gap/wd-gap.vue +39 -0
- package/components/wd-grid/index.scss +9 -0
- package/components/wd-grid/types.ts +54 -0
- package/components/wd-grid/wd-grid.vue +107 -0
- package/components/wd-grid-item/index.scss +137 -0
- package/components/wd-grid-item/types.ts +74 -0
- package/components/wd-grid-item/wd-grid-item.vue +181 -0
- package/components/wd-icon/index.scss +1222 -0
- package/components/wd-icon/types.ts +21 -0
- package/components/wd-icon/wd-icon.vue +53 -0
- package/components/wd-icon/wd-icons.ttf +0 -0
- package/components/wd-img/index.scss +19 -0
- package/components/wd-img/types.ts +53 -0
- package/components/wd-img/wd-img.vue +76 -0
- package/components/wd-img-cropper/index.scss +227 -0
- package/components/wd-img-cropper/types.ts +87 -0
- package/components/wd-img-cropper/wd-img-cropper.vue +659 -0
- package/components/wd-index-anchor/index.scss +34 -0
- package/components/wd-index-anchor/type.ts +9 -0
- package/components/wd-index-anchor/wd-index-anchor.vue +57 -0
- package/components/wd-index-bar/index.scss +39 -0
- package/components/wd-index-bar/type.ts +28 -0
- package/components/wd-index-bar/wd-index-bar.vue +158 -0
- package/components/wd-input/index.scss +326 -0
- package/components/wd-input/types.ts +182 -0
- package/components/wd-input/wd-input.vue +327 -0
- package/components/wd-input-number/index.scss +132 -0
- package/components/wd-input-number/types.ts +78 -0
- package/components/wd-input-number/wd-input-number.vue +221 -0
- package/components/wd-loading/index.scss +34 -0
- package/components/wd-loading/types.ts +31 -0
- package/components/wd-loading/wd-loading.vue +90 -0
- package/components/wd-loadmore/index.scss +39 -0
- package/components/wd-loadmore/types.ts +24 -0
- package/components/wd-loadmore/wd-loadmore.vue +53 -0
- package/components/wd-message-box/index.scss +121 -0
- package/components/wd-message-box/index.ts +95 -0
- package/components/wd-message-box/types.ts +116 -0
- package/components/wd-message-box/wd-message-box.vue +326 -0
- package/components/wd-navbar/index.scss +103 -0
- package/components/wd-navbar/types.ts +52 -0
- package/components/wd-navbar/wd-navbar.vue +142 -0
- package/components/wd-navbar-capsule/index.scss +65 -0
- package/components/wd-navbar-capsule/types.ts +0 -0
- package/components/wd-navbar-capsule/wd-navbar-capsule.vue +31 -0
- package/components/wd-notice-bar/index.scss +86 -0
- package/components/wd-notice-bar/types.ts +56 -0
- package/components/wd-notice-bar/wd-notice-bar.vue +223 -0
- package/components/wd-notify/index.scss +34 -0
- package/components/wd-notify/index.ts +59 -0
- package/components/wd-notify/types.ts +62 -0
- package/components/wd-notify/wd-notify.vue +83 -0
- package/components/wd-number-keyboard/index.scss +78 -0
- package/components/wd-number-keyboard/key/index.scss +79 -0
- package/components/wd-number-keyboard/key/index.vue +76 -0
- package/components/wd-number-keyboard/key/types.ts +11 -0
- package/components/wd-number-keyboard/types.ts +79 -0
- package/components/wd-number-keyboard/wd-number-keyboard.vue +173 -0
- package/components/wd-overlay/index.scss +17 -0
- package/components/wd-overlay/types.ts +25 -0
- package/components/wd-overlay/wd-overlay.vue +46 -0
- package/components/wd-pagination/index.scss +57 -0
- package/components/wd-pagination/types.ts +41 -0
- package/components/wd-pagination/wd-pagination.vue +121 -0
- package/components/wd-password-input/index.scss +123 -0
- package/components/wd-password-input/types.ts +48 -0
- package/components/wd-password-input/wd-password-input.vue +58 -0
- package/components/wd-picker/index.scss +216 -0
- package/components/wd-picker/types.ts +186 -0
- package/components/wd-picker/wd-picker.vue +409 -0
- package/components/wd-picker-view/index.scss +91 -0
- package/components/wd-picker-view/types.ts +162 -0
- package/components/wd-picker-view/wd-picker-view.vue +361 -0
- package/components/wd-popover/index.scss +123 -0
- package/components/wd-popover/types.ts +69 -0
- package/components/wd-popover/wd-popover.vue +216 -0
- package/components/wd-popup/index.scss +112 -0
- package/components/wd-popup/types.ts +68 -0
- package/components/wd-popup/wd-popup.vue +227 -0
- package/components/wd-progress/index.scss +62 -0
- package/components/wd-progress/types.ts +40 -0
- package/components/wd-progress/wd-progress.vue +201 -0
- package/components/wd-radio/index.scss +300 -0
- package/components/wd-radio/types.ts +42 -0
- package/components/wd-radio/wd-radio.vue +136 -0
- package/components/wd-radio-group/index.scss +23 -0
- package/components/wd-radio-group/types.ts +36 -0
- package/components/wd-radio-group/wd-radio-group.vue +54 -0
- package/components/wd-rate/index.scss +24 -0
- package/components/wd-rate/types.ts +91 -0
- package/components/wd-rate/wd-rate.vue +131 -0
- package/components/wd-resize/index.scss +26 -0
- package/components/wd-resize/types.ts +6 -0
- package/components/wd-resize/wd-resize.vue +155 -0
- package/components/wd-row/index.scss +10 -0
- package/components/wd-row/types.ts +16 -0
- package/components/wd-row/wd-row.vue +63 -0
- package/components/wd-search/index.scss +148 -0
- package/components/wd-search/types.ts +83 -0
- package/components/wd-search/wd-search.vue +237 -0
- package/components/wd-segmented/index.scss +97 -0
- package/components/wd-segmented/types.ts +68 -0
- package/components/wd-segmented/wd-segmented.vue +143 -0
- package/components/wd-select-picker/index.scss +177 -0
- package/components/wd-select-picker/types.ts +116 -0
- package/components/wd-select-picker/wd-select-picker.vue +486 -0
- package/components/wd-sidebar/index.scss +25 -0
- package/components/wd-sidebar/types.ts +28 -0
- package/components/wd-sidebar/wd-sidebar.vue +41 -0
- package/components/wd-sidebar-item/index.scss +93 -0
- package/components/wd-sidebar-item/types.ts +31 -0
- package/components/wd-sidebar-item/wd-sidebar-item.vue +114 -0
- package/components/wd-skeleton/index.scss +101 -0
- package/components/wd-skeleton/index.ts +1 -0
- package/components/wd-skeleton/types.ts +69 -0
- package/components/wd-skeleton/wd-skeleton.vue +135 -0
- package/components/wd-slider/index.scss +91 -0
- package/components/wd-slider/types.ts +104 -0
- package/components/wd-slider/wd-slider.vue +377 -0
- package/components/wd-sort-button/index.scss +86 -0
- package/components/wd-sort-button/types.ts +43 -0
- package/components/wd-sort-button/wd-sort-button.vue +76 -0
- package/components/wd-status-tip/index.scss +37 -0
- package/components/wd-status-tip/types.ts +59 -0
- package/components/wd-status-tip/wd-status-tip.vue +94 -0
- package/components/wd-step/index.scss +236 -0
- package/components/wd-step/types.ts +33 -0
- package/components/wd-step/wd-step.vue +151 -0
- package/components/wd-steps/index.scss +10 -0
- package/components/wd-steps/types.ts +59 -0
- package/components/wd-steps/wd-steps.vue +37 -0
- package/components/wd-sticky/index.scss +9 -0
- package/components/wd-sticky/types.ts +13 -0
- package/components/wd-sticky/wd-sticky.vue +190 -0
- package/components/wd-sticky-box/index.scss +6 -0
- package/components/wd-sticky-box/types.ts +20 -0
- package/components/wd-sticky-box/wd-sticky-box.vue +154 -0
- package/components/wd-swipe-action/index.scss +22 -0
- package/components/wd-swipe-action/types.ts +43 -0
- package/components/wd-swipe-action/wd-swipe-action.vue +307 -0
- package/components/wd-swiper/index.scss +23 -0
- package/components/wd-swiper/types.ts +189 -0
- package/components/wd-swiper/wd-swiper.vue +202 -0
- package/components/wd-swiper-nav/index.scss +153 -0
- package/components/wd-swiper-nav/types.ts +42 -0
- package/components/wd-swiper-nav/wd-swiper-nav.vue +37 -0
- package/components/wd-switch/index.scss +58 -0
- package/components/wd-switch/types.ts +56 -0
- package/components/wd-switch/wd-switch.vue +83 -0
- package/components/wd-tab/index.scss +8 -0
- package/components/wd-tab/types.ts +20 -0
- package/components/wd-tab/wd-tab.vue +100 -0
- package/components/wd-tabbar/index.scss +57 -0
- package/components/wd-tabbar/types.ts +88 -0
- package/components/wd-tabbar/wd-tabbar.vue +104 -0
- package/components/wd-tabbar-item/index.scss +52 -0
- package/components/wd-tabbar-item/types.ts +51 -0
- package/components/wd-tabbar-item/wd-tabbar-item.vue +101 -0
- package/components/wd-table/index.scss +132 -0
- package/components/wd-table/types.ts +69 -0
- package/components/wd-table/wd-table.vue +255 -0
- package/components/wd-table-col/index.scss +44 -0
- package/components/wd-table-col/types.ts +54 -0
- package/components/wd-table-col/wd-table-col.vue +149 -0
- package/components/wd-tabs/index.scss +280 -0
- package/components/wd-tabs/types.ts +71 -0
- package/components/wd-tabs/wd-tabs.vue +528 -0
- package/components/wd-tag/index.scss +115 -0
- package/components/wd-tag/types.ts +81 -0
- package/components/wd-tag/wd-tag.vue +154 -0
- package/components/wd-text/index.scss +34 -0
- package/components/wd-text/types.ts +98 -0
- package/components/wd-text/wd-text.vue +138 -0
- package/components/wd-textarea/index.scss +343 -0
- package/components/wd-textarea/types.ts +298 -0
- package/components/wd-textarea/wd-textarea.vue +303 -0
- package/components/wd-toast/index.scss +66 -0
- package/components/wd-toast/index.ts +109 -0
- package/components/wd-toast/types.ts +76 -0
- package/components/wd-toast/wd-toast.vue +212 -0
- package/components/wd-tooltip/index.scss +61 -0
- package/components/wd-tooltip/types.ts +102 -0
- package/components/wd-tooltip/wd-tooltip.vue +167 -0
- package/components/wd-transition/index.scss +91 -0
- package/components/wd-transition/types.ts +89 -0
- package/components/wd-transition/wd-transition.vue +221 -0
- package/components/wd-upload/index.scss +173 -0
- package/components/wd-upload/types.ts +378 -0
- package/components/wd-upload/utils.ts +152 -0
- package/components/wd-upload/wd-upload.vue +737 -0
- package/components/wd-video-preview/index.scss +34 -0
- package/components/wd-video-preview/types.ts +32 -0
- package/components/wd-video-preview/wd-video-preview.vue +76 -0
- package/components/wd-watermark/index.scss +18 -0
- package/components/wd-watermark/types.ts +82 -0
- package/components/wd-watermark/wd-watermark.vue +592 -0
- package/components/wot-design-uni/wot-design-uni.vue +14 -0
- package/global.d.ts +108 -0
- package/index.ts +30 -0
- package/locale/index.ts +41 -0
- package/locale/lang/en-US.ts +128 -0
- package/locale/lang/th-TH.ts +127 -0
- package/locale/lang/vi-VN.ts +89 -0
- package/locale/lang/zh-CN.ts +127 -0
- package/locale/lang/zh-HK.ts +84 -0
- package/locale/lang/zh-TW.ts +84 -0
- package/package.json +20 -0
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<wd-overlay
|
|
3
|
+
v-if="cover"
|
|
4
|
+
:z-index="zIndex"
|
|
5
|
+
lock-scroll
|
|
6
|
+
:show="show"
|
|
7
|
+
custom-style="background-color: transparent;pointer-events: auto;"
|
|
8
|
+
></wd-overlay>
|
|
9
|
+
<wd-transition
|
|
10
|
+
name="fade"
|
|
11
|
+
:show="show"
|
|
12
|
+
:custom-style="transitionStyle"
|
|
13
|
+
@after-enter="handleAfterEnter"
|
|
14
|
+
@after-leave="handleAfterLeave"
|
|
15
|
+
>
|
|
16
|
+
<view :class="rootClass">
|
|
17
|
+
<!--iconName优先级更高-->
|
|
18
|
+
<wd-loading
|
|
19
|
+
v-if="iconName === 'loading'"
|
|
20
|
+
:type="loadingType"
|
|
21
|
+
:color="loadingColor"
|
|
22
|
+
:size="loadingSize"
|
|
23
|
+
custom-class="wd-toast__icon"
|
|
24
|
+
/>
|
|
25
|
+
<view
|
|
26
|
+
class="wd-toast__iconWrap wd-toast__icon"
|
|
27
|
+
v-else-if="
|
|
28
|
+
iconName === 'success' ||
|
|
29
|
+
iconName === 'warning' ||
|
|
30
|
+
iconName === 'info' ||
|
|
31
|
+
iconName === 'error'
|
|
32
|
+
"
|
|
33
|
+
>
|
|
34
|
+
<view class="wd-toast__iconBox">
|
|
35
|
+
<view class="wd-toast__iconSvg" :style="svgStyle"></view>
|
|
36
|
+
</view>
|
|
37
|
+
</view>
|
|
38
|
+
<wd-icon
|
|
39
|
+
v-else-if="iconClass"
|
|
40
|
+
custom-class="wd-toast__icon"
|
|
41
|
+
:size="iconSize"
|
|
42
|
+
:class-prefix="classPrefix"
|
|
43
|
+
:name="iconClass"
|
|
44
|
+
></wd-icon>
|
|
45
|
+
<!--文本-->
|
|
46
|
+
<view v-if="msg" class="wd-toast__msg">{{ msg }}</view>
|
|
47
|
+
</view>
|
|
48
|
+
</wd-transition>
|
|
49
|
+
</template>
|
|
50
|
+
|
|
51
|
+
<script lang="ts">
|
|
52
|
+
export default {
|
|
53
|
+
name: 'wd-toast',
|
|
54
|
+
options: {
|
|
55
|
+
addGlobalClass: true,
|
|
56
|
+
virtualHost: true,
|
|
57
|
+
styleIsolation: 'shared',
|
|
58
|
+
},
|
|
59
|
+
}
|
|
60
|
+
</script>
|
|
61
|
+
|
|
62
|
+
<script lang="ts" setup>
|
|
63
|
+
import { computed, inject, onBeforeMount, ref, watch, type CSSProperties } from 'vue'
|
|
64
|
+
import base64 from '../common/base64'
|
|
65
|
+
import { defaultOptions, toastDefaultOptionKey, toastIcon } from '../wd-toast'
|
|
66
|
+
import { toastProps, type ToastLoadingType, type ToastOptions } from './types'
|
|
67
|
+
import { addUnit, isDef, isFunction, objToStyle } from '../common/util'
|
|
68
|
+
|
|
69
|
+
const props = defineProps(toastProps)
|
|
70
|
+
|
|
71
|
+
const iconName = ref<string>('') // 图标类型
|
|
72
|
+
const msg = ref<string>('') // 消息内容
|
|
73
|
+
const position = ref<string>('middle')
|
|
74
|
+
const show = ref<boolean>(false)
|
|
75
|
+
const zIndex = ref<number>(100)
|
|
76
|
+
const loadingType = ref<ToastLoadingType>('outline')
|
|
77
|
+
const loadingColor = ref<string>('#4D80F0')
|
|
78
|
+
const iconSize = ref<string>() // 图标大小
|
|
79
|
+
const loadingSize = ref<string>() // loading大小
|
|
80
|
+
const svgStr = ref<string>('') // 图标
|
|
81
|
+
const cover = ref<boolean>(false) // 是否存在遮罩层
|
|
82
|
+
const classPrefix = ref<string>('wd-icon') // 图标前缀
|
|
83
|
+
const iconClass = ref<string>('') // 图标类名
|
|
84
|
+
|
|
85
|
+
let opened: (() => void) | null = null
|
|
86
|
+
|
|
87
|
+
let closed: (() => void) | null = null
|
|
88
|
+
|
|
89
|
+
const toastOptionKey = props.selector
|
|
90
|
+
? toastDefaultOptionKey + props.selector
|
|
91
|
+
: toastDefaultOptionKey
|
|
92
|
+
const toastOption = inject(toastOptionKey, ref<ToastOptions>(defaultOptions)) // toast选项
|
|
93
|
+
|
|
94
|
+
// 监听options变化展示
|
|
95
|
+
watch(
|
|
96
|
+
() => toastOption.value,
|
|
97
|
+
(newVal: ToastOptions) => {
|
|
98
|
+
reset(newVal)
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
deep: true,
|
|
102
|
+
immediate: true,
|
|
103
|
+
},
|
|
104
|
+
)
|
|
105
|
+
|
|
106
|
+
// 监听options变化展示
|
|
107
|
+
watch(
|
|
108
|
+
() => iconName.value,
|
|
109
|
+
() => {
|
|
110
|
+
buildSvg()
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
deep: true,
|
|
114
|
+
immediate: true,
|
|
115
|
+
},
|
|
116
|
+
)
|
|
117
|
+
|
|
118
|
+
/**
|
|
119
|
+
* 动画自定义样式
|
|
120
|
+
*/
|
|
121
|
+
const transitionStyle = computed(() => {
|
|
122
|
+
const style: CSSProperties = {
|
|
123
|
+
'z-index': zIndex.value,
|
|
124
|
+
position: 'fixed',
|
|
125
|
+
top: '50%',
|
|
126
|
+
left: 0,
|
|
127
|
+
width: '100%',
|
|
128
|
+
transform: 'translate(0, -50%)',
|
|
129
|
+
'text-align': 'center',
|
|
130
|
+
}
|
|
131
|
+
return objToStyle(style)
|
|
132
|
+
})
|
|
133
|
+
|
|
134
|
+
const rootClass = computed(() => {
|
|
135
|
+
return `wd-toast ${props.customClass} wd-toast--${position.value} ${
|
|
136
|
+
(iconName.value !== 'loading' || msg.value) && (iconName.value || iconClass.value)
|
|
137
|
+
? 'wd-toast--with-icon'
|
|
138
|
+
: ''
|
|
139
|
+
} ${iconName.value === 'loading' && !msg.value ? 'wd-toast--loading' : ''}`
|
|
140
|
+
})
|
|
141
|
+
|
|
142
|
+
const svgStyle = computed(() => {
|
|
143
|
+
const style: CSSProperties = {
|
|
144
|
+
backgroundImage: `url(${svgStr.value})`,
|
|
145
|
+
}
|
|
146
|
+
if (isDef(iconSize.value)) {
|
|
147
|
+
style.width = iconSize.value
|
|
148
|
+
style.height = iconSize.value
|
|
149
|
+
}
|
|
150
|
+
return objToStyle(style)
|
|
151
|
+
})
|
|
152
|
+
|
|
153
|
+
onBeforeMount(() => {
|
|
154
|
+
buildSvg()
|
|
155
|
+
})
|
|
156
|
+
|
|
157
|
+
function handleAfterEnter() {
|
|
158
|
+
if (isFunction(opened)) {
|
|
159
|
+
opened()
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
function handleAfterLeave() {
|
|
164
|
+
if (isFunction(closed)) {
|
|
165
|
+
closed()
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
function buildSvg() {
|
|
170
|
+
if (
|
|
171
|
+
iconName.value !== 'success' &&
|
|
172
|
+
iconName.value !== 'warning' &&
|
|
173
|
+
iconName.value !== 'info' &&
|
|
174
|
+
iconName.value !== 'error'
|
|
175
|
+
)
|
|
176
|
+
return
|
|
177
|
+
const iconSvg = toastIcon[iconName.value]()
|
|
178
|
+
const iconSvgStr = `"data:image/svg+xml;base64,${base64(iconSvg)}"`
|
|
179
|
+
svgStr.value = iconSvgStr
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* 重置toast选项值
|
|
184
|
+
* @param option toast选项值
|
|
185
|
+
*/
|
|
186
|
+
function reset(option: ToastOptions) {
|
|
187
|
+
if (option) {
|
|
188
|
+
show.value = isDef(option.show) ? option.show : false
|
|
189
|
+
|
|
190
|
+
if (show.value) {
|
|
191
|
+
iconName.value = isDef(option.iconName!) ? option.iconName! : ''
|
|
192
|
+
iconClass.value = isDef(option.iconClass!) ? option.iconClass! : ''
|
|
193
|
+
msg.value = isDef(option.msg!) ? option.msg! : ''
|
|
194
|
+
position.value = isDef(option.position!) ? option.position! : 'middle'
|
|
195
|
+
zIndex.value = isDef(option.zIndex!) ? option.zIndex! : 100
|
|
196
|
+
loadingType.value = isDef(option.loadingType!) ? option.loadingType! : 'outline'
|
|
197
|
+
loadingColor.value = isDef(option.loadingColor!) ? option.loadingColor! : '#4D80F0'
|
|
198
|
+
iconSize.value = isDef(option.iconSize) ? addUnit(option.iconSize) : option.iconSize
|
|
199
|
+
loadingSize.value = isDef(option.loadingSize)
|
|
200
|
+
? addUnit(option.loadingSize)
|
|
201
|
+
: option.loadingSize
|
|
202
|
+
cover.value = isDef(option.cover!) ? option.cover! : false
|
|
203
|
+
classPrefix.value = isDef(option.classPrefix) ? option.classPrefix : 'wd-icon'
|
|
204
|
+
closed = isFunction(option.closed) ? option.closed : null
|
|
205
|
+
opened = isFunction(option.opened) ? option.opened : null
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
</script>
|
|
210
|
+
<style lang="scss" scoped>
|
|
211
|
+
@import './index';
|
|
212
|
+
</style>
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
@import './../common/abstracts/_mixin';
|
|
2
|
+
@import './../common/abstracts/variable';
|
|
3
|
+
|
|
4
|
+
.wot-theme-dark {
|
|
5
|
+
@include b(tooltip) {
|
|
6
|
+
@include e(pos) {
|
|
7
|
+
color: $-tooltip-color;
|
|
8
|
+
background: $-dark-background4;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
@include triangleArrow($-tooltip-arrow-size, $-dark-background4);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
@include b(tooltip) {
|
|
16
|
+
position: relative;
|
|
17
|
+
display: inline-block;
|
|
18
|
+
|
|
19
|
+
@include edeep(pos) {
|
|
20
|
+
position: absolute;
|
|
21
|
+
z-index: $-tooltip-z-index;
|
|
22
|
+
box-sizing: border-box;
|
|
23
|
+
min-width: 138px;
|
|
24
|
+
min-height: 36px;
|
|
25
|
+
font-size: $-tooltip-fs;
|
|
26
|
+
color: $-tooltip-color;
|
|
27
|
+
text-align: center;
|
|
28
|
+
background: $-tooltip-bg;
|
|
29
|
+
background-clip: padding-box;
|
|
30
|
+
backdrop-filter: blur($-tooltip-blur);
|
|
31
|
+
border-radius: $-tooltip-radius;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@include e(hidden) {
|
|
35
|
+
bottom: -100vh;
|
|
36
|
+
left: -100vw;
|
|
37
|
+
visibility: hidden;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
@include e(container) {
|
|
41
|
+
font-size: $-tooltip-fs;
|
|
42
|
+
line-height: $-tooltip-line-height;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@include e(inner) {
|
|
46
|
+
padding: $-tooltip-padding;
|
|
47
|
+
line-height: $-tooltip-line-height;
|
|
48
|
+
white-space: nowrap;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@include edeep(close-icon) {
|
|
52
|
+
position: absolute;
|
|
53
|
+
top: -10px;
|
|
54
|
+
right: -8px;
|
|
55
|
+
padding: 10px;
|
|
56
|
+
font-size: 12px;
|
|
57
|
+
transform: scale(0.5);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
@include triangleArrow($-tooltip-arrow-size, $-tooltip-bg);
|
|
61
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import type { ComponentPublicInstance, ExtractPropTypes, PropType } from 'vue'
|
|
2
|
+
import { baseProps, makeBooleanProp, makeNumberProp, makeStringProp } from '../common/props'
|
|
3
|
+
|
|
4
|
+
export type PlacementType =
|
|
5
|
+
| 'top'
|
|
6
|
+
| 'top-start'
|
|
7
|
+
| 'top-end'
|
|
8
|
+
| 'bottom'
|
|
9
|
+
| 'bottom-start'
|
|
10
|
+
| 'bottom-end'
|
|
11
|
+
| 'left'
|
|
12
|
+
| 'left-start'
|
|
13
|
+
| 'left-end'
|
|
14
|
+
| 'right'
|
|
15
|
+
| 'right-start'
|
|
16
|
+
| 'right-end'
|
|
17
|
+
|
|
18
|
+
export const tooltipProps = {
|
|
19
|
+
...baseProps,
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* 自定义箭头内容
|
|
23
|
+
* 类型:string
|
|
24
|
+
*/
|
|
25
|
+
customArrow: makeStringProp(''),
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* 自定义弹出内容
|
|
29
|
+
* 类型:string
|
|
30
|
+
*/
|
|
31
|
+
customPop: makeStringProp(''),
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* 是否显示Tooltip箭头
|
|
35
|
+
* 类型:boolean
|
|
36
|
+
* 默认值:true
|
|
37
|
+
*/
|
|
38
|
+
visibleArrow: makeBooleanProp(true),
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* 显示的内容,也可以通过`slot#content`传入
|
|
42
|
+
* 类型:string | Array<Record<string, any>>
|
|
43
|
+
* 默认值:无(根据传入值而定)
|
|
44
|
+
*/
|
|
45
|
+
content: {
|
|
46
|
+
type: [String, Array] as PropType<string | Array<Record<string, any>>>,
|
|
47
|
+
},
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Tooltip的出现位置
|
|
51
|
+
* 类型:string
|
|
52
|
+
* 可选值:top/top-start/top-end/bottom/bottom-start/bottom-end/left/left-start/left-end/right/right-start/right-end
|
|
53
|
+
* 默认值:'bottom'
|
|
54
|
+
*/
|
|
55
|
+
placement: makeStringProp<PlacementType>('bottom'),
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* 出现位置的偏移量
|
|
59
|
+
* 类型:number
|
|
60
|
+
* 默认值:0
|
|
61
|
+
*/
|
|
62
|
+
offset: makeNumberProp(0),
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* 是否使用slot来传入content内容
|
|
66
|
+
* 类型:boolean
|
|
67
|
+
* 默认值:false
|
|
68
|
+
*/
|
|
69
|
+
useContentSlot: makeBooleanProp(false),
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Tooltip是否可用
|
|
73
|
+
* 类型:boolean
|
|
74
|
+
* 默认值:false
|
|
75
|
+
*/
|
|
76
|
+
disabled: makeBooleanProp(false),
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* 是否显示Tooltip内部的关闭按钮
|
|
80
|
+
* 类型:boolean
|
|
81
|
+
* 默认值:false
|
|
82
|
+
*/
|
|
83
|
+
showClose: makeBooleanProp(false),
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Tooltip的状态是否可见,通过v-model绑定
|
|
87
|
+
* 类型:boolean
|
|
88
|
+
* 默认值:false
|
|
89
|
+
*/
|
|
90
|
+
modelValue: makeBooleanProp(false),
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export type TooltipProps = ExtractPropTypes<typeof tooltipProps>
|
|
94
|
+
|
|
95
|
+
export type TooltipExpose = {
|
|
96
|
+
// 打开tooltip
|
|
97
|
+
open: () => void
|
|
98
|
+
// 关闭tooltip
|
|
99
|
+
close: () => void
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export type TooltipInstance = ComponentPublicInstance<TooltipProps, TooltipExpose>
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view
|
|
3
|
+
:class="`wd-tooltip ${customClass}`"
|
|
4
|
+
:style="customStyle"
|
|
5
|
+
id="tooltip"
|
|
6
|
+
@click.stop="popover.noop"
|
|
7
|
+
>
|
|
8
|
+
<!-- 用于为渲染获取宽高的元素 -->
|
|
9
|
+
<view class="wd-tooltip__pos wd-tooltip__hidden" id="pos">
|
|
10
|
+
<view class="wd-tooltip__container custom-pop">
|
|
11
|
+
<view v-if="!useContentSlot" class="wd-tooltip__inner">{{ content }}</view>
|
|
12
|
+
</view>
|
|
13
|
+
</view>
|
|
14
|
+
<wd-transition
|
|
15
|
+
custom-class="wd-tooltip__pos"
|
|
16
|
+
:custom-style="popover.popStyle.value"
|
|
17
|
+
:show="showTooltip"
|
|
18
|
+
name="fade"
|
|
19
|
+
:duration="200"
|
|
20
|
+
>
|
|
21
|
+
<view class="wd-tooltip__container custom-pop">
|
|
22
|
+
<view
|
|
23
|
+
v-if="visibleArrow"
|
|
24
|
+
:class="`wd-tooltip__arrow ${popover.arrowClass.value} ${customArrow}`"
|
|
25
|
+
:style="popover.arrowStyle.value"
|
|
26
|
+
></view>
|
|
27
|
+
<!-- 普通模式 -->
|
|
28
|
+
<view v-if="!useContentSlot" class="wd-tooltip__inner">{{ content }}</view>
|
|
29
|
+
<!-- 用户自定义样式 -->
|
|
30
|
+
<slot name="content" v-else />
|
|
31
|
+
</view>
|
|
32
|
+
<wd-icon
|
|
33
|
+
v-if="showClose"
|
|
34
|
+
name="close"
|
|
35
|
+
custom-class="wd-tooltip__close-icon"
|
|
36
|
+
@click="toggle"
|
|
37
|
+
></wd-icon>
|
|
38
|
+
</wd-transition>
|
|
39
|
+
<view @click="toggle" class="wd-tooltip__target" id="target">
|
|
40
|
+
<slot />
|
|
41
|
+
</view>
|
|
42
|
+
</view>
|
|
43
|
+
</template>
|
|
44
|
+
|
|
45
|
+
<script lang="ts">
|
|
46
|
+
export default {
|
|
47
|
+
name: 'wd-tooltip',
|
|
48
|
+
options: {
|
|
49
|
+
addGlobalClass: true,
|
|
50
|
+
virtualHost: true,
|
|
51
|
+
styleIsolation: 'shared',
|
|
52
|
+
},
|
|
53
|
+
}
|
|
54
|
+
</script>
|
|
55
|
+
|
|
56
|
+
<script lang="ts" setup>
|
|
57
|
+
import {
|
|
58
|
+
getCurrentInstance,
|
|
59
|
+
inject,
|
|
60
|
+
onBeforeMount,
|
|
61
|
+
onBeforeUnmount,
|
|
62
|
+
onMounted,
|
|
63
|
+
ref,
|
|
64
|
+
watch,
|
|
65
|
+
} from 'vue'
|
|
66
|
+
import { usePopover } from '../composables/usePopover'
|
|
67
|
+
import { closeOther, pushToQueue, removeFromQueue } from '../common/clickoutside'
|
|
68
|
+
import { type Queue, queueKey } from '../composables/useQueue'
|
|
69
|
+
import { tooltipProps, type TooltipExpose } from './types'
|
|
70
|
+
|
|
71
|
+
const props = defineProps(tooltipProps)
|
|
72
|
+
const emit = defineEmits(['update:modelValue', 'menuclick', 'change', 'open', 'close'])
|
|
73
|
+
|
|
74
|
+
const popover = usePopover()
|
|
75
|
+
const queue = inject<Queue | null>(queueKey, null)
|
|
76
|
+
const selector: string = 'tooltip'
|
|
77
|
+
const { proxy } = getCurrentInstance() as any
|
|
78
|
+
const showTooltip = ref<boolean>(false) // 控制tooltip显隐
|
|
79
|
+
|
|
80
|
+
watch(
|
|
81
|
+
() => props.content,
|
|
82
|
+
(newVal) => {
|
|
83
|
+
if (newVal === null || newVal === undefined) {
|
|
84
|
+
// eslint-disable-next-line prettier/prettier
|
|
85
|
+
console.error('[wot-design] warning(wd-tooltip): content can\'t be null or undefined')
|
|
86
|
+
}
|
|
87
|
+
},
|
|
88
|
+
)
|
|
89
|
+
|
|
90
|
+
watch(
|
|
91
|
+
() => props.placement,
|
|
92
|
+
() => {
|
|
93
|
+
popover.init(props.placement, props.visibleArrow, selector)
|
|
94
|
+
},
|
|
95
|
+
)
|
|
96
|
+
|
|
97
|
+
watch(
|
|
98
|
+
() => props.modelValue,
|
|
99
|
+
(newValue) => {
|
|
100
|
+
showTooltip.value = newValue
|
|
101
|
+
},
|
|
102
|
+
)
|
|
103
|
+
|
|
104
|
+
watch(
|
|
105
|
+
() => showTooltip.value,
|
|
106
|
+
(newValue) => {
|
|
107
|
+
if (newValue) {
|
|
108
|
+
popover.control(props.placement, props.offset)
|
|
109
|
+
if (queue && queue.closeOther) {
|
|
110
|
+
queue.closeOther(proxy)
|
|
111
|
+
} else {
|
|
112
|
+
closeOther(proxy)
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
popover.showStyle.value = newValue ? 'display: inline-block;' : 'display: none;'
|
|
116
|
+
emit('change', { show: newValue })
|
|
117
|
+
emit(`${newValue ? 'open' : 'close'}`)
|
|
118
|
+
},
|
|
119
|
+
)
|
|
120
|
+
|
|
121
|
+
onMounted(() => {
|
|
122
|
+
popover.init(props.placement, props.visibleArrow, selector)
|
|
123
|
+
})
|
|
124
|
+
|
|
125
|
+
onBeforeMount(() => {
|
|
126
|
+
if (queue && queue.pushToQueue) {
|
|
127
|
+
queue.pushToQueue(proxy)
|
|
128
|
+
} else {
|
|
129
|
+
pushToQueue(proxy)
|
|
130
|
+
}
|
|
131
|
+
popover.showStyle.value = props.modelValue ? 'opacity: 1;' : 'opacity: 0;'
|
|
132
|
+
})
|
|
133
|
+
|
|
134
|
+
onBeforeUnmount(() => {
|
|
135
|
+
if (queue && queue.removeFromQueue) {
|
|
136
|
+
queue.removeFromQueue(proxy)
|
|
137
|
+
} else {
|
|
138
|
+
removeFromQueue(proxy)
|
|
139
|
+
}
|
|
140
|
+
})
|
|
141
|
+
|
|
142
|
+
function toggle() {
|
|
143
|
+
if (props.disabled) return
|
|
144
|
+
updateModelValue(!showTooltip.value)
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
function open() {
|
|
148
|
+
updateModelValue(true)
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
function close() {
|
|
152
|
+
updateModelValue(false)
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
function updateModelValue(value: boolean) {
|
|
156
|
+
showTooltip.value = value
|
|
157
|
+
emit('update:modelValue', value)
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
defineExpose<TooltipExpose>({
|
|
161
|
+
open,
|
|
162
|
+
close,
|
|
163
|
+
})
|
|
164
|
+
</script>
|
|
165
|
+
<style lang="scss" scoped>
|
|
166
|
+
@import './index';
|
|
167
|
+
</style>
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
.wd-transition {
|
|
2
|
+
transition-timing-function: ease;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.wd-fade-enter-active,
|
|
6
|
+
.wd-fade-leave-active {
|
|
7
|
+
transition-property: opacity;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.wd-fade-enter,
|
|
11
|
+
.wd-fade-leave-to {
|
|
12
|
+
opacity: 0;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.wd-fade-up-enter-active,
|
|
16
|
+
.wd-fade-up-leave-active,
|
|
17
|
+
.wd-fade-down-enter-active,
|
|
18
|
+
.wd-fade-down-leave-active,
|
|
19
|
+
.wd-fade-left-enter-active,
|
|
20
|
+
.wd-fade-left-leave-active,
|
|
21
|
+
.wd-fade-right-enter-active,
|
|
22
|
+
.wd-fade-right-enter-active {
|
|
23
|
+
transition-property: opacity, transform;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.wd-fade-up-enter,
|
|
27
|
+
.wd-fade-up-leave-to {
|
|
28
|
+
opacity: 0;
|
|
29
|
+
transform: translate3d(0, 100%, 0);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.wd-fade-down-enter,
|
|
33
|
+
.wd-fade-down-leave-to {
|
|
34
|
+
opacity: 0;
|
|
35
|
+
transform: translate3d(0, -100%, 0);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.wd-fade-left-enter,
|
|
39
|
+
.wd-fade-left-leave-to {
|
|
40
|
+
opacity: 0;
|
|
41
|
+
transform: translate3d(-100%, 0, 0);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.wd-fade-right-enter,
|
|
45
|
+
.wd-fade-right-leave-to {
|
|
46
|
+
opacity: 0;
|
|
47
|
+
transform: translate3d(100%, 0, 0);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.wd-slide-up-enter-active,
|
|
51
|
+
.wd-slide-up-leave-active,
|
|
52
|
+
.wd-slide-down-enter-active,
|
|
53
|
+
.wd-slide-down-leave-active,
|
|
54
|
+
.wd-slide-left-enter-active,
|
|
55
|
+
.wd-slide-left-leave-active,
|
|
56
|
+
.wd-slide-right-enter-active,
|
|
57
|
+
.wd-slide-right-enter-active {
|
|
58
|
+
transition-property: transform;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.wd-slide-up-enter,
|
|
62
|
+
.wd-slide-up-leave-to {
|
|
63
|
+
transform: translate3d(0, 100%, 0);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.wd-slide-down-enter,
|
|
67
|
+
.wd-slide-down-leave-to {
|
|
68
|
+
transform: translate3d(0, -100%, 0);
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.wd-slide-left-enter,
|
|
72
|
+
.wd-slide-left-leave-to {
|
|
73
|
+
transform: translate3d(-100%, 0, 0);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.wd-slide-right-enter,
|
|
77
|
+
.wd-slide-right-leave-to {
|
|
78
|
+
transform: translate3d(100%, 0, 0);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.wd-zoom-in-enter-active,
|
|
82
|
+
.wd-zoom-in-leave-active {
|
|
83
|
+
transition-property: opacity, transform;
|
|
84
|
+
transform-origin: center center;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.wd-zoom-in-enter,
|
|
88
|
+
.wd-zoom-in-leave-to {
|
|
89
|
+
opacity: 0;
|
|
90
|
+
transform: scale(0.7);
|
|
91
|
+
}
|