@nutui/nutui 3.1.21-beta.2 → 3.1.22-beta.0

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.
Files changed (278) hide show
  1. package/CHANGELOG.md +57 -0
  2. package/dist/nutui.es.js +1470 -404
  3. package/dist/nutui.umd.js +1465 -399
  4. package/dist/packages/_es/ActionSheet.js +1 -1
  5. package/dist/packages/_es/Address.js +1 -1
  6. package/dist/packages/_es/AddressList.js +4 -2
  7. package/dist/packages/_es/Audio.js +29 -39
  8. package/dist/packages/_es/AudioOperate.js +1 -1
  9. package/dist/packages/_es/Avatar.js +1 -1
  10. package/dist/packages/_es/AvatarGroup.js +1 -1
  11. package/dist/packages/_es/BackTop.js +1 -1
  12. package/dist/packages/_es/Badge.js +1 -1
  13. package/dist/packages/_es/Barrage.js +9 -2
  14. package/dist/packages/_es/Button.js +1 -1
  15. package/dist/packages/_es/Calendar.js +1 -1
  16. package/dist/packages/_es/CalendarItem.js +1 -1
  17. package/dist/packages/_es/Card.js +1 -1
  18. package/dist/packages/_es/Cascader.js +1 -1
  19. package/dist/packages/_es/Category.js +1 -1
  20. package/dist/packages/_es/CategoryPane.js +1 -1
  21. package/dist/packages/_es/Cell.js +5 -3
  22. package/dist/packages/_es/CellGroup.js +1 -1
  23. package/dist/packages/_es/Checkbox.js +1 -1
  24. package/dist/packages/_es/CheckboxGroup.js +1 -1
  25. package/dist/packages/_es/CircleProgress.js +2 -2
  26. package/dist/packages/_es/Col.js +1 -1
  27. package/dist/packages/_es/Collapse.js +1 -1
  28. package/dist/packages/_es/CollapseItem.js +1 -1
  29. package/dist/packages/_es/Comment.js +1 -1
  30. package/dist/packages/_es/CountDown.js +1 -1
  31. package/dist/packages/_es/CountUp.js +1 -3
  32. package/dist/packages/_es/DatePicker.js +8 -8
  33. package/dist/packages/_es/Dialog.js +8 -6
  34. package/dist/packages/_es/Divider.js +47 -10
  35. package/dist/packages/_es/Drag.js +1 -1
  36. package/dist/packages/_es/Ecard.js +1 -1
  37. package/dist/packages/_es/Elevator.js +13 -9
  38. package/dist/packages/_es/Empty.js +1 -1
  39. package/dist/packages/_es/FixedNav.js +1 -1
  40. package/dist/packages/_es/Form.js +8 -3
  41. package/dist/packages/_es/FormItem.js +1 -1
  42. package/dist/packages/_es/Grid.js +1 -1
  43. package/dist/packages/_es/GridItem.js +1 -1
  44. package/dist/packages/_es/Icon.js +1 -1
  45. package/dist/packages/_es/ImagePreview.js +1 -1
  46. package/dist/packages/_es/Indicator.js +1 -1
  47. package/dist/packages/_es/InfiniteLoading.js +1 -1
  48. package/dist/packages/_es/Input.js +1 -1
  49. package/dist/packages/_es/InputNumber.js +1 -1
  50. package/dist/packages/_es/Layout.js +1 -1
  51. package/dist/packages/_es/List.js +3 -2
  52. package/dist/packages/_es/Menu.js +5 -1
  53. package/dist/packages/_es/MenuItem.js +4 -3
  54. package/dist/packages/_es/Navbar.js +119 -21
  55. package/dist/packages/_es/NoticeBar.js +1 -1
  56. package/dist/packages/_es/Notify.js +1 -1
  57. package/dist/packages/_es/NumberKeyboard.js +25 -8
  58. package/dist/packages/_es/OldPicker.js +1 -1
  59. package/dist/packages/_es/OverLay.js +1 -1
  60. package/dist/packages/_es/Pagination.js +1 -1
  61. package/dist/packages/_es/Picker.js +4 -2
  62. package/dist/packages/_es/Popover.js +890 -93
  63. package/dist/packages/_es/Popup.js +7 -4
  64. package/dist/packages/_es/Price.js +1 -1
  65. package/dist/packages/_es/Progress.js +3 -3
  66. package/dist/packages/_es/PullRefresh.js +1 -1
  67. package/dist/packages/_es/Radio.js +1 -1
  68. package/dist/packages/_es/RadioGroup.js +1 -1
  69. package/dist/packages/_es/Range.js +1 -1
  70. package/dist/packages/_es/Rate.js +1 -1
  71. package/dist/packages/_es/Row.js +3 -3
  72. package/dist/packages/_es/SearchBar.js +91 -25
  73. package/dist/packages/_es/ShortPassword.js +1 -1
  74. package/dist/packages/_es/SideNavBar.js +1 -1
  75. package/dist/packages/_es/SideNavBarItem.js +1 -1
  76. package/dist/packages/_es/Signature.js +1 -1
  77. package/dist/packages/_es/Skeleton.js +1 -1
  78. package/dist/packages/_es/Sku.js +2 -2
  79. package/dist/packages/_es/Step.js +1 -1
  80. package/dist/packages/_es/Steps.js +1 -1
  81. package/dist/packages/_es/Sticky.js +1 -1
  82. package/dist/packages/_es/SubSideNavBar.js +1 -1
  83. package/dist/packages/_es/Swipe.js +1 -1
  84. package/dist/packages/_es/Swiper.js +35 -16
  85. package/dist/packages/_es/SwiperItem.js +5 -2
  86. package/dist/packages/_es/Switch.js +1 -1
  87. package/dist/packages/_es/TabPane.js +7 -3
  88. package/dist/packages/_es/Tabbar.js +1 -1
  89. package/dist/packages/_es/TabbarItem.js +2 -1
  90. package/dist/packages/_es/Table.js +1 -1
  91. package/dist/packages/_es/Tabs.js +12 -7
  92. package/dist/packages/_es/Tag.js +1 -1
  93. package/dist/packages/_es/TextArea.js +1 -1
  94. package/dist/packages/_es/TimeDetail.js +1 -1
  95. package/dist/packages/_es/TimePannel.js +1 -1
  96. package/dist/packages/_es/TimeSelect.js +1 -1
  97. package/dist/packages/_es/Toast.js +1 -1
  98. package/dist/packages/_es/Uploader.js +6 -5
  99. package/dist/packages/_es/Video.js +1 -1
  100. package/dist/packages/_es/common.js +1 -1
  101. package/dist/packages/_es/component.js +2 -2
  102. package/dist/packages/_es/index.js +1 -1
  103. package/dist/packages/_es/index2.js +1 -1
  104. package/dist/packages/_es/index3.js +1 -1
  105. package/dist/packages/_es/index4.js +1 -1
  106. package/dist/packages/_es/index5.js +1 -1
  107. package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
  108. package/dist/packages/_es/pxCheck.js +1 -1
  109. package/dist/packages/_es/raf.js +1 -1
  110. package/dist/packages/_es/style.css +1 -1
  111. package/dist/packages/addresslist/index.scss +2 -2
  112. package/dist/packages/card/index.scss +1 -1
  113. package/dist/packages/cell/index.scss +4 -0
  114. package/dist/packages/dialog/index.scss +0 -2
  115. package/dist/packages/divider/index.scss +9 -0
  116. package/dist/packages/formitem/index.scss +1 -0
  117. package/dist/packages/locale/index.d.ts +8 -3
  118. package/dist/packages/locale/{locale/lang → lang}/baseLang.d.ts +1 -1
  119. package/dist/packages/locale/lang/baseLang.js +1 -1
  120. package/dist/packages/locale/{locale/lang → lang}/en-US.d.ts +9 -1
  121. package/dist/packages/locale/lang/en-US.js +10 -2
  122. package/dist/packages/locale/lang/id-ID.d.ts +96 -0
  123. package/dist/packages/locale/lang/id-ID.js +104 -0
  124. package/dist/packages/locale/lang/index.js +2 -2
  125. package/dist/packages/locale/{locale/lang → lang}/zh-CN.d.ts +9 -1
  126. package/dist/packages/locale/lang/zh-CN.js +10 -2
  127. package/dist/packages/locale/{locale/lang → lang}/zh-TW.d.ts +9 -1
  128. package/dist/packages/locale/lang/zh-TW.js +10 -2
  129. package/dist/packages/menuitem/index.scss +0 -1
  130. package/dist/packages/navbar/index.scss +8 -1
  131. package/dist/packages/popover/index.scss +402 -81
  132. package/dist/packages/popup/index.scss +3 -0
  133. package/dist/packages/searchbar/index.scss +4 -0
  134. package/dist/packages/tabbar/index.scss +2 -2
  135. package/dist/packages/tabpane/index.scss +4 -2
  136. package/dist/packages/tabs/index.scss +3 -0
  137. package/dist/packages/timeselect/index.scss +3 -2
  138. package/dist/smartips/attributes.json +126 -34
  139. package/dist/smartips/tags.json +48 -23
  140. package/dist/style.css +1 -1
  141. package/dist/styles/themes/default.scss +53 -53
  142. package/dist/styles/themes/jdb.scss +97 -0
  143. package/dist/styles/themes/jdt.scss +53 -53
  144. package/dist/styles/variables-jdb.scss +852 -0
  145. package/dist/styles/variables-jdt.scss +15 -7
  146. package/dist/styles/variables.scss +15 -6
  147. package/dist/types/__VUE/actionsheet/{index.d.ts → index.vue.d.ts} +63 -115
  148. package/dist/types/__VUE/address/{index.d.ts → index.vue.d.ts} +80 -150
  149. package/dist/types/__VUE/addresslist/components/{GeneralShell.d.ts → GeneralShell.vue.d.ts} +6 -7
  150. package/dist/types/__VUE/addresslist/components/{ItemContents.d.ts → ItemContents.vue.d.ts} +8 -11
  151. package/dist/types/__VUE/addresslist/components/{LongPressShell.d.ts → LongPressShell.vue.d.ts} +6 -7
  152. package/dist/types/__VUE/addresslist/components/{SwipeShell.d.ts → SwipeShell.vue.d.ts} +6 -7
  153. package/dist/types/__VUE/addresslist/{index.d.ts → index.vue.d.ts} +15 -24
  154. package/dist/types/__VUE/audio/index.vue.d.ts +102 -0
  155. package/dist/types/__VUE/audiooperate/index.vue.d.ts +87 -0
  156. package/dist/types/__VUE/avatar/{index.d.ts → index.vue.d.ts} +19 -32
  157. package/dist/types/__VUE/avatargroup/{index.d.ts → index.vue.d.ts} +20 -35
  158. package/dist/types/__VUE/backtop/{index.d.ts → index.vue.d.ts} +19 -35
  159. package/dist/types/__VUE/badge/{index.d.ts → index.vue.d.ts} +20 -33
  160. package/dist/types/__VUE/barrage/{index.d.ts → index.vue.d.ts} +15 -26
  161. package/dist/types/__VUE/button/{index.d.ts → index.vue.d.ts} +34 -51
  162. package/dist/types/__VUE/button/type.d.ts +7 -0
  163. package/dist/types/__VUE/calendar/{index.d.ts → index.vue.d.ts} +32 -57
  164. package/dist/types/__VUE/calendaritem/{index.d.ts → index.vue.d.ts} +35 -60
  165. package/dist/types/__VUE/card/{index.d.ts → index.vue.d.ts} +19 -34
  166. package/dist/types/__VUE/cascader/{cascader-item.d.ts → cascader-item.vue.d.ts} +23 -24
  167. package/dist/types/__VUE/cascader/{index.d.ts → index.vue.d.ts} +63 -99
  168. package/dist/types/__VUE/category/{index.d.ts → index.vue.d.ts} +7 -10
  169. package/dist/types/__VUE/categorypane/{index.d.ts → index.vue.d.ts} +10 -15
  170. package/dist/types/__VUE/cell/{index.d.ts → index.vue.d.ts} +32 -40
  171. package/dist/types/__VUE/cellgroup/{index.d.ts → index.vue.d.ts} +8 -11
  172. package/dist/types/__VUE/checkbox/{index.d.ts → index.vue.d.ts} +21 -38
  173. package/dist/types/__VUE/checkboxgroup/{index.d.ts → index.vue.d.ts} +8 -11
  174. package/dist/types/__VUE/circleprogress/{index.d.ts → index.vue.d.ts} +18 -31
  175. package/dist/types/__VUE/col/{index.d.ts → index.vue.d.ts} +7 -10
  176. package/dist/types/__VUE/collapse/{index.d.ts → index.vue.d.ts} +24 -40
  177. package/dist/types/__VUE/collapseitem/{index.d.ts → index.vue.d.ts} +22 -30
  178. package/dist/types/__VUE/comment/components/{CmtBottom.d.ts → CmtBottom.vue.d.ts} +11 -16
  179. package/dist/types/__VUE/comment/components/{CmtHeader.d.ts → CmtHeader.vue.d.ts} +10 -15
  180. package/dist/types/__VUE/comment/components/{CmtImages.d.ts → CmtImages.vue.d.ts} +10 -15
  181. package/dist/types/__VUE/comment/{index.d.ts → index.vue.d.ts} +22 -39
  182. package/dist/types/__VUE/countdown/{index.d.ts → index.vue.d.ts} +22 -36
  183. package/dist/types/__VUE/countup/{index.d.ts → index.vue.d.ts} +41 -74
  184. package/dist/types/__VUE/datepicker/{index.d.ts → index.vue.d.ts} +72 -126
  185. package/dist/types/__VUE/datepicker/type.d.ts +6 -0
  186. package/dist/types/__VUE/dialog/index.d.ts +37 -302
  187. package/dist/types/__VUE/dialog/index.vue.d.ts +248 -0
  188. package/dist/types/__VUE/divider/{index.d.ts → index.vue.d.ts} +15 -15
  189. package/dist/types/__VUE/drag/{index.d.ts → index.vue.d.ts} +9 -19
  190. package/dist/types/__VUE/ecard/{index.d.ts → index.vue.d.ts} +25 -44
  191. package/dist/types/__VUE/elevator/{index.d.ts → index.vue.d.ts} +10 -14
  192. package/dist/types/__VUE/empty/{index.d.ts → index.vue.d.ts} +10 -15
  193. package/dist/types/__VUE/fixednav/{index.d.ts → index.vue.d.ts} +20 -36
  194. package/dist/types/__VUE/form/{index.d.ts → index.vue.d.ts} +5 -6
  195. package/dist/types/__VUE/formitem/{index.d.ts → index.vue.d.ts} +26 -45
  196. package/dist/types/__VUE/grid/common.d.ts +3 -3
  197. package/dist/types/__VUE/grid/{index.d.ts → index.vue.d.ts} +24 -40
  198. package/dist/types/__VUE/griditem/{index.d.ts → index.vue.d.ts} +19 -26
  199. package/dist/types/__VUE/icon/{index.d.ts → index.vue.d.ts} +15 -26
  200. package/dist/types/__VUE/imagepreview/index.d.ts +20 -121
  201. package/dist/types/__VUE/imagepreview/index.vue.d.ts +108 -0
  202. package/dist/types/__VUE/indicator/{index.d.ts → index.vue.d.ts} +13 -24
  203. package/dist/types/__VUE/infiniteloading/{index.d.ts → index.vue.d.ts} +27 -48
  204. package/dist/types/__VUE/input/{index.d.ts → index.vue.d.ts} +83 -146
  205. package/dist/types/__VUE/input/type.d.ts +13 -0
  206. package/dist/types/__VUE/inputnumber/{index.d.ts → index.vue.d.ts} +22 -39
  207. package/dist/types/__VUE/layout/{index.d.ts → index.vue.d.ts} +1 -1
  208. package/dist/types/__VUE/list/{index.d.ts → index.vue.d.ts} +10 -14
  209. package/dist/types/__VUE/menu/{index.d.ts → index.vue.d.ts} +16 -14
  210. package/dist/types/__VUE/menuitem/{index.d.ts → index.vue.d.ts} +20 -24
  211. package/dist/types/__VUE/menuitem/type.d.ts +8 -0
  212. package/dist/types/__VUE/navbar/{index.d.ts → index.vue.d.ts} +48 -26
  213. package/dist/types/__VUE/noticebar/{index.d.ts → index.vue.d.ts} +34 -63
  214. package/dist/types/__VUE/notify/index.d.ts +12 -109
  215. package/dist/types/__VUE/notify/index.vue.d.ts +101 -0
  216. package/dist/types/__VUE/numberkeyboard/{index.d.ts → index.vue.d.ts} +43 -45
  217. package/dist/types/__VUE/oldpicker/{Column.d.ts → Column.vue.d.ts} +17 -22
  218. package/dist/types/__VUE/oldpicker/{index.d.ts → index.vue.d.ts} +75 -128
  219. package/dist/types/__VUE/overlay/{index.d.ts → index.vue.d.ts} +19 -30
  220. package/dist/types/__VUE/pagination/{index.d.ts → index.vue.d.ts} +22 -39
  221. package/dist/types/__VUE/picker/{Column.d.ts → Column.vue.d.ts} +16 -18
  222. package/dist/types/__VUE/picker/{index.d.ts → index.vue.d.ts} +80 -130
  223. package/dist/types/__VUE/popover/{index.d.ts → index.vue.d.ts} +86 -110
  224. package/dist/types/__VUE/popover/type.d.ts +6 -0
  225. package/dist/types/__VUE/popup/{index.d.ts → index.vue.d.ts} +47 -82
  226. package/dist/types/__VUE/price/{index.d.ts → index.vue.d.ts} +17 -30
  227. package/dist/types/__VUE/progress/{index.d.ts → index.vue.d.ts} +29 -53
  228. package/dist/types/__VUE/pullrefresh/{index.d.ts → index.vue.d.ts} +18 -46
  229. package/dist/types/__VUE/radio/{index.d.ts → index.vue.d.ts} +19 -34
  230. package/dist/types/__VUE/radiogroup/{index.d.ts → index.vue.d.ts} +10 -15
  231. package/dist/types/__VUE/range/{index.d.ts → index.vue.d.ts} +34 -46
  232. package/dist/types/__VUE/range/type.d.ts +5 -0
  233. package/dist/types/__VUE/rate/{index.d.ts → index.vue.d.ts} +29 -54
  234. package/dist/types/__VUE/row/{index.d.ts → index.vue.d.ts} +15 -24
  235. package/dist/types/__VUE/searchbar/{index.d.ts → index.vue.d.ts} +63 -33
  236. package/dist/types/__VUE/shortpassword/{index.d.ts → index.vue.d.ts} +25 -44
  237. package/dist/types/__VUE/sidenavbar/{index.d.ts → index.vue.d.ts} +6 -7
  238. package/dist/types/__VUE/sidenavbaritem/{index.d.ts → index.vue.d.ts} +8 -11
  239. package/dist/types/__VUE/signature/{index.d.ts → index.vue.d.ts} +14 -23
  240. package/dist/types/__VUE/skeleton/common.d.ts +3 -5
  241. package/dist/types/__VUE/skeleton/{index.d.ts → index.vue.d.ts} +24 -43
  242. package/dist/types/__VUE/sku/components/{SkuHeader.d.ts → SkuHeader.vue.d.ts} +7 -8
  243. package/dist/types/__VUE/sku/components/{SkuOperate.d.ts → SkuOperate.vue.d.ts} +14 -23
  244. package/dist/types/__VUE/sku/components/{SkuSelect.d.ts → SkuSelect.vue.d.ts} +6 -7
  245. package/dist/types/__VUE/sku/components/{SkuStepper.d.ts → SkuStepper.vue.d.ts} +12 -19
  246. package/dist/types/__VUE/sku/{index.d.ts → index.vue.d.ts} +68 -126
  247. package/dist/types/__VUE/step/{index.d.ts → index.vue.d.ts} +15 -24
  248. package/dist/types/__VUE/steps/{index.d.ts → index.vue.d.ts} +9 -14
  249. package/dist/types/__VUE/sticky/{index.d.ts → index.vue.d.ts} +14 -21
  250. package/dist/types/__VUE/subsidenavbar/{index.d.ts → index.vue.d.ts} +10 -15
  251. package/dist/types/__VUE/swipe/{index.d.ts → index.vue.d.ts} +12 -19
  252. package/dist/types/__VUE/swiper/{index.d.ts → index.vue.d.ts} +30 -50
  253. package/dist/types/__VUE/swiperitem/{index.d.ts → index.vue.d.ts} +2 -2
  254. package/dist/types/__VUE/switch/{index.d.ts → index.vue.d.ts} +27 -50
  255. package/dist/types/__VUE/tabbar/{index.d.ts → index.vue.d.ts} +17 -30
  256. package/dist/types/__VUE/tabbaritem/{index.d.ts → index.vue.d.ts} +25 -40
  257. package/dist/types/__VUE/table/common.d.ts +1 -1
  258. package/dist/types/__VUE/table/{index.d.ts → index.vue.d.ts} +14 -23
  259. package/dist/types/__VUE/tabpane/{index.d.ts → index.vue.d.ts} +11 -15
  260. package/dist/types/__VUE/tabs/common.d.ts +6 -2
  261. package/dist/types/__VUE/tabs/{index.d.ts → index.vue.d.ts} +30 -42
  262. package/dist/types/__VUE/tag/{index.d.ts → index.vue.d.ts} +21 -34
  263. package/dist/types/__VUE/tag/type.d.ts +5 -0
  264. package/dist/types/__VUE/textarea/{index.d.ts → index.vue.d.ts} +27 -46
  265. package/dist/types/__VUE/timedetail/{index.d.ts → index.vue.d.ts} +8 -11
  266. package/dist/types/__VUE/timepannel/{index.d.ts → index.vue.d.ts} +8 -11
  267. package/dist/types/__VUE/timeselect/{index.d.ts → index.vue.d.ts} +18 -29
  268. package/dist/types/__VUE/toast/index.d.ts +12 -145
  269. package/dist/types/__VUE/toast/index.vue.d.ts +134 -0
  270. package/dist/types/__VUE/uploader/{index.d.ts → index.vue.d.ts} +59 -106
  271. package/dist/types/__VUE/uploader/type.d.ts +18 -0
  272. package/dist/types/__VUE/video/{index.d.ts → index.vue.d.ts} +11 -28
  273. package/dist/types/index.d.ts +7 -2
  274. package/dist/types/nutui.d.ts +92 -92
  275. package/package.json +6 -3
  276. package/dist/packages/locale/locale/index.d.ts +0 -8
  277. package/dist/types/__VUE/audio/index.d.ts +0 -92
  278. package/dist/types/__VUE/audiooperate/index.d.ts +0 -68
