@nutui/nutui 3.2.2 → 3.2.3
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/CHANGELOG.md +53 -0
- package/dist/nutui.es.js +2127 -1414
- package/dist/nutui.umd.js +2136 -1422
- package/dist/packages/_es/ActionSheet.js +4 -22
- package/dist/packages/_es/Address.js +63 -57
- package/dist/packages/_es/AddressList.js +12 -9
- package/dist/packages/_es/Animate.js +2 -21
- package/dist/packages/_es/Audio.js +11 -25
- package/dist/packages/_es/AudioOperate.js +3 -23
- package/dist/packages/_es/Avatar.js +6 -21
- package/dist/packages/_es/AvatarGroup.js +1 -1
- package/dist/packages/_es/BackTop.js +1 -1
- package/dist/packages/_es/Badge.js +1 -1
- package/dist/packages/_es/Barrage.js +74 -22
- package/dist/packages/_es/Button.js +1 -1
- package/dist/packages/_es/Calendar.js +17 -9
- package/dist/packages/_es/CalendarItem.js +1 -1
- package/dist/packages/_es/Card.js +1 -1
- package/dist/packages/_es/Cascader.js +72 -68
- package/dist/packages/_es/Category.js +1 -1
- package/dist/packages/_es/CategoryPane.js +1 -1
- package/dist/packages/_es/Cell.js +1 -1
- package/dist/packages/_es/CellGroup.js +1 -1
- package/dist/packages/_es/Checkbox.js +31 -17
- package/dist/packages/_es/CheckboxGroup.js +14 -7
- package/dist/packages/_es/CircleProgress.js +4 -4
- package/dist/packages/_es/Col.js +1 -1
- package/dist/packages/_es/Collapse.js +22 -19
- package/dist/packages/_es/CollapseItem.js +18 -32
- package/dist/packages/_es/Comment.js +13 -9
- package/dist/packages/_es/ConfigProvider.js +8 -4
- package/dist/packages/_es/CountDown.js +40 -46
- package/dist/packages/_es/CountUp.js +41 -40
- package/dist/packages/_es/DatePicker.js +25 -33
- package/dist/packages/_es/Dialog.js +13 -28
- package/dist/packages/_es/Divider.js +7 -24
- package/dist/packages/_es/Drag.js +2 -2
- package/dist/packages/_es/Ecard.js +8 -5
- package/dist/packages/_es/Elevator.js +27 -39
- package/dist/packages/_es/Ellipsis.js +14 -28
- package/dist/packages/_es/Empty.js +1 -1
- package/dist/packages/_es/FixedNav.js +1 -1
- package/dist/packages/_es/Form.js +23 -12
- package/dist/packages/_es/FormItem.js +1 -1
- package/dist/packages/_es/Grid.js +1 -1
- package/dist/packages/_es/GridItem.js +1 -1
- package/dist/packages/_es/Icon.js +15 -11
- package/dist/packages/_es/Image.js +8 -24
- package/dist/packages/_es/ImagePreview.js +34 -48
- package/dist/packages/_es/Indicator.js +1 -1
- package/dist/packages/_es/InfiniteLoading.js +5 -24
- package/dist/packages/_es/Input.js +8 -5
- package/dist/packages/_es/InputNumber.js +1 -1
- package/dist/packages/_es/Invoice.js +10 -25
- package/dist/packages/_es/Layout.js +1 -1
- package/dist/packages/_es/List.js +21 -30
- package/dist/packages/_es/Menu.js +13 -7
- package/dist/packages/_es/MenuItem.js +2 -21
- package/dist/packages/_es/Navbar.js +1 -1
- package/dist/packages/_es/NoticeBar.js +18 -29
- package/dist/packages/_es/Notify.js +16 -32
- package/dist/packages/_es/NumberKeyboard.js +23 -18
- package/dist/packages/_es/OldPicker.js +47 -46
- package/dist/packages/_es/OverLay.js +11 -23
- package/dist/packages/_es/Pagination.js +6 -6
- package/dist/packages/_es/Picker.js +66 -59
- package/dist/packages/_es/Popover.js +55 -52
- package/dist/packages/_es/Popup.js +35 -40
- package/dist/packages/_es/Price.js +1 -1
- package/dist/packages/_es/Progress.js +2 -2
- package/dist/packages/_es/PullRefresh.js +5 -20
- package/dist/packages/_es/Radio.js +25 -13
- package/dist/packages/_es/RadioGroup.js +12 -5
- package/dist/packages/_es/Range.js +20 -33
- package/dist/packages/_es/Rate.js +6 -24
- package/dist/packages/_es/Row.js +1 -1
- package/dist/packages/_es/SearchBar.js +6 -25
- package/dist/packages/_es/ShortPassword.js +18 -11
- package/dist/packages/_es/SideNavBar.js +6 -24
- package/dist/packages/_es/SideNavBarItem.js +1 -1
- package/dist/packages/_es/Signature.js +2 -21
- package/dist/packages/_es/Skeleton.js +1 -1
- package/dist/packages/_es/Sku.js +30 -35
- package/dist/packages/_es/Step.js +4 -22
- package/dist/packages/_es/Steps.js +8 -4
- package/dist/packages/_es/Sticky.js +23 -12
- package/dist/packages/_es/SubSideNavBar.js +4 -22
- package/dist/packages/_es/Swipe.js +5 -24
- package/dist/packages/_es/Swiper.js +23 -14
- package/dist/packages/_es/SwiperItem.js +1 -1
- package/dist/packages/_es/Switch.js +10 -7
- package/dist/packages/_es/TabPane.js +1 -1
- package/dist/packages/_es/Tabbar.js +7 -4
- package/dist/packages/_es/TabbarItem.js +1 -1
- package/dist/packages/_es/Table.js +10 -25
- package/dist/packages/_es/Tabs.js +99 -34
- package/dist/packages/_es/Tag.js +1 -2
- package/dist/packages/_es/TextArea.js +8 -5
- package/dist/packages/_es/TimeDetail.js +5 -24
- package/dist/packages/_es/TimePannel.js +4 -22
- package/dist/packages/_es/TimeSelect.js +1 -1
- package/dist/packages/_es/Toast.js +19 -35
- package/dist/packages/_es/TrendArrow.js +131 -0
- package/dist/packages/_es/Uploader.js +40 -34
- package/dist/packages/_es/Video.js +22 -33
- package/dist/packages/_es/WaterMark.js +31 -41
- package/dist/packages/_es/common.js +21 -11
- package/dist/packages/_es/component.js +13 -6
- package/dist/packages/_es/index.js +1 -1
- package/dist/packages/_es/index2.js +1 -1
- package/dist/packages/_es/index3.js +1 -1
- package/dist/packages/_es/index4.js +1 -1
- package/dist/packages/_es/index5.js +39 -41
- package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
- package/dist/packages/_es/pxCheck.js +1 -1
- package/dist/packages/_es/raf.js +1 -1
- package/dist/packages/_es/style.css +16 -1
- package/dist/packages/barrage/index.scss +27 -18
- package/dist/packages/list/index.scss +0 -1
- package/dist/packages/locale/lang/baseLang.js +1 -1
- package/dist/packages/locale/lang/en-US.js +1 -1
- package/dist/packages/locale/lang/id-ID.js +1 -1
- package/dist/packages/locale/lang/index.js +1 -1
- package/dist/packages/locale/lang/zh-CN.js +1 -1
- package/dist/packages/locale/lang/zh-TW.js +1 -1
- package/dist/packages/picker/index.scss +14 -0
- package/dist/packages/tabbar/index.scss +2 -1
- package/dist/packages/trendarrow/index.scss +17 -0
- package/dist/smartips/attributes.json +70 -10
- package/dist/smartips/tags.json +26 -7
- package/dist/smartips/web-types.json +153 -11
- package/dist/style.css +1 -1
- package/dist/style.es.js +1 -1
- package/dist/styles/font/config.json +3 -1
- package/dist/styles/font/demo_index.html +51 -5
- package/dist/styles/font/iconfont.css +11 -3
- package/dist/styles/font/iconfont.js +64 -61
- package/dist/styles/font/iconfont.json +14 -0
- package/dist/styles/font/iconfont.ttf +0 -0
- package/dist/styles/font/iconfont.woff +0 -0
- package/dist/styles/font/iconfont.woff2 +0 -0
- package/dist/styles/themes/default.scss +48 -47
- package/dist/styles/themes/jdb.scss +48 -47
- package/dist/styles/themes/jdt.scss +48 -47
- package/dist/styles/variables-jdb.scss +4 -1
- package/dist/styles/variables-jdt.scss +4 -1
- package/dist/styles/variables.scss +4 -1
- package/dist/types/__VUE/actionsheet/index.vue.d.ts +117 -63
- package/dist/types/__VUE/address/index.vue.d.ts +150 -80
- package/dist/types/__VUE/addresslist/components/GeneralShell.vue.d.ts +6 -5
- package/dist/types/__VUE/addresslist/components/ItemContents.vue.d.ts +10 -7
- package/dist/types/__VUE/addresslist/components/LongPressShell.vue.d.ts +6 -5
- package/dist/types/__VUE/addresslist/components/SwipeShell.vue.d.ts +6 -5
- package/dist/types/__VUE/addresslist/index.vue.d.ts +22 -13
- package/dist/types/__VUE/animate/index.vue.d.ts +14 -9
- package/dist/types/__VUE/audio/index.vue.d.ts +30 -17
- package/dist/types/__VUE/audiooperate/index.vue.d.ts +6 -5
- package/dist/types/__VUE/avatar/index.vue.d.ts +34 -21
- package/dist/types/__VUE/avatargroup/index.vue.d.ts +34 -19
- package/dist/types/__VUE/backtop/index.vue.d.ts +31 -18
- package/dist/types/__VUE/badge/index.vue.d.ts +33 -20
- package/dist/types/__VUE/barrage/index.vue.d.ts +28 -16
- package/dist/types/__VUE/button/index.vue.d.ts +44 -27
- package/dist/types/__VUE/calendar/index.vue.d.ts +62 -35
- package/dist/types/__VUE/calendaritem/index.vue.d.ts +72 -45
- package/dist/types/__VUE/card/index.vue.d.ts +34 -19
- package/dist/types/__VUE/cascader/cascader-item.vue.d.ts +25 -24
- package/dist/types/__VUE/cascader/index.vue.d.ts +109 -64
- package/dist/types/__VUE/category/index.vue.d.ts +10 -7
- package/dist/types/__VUE/categorypane/index.vue.d.ts +14 -9
- package/dist/types/__VUE/cell/index.vue.d.ts +55 -34
- package/dist/types/__VUE/cellgroup/index.vue.d.ts +10 -7
- package/dist/types/__VUE/checkbox/index.vue.d.ts +47 -26
- package/dist/types/__VUE/checkboxgroup/index.vue.d.ts +14 -9
- package/dist/types/__VUE/circleprogress/index.vue.d.ts +30 -17
- package/dist/types/__VUE/col/index.vue.d.ts +10 -7
- package/dist/types/__VUE/collapse/index.vue.d.ts +40 -24
- package/dist/types/__VUE/collapseitem/index.vue.d.ts +29 -21
- package/dist/types/__VUE/comment/components/CmtBottom.vue.d.ts +14 -9
- package/dist/types/__VUE/comment/components/CmtHeader.vue.d.ts +14 -9
- package/dist/types/__VUE/comment/components/CmtImages.vue.d.ts +14 -9
- package/dist/types/__VUE/comment/index.vue.d.ts +38 -21
- package/dist/types/__VUE/configprovider/index.vue.d.ts +10 -7
- package/dist/types/__VUE/countdown/index.vue.d.ts +34 -20
- package/dist/types/__VUE/countdown/util.d.ts +1 -1
- package/dist/types/__VUE/countup/index.vue.d.ts +73 -40
- package/dist/types/__VUE/datepicker/index.vue.d.ts +132 -71
- package/dist/types/__VUE/dialog/index.vue.d.ts +136 -74
- package/dist/types/__VUE/divider/index.vue.d.ts +18 -11
- package/dist/types/__VUE/drag/index.vue.d.ts +19 -9
- package/dist/types/__VUE/ecard/index.vue.d.ts +42 -23
- package/dist/types/__VUE/elevator/index.vue.d.ts +26 -15
- package/dist/types/__VUE/ellipsis/index.vue.d.ts +26 -15
- package/dist/types/__VUE/empty/index.vue.d.ts +14 -9
- package/dist/types/__VUE/fixednav/index.vue.d.ts +39 -21
- package/dist/types/__VUE/form/common.d.ts +4 -0
- package/dist/types/__VUE/form/index.vue.d.ts +16 -6
- package/dist/types/__VUE/formitem/index.vue.d.ts +42 -23
- package/dist/types/__VUE/grid/index.vue.d.ts +40 -24
- package/dist/types/__VUE/griditem/index.vue.d.ts +25 -18
- package/dist/types/__VUE/icon/index.vue.d.ts +26 -15
- package/dist/types/__VUE/image/index.vue.d.ts +37 -25
- package/dist/types/__VUE/imagepreview/imagePreviewItem.vue.d.ts +42 -29
- package/dist/types/__VUE/imagepreview/index.d.ts +4 -4
- package/dist/types/__VUE/imagepreview/index.vue.d.ts +64 -37
- package/dist/types/__VUE/indicator/index.vue.d.ts +24 -13
- package/dist/types/__VUE/infiniteloading/index.vue.d.ts +46 -25
- package/dist/types/__VUE/input/index.vue.d.ts +133 -70
- package/dist/types/__VUE/inputnumber/index.vue.d.ts +46 -25
- package/dist/types/__VUE/invoice/index.vue.d.ts +14 -9
- package/dist/types/__VUE/layout/index.vue.d.ts +1 -1
- package/dist/types/__VUE/list/index.vue.d.ts +15 -9
- package/dist/types/__VUE/menu/index.vue.d.ts +32 -22
- package/dist/types/__VUE/menuitem/index.vue.d.ts +22 -20
- package/dist/types/__VUE/navbar/index.vue.d.ts +42 -23
- package/dist/types/__VUE/noticebar/index.vue.d.ts +65 -36
- package/dist/types/__VUE/notify/index.vue.d.ts +42 -30
- package/dist/types/__VUE/numberkeyboard/index.vue.d.ts +65 -36
- package/dist/types/__VUE/oldpicker/Column.vue.d.ts +20 -15
- package/dist/types/__VUE/oldpicker/index.vue.d.ts +124 -71
- package/dist/types/__VUE/overlay/index.vue.d.ts +30 -1547
- package/dist/types/__VUE/pagination/index.vue.d.ts +42 -25
- package/dist/types/__VUE/picker/Column.vue.d.ts +25 -19
- package/dist/types/__VUE/picker/index.vue.d.ts +137 -79
- package/dist/types/__VUE/popover/index.vue.d.ts +107 -59
- package/dist/types/__VUE/popup/index.vue.d.ts +92 -62
- package/dist/types/__VUE/price/index.vue.d.ts +30 -17
- package/dist/types/__VUE/progress/index.vue.d.ts +51 -27
- package/dist/types/__VUE/pullrefresh/index.vue.d.ts +45 -17
- package/dist/types/__VUE/radio/index.vue.d.ts +34 -19
- package/dist/types/__VUE/radiogroup/index.vue.d.ts +14 -9
- package/dist/types/__VUE/range/index.vue.d.ts +46 -34
- package/dist/types/__VUE/rate/index.vue.d.ts +59 -32
- package/dist/types/__VUE/row/index.vue.d.ts +22 -13
- package/dist/types/__VUE/searchbar/index.vue.d.ts +58 -31
- package/dist/types/__VUE/shortpassword/index.vue.d.ts +42 -23
- package/dist/types/__VUE/sidenavbar/index.vue.d.ts +6 -5
- package/dist/types/__VUE/sidenavbaritem/index.vue.d.ts +10 -7
- package/dist/types/__VUE/signature/index.vue.d.ts +22 -13
- package/dist/types/__VUE/skeleton/common.d.ts +1 -1
- package/dist/types/__VUE/skeleton/index.vue.d.ts +43 -24
- package/dist/types/__VUE/sku/components/SkuHeader.vue.d.ts +6 -5
- package/dist/types/__VUE/sku/components/SkuOperate.vue.d.ts +22 -13
- package/dist/types/__VUE/sku/components/SkuSelect.vue.d.ts +6 -5
- package/dist/types/__VUE/sku/components/SkuStepper.vue.d.ts +18 -11
- package/dist/types/__VUE/sku/index.vue.d.ts +125 -67
- package/dist/types/__VUE/step/index.vue.d.ts +24 -15
- package/dist/types/__VUE/steps/index.vue.d.ts +14 -9
- package/dist/types/__VUE/sticky/index.vue.d.ts +21 -14
- package/dist/types/__VUE/subsidenavbar/index.vue.d.ts +14 -9
- package/dist/types/__VUE/swipe/index.vue.d.ts +19 -12
- package/dist/types/__VUE/swiper/index.vue.d.ts +54 -29
- package/dist/types/__VUE/swiperitem/index.vue.d.ts +1 -1
- package/dist/types/__VUE/switch/index.vue.d.ts +50 -27
- package/dist/types/__VUE/tabbar/index.vue.d.ts +31 -18
- package/dist/types/__VUE/tabbaritem/index.vue.d.ts +42 -26
- package/dist/types/__VUE/table/common.d.ts +1 -1
- package/dist/types/__VUE/table/index.vue.d.ts +24 -15
- package/dist/types/__VUE/tabpane/index.vue.d.ts +14 -9
- package/dist/types/__VUE/tabs/common.d.ts +13 -0
- package/dist/types/__VUE/tabs/index.vue.d.ts +70 -26
- package/dist/types/__VUE/tag/index.vue.d.ts +30 -17
- package/dist/types/__VUE/textarea/index.vue.d.ts +43 -24
- package/dist/types/__VUE/timedetail/index.vue.d.ts +10 -7
- package/dist/types/__VUE/timepannel/index.vue.d.ts +10 -7
- package/dist/types/__VUE/timeselect/index.vue.d.ts +31 -18
- package/dist/types/__VUE/toast/index.d.ts +1 -1
- package/dist/types/__VUE/toast/index.vue.d.ts +58 -43
- package/dist/types/__VUE/trendarrow/index.vue.d.ts +138 -0
- package/dist/types/__VUE/uploader/index.vue.d.ts +108 -59
- package/dist/types/__VUE/video/index.vue.d.ts +27 -10
- package/dist/types/__VUE/watermark/index.vue.d.ts +70 -37
- package/dist/types/index.d.ts +1 -1
- package/dist/types/nutui.d.ts +2 -1
- package/package.json +4 -4
- package/dist/types/__VUE/animate/type.d.ts +0 -6
- package/dist/types/__VUE/button/type.d.ts +0 -7
- package/dist/types/__VUE/cascader/types.d.ts +0 -30
- package/dist/types/__VUE/datepicker/type.d.ts +0 -6
- package/dist/types/__VUE/form/types.d.ts +0 -13
- package/dist/types/__VUE/formitem/types.d.ts +0 -10
- package/dist/types/__VUE/image/type.d.ts +0 -6
- package/dist/types/__VUE/imagepreview/types.d.ts +0 -7
- package/dist/types/__VUE/input/type.d.ts +0 -13
- package/dist/types/__VUE/menuitem/type.d.ts +0 -8
- package/dist/types/__VUE/oldpicker/commonProps.d.ts +0 -22
- package/dist/types/__VUE/oldpicker/types.d.ts +0 -24
- package/dist/types/__VUE/picker/types.d.ts +0 -26
- package/dist/types/__VUE/popover/type.d.ts +0 -6
- package/dist/types/__VUE/range/type.d.ts +0 -5
- package/dist/types/__VUE/table/types.d.ts +0 -21
- package/dist/types/__VUE/tag/type.d.ts +0 -5
|
@@ -1,24 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
1
|
/*!
|
|
21
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
22
3
|
* (c) 2022 @jdf2e.
|
|
23
4
|
* Released under the MIT License.
|
|
24
5
|
*/
|
|
@@ -32,7 +13,8 @@ import "./Icon.js";
|
|
|
32
13
|
import "./pxCheck.js";
|
|
33
14
|
const { componentName, create } = createComponent("actionsheet");
|
|
34
15
|
const _sfc_main = create({
|
|
35
|
-
props:
|
|
16
|
+
props: {
|
|
17
|
+
...popupProps,
|
|
36
18
|
cancelTxt: {
|
|
37
19
|
type: String,
|
|
38
20
|
default: ""
|
|
@@ -73,7 +55,7 @@ const _sfc_main = create({
|
|
|
73
55
|
type: Boolean,
|
|
74
56
|
default: true
|
|
75
57
|
}
|
|
76
|
-
}
|
|
58
|
+
},
|
|
77
59
|
emits: ["cancel", "close", "choose", "update:visible"],
|
|
78
60
|
setup(props, { emit }) {
|
|
79
61
|
const slotDefault = !!useSlots().default;
|
|
@@ -1,24 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
1
|
/*!
|
|
21
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
22
3
|
* (c) 2022 @jdf2e.
|
|
23
4
|
* Released under the MIT License.
|
|
24
5
|
*/
|
|
@@ -33,7 +14,8 @@ import "./pxCheck.js";
|
|
|
33
14
|
const { componentName, create, translate } = createComponent("address");
|
|
34
15
|
const _sfc_main = create({
|
|
35
16
|
inheritAttrs: false,
|
|
36
|
-
props:
|
|
17
|
+
props: {
|
|
18
|
+
...popupProps,
|
|
37
19
|
modelValue: {
|
|
38
20
|
type: Array,
|
|
39
21
|
default: () => []
|
|
@@ -102,7 +84,7 @@ const _sfc_main = create({
|
|
|
102
84
|
type: [String, Array],
|
|
103
85
|
default: ""
|
|
104
86
|
}
|
|
105
|
-
}
|
|
87
|
+
},
|
|
106
88
|
emits: ["update:visible", "update:modelValue", "type", "change", "selected", "close", "close-mask", "switch-module"],
|
|
107
89
|
setup(props, { emit }) {
|
|
108
90
|
const regionLine = ref(null);
|
|
@@ -278,10 +260,13 @@ const _sfc_main = create({
|
|
|
278
260
|
lineAnimation();
|
|
279
261
|
};
|
|
280
262
|
const close = () => {
|
|
281
|
-
const resCopy = Object.assign(
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
263
|
+
const resCopy = Object.assign(
|
|
264
|
+
{
|
|
265
|
+
addressIdStr: "",
|
|
266
|
+
addressStr: ""
|
|
267
|
+
},
|
|
268
|
+
selectedRegion
|
|
269
|
+
);
|
|
285
270
|
const res = {
|
|
286
271
|
data: {},
|
|
287
272
|
type: privateType.value
|
|
@@ -324,36 +309,57 @@ const _sfc_main = create({
|
|
|
324
309
|
const handleElevatorItem = (key, item) => {
|
|
325
310
|
nextAreaList(item);
|
|
326
311
|
};
|
|
327
|
-
watch(
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
if (value == false) {
|
|
332
|
-
close();
|
|
333
|
-
} else {
|
|
334
|
-
initCustomSelected();
|
|
312
|
+
watch(
|
|
313
|
+
() => props.visible,
|
|
314
|
+
(value) => {
|
|
315
|
+
showPopup.value = value;
|
|
335
316
|
}
|
|
336
|
-
|
|
337
|
-
watch(
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
regionList.country = isCustom2.value ? transformData(value) : value;
|
|
345
|
-
});
|
|
346
|
-
watch(() => props.town, (value) => {
|
|
347
|
-
regionList.town = isCustom2.value ? transformData(value) : value;
|
|
348
|
-
});
|
|
349
|
-
watch(() => props.existAddress, (value) => {
|
|
350
|
-
value.forEach((item, index2) => {
|
|
351
|
-
if (item.selectedAddress) {
|
|
352
|
-
selectedExistAddress = item;
|
|
317
|
+
);
|
|
318
|
+
watch(
|
|
319
|
+
() => showPopup.value,
|
|
320
|
+
(value) => {
|
|
321
|
+
if (value == false) {
|
|
322
|
+
close();
|
|
323
|
+
} else {
|
|
324
|
+
initCustomSelected();
|
|
353
325
|
}
|
|
354
|
-
}
|
|
355
|
-
|
|
356
|
-
|
|
326
|
+
}
|
|
327
|
+
);
|
|
328
|
+
watch(
|
|
329
|
+
() => props.province,
|
|
330
|
+
(value) => {
|
|
331
|
+
regionList.province = isCustom2.value ? transformData(value) : value;
|
|
332
|
+
}
|
|
333
|
+
);
|
|
334
|
+
watch(
|
|
335
|
+
() => props.city,
|
|
336
|
+
(value) => {
|
|
337
|
+
regionList.city = isCustom2.value ? transformData(value) : value;
|
|
338
|
+
}
|
|
339
|
+
);
|
|
340
|
+
watch(
|
|
341
|
+
() => props.country,
|
|
342
|
+
(value) => {
|
|
343
|
+
regionList.country = isCustom2.value ? transformData(value) : value;
|
|
344
|
+
}
|
|
345
|
+
);
|
|
346
|
+
watch(
|
|
347
|
+
() => props.town,
|
|
348
|
+
(value) => {
|
|
349
|
+
regionList.town = isCustom2.value ? transformData(value) : value;
|
|
350
|
+
}
|
|
351
|
+
);
|
|
352
|
+
watch(
|
|
353
|
+
() => props.existAddress,
|
|
354
|
+
(value) => {
|
|
355
|
+
value.forEach((item, index2) => {
|
|
356
|
+
if (item.selectedAddress) {
|
|
357
|
+
selectedExistAddress = item;
|
|
358
|
+
}
|
|
359
|
+
});
|
|
360
|
+
}
|
|
361
|
+
);
|
|
362
|
+
return {
|
|
357
363
|
showPopup,
|
|
358
364
|
privateType,
|
|
359
365
|
tabIndex,
|
|
@@ -374,10 +380,10 @@ const _sfc_main = create({
|
|
|
374
380
|
clickOverlay,
|
|
375
381
|
handClose,
|
|
376
382
|
handleElevatorItem,
|
|
377
|
-
initCustomSelected
|
|
378
|
-
|
|
383
|
+
initCustomSelected,
|
|
384
|
+
...toRefs(props),
|
|
379
385
|
translate
|
|
380
|
-
}
|
|
386
|
+
};
|
|
381
387
|
}
|
|
382
388
|
});
|
|
383
389
|
const _hoisted_1 = { class: "nut-address" };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2022 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -7,7 +7,7 @@ import { resolveComponent, openBlock, createElementBlock, createElementVNode, re
|
|
|
7
7
|
import { c as createComponent, f as floatData } from "./component.js";
|
|
8
8
|
import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
|
|
9
9
|
import "../locale/lang";
|
|
10
|
-
var ItemContents_vue_vue_type_style_index_0_lang =
|
|
10
|
+
var ItemContents_vue_vue_type_style_index_0_lang = "";
|
|
11
11
|
const { componentName: componentName$4, create: create$4 } = createComponent("item-contents");
|
|
12
12
|
const { translate: translate$1 } = createComponent("addresslist");
|
|
13
13
|
const _sfc_main$4 = create$4({
|
|
@@ -45,7 +45,7 @@ const _sfc_main$4 = create$4({
|
|
|
45
45
|
}
|
|
46
46
|
});
|
|
47
47
|
const _hoisted_1$4 = { class: "nut-item-contents__info" };
|
|
48
|
-
const _hoisted_2$
|
|
48
|
+
const _hoisted_2$1 = { class: "nut-item-contents__info-contact" };
|
|
49
49
|
const _hoisted_3$1 = { class: "nut-item-contents__info-contact-name" };
|
|
50
50
|
const _hoisted_4$1 = { class: "nut-item-contents__info-contact-tel" };
|
|
51
51
|
const _hoisted_5$1 = {
|
|
@@ -61,7 +61,7 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
61
61
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.contentsClick && _ctx.contentsClick(...args))
|
|
62
62
|
}, [
|
|
63
63
|
createElementVNode("div", _hoisted_1$4, [
|
|
64
|
-
createElementVNode("div", _hoisted_2$
|
|
64
|
+
createElementVNode("div", _hoisted_2$1, [
|
|
65
65
|
renderSlot(_ctx.$slots, "contentTop", {}, () => [
|
|
66
66
|
createElementVNode("div", _hoisted_3$1, toDisplayString(_ctx.item.addressName), 1),
|
|
67
67
|
createElementVNode("div", _hoisted_4$1, toDisplayString(_ctx.item.phone), 1),
|
|
@@ -188,13 +188,13 @@ const _sfc_main$3 = create$3({
|
|
|
188
188
|
}
|
|
189
189
|
});
|
|
190
190
|
const _hoisted_1$3 = { class: "nut-long-press-shell" };
|
|
191
|
-
const _hoisted_2
|
|
191
|
+
const _hoisted_2 = /* @__PURE__ */ createElementVNode("div", { class: "mask-contain" }, [
|
|
192
192
|
/* @__PURE__ */ createTextVNode(" \u590D\u5236"),
|
|
193
193
|
/* @__PURE__ */ createElementVNode("br"),
|
|
194
194
|
/* @__PURE__ */ createTextVNode("\u5730\u5740 ")
|
|
195
195
|
], -1);
|
|
196
196
|
const _hoisted_3 = [
|
|
197
|
-
_hoisted_2
|
|
197
|
+
_hoisted_2
|
|
198
198
|
];
|
|
199
199
|
const _hoisted_4 = /* @__PURE__ */ createElementVNode("div", { class: "mask-contain" }, [
|
|
200
200
|
/* @__PURE__ */ createTextVNode(" \u8BBE\u7F6E"),
|
|
@@ -316,7 +316,6 @@ const _sfc_main$2 = create$2({
|
|
|
316
316
|
}
|
|
317
317
|
});
|
|
318
318
|
const _hoisted_1$2 = { class: "nut-swipe-shell" };
|
|
319
|
-
const _hoisted_2 = /* @__PURE__ */ createTextVNode("\u5220\u9664");
|
|
320
319
|
function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
321
320
|
const _component_item_contents = resolveComponent("item-contents");
|
|
322
321
|
const _component_nut_button = resolveComponent("nut-button");
|
|
@@ -331,7 +330,7 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
331
330
|
onClick: _ctx.swipeDelClick
|
|
332
331
|
}, {
|
|
333
332
|
default: withCtx(() => [
|
|
334
|
-
|
|
333
|
+
createTextVNode("\u5220\u9664")
|
|
335
334
|
]),
|
|
336
335
|
_: 1
|
|
337
336
|
}, 8, ["onClick"])
|
|
@@ -480,7 +479,11 @@ const _sfc_main = create({
|
|
|
480
479
|
});
|
|
481
480
|
}
|
|
482
481
|
};
|
|
483
|
-
watch(
|
|
482
|
+
watch(
|
|
483
|
+
() => props.data,
|
|
484
|
+
() => trowelData(),
|
|
485
|
+
{ deep: true }
|
|
486
|
+
);
|
|
484
487
|
const clickDelIcon = (event, item) => {
|
|
485
488
|
emit("handelDelIcon", event, item);
|
|
486
489
|
event.stopPropagation();
|
|
@@ -1,24 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
1
|
/*!
|
|
21
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
22
3
|
* (c) 2022 @jdf2e.
|
|
23
4
|
* Released under the MIT License.
|
|
24
5
|
*/
|
|
@@ -65,7 +46,7 @@ const _sfc_main = create({
|
|
|
65
46
|
}
|
|
66
47
|
emit("click", event);
|
|
67
48
|
};
|
|
68
|
-
return
|
|
49
|
+
return { ...toRefs(state), classes, handleClick };
|
|
69
50
|
}
|
|
70
51
|
});
|
|
71
52
|
const _hoisted_1 = { class: "nut-animate" };
|
|
@@ -1,24 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
1
|
/*!
|
|
21
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
22
3
|
* (c) 2022 @jdf2e.
|
|
23
4
|
* Released under the MIT License.
|
|
24
5
|
*/
|
|
@@ -161,9 +142,12 @@ const _sfc_main = create({
|
|
|
161
142
|
result += ("0" + seconds.toString()).slice(-2);
|
|
162
143
|
return result;
|
|
163
144
|
};
|
|
164
|
-
watch(
|
|
165
|
-
|
|
166
|
-
|
|
145
|
+
watch(
|
|
146
|
+
() => audioData.currentTime,
|
|
147
|
+
(value) => {
|
|
148
|
+
handle(value);
|
|
149
|
+
}
|
|
150
|
+
);
|
|
167
151
|
provide("audioParent", {
|
|
168
152
|
children: [],
|
|
169
153
|
props,
|
|
@@ -173,7 +157,9 @@ const _sfc_main = create({
|
|
|
173
157
|
fastBack,
|
|
174
158
|
changeStatus
|
|
175
159
|
});
|
|
176
|
-
return
|
|
160
|
+
return {
|
|
161
|
+
...toRefs(props),
|
|
162
|
+
...toRefs(audioData),
|
|
177
163
|
audioRef,
|
|
178
164
|
fastBack,
|
|
179
165
|
forward,
|
|
@@ -183,7 +169,7 @@ const _sfc_main = create({
|
|
|
183
169
|
onTimeupdate,
|
|
184
170
|
handleMute,
|
|
185
171
|
onCanplay
|
|
186
|
-
}
|
|
172
|
+
};
|
|
187
173
|
}
|
|
188
174
|
});
|
|
189
175
|
const _hoisted_1 = { class: "nut-audio" };
|
|
@@ -1,24 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
1
|
/*!
|
|
21
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
22
3
|
* (c) 2022 @jdf2e.
|
|
23
4
|
* Released under the MIT License.
|
|
24
5
|
*/
|
|
@@ -40,11 +21,10 @@ const _sfc_main = create({
|
|
|
40
21
|
const audio = inject("audioParent");
|
|
41
22
|
const parent = reactive(audio);
|
|
42
23
|
const customSlot = ref(useSlots().default);
|
|
43
|
-
return
|
|
24
|
+
return { ...toRefs(props), ...toRefs(parent), customSlot, translate };
|
|
44
25
|
}
|
|
45
26
|
});
|
|
46
27
|
const _hoisted_1 = { class: "nut-audio-operate" };
|
|
47
|
-
const _hoisted_2 = /* @__PURE__ */ createTextVNode("\u5FEB\u8FDB");
|
|
48
28
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
49
29
|
const _component_nut_button = resolveComponent("nut-button");
|
|
50
30
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
@@ -93,7 +73,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
93
73
|
size: "small"
|
|
94
74
|
}, {
|
|
95
75
|
default: withCtx(() => [
|
|
96
|
-
|
|
76
|
+
createTextVNode("\u5FEB\u8FDB")
|
|
97
77
|
]),
|
|
98
78
|
_: 1
|
|
99
79
|
})) : createCommentVNode("", true),
|
|
@@ -1,21 +1,5 @@
|
|
|
1
|
-
var __defProp = Object.defineProperty;
|
|
2
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
6
|
-
var __spreadValues = (a, b) => {
|
|
7
|
-
for (var prop in b || (b = {}))
|
|
8
|
-
if (__hasOwnProp.call(b, prop))
|
|
9
|
-
__defNormalProp(a, prop, b[prop]);
|
|
10
|
-
if (__getOwnPropSymbols)
|
|
11
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
12
|
-
if (__propIsEnum.call(b, prop))
|
|
13
|
-
__defNormalProp(a, prop, b[prop]);
|
|
14
|
-
}
|
|
15
|
-
return a;
|
|
16
|
-
};
|
|
17
1
|
/*!
|
|
18
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
19
3
|
* (c) 2022 @jdf2e.
|
|
20
4
|
* Released under the MIT License.
|
|
21
5
|
*/
|
|
@@ -128,7 +112,7 @@ const _sfc_main = create({
|
|
|
128
112
|
const onError = (event) => {
|
|
129
113
|
emit("onError", event);
|
|
130
114
|
};
|
|
131
|
-
return
|
|
115
|
+
return {
|
|
132
116
|
classes,
|
|
133
117
|
styles,
|
|
134
118
|
iconStyles,
|
|
@@ -138,8 +122,9 @@ const _sfc_main = create({
|
|
|
138
122
|
onError,
|
|
139
123
|
avatarGroup,
|
|
140
124
|
visible,
|
|
141
|
-
avatarRef
|
|
142
|
-
|
|
125
|
+
avatarRef,
|
|
126
|
+
...toRefs(state)
|
|
127
|
+
};
|
|
143
128
|
}
|
|
144
129
|
});
|
|
145
130
|
const _hoisted_1 = ["src", "alt"];
|
|
@@ -158,7 +143,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
158
143
|
key: 0,
|
|
159
144
|
style: normalizeStyle(!_ctx.showMax ? _ctx.styles : _ctx.maxStyles),
|
|
160
145
|
class: normalizeClass(_ctx.classes),
|
|
161
|
-
onClick: _cache[1] || (_cache[1] = (
|
|
146
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.activeAvatar && _ctx.activeAvatar(...args)),
|
|
162
147
|
ref: "avatarRef"
|
|
163
148
|
}, [
|
|
164
149
|
!((_f = (_e = _ctx.avatarGroup) == null ? void 0 : _e.props) == null ? void 0 : _f.maxCount) || _ctx.index <= ((_h = (_g = _ctx.avatarGroup) == null ? void 0 : _g.props) == null ? void 0 : _h.maxCount) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.3 Fri Sep 30 2022 10:26:47 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2022 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
|
-
import { computed, ref, onMounted, onUnmounted, onDeactivated, watch, nextTick, openBlock, createElementBlock, normalizeClass,
|
|
6
|
+
import { useSlots, computed, ref, onMounted, onUnmounted, onDeactivated, watch, nextTick, useCssVars, openBlock, createElementBlock, normalizeClass, renderSlot } from "vue";
|
|
7
7
|
import { c as createComponent } from "./component.js";
|
|
8
8
|
import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
|
|
9
9
|
import "../locale/lang";
|
|
10
|
+
var index_vue_vue_type_style_index_0_lang = "";
|
|
10
11
|
const { componentName, create } = createComponent("barrage");
|
|
11
|
-
const
|
|
12
|
+
const __default__ = create({
|
|
12
13
|
props: {
|
|
13
14
|
danmu: {
|
|
14
15
|
type: Array,
|
|
@@ -20,7 +21,7 @@ const _sfc_main = create({
|
|
|
20
21
|
},
|
|
21
22
|
speeds: {
|
|
22
23
|
type: Number,
|
|
23
|
-
default:
|
|
24
|
+
default: 5e3
|
|
24
25
|
},
|
|
25
26
|
rows: {
|
|
26
27
|
type: Number,
|
|
@@ -36,7 +37,8 @@ const _sfc_main = create({
|
|
|
36
37
|
}
|
|
37
38
|
},
|
|
38
39
|
emits: ["click"],
|
|
39
|
-
setup(props, {
|
|
40
|
+
setup(props, { slots }) {
|
|
41
|
+
const slotDefault = !!useSlots().default;
|
|
40
42
|
const classes = computed(() => {
|
|
41
43
|
const prefixCls = componentName;
|
|
42
44
|
return {
|
|
@@ -53,8 +55,14 @@ const _sfc_main = create({
|
|
|
53
55
|
const speeds = props.speeds;
|
|
54
56
|
const danmuCWidth = ref(0);
|
|
55
57
|
onMounted(() => {
|
|
58
|
+
var _a;
|
|
56
59
|
danmuCWidth.value = dmBody.value.offsetWidth;
|
|
57
|
-
|
|
60
|
+
if (slotDefault) {
|
|
61
|
+
danmuList.value = (_a = slots == null ? void 0 : slots.default) == null ? void 0 : _a.call(slots);
|
|
62
|
+
run();
|
|
63
|
+
} else {
|
|
64
|
+
run();
|
|
65
|
+
}
|
|
58
66
|
});
|
|
59
67
|
onUnmounted(() => {
|
|
60
68
|
clearInterval(timer);
|
|
@@ -64,9 +72,14 @@ const _sfc_main = create({
|
|
|
64
72
|
clearInterval(timer);
|
|
65
73
|
timer = 0;
|
|
66
74
|
});
|
|
67
|
-
watch(
|
|
68
|
-
|
|
69
|
-
|
|
75
|
+
watch(
|
|
76
|
+
() => props.danmu,
|
|
77
|
+
(newValue) => {
|
|
78
|
+
if (props.danmu.length > 0) {
|
|
79
|
+
danmuList.value = [...newValue];
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
);
|
|
70
83
|
const add = (word) => {
|
|
71
84
|
const _index = index2.value % danmuList.value.length;
|
|
72
85
|
if (!props.loop && index2.value === danmuList.value.length) {
|
|
@@ -83,43 +96,82 @@ const _sfc_main = create({
|
|
|
83
96
|
run();
|
|
84
97
|
}, props.frequency);
|
|
85
98
|
};
|
|
99
|
+
const distance = ref("0");
|
|
86
100
|
const play = () => {
|
|
101
|
+
var _a, _b;
|
|
87
102
|
if (!props.loop && index2.value >= danmuList.value.length) {
|
|
88
103
|
return;
|
|
89
104
|
}
|
|
90
105
|
const _index = props.loop ? index2.value % danmuList.value.length : index2.value;
|
|
91
|
-
let el = document.createElement(`
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
106
|
+
let el = document.createElement(`div`);
|
|
107
|
+
if (slotDefault && ((_a = danmuList.value[_index]) == null ? void 0 : _a.el)) {
|
|
108
|
+
el = (_b = danmuList.value[_index]) == null ? void 0 : _b.el;
|
|
109
|
+
if (el == null ? void 0 : el.classList.contains("dmitem")) {
|
|
110
|
+
el.classList.remove("dmitem");
|
|
111
|
+
}
|
|
112
|
+
if (el == null ? void 0 : el.classList.contains("move")) {
|
|
113
|
+
el.classList.remove("move");
|
|
114
|
+
}
|
|
115
|
+
el == null ? void 0 : el.classList.add("dmitem");
|
|
116
|
+
} else {
|
|
117
|
+
el.innerHTML = danmuList.value[_index];
|
|
118
|
+
el.classList.add("dmitem");
|
|
119
|
+
dmContainer.value.appendChild(el);
|
|
120
|
+
}
|
|
95
121
|
nextTick(() => {
|
|
96
|
-
const width = el.offsetWidth;
|
|
97
122
|
const height = el.offsetHeight;
|
|
98
123
|
el.classList.add("move");
|
|
99
124
|
el.style.animationDuration = `${speeds}ms`;
|
|
100
125
|
el.style.top = _index % rows.value * (height + top.value) + 20 + "px";
|
|
101
|
-
|
|
126
|
+
if (!slotDefault) {
|
|
127
|
+
const width = el.offsetWidth;
|
|
128
|
+
el.style.width = width + 20 + "px";
|
|
129
|
+
}
|
|
102
130
|
el.style.setProperty("--move-distance", `-${danmuCWidth.value}px`);
|
|
131
|
+
distance.value = "-" + speeds / 1e3 * 150 + "%";
|
|
103
132
|
el.dataset.index = `${_index}`;
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}
|
|
107
|
-
|
|
133
|
+
if (slotDefault) {
|
|
134
|
+
index2.value++;
|
|
135
|
+
} else {
|
|
136
|
+
el.addEventListener("animationend", () => {
|
|
137
|
+
dmContainer.value.removeChild(el);
|
|
138
|
+
});
|
|
139
|
+
index2.value++;
|
|
140
|
+
}
|
|
108
141
|
});
|
|
109
142
|
};
|
|
110
|
-
return { classes, danmuList, dmBody, dmContainer, add };
|
|
143
|
+
return { classes, danmuList, dmBody, dmContainer, add, distance };
|
|
111
144
|
}
|
|
112
145
|
});
|
|
146
|
+
const __injectCSSVars__ = () => {
|
|
147
|
+
useCssVars((_ctx) => ({
|
|
148
|
+
"21cca3b5": _ctx.distance
|
|
149
|
+
}));
|
|
150
|
+
};
|
|
151
|
+
const __setup__ = __default__.setup;
|
|
152
|
+
__default__.setup = __setup__ ? (props, ctx) => {
|
|
153
|
+
__injectCSSVars__();
|
|
154
|
+
return __setup__(props, ctx);
|
|
155
|
+
} : __injectCSSVars__;
|
|
156
|
+
const _sfc_main = __default__;
|
|
113
157
|
const _hoisted_1 = {
|
|
158
|
+
key: 0,
|
|
159
|
+
ref: "dmContainer",
|
|
160
|
+
class: "dmContainer slotContainer"
|
|
161
|
+
};
|
|
162
|
+
const _hoisted_2 = {
|
|
163
|
+
key: 1,
|
|
114
164
|
ref: "dmContainer",
|
|
115
165
|
class: "dmContainer"
|
|
116
166
|
};
|
|
117
167
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
118
|
-
return openBlock(), createElementBlock("
|
|
168
|
+
return openBlock(), createElementBlock("div", {
|
|
119
169
|
ref: "dmBody",
|
|
120
170
|
class: normalizeClass(_ctx.classes)
|
|
121
171
|
}, [
|
|
122
|
-
|
|
172
|
+
_ctx.$slots.default ? (openBlock(), createElementBlock("div", _hoisted_1, [
|
|
173
|
+
renderSlot(_ctx.$slots, "default")
|
|
174
|
+
], 512)) : (openBlock(), createElementBlock("div", _hoisted_2, null, 512))
|
|
123
175
|
], 2);
|
|
124
176
|
}
|
|
125
177
|
var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|