@opentiny/vue-docs 2.2.18 → 2.2.20

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 (380) hide show
  1. package/demos/apis/card.js +56 -23
  2. package/demos/apis/dialog-box.js +12 -5
  3. package/demos/apis/fall-menu.js +2 -2
  4. package/demos/apis/file-upload.js +2 -1
  5. package/demos/apis/float-button.js +211 -0
  6. package/demos/apis/grid.js +40 -40
  7. package/demos/apis/ip-address.js +3 -3
  8. package/demos/apis/multi-select.js +141 -22
  9. package/demos/apis/numeric.js +25 -0
  10. package/demos/apis/popeditor.js +20 -14
  11. package/demos/apis/search.js +11 -0
  12. package/demos/apis/slider.js +13 -2
  13. package/demos/apis/steps.js +6 -6
  14. package/demos/apis/tabs.js +39 -0
  15. package/demos/apis/time-line.js +34 -1
  16. package/demos/apis/time-select.js +1 -1
  17. package/demos/apis/tooltip.js +1 -1
  18. package/demos/apis/tree-menu.js +5 -5
  19. package/demos/mobile/app/alert/icon.vue +1 -1
  20. package/demos/mobile/app/alert/size.vue +1 -1
  21. package/demos/mobile/app/alert/slot-default.vue +8 -2
  22. package/demos/mobile/app/exception/buttonText.vue +4 -2
  23. package/demos/mobile/app/exception/exceptionClass.vue +4 -2
  24. package/demos/mobile/app/exception/message.vue +4 -7
  25. package/demos/mobile/app/exception/type.vue +4 -2
  26. package/demos/mobile/app/loading/background.vue +24 -0
  27. package/demos/mobile/app/loading/base.vue +16 -6
  28. package/demos/mobile/app/loading/custom-class.vue +29 -0
  29. package/demos/mobile/app/loading/global-registry.vue +61 -0
  30. package/demos/mobile/app/loading/size.vue +59 -0
  31. package/demos/mobile/app/loading/spinner.vue +26 -0
  32. package/demos/mobile/app/loading/tip-text.vue +23 -0
  33. package/demos/mobile/app/loading/webdoc/loading.js +155 -9
  34. package/demos/mobile/app/multi-select/basic-usage.vue +221 -73
  35. package/demos/mobile/app/multi-select/disabled.vue +174 -206
  36. package/demos/mobile/app/multi-select/event-click-item.vue +60 -75
  37. package/demos/mobile/app/multi-select/filter.vue +65 -93
  38. package/demos/mobile/app/multi-select/mask.vue +60 -0
  39. package/demos/mobile/app/multi-select/slots.vue +66 -0
  40. package/demos/mobile/app/multi-select/type-wheel.vue +39 -49
  41. package/demos/mobile/app/multi-select/webdoc/multi-select.js +49 -10
  42. package/demos/mobile/app/popover/base.vue +2 -3
  43. package/demos/mobile/app/search/base.vue +2 -2
  44. package/demos/mobile/app/user-head/basic-usage.vue +2 -5
  45. package/demos/mobile-first/app/card/basic-usage.vue +4 -2
  46. package/demos/mobile-first/app/card/card-type.vue +6 -12
  47. package/demos/mobile-first/app/card/slot.vue +2 -5
  48. package/demos/mobile-first/app/carousel/close-loop.vue +12 -4
  49. package/demos/mobile-first/app/column-list-item/basic-usage.vue +3 -7
  50. package/demos/mobile-first/app/column-list-item/custom-width.vue +4 -7
  51. package/demos/mobile-first/app/column-list-item/icon-click-event.vue +2 -5
  52. package/demos/mobile-first/app/column-list-item/icon-disabled.vue +2 -5
  53. package/demos/mobile-first/app/column-list-item/size.vue +3 -6
  54. package/demos/mobile-first/app/select/filter-method.vue +47 -18
  55. package/demos/mobile-first/app/time-line/limited-nodes.vue +29 -0
  56. package/demos/mobile-first/app/time-line/node-max.vue +26 -0
  57. package/demos/mobile-first/app/time-line/webdoc/time-line.js +26 -1
  58. package/demos/pc/app/alert/custom-close-composition-api.vue +7 -2
  59. package/demos/pc/app/alert/custom-close.spec.ts +1 -1
  60. package/demos/pc/app/alert/custom-close.vue +7 -2
  61. package/demos/pc/app/area/custom-service.spec.ts +1 -2
  62. package/demos/pc/app/button/ghost-composition-api.vue +6 -6
  63. package/demos/pc/app/button/ghost.spec.ts +19 -12
  64. package/demos/pc/app/button/ghost.vue +6 -6
  65. package/demos/pc/app/card/basic-usage-composition-api.vue +24 -0
  66. package/demos/pc/app/card/basic-usage.vue +32 -0
  67. package/demos/pc/app/card/card-disabled-composition-api.vue +45 -0
  68. package/demos/pc/app/card/card-disabled.vue +53 -0
  69. package/demos/pc/app/card/card-events-composition-api.vue +66 -0
  70. package/demos/pc/app/card/card-events.vue +75 -0
  71. package/demos/pc/app/card/card-group-composition-api.vue +69 -0
  72. package/demos/pc/app/card/card-group.vue +79 -0
  73. package/demos/pc/app/card/card-size-composition-api.vue +59 -0
  74. package/demos/pc/app/card/card-size.vue +67 -0
  75. package/demos/pc/app/card/card-status-composition-api.vue +49 -0
  76. package/demos/pc/app/card/card-status.vue +58 -0
  77. package/demos/pc/app/card/card-type-composition-api.vue +47 -0
  78. package/demos/pc/app/card/card-type.vue +55 -0
  79. package/demos/pc/app/card/check-type-checkbox-composition-api.vue +31 -0
  80. package/demos/pc/app/card/check-type-checkbox.vue +40 -0
  81. package/demos/pc/app/card/check-type-radio-composition-api.vue +31 -0
  82. package/demos/pc/app/card/check-type-radio.vue +39 -0
  83. package/demos/pc/app/card/custom-class-composition-api.vue +51 -0
  84. package/demos/pc/app/card/custom-class.vue +59 -0
  85. package/demos/pc/app/card/operate-bar-composition-api.vue +53 -0
  86. package/demos/pc/app/card/operate-bar.vue +60 -0
  87. package/demos/pc/app/card/slot-composition-api.vue +67 -0
  88. package/demos/pc/app/card/slot.vue +76 -0
  89. package/demos/pc/app/card/webdoc/card.cn.md +7 -0
  90. package/demos/pc/app/card/webdoc/card.en.md +7 -0
  91. package/demos/pc/app/card/webdoc/card.js +148 -0
  92. package/demos/pc/app/carousel/basic-usage.spec.ts +3 -3
  93. package/demos/pc/app/carousel/card-mode.spec.ts +4 -11
  94. package/demos/pc/app/carousel/carousel-arrow-hover.spec.ts +5 -7
  95. package/demos/pc/app/carousel/carousel-events.spec.ts +7 -16
  96. package/demos/pc/app/carousel/manual-play.spec.ts +0 -2
  97. package/demos/pc/app/carousel/play-interval.spec.ts +1 -4
  98. package/demos/pc/app/cascader/auto-load-checkStrictly.spec.ts +1 -1
  99. package/demos/pc/app/cascader/auto-load.spec.ts +5 -2
  100. package/demos/pc/app/color-picker/base.spec.ts +2 -2
  101. package/demos/pc/app/color-picker/event.spec.ts +1 -1
  102. package/demos/pc/app/color-picker/history.spec.ts +2 -6
  103. package/demos/pc/app/color-picker/predefine.spec.ts +2 -5
  104. package/demos/pc/app/company/basic-usage.spec.ts +3 -6
  105. package/demos/pc/app/company/custom-service.spec.ts +4 -8
  106. package/demos/pc/app/country/custom-service.spec.js +4 -4
  107. package/demos/pc/app/country/fields.spec.js +2 -2
  108. package/demos/pc/app/crop/aspect-ratio.spec.ts +1 -2
  109. package/demos/pc/app/crop/auto-crop-area.spec.ts +1 -4
  110. package/demos/pc/app/crop/basic-usage.spec.ts +0 -2
  111. package/demos/pc/app/crop/crop-meth.spec.ts +0 -2
  112. package/demos/pc/app/crop/event-ready.spec.ts +0 -1
  113. package/demos/pc/app/crop/get-container-data.spec.ts +0 -1
  114. package/demos/pc/app/crop/get-crop-box-data.spec.ts +0 -2
  115. package/demos/pc/app/crop/get-data.spec.ts +0 -1
  116. package/demos/pc/app/crop/min-crop-box-width-height.spec.ts +0 -2
  117. package/demos/pc/app/crop/no-background.spec.ts +0 -1
  118. package/demos/pc/app/crop/no-modal.spec.ts +0 -2
  119. package/demos/pc/app/crop/replace-image.spec.ts +4 -5
  120. package/demos/pc/app/crop/view-mode.spec.ts +1 -16
  121. package/demos/pc/app/date-picker/align.spec.ts +17 -14
  122. package/demos/pc/app/date-picker/basic-usage.spec.ts +17 -22
  123. package/demos/pc/app/date-picker/clear.spec.ts +13 -7
  124. package/demos/pc/app/date-picker/date-range.spec.ts +39 -10
  125. package/demos/pc/app/date-picker/events.spec.ts +11 -3
  126. package/demos/pc/app/date-picker/format.spec.ts +2 -2
  127. package/demos/pc/app/date-picker/shortcuts.spec.ts +1 -2
  128. package/demos/pc/app/dept/custom-service.spec.ts +16 -4
  129. package/demos/pc/app/detail-page/basic-usage.spec.ts +4 -4
  130. package/demos/pc/app/dialog-box/basic-usage-composition-api.vue +1 -1
  131. package/demos/pc/app/dialog-box/basic-usage.vue +1 -1
  132. package/demos/pc/app/dialog-box/center-composition-api.vue +1 -1
  133. package/demos/pc/app/dialog-box/center.vue +1 -1
  134. package/demos/pc/app/dialog-box/close-on-click-modal-composition-api.vue +1 -1
  135. package/demos/pc/app/dialog-box/close-on-click-modal.vue +1 -1
  136. package/demos/pc/app/dialog-box/close-on-press-escape-composition-api.vue +1 -1
  137. package/demos/pc/app/dialog-box/close-on-press-escape.vue +1 -1
  138. package/demos/pc/app/dialog-box/custom-dialog-content-composition-api.vue +1 -1
  139. package/demos/pc/app/dialog-box/custom-dialog-content.vue +1 -1
  140. package/demos/pc/app/dialog-box/custom-dialog-footer-composition-api.vue +2 -2
  141. package/demos/pc/app/dialog-box/custom-dialog-footer.spec.ts +1 -1
  142. package/demos/pc/app/dialog-box/custom-dialog-title-composition-api.vue +2 -2
  143. package/demos/pc/app/dialog-box/custom-dialog-title.spec.ts +1 -1
  144. package/demos/pc/app/dialog-box/custom-dialog-title.vue +2 -2
  145. package/demos/pc/app/dialog-box/dialog-top-height-composition-api.vue +2 -2
  146. package/demos/pc/app/dialog-box/dialog-top-height.vue +2 -2
  147. package/demos/pc/app/dialog-box/dialog-width-composition-api.vue +2 -2
  148. package/demos/pc/app/dialog-box/dialog-width.vue +2 -2
  149. package/demos/pc/app/dialog-box/draggable-composition-api.vue +15 -3
  150. package/demos/pc/app/dialog-box/draggable.spec.ts +2 -2
  151. package/demos/pc/app/dialog-box/draggable.vue +15 -3
  152. package/demos/pc/app/dialog-box/form-in-dialog.spec.ts +0 -1
  153. package/demos/pc/app/dialog-box/open-close-events-composition-api.vue +1 -1
  154. package/demos/pc/app/dialog-box/open-close-events.vue +1 -1
  155. package/demos/pc/app/dialog-box/webdoc/dialog-box.js +2 -2
  156. package/demos/pc/app/drawer/tips-props-composition-api.vue +23 -0
  157. package/demos/pc/app/drawer/tips-props.spec.ts +15 -0
  158. package/demos/pc/app/drawer/tips-props.vue +33 -0
  159. package/demos/pc/app/drawer/webdoc/drawer.js +10 -12
  160. package/demos/pc/app/drop-roles/custom-service.spec.ts +1 -1
  161. package/demos/pc/app/file-upload/custom-prefix.spec.ts +1 -1
  162. package/demos/pc/app/file-upload/file-picture-card.spec.ts +1 -1
  163. package/demos/pc/app/file-upload/manual-upload.spec.ts +1 -1
  164. package/demos/pc/app/file-upload/picture-card.spec.ts +3 -2
  165. package/demos/pc/app/file-upload/picture-list.spec.ts +3 -3
  166. package/demos/pc/app/file-upload/upload-file-list.spec.ts +1 -1
  167. package/demos/pc/app/file-upload/upload-request.spec.ts +11 -6
  168. package/demos/pc/app/float-button/backTop-composition-api.vue +40 -0
  169. package/demos/pc/app/float-button/backTop.vue +51 -0
  170. package/demos/pc/app/float-button/basic-usage-composition-api.vue +39 -0
  171. package/demos/pc/app/float-button/basic-usage.vue +48 -0
  172. package/demos/pc/app/float-button/icon-composition-api.vue +21 -0
  173. package/demos/pc/app/float-button/icon.vue +31 -0
  174. package/demos/pc/app/float-button/jump-composition-api.vue +19 -0
  175. package/demos/pc/app/float-button/jump.vue +26 -0
  176. package/demos/pc/app/float-button/reset-time-composition-api.vue +22 -0
  177. package/demos/pc/app/float-button/reset-time.vue +26 -0
  178. package/demos/pc/app/float-button/trigger-composition-api.vue +31 -0
  179. package/demos/pc/app/float-button/trigger.vue +40 -0
  180. package/demos/pc/app/float-button/webdoc/float-button.cn.md +7 -0
  181. package/demos/pc/app/float-button/webdoc/float-button.en.md +7 -0
  182. package/demos/pc/app/float-button/webdoc/float-button.js +68 -0
  183. package/demos/pc/app/floatbar/base.spec.ts +1 -1
  184. package/demos/pc/app/floatbar/custom-floatbar-item.spec.ts +1 -1
  185. package/demos/pc/app/floatbar/custom-style.spec.ts +1 -1
  186. package/demos/pc/app/floatbar/operation-floatbar-item.spec.ts +1 -1
  187. package/demos/pc/app/form/form-row-col.spec.js +2 -0
  188. package/demos/pc/app/form/label-position.spec.ts +3 -3
  189. package/demos/pc/app/grid/custom/ordercolumn-local.spec.js +2 -2
  190. package/demos/pc/app/grid/data-source/static-data-composition-api.vue +1 -1
  191. package/demos/pc/app/grid/data-source/static-data.spec.js +1 -1
  192. package/demos/pc/app/grid/data-source/static-data.vue +1 -1
  193. package/demos/pc/app/grid/edit/grid-equals-composition-api.vue +50 -0
  194. package/demos/pc/app/grid/edit/grid-equals.spec.js +10 -0
  195. package/demos/pc/app/grid/edit/grid-equals.vue +60 -0
  196. package/demos/pc/app/grid/edit/has-row-change.spec.js +2 -2
  197. package/demos/pc/app/grid/edit/trigger-mode-hm-editing-composition-api.vue +11 -11
  198. package/demos/pc/app/grid/editor/mutil-render.spec.js +1 -1
  199. package/demos/pc/app/grid/event/get-row-method.spec.js +4 -4
  200. package/demos/pc/app/grid/filter/server-filter.spec.js +1 -1
  201. package/demos/pc/app/grid/fixed/left-fixed.vue +1 -1
  202. package/demos/pc/app/grid/large-data/column-anchor.vue +132 -0
  203. package/demos/pc/app/grid/large-data/scroll-to.spec.js +1 -1
  204. package/demos/pc/app/grid/loading/grid-loading-tip.spec.js +1 -1
  205. package/demos/pc/app/grid/pager/show-save-msg-composition-api.vue +1 -1
  206. package/demos/pc/app/grid/pager/show-save-msg.vue +1 -1
  207. package/demos/pc/app/grid/renderer/inner-renderer-date-composition-api.vue +40 -0
  208. package/demos/pc/app/grid/renderer/inner-renderer-date.spec.js +9 -0
  209. package/demos/pc/app/grid/renderer/inner-renderer-date.vue +50 -0
  210. package/demos/pc/app/grid/size/grid-size-composition-api.vue +33 -26
  211. package/demos/pc/app/grid/size/grid-size.spec.js +7 -3
  212. package/demos/pc/app/grid/size/grid-size.vue +34 -26
  213. package/demos/pc/app/grid/sort/sort.vue +0 -1
  214. package/demos/pc/app/grid/toolbar/grid-full-screen-teleport-composition-api.vue +65 -0
  215. package/demos/pc/app/grid/toolbar/grid-full-screen-teleport.spec.js +10 -0
  216. package/demos/pc/app/grid/toolbar/grid-full-screen-teleport.vue +73 -0
  217. package/demos/pc/app/grid/tree-table/tree-grid-insert-delete-update.spec.js +1 -1
  218. package/demos/pc/app/grid/validation/before-submit-validation.spec.js +1 -1
  219. package/demos/pc/app/grid/webdoc/grid-custom-style.js +1 -1
  220. package/demos/pc/app/grid/webdoc/grid-edit.js +11 -0
  221. package/demos/pc/app/grid/webdoc/grid-editor.js +1 -1
  222. package/demos/pc/app/grid/webdoc/grid-large-data.js +1 -49
  223. package/demos/pc/app/grid/webdoc/grid-renderer.js +11 -0
  224. package/demos/pc/app/grid/webdoc/grid-toolbar.js +11 -2
  225. package/demos/pc/app/guide/basic-usage.spec.ts +3 -2
  226. package/demos/pc/app/guide/offset.spec.ts +3 -1
  227. package/demos/pc/app/hrapprover/basic-usage.spec.ts +2 -6
  228. package/demos/pc/app/hrapprover/custom-service.spec.ts +5 -2
  229. package/demos/pc/app/hrapprover/disabled.spec.ts +1 -1
  230. package/demos/pc/app/ip-address/delimiter.spec.ts +1 -1
  231. package/demos/pc/app/loading/webdoc/loading.js +1 -1
  232. package/demos/pc/app/locales/custom-service.spec.ts +0 -3
  233. package/demos/pc/app/logout/basic-usage.spec.ts +5 -5
  234. package/demos/pc/app/milestone/show-number.spec.ts +1 -1
  235. package/demos/pc/app/milestone/solid-style.spec.ts +1 -1
  236. package/demos/pc/app/modal/basic-usage.spec.ts +1 -1
  237. package/demos/pc/app/modal/duration.spec.ts +1 -2
  238. package/demos/pc/app/modal/{min-width-composition-api.vue → min-width-height-composition-api.vue} +4 -2
  239. package/demos/pc/app/modal/{min-width.spec.ts → min-width-height.spec.ts} +3 -3
  240. package/demos/pc/app/modal/{min-width.vue → min-width-height.vue} +4 -2
  241. package/demos/pc/app/modal/prop-slots-composition-api.vue +2 -2
  242. package/demos/pc/app/modal/show-header-footer-composition-api.vue +11 -0
  243. package/demos/pc/app/modal/{showHeader.spec.ts → show-header-footer.spec.ts} +3 -3
  244. package/demos/pc/app/modal/{showHeader.vue → show-header-footer.vue} +2 -2
  245. package/demos/pc/app/modal/webdoc/modal.js +12 -36
  246. package/demos/pc/app/notify/closeIcon.spec.ts +1 -1
  247. package/demos/pc/app/numeric/change-event-composition-api.vue +9 -2
  248. package/demos/pc/app/numeric/change-event.vue +10 -3
  249. package/demos/pc/app/numeric/dynamic-disabled-composition-api.vue +10 -2
  250. package/demos/pc/app/numeric/dynamic-disabled.spec.ts +1 -1
  251. package/demos/pc/app/numeric/dynamic-disabled.vue +11 -3
  252. package/demos/pc/app/numeric/mouse-wheel.spec.ts +2 -2
  253. package/demos/pc/app/numeric/precision-composition-api.vue +1 -1
  254. package/demos/pc/app/numeric/precision.spec.ts +10 -11
  255. package/demos/pc/app/numeric/string-mode-composition-api.vue +10 -0
  256. package/demos/pc/app/numeric/string-mode.spec.ts +17 -0
  257. package/demos/pc/app/numeric/string-mode.vue +19 -0
  258. package/demos/pc/app/numeric/webdoc/numeric.js +13 -0
  259. package/demos/pc/app/pager/before-page-change.spec.ts +1 -1
  260. package/demos/pc/app/pager/disabled-and-size.spec.ts +1 -1
  261. package/demos/pc/app/pop-upload/basic-usage.spec.ts +1 -1
  262. package/demos/pc/app/pop-upload/custom-request-headers.spec.ts +1 -1
  263. package/demos/pc/app/popeditor/condition-form-composition-api.vue +0 -1
  264. package/demos/pc/app/popeditor/condition-form.vue +0 -1
  265. package/demos/pc/app/popeditor/events-composition-api.vue +8 -2
  266. package/demos/pc/app/popeditor/events.vue +8 -2
  267. package/demos/pc/app/popeditor/webdoc/popeditor.js +9 -9
  268. package/demos/pc/app/popover/webdoc/popover.js +69 -28
  269. package/demos/pc/app/radio/group-options-composition-api.vue +1 -1
  270. package/demos/pc/app/rate/custom-3-threshold-colors.spec.js +0 -13
  271. package/demos/pc/app/rate/custom-3-threshold-icon.spec.js +5 -5
  272. package/demos/pc/app/rate/disabled-not-selected-class.spec.js +1 -1
  273. package/demos/pc/app/rate/not-selected-class.spec.js +1 -1
  274. package/demos/pc/app/rate/threshold-value.spec.js +0 -13
  275. package/demos/pc/app/search/basic-usage-composition-api.vue +1 -1
  276. package/demos/pc/app/search/basic-usage.vue +1 -1
  277. package/demos/pc/app/search/webdoc/search.js +3 -2
  278. package/demos/pc/app/select/copy-multi.spec.ts +6 -5
  279. package/demos/pc/app/select/copy-single.spec.ts +7 -4
  280. package/demos/pc/app/select/disabled-composition-api.vue +2 -2
  281. package/demos/pc/app/select/disabled.spec.ts +3 -3
  282. package/demos/pc/app/select/disabled.vue +2 -2
  283. package/demos/pc/app/select/events.spec.ts +3 -3
  284. package/demos/pc/app/select/multiple.vue +1 -1
  285. package/demos/pc/app/select/optimization.spec.ts +3 -7
  286. package/demos/pc/app/select/option-group-composition-api.vue +2 -2
  287. package/demos/pc/app/select/option-group.vue +2 -2
  288. package/demos/pc/app/select/searchable.spec.ts +1 -1
  289. package/demos/pc/app/select/size.spec.ts +1 -1
  290. package/demos/pc/app/select/tag-type-composition-api.vue +1 -1
  291. package/demos/pc/app/select/tag-type.spec.ts +1 -1
  292. package/demos/pc/app/select/tag-type.vue +1 -1
  293. package/demos/pc/app/slide-bar/basic-usage.spec.ts +0 -5
  294. package/demos/pc/app/slide-bar/wheel-blocks.spec.ts +2 -6
  295. package/demos/pc/app/slider/marks-composition-api.vue +20 -0
  296. package/demos/pc/app/slider/marks.spec.ts +12 -0
  297. package/demos/pc/app/slider/marks.vue +27 -0
  298. package/demos/pc/app/slider/show-input-composition-api.vue +2 -0
  299. package/demos/pc/app/slider/show-input.vue +3 -1
  300. package/demos/pc/app/slider/show-iput.spec.ts +14 -4
  301. package/demos/pc/app/slider/webdoc/slider.js +12 -0
  302. package/demos/pc/app/steps/advanced-steps-composition-api.vue +2 -2
  303. package/demos/pc/app/steps/advanced-steps.spec.ts +3 -3
  304. package/demos/pc/app/steps/advanced-steps.vue +2 -2
  305. package/demos/pc/app/steps/click-composition-api.vue +3 -10
  306. package/demos/pc/app/steps/click.vue +4 -12
  307. package/demos/pc/app/steps/line-horizontal-composition-api.vue +1 -1
  308. package/demos/pc/app/steps/line-horizontal.vue +1 -1
  309. package/demos/pc/app/steps/line-vertical-composition-api.vue +1 -1
  310. package/demos/pc/app/steps/line-vertical.vue +1 -1
  311. package/demos/pc/app/tabs/overflow-title-composition-api.vue +19 -0
  312. package/demos/pc/app/tabs/overflow-title.vue +28 -0
  313. package/demos/pc/app/tabs/tabs-events-close-composition-api.vue +5 -1
  314. package/demos/pc/app/tabs/tabs-events-close.spec.ts +1 -1
  315. package/demos/pc/app/tabs/tabs-events-close.vue +5 -1
  316. package/demos/pc/app/tabs/webdoc/tabs.js +18 -4
  317. package/demos/pc/app/tag/delete.spec.ts +3 -3
  318. package/demos/pc/app/time-line/shape-composition-api.vue +5 -2
  319. package/demos/pc/app/time-line/shape.spec.ts +2 -0
  320. package/demos/pc/app/time-line/shape.vue +5 -1
  321. package/demos/pc/app/time-line/show-divider-composition-api.vue +1 -1
  322. package/demos/pc/app/time-line/show-divider.vue +1 -1
  323. package/demos/pc/app/time-picker/disabled.spec.ts +9 -1
  324. package/demos/pc/app/time-picker/event.spec.ts +1 -2
  325. package/demos/pc/app/time-picker/format.spec.ts +10 -3
  326. package/demos/pc/app/time-picker/step.spec.ts +4 -1
  327. package/demos/pc/app/time-select/basic-usage.spec.ts +1 -1
  328. package/demos/pc/app/time-select/clear-icon.spec.ts +1 -1
  329. package/demos/pc/app/time-select/default-value.spec.ts +1 -1
  330. package/demos/pc/app/time-select/event-blur-composition-api.vue +3 -3
  331. package/demos/pc/app/time-select/event-blur.spec.ts +1 -1
  332. package/demos/pc/app/time-select/event-blur.vue +3 -3
  333. package/demos/pc/app/time-select/focus-composition-api.vue +1 -1
  334. package/demos/pc/app/time-select/focus.spec.ts +2 -3
  335. package/demos/pc/app/time-select/focus.vue +1 -1
  336. package/demos/pc/app/time-select/range-placeholder.spec.ts +2 -2
  337. package/demos/pc/app/tooltip/theme-composition-api.vue +28 -26
  338. package/demos/pc/app/tooltip/theme.vue +28 -26
  339. package/demos/pc/app/tooltip/webdoc/tooltip.js +55 -29
  340. package/demos/pc/app/transfer/webdoc/transfer.js +130 -44
  341. package/demos/pc/app/tree/webdoc/tree.js +319 -68
  342. package/demos/pc/app/tree-menu/basic-usage.spec.ts +0 -1
  343. package/demos/pc/app/tree-menu/props.spec.ts +2 -1
  344. package/demos/pc/app/user/custom-service.spec.ts +1 -1
  345. package/demos/pc/app/user-account/custom-service.spec.ts +2 -8
  346. package/demos/pc/app/user-contact/contact-espace-composition-api.vue +1 -0
  347. package/demos/pc/app/user-link/custom-service.spec.ts +2 -2
  348. package/demos/pc/app/watermark/webdoc/watermark.js +1 -1
  349. package/demos/pc/menus.js +2 -1
  350. package/demos/pc/resource/newVars.json +2 -2
  351. package/demos/pc/webdoc/changelog.md +139 -0
  352. package/demos/pc/webdoc/import-components-en.md +40 -2
  353. package/demos/pc/webdoc/import-components.md +40 -2
  354. package/package.json +11 -11
  355. package/playground/App.vue +2 -2
  356. package/src/App.vue +3 -2
  357. package/src/const.ts +27 -0
  358. package/src/router.js +5 -3
  359. package/src/tools/useTheme.js +60 -50
  360. package/src/views/components/components.vue +12 -33
  361. package/src/views/components/demo.vue +4 -4
  362. package/src/views/layout/layout.vue +6 -6
  363. package/src/views/overview.vue +6 -3
  364. package/demos/pc/app/credit-card-form/background-image.spec.ts +0 -10
  365. package/demos/pc/app/credit-card-form/basic-usage.spec.ts +0 -13
  366. package/demos/pc/app/credit-card-form/credit-card-form-events.spec.ts +0 -18
  367. package/demos/pc/app/drawer/default-slot-composition-api.vue +0 -25
  368. package/demos/pc/app/drawer/default-slot.spec.ts +0 -11
  369. package/demos/pc/app/drawer/default-slot.vue +0 -35
  370. package/demos/pc/app/font/Font-usage-specifications.spec.js +0 -41
  371. package/demos/pc/app/font/chinese-font-set.spec.js +0 -10
  372. package/demos/pc/app/font/english-fonts.spec.js +0 -10
  373. package/demos/pc/app/hrapprover/category-type.spec.ts +0 -13
  374. package/demos/pc/app/modal/min-height-composition-api.vue +0 -16
  375. package/demos/pc/app/modal/min-height.spec.ts +0 -21
  376. package/demos/pc/app/modal/min-height.vue +0 -23
  377. package/demos/pc/app/modal/showFooter-composition-api.vue +0 -11
  378. package/demos/pc/app/modal/showFooter.spec.ts +0 -10
  379. package/demos/pc/app/modal/showFooter.vue +0 -18
  380. package/demos/pc/app/modal/showHeader-composition-api.vue +0 -11
