@opentiny/vue-docs 2.2.4 → 2.2.6

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 (414) hide show
  1. package/demos/mobile/app/container/basic-usage.vue +105 -0
  2. package/demos/mobile/app/container/custom-width.vue +93 -0
  3. package/demos/mobile/app/container/webdoc/container.cn.md +7 -0
  4. package/demos/mobile/app/container/webdoc/container.en.md +7 -0
  5. package/demos/mobile/app/container/webdoc/container.js +80 -0
  6. package/demos/mobile/app/pull-refresh/animation-duration.vue +58 -12
  7. package/demos/mobile/app/pull-refresh/base.vue +32 -18
  8. package/demos/mobile/app/pull-refresh/disabled-pull-down.vue +66 -0
  9. package/demos/mobile/app/pull-refresh/disabled-pull-up.vue +67 -0
  10. package/demos/mobile/app/pull-refresh/{hasmore.vue → event.vue} +21 -20
  11. package/demos/mobile/app/pull-refresh/{enhance.vue → has-more.vue} +20 -25
  12. package/demos/mobile/app/pull-refresh/loosing-text.vue +55 -12
  13. package/demos/mobile/app/pull-refresh/pull-refresh-slot.vue +64 -15
  14. package/demos/mobile/app/pull-refresh/pull-up-distance.vue +74 -0
  15. package/demos/mobile/app/pull-refresh/pulling-text.vue +56 -12
  16. package/demos/mobile/app/pull-refresh/webdoc/pull-refresh.js +98 -120
  17. package/demos/mobile/app/tabs/before-leave.vue +3 -3
  18. package/demos/mobile/app/tabs/tabs-events.vue +7 -7
  19. package/demos/mobile/menus.js +4 -1
  20. package/demos/mobile-first/app/tabs/basic-usage.vue +3 -3
  21. package/demos/mobile-first/app/tabs/before-leave.vue +3 -3
  22. package/demos/mobile-first/app/tabs/change-title.vue +2 -2
  23. package/demos/mobile-first/app/tabs/custom-tab-content.vue +3 -3
  24. package/demos/mobile-first/app/tabs/custom-tab-title.vue +3 -3
  25. package/demos/mobile-first/app/tabs/position-bottom.vue +10 -10
  26. package/demos/mobile-first/app/tabs/position-left.vue +10 -10
  27. package/demos/mobile-first/app/tabs/position-right.vue +10 -10
  28. package/demos/mobile-first/app/tabs/position.vue +10 -10
  29. package/demos/mobile-first/app/tabs/prevent-tab-switching.vue +3 -3
  30. package/demos/mobile-first/app/tabs/stretch-wh.vue +3 -3
  31. package/demos/mobile-first/app/tabs/tab-style-bordercard.vue +10 -10
  32. package/demos/mobile-first/app/tabs/tab-style-card.vue +10 -10
  33. package/demos/mobile-first/app/tabs/tabdata-title.vue +4 -4
  34. package/demos/mobile-first/app/tabs/tabs-draggable.vue +1 -1
  35. package/demos/mobile-first/app/tabs/tabs-events-add.vue +3 -3
  36. package/demos/mobile-first/app/tabs/tabs-events-click.vue +3 -3
  37. package/demos/mobile-first/app/tabs/tabs-events-close.vue +4 -4
  38. package/demos/mobile-first/app/tabs/tabs-events-edit.vue +4 -4
  39. package/demos/mobile-first/app/tabs/tabs-separator.vue +8 -8
  40. package/demos/mobile-first/app/tabs/tabs-size.vue +3 -3
  41. package/demos/mobile-first/app/tabs/tabs-tabs.vue +2 -2
  42. package/demos/mobile-first/app/tabs/with-add.vue +1 -1
  43. package/demos/pc/app/action-menu/disabled.vue +2 -1
  44. package/demos/pc/app/action-menu/icon-composition-api.vue +73 -0
  45. package/demos/pc/app/action-menu/icon.vue +79 -0
  46. package/demos/pc/app/action-menu/popper-class.spec.ts +2 -1
  47. package/demos/pc/app/action-menu/webdoc/action-menu.js +42 -1
  48. package/demos/pc/app/autocomplete/webdoc/autocomplete.js +30 -16
  49. package/demos/pc/app/breadcrumb/webdoc/breadcrumb.js +3 -3
  50. package/demos/pc/app/button/basic-usage-composition-api.vue +2 -0
  51. package/demos/pc/app/button/basic-usage.vue +2 -0
  52. package/demos/pc/app/button/click-composition-api.vue +1 -1
  53. package/demos/pc/app/button/click.vue +1 -1
  54. package/demos/pc/app/button/dynamic-disabled-composition-api.vue +10 -1
  55. package/demos/pc/app/button/{dynamic-disabled.spec.js → dynamic-disabled.spec.ts} +4 -0
  56. package/demos/pc/app/button/dynamic-disabled.vue +12 -3
  57. package/demos/pc/app/button/ghost-composition-api.vue +26 -0
  58. package/demos/pc/app/button/ghost.spec.ts +69 -0
  59. package/demos/pc/app/button/ghost.vue +32 -0
  60. package/demos/pc/app/button/icon-composition-api.vue +2 -0
  61. package/demos/pc/app/button/icon.vue +2 -0
  62. package/demos/pc/app/button/loading-composition-api.vue +2 -0
  63. package/demos/pc/app/button/loading.vue +2 -0
  64. package/demos/pc/app/button/size-composition-api.vue +2 -0
  65. package/demos/pc/app/button/size.vue +2 -0
  66. package/demos/pc/app/button/text-composition-api.vue +1 -1
  67. package/demos/pc/app/button/text.vue +1 -1
  68. package/demos/pc/app/button/webdoc/button.js +28 -1
  69. package/demos/pc/app/button-group/button-group-multiple-composition-api.vue +9 -9
  70. package/demos/pc/app/button-group/button-group-multiple.vue +9 -9
  71. package/demos/pc/app/button-group/change-event-composition-api.vue +1 -1
  72. package/demos/pc/app/button-group/change-event.vue +1 -1
  73. package/demos/pc/app/button-group/show-edit-composition-api.vue +1 -1
  74. package/demos/pc/app/button-group/show-edit.vue +1 -1
  75. package/demos/pc/app/button-group/webdoc/button-group.js +2 -3
  76. package/demos/pc/app/carousel/webdoc/carousel.js +82 -49
  77. package/demos/pc/app/cascader/auto-load-checkStrictly-composition-api.vue +2 -1
  78. package/demos/pc/app/cascader/auto-load-checkStrictly.vue +2 -1
  79. package/demos/pc/app/cascader/auto-load-composition-api.vue +3 -1
  80. package/demos/pc/app/cascader/auto-load.vue +2 -1
  81. package/demos/pc/app/cascader/events-composition-api.vue +1 -1
  82. package/demos/pc/app/cascader/expand-trigger-composition-api.vue +195 -2
  83. package/demos/pc/app/cascader/show-all-levels-composition-api.vue +197 -2
  84. package/demos/pc/app/cascader/webdoc/cascader.js +27 -13
  85. package/demos/pc/app/cascader-panel/basic-usage-composition-api.vue +3 -1
  86. package/demos/pc/app/cascader-panel/basic-usage.vue +2 -1
  87. package/demos/pc/app/cascader-panel/cascader-panel-props-composition-api.vue +3 -1
  88. package/demos/pc/app/cascader-panel/cascader-panel-props.vue +3 -1
  89. package/demos/pc/app/cascader-panel/change-composition-api.vue +1 -2
  90. package/demos/pc/app/cascader-panel/change.vue +1 -1
  91. package/demos/pc/app/cascader-panel/webdoc/cascader-panel.js +5 -5
  92. package/demos/pc/app/color-picker/webdoc/color-picker.js +36 -18
  93. package/demos/pc/app/color-select-panel/webdoc/color-select-panel.js +32 -19
  94. package/demos/pc/app/config-provider/basic.spec.ts +9 -0
  95. package/demos/pc/app/config-provider/tag.spec.ts +12 -0
  96. package/demos/pc/app/config-provider/text-direct.spec.ts +11 -0
  97. package/demos/pc/app/config-provider/webdoc/config-provider.en.md +7 -0
  98. package/demos/pc/app/config-provider/webdoc/config-provider.js +27 -12
  99. package/demos/pc/app/container/basic-usage.spec.js +47 -2
  100. package/demos/pc/app/container/custom-with-height.spec.js +10 -2
  101. package/demos/pc/app/crop/webdoc/crop.js +53 -49
  102. package/demos/pc/app/dialog-box/webdoc/dialog-box.js +82 -83
  103. package/demos/pc/app/divider/webdoc/divider.js +25 -21
  104. package/demos/pc/app/dropdown/events-composition-api.vue +1 -1
  105. package/demos/pc/app/dropdown/events.spec.ts +1 -0
  106. package/demos/pc/app/dropdown/multi-level-composition-api.vue +4 -8
  107. package/demos/pc/app/dropdown/multi-level.spec.ts +16 -9
  108. package/demos/pc/app/dropdown/multi-level.vue +3 -7
  109. package/demos/pc/app/dropdown/show-icon-composition-api.vue +44 -21
  110. package/demos/pc/app/dropdown/show-icon.vue +42 -12
  111. package/demos/pc/app/dropdown/webdoc/dropdown.js +29 -8
  112. package/demos/pc/app/fall-menu/custom-menuitem.spec.ts +6 -9
  113. package/demos/pc/app/fall-menu/custom-slider-icon.spec.ts +10 -21
  114. package/demos/pc/app/fall-menu/data-resource.spec.ts +6 -9
  115. package/demos/pc/app/file-upload/abort-quest.spec.ts +6 -5
  116. package/demos/pc/app/file-upload/accept-file-image.spec.ts +9 -4
  117. package/demos/pc/app/file-upload/custom-trigger.spec.ts +1 -1
  118. package/demos/pc/app/file-upload/disabled.spec.ts +4 -5
  119. package/demos/pc/app/file-upload/drag-upload.spec.ts +1 -1
  120. package/demos/pc/app/file-upload/file-picture-card.spec.ts +7 -6
  121. package/demos/pc/app/file-upload/form-validation.spec.ts +2 -2
  122. package/demos/pc/app/file-upload/image-size.spec.ts +2 -2
  123. package/demos/pc/app/file-upload/max-file-count.spec.ts +6 -6
  124. package/demos/pc/app/file-upload/paste-upload-composition-api.vue +2 -2
  125. package/demos/pc/app/file-upload/paste-upload.spec.ts +19 -2
  126. package/demos/pc/app/file-upload/picture-card.spec.ts +6 -5
  127. package/demos/pc/app/file-upload/picture-list.spec.ts +2 -3
  128. package/demos/pc/app/file-upload/prevent-delete-file.spec.ts +1 -1
  129. package/demos/pc/app/file-upload/prevent-upload-file.spec.ts +1 -1
  130. package/demos/pc/app/file-upload/upload-events.spec.ts +6 -4
  131. package/demos/pc/app/file-upload/upload-file-list-slot.spec.ts +18 -0
  132. package/demos/pc/app/file-upload/upload-file-list-thumb-composition-api.vue +4 -3
  133. package/demos/pc/app/file-upload/upload-file-list-thumb.spec.ts +2 -2
  134. package/demos/pc/app/file-upload/upload-file-list-thumb.vue +4 -3
  135. package/demos/pc/app/file-upload/upload-file-list.spec.ts +9 -9
  136. package/demos/pc/app/file-upload/upload-limit.spec.ts +5 -8
  137. package/demos/pc/app/file-upload/upload-request.spec.ts +1 -1
  138. package/demos/pc/app/file-upload/upload-user-head.spec.ts +1 -1
  139. package/demos/pc/app/file-upload/webdoc/file-upload.js +4 -4
  140. package/demos/pc/app/file-upload//346/265/213/350/257/225.txt +1 -0
  141. package/demos/pc/app/form/custom-validation-rule-composition-api.vue +2 -14
  142. package/demos/pc/app/form/custom-validation-rule.vue +2 -8
  143. package/demos/pc/app/form/form-validate-field.vue +2 -2
  144. package/demos/pc/app/form/size.spec.ts +26 -6
  145. package/demos/pc/app/grid/custom-style/body-style-composition-api.vue +1 -1
  146. package/demos/pc/app/grid/custom-style/footer-style-composition-api.vue +64 -19
  147. package/demos/pc/app/grid/drag/row-drag-ctrl-composition-api.vue +4 -4
  148. package/demos/pc/app/grid/edit/trigger-mode-hm-editing-composition-api.vue +2 -2
  149. package/demos/pc/app/grid/edit/trigger-mode-hm-editing.vue +1 -1
  150. package/demos/pc/app/grid/event/cell-mouse-event-composition-api.vue +1 -1
  151. package/demos/pc/app/grid/event/context-menu-event-composition-api.vue +1 -0
  152. package/demos/pc/app/grid/event/edit-event-composition-api.vue +1 -1
  153. package/demos/pc/app/grid/expand/set-row-expansion-composition-api.vue +9 -4
  154. package/demos/pc/app/grid/loading/{grid-loading-off-tip-composition-api.vue → grid-custom-loading-composition-api.vue} +29 -4
  155. package/demos/pc/app/grid/loading/grid-custom-loading.spec.js +7 -0
  156. package/demos/pc/app/grid/loading/{grid-loading-off-tip.vue → grid-custom-loading.vue} +27 -1
  157. package/demos/pc/app/grid/operation-column/clear-and-set-radio-row-composition-api.vue +5 -1
  158. package/demos/pc/app/grid/operation-column/selection-operation-composition-api.vue +32 -0
  159. package/demos/pc/app/grid/size/grid-size-composition-api.vue +17 -0
  160. package/demos/pc/app/grid/slot/editor-slot-composition-api.vue +13 -7
  161. package/demos/pc/app/grid/sort/combinations-sort-composition-api.vue +3 -3
  162. package/demos/pc/app/grid/sort/combinations-sort.spec.js +3 -0
  163. package/demos/pc/app/grid/sort/combinations-sort.vue +3 -3
  164. package/demos/pc/app/grid/toolbar/insert-remove-rows-composition-api.vue +1 -1
  165. package/demos/pc/app/grid/toolbar/insert-remove-rows.vue +1 -1
  166. package/demos/pc/app/grid/toolbar/refresh-grid-composition-api.vue +105 -0
  167. package/demos/pc/app/grid/tree-table/set-tree-expansion-composition-api.vue +4 -4
  168. package/demos/pc/app/grid/validation/before-submit-validation-composition-api.vue +19 -2
  169. package/demos/pc/app/grid/validation/before-submit-validation.spec.js +5 -2
  170. package/demos/pc/app/grid/validation/before-submit-validation.vue +19 -2
  171. package/demos/pc/app/grid/webdoc/grid-loading.js +9 -5
  172. package/demos/pc/app/grid/webdoc/grid-size.js +2 -2
  173. package/demos/pc/app/grid/webdoc/grid-validation.js +1 -1
  174. package/demos/pc/app/grid/webdoc/grid.js +8 -1
  175. package/demos/pc/app/guide/callback-composition-api.vue +2 -2
  176. package/demos/pc/app/guide/callback.vue +2 -2
  177. package/demos/pc/app/guide/highlight-box-composition-api.vue +9 -8
  178. package/demos/pc/app/guide/highlight-box.vue +8 -2
  179. package/demos/pc/app/guide/offset-composition-api.vue +7 -2
  180. package/demos/pc/app/guide/offset.vue +7 -2
  181. package/demos/pc/app/guide/size-composition-api.vue +3 -8
  182. package/demos/pc/app/guide/size.vue +3 -8
  183. package/demos/pc/app/guide/webdoc/guide.js +2 -2
  184. package/demos/pc/app/image/basic-usage.spec.ts +9 -2
  185. package/demos/pc/app/image/events.spec.ts +3 -1
  186. package/demos/pc/app/image/lazy-composition-api.vue +2 -2
  187. package/demos/pc/app/image/lazy.spec.ts +7 -4
  188. package/demos/pc/app/image/lazy.vue +2 -2
  189. package/demos/pc/app/image/preview-in-dialog.spec.ts +15 -1
  190. package/demos/pc/app/image/preview.spec.ts +28 -13
  191. package/demos/pc/app/image/slot.spec.ts +3 -0
  192. package/demos/pc/app/input/webdoc/input.js +11 -11
  193. package/demos/pc/app/link/basic-usage-composition-api.vue +1 -1
  194. package/demos/pc/app/link/basic-usage.spec.ts +1 -1
  195. package/demos/pc/app/link/basic-usage.vue +1 -1
  196. package/demos/pc/app/link/config-href.spec.ts +2 -2
  197. package/demos/pc/app/link/custom-icon.spec.ts +5 -5
  198. package/demos/pc/app/link/dynamic-disable.spec.ts +11 -11
  199. package/demos/pc/app/link/focus-no-underline.spec.ts +3 -3
  200. package/demos/pc/app/link/link-style-composition-api.vue +6 -6
  201. package/demos/pc/app/link/link-style.spec.ts +36 -7
  202. package/demos/pc/app/link/link-style.vue +6 -6
  203. package/demos/pc/app/link/webdoc/link.js +20 -22
  204. package/demos/pc/app/link-menu/webdoc/link-menu.js +22 -22
  205. package/demos/pc/app/milestone/basic-usage-composition-api.vue +6 -6
  206. package/demos/pc/app/milestone/basic-usage.spec.ts +1 -1
  207. package/demos/pc/app/milestone/basic-usage.vue +6 -6
  208. package/demos/pc/app/milestone/line-style-composition-api.vue +6 -6
  209. package/demos/pc/app/milestone/line-style.vue +6 -6
  210. package/demos/pc/app/milestone/show-number-composition-api.vue +9 -7
  211. package/demos/pc/app/milestone/show-number.spec.ts +7 -7
  212. package/demos/pc/app/milestone/show-number.vue +9 -7
  213. package/demos/pc/app/milestone/solid-style-composition-api.vue +7 -7
  214. package/demos/pc/app/milestone/solid-style.spec.ts +7 -7
  215. package/demos/pc/app/milestone/solid-style.vue +7 -7
  216. package/demos/pc/app/milestone/webdoc/milestone.js +31 -12
  217. package/demos/pc/app/modal/webdoc/modal.js +80 -76
  218. package/demos/pc/app/nav-menu/basic-usage.spec.ts +2 -2
  219. package/demos/pc/app/nav-menu/before-skip-prevent.spec.ts +1 -1
  220. package/demos/pc/app/nav-menu/before-skip.spec.ts +1 -1
  221. package/demos/pc/app/nav-menu/custom-service.spec.ts +1 -2
  222. package/demos/pc/app/nav-menu/overflow.spec.ts +2 -2
  223. package/demos/pc/app/nav-menu/slot-logo.spec.ts +1 -1
  224. package/demos/pc/app/nav-menu/slot-toolbar.spec.ts +2 -2
  225. package/demos/pc/app/numeric/webdoc/numeric.js +33 -32
  226. package/demos/pc/app/search/basic-usage.spec.ts +1 -1
  227. package/demos/pc/app/search/clearable.spec.ts +1 -1
  228. package/demos/pc/app/search/events-composition-api.vue +6 -0
  229. package/demos/pc/app/search/events.spec.ts +9 -6
  230. package/demos/pc/app/search/events.vue +5 -0
  231. package/demos/pc/app/search/webdoc/search.js +14 -4
  232. package/demos/pc/app/slide-bar/webdoc/slide-bar.js +18 -12
  233. package/demos/pc/app/slider/webdoc/slider.js +23 -18
  234. package/demos/pc/app/steps/advanced-steps.spec.ts +3 -2
  235. package/demos/pc/app/steps/click-composition-api.vue +0 -1
  236. package/demos/pc/app/steps/click.spec.ts +1 -12
  237. package/demos/pc/app/steps/custom-steps-item.spec.ts +1 -1
  238. package/demos/pc/app/steps/node-status-composition-api.vue +1 -1
  239. package/demos/pc/app/steps/node-status.spec.ts +1 -1
  240. package/demos/pc/app/steps/node-status.vue +1 -1
  241. package/demos/pc/app/steps/normal-steps-composition-api.vue +1 -1
  242. package/demos/pc/app/steps/normal-steps.spec.ts +2 -2
  243. package/demos/pc/app/steps/normal-steps.vue +1 -1
  244. package/demos/pc/app/steps/only-number-composition-api.vue +1 -1
  245. package/demos/pc/app/steps/only-number.spec.ts +1 -1
  246. package/demos/pc/app/steps/only-number.vue +1 -1
  247. package/demos/pc/app/steps/show-divider-composition-api.vue +1 -1
  248. package/demos/pc/app/steps/show-divider.spec.ts +1 -1
  249. package/demos/pc/app/steps/show-divider.vue +1 -1
  250. package/demos/pc/app/steps/size-composition-api.vue +6 -9
  251. package/demos/pc/app/steps/size.spec.ts +1 -4
  252. package/demos/pc/app/steps/size.vue +4 -4
  253. package/demos/pc/app/steps/slot-active-node-desc-composition-api.vue +3 -1
  254. package/demos/pc/app/steps/slot-active-node-desc.spec.ts +1 -1
  255. package/demos/pc/app/steps/slot-active-node-desc.vue +3 -1
  256. package/demos/pc/app/steps/slot-description-composition-api.vue +6 -6
  257. package/demos/pc/app/steps/slot-description.spec.ts +1 -1
  258. package/demos/pc/app/steps/slot-description.vue +5 -5
  259. package/demos/pc/app/steps/slot-item-composition-api.vue +0 -1
  260. package/demos/pc/app/steps/slot-item.spec.ts +1 -7
  261. package/demos/pc/app/steps/slot-item.vue +0 -1
  262. package/demos/pc/app/steps/space.spec.ts +1 -1
  263. package/demos/pc/app/steps/text-position-composition-api.vue +1 -1
  264. package/demos/pc/app/steps/text-position.spec.ts +1 -4
  265. package/demos/pc/app/steps/text-position.vue +1 -1
  266. package/demos/pc/app/steps/vertical-steps.spec.ts +13 -19
  267. package/demos/pc/app/steps/webdoc/steps.js +18 -17
  268. package/demos/pc/app/tabs/basic-usage-composition-api.vue +4 -4
  269. package/demos/pc/app/tabs/basic-usage.vue +4 -4
  270. package/demos/pc/app/tabs/before-leave-composition-api.vue +3 -3
  271. package/demos/pc/app/tabs/before-leave.vue +3 -3
  272. package/demos/pc/app/tabs/custom-more-icon-composition-api.vue +1 -1
  273. package/demos/pc/app/tabs/custom-more-icon.vue +1 -1
  274. package/demos/pc/app/tabs/custom-tab-content-composition-api.vue +3 -3
  275. package/demos/pc/app/tabs/custom-tab-content.vue +3 -3
  276. package/demos/pc/app/tabs/custom-tab-title-composition-api.vue +3 -3
  277. package/demos/pc/app/tabs/custom-tab-title.vue +3 -3
  278. package/demos/pc/app/tabs/lazy-composition-api.vue +5 -3
  279. package/demos/pc/app/tabs/lazy.vue +5 -3
  280. package/demos/pc/app/tabs/position-composition-api.vue +22 -17
  281. package/demos/pc/app/tabs/position.spec.ts +4 -4
  282. package/demos/pc/app/tabs/position.vue +19 -18
  283. package/demos/pc/app/tabs/prevent-tab-switching-composition-api.vue +3 -3
  284. package/demos/pc/app/tabs/prevent-tab-switching.vue +3 -3
  285. package/demos/pc/app/tabs/stretch-wh-composition-api.vue +3 -3
  286. package/demos/pc/app/tabs/stretch-wh.vue +3 -3
  287. package/demos/pc/app/tabs/tab-style-bordercard-composition-api.vue +10 -10
  288. package/demos/pc/app/tabs/tab-style-bordercard.vue +10 -10
  289. package/demos/pc/app/tabs/tab-style-card-composition-api.vue +1 -1
  290. package/demos/pc/app/tabs/tab-style-card.vue +1 -1
  291. package/demos/pc/app/tabs/tabs-draggable-composition-api.vue +1 -1
  292. package/demos/pc/app/tabs/tabs-draggable.spec.ts +1 -7
  293. package/demos/pc/app/tabs/tabs-draggable.vue +1 -1
  294. package/demos/pc/app/tabs/tabs-events-click-composition-api.vue +3 -3
  295. package/demos/pc/app/tabs/tabs-events-click.vue +3 -3
  296. package/demos/pc/app/tabs/tabs-events-close-composition-api.vue +4 -4
  297. package/demos/pc/app/tabs/tabs-events-close.vue +4 -4
  298. package/demos/pc/app/tabs/tabs-events-edit-composition-api.vue +4 -4
  299. package/demos/pc/app/tabs/tabs-events-edit.vue +4 -4
  300. package/demos/pc/app/tabs/tabs-separator-composition-api.vue +7 -7
  301. package/demos/pc/app/tabs/tabs-separator.vue +7 -7
  302. package/demos/pc/app/tabs/tabs-size-composition-api.vue +3 -3
  303. package/demos/pc/app/tabs/tabs-size.vue +3 -3
  304. package/demos/pc/app/tabs/tooltip-composition-api.vue +17 -13
  305. package/demos/pc/app/tabs/tooltip.vue +17 -13
  306. package/demos/pc/app/tabs/webdoc/tabs.js +35 -35
  307. package/demos/pc/app/tabs/with-add-composition-api.vue +1 -1
  308. package/demos/pc/app/tabs/with-add.vue +1 -1
  309. package/demos/pc/app/tag/{before-delete-composition-api.vue → delete-composition-api.vue} +6 -16
  310. package/demos/pc/app/tag/delete.spec.ts +19 -0
  311. package/demos/pc/app/tag/{closable.vue → delete.vue} +22 -5
  312. package/demos/pc/app/tag/webdoc/tag.js +15 -7
  313. package/demos/pc/app/time-line/webdoc/time-line.js +12 -12
  314. package/demos/pc/app/toggle-menu/webdoc/toggle-menu.js +64 -55
  315. package/demos/pc/app/tooltip/content.spec.js +1 -1
  316. package/demos/pc/app/tooltip/custom-popper.spec.js +4 -4
  317. package/demos/pc/app/transfer/basic-usage.spec.ts +7 -20
  318. package/demos/pc/app/transfer/custom-btns.spec.ts +11 -19
  319. package/demos/pc/app/transfer/custom-filter.spec.ts +6 -4
  320. package/demos/pc/app/transfer/custom-footer.spec.ts +1 -2
  321. package/demos/pc/app/transfer/custom-render.spec.ts +7 -5
  322. package/demos/pc/app/transfer/custom-titles.spec.ts +5 -3
  323. package/demos/pc/app/transfer/default-checked.spec.ts +5 -9
  324. package/demos/pc/app/transfer/drop-config.spec.ts +21 -16
  325. package/demos/pc/app/transfer/manual-clear-query.spec.ts +2 -2
  326. package/demos/pc/app/transfer/nested-table.spec.ts +12 -35
  327. package/demos/pc/app/transfer/nested-tree.spec.ts +3 -30
  328. package/demos/pc/app/transfer/target-order.spec.ts +2 -1
  329. package/demos/pc/app/transfer/transfer-events.spec.ts +2 -1
  330. package/demos/pc/app/tree/basic-usage.spec.ts +26 -16
  331. package/demos/pc/app/tree/check-op.spec.ts +37 -19
  332. package/demos/pc/app/tree/checkbox.spec.ts +23 -18
  333. package/demos/pc/app/tree/contextmenu.spec.ts +9 -8
  334. package/demos/pc/app/tree/drag.spec.ts +10 -18
  335. package/demos/pc/app/tree/edit.spec.ts +24 -103
  336. package/demos/pc/app/tree/expand-control.spec.ts +22 -18
  337. package/demos/pc/app/tree/filter-view.spec.ts +16 -18
  338. package/demos/pc/app/tree/icons.spec.ts +20 -18
  339. package/demos/pc/app/tree/lazy.spec.ts +10 -18
  340. package/demos/pc/app/tree/node-hl.spec.ts +27 -18
  341. package/demos/pc/app/tree/node-op-composition-api.vue +12 -6
  342. package/demos/pc/app/tree/node-op.spec.ts +32 -19
  343. package/demos/pc/app/tree/other.spec.ts +5 -18
  344. package/demos/pc/app/tree/props.spec.ts +7 -18
  345. package/demos/pc/app/tree/radio.spec.ts +10 -18
  346. package/demos/pc/app/tree/slot.spec.ts +12 -18
  347. package/demos/pc/app/tree/webdoc/tree.js +2 -2
  348. package/demos/pc/app/tree-menu/accordion.spec.ts +3 -1
  349. package/demos/pc/app/tree-menu/basic-usage.spec.ts +4 -2
  350. package/demos/pc/app/tree-menu/current-node-composition-api.vue +7 -3
  351. package/demos/pc/app/tree-menu/current-node.spec.ts +20 -13
  352. package/demos/pc/app/tree-menu/current-node.vue +8 -6
  353. package/demos/pc/app/tree-menu/custom-icon.spec.ts +12 -2
  354. package/demos/pc/app/tree-menu/data-resource.spec.ts +33 -21
  355. package/demos/pc/app/tree-menu/default-expand-all.spec.ts +25 -8
  356. package/demos/pc/app/tree-menu/default-expanded-keys-highlight.spec.ts +6 -4
  357. package/demos/pc/app/tree-menu/default-expanded-keys.spec.ts +11 -7
  358. package/demos/pc/app/tree-menu/draggable.spec.ts +11 -4
  359. package/demos/pc/app/tree-menu/empty-text.spec.ts +1 -1
  360. package/demos/pc/app/tree-menu/event-allow-draggable.spec.ts +4 -1
  361. package/demos/pc/app/tree-menu/events.spec.ts +56 -28
  362. package/demos/pc/app/tree-menu/expand-on-click-node.spec.ts +32 -3
  363. package/demos/pc/app/tree-menu/filter-node-method.spec.ts +9 -6
  364. package/demos/pc/app/tree-menu/filter-node-method.vue +0 -4
  365. package/demos/pc/app/tree-menu/indent.spec.ts +9 -4
  366. package/demos/pc/app/tree-menu/lazy-load.spec.ts +8 -4
  367. package/demos/pc/app/tree-menu/menu-collapsible.spec.ts +5 -2
  368. package/demos/pc/app/tree-menu/show-checkbox.spec.ts +79 -41
  369. package/demos/pc/app/tree-menu/text-ellipsis.spec.ts +7 -4
  370. package/demos/pc/app/tree-menu/tree-menu-slot.spec.ts +4 -3
  371. package/demos/pc/app/tree-menu/webdoc/tree-menu.cn.md +1 -1
  372. package/demos/pc/app/tree-menu/webdoc/tree-menu.en.md +1 -1
  373. package/demos/pc/app/tree-menu/webdoc/tree-menu.js +3 -3
  374. package/demos/pc/app/user-contact/webdoc/user-contact.js +21 -13
  375. package/demos/pc/app/user-head/icon-user-head.spec.ts +3 -3
  376. package/demos/pc/app/user-head/image-user-head.spec.ts +2 -2
  377. package/demos/pc/app/user-head/webdoc/user-head.js +44 -28
  378. package/demos/pc/webdoc/changelog.md +1 -0
  379. package/demos/pc/webdoc/import-components.md +2 -4
  380. package/demos/pc/webdoc/theme-en.md +8 -4
  381. package/demos/pc/webdoc/theme.md +10 -3
  382. package/package.json +6 -6
  383. package/src/App.vue +0 -2
  384. package/src/i18n/index.js +3 -3
  385. package/src/main.js +2 -7
  386. package/src/menus.jsx +1 -1
  387. package/src/tools/useApiMode.js +2 -2
  388. package/src/tools/useBulletin.jsx +2 -2
  389. package/src/tools/utils.js +2 -2
  390. package/src/views/components/VersionTip.vue +14 -8
  391. package/src/views/components/components.vue +48 -47
  392. package/src/views/components/demo.vue +11 -11
  393. package/src/views/docs/docs.vue +2 -3
  394. package/src/views/layout/layout.vue +17 -19
  395. package/src/views/overview.vue +16 -13
  396. package/vite.config.ts +10 -4
  397. package/demos/mobile/app/pull-refresh/disabled.vue +0 -57
  398. package/demos/mobile/app/pull-refresh/head-height.vue +0 -31
  399. package/demos/mobile/app/pull-refresh/result-text.vue +0 -46
  400. package/demos/mobile/app/pull-refresh/success-duration.vue +0 -31
  401. package/demos/mobile/app/pull-refresh/success-text.vue +0 -27
  402. package/demos/pc/app/grid/loading/grid-loading-off-tip.spec.js +0 -8
  403. package/demos/pc/app/tag/before-delete.vue +0 -64
  404. package/demos/pc/app/tag/closable-composition-api.vue +0 -25
  405. package/demos/pc/app/tag/closable.spec.ts +0 -14
  406. /package/demos/pc/app/button/{autofocus.spec.js → autofocus.spec.ts} +0 -0
  407. /package/demos/pc/app/button/{basic-usage.spec.js → basic-usage.spec.ts} +0 -0
  408. /package/demos/pc/app/button/{click.spec.js → click.spec.ts} +0 -0
  409. /package/demos/pc/app/button/{icon.spec.js → icon.spec.ts} +0 -0
  410. /package/demos/pc/app/button/{image.spec.js → image.spec.ts} +0 -0
  411. /package/demos/pc/app/button/{loading.spec.js → loading.spec.ts} +0 -0
  412. /package/demos/pc/app/button/{reset-time.spec.js → reset-time.spec.ts} +0 -0
  413. /package/demos/pc/app/button/{size.spec.js → size.spec.ts} +0 -0
  414. /package/demos/pc/app/button/{text.spec.js → text.spec.ts} +0 -0
@@ -4,15 +4,18 @@ test('文字超长省略显示', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('tree-menu#text-ellipsis')
6
6
 
7
- const treeMenu = page.locator('#preview .tiny-tree-menu')
7
+ const wrap = page.locator('#text-ellipsis')
8
+ const treeMenu = wrap.locator('.tiny-tree-menu').nth(0)
9
+
8
10
  await expect(treeMenu.locator('.tiny-tree')).toHaveClass(/tiny-tree-menu__overflow/)
9
11
  })
10
12
 
11
13
  test('文字超长换行显示', async ({ page }) => {
12
14
  page.on('pageerror', (exception) => expect(exception).toBeNull())
13
- await page.goto('tree-menu#text-wrap')
15
+ await page.goto('tree-menu#text-ellipsis')
16
+
17
+ const wrap = page.locator('#text-ellipsis')
18
+ const treeMenu = wrap.locator('.tiny-tree-menu').nth(1)
14
19
 
15
- const treeMenu = page.locator('#preview .tiny-tree-menu')
16
20
  await expect(treeMenu.locator('.tiny-tree')).toHaveClass(/tiny-tree-menu__wrap/)
17
21
  })
18
-
@@ -4,9 +4,10 @@ test('插槽', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('tree-menu#tree-menu-slot')
6
6
 
7
- const treeMenu = page.locator('#preview .tiny-tree-menu')
7
+ const treeMenu = page.locator('#tree-menu-slot .tiny-tree-menu')
8
+
8
9
  await expect(treeMenu.getByText('首页')).toHaveClass('treeClass')
9
10
  await expect(treeMenu.getByText('指南')).toHaveClass('treeNodeClass')
10
- await expect(treeMenu.getByTitle('首页').locator('.tiny-svg')).toHaveCSS('margin-right', '4px')
11
- await expect(treeMenu.getByTitle('教程').locator('.tiny-svg')).toHaveCSS('margin-left', '-20px')
11
+ await expect(treeMenu.getByTitle('首页').locator('.tiny-svg')).toHaveCSS('margin-left', '8px')
12
+ await expect(treeMenu.getByTitle('教程').locator('.tiny-svg')).toHaveCSS('margin-left', '8px')
12
13
  })
@@ -4,4 +4,4 @@ title: TreeMenu 树型菜单
4
4
 
5
5
  # TreeMenu 树型菜单
6
6
 
7
- > 以树形方式显示的菜单,适用于版型定制的一种组件。
7
+ 以树形方式显示的菜单,适用于版型定制的一种组件。
@@ -4,4 +4,4 @@ title: TreeMenu
4
4
 
5
5
  # TreeMenu
6
6
 
7
- > The menu is displayed in tree mode and is applicable to a component of version customization.
7
+ The menu is displayed in tree mode and is applicable to a component of version customization.
@@ -6,8 +6,8 @@ export default {
6
6
  'demoId': 'basic-usage',
7
7
  'name': { 'zh-CN': '基本用法', 'en-US': 'Basic Usage' },
8
8
  'desc': {
9
- 'zh-CN': '<p>不配置数据源时,默认从框架服务读取数据。</p>\n',
10
- 'en-US': '<p>If no data is configured, data is read from the framework service by default. </p>\n'
9
+ 'zh-CN': '<p>通过引用组件标签即可,默认从框架服务读取数据 。</p>\n',
10
+ 'en-US': '<p>By referencing component labels, data is read from the framework service by default. </p>\n'
11
11
  },
12
12
  'codeFiles': ['basic-usage.vue']
13
13
  },
@@ -294,7 +294,7 @@ export default {
294
294
  {
295
295
  'name': 'tree-menu',
296
296
  'type': 'component',
297
- 'properties': [
297
+ 'props': [
298
298
  {
299
299
  'name': 'accordion',
300
300
  'type': 'boolean',
@@ -5,7 +5,12 @@ export default {
5
5
  {
6
6
  'demoId': 'basic-usage',
7
7
  'name': { 'zh-CN': '基本用法', 'en-US': 'Basic Usage' },
8
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
8
+ 'desc': {
9
+ 'zh-CN':
10
+ '通过<code>:data</code>设置数据源。<code>imgUrl:图片路径</code><code>userName:姓名</code><code>userDescription:用户描述</code>。',
11
+ 'en-US':
12
+ 'Set the data source through<code>: data</code>.<code>imgUrl:"Image URL"</code><code>userName:"Name"</code><code>userDescription: User Description</code>.'
13
+ },
9
14
  'codeFiles': ['basic-usage.vue']
10
15
  },
11
16
  {
@@ -13,9 +18,9 @@ export default {
13
18
  'name': { 'zh-CN': '设置数据源', 'en-US': 'Set Data Source' },
14
19
  'desc': {
15
20
  'zh-CN':
16
- '<p>可通过 <code>data</code> 设置数据源, <code>imgUrl</code> 表示的是图片路径, <code>userName</code> 表示的是姓名, <code>userDescription</code> 表示的是用户描述。</p>\n',
21
+ '<p>通过 <code>:data</code> 设置数据源, <code>imgUrl</code> 表示的是图片路径, <code>userName</code> 表示的是姓名, <code>userDescription</code> 表示的是用户描述。</p>\n',
17
22
  'en-US':
18
- '<p>You can use <code>data</code> to set the data source. <code>imgUrl</code> indicates the image path, and <code>userName</code> indicates the name. <code>userDescription</code> indicates the user description. </p>\n'
23
+ '<p>Set the data source through<code>: data</code>. <code>imgUrl</code> indicates the image path, and <code>userName</code> indicates the name. <code>userDescription</code> indicates the user description. </p>\n'
19
24
  },
20
25
  'codeFiles': ['data-source.vue']
21
26
  },
@@ -27,16 +32,19 @@ export default {
27
32
  },
28
33
  'desc': {
29
34
  'zh-CN':
30
- '<p>定制弹框不显示的内容\n<code>show-img</code> 是否显示头像,值为 true 时显示, false 隐藏,默认 true。\n<code>show-name</code> 是否显示名字,值为 true 时显示, false 隐藏,默认 true。\n<code>show-number</code> 是否显示用户账号,值为 true 时显示, false 隐藏,默认 true。</p>\n',
35
+ '<p>通过设置<code>show-img</code> 是否显示头像,<code>show-name</code> 是否显示名字,<code>show-number</code> 是否显示用户账号,默认值为<code>true</code>。</p>',
31
36
  'en-US':
32
- '<p>Customize the content that is not displayed in the dialog box.\n<code>show-img</code>Indicates whether to display the avatar. The value true indicates that the avatar is displayed. The value false indicates that the avatar is hidden. The default value is true. \n<code>show-name</code> Indicates whether to display the name. The value true indicates that the name is displayed, and the value false indicates that the name is hidden. The default value is true. \n<code>show-number</code>Indicates whether to display the user account number. If the value is true, the user account number. is displayed. If the value is false, the user account number. is hidden. The default value is true. </p>\n'
37
+ '<p>By setting<code>show img</code>to display avatars,<code>show name</code>to display names, and<code>show number</code>to display user accounts, the default value is<code>true</code>.</p> '
33
38
  },
34
39
  'codeFiles': ['not-displayed-content.vue']
35
40
  },
36
41
  {
37
42
  'demoId': 'slots-usercontact',
38
43
  'name': { 'zh-CN': '自定义默认插槽', 'en-US': 'Customize the default slot' },
39
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
44
+ 'desc': {
45
+ 'zh-CN': '通过在组件内插入<code>div</code>元素即可。',
46
+ 'en-US': 'You can insert the<code>div</code>element within the component.'
47
+ },
40
48
  'codeFiles': ['slots-usercontact.vue']
41
49
  }
42
50
  ],
@@ -44,12 +52,12 @@ export default {
44
52
  {
45
53
  'name': 'user-contact',
46
54
  'type': 'component',
47
- 'properties': [
55
+ 'props': [
48
56
  {
49
57
  'name': 'data',
50
58
  'type': 'object',
51
59
  'defaultValue': '',
52
- 'desc': { 'zh-CN': '设置的数据;数据设置', 'en-US': 'Setted data; Data Settings' },
60
+ 'desc': { 'zh-CN': '设置的数据', 'en-US': 'Setted data; Data Settings' },
53
61
  'demoId': 'data-source'
54
62
  },
55
63
  {
@@ -58,7 +66,7 @@ export default {
58
66
  'defaultValue': '该属性的默认值为 true',
59
67
  'desc': {
60
68
  'zh-CN': '是否显示头像,默认 true',
61
- 'en-US': 'Indicates whether to display the avatar. The default value is true.'
69
+ 'en-US': 'Indicates whether to display the avatar. The default value is true'
62
70
  },
63
71
  'demoId': 'not-displayed-content'
64
72
  },
@@ -68,7 +76,7 @@ export default {
68
76
  'defaultValue': '该属性的默认值为 true',
69
77
  'desc': {
70
78
  'zh-CN': '是否显示姓名 userName,默认 true',
71
- 'en-US': 'Indicates whether to display userName. The default value is true.'
79
+ 'en-US': 'Indicates whether to display userName. The default value is true'
72
80
  },
73
81
  'demoId': 'not-displayed-content'
74
82
  },
@@ -78,7 +86,7 @@ export default {
78
86
  'defaultValue': '该属性的默认值为 true',
79
87
  'desc': {
80
88
  'zh-CN': '是否显示工号 roleNumber,默认 true',
81
- 'en-US': 'Indicates whether to display the employee ID roleNumber. The default value is true.'
89
+ 'en-US': 'Indicates whether to display the employee ID roleNumber. The default value is true'
82
90
  },
83
91
  'demoId': 'not-displayed-content'
84
92
  },
@@ -88,7 +96,7 @@ export default {
88
96
  'defaultValue': '',
89
97
  'desc': {
90
98
  'zh-CN': '为 popper 添加类名(可参考 popover 组件)',
91
- 'en-US': 'Add a class name for the popper. For details, see the popover component.'
99
+ 'en-US': 'Add a class name for the popper. For details, see the popover component'
92
100
  },
93
101
  'demoId': ''
94
102
  },
@@ -100,7 +108,7 @@ export default {
100
108
  'zh-CN':
101
109
  '是否将弹出框插入至 body 元素。在弹出框的定位出现问题时,可将该属性设置为 false (可参考 select 组件)',
102
110
  'en-US':
103
- 'Indicates whether to insert a pop-up box to the body element. If a fault occurs in locating the fault in the dialog box that is displayed, you can set this attribute to false (for details, see the select component).'
111
+ 'Indicates whether to insert a pop-up box to the body element. If a fault occurs in locating the fault in the dialog box that is displayed, you can set this attribute to false (for details, see the select component)'
104
112
  },
105
113
  'demoId': ''
106
114
  },
@@ -1,8 +1,8 @@
1
1
  import { test, expect } from '@playwright/test'
2
2
 
3
- test('图片头像', async ({ page }) => {
3
+ test('图标头像', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
- await page.goto('user-head#image-user-head')
6
- const minBox = page.locator('.tiny-user-head__portrait')
5
+ await page.goto('user-head#icon-user-head')
6
+ const minBox = page.locator('.tiny-user-head > .tiny-user-head__portrait')
7
7
  await expect(minBox).toHaveCSS('background-image', 'none')
8
8
  })
@@ -3,6 +3,6 @@ import { test, expect } from '@playwright/test'
3
3
  test('图片头像', async ({ page }) => {
4
4
  page.on('pageerror', (exception) => expect(exception).toBeNull())
5
5
  await page.goto('user-head#image-user-head')
6
- const headImg = page.locator('.tiny-user-head')
7
- await expect(headImg).toHaveAttribute('value', 'localhost:3000/webnova/static/img/compontent.b2f0f5b.png')
6
+ const minBox = page.locator('.tiny-user-head > .tiny-user-head__portrait')
7
+ await expect(minBox).toHaveCSS('color', 'rgb(255, 255, 255)')
8
8
  })
@@ -5,14 +5,17 @@ export default {
5
5
  {
6
6
  'demoId': 'basic-usage',
7
7
  'name': { 'zh-CN': '基本用法', 'en-US': 'Basic Usage' },
8
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
8
+ 'desc': {
9
+ 'zh-CN': '通过 <code>type="icon"</code> 设置头像。',
10
+ 'en-US': 'Set a profile picture through<code>type="icon"</code>.'
11
+ },
9
12
  'codeFiles': ['basic-usage.vue']
10
13
  },
11
14
  {
12
15
  'demoId': 'min-user-head',
13
16
  'name': { 'zh-CN': '小头像', 'en-US': 'Avatar' },
14
17
  'desc': {
15
- 'zh-CN': '<p>可通过 <code>min</code> 设置小头像。</p>\n',
18
+ 'zh-CN': '<p>通过 <code>min</code> 设置小头像。</p>\n',
16
19
  'en-US': '<p>You can use <code>min</code> to set a small avatar. </p>\n'
17
20
  },
18
21
  'codeFiles': ['min-user-head.vue']
@@ -21,7 +24,7 @@ export default {
21
24
  'demoId': 'round-user-head',
22
25
  'name': { 'zh-CN': '圆形头像', 'en-US': 'Round Head' },
23
26
  'desc': {
24
- 'zh-CN': '<p>可通过 <code>round</code> 设置圆形头像。</p>\n',
27
+ 'zh-CN': '<p>通过 <code>round</code> 设置圆形头像。</p>\n',
25
28
  'en-US': '<p>You can use <code>round</code> to set a round avatar. </p>\n'
26
29
  },
27
30
  'codeFiles': ['round-user-head.vue']
@@ -30,7 +33,7 @@ export default {
30
33
  'demoId': 'label-user-head',
31
34
  'name': { 'zh-CN': '文字头像', 'en-US': 'Avatar' },
32
35
  'desc': {
33
- 'zh-CN': '<p>可通过 <code>type=&quot;label&quot;</code> 设置文字头像。</p>\n',
36
+ 'zh-CN': '<p>通过 <code>type=&quot;label&quot;</code> 设置文字头像。</p>\n',
34
37
  'en-US': '<p>You can use <code>type=&quot;label&quot;</code> to set the text avatar. </p>\n'
35
38
  },
36
39
  'codeFiles': ['label-user-head.vue']
@@ -39,7 +42,7 @@ export default {
39
42
  'demoId': 'icon-user-head',
40
43
  'name': { 'zh-CN': '图标头像', 'en-US': 'Icon avatar' },
41
44
  'desc': {
42
- 'zh-CN': '<p>可通过 <code>type=&quot;icon&quot;</code> 设置图标头像。</p>\n',
45
+ 'zh-CN': '<p>通过 <code>type=&quot;icon&quot;</code> 设置图标头像。</p>\n',
43
46
  'en-US': '<p>You can use <code>type=&quot;icon&quot;</code> to set the icon avatar. </p>\n'
44
47
  },
45
48
  'codeFiles': ['icon-user-head.vue']
@@ -48,7 +51,7 @@ export default {
48
51
  'demoId': 'image-user-head',
49
52
  'name': { 'zh-CN': '图片头像', 'en-US': 'Avatar' },
50
53
  'desc': {
51
- 'zh-CN': '<p>可通过 <code>type=&quot;image&quot;</code> 设置图片头像。</p>\n',
54
+ 'zh-CN': '<p>通过 <code>type=&quot;image&quot;</code> 设置图片头像。</p>\n',
52
55
  'en-US': '<p>You can use <code>type=&quot;image&quot;</code> to set the picture avatar. </p>\n'
53
56
  },
54
57
  'codeFiles': ['image-user-head.vue']
@@ -56,19 +59,28 @@ export default {
56
59
  {
57
60
  'demoId': 'message-count-total',
58
61
  'name': { 'zh-CN': '头像消息计数', 'en-US': 'Avatar Message Count' },
59
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
62
+ 'desc': {
63
+ 'zh-CN': '通过<code>:message-total="100"</code>设置消息数据。',
64
+ 'en-US': `Set message data through<code>message-total='100'</code>. `
65
+ },
60
66
  'codeFiles': ['message-count-total.vue']
61
67
  },
62
68
  {
63
69
  'demoId': 'message-count-type',
64
- 'name': { 'zh-CN': '使用小红点代替具体数值', 'en-US': 'Use a red dot instead of a specific value.' },
65
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
70
+ 'name': { 'zh-CN': '使用小红点代替具体数值', 'en-US': 'Use a red dot instead of a specific value' },
71
+ 'desc': {
72
+ 'zh-CN': '通过<code>:message-type="basic"</code>设置消息显示替代成小红点。',
73
+ 'en-US': `Set the message display to be replaced with a small red dot through<code>message-type='basic'</code>.`
74
+ },
66
75
  'codeFiles': ['message-count-type.vue']
67
76
  },
68
77
  {
69
78
  'demoId': 'message-count-limit',
70
79
  'name': { 'zh-CN': '消息计数上限', 'en-US': 'Maximum number of messages' },
71
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
80
+ 'desc': {
81
+ 'zh-CN': '通过<code>:message-upper-limit="99"</code>设置消息数据上限。',
82
+ 'en-US': `Set the message data upper limit through<code>message-upper-limit='99'</code>.`
83
+ },
72
84
  'codeFiles': ['message-count-limit.vue']
73
85
  },
74
86
  {
@@ -76,7 +88,7 @@ export default {
76
88
  'name': { 'zh-CN': '自定义颜色', 'en-US': 'Custom Color' },
77
89
  'desc': {
78
90
  'zh-CN':
79
- '<p>可通过 <code>color</code> 自定义颜色,图标或文字类型(type属性值为 icon 或 label )的情况下,设置字体颜色和背景色。</p>\n',
91
+ '<p>通过 <code>color</code> 自定义颜色,图标或文字类型(type属性值为 icon 或 label )的情况下,设置字体颜色和背景色。</p>\n',
80
92
  'en-US':
81
93
  '<p>You can use <code>color</code> to customize the color. If the icon or text type is set to icon or label, set the font color and background color. </p>\n'
82
94
  },
@@ -86,7 +98,7 @@ export default {
86
98
  'demoId': 'custom-background-color',
87
99
  'name': { 'zh-CN': '自定义背景颜色', 'en-US': 'Custom background color' },
88
100
  'desc': {
89
- 'zh-CN': '<p>可通过 <code>background-color</code> 自定义背景颜色。</p>\n',
101
+ 'zh-CN': '<p>通过 <code>background-color</code> 自定义背景颜色。</p>\n',
90
102
  'en-US': '<p>You can use <code>background-color</code> to customize the background color. </p>\n'
91
103
  },
92
104
  'codeFiles': ['custom-background-color.vue']
@@ -103,7 +115,11 @@ export default {
103
115
  {
104
116
  'demoId': 'render-user-head-in-grid',
105
117
  'name': { 'zh-CN': 'Grid 单元格展示头像', 'en-US': 'Avatar Displayed in Grid Cells' },
106
- 'desc': { 'zh-CN': '详细用法参考如下示例', 'en-US': 'For details, see the following example.' },
118
+ 'desc': {
119
+ 'zh-CN': '通过Grid单元格属性<code>renderer</code>传入封装用户头像组件(HTML格式)。',
120
+ 'en-US':
121
+ 'Pass in the encapsulated user avatar component (in HTML format) through the Grid cell attribute<code>renderer</code>.'
122
+ },
107
123
  'codeFiles': ['render-user-head-in-grid.vue']
108
124
  }
109
125
  ],
@@ -111,35 +127,35 @@ export default {
111
127
  {
112
128
  'name': 'user-head',
113
129
  'type': 'component',
114
- 'properties': [
130
+ 'props': [
115
131
  {
116
132
  'name': 'background-color',
117
133
  'type': 'string',
118
- 'defaultValue': '#d9d9d9',
119
- 'desc': { 'zh-CN': '背景色', 'en-US': 'Background color.' },
134
+ 'defaultValue': `'#d9d9d9'`,
135
+ 'desc': { 'zh-CN': '背景色', 'en-US': 'Background color' },
120
136
  'demoId': 'custom-background-color'
121
137
  },
122
138
  {
123
139
  'name': 'color',
124
140
  'type': 'string',
125
- 'defaultValue': '#ffffff',
126
- 'desc': { 'zh-CN': '文字颜色', 'en-US': 'Text color.' },
141
+ 'defaultValue': `'#ffffff'`,
142
+ 'desc': { 'zh-CN': '文字颜色', 'en-US': 'Text color' },
127
143
  'demoId': 'color'
128
144
  },
129
145
  {
130
146
  'name': 'message-total',
131
147
  'type': 'number',
132
148
  'defaultValue': '',
133
- 'desc': { 'zh-CN': '消息计数', 'en-US': 'Number of messages.' },
149
+ 'desc': { 'zh-CN': '消息计数', 'en-US': 'Number of messages' },
134
150
  'demoId': 'message-count-total'
135
151
  },
136
152
  {
137
153
  'name': 'message-type',
138
154
  'type': 'string',
139
- 'defaultValue': 'details',
155
+ 'defaultValue': `'details'`,
140
156
  'desc': {
141
- 'zh-CN': '消息类型 details|basic 可选 。;该属性的可选值为 details / basic',
142
- 'en-US': 'Message type details|basic is optional. ;The value of this attribute can be details or basic'
157
+ 'zh-CN': '消息类型 details|basic 可选。该属性的可选值为 details / basic',
158
+ 'en-US': 'Message type details|basic is optional. The value of this attribute can be details or basic.'
143
159
  },
144
160
  'demoId': 'message-count-type'
145
161
  },
@@ -147,29 +163,29 @@ export default {
147
163
  'name': 'message-upper-limit',
148
164
  'type': 'number',
149
165
  'defaultValue': '0',
150
- 'desc': { 'zh-CN': '消息显示上限', 'en-US': 'Maximum number of displayed messages.' },
166
+ 'desc': { 'zh-CN': '消息显示上限', 'en-US': 'Maximum number of displayed messages' },
151
167
  'demoId': 'message-count-limit'
152
168
  },
153
169
  {
154
170
  'name': 'min',
155
171
  'type': 'boolean',
156
172
  'defaultValue': 'false',
157
- 'desc': { 'zh-CN': '小尺寸模式', 'en-US': 'Small size mode.' },
173
+ 'desc': { 'zh-CN': '小尺寸模式', 'en-US': 'Small size mode' },
158
174
  'demoId': 'min-user-head'
159
175
  },
160
176
  {
161
177
  'name': 'round',
162
178
  'type': 'boolean',
163
179
  'defaultValue': '',
164
- 'desc': { 'zh-CN': '圆形模式', 'en-US': 'Circular mode.' },
180
+ 'desc': { 'zh-CN': '圆形模式', 'en-US': 'Circular mode' },
165
181
  'demoId': 'round-user-head'
166
182
  },
167
183
  {
168
184
  'name': 'type',
169
185
  'type': 'string',
170
- 'defaultValue': 'label',
186
+ 'defaultValue': `'label'`,
171
187
  'desc': {
172
- 'zh-CN': '头像类型,icon|image|label 可选。;该属性的可选值为 icon / image / label',
188
+ 'zh-CN': '头像类型,icon|image|label 可选。该属性的可选值为 icon / image / label',
173
189
  'en-US':
174
190
  'Avatar type. The options are icon, image, and label. ;The value of this attribute can be icon / image / label'
175
191
  },
@@ -182,7 +198,7 @@ export default {
182
198
  'desc': {
183
199
  'zh-CN': 'type=icon 时为图标类名,type=label时为字体串,type=image时为资源路径',
184
200
  'en-US':
185
- 'If type is set to icon, it indicates the icon class name. If type is set to label, it indicates the font string. If type is set to image, it indicates the resource path.'
201
+ 'If type is set to icon, it indicates the icon class name. If type is set to label, it indicates the font string. If type is set to image, it indicates the resource path'
186
202
  },
187
203
  'demoId': 'icon-user-head'
188
204
  }
@@ -6,6 +6,7 @@
6
6
 
7
7
  ### Exciting New Features 🎉
8
8
 
9
+ - feat: 新增 QrCode 二维码、Watermark 水印两个全新组件 🎊
9
10
  - feat(Timeline): Timeline component adapts to new themes by @Huangyilin19 in https://github.com/opentiny/tiny-vue/pull/615
10
11
  - feat(grid-slot):Add Table Header Slot by @ianxinnew in https://github.com/opentiny/tiny-vue/pull/674
11
12
  - feat(components): [date-picker] add props time-editable by @kagol in https://github.com/opentiny/tiny-vue/pull/696
@@ -68,16 +68,14 @@ export default {
68
68
  )
69
69
  ],
70
70
  define: {
71
- 'process.env': Object.assign({}, process.env)
71
+ 'process.env': { ...process.env }
72
72
  }
73
73
  }
74
74
  ```
75
75
 
76
76
  #### 温馨提示:
77
77
 
78
- `pnpm` 工程使用该插件时需要在 `package.json` 文件中逐个声明用到的每一个 `TinyVue` 组件依赖,因为 `pnpm` 特点就是用到的依赖就需要提前声明,防止幽灵依赖。
79
-
80
- 依赖声明可以参考一下配置
78
+ 因为 `pnpm` 工程的特点之一是:项目中显示引入的依赖需要提前在 `package.json` 中声明(防止幽灵依赖),所以在 `pnpm` 工程使用该插件时需要在 `package.json` 中声明项目用到的每一个 `TinyVue` 组件依赖(`TinyVue` 每个组件都是一个 `npm` 包)。依赖声明可以参考以下配置:
81
79
 
82
80
  ```json
83
81
  {
@@ -96,10 +96,10 @@ If you want to control the `css` variable through `js`, you can do this:
96
96
  ```js
97
97
  const el = document.documentElement
98
98
 
99
- //Obtain the CSS variable.
99
+ // Obtain the CSS variable.
100
100
  getComputedStyle(el).getPropertyValue('--ti-base-color-white')
101
101
 
102
- //Set the CSS variable.
102
+ // Set the CSS variable.
103
103
  el.style.setProperty('--ti-base-color-white', '#fefefe')
104
104
  ```
105
105
 
@@ -115,11 +115,15 @@ Replace all the old variable names in the `src` directory in the project as an e
115
115
 
116
116
  Step 1: Click to download the mapping table `newVars.json` and the replacement script `replaceVar.js`.
117
117
 
118
- <a :href="$pub('@demos/resource/newVars.json')" target="_blank" download="newVars.json">newVars.json files</a> and <a :href="$pub('@demos/resource/replaceVar.js')" target="_blank" download="replaceVar.js">replaceVar.js files</a>
118
+ <script setup>
119
+ import { pubUrl } from '@/tools'
120
+ </script>
121
+
122
+ <a :href="pubUrl('@demos/resource/newVars.json')" target="_blank" download="newVars.json">newVars.json files</a> and <a :href="pubUrl('@demos/resource/replaceVar.js')" target="_blank" download="replaceVar.js">replaceVar.js files</a>
119
123
 
120
124
  Step 2: Place `newVars.json` and `replaceVar.js` in the root directory of the project, which is at the same level as the src directory.
121
125
 
122
- <img src="@demos/resource/theme-demo.png" class="image" style="box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.14); width: 30vw" ><br><br>
126
+ <img :src="pubUrl('@demos/resource/theme-demo.png')" class="image" style="box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.14); width: 30vw" ><br><br>
123
127
 
124
128
  Step 3: Run the following command in the root directory of the project:
125
129
 
@@ -47,7 +47,10 @@ resolve: {
47
47
 
48
48
  ```js
49
49
  import TinyThemeTool from '@opentiny/vue-theme/theme-tool'
50
- import { tinySmbTheme } from '@opentiny/vue-theme/theme' // 导入主题
50
+
51
+ import { tinySmbTheme } from '@opentiny/vue-theme/theme'
52
+
53
+ // 导入主题
51
54
 
52
55
  new TinyThemeTool(tinySmbTheme, 'tinyStyleSheetId') // 初始化主题
53
56
  ```
@@ -162,11 +165,15 @@ el.style.setProperty('--ti-base-color-white', '#fefefe')
162
165
 
163
166
  步骤一、点击下载新旧变量的映射表`newVars.json`和替换脚本`replaceVar.js`
164
167
 
165
- <a :href="$pub('@demos/resource/newVars.json')" target="_blank" download="newVars.json">newVars.json 文件</a> 和 <a :href="$pub('@demos/resource/replaceVar.js')" target="_blank" download="replaceVar.js">replaceVar.js 文件</a>
168
+ <script setup>
169
+ import { pubUrl } from '@/tools'
170
+ </script>
171
+
172
+ <a :href="pubUrl('@demos/resource/newVars.json')" target="_blank" download="newVars.json">newVars.json 文件</a> 和 <a :href="pubUrl('@demos/resource/replaceVar.js')" target="_blank" download="replaceVar.js">replaceVar.js 文件</a>
166
173
 
167
174
  步骤二、将 `newVars.json` 和 `replaceVar.js` 放到项目根目录下,与 src 目录同级;
168
175
 
169
- <img src="@demos/resource/theme-demo.png" class="image" style="box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.14); width: 30vw" ><br><br>
176
+ <img :src="pubUrl('@demos/resource/theme-demo.png')" class="image" style="box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.14); width: 30vw" ><br><br>
170
177
 
171
178
  步骤三、在项目根目录下,执行以下命令进行替换;
172
179
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opentiny/vue-docs",
3
- "version": "2.2.4",
3
+ "version": "2.2.6",
4
4
  "dependencies": {
5
5
  "@unocss/reset": "0.38.2",
6
6
  "@vue/repl": "^2.5.5",
@@ -17,15 +17,15 @@
17
17
  "sortablejs": "1.15.0",
18
18
  "@opentiny/vue-repl": "^1.1.0",
19
19
  "@opentiny/vue": "~3.12.0",
20
- "@opentiny/vue-icon": "~3.12.0",
21
20
  "@opentiny/vue-common": "~3.12.0",
21
+ "@opentiny/vue-design-aurora": "~3.12.0",
22
+ "@opentiny/vue-icon": "~3.12.0",
23
+ "@opentiny/vue-design-smb": "~3.12.0",
22
24
  "@opentiny/vue-icon-saas": "~3.12.0",
25
+ "@opentiny/vue-theme": "~3.12.0",
23
26
  "@opentiny/vue-theme-mobile": "~3.12.0",
24
- "@opentiny/vue-design-smb": "~3.12.0",
25
- "@opentiny/vue-design-aurora": "~3.12.0",
26
27
  "@opentiny/vue-vite-import": "~1.1.5",
27
- "@opentiny/vue-theme-saas": "~3.12.0",
28
- "@opentiny/vue-theme": "~3.12.0"
28
+ "@opentiny/vue-theme-saas": "~3.12.0"
29
29
  },
30
30
  "devDependencies": {
31
31
  "@types/markdown-it": "^12.2.3",
package/src/App.vue CHANGED
@@ -16,7 +16,6 @@ import { ConfigProvider, Modal } from '@opentiny/vue'
16
16
  import { iconClose } from '@opentiny/vue-icon'
17
17
  import { appData } from './tools'
18
18
  import useTheme from './tools/useTheme'
19
- import { useBulletin } from './tools/useBulletin.jsx'
20
19
 
21
20
  export default defineComponent({
22
21
  name: 'AppVue',
@@ -43,7 +42,6 @@ export default defineComponent({
43
42
  common.renderHeader()
44
43
  })
45
44
  const { designConfig } = useTheme()
46
- useBulletin()
47
45
 
48
46
  provide('showPreview', (url) => {
49
47
  previewUrl.value = url
package/src/i18n/index.js CHANGED
@@ -20,7 +20,7 @@ const i18n = initI18n({
20
20
  },
21
21
  messages
22
22
  })
23
- const $t = i18n.global.t
24
- const $t2 = (cn, en) => (i18n.global.locale === 'zhCN' ? cn : en)
23
+ const i18nByKey = i18n.global.t
24
+ const getWord = (cn, en) => (i18n.global.locale === 'zhCN' ? cn : en)
25
25
 
26
- export { i18n, $t, $t2 }
26
+ export { i18n, i18nByKey, getWord }
package/src/main.js CHANGED
@@ -21,8 +21,7 @@ import './assets/custom-block.less'
21
21
  import { i18n } from './i18n/index'
22
22
  import { router } from './router'
23
23
  import App from './App.vue'
24
- import { $t, $t2 } from './i18n'
25
- import { $pub, appData } from './tools'
24
+ import { appData } from './tools'
26
25
  import { ZH_CN_LANG, EN_US_LANG, LANG_PATH_MAP } from './const'
27
26
  import demoConfig from '@demos/config.js'
28
27
 
@@ -62,11 +61,7 @@ if (import.meta.env.VITE_TINY_THEME === 'saas') {
62
61
  import('./tailwind.css')
63
62
  }
64
63
 
65
- app
66
- .use(router)
67
- .use(i18n)
68
- .use(createHead()) // 支持md修改title
69
- .mixin({ methods: { $t, $t2, $pub } })
64
+ app.use(router).use(i18n).use(createHead()) // 支持md修改title
70
65
 
71
66
  if (typeof demoConfig.initApp === 'function') {
72
67
  demoConfig.initApp(app)
package/src/menus.jsx CHANGED
@@ -1,6 +1,6 @@
1
1
  import { docMenus, cmpMenus } from '@menu/menus.js'
2
2
 
3
- import { appData, $t2 } from './tools'
3
+ import { appData } from './tools'
4
4
 
5
5
  /**
6
6
  * 聚合doc / cmp 两个页面的所有菜单.
@@ -4,8 +4,8 @@ import { $local } from './storage'
4
4
  const _modeKey = 'tiny-vue-api-mode'
5
5
  const _demoModeKey = 'tiny-vue-demo-mode'
6
6
  const apiModeState = reactive({
7
- apiMode: $local[_modeKey] || 'Options',
8
- demoMode: $local[_demoModeKey] || 'single' // 示例展示: default:多示例, single:单示例
7
+ apiMode: $local[_modeKey] || 'Composition',
8
+ demoMode: $local[_demoModeKey] || 'default' // 示例展示: default:多示例, single:单示例
9
9
  })
10
10
 
11
11
  const apiModeFn = {
@@ -5,8 +5,8 @@ import { Modal } from '@opentiny/vue'
5
5
  const bulletins = [
6
6
  {
7
7
  id: 'version-tip',
8
- content: `为了避免 @opentiny/vue 的月度版本(minor)升级带来的不确定因素,所以推荐在您的工程中的 package.json 中依赖包的版本号前使用 ~,
9
- 比如 "@opentiny/vue": "~3.12.0。`,
8
+ content: `为了避免 @opentiny/vue 的月度版本(minor)升级带来的不确定因素,推荐在您的工程中的 package.json 中依赖包的版本号前使用 ~,
9
+ 比如 "@opentiny/vue": "~3.12.0"。`,
10
10
  time: '2023-12-04'
11
11
  }
12
12
  ]