@nutui/nutui 3.1.21-beta.3 → 3.1.22-beta.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 +57 -0
- package/dist/nutui.es.js +4024 -18197
- package/dist/nutui.umd.js +4017 -18290
- package/dist/packages/_es/ActionSheet.js +26 -157
- package/dist/packages/_es/Address.js +119 -542
- package/dist/packages/_es/AddressList.js +113 -611
- package/dist/packages/_es/Audio.js +62 -274
- package/dist/packages/_es/AudioOperate.js +18 -107
- package/dist/packages/_es/Avatar.js +42 -165
- package/dist/packages/_es/AvatarGroup.js +14 -73
- package/dist/packages/_es/BackTop.js +43 -156
- package/dist/packages/_es/Badge.js +14 -86
- package/dist/packages/_es/Barrage.js +41 -113
- package/dist/packages/_es/Button.js +23 -128
- package/dist/packages/_es/Calendar.js +24 -237
- package/dist/packages/_es/CalendarItem.js +1 -1
- package/dist/packages/_es/Card.js +10 -107
- package/dist/packages/_es/Cascader.js +156 -500
- package/dist/packages/_es/Category.js +15 -58
- package/dist/packages/_es/CategoryPane.js +11 -111
- package/dist/packages/_es/Cell.js +21 -98
- package/dist/packages/_es/CellGroup.js +9 -44
- package/dist/packages/_es/Checkbox.js +31 -113
- package/dist/packages/_es/CheckboxGroup.js +29 -58
- package/dist/packages/_es/CircleProgress.js +28 -151
- package/dist/packages/_es/Col.js +14 -56
- package/dist/packages/_es/Collapse.js +24 -85
- package/dist/packages/_es/CollapseItem.js +70 -261
- package/dist/packages/_es/Comment.js +64 -434
- package/dist/packages/_es/CountDown.js +61 -242
- package/dist/packages/_es/CountUp.js +149 -548
- package/dist/packages/_es/DatePicker.js +107 -322
- package/dist/packages/_es/Dialog.js +69 -259
- package/dist/packages/_es/Divider.js +32 -45
- package/dist/packages/_es/Drag.js +56 -197
- package/dist/packages/_es/Ecard.js +24 -159
- package/dist/packages/_es/Elevator.js +63 -194
- package/dist/packages/_es/Empty.js +12 -71
- package/dist/packages/_es/FixedNav.js +15 -122
- package/dist/packages/_es/Form.js +64 -146
- package/dist/packages/_es/FormItem.js +15 -110
- package/dist/packages/_es/Grid.js +5 -6
- package/dist/packages/_es/GridItem.js +33 -144
- package/dist/packages/_es/Icon.js +15 -40
- package/dist/packages/_es/ImagePreview.js +74 -298
- package/dist/packages/_es/Indicator.js +15 -62
- package/dist/packages/_es/InfiniteLoading.js +66 -258
- package/dist/packages/_es/Input.js +51 -413
- package/dist/packages/_es/InputNumber.js +41 -160
- package/dist/packages/_es/Layout.js +4 -5
- package/dist/packages/_es/List.js +23 -109
- package/dist/packages/_es/Menu.js +30 -114
- package/dist/packages/_es/MenuItem.js +34 -161
- package/dist/packages/_es/Navbar.js +30 -94
- package/dist/packages/_es/NoticeBar.js +83 -387
- package/dist/packages/_es/Notify.js +81 -236
- package/dist/packages/_es/NumberKeyboard.js +41 -262
- package/dist/packages/_es/OldPicker.js +140 -464
- package/dist/packages/_es/OverLay.js +32 -105
- package/dist/packages/_es/Pagination.js +39 -157
- package/dist/packages/_es/Picker.js +138 -457
- package/dist/packages/_es/Popover.js +344 -185
- package/dist/packages/_es/Popup.js +64 -300
- package/dist/packages/_es/Price.js +16 -118
- package/dist/packages/_es/Progress.js +14 -146
- package/dist/packages/_es/PullRefresh.js +92 -346
- package/dist/packages/_es/Radio.js +22 -90
- package/dist/packages/_es/RadioGroup.js +8 -37
- package/dist/packages/_es/Range.js +92 -417
- package/dist/packages/_es/Rate.js +16 -139
- package/dist/packages/_es/Row.js +22 -64
- package/dist/packages/_es/SearchBar.js +46 -181
- package/dist/packages/_es/ShortPassword.js +35 -225
- package/dist/packages/_es/SideNavBar.js +33 -89
- package/dist/packages/_es/SideNavBarItem.js +11 -46
- package/dist/packages/_es/Signature.js +46 -165
- package/dist/packages/_es/Skeleton.js +20 -136
- package/dist/packages/_es/Sku.js +93 -499
- package/dist/packages/_es/Step.js +25 -119
- package/dist/packages/_es/Steps.js +18 -53
- package/dist/packages/_es/Sticky.js +53 -138
- package/dist/packages/_es/SubSideNavBar.js +26 -90
- package/dist/packages/_es/Swipe.js +46 -183
- package/dist/packages/_es/Swiper.js +121 -414
- package/dist/packages/_es/SwiperItem.js +22 -50
- package/dist/packages/_es/Switch.js +21 -116
- package/dist/packages/_es/TabPane.js +12 -35
- package/dist/packages/_es/Tabbar.js +17 -72
- package/dist/packages/_es/TabbarItem.js +29 -150
- package/dist/packages/_es/Table.js +27 -186
- package/dist/packages/_es/Tabs.js +51 -204
- package/dist/packages/_es/Tag.js +20 -97
- package/dist/packages/_es/TextArea.js +42 -160
- package/dist/packages/_es/TimeDetail.js +23 -84
- package/dist/packages/_es/TimePannel.js +19 -52
- package/dist/packages/_es/TimeSelect.js +15 -103
- package/dist/packages/_es/Toast.js +80 -319
- package/dist/packages/_es/Uploader.js +112 -459
- package/dist/packages/_es/Video.js +83 -340
- package/dist/packages/_es/common.js +38 -128
- package/dist/packages/_es/component.js +35 -76
- package/dist/packages/_es/index.js +5 -6
- package/dist/packages/_es/index2.js +9 -30
- package/dist/packages/_es/index3.js +6 -8
- package/dist/packages/_es/index4.js +13 -58
- package/dist/packages/_es/index5.js +120 -675
- package/dist/packages/_es/plugin-vue_export-helper.js +7 -8
- package/dist/packages/_es/pxCheck.js +3 -5
- package/dist/packages/_es/raf.js +8 -15
- package/dist/packages/addresslist/index.scss +2 -2
- package/dist/packages/button/index.scss +2 -1
- package/dist/packages/card/index.scss +1 -1
- package/dist/packages/cell/index.scss +15 -0
- package/dist/packages/checkbox/index.scss +6 -0
- package/dist/packages/dialog/index.scss +1 -2
- package/dist/packages/divider/index.scss +9 -0
- package/dist/packages/elevator/index.scss +21 -0
- package/dist/packages/formitem/index.scss +1 -0
- package/dist/packages/input/index.scss +13 -1
- package/dist/packages/locale/index.d.ts +8 -3
- package/dist/packages/locale/{locale/lang → lang}/baseLang.d.ts +1 -0
- package/dist/packages/locale/lang/baseLang.js +3 -3
- package/dist/packages/locale/{locale/lang → lang}/en-US.d.ts +16 -0
- package/dist/packages/locale/lang/en-US.js +5 -89
- package/dist/packages/locale/lang/id-ID.d.ts +104 -0
- package/dist/packages/locale/lang/id-ID.js +12 -0
- package/dist/packages/locale/lang/index.js +16 -38
- package/dist/packages/locale/{locale/lang → lang}/zh-CN.d.ts +16 -0
- package/dist/packages/locale/lang/zh-CN.js +5 -89
- package/dist/packages/locale/{locale/lang → lang}/zh-TW.d.ts +16 -0
- package/dist/packages/locale/lang/zh-TW.js +5 -89
- package/dist/packages/menuitem/index.scss +0 -1
- package/dist/packages/navbar/index.scss +8 -1
- package/dist/packages/popover/index.scss +402 -81
- package/dist/packages/popup/index.scss +3 -0
- package/dist/packages/radio/index.scss +1 -0
- package/dist/packages/searchbar/index.scss +4 -0
- package/dist/packages/switch/index.scss +3 -3
- package/dist/packages/tabbar/index.scss +2 -2
- package/dist/packages/tabpane/index.scss +5 -2
- package/dist/packages/tabs/index.scss +3 -0
- package/dist/packages/timeselect/index.scss +3 -2
- package/dist/smartips/attributes.json +188 -44
- package/dist/smartips/tags.json +65 -27
- package/dist/style.css +1 -1
- package/dist/styles/themes/default.scss +48 -48
- package/dist/styles/themes/jdb.scss +48 -48
- package/dist/styles/themes/jdt.scss +48 -48
- package/dist/styles/variables-jdb.scss +25 -8
- package/dist/styles/variables-jdt.scss +25 -8
- package/dist/styles/variables.scss +25 -7
- package/dist/types/__VUE/actionsheet/{index.d.ts → index.vue.d.ts} +62 -114
- package/dist/types/__VUE/address/{index.d.ts → index.vue.d.ts} +81 -151
- package/dist/types/__VUE/addresslist/components/{GeneralShell.d.ts → GeneralShell.vue.d.ts} +6 -7
- package/dist/types/__VUE/addresslist/components/{ItemContents.d.ts → ItemContents.vue.d.ts} +9 -11
- package/dist/types/__VUE/addresslist/components/{LongPressShell.d.ts → LongPressShell.vue.d.ts} +6 -7
- package/dist/types/__VUE/addresslist/components/{SwipeShell.d.ts → SwipeShell.vue.d.ts} +6 -7
- package/dist/types/__VUE/addresslist/{index.d.ts → index.vue.d.ts} +14 -23
- package/dist/types/__VUE/audio/index.vue.d.ts +102 -0
- package/dist/types/__VUE/audiooperate/index.vue.d.ts +88 -0
- package/dist/types/__VUE/avatar/{index.d.ts → index.vue.d.ts} +17 -30
- package/dist/types/__VUE/avatargroup/{index.d.ts → index.vue.d.ts} +20 -35
- package/dist/types/__VUE/backtop/{index.d.ts → index.vue.d.ts} +18 -34
- package/dist/types/__VUE/badge/{index.d.ts → index.vue.d.ts} +20 -33
- package/dist/types/__VUE/barrage/{index.d.ts → index.vue.d.ts} +15 -26
- package/dist/types/__VUE/button/{index.d.ts → index.vue.d.ts} +33 -50
- package/dist/types/__VUE/button/type.d.ts +7 -0
- package/dist/types/__VUE/calendar/{index.d.ts → index.vue.d.ts} +32 -57
- package/dist/types/__VUE/calendaritem/{index.d.ts → index.vue.d.ts} +33 -58
- package/dist/types/__VUE/card/{index.d.ts → index.vue.d.ts} +19 -34
- package/dist/types/__VUE/cascader/{cascader-item.d.ts → cascader-item.vue.d.ts} +22 -23
- package/dist/types/__VUE/cascader/{index.d.ts → index.vue.d.ts} +62 -98
- package/dist/types/__VUE/category/{index.d.ts → index.vue.d.ts} +7 -10
- package/dist/types/__VUE/categorypane/{index.d.ts → index.vue.d.ts} +10 -15
- package/dist/types/__VUE/cell/{index.d.ts → index.vue.d.ts} +38 -39
- package/dist/types/__VUE/cellgroup/{index.d.ts → index.vue.d.ts} +8 -11
- package/dist/types/__VUE/checkbox/common.d.ts +59 -0
- package/dist/types/__VUE/checkbox/{index.d.ts → index.vue.d.ts} +36 -40
- package/dist/types/__VUE/checkboxgroup/{index.d.ts → index.vue.d.ts} +15 -11
- package/dist/types/__VUE/circleprogress/{index.d.ts → index.vue.d.ts} +18 -31
- package/dist/types/__VUE/col/{index.d.ts → index.vue.d.ts} +7 -10
- package/dist/types/__VUE/collapse/{index.d.ts → index.vue.d.ts} +24 -40
- package/dist/types/__VUE/collapseitem/{index.d.ts → index.vue.d.ts} +22 -30
- package/dist/types/__VUE/comment/components/{CmtBottom.d.ts → CmtBottom.vue.d.ts} +10 -15
- package/dist/types/__VUE/comment/components/{CmtHeader.d.ts → CmtHeader.vue.d.ts} +10 -15
- package/dist/types/__VUE/comment/components/{CmtImages.d.ts → CmtImages.vue.d.ts} +10 -15
- package/dist/types/__VUE/comment/{index.d.ts → index.vue.d.ts} +21 -38
- package/dist/types/__VUE/countdown/{index.d.ts → index.vue.d.ts} +21 -35
- package/dist/types/__VUE/countup/{index.d.ts → index.vue.d.ts} +41 -74
- package/dist/types/__VUE/datepicker/{index.d.ts → index.vue.d.ts} +71 -125
- package/dist/types/__VUE/datepicker/type.d.ts +6 -0
- package/dist/types/__VUE/dialog/index.d.ts +44 -302
- package/dist/types/__VUE/dialog/index.vue.d.ts +263 -0
- package/dist/types/__VUE/divider/{index.d.ts → index.vue.d.ts} +15 -15
- package/dist/types/__VUE/drag/{index.d.ts → index.vue.d.ts} +9 -19
- package/dist/types/__VUE/ecard/{index.d.ts → index.vue.d.ts} +25 -44
- package/dist/types/__VUE/elevator/{index.d.ts → index.vue.d.ts} +39 -14
- package/dist/types/__VUE/empty/{index.d.ts → index.vue.d.ts} +9 -14
- package/dist/types/__VUE/fixednav/{index.d.ts → index.vue.d.ts} +18 -34
- package/dist/types/__VUE/form/{index.d.ts → index.vue.d.ts} +5 -6
- package/dist/types/__VUE/formitem/{index.d.ts → index.vue.d.ts} +29 -55
- package/dist/types/__VUE/grid/common.d.ts +3 -3
- package/dist/types/__VUE/grid/{index.d.ts → index.vue.d.ts} +24 -40
- package/dist/types/__VUE/griditem/{index.d.ts → index.vue.d.ts} +19 -26
- package/dist/types/__VUE/icon/{index.d.ts → index.vue.d.ts} +15 -26
- package/dist/types/__VUE/imagepreview/index.d.ts +20 -121
- package/dist/types/__VUE/imagepreview/index.vue.d.ts +108 -0
- package/dist/types/__VUE/indicator/{index.d.ts → index.vue.d.ts} +13 -24
- package/dist/types/__VUE/infiniteloading/{index.d.ts → index.vue.d.ts} +26 -47
- package/dist/types/__VUE/input/{index.d.ts → index.vue.d.ts} +81 -144
- package/dist/types/__VUE/input/type.d.ts +13 -0
- package/dist/types/__VUE/inputnumber/{index.d.ts → index.vue.d.ts} +22 -39
- package/dist/types/__VUE/layout/{index.d.ts → index.vue.d.ts} +1 -1
- package/dist/types/__VUE/list/{index.d.ts → index.vue.d.ts} +10 -14
- package/dist/types/__VUE/menu/{index.d.ts → index.vue.d.ts} +16 -14
- package/dist/types/__VUE/menuitem/{index.d.ts → index.vue.d.ts} +20 -24
- package/dist/types/__VUE/menuitem/type.d.ts +8 -0
- package/dist/types/__VUE/navbar/{index.d.ts → index.vue.d.ts} +48 -26
- package/dist/types/__VUE/noticebar/{index.d.ts → index.vue.d.ts} +35 -64
- package/dist/types/__VUE/notify/index.d.ts +12 -109
- package/dist/types/__VUE/notify/index.vue.d.ts +101 -0
- package/dist/types/__VUE/numberkeyboard/{index.d.ts → index.vue.d.ts} +41 -43
- package/dist/types/__VUE/oldpicker/{Column.d.ts → Column.vue.d.ts} +17 -22
- package/dist/types/__VUE/oldpicker/{index.d.ts → index.vue.d.ts} +75 -128
- package/dist/types/__VUE/overlay/{index.d.ts → index.vue.d.ts} +19 -30
- package/dist/types/__VUE/pagination/{index.d.ts → index.vue.d.ts} +21 -38
- package/dist/types/__VUE/picker/{Column.d.ts → Column.vue.d.ts} +16 -18
- package/dist/types/__VUE/picker/{index.d.ts → index.vue.d.ts} +79 -129
- package/dist/types/__VUE/popover/{index.d.ts → index.vue.d.ts} +85 -109
- package/dist/types/__VUE/popover/type.d.ts +6 -0
- package/dist/types/__VUE/popup/{index.d.ts → index.vue.d.ts} +45 -80
- package/dist/types/__VUE/price/{index.d.ts → index.vue.d.ts} +17 -30
- package/dist/types/__VUE/progress/{index.d.ts → index.vue.d.ts} +29 -53
- package/dist/types/__VUE/pullrefresh/{index.d.ts → index.vue.d.ts} +18 -46
- package/dist/types/__VUE/radio/{index.d.ts → index.vue.d.ts} +19 -34
- package/dist/types/__VUE/radiogroup/{index.d.ts → index.vue.d.ts} +10 -15
- package/dist/types/__VUE/range/{index.d.ts → index.vue.d.ts} +35 -47
- package/dist/types/__VUE/range/type.d.ts +5 -0
- package/dist/types/__VUE/rate/{index.d.ts → index.vue.d.ts} +30 -55
- package/dist/types/__VUE/row/{index.d.ts → index.vue.d.ts} +16 -25
- package/dist/types/__VUE/searchbar/{index.d.ts → index.vue.d.ts} +62 -32
- package/dist/types/__VUE/shortpassword/{index.d.ts → index.vue.d.ts} +25 -44
- package/dist/types/__VUE/sidenavbar/{index.d.ts → index.vue.d.ts} +6 -7
- package/dist/types/__VUE/sidenavbaritem/{index.d.ts → index.vue.d.ts} +8 -11
- package/dist/types/__VUE/signature/{index.d.ts → index.vue.d.ts} +13 -22
- package/dist/types/__VUE/skeleton/common.d.ts +3 -5
- package/dist/types/__VUE/skeleton/{index.d.ts → index.vue.d.ts} +24 -43
- package/dist/types/__VUE/sku/components/{SkuHeader.d.ts → SkuHeader.vue.d.ts} +6 -7
- package/dist/types/__VUE/sku/components/{SkuOperate.d.ts → SkuOperate.vue.d.ts} +14 -23
- package/dist/types/__VUE/sku/components/{SkuSelect.d.ts → SkuSelect.vue.d.ts} +6 -7
- package/dist/types/__VUE/sku/components/{SkuStepper.d.ts → SkuStepper.vue.d.ts} +12 -19
- package/dist/types/__VUE/sku/{index.d.ts → index.vue.d.ts} +66 -124
- package/dist/types/__VUE/step/{index.d.ts → index.vue.d.ts} +14 -23
- package/dist/types/__VUE/steps/{index.d.ts → index.vue.d.ts} +9 -14
- package/dist/types/__VUE/sticky/{index.d.ts → index.vue.d.ts} +14 -21
- package/dist/types/__VUE/subsidenavbar/{index.d.ts → index.vue.d.ts} +10 -15
- package/dist/types/__VUE/swipe/{index.d.ts → index.vue.d.ts} +11 -18
- package/dist/types/__VUE/swiper/{index.d.ts → index.vue.d.ts} +30 -50
- package/dist/types/__VUE/swiperitem/{index.d.ts → index.vue.d.ts} +2 -2
- package/dist/types/__VUE/switch/{index.d.ts → index.vue.d.ts} +28 -51
- package/dist/types/__VUE/tabbar/{index.d.ts → index.vue.d.ts} +17 -30
- package/dist/types/__VUE/tabbaritem/{index.d.ts → index.vue.d.ts} +25 -40
- package/dist/types/__VUE/table/common.d.ts +1 -1
- package/dist/types/__VUE/table/{index.d.ts → index.vue.d.ts} +14 -23
- package/dist/types/__VUE/tabpane/{index.d.ts → index.vue.d.ts} +11 -15
- package/dist/types/__VUE/tabs/common.d.ts +6 -2
- package/dist/types/__VUE/tabs/{index.d.ts → index.vue.d.ts} +30 -42
- package/dist/types/__VUE/tag/{index.d.ts → index.vue.d.ts} +21 -34
- package/dist/types/__VUE/tag/type.d.ts +5 -0
- package/dist/types/__VUE/textarea/{index.d.ts → index.vue.d.ts} +26 -45
- package/dist/types/__VUE/timedetail/{index.d.ts → index.vue.d.ts} +8 -11
- package/dist/types/__VUE/timepannel/{index.d.ts → index.vue.d.ts} +8 -11
- package/dist/types/__VUE/timeselect/{index.d.ts → index.vue.d.ts} +25 -29
- package/dist/types/__VUE/toast/index.d.ts +12 -145
- package/dist/types/__VUE/toast/index.vue.d.ts +134 -0
- package/dist/types/__VUE/uploader/{index.d.ts → index.vue.d.ts} +59 -106
- package/dist/types/__VUE/uploader/type.d.ts +18 -0
- package/dist/types/__VUE/video/{index.d.ts → index.vue.d.ts} +9 -26
- package/dist/types/index.d.ts +7 -2
- package/dist/types/nutui.d.ts +92 -92
- package/package.json +7 -3
- package/dist/packages/locale/locale/index.d.ts +0 -8
- package/dist/types/__VUE/audio/index.d.ts +0 -92
- package/dist/types/__VUE/audiooperate/index.d.ts +0 -68
|
@@ -1,204 +1,63 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.1.
|
|
2
|
+
* @nutui/nutui v3.1.22-beta.3 Wed Jun 15 2022 20:12:30 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2022 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
|
-
import { ref, reactive, computed, onMounted, onActivated, onDeactivated, openBlock, createElementBlock, normalizeClass, renderSlot } from "vue";
|
|
7
|
-
import { c as
|
|
8
|
-
import { r as
|
|
9
|
-
import { _ as
|
|
6
|
+
import { ref as t, reactive as e, computed as o, onMounted as n, onActivated as r, onDeactivated as s, openBlock as i, createElementBlock as l, normalizeClass as u, renderSlot as c } from "vue";
|
|
7
|
+
import { c as a } from "./component.js";
|
|
8
|
+
import { r as p } from "./raf.js";
|
|
9
|
+
import { _ as y } from "./plugin-vue_export-helper.js";
|
|
10
10
|
import "../locale/lang";
|
|
11
|
-
const { componentName, create } =
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
},
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
setup(props, { emit }) {
|
|
35
|
-
const myDrag = ref();
|
|
36
|
-
const state = reactive({
|
|
37
|
-
keepAlive: false,
|
|
38
|
-
elWidth: 0,
|
|
39
|
-
elHeight: 0,
|
|
40
|
-
screenWidth: 0,
|
|
41
|
-
screenHeight: 0,
|
|
42
|
-
startTop: 0,
|
|
43
|
-
startLeft: 0,
|
|
44
|
-
nx: 0,
|
|
45
|
-
ny: 0,
|
|
46
|
-
xPum: 0,
|
|
47
|
-
yPum: 0,
|
|
48
|
-
position: { x: 0, y: 0 },
|
|
49
|
-
boundary: {
|
|
50
|
-
top: 0,
|
|
51
|
-
left: 0,
|
|
52
|
-
right: 0,
|
|
53
|
-
bottom: 0
|
|
54
|
-
}
|
|
55
|
-
});
|
|
56
|
-
const classes = computed(() => {
|
|
57
|
-
const prefixCls = componentName;
|
|
58
|
-
return {
|
|
59
|
-
[prefixCls]: true
|
|
60
|
-
};
|
|
61
|
-
});
|
|
62
|
-
function getInfo() {
|
|
63
|
-
const domElem = document.documentElement;
|
|
64
|
-
state.elWidth = myDrag.value.offsetWidth;
|
|
65
|
-
state.elHeight = myDrag.value.offsetHeight;
|
|
66
|
-
state.screenWidth = domElem.clientWidth || 375;
|
|
67
|
-
state.screenHeight = domElem.clientHeight || 667;
|
|
68
|
-
}
|
|
69
|
-
function goLeft(target) {
|
|
70
|
-
if (state.boundary.left) {
|
|
71
|
-
if (+target.style.left.split("px")[0] > state.boundary.left) {
|
|
72
|
-
target.style.left = +target.style.left.split("px")[0] - 10 + "px";
|
|
73
|
-
requestAniFrame(() => {
|
|
74
|
-
goLeft(target);
|
|
75
|
-
});
|
|
76
|
-
} else {
|
|
77
|
-
target.style.left = `${state.boundary.left}px`;
|
|
78
|
-
}
|
|
79
|
-
} else {
|
|
80
|
-
if (+target.style.left.split("px")[0] > 10) {
|
|
81
|
-
target.style.left = +target.style.left.split("px")[0] - 10 + "px";
|
|
82
|
-
requestAniFrame(() => {
|
|
83
|
-
goLeft(target);
|
|
84
|
-
});
|
|
85
|
-
} else {
|
|
86
|
-
target.style.left = "0px";
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
function goRight(target, rightLocation) {
|
|
91
|
-
if (rightLocation - parseInt(target.style.left.split("px")[0]) > 10) {
|
|
92
|
-
target.style.left = parseInt(target.style.left.split("px")[0]) + 10 + "px";
|
|
93
|
-
requestAniFrame(() => {
|
|
94
|
-
goRight(target, rightLocation);
|
|
95
|
-
});
|
|
96
|
-
} else {
|
|
97
|
-
target.style.left = rightLocation + "px";
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
function touchMove(e) {
|
|
101
|
-
e.preventDefault();
|
|
102
|
-
const target = e.currentTarget;
|
|
103
|
-
if (e.targetTouches.length === 1) {
|
|
104
|
-
const touch = e.targetTouches[0];
|
|
105
|
-
state.nx = touch.clientX - state.position.x;
|
|
106
|
-
state.ny = touch.clientY - state.position.y;
|
|
107
|
-
state.xPum = state.startLeft + state.nx;
|
|
108
|
-
state.yPum = state.startTop + state.ny;
|
|
109
|
-
const rightLocation = state.screenWidth - state.elWidth - state.boundary.right;
|
|
110
|
-
if (Math.abs(state.xPum) > rightLocation) {
|
|
111
|
-
state.xPum = rightLocation;
|
|
112
|
-
} else if (state.xPum <= state.boundary.left) {
|
|
113
|
-
state.xPum = state.boundary.left;
|
|
114
|
-
}
|
|
115
|
-
if (state.yPum < state.boundary.top) {
|
|
116
|
-
state.yPum = state.boundary.top;
|
|
117
|
-
} else if (state.yPum > state.screenHeight - state.elHeight - state.boundary.bottom) {
|
|
118
|
-
state.yPum = state.screenHeight - state.elHeight - state.boundary.bottom;
|
|
119
|
-
}
|
|
120
|
-
if (props.direction != "y") {
|
|
121
|
-
target.style.left = state.xPum + "px";
|
|
122
|
-
}
|
|
123
|
-
if (props.direction != "x") {
|
|
124
|
-
target.style.top = state.yPum + "px";
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
|
-
function touchEnd(e) {
|
|
129
|
-
const target = e.currentTarget;
|
|
130
|
-
const touch = e.changedTouches[0];
|
|
131
|
-
let currX = touch.clientX;
|
|
132
|
-
const rightLocation = state.screenWidth - state.elWidth - state.boundary.right;
|
|
133
|
-
if (currX > rightLocation) {
|
|
134
|
-
currX = rightLocation;
|
|
135
|
-
} else if (currX < state.boundary.left) {
|
|
136
|
-
currX = state.boundary.left;
|
|
137
|
-
} else {
|
|
138
|
-
currX = currX < state.screenWidth / 2 ? state.boundary.left : rightLocation;
|
|
139
|
-
}
|
|
140
|
-
if (props.direction != "y" && props.attract) {
|
|
141
|
-
if (currX < state.screenWidth / 2) {
|
|
142
|
-
requestAniFrame(() => {
|
|
143
|
-
goLeft(target);
|
|
144
|
-
});
|
|
145
|
-
} else {
|
|
146
|
-
requestAniFrame(() => {
|
|
147
|
-
goRight(target, rightLocation);
|
|
148
|
-
});
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
if (props.direction != "x") {
|
|
152
|
-
target.style.top = state.yPum + "px";
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
function touchStart(e) {
|
|
156
|
-
const target = e.currentTarget;
|
|
157
|
-
const touches = e.touches[0];
|
|
158
|
-
const touch = e.targetTouches[0];
|
|
159
|
-
state.startTop = target.offsetTop;
|
|
160
|
-
state.startLeft = target.offsetLeft;
|
|
161
|
-
state.position.x = touches.clientX;
|
|
162
|
-
state.position.y = touches.clientY;
|
|
163
|
-
state.nx = touch.clientX - state.position.x;
|
|
164
|
-
state.ny = touch.clientY - state.position.y;
|
|
165
|
-
state.xPum = state.startLeft + state.nx;
|
|
166
|
-
state.yPum = state.startTop + state.ny;
|
|
11
|
+
const { componentName: f, create: d } = a("drag");
|
|
12
|
+
var h = y(d({ props: { attract: { type: Boolean, default: false }, direction: { type: String, default: "all" }, boundary: { type: Object, default: () => ({ top: 0, left: 0, right: 0, bottom: 0 }) } }, setup(i2, { emit: l2 }) {
|
|
13
|
+
const u2 = t(), c2 = e({ keepAlive: false, elWidth: 0, elHeight: 0, screenWidth: 0, screenHeight: 0, startTop: 0, startLeft: 0, nx: 0, ny: 0, xPum: 0, yPum: 0, position: { x: 0, y: 0 }, boundary: { top: 0, left: 0, right: 0, bottom: 0 } }), a2 = o(() => ({ [f]: true }));
|
|
14
|
+
function y2(t2) {
|
|
15
|
+
c2.boundary.left ? +t2.style.left.split("px")[0] > c2.boundary.left ? (t2.style.left = +t2.style.left.split("px")[0] - 10 + "px", p(() => {
|
|
16
|
+
y2(t2);
|
|
17
|
+
})) : t2.style.left = `${c2.boundary.left}px` : +t2.style.left.split("px")[0] > 10 ? (t2.style.left = +t2.style.left.split("px")[0] - 10 + "px", p(() => {
|
|
18
|
+
y2(t2);
|
|
19
|
+
})) : t2.style.left = "0px";
|
|
20
|
+
}
|
|
21
|
+
function d2(t2, e2) {
|
|
22
|
+
e2 - parseInt(t2.style.left.split("px")[0]) > 10 ? (t2.style.left = parseInt(t2.style.left.split("px")[0]) + 10 + "px", p(() => {
|
|
23
|
+
d2(t2, e2);
|
|
24
|
+
})) : t2.style.left = e2 + "px";
|
|
25
|
+
}
|
|
26
|
+
function h2(t2) {
|
|
27
|
+
t2.preventDefault();
|
|
28
|
+
const e2 = t2.currentTarget;
|
|
29
|
+
if (t2.targetTouches.length === 1) {
|
|
30
|
+
const o2 = t2.targetTouches[0];
|
|
31
|
+
c2.nx = o2.clientX - c2.position.x, c2.ny = o2.clientY - c2.position.y, c2.xPum = c2.startLeft + c2.nx, c2.yPum = c2.startTop + c2.ny;
|
|
32
|
+
const n2 = c2.screenWidth - c2.elWidth - c2.boundary.right;
|
|
33
|
+
Math.abs(c2.xPum) > n2 ? c2.xPum = n2 : c2.xPum <= c2.boundary.left && (c2.xPum = c2.boundary.left), c2.yPum < c2.boundary.top ? c2.yPum = c2.boundary.top : c2.yPum > c2.screenHeight - c2.elHeight - c2.boundary.bottom && (c2.yPum = c2.screenHeight - c2.elHeight - c2.boundary.bottom), i2.direction != "y" && (e2.style.left = c2.xPum + "px"), i2.direction != "x" && (e2.style.top = c2.yPum + "px");
|
|
167
34
|
}
|
|
168
|
-
onMounted(() => {
|
|
169
|
-
getInfo();
|
|
170
|
-
state.boundary = props.boundary;
|
|
171
|
-
});
|
|
172
|
-
onActivated(() => {
|
|
173
|
-
if (state.keepAlive) {
|
|
174
|
-
state.keepAlive = false;
|
|
175
|
-
}
|
|
176
|
-
});
|
|
177
|
-
onDeactivated(() => {
|
|
178
|
-
state.keepAlive = true;
|
|
179
|
-
myDrag.removeEventListener("touchstart", touchStart);
|
|
180
|
-
myDrag.removeEventListener("touchmove", touchMove);
|
|
181
|
-
myDrag.removeEventListener("touchend", touchEnd);
|
|
182
|
-
});
|
|
183
|
-
return {
|
|
184
|
-
classes,
|
|
185
|
-
myDrag,
|
|
186
|
-
touchStart,
|
|
187
|
-
touchMove,
|
|
188
|
-
touchEnd
|
|
189
|
-
};
|
|
190
35
|
}
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
36
|
+
function m(t2) {
|
|
37
|
+
const e2 = t2.currentTarget;
|
|
38
|
+
let o2 = t2.changedTouches[0].clientX;
|
|
39
|
+
const n2 = c2.screenWidth - c2.elWidth - c2.boundary.right;
|
|
40
|
+
o2 = o2 > n2 ? n2 : o2 < c2.boundary.left || o2 < c2.screenWidth / 2 ? c2.boundary.left : n2, i2.direction != "y" && i2.attract && (o2 < c2.screenWidth / 2 ? p(() => {
|
|
41
|
+
y2(e2);
|
|
42
|
+
}) : p(() => {
|
|
43
|
+
d2(e2, n2);
|
|
44
|
+
})), i2.direction != "x" && (e2.style.top = c2.yPum + "px");
|
|
45
|
+
}
|
|
46
|
+
function x(t2) {
|
|
47
|
+
const e2 = t2.currentTarget, o2 = t2.touches[0], n2 = t2.targetTouches[0];
|
|
48
|
+
c2.startTop = e2.offsetTop, c2.startLeft = e2.offsetLeft, c2.position.x = o2.clientX, c2.position.y = o2.clientY, c2.nx = n2.clientX - c2.position.x, c2.ny = n2.clientY - c2.position.y, c2.xPum = c2.startLeft + c2.nx, c2.yPum = c2.startTop + c2.ny;
|
|
49
|
+
}
|
|
50
|
+
return n(() => {
|
|
51
|
+
!function() {
|
|
52
|
+
const t2 = document.documentElement;
|
|
53
|
+
c2.elWidth = u2.value.offsetWidth, c2.elHeight = u2.value.offsetHeight, c2.screenWidth = t2.clientWidth || 375, c2.screenHeight = t2.clientHeight || 667;
|
|
54
|
+
}(), c2.boundary = i2.boundary;
|
|
55
|
+
}), r(() => {
|
|
56
|
+
c2.keepAlive && (c2.keepAlive = false);
|
|
57
|
+
}), s(() => {
|
|
58
|
+
c2.keepAlive = true, u2.removeEventListener("touchstart", x), u2.removeEventListener("touchmove", h2), u2.removeEventListener("touchend", m);
|
|
59
|
+
}), { classes: a2, myDrag: u2, touchStart: x, touchMove: h2, touchEnd: m };
|
|
60
|
+
} }), [["render", function(t2, e2, o2, n2, r2, s2) {
|
|
61
|
+
return i(), l("view", { class: u(t2.classes), ref: "myDrag", onTouchstart: e2[0] || (e2[0] = (e3) => t2.touchStart(e3)), onTouchmove: e2[1] || (e2[1] = (e3) => t2.touchMove(e3)), onTouchend: e2[2] || (e2[2] = (e3) => t2.touchEnd(e3)) }, [c(t2.$slots, "default")], 34);
|
|
62
|
+
}]]);
|
|
63
|
+
export { h as default };
|
|
@@ -1,164 +1,29 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.1.
|
|
2
|
+
* @nutui/nutui v3.1.22-beta.3 Wed Jun 15 2022 20:12:30 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2022 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
|
-
import { ref, watch, resolveComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, Fragment, renderList, normalizeClass, withDirectives, vModelText, createTextVNode, createVNode } from "vue";
|
|
7
|
-
import { c as
|
|
8
|
-
import { _ as
|
|
6
|
+
import { ref as e, watch as a, resolveComponent as t, openBlock as u, createElementBlock as l, createElementVNode as n, toDisplayString as r, Fragment as c, renderList as i, normalizeClass as d, withDirectives as o, vModelText as p, createTextVNode as m, createVNode as s } from "vue";
|
|
7
|
+
import { c as v } from "./component.js";
|
|
8
|
+
import { _ as h } from "./plugin-vue_export-helper.js";
|
|
9
9
|
import "../locale/lang";
|
|
10
|
-
const { componentName, create, translate } =
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
},
|
|
31
|
-
cardAmountMax: {
|
|
32
|
-
type: Number,
|
|
33
|
-
default: 9999
|
|
34
|
-
},
|
|
35
|
-
cardBuyMin: {
|
|
36
|
-
type: Number,
|
|
37
|
-
default: 1
|
|
38
|
-
},
|
|
39
|
-
cardBuyMax: {
|
|
40
|
-
type: Number,
|
|
41
|
-
default: 9999
|
|
42
|
-
},
|
|
43
|
-
modelValue: {
|
|
44
|
-
type: Number,
|
|
45
|
-
default: 0
|
|
46
|
-
},
|
|
47
|
-
placeholder: {
|
|
48
|
-
type: String,
|
|
49
|
-
default: ""
|
|
50
|
-
},
|
|
51
|
-
suffix: {
|
|
52
|
-
type: String,
|
|
53
|
-
default: "\xA5"
|
|
54
|
-
}
|
|
55
|
-
},
|
|
56
|
-
emits: ["inputChange", "changeStep", "inputClick", "change", "update:modelValue"],
|
|
57
|
-
setup(props, { emit }) {
|
|
58
|
-
const currentIndex = ref(null);
|
|
59
|
-
const currentValue = ref(null);
|
|
60
|
-
const inputValue = ref();
|
|
61
|
-
const stepValue = ref(props.cardAmountMin);
|
|
62
|
-
const money = ref(props.modelValue);
|
|
63
|
-
const handleClick = (item, index2) => {
|
|
64
|
-
currentIndex.value = index2;
|
|
65
|
-
inputValue.value = "";
|
|
66
|
-
stepValue.value = props.cardAmountMin;
|
|
67
|
-
currentValue.value = item.price;
|
|
68
|
-
emit("change", item);
|
|
69
|
-
emit("update:modelValue", item.price);
|
|
70
|
-
};
|
|
71
|
-
const change = (event) => {
|
|
72
|
-
let input = event.target;
|
|
73
|
-
let val = input.value.replace(/[^\d]/g, "");
|
|
74
|
-
inputValue.value = val;
|
|
75
|
-
currentValue.value = val;
|
|
76
|
-
if (Number(val) > props.cardAmountMax) {
|
|
77
|
-
inputValue.value = props.cardAmountMax;
|
|
78
|
-
currentValue.value = props.cardAmountMax;
|
|
79
|
-
}
|
|
80
|
-
if (Number(val) < props.cardAmountMin) {
|
|
81
|
-
inputValue.value = props.cardAmountMin;
|
|
82
|
-
currentValue.value = props.cardAmountMin;
|
|
83
|
-
}
|
|
84
|
-
emit("inputChange", Number(inputValue.value));
|
|
85
|
-
emit("update:modelValue", Number(inputValue.value));
|
|
86
|
-
};
|
|
87
|
-
const inputClick = () => {
|
|
88
|
-
currentIndex.value = "input";
|
|
89
|
-
stepValue.value = props.cardAmountMin;
|
|
90
|
-
emit("update:modelValue", 0);
|
|
91
|
-
emit("inputClick");
|
|
92
|
-
};
|
|
93
|
-
const changeStep = (value) => {
|
|
94
|
-
stepValue.value = value;
|
|
95
|
-
emit("changeStep", stepValue.value, currentValue.value);
|
|
96
|
-
};
|
|
97
|
-
watch(() => props.modelValue, (value) => {
|
|
98
|
-
money.value = value;
|
|
99
|
-
});
|
|
100
|
-
return {
|
|
101
|
-
handleClick,
|
|
102
|
-
changeStep,
|
|
103
|
-
change,
|
|
104
|
-
inputClick,
|
|
105
|
-
stepValue,
|
|
106
|
-
currentIndex,
|
|
107
|
-
inputValue,
|
|
108
|
-
money,
|
|
109
|
-
translate
|
|
110
|
-
};
|
|
111
|
-
}
|
|
112
|
-
});
|
|
113
|
-
const _hoisted_1 = { class: "nut-ecard" };
|
|
114
|
-
const _hoisted_2 = { class: "nut-ecard__title" };
|
|
115
|
-
const _hoisted_3 = { class: "nut-ecard__list" };
|
|
116
|
-
const _hoisted_4 = ["onClick"];
|
|
117
|
-
const _hoisted_5 = { class: "nut-ecard__list__input--con" };
|
|
118
|
-
const _hoisted_6 = ["placeholder"];
|
|
119
|
-
const _hoisted_7 = { class: "nut-ecard__list__step" };
|
|
120
|
-
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
121
|
-
const _component_nut_inputnumber = resolveComponent("nut-inputnumber");
|
|
122
|
-
return openBlock(), createElementBlock("view", _hoisted_1, [
|
|
123
|
-
createElementVNode("view", _hoisted_2, toDisplayString(_ctx.chooseText || _ctx.translate("chooseText")), 1),
|
|
124
|
-
createElementVNode("view", _hoisted_3, [
|
|
125
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.dataList, (item, index2) => {
|
|
126
|
-
return openBlock(), createElementBlock("view", {
|
|
127
|
-
key: index2,
|
|
128
|
-
class: normalizeClass(["nut-ecard__list__item", _ctx.currentIndex == index2 ? "active" : ""]),
|
|
129
|
-
onClick: ($event) => _ctx.handleClick(item, index2)
|
|
130
|
-
}, toDisplayString(item.price), 11, _hoisted_4);
|
|
131
|
-
}), 128)),
|
|
132
|
-
createElementVNode("view", {
|
|
133
|
-
class: normalizeClass(["nut-ecard__list__input", _ctx.currentIndex == "input" ? "active" : ""]),
|
|
134
|
-
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.inputClick && _ctx.inputClick(...args))
|
|
135
|
-
}, [
|
|
136
|
-
createElementVNode("view", null, toDisplayString(_ctx.otherValueText || _ctx.translate("otherValueText")), 1),
|
|
137
|
-
createElementVNode("view", _hoisted_5, [
|
|
138
|
-
withDirectives(createElementVNode("input", {
|
|
139
|
-
class: "nut-ecard__list__input--input",
|
|
140
|
-
type: "text",
|
|
141
|
-
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.inputValue = $event),
|
|
142
|
-
onInput: _cache[1] || (_cache[1] = (...args) => _ctx.change && _ctx.change(...args)),
|
|
143
|
-
placeholder: _ctx.placeholder || _ctx.translate("placeholder")
|
|
144
|
-
}, null, 40, _hoisted_6), [
|
|
145
|
-
[vModelText, _ctx.inputValue]
|
|
146
|
-
]),
|
|
147
|
-
createTextVNode(" " + toDisplayString(_ctx.suffix), 1)
|
|
148
|
-
])
|
|
149
|
-
], 2),
|
|
150
|
-
createElementVNode("view", _hoisted_7, [
|
|
151
|
-
createElementVNode("view", null, toDisplayString(_ctx.suffix) + toDisplayString(_ctx.money), 1),
|
|
152
|
-
createVNode(_component_nut_inputnumber, {
|
|
153
|
-
modelValue: _ctx.stepValue,
|
|
154
|
-
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.stepValue = $event),
|
|
155
|
-
min: _ctx.cardBuyMin,
|
|
156
|
-
max: _ctx.cardBuyMax,
|
|
157
|
-
onChange: _ctx.changeStep
|
|
158
|
-
}, null, 8, ["modelValue", "min", "max", "onChange"])
|
|
159
|
-
])
|
|
160
|
-
])
|
|
161
|
-
]);
|
|
162
|
-
}
|
|
163
|
-
var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
164
|
-
export { index as default };
|
|
10
|
+
const { componentName: _, create: x, translate: g } = v("ecard"), f = x({ props: { chooseText: { type: String, default: "" }, otherValueText: { type: String, default: "" }, dataList: { type: [Object, Array], default: () => [] }, cardAmountMin: { type: Number, default: 1 }, cardAmountMax: { type: Number, default: 9999 }, cardBuyMin: { type: Number, default: 1 }, cardBuyMax: { type: Number, default: 9999 }, modelValue: { type: [Number, String], default: 0 }, placeholder: { type: String, default: "" }, suffix: { type: String, default: "\xA5" } }, emits: ["inputChange", "changeStep", "inputClick", "change", "update:modelValue"], setup(t2, { emit: u2 }) {
|
|
11
|
+
const l2 = e(null), n2 = e(null), r2 = e(""), c2 = e(t2.cardAmountMin), i2 = e(t2.modelValue);
|
|
12
|
+
return a(() => t2.modelValue, (e2) => {
|
|
13
|
+
i2.value = e2;
|
|
14
|
+
}), { handleClick: (e2, a2) => {
|
|
15
|
+
l2.value = a2, c2.value = t2.cardAmountMin, n2.value = e2.price, u2("change", e2), u2("update:modelValue", e2.price);
|
|
16
|
+
}, changeStep: (e2) => {
|
|
17
|
+
c2.value = e2, u2("changeStep", c2.value, n2.value);
|
|
18
|
+
}, change: (e2) => {
|
|
19
|
+
let a2 = e2.target.value.replace(/[^\d]/g, "");
|
|
20
|
+
r2.value = a2, n2.value = a2, Number(a2) > t2.cardAmountMax && (r2.value = t2.cardAmountMax, n2.value = t2.cardAmountMax), Number(a2) < t2.cardAmountMin && (r2.value = t2.cardAmountMin, n2.value = t2.cardAmountMin), u2("inputChange", Number(r2.value)), u2("update:modelValue", Number(r2.value));
|
|
21
|
+
}, inputClick: () => {
|
|
22
|
+
l2.value = "input", c2.value = t2.cardAmountMin, n2.value = r2.value, u2("update:modelValue", r2.value), u2("inputClick");
|
|
23
|
+
}, stepValue: c2, currentIndex: l2, inputValue: r2, money: i2, translate: g };
|
|
24
|
+
} }), V = { class: "nut-ecard" }, y = { class: "nut-ecard__title" }, M = { class: "nut-ecard__list" }, C = ["onClick"], A = { class: "nut-ecard__list__input--con" }, b = ["placeholder"], k = { class: "nut-ecard__list__step" };
|
|
25
|
+
var N = h(f, [["render", function(e2, a2, v2, h2, _2, x2) {
|
|
26
|
+
const g2 = t("nut-inputnumber");
|
|
27
|
+
return u(), l("view", V, [n("view", y, r(e2.chooseText || e2.translate("chooseText")), 1), n("view", M, [(u(true), l(c, null, i(e2.dataList, (a3, t2) => (u(), l("view", { key: t2, class: d(["nut-ecard__list__item", e2.currentIndex == t2 ? "active" : ""]), onClick: (u2) => e2.handleClick(a3, t2) }, r(a3.price), 11, C))), 128)), n("view", { class: d(["nut-ecard__list__input", e2.currentIndex == "input" ? "active" : ""]), onClick: a2[2] || (a2[2] = (...a3) => e2.inputClick && e2.inputClick(...a3)) }, [n("view", null, r(e2.otherValueText || e2.translate("otherValueText")), 1), n("view", A, [o(n("input", { class: "nut-ecard__list__input--input", type: "text", "onUpdate:modelValue": a2[0] || (a2[0] = (a3) => e2.inputValue = a3), onInput: a2[1] || (a2[1] = (...a3) => e2.change && e2.change(...a3)), placeholder: e2.placeholder || e2.translate("placeholder") }, null, 40, b), [[p, e2.inputValue]]), m(" " + r(e2.suffix), 1)])], 2), n("view", k, [n("view", null, r(e2.suffix) + r(e2.money), 1), s(g2, { modelValue: e2.stepValue, "onUpdate:modelValue": a2[3] || (a2[3] = (a3) => e2.stepValue = a3), min: e2.cardBuyMin, max: e2.cardBuyMax, onChange: e2.changeStep }, null, 8, ["modelValue", "min", "max", "onChange"])])])]);
|
|
28
|
+
}]]);
|
|
29
|
+
export { N as default };
|