@@ -16,13 +16,13 @@ test('图片列表缩略图', async ({ page }) => {
16
16
  const path = require('node:path')
17
17
  const currentPath = path.resolve(__dirname, '测试.jpg')
18
18
 
19
- await expect(width).toBeGreaterThanOrEqual(700)
19
+ await expect(width).toBeGreaterThanOrEqual(height)
20
20
  await expect(height).toBeGreaterThanOrEqual(56)
21
21
  await expect(lists).toHaveCount(2)
22
22
  await fileChooser.setFiles(currentPath)
23
23
  await expect(images.nth(0)).toHaveCSS('width', '56px')
24
24
  await expect(images.nth(0)).toHaveCSS('height', '56px')
25
- await expect(images.nth(0)).toHaveAttribute('src', '/static/images/fruit.jpg')
26
- await expect(images.nth(1)).toHaveAttribute('src', '/static/images/book.jpg')
25
+ await expect(images.nth(0)).toHaveAttribute('src', /\/fruit.jpg/)
26
+ await expect(images.nth(1)).toHaveAttribute('src', /\/book.jpg/)
27
27
  await expect(triangles.nth(0)).toHaveCSS('transform', 'matrix(0.707107, 0.707107, -0.707107, 0.707107, 0, 0)')
28
28
  })