@@ -18,11 +18,11 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
25
- import { reactive, computed, onMounted, onBeforeUnmount, onBeforeMount, onActivated, onDeactivated, watch, toRefs, resolveComponent, openBlock, createBlock, Teleport, normalizeClass, normalizeStyle, createCommentVNode, createVNode, Transition, withCtx, withDirectives, createElementVNode, renderSlot, createElementBlock, vShow } from "vue";
25
+ import { ref, reactive, computed, onMounted, onBeforeUnmount, onBeforeMount, onActivated, onDeactivated, watch, toRefs, resolveComponent, openBlock, createBlock, Teleport, normalizeClass, normalizeStyle, createCommentVNode, createVNode, Transition, withCtx, withDirectives, createElementVNode, renderSlot, createElementBlock, vShow } from "vue";
26
26
  import overlay, { overlayProps } from "./OverLay.js";
27
27
  import _sfc_main$1 from "./Icon.js";
28
28
  import { c as createComponent } from "./component.js";
@@ -106,6 +106,7 @@ const _sfc_main = create({
106
106
  props: __spreadValues({}, popupProps),
107
107
  emits: ["click", "click-close-icon", "open", "close", "opend", "closed", "update:visible", "click-overlay"],
108
108
  setup(props, { emit }) {
109
+ const popupRef = ref();
109
110
  const state = reactive({
110
111
  zIndex: props.zIndex ? props.zIndex : _zIndex,
111
112
  showSlot: true,
@@ -220,7 +221,8 @@ const _sfc_main = create({
220
221
  onClickCloseIcon,
221
222
  onClickOverlay,
222
223
  onOpened,
223
- onClosed
224
+ onClosed,
225
+ popupRef
224
226
  });
225
227
  }
226
228
  });
@@ -252,7 +254,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
252
254
  withDirectives(createElementVNode("view", {
253
255
  class: normalizeClass(_ctx.classes),
254
256
  style: normalizeStyle(_ctx.popStyle),
255
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.onClick && _ctx.onClick(...args))
257
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.onClick && _ctx.onClick(...args)),
258
+ ref: "popupRef"
256
259
  }, [
257
260
  _ctx.showSlot ? renderSlot(_ctx.$slots, "default", { key: 0 }) : createCommentVNode("", true),
258
261
  _ctx.closed ? (openBlock(), createElementBlock("view", {
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -40,11 +40,11 @@ const _sfc_main = create({
40
40
  default: ""
41
41
  },
42
42
  textColor: {
43
- tyep: String,
43
+ type: String,
44
44
  default: ""
45
45
  },
46
46
  textBackground: {
47
- tyep: String,
47
+ type: String,
48
48
  default: ""
49
49
  },
50
50
  iconName: {
@@ -15,7 +15,7 @@ var __spreadValues = (a, b) => {
15
15
  return a;
16
16
  };
17
17
  /*!
18
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
18
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
19
19
  * (c) 2022 @jdf2e.
20
20
  * Released under the MIT License.
21
21
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -26,7 +26,7 @@ const _sfc_main = create({
26
26
  type: String,
27
27
  default: "flex-start"
28
28
  },
29
- wrap: {
29
+ flexWrap: {
30
30
  type: String,
31
31
  default: "nowrap"
32
32
  }
@@ -43,7 +43,7 @@ const _sfc_main = create({
43
43
  ${getClass("", props.type)}
44
44
  ${getClass("justify", props.justify)}
45
45
  ${getClass("align", props.align)}
46
- ${getClass("flex", props.wrap)}
46
+ ${getClass("flex", props.flexWrap)}
47
47
  ${prefixCls}
48
48
  `;
49
49
  };
@@ -18,11 +18,11 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
25
- import { reactive, computed, toRefs, resolveComponent, openBlock, createElementBlock, normalizeStyle, renderSlot, createCommentVNode, createElementVNode, withModifiers, withDirectives, createVNode, vShow } from "vue";
25
+ import { reactive, computed, ref, onMounted, toRefs, resolveComponent, openBlock, createElementBlock, normalizeStyle, toDisplayString, createCommentVNode, renderSlot, createElementVNode, withModifiers, withDirectives, createVNode, vShow } from "vue";
26
26
  import { c as createComponent } from "./component.js";
27
27
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
28
28
  import "../locale/lang";
@@ -35,7 +35,11 @@ const _sfc_main = create({
35
35
  },
36
36
  inputType: {
37
37
  type: String,
38
- default: "text"
38
+ default: "textarea"
39
+ },
40
+ label: {
41
+ type: String,
42
+ default: ""
39
43
  },
40
44
  maxLength: {
41
45
  type: [String, Number],
@@ -56,9 +60,35 @@ const _sfc_main = create({
56
60
  inputBackground: {
57
61
  type: String,
58
62
  default: ""
63
+ },
64
+ autofocus: {
65
+ type: Boolean,
66
+ default: false
67
+ },
68
+ disabled: {
69
+ type: Boolean,
70
+ default: false
71
+ },
72
+ readonly: {
73
+ type: Boolean,
74
+ default: false
75
+ },
76
+ inputAlign: {
77
+ type: String,
78
+ default: "left"
59
79
  }
60
80
  },
61
- emits: ["change", "update:modelValue", "blur", "focus", "clear", "search"],
81
+ emits: [
82
+ "change",
83
+ "update:modelValue",
84
+ "blur",
85
+ "focus",
86
+ "clear",
87
+ "search",
88
+ "click-input",
89
+ "click-left-icon",
90
+ "click-right-icon"
91
+ ],
62
92
  setup(props, { emit }) {
63
93
  const state = reactive({
64
94
  active: false
@@ -107,7 +137,29 @@ const _sfc_main = create({
107
137
  const handleSubmit = () => {
108
138
  emit("search", props.modelValue);
109
139
  };
110
- return __spreadProps(__spreadValues({}, toRefs(state)), {
140
+ const clickInput = (event) => {
141
+ emit("click-input", event);
142
+ };
143
+ const leftIconClick = (event) => {
144
+ emit("click-left-icon", props.modelValue, event);
145
+ };
146
+ const rightIconClick = (event) => {
147
+ emit("click-right-icon", props.modelValue, event);
148
+ };
149
+ const styleSearchbar = computed(() => {
150
+ return {
151
+ "text-align": props.inputAlign
152
+ };
153
+ });
154
+ const inputsearch = ref(null);
155
+ onMounted(() => {
156
+ if (props.autofocus) {
157
+ inputsearch.value.focus();
158
+ }
159
+ });
160
+ return __spreadProps(__spreadValues({
161
+ inputsearch
162
+ }, toRefs(state)), {
111
163
  valueChange,
112
164
  valueFocus,
113
165
  valueBlur,
@@ -115,26 +167,26 @@ const _sfc_main = create({
115
167
  handleSubmit,
116
168
  searchbarStyle,
117
169
  inputSearchbarStyle,
118
- translate
170
+ translate,
171
+ clickInput,
172
+ leftIconClick,
173
+ rightIconClick,
174
+ styleSearchbar
119
175
  });
120
176
  }
121
177
  });
122
178
  const _hoisted_1 = {
123
179
  key: 0,
124
- class: "nut-searchbar__search-icon nut-searchbar__left-search-icon"
180
+ class: "nut-searchbar__search-label"
125
181
  };
126
182
  const _hoisted_2 = {
127
- key: 0,
128
- class: "nut-searchbar__search-icon nut-searchbar__iptleft-search-icon"
183
+ key: 1,
184
+ class: "nut-searchbar__search-icon nut-searchbar__left-search-icon"
129
185
  };
130
186
  const _hoisted_3 = { class: "nut-searchbar__input-inner" };
131
- const _hoisted_4 = ["type", "maxlength", "placeholder", "value"];
187
+ const _hoisted_4 = ["type", "maxlength", "placeholder", "value", "disabled", "readonly"];
132
188
  const _hoisted_5 = {
133
- key: 1,
134
- class: "nut-searchbar__search-icon nut-searchbar__iptright-sarch-icon"
135
- };
136
- const _hoisted_6 = {
137
- key: 1,
189
+ key: 2,
138
190
  class: "nut-searchbar__search-icon nut-searchbar__right-search-icon"
139
191
  };
140
192
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
@@ -143,35 +195,45 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
143
195
  class: "nut-searchbar",
144
196
  style: normalizeStyle(_ctx.searchbarStyle)
145
197
  }, [
146
- _ctx.$slots.leftout ? (openBlock(), createElementBlock("view", _hoisted_1, [
198
+ _ctx.label ? (openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(_ctx.label), 1)) : createCommentVNode("", true),
199
+ _ctx.$slots.leftout ? (openBlock(), createElementBlock("view", _hoisted_2, [
147
200
  renderSlot(_ctx.$slots, "leftout")
148
201
  ])) : createCommentVNode("", true),
149
202
  createElementVNode("view", {
150
203
  class: "nut-searchbar__search-input",
151
204
  style: normalizeStyle(_ctx.inputSearchbarStyle)
152
205
  }, [
153
- _ctx.$slots.leftin ? (openBlock(), createElementBlock("view", _hoisted_2, [
206
+ _ctx.$slots.leftin ? (openBlock(), createElementBlock("view", {
207
+ key: 0,
208
+ class: "nut-searchbar__search-icon nut-searchbar__iptleft-search-icon",
209
+ onClick: _cache[0] || (_cache[0] = (...args) => _ctx.leftIconClick && _ctx.leftIconClick(...args))
210
+ }, [
154
211
  renderSlot(_ctx.$slots, "leftin")
155
212
  ])) : createCommentVNode("", true),
156
213
  createElementVNode("view", _hoisted_3, [
157
214
  createElementVNode("form", {
158
215
  action: "#",
159
- onSubmit: _cache[3] || (_cache[3] = withModifiers((...args) => _ctx.handleSubmit && _ctx.handleSubmit(...args), ["prevent"]))
216
+ onSubmit: _cache[5] || (_cache[5] = withModifiers((...args) => _ctx.handleSubmit && _ctx.handleSubmit(...args), ["prevent"]))
160
217
  }, [
161
218
  createElementVNode("input", {
219
+ ref: "inputsearch",
162
220
  class: "nut-searchbar__input-bar",
163
221
  type: _ctx.inputType,
164
222
  maxlength: _ctx.maxLength,
165
223
  placeholder: _ctx.placeholder || _ctx.translate("placeholder"),
166
224
  value: _ctx.modelValue,
167
- onInput: _cache[0] || (_cache[0] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
168
- onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
169
- onBlur: _cache[2] || (_cache[2] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args))
170
- }, null, 40, _hoisted_4)
225
+ disabled: _ctx.disabled,
226
+ readonly: _ctx.readonly,
227
+ onClick: _cache[1] || (_cache[1] = (...args) => _ctx.clickInput && _ctx.clickInput(...args)),
228
+ onInput: _cache[2] || (_cache[2] = (...args) => _ctx.valueChange && _ctx.valueChange(...args)),
229
+ onFocus: _cache[3] || (_cache[3] = (...args) => _ctx.valueFocus && _ctx.valueFocus(...args)),
230
+ onBlur: _cache[4] || (_cache[4] = (...args) => _ctx.valueBlur && _ctx.valueBlur(...args)),
231
+ style: normalizeStyle(_ctx.styleSearchbar)
232
+ }, null, 44, _hoisted_4)
171
233
  ], 32),
172
234
  _ctx.clearable ? withDirectives((openBlock(), createElementBlock("view", {
173
235
  key: 0,
174
- onClick: _cache[4] || (_cache[4] = (...args) => _ctx.handleClear && _ctx.handleClear(...args)),
236
+ onClick: _cache[6] || (_cache[6] = (...args) => _ctx.handleClear && _ctx.handleClear(...args)),
175
237
  class: "nut-searchbar__input-clear"
176
238
  }, [
177
239
  createVNode(_component_nut_icon, {
@@ -183,11 +245,15 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
183
245
  [vShow, _ctx.modelValue.length > 0]
184
246
  ]) : createCommentVNode("", true)
185
247
  ]),
186
- _ctx.$slots.rightin ? (openBlock(), createElementBlock("view", _hoisted_5, [
248
+ _ctx.$slots.rightin ? (openBlock(), createElementBlock("view", {
249
+ key: 1,
250
+ class: "nut-searchbar__search-icon nut-searchbar__iptright-sarch-icon",
251
+ onClick: _cache[7] || (_cache[7] = (...args) => _ctx.rightIconClick && _ctx.rightIconClick(...args))
252
+ }, [
187
253
  renderSlot(_ctx.$slots, "rightin")
188
254
  ])) : createCommentVNode("", true)
189
255
  ], 4),
190
- _ctx.$slots.rightout ? (openBlock(), createElementBlock("view", _hoisted_6, [
256
+ _ctx.$slots.rightout ? (openBlock(), createElementBlock("view", _hoisted_5, [
191
257
  renderSlot(_ctx.$slots, "rightout")
192
258
  ])) : createCommentVNode("", true)
193
259
  ], 4);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -497,7 +497,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
497
497
  btnOptions: _ctx.btnOptions,
498
498
  btnExtraText: _ctx.btnExtraText,
499
499
  buyText: _ctx.buyText || _ctx.translate("buyNow"),
500
- addCartText: _ctx.addCartText || _ctx.translate("addToCard"),
500
+ addCartText: _ctx.addCartText || _ctx.translate("addToCart"),
501
501
  confirmText: _ctx.confirmText || _ctx.translate("confirm"),
502
502
  onClickBtnOperate: _ctx.clickBtnOperate
503
503
  }, createSlots({ _: 2 }, [
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */
@@ -1,9 +1,9 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
6
- import { reactive, ref, computed, provide, onMounted, nextTick, onActivated, onDeactivated, onBeforeUnmount, watch, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, renderSlot, Fragment, renderList, createCommentVNode } from "vue";
6
+ import { reactive, ref, computed, provide, onDeactivated, onBeforeUnmount, watch, nextTick, openBlock, createElementBlock, normalizeClass, createElementVNode, normalizeStyle, renderSlot, Fragment, renderList, createCommentVNode } from "vue";
7
7
  import { c as createComponent } from "./component.js";
8
8
  import { u as useExpose } from "./index3.js";
9
9
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
@@ -122,6 +122,7 @@ const _sfc_main = create({
122
122
  touchTime: 0,
123
123
  autoplayTimer: 0,
124
124
  children: [],
125
+ childrenVNode: [],
125
126
  style: {}
126
127
  });
127
128
  const touch = useTouch();
@@ -158,8 +159,35 @@ const _sfc_main = create({
158
159
  };
159
160
  };
160
161
  const relation = (child) => {
161
- if (child.proxy) {
162
- state.children.push(child.proxy);
162
+ var _a;
163
+ let children = [];
164
+ let slot = (_a = slots == null ? void 0 : slots.default) == null ? void 0 : _a.call(slots);
165
+ slot = slot.filter((item) => item.children && Array.isArray(item.children));
166
+ slot.forEach((item) => {
167
+ children = children.concat(item.children);
168
+ });
169
+ if (!state.childrenVNode.length) {
170
+ state.childrenVNode = children.slice();
171
+ child.proxy && state.children.push(child.proxy);
172
+ } else {
173
+ if (state.childrenVNode.length > children.length) {
174
+ state.children = state.children.filter((item) => child.proxy !== item);
175
+ } else if (state.childrenVNode.length < children.length) {
176
+ for (let i = 0; i < state.childrenVNode.length; i++) {
177
+ if (children[i].key !== state.childrenVNode[i].key) {
178
+ child.proxy && state.children.splice(i, 0, child.proxy);
179
+ child.vnode && state.childrenVNode.splice(i, 0, child.vnode);
180
+ break;
181
+ }
182
+ }
183
+ if (state.childrenVNode.length !== children.length) {
184
+ child.proxy && state.children.push(child.proxy);
185
+ child.vnode && state.childrenVNode.push(child.vnode);
186
+ }
187
+ } else {
188
+ state.childrenVNode = children.slice();
189
+ child.proxy && state.children.push(child.proxy);
190
+ }
163
191
  }
164
192
  };
165
193
  const range = (num, min, max) => {
@@ -346,16 +374,6 @@ const _sfc_main = create({
346
374
  next,
347
375
  to
348
376
  });
349
- onMounted(() => {
350
- nextTick(() => {
351
- init();
352
- });
353
- });
354
- onActivated(() => {
355
- nextTick(() => {
356
- init();
357
- });
358
- });
359
377
  onDeactivated(() => {
360
378
  stopAutoPlay();
361
379
  });
@@ -369,7 +387,7 @@ const _sfc_main = create({
369
387
  });
370
388
  watch(() => state.children.length, () => {
371
389
  nextTick(() => {
372
- init(state.active);
390
+ init();
373
391
  });
374
392
  });
375
393
  watch(() => props.autoPlay, (val) => {
@@ -420,8 +438,9 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
420
438
  style: normalizeStyle({
421
439
  backgroundColor: _ctx.activePagination === index ? _ctx.paginationColor : "#ddd"
422
440
  }),
441
+ class: normalizeClass({ active: _ctx.activePagination === index }),
423
442
  key: index
424
- }, null, 4);
443
+ }, null, 6);
425
444
  }), 128))
426
445
  ], 2)) : createCommentVNode("", true)
427
446
  ], 34);
@@ -1,9 +1,9 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
6
- import { inject, getCurrentInstance, reactive, computed, openBlock, createElementBlock, normalizeClass, normalizeStyle, renderSlot } from "vue";
6
+ import { inject, getCurrentInstance, reactive, computed, onUnmounted, openBlock, createElementBlock, normalizeClass, normalizeStyle, renderSlot } from "vue";
7
7
  import { c as createComponent } from "./component.js";
8
8
  import { u as useExpose } from "./index3.js";
9
9
  import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
@@ -36,6 +36,9 @@ const _sfc_main = create({
36
36
  const setOffset = (offset) => {
37
37
  state.offset = offset;
38
38
  };
39
+ onUnmounted(() => {
40
+ parent["relation"](getCurrentInstance(), "unmount");
41
+ });
39
42
  useExpose({ setOffset });
40
43
  return {
41
44
  style,
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -26,12 +26,16 @@ const _sfc_main = create({
26
26
  emits: ["click"],
27
27
  setup(props, { emit }) {
28
28
  const parent = inject("activeKey");
29
- return { activeKey: parent.activeKey };
29
+ const parentOption = inject("autoHeight");
30
+ return {
31
+ activeKey: parent.activeKey,
32
+ autoHeight: parentOption.autoHeight
33
+ };
30
34
  }
31
35
  });
32
36
  function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
33
37
  return openBlock(), createElementBlock("view", {
34
- class: normalizeClass(["nut-tabpane", { active: _ctx.paneKey == _ctx.activeKey }])
38
+ class: normalizeClass(["nut-tabpane", { inactive: _ctx.paneKey != _ctx.activeKey && _ctx.autoHeight }])
35
39
  }, [
36
40
  renderSlot(_ctx.$slots, "default")
37
41
  ], 2);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
2
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
3
3
  * (c) 2022 @jdf2e.
4
4
  * Released under the MIT License.
5
5
  */
@@ -81,6 +81,7 @@ const _sfc_main = create({
81
81
  setTimeout(() => {
82
82
  if (parent.children[value].href) {
83
83
  window.location.href = parent.children[value].href;
84
+ return;
84
85
  }
85
86
  if (parent.children[value].to) {
86
87
  let to = parent.children[value].to;
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
18
18
  };
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  /*!
21
- * @nutui/nutui v3.1.21-beta.2 Mon May 09 2022 11:11:13 GMT+0800 (中国标准时间)
21
+ * @nutui/nutui v3.1.22-beta.0 Tue May 31 2022 21:47:10 GMT+0800 (中国标准时间)
22
22
  * (c) 2022 @jdf2e.
23
23
  * Released under the MIT License.
24
24
  */