@@ -13,7 +13,7 @@ test('文件列表', async ({ page }) => {
13
13
  const path = require('node:path')
14
14
  const currentPath = path.resolve(__dirname, '测试.jpg')
15
15
 
16
- await expect(width).toBeGreaterThanOrEqual(700)
16
+ await expect(width).toBeGreaterThanOrEqual(height)
17
17
  await expect(height).toBeGreaterThanOrEqual(25, 0)
18
18
  await expect(items).toHaveCount(2)
19
19
  await expect(items).toHaveText([/test1/, /test2/])
@@ -10,8 +10,11 @@ test.describe('设置上传请求', () => {
10
10
 
11
11
  const upload = page.getByRole('button', { name: '选取文件' })
12
12
  const [fileChooser] = await Promise.all([page.waitForEvent('filechooser'), upload.click()])
13
- const [request] = await Promise.all([page.waitForEvent('requestfailed'), fileChooser.setFiles(path1)])
14
- await expect(request.url()).toEqual('http://localhost:3000/api/upload')
13
+ await fileChooser.setFiles(path1)
14
+ page.on('requestfailed', (request) => {
15
+ expect(request.url()).toEqual('http://localhost:3000/api/upload')
16
+ })
17
+ await page.waitForTimeout(200)
15
18
  })
16
19
 
17
20
  test('支持发送 cookie 凭证信息', async ({ page }) => {
@@ -20,10 +23,12 @@ test.describe('设置上传请求', () => {
20
23
 
21
24
  const upload = page.getByRole('button', { name: '选取文件' })
22
25
  const [fileChooser] = await Promise.all([page.waitForEvent('filechooser'), upload.click()])
23
- const [request] = await Promise.all([page.waitForEvent('requestfailed'), fileChooser.setFiles(path1)])
24
- const { authorization } = await request.headers()
26
+ await fileChooser.setFiles(path1)
27
+ page.on('requestfailed', (request) => {
28
+ const { authorization } = request.headers()
25
29
 
26
- await expect(request.headers()).not.toBeNull()
27
- await expect(authorization).toEqual('Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==')
30
+ expect(request.headers()).not.toBeNull()
31
+ expect(authorization).toEqual('Basic QWxhZGRpbjpvcGVuIHNlc2FtZQ==')
32
+ })
28
33
  })
29
34
  })
@@ -0,0 +1,40 @@
1
+ <template>
2
+ <div class="parent" ref="dom">
3
+ <div class="child"></div>
4
+ <tiny-float-button
5
+ :back-top="true"
6
+ :visibility-height="199"
7
+ bottom="-200px"
8
+ right="0"
9
+ trigger=""
10
+ :element="dom"
11
+ :icon="IconDel"
12
+ >
13
+ </tiny-float-button>
14
+ </div>
15
+ </template>
16
+
17
+ <script setup>
18
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
19
+ import { iconDel } from '@opentiny/vue-icon'
20
+ import { ref } from 'vue'
21
+
22
+ const IconDel = iconDel()
23
+ const dom = ref(null)
24
+ </script>
25
+
26
+ <style scoped>
27
+ .parent {
28
+ position: relative;
29
+ height: 100px;
30
+ overflow-y: scroll;
31
+ }
32
+
33
+ .child {
34
+ margin-top: 300px;
35
+ }
36
+
37
+ .tiny-float-button {
38
+ position: absolute;
39
+ }
40
+ </style>
@@ -0,0 +1,51 @@
1
+ <template>
2
+ <div class="parent" ref="dom">
3
+ <div class="child"></div>
4
+ <tiny-float-button
5
+ :back-top="true"
6
+ :visibility-height="199"
7
+ bottom="-200px"
8
+ right="0"
9
+ trigger=""
10
+ :element="dom"
11
+ :icon="IconDel"
12
+ >
13
+ </tiny-float-button>
14
+ </div>
15
+ </template>
16
+
17
+ <script>
18
+ import { iconDel } from '@opentiny/vue-icon'
19
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
20
+
21
+ export default {
22
+ components: {
23
+ TinyFloatButton
24
+ },
25
+ data() {
26
+ return {
27
+ dom: null,
28
+ IconDel: iconDel()
29
+ }
30
+ },
31
+ created() {
32
+ this.dom = this.$refs.dom
33
+ }
34
+ }
35
+ </script>
36
+
37
+ <style scoped>
38
+ .parent {
39
+ position: relative;
40
+ height: 100px;
41
+ overflow-y: scroll;
42
+ }
43
+
44
+ .child {
45
+ margin-top: 300px;
46
+ }
47
+
48
+ .tiny-float-button {
49
+ position: absolute;
50
+ }
51
+ </style>
@@ -0,0 +1,39 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button :icon="IconSearch" circle bottom="20px"></tiny-float-button>
4
+ <tiny-float-button
5
+ type="primary"
6
+ :icon="IconEdit"
7
+ circle
8
+ bottom="20px"
9
+ right="60px"
10
+ shape="square"
11
+ ></tiny-float-button>
12
+
13
+ <tiny-float-button type="info" :icon="IconMail" circle bottom="20px" right="100px "></tiny-float-button>
14
+ <tiny-float-button type="warning" :icon="IconStarO" circle bottom="20px" right="140px"></tiny-float-button>
15
+ <tiny-float-button type="danger" :icon="IconDel" circle bottom="20px" right="180px"></tiny-float-button>
16
+ </div>
17
+ </template>
18
+
19
+ <script setup>
20
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
21
+ import { iconDel, iconEdit, iconMail, iconStarO, iconSearch } from '@opentiny/vue-icon'
22
+
23
+ const IconDel = iconDel()
24
+ const IconEdit = iconEdit()
25
+ const IconMail = iconMail()
26
+ const IconStarO = iconStarO()
27
+ const IconSearch = iconSearch()
28
+ </script>
29
+
30
+ <style scoped>
31
+ .parent {
32
+ position: relative;
33
+ height: 100px;
34
+ }
35
+
36
+ .tiny-float-button {
37
+ position: absolute;
38
+ }
39
+ </style>
@@ -0,0 +1,48 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button :icon="IconSearch" circle bottom="20px"></tiny-float-button>
4
+ <tiny-float-button
5
+ type="primary"
6
+ :icon="IconEdit"
7
+ circle
8
+ bottom="20px"
9
+ right="60px"
10
+ shape="square"
11
+ ></tiny-float-button>
12
+
13
+ <tiny-float-button type="info" :icon="IconMail" circle bottom="20px" right="100px "></tiny-float-button>
14
+ <tiny-float-button type="warning" :icon="IconStarO" circle bottom="20px" right="140px"></tiny-float-button>
15
+ <tiny-float-button type="danger" :icon="IconDel" circle bottom="20px" right="180px"></tiny-float-button>
16
+ </div>
17
+ </template>
18
+
19
+ <script>
20
+ import { FloatButton } from '@opentiny/vue'
21
+ import { IconDel, IconEdit, IconMail, IconStarO, IconSearch } from '@opentiny/vue-icon'
22
+
23
+ export default {
24
+ components: {
25
+ TinyFloatButton: FloatButton
26
+ },
27
+ data() {
28
+ return {
29
+ IconDel: IconDel(),
30
+ IconEdit: IconEdit(),
31
+ IconMail: IconMail(),
32
+ IconStarO: IconStarO(),
33
+ IconSearch: IconSearch()
34
+ }
35
+ }
36
+ }
37
+ </script>
38
+
39
+ <style scoped>
40
+ .parent {
41
+ position: relative;
42
+ height: 100px;
43
+ }
44
+
45
+ .tiny-float-button {
46
+ position: absolute;
47
+ }
48
+ </style>
@@ -0,0 +1,21 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button bottom="-15px" right="100px" trigger="" :icon="IconDel"> </tiny-float-button>
4
+ </div>
5
+ </template>
6
+
7
+ <script setup>
8
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
9
+ import { iconDel } from '@opentiny/vue-icon'
10
+
11
+ const IconDel = iconDel()
12
+ </script>
13
+
14
+ <style scoped>
15
+ .parent {
16
+ position: relative;
17
+ }
18
+ .tiny-float-button {
19
+ position: absolute;
20
+ }
21
+ </style>
@@ -0,0 +1,31 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button bottom="-15px" right="100px" trigger="" :icon="IconDel"> </tiny-float-button>
4
+ </div>
5
+ </template>
6
+
7
+ <script>
8
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
9
+ import { iconDel } from '@opentiny/vue-icon'
10
+
11
+ export default {
12
+ components: {
13
+ TinyFloatButton
14
+ },
15
+ data() {
16
+ return {
17
+ IconDel: iconDel()
18
+ }
19
+ }
20
+ }
21
+ </script>
22
+
23
+ <style scoped>
24
+ .parent {
25
+ position: relative;
26
+ }
27
+
28
+ .tiny-float-button {
29
+ position: absolute;
30
+ }
31
+ </style>
@@ -0,0 +1,19 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button type="success" right="" left="0" bottom="0" top="-9px" trigger="" href="/" description="跳">
4
+ </tiny-float-button>
5
+ </div>
6
+ </template>
7
+
8
+ <script setup>
9
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
10
+ </script>
11
+
12
+ <style scoped>
13
+ .parent {
14
+ position: relative;
15
+ }
16
+ .tiny-float-button {
17
+ position: absolute;
18
+ }
19
+ </style>
@@ -0,0 +1,26 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button type="success" right="" left="0" bottom="0" top="-9px" trigger="" href="/" description="跳">
4
+ </tiny-float-button>
5
+ </div>
6
+ </template>
7
+
8
+ <script>
9
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
10
+
11
+ export default {
12
+ components: {
13
+ TinyFloatButton
14
+ }
15
+ }
16
+ </script>
17
+
18
+ <style scoped>
19
+ .parent {
20
+ position: relative;
21
+ }
22
+
23
+ .tiny-float-button {
24
+ position: absolute;
25
+ }
26
+ </style>
@@ -0,0 +1,22 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button reset-time="2000" type="success" right="" left="0" bottom="0" trigger="click" description="点">
4
+ 展开</tiny-float-button
5
+ >
6
+ </div>
7
+ </template>
8
+
9
+ <script setup>
10
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
11
+ </script>
12
+
13
+ <style scoped>
14
+ .parent {
15
+ position: relative;
16
+ height: 100px;
17
+ }
18
+
19
+ .tiny-float-button {
20
+ position: absolute;
21
+ }
22
+ </style>
@@ -0,0 +1,26 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button reset-time="2000" type="success" right="" left="0" bottom="0" trigger="click" description="点">
4
+ 展开</tiny-float-button
5
+ >
6
+ </div>
7
+ </template>
8
+
9
+ <script>
10
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
11
+
12
+ export default {
13
+ TinyFloatButton
14
+ }
15
+ </script>
16
+
17
+ <style scoped>
18
+ .parent {
19
+ position: relative;
20
+ height: 100px;
21
+ }
22
+
23
+ .tiny-float-button {
24
+ position: absolute;
25
+ }
26
+ </style>
@@ -0,0 +1,31 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button bottom="-15px" right="100px" trigger="click" :icon="IconDel" type="primary">
4
+ <tiny-float-button bottom="0" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
5
+ </tiny-float-button>
6
+ <tiny-float-button bottom="-15px" right="180px" trigger="hover" :icon="IconDel" type="primary">
7
+ <tiny-float-button bottom="0" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
8
+ </tiny-float-button>
9
+ <tiny-float-button bottom="-15px" right="280px" trigger="click" :open="true" :icon="IconDel" type="primary">
10
+ <tiny-float-button bottom="0px" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
11
+ </tiny-float-button>
12
+ </div>
13
+ </template>
14
+
15
+ <script setup>
16
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
17
+ import { iconDel } from '@opentiny/vue-icon'
18
+
19
+ const IconDel = iconDel()
20
+ </script>
21
+
22
+ <style scoped>
23
+ .parent {
24
+ position: relative;
25
+ height: 100px;
26
+ }
27
+
28
+ .tiny-float-button {
29
+ position: absolute;
30
+ }
31
+ </style>
@@ -0,0 +1,40 @@
1
+ <template>
2
+ <div class="parent">
3
+ <tiny-float-button bottom="-15px" right="100px" trigger="click" :icon="IconDel" type="primary">
4
+ <tiny-float-button bottom="0" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
5
+ </tiny-float-button>
6
+ <tiny-float-button bottom="-15px" right="180px" trigger="hover" :icon="IconDel" type="primary">
7
+ <tiny-float-button bottom="0" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
8
+ </tiny-float-button>
9
+ <tiny-float-button bottom="-15px" right="280px" trigger="click" :open="true" :icon="IconDel" type="primary">
10
+ <tiny-float-button bottom="0px" right="-28px" trigger="" :icon="IconDel"> </tiny-float-button>
11
+ </tiny-float-button>
12
+ </div>
13
+ </template>
14
+
15
+ <script>
16
+ import { FloatButton as TinyFloatButton } from '@opentiny/vue'
17
+ import { iconDel } from '@opentiny/vue-icon'
18
+
19
+ export default {
20
+ components: {
21
+ TinyFloatButton
22
+ },
23
+ data() {
24
+ return {
25
+ IconDel: iconDel()
26
+ }
27
+ }
28
+ }
29
+ </script>
30
+
31
+ <style scoped>
32
+ .parent {
33
+ position: relative;
34
+ height: 100px;
35
+ }
36
+
37
+ .tiny-float-button {
38
+ position: absolute;
39
+ }
40
+ </style>
@@ -0,0 +1,7 @@
1
+ ---
2
+ title: FloatButton 悬浮按钮
3
+ ---
4
+
5
+ # FloatButton 悬浮按钮
6
+
7
+ <div>悬浮在固定位置的按钮。</div>
@@ -0,0 +1,7 @@
1
+ ---
2
+ title: FloatButton
3
+ ---
4
+
5
+ # FloatButton
6
+
7
+ <div>A button that hovers in a fixed position.</div>
@@ -0,0 +1,68 @@
1
+ export default {
2
+ column: '2',
3
+ owner: '',
4
+ demos: [
5
+ {
6
+ 'demoId': 'basic-usage',
7
+ 'name': { 'zh-CN': '基本用法', 'en-US': 'Basic Usage' },
8
+ 'desc': {
9
+ 'zh-CN': '<p>通过 <code>type</code> 设置按钮类型, <code>shape</code>设置按钮的形状</p>',
10
+ 'en-US': '<p>The type of the button is set by type, and the shape of the button is set by shape.</p>'
11
+ },
12
+ 'codeFiles': ['basic-usage.vue']
13
+ },
14
+ {
15
+ 'demoId': 'reset-time',
16
+ 'name': { 'zh-CN': '防止重复点击', 'en-US': 'Prevent duplicate clicks' },
17
+ 'desc': {
18
+ 'zh-CN':
19
+ '<p>通过 <code>reset-time</code> 设置单击后按钮禁用的时长,默认禁用时长为 1000 毫秒,可用于防止按钮连续点击出现表单重复提交的问题。</p>',
20
+ 'en-US':
21
+ '<p>You can use the <code>reset-time</code> to set the duration for which the button is disabled. The default duration is 1000 ms. This parameter can be used to prevent repeated submission of the form when you click the button continuously. </p>'
22
+ },
23
+ 'codeFiles': ['reset-time.vue']
24
+ },
25
+ {
26
+ 'demoId': 'icon',
27
+ 'name': { 'zh-CN': '图标按钮', 'en-US': 'Icon Button' },
28
+ 'desc': {
29
+ 'zh-CN':
30
+ '<p>通过 <code>icon</code> 设置按钮展示图标, 接收一个图标组件。</p><div class="tip custom-block"><p class="custom-block-title">Icon 图标用法</p><p>先从 <code>@opentiny/vue-icon</code> 中导入需要的 Icon,执行Icon函数得到Icon组件。然后在模板中通过 <code>icon</code> 属性进行引用。</p>',
31
+ 'en-US':
32
+ '<p>Display icons and receive an icon component through the <code>icon</code> settings button</ p> <div class="tip custom block"><p class="custom block title">Icon icon usage</p><p>First, import the required Icon from <code>@ opentiny/vue icon</code> , and execute the Icon function to obtain the Icon component. Then refer to it in the template through the <code>icon</code> attribute.</p>'
33
+ },
34
+ 'codeFiles': ['icon.vue']
35
+ },
36
+ {
37
+ 'demoId': 'trigger',
38
+ 'name': { 'zh-CN': '菜单模式', 'en-US': 'Menu mode' },
39
+ 'desc': {
40
+ 'zh-CN':
41
+ '<p>设置<code>trigger</code> 属性即可开启菜单模式。设置<code>open</code>为<code>true</code>即可手动打开菜单.</p>',
42
+ 'en-US':
43
+ '<p>Set the trigger property to turn on the menu mode.Set <code>open</code> to <code>true</code> to manually open the menu.</p>'
44
+ },
45
+ 'codeFiles': ['trigger.vue']
46
+ },
47
+ {
48
+ 'demoId': 'backTop',
49
+ 'name': { 'zh-CN': '回到顶部', 'en-US': 'Back to top' },
50
+ 'desc': {
51
+ 'zh-CN': '<p>设置<code>backtop</code> 属性即可实现页面滚回顶部。<code>element</code>赋值为滚动元素。</p>',
52
+ 'en-US':
53
+ '<p>Set the backtop attribute to roll the page back to the top. element is assigned as a scrolling element.</p>'
54
+ },
55
+ 'codeFiles': ['backTop.vue']
56
+ },
57
+
58
+ {
59
+ 'demoId': 'jump',
60
+ 'name': { 'zh-CN': '跳转页面', 'en-US': 'Jump to the page' },
61
+ 'desc': {
62
+ 'zh-CN': '<p>可以设置<code>href</code>和<code>target</code>两个属性,按钮点击跳转页面。</p>',
63
+ 'en-US': '<p>You can set the two properties of href and target, and click the button to jump to the page.</p>'
64
+ },
65
+ 'codeFiles': ['jump.vue']
66
+ }
67
+ ]
68
+ }
@@ -4,7 +4,7 @@ test('基本用法', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('floatbar#base')
6
6
 
7
- const floatbar = page.locator('#preview .tiny-float-bar')
7
+ const floatbar = page.locator('.tiny-float-bar')
8
8
  await expect(floatbar).toBeVisible()
9
9
  await expect(floatbar).toHaveCSS('right', '10px')
10
10
  await page.getByRole('listitem').filter({ hasText: 'Default-A' }).click()
@@ -4,7 +4,7 @@ test('自定义内容', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('floatbar#custom-floatbar-item')
6
6
 
7
- const floatbar = page.locator('#preview .tiny-float-bar')
7
+ const floatbar = page.locator('.tiny-float-bar')
8
8
  const item1 = floatbar.getByRole('listitem').first()
9
9
  const item2 = floatbar.getByRole('listitem').nth(1)
10
10
  const item3 = floatbar.getByRole('listitem').nth(2)
@@ -4,7 +4,7 @@ test('自定义样式', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('floatbar#custom-style')
6
6
 
7
- const floatbar = page.locator('#preview .tiny-float-bar')
7
+ const floatbar = page.locator('.tiny-float-bar')
8
8
  const item = page.getByRole('listitem').filter({ hasText: 'Default-A' })
9
9
  await expect(floatbar).toHaveClass(/custom/)
10
10
  await expect(floatbar).toHaveCSS('background-color', 'rgb(222, 184, 135)')
@@ -4,7 +4,7 @@ test('操作浮动块内容', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('floatbar#operation-floatbar-item')
6
6
 
7
- const floatbar = page.locator('#preview .tiny-float-bar')
7
+ const floatbar = page.locator('.tiny-float-bar')
8
8
  const item = floatbar.getByRole('listitem').filter({ hasText: 'custom-Add' })
9
9
  await page.getByRole('button', { name: '增加一项' }).click()
10
10
  await expect(item).toBeVisible()
@@ -8,6 +8,8 @@ test('测试表单复杂布局', async ({ page }) => {
8
8
  const form = demo.locator('.tiny-form')
9
9
  const formItem = form.locator('.tiny-form-item')
10
10
 
11
+ await page.waitForTimeout(2000)
12
+
11
13
  const item1Box = await formItem.first().boundingBox()
12
14
  const item2Box = await formItem.nth(1).boundingBox()
13
15
  const item3Box = await formItem.nth(2).boundingBox()
@@ -12,21 +12,21 @@ test('测试表单文本对齐', async ({ page }) => {
12
12
  const firstItemContent = formItem.first().locator('.tiny-form-item__content')
13
13
 
14
14
  await getBtnByText('left').click()
15
- await page.waitForTimeout(300)
15
+ await page.waitForTimeout(1000)
16
16
  await expect(form).toHaveClass(/tiny-form--label-left/)
17
17
  let labelBox = await firstItemLabel.boundingBox()
18
18
  let contentBox = await firstItemContent.boundingBox()
19
19
  expect(labelBox?.y).toEqual(contentBox?.y)
20
20
 
21
21
  await getBtnByText('top').click()
22
- await page.waitForTimeout(300)
22
+ await page.waitForTimeout(1000)
23
23
  await expect(form).toHaveClass(/tiny-form--label-top/)
24
24
  labelBox = await firstItemLabel.boundingBox()
25
25
  contentBox = await firstItemContent.boundingBox()
26
26
  expect(labelBox?.y).toBeLessThan(contentBox?.y || 0)
27
27
 
28
28
  await getBtnByText('right').click()
29
- await page.waitForTimeout(300)
29
+ await page.waitForTimeout(1000)
30
30
  await expect(form).toHaveClass(/tiny-form--label-right/)
31
31
  labelBox = await firstItemLabel.boundingBox()
32
32
  contentBox = await firstItemContent.boundingBox()
@@ -9,11 +9,11 @@ test('个性化按钮点击事件', async ({ page }) => {
9
9
  await expect(
10
10
  page.getByText('点击了确认按钮{"sortType":"page","pageSize":10,"columns":[{"property":"name","order":nu')
11
11
  ).toBeVisible()
12
- await page.getByRole('button', { name: '确认' }).click()
12
+ await page.getByRole('button', { name: '确定' }).click()
13
13
  await page.locator('.tiny-grid-custom__setting-btn').click()
14
14
  await page.getByRole('button', { name: '重置' }).click()
15
15
  await expect(page.getByText('点击了重置按钮')).toBeVisible()
16
- await page.getByRole('button', { name: '确认' }).click()
16
+ await page.getByRole('button', { name: '确定' }).nth(1).click()
17
17
  await page.getByRole('button', { name: '取消' }).click()
18
18
  await expect(page.getByText('点击了取消按钮undefined')).toBeVisible
19
19
  })
@@ -3,7 +3,7 @@
3
3
  <div class="button-box">
4
4
  <tiny-button @click="addRow">添加数据</tiny-button>
5
5
  <tiny-button @click="deleteRow">减少数据</tiny-button>
6
- <tiny-button @click="changeTableData">改变tableData引用地址</tiny-button>
6
+ <tiny-button @click="changeTableData">改变 tableData 引用地址</tiny-button>
7
7
  </div>
8
8
  <tiny-grid :data="tableData">
9
9
  <tiny-grid-column type="index" width="60"></tiny-grid-column>