@berqnet/theme 0.0.0-stage → 2.4.292
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +111 -2
- package/dist/module.cjs +5 -0
- package/dist/module.d.mts +12 -0
- package/dist/module.d.ts +12 -0
- package/dist/module.json +9 -0
- package/dist/module.mjs +194 -0
- package/dist/runtime/assets/scss/main.css +18832 -0
- package/dist/runtime/components/development/example.alert.vue +47 -0
- package/dist/runtime/components/development/example.avatar.vue +88 -0
- package/dist/runtime/components/development/example.badge.vue +95 -0
- package/dist/runtime/components/development/example.breadcrumb.vue +58 -0
- package/dist/runtime/components/development/example.button.vue +250 -0
- package/dist/runtime/components/development/example.card.vue +68 -0
- package/dist/runtime/components/development/example.checkbox.vue +191 -0
- package/dist/runtime/components/development/example.checkbox.vue.d.ts +134 -0
- package/dist/runtime/components/development/example.collapse.vue +38 -0
- package/dist/runtime/components/development/example.datepicker.vue +196 -0
- package/dist/runtime/components/development/example.description.vue +144 -0
- package/dist/runtime/components/development/example.dialog.vue +76 -0
- package/dist/runtime/components/development/example.dropdown.vue +194 -0
- package/dist/runtime/components/development/example.form.vue +497 -0
- package/dist/runtime/components/development/example.input.vue +275 -0
- package/dist/runtime/components/development/example.link.vue +94 -0
- package/dist/runtime/components/development/example.menu.vue +237 -0
- package/dist/runtime/components/development/example.message.vue +68 -0
- package/dist/runtime/components/development/example.notification.vue +77 -0
- package/dist/runtime/components/development/example.number.vue +74 -0
- package/dist/runtime/components/development/example.pagination.vue +100 -0
- package/dist/runtime/components/development/example.popover.vue +146 -0
- package/dist/runtime/components/development/example.radio.vue +178 -0
- package/dist/runtime/components/development/example.radio.vue.d.ts +26 -0
- package/dist/runtime/components/development/example.select.vue +619 -0
- package/dist/runtime/components/development/example.select.vue.d.ts +70 -0
- package/dist/runtime/components/development/example.sidebar.vue +106 -0
- package/dist/runtime/components/development/example.static.vue +51 -0
- package/dist/runtime/components/development/example.switch.vue +102 -0
- package/dist/runtime/components/development/example.tab.vue +48 -0
- package/dist/runtime/components/development/example.table.vue +333 -0
- package/dist/runtime/components/development/example.tag.vue +268 -0
- package/dist/runtime/components/development/example.timepicker.vue +95 -0
- package/dist/runtime/components/development/example.tooltip.vue +104 -0
- package/dist/runtime/components/development/example.upload.vue +89 -0
- package/dist/runtime/components/production/html-encode.vue +99 -0
- package/dist/runtime/layouts/berqnet-modules.vue +34 -0
- package/dist/runtime/pages/colors.vue +142 -0
- package/dist/runtime/pages/theme.vue +60 -0
- package/dist/runtime/plugins/disable-warnings-plugin.d.ts +2 -0
- package/dist/runtime/plugins/disable-warnings-plugin.js +37 -0
- package/dist/runtime/plugins/disable-warnings-plugin.mjs +37 -0
- package/dist/runtime/plugins/sample-plugin.d.ts +20 -0
- package/dist/runtime/plugins/sample-plugin.js +5 -0
- package/dist/runtime/plugins/sample-plugin.mjs +5 -0
- package/dist/runtime/plugins/theme-provider-plugin.d.ts +30 -0
- package/dist/runtime/plugins/theme-provider-plugin.js +46 -0
- package/dist/runtime/plugins/theme-provider-plugin.mjs +46 -0
- package/dist/runtime/public/scss/_buttons.scss +157 -0
- package/dist/runtime/public/scss/_colors.scss +163 -0
- package/dist/runtime/public/scss/_containers.scss +7 -0
- package/dist/runtime/public/scss/_fonts.scss +84 -0
- package/dist/runtime/public/scss/_icons.scss +111 -0
- package/dist/runtime/public/scss/_inputs.scss +64 -0
- package/dist/runtime/public/scss/_layers.scss +9 -0
- package/dist/runtime/public/scss/_logo.scss +53 -0
- package/dist/runtime/public/scss/_selectbox.scss +4 -0
- package/dist/runtime/public/scss/_tag.scss +0 -0
- package/dist/runtime/public/scss/_variables.scss +16 -0
- package/dist/runtime/public/scss/element-plus/affix.css +305 -0
- package/dist/runtime/public/scss/element-plus/affix.scss +7 -0
- package/dist/runtime/public/scss/element-plus/alert.css +523 -0
- package/dist/runtime/public/scss/element-plus/alert.scss +160 -0
- package/dist/runtime/public/scss/element-plus/anchor-link.css +332 -0
- package/dist/runtime/public/scss/element-plus/anchor-link.scss +41 -0
- package/dist/runtime/public/scss/element-plus/anchor.css +376 -0
- package/dist/runtime/public/scss/element-plus/anchor.scss +93 -0
- package/dist/runtime/public/scss/element-plus/aside.css +308 -0
- package/dist/runtime/public/scss/element-plus/aside.scss +8 -0
- package/dist/runtime/public/scss/element-plus/autocomplete.css +411 -0
- package/dist/runtime/public/scss/element-plus/autocomplete.scss +85 -0
- package/dist/runtime/public/scss/element-plus/avatar.css +374 -0
- package/dist/runtime/public/scss/element-plus/avatar.scss +56 -0
- package/dist/runtime/public/scss/element-plus/backtop.css +326 -0
- package/dist/runtime/public/scss/element-plus/backtop.scss +29 -0
- package/dist/runtime/public/scss/element-plus/badge.css +376 -0
- package/dist/runtime/public/scss/element-plus/badge.scss +54 -0
- package/dist/runtime/public/scss/element-plus/base.css +559 -0
- package/dist/runtime/public/scss/element-plus/base.scss +3 -0
- package/dist/runtime/public/scss/element-plus/breadcrumb-item.css +0 -0
- package/dist/runtime/public/scss/element-plus/breadcrumb-item.scss +0 -0
- package/dist/runtime/public/scss/element-plus/breadcrumb.css +370 -0
- package/dist/runtime/public/scss/element-plus/breadcrumb.scss +77 -0
- package/dist/runtime/public/scss/element-plus/button-group.css +535 -0
- package/dist/runtime/public/scss/element-plus/button-group.scss +111 -0
- package/dist/runtime/public/scss/element-plus/button.css +1103 -0
- package/dist/runtime/public/scss/element-plus/button.scss +374 -0
- package/dist/runtime/public/scss/element-plus/calendar.css +370 -0
- package/dist/runtime/public/scss/element-plus/calendar.scss +80 -0
- package/dist/runtime/public/scss/element-plus/card.css +349 -0
- package/dist/runtime/public/scss/element-plus/card.scss +56 -0
- package/dist/runtime/public/scss/element-plus/carousel-item.css +350 -0
- package/dist/runtime/public/scss/element-plus/carousel-item.scss +58 -0
- package/dist/runtime/public/scss/element-plus/carousel.css +475 -0
- package/dist/runtime/public/scss/element-plus/carousel.scss +183 -0
- package/dist/runtime/public/scss/element-plus/cascader-panel.css +438 -0
- package/dist/runtime/public/scss/element-plus/cascader-panel.scss +148 -0
- package/dist/runtime/public/scss/element-plus/cascader.css +560 -0
- package/dist/runtime/public/scss/element-plus/cascader.scss +218 -0
- package/dist/runtime/public/scss/element-plus/check-tag.css +386 -0
- package/dist/runtime/public/scss/element-plus/check-tag.scss +38 -0
- package/dist/runtime/public/scss/element-plus/checkbox-button.css +446 -0
- package/dist/runtime/public/scss/element-plus/checkbox-button.scss +141 -0
- package/dist/runtime/public/scss/element-plus/checkbox-group.css +311 -0
- package/dist/runtime/public/scss/element-plus/checkbox-group.scss +13 -0
- package/dist/runtime/public/scss/element-plus/checkbox.css +587 -0
- package/dist/runtime/public/scss/element-plus/checkbox.scss +293 -0
- package/dist/runtime/public/scss/element-plus/col.css +3270 -0
- package/dist/runtime/public/scss/element-plus/col.scss +48 -0
- package/dist/runtime/public/scss/element-plus/collapse-item.css +0 -0
- package/dist/runtime/public/scss/element-plus/collapse-item.scss +0 -0
- package/dist/runtime/public/scss/element-plus/collapse-transition.css +0 -0
- package/dist/runtime/public/scss/element-plus/collapse-transition.scss +0 -0
- package/dist/runtime/public/scss/element-plus/collapse.css +499 -0
- package/dist/runtime/public/scss/element-plus/collapse.scss +85 -0
- package/dist/runtime/public/scss/element-plus/color/index.css +0 -0
- package/dist/runtime/public/scss/element-plus/color/index.scss +17 -0
- package/dist/runtime/public/scss/element-plus/color-picker.css +650 -0
- package/dist/runtime/public/scss/element-plus/color-picker.scss +365 -0
- package/dist/runtime/public/scss/element-plus/common/popup.css +338 -0
- package/dist/runtime/public/scss/element-plus/common/popup.scss +47 -0
- package/dist/runtime/public/scss/element-plus/common/transition.css +420 -0
- package/dist/runtime/public/scss/element-plus/common/transition.scss +124 -0
- package/dist/runtime/public/scss/element-plus/common/var.css +302 -0
- package/dist/runtime/public/scss/element-plus/common/var.scss +1676 -0
- package/dist/runtime/public/scss/element-plus/config-provider.css +0 -0
- package/dist/runtime/public/scss/element-plus/config-provider.scss +0 -0
- package/dist/runtime/public/scss/element-plus/container.css +313 -0
- package/dist/runtime/public/scss/element-plus/container.scss +14 -0
- package/dist/runtime/public/scss/element-plus/dark/css-vars.css +353 -0
- package/dist/runtime/public/scss/element-plus/dark/css-vars.scss +39 -0
- package/dist/runtime/public/scss/element-plus/dark/var.css +302 -0
- package/dist/runtime/public/scss/element-plus/dark/var.scss +222 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-picker.css +558 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-picker.scss +109 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-range-picker.css +410 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-range-picker.scss +117 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-table.css +426 -0
- package/dist/runtime/public/scss/element-plus/date-picker/date-table.scss +158 -0
- package/dist/runtime/public/scss/element-plus/date-picker/month-table.css +388 -0
- package/dist/runtime/public/scss/element-plus/date-picker/month-table.scss +112 -0
- package/dist/runtime/public/scss/element-plus/date-picker/picker-panel.css +454 -0
- package/dist/runtime/public/scss/element-plus/date-picker/picker-panel.scss +168 -0
- package/dist/runtime/public/scss/element-plus/date-picker/picker.css +668 -0
- package/dist/runtime/public/scss/element-plus/date-picker/picker.scss +198 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-picker.css +384 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-picker.scss +98 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-range-picker.css +338 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-range-picker.scss +40 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-spinner.css +389 -0
- package/dist/runtime/public/scss/element-plus/date-picker/time-spinner.scss +110 -0
- package/dist/runtime/public/scss/element-plus/date-picker/year-table.css +384 -0
- package/dist/runtime/public/scss/element-plus/date-picker/year-table.scss +108 -0
- package/dist/runtime/public/scss/element-plus/date-picker.css +1537 -0
- package/dist/runtime/public/scss/element-plus/date-picker.scss +9 -0
- package/dist/runtime/public/scss/element-plus/descriptions-item.css +347 -0
- package/dist/runtime/public/scss/element-plus/descriptions-item.scss +69 -0
- package/dist/runtime/public/scss/element-plus/descriptions.css +438 -0
- package/dist/runtime/public/scss/element-plus/descriptions.scss +212 -0
- package/dist/runtime/public/scss/element-plus/dialog.css +546 -0
- package/dist/runtime/public/scss/element-plus/dialog.scss +196 -0
- package/dist/runtime/public/scss/element-plus/display.css +357 -0
- package/dist/runtime/public/scss/element-plus/display.scss +12 -0
- package/dist/runtime/public/scss/element-plus/divider.css +345 -0
- package/dist/runtime/public/scss/element-plus/divider.scss +48 -0
- package/dist/runtime/public/scss/element-plus/drawer.css +419 -0
- package/dist/runtime/public/scss/element-plus/drawer.scss +155 -0
- package/dist/runtime/public/scss/element-plus/dropdown-item.css +0 -0
- package/dist/runtime/public/scss/element-plus/dropdown-item.scss +0 -0
- package/dist/runtime/public/scss/element-plus/dropdown-menu.css +0 -0
- package/dist/runtime/public/scss/element-plus/dropdown-menu.scss +0 -0
- package/dist/runtime/public/scss/element-plus/dropdown.css +499 -0
- package/dist/runtime/public/scss/element-plus/dropdown.scss +216 -0
- package/dist/runtime/public/scss/element-plus/empty.css +355 -0
- package/dist/runtime/public/scss/element-plus/empty.scss +49 -0
- package/dist/runtime/public/scss/element-plus/footer.css +310 -0
- package/dist/runtime/public/scss/element-plus/footer.scss +12 -0
- package/dist/runtime/public/scss/element-plus/form-item.css +0 -0
- package/dist/runtime/public/scss/element-plus/form-item.scss +0 -0
- package/dist/runtime/public/scss/element-plus/form.css +547 -0
- package/dist/runtime/public/scss/element-plus/form.scss +328 -0
- package/dist/runtime/public/scss/element-plus/header.css +310 -0
- package/dist/runtime/public/scss/element-plus/header.scss +12 -0
- package/dist/runtime/public/scss/element-plus/icon.css +343 -0
- package/dist/runtime/public/scss/element-plus/icon.scss +45 -0
- package/dist/runtime/public/scss/element-plus/image-viewer.css +439 -0
- package/dist/runtime/public/scss/element-plus/image-viewer.scss +139 -0
- package/dist/runtime/public/scss/element-plus/image.css +343 -0
- package/dist/runtime/public/scss/element-plus/image.scss +49 -0
- package/dist/runtime/public/scss/element-plus/index.css +17940 -0
- package/dist/runtime/public/scss/element-plus/index.scss +110 -0
- package/dist/runtime/public/scss/element-plus/infinite-scroll.css +0 -0
- package/dist/runtime/public/scss/element-plus/infinite-scroll.scss +0 -0
- package/dist/runtime/public/scss/element-plus/input-number.css +506 -0
- package/dist/runtime/public/scss/element-plus/input-number.scss +205 -0
- package/dist/runtime/public/scss/element-plus/input.css +771 -0
- package/dist/runtime/public/scss/element-plus/input.scss +534 -0
- package/dist/runtime/public/scss/element-plus/link.css +603 -0
- package/dist/runtime/public/scss/element-plus/link.scss +132 -0
- package/dist/runtime/public/scss/element-plus/loading.css +392 -0
- package/dist/runtime/public/scss/element-plus/loading.scss +103 -0
- package/dist/runtime/public/scss/element-plus/main.css +312 -0
- package/dist/runtime/public/scss/element-plus/main.scss +15 -0
- package/dist/runtime/public/scss/element-plus/mention.css +413 -0
- package/dist/runtime/public/scss/element-plus/mention.scss +84 -0
- package/dist/runtime/public/scss/element-plus/menu-item-group.css +0 -0
- package/dist/runtime/public/scss/element-plus/menu-item-group.scss +0 -0
- package/dist/runtime/public/scss/element-plus/menu-item.css +0 -0
- package/dist/runtime/public/scss/element-plus/menu-item.scss +0 -0
- package/dist/runtime/public/scss/element-plus/menu.css +765 -0
- package/dist/runtime/public/scss/element-plus/menu.scss +360 -0
- package/dist/runtime/public/scss/element-plus/message-box.css +576 -0
- package/dist/runtime/public/scss/element-plus/message-box.scss +238 -0
- package/dist/runtime/public/scss/element-plus/message.css +529 -0
- package/dist/runtime/public/scss/element-plus/message.scss +165 -0
- package/dist/runtime/public/scss/element-plus/mixins/_button.scss +241 -0
- package/dist/runtime/public/scss/element-plus/mixins/_col.scss +33 -0
- package/dist/runtime/public/scss/element-plus/mixins/_var.scss +59 -0
- package/dist/runtime/public/scss/element-plus/mixins/config.css +0 -0
- package/dist/runtime/public/scss/element-plus/mixins/config.scss +5 -0
- package/dist/runtime/public/scss/element-plus/mixins/function.css +0 -0
- package/dist/runtime/public/scss/element-plus/mixins/function.scss +86 -0
- package/dist/runtime/public/scss/element-plus/mixins/mixins.css +302 -0
- package/dist/runtime/public/scss/element-plus/mixins/mixins.scss +232 -0
- package/dist/runtime/public/scss/element-plus/mixins/utils.css +0 -0
- package/dist/runtime/public/scss/element-plus/mixins/utils.scss +39 -0
- package/dist/runtime/public/scss/element-plus/notification.css +414 -0
- package/dist/runtime/public/scss/element-plus/notification.scss +104 -0
- package/dist/runtime/public/scss/element-plus/option-group.css +331 -0
- package/dist/runtime/public/scss/element-plus/option-group.scss +38 -0
- package/dist/runtime/public/scss/element-plus/option.css +363 -0
- package/dist/runtime/public/scss/element-plus/option.scss +84 -0
- package/dist/runtime/public/scss/element-plus/overlay.css +316 -0
- package/dist/runtime/public/scss/element-plus/overlay.scss +20 -0
- package/dist/runtime/public/scss/element-plus/page-header.css +351 -0
- package/dist/runtime/public/scss/element-plus/page-header.scss +60 -0
- package/dist/runtime/public/scss/element-plus/pagination.css +594 -0
- package/dist/runtime/public/scss/element-plus/pagination.scss +255 -0
- package/dist/runtime/public/scss/element-plus/popconfirm.css +315 -0
- package/dist/runtime/public/scss/element-plus/popconfirm.scss +16 -0
- package/dist/runtime/public/scss/element-plus/popover.css +411 -0
- package/dist/runtime/public/scss/element-plus/popover.scss +85 -0
- package/dist/runtime/public/scss/element-plus/popper.css +405 -0
- package/dist/runtime/public/scss/element-plus/popper.scss +127 -0
- package/dist/runtime/public/scss/element-plus/progress.css +449 -0
- package/dist/runtime/public/scss/element-plus/progress.scss +179 -0
- package/dist/runtime/public/scss/element-plus/radio-button.css +435 -0
- package/dist/runtime/public/scss/element-plus/radio-button.scss +138 -0
- package/dist/runtime/public/scss/element-plus/radio-group.css +311 -0
- package/dist/runtime/public/scss/element-plus/radio-group.scss +13 -0
- package/dist/runtime/public/scss/element-plus/radio.css +565 -0
- package/dist/runtime/public/scss/element-plus/radio.scss +246 -0
- package/dist/runtime/public/scss/element-plus/rate.css +384 -0
- package/dist/runtime/public/scss/element-plus/rate.scss +108 -0
- package/dist/runtime/public/scss/element-plus/reset.css +399 -0
- package/dist/runtime/public/scss/element-plus/reset.scss +97 -0
- package/dist/runtime/public/scss/element-plus/result.css +381 -0
- package/dist/runtime/public/scss/element-plus/result.scss +57 -0
- package/dist/runtime/public/scss/element-plus/row.css +339 -0
- package/dist/runtime/public/scss/element-plus/row.scss +35 -0
- package/dist/runtime/public/scss/element-plus/scrollbar.css +373 -0
- package/dist/runtime/public/scss/element-plus/scrollbar.scss +85 -0
- package/dist/runtime/public/scss/element-plus/segmented.css +460 -0
- package/dist/runtime/public/scss/element-plus/segmented.scss +160 -0
- package/dist/runtime/public/scss/element-plus/select-dropdown-v2.css +354 -0
- package/dist/runtime/public/scss/element-plus/select-dropdown-v2.scss +1 -0
- package/dist/runtime/public/scss/element-plus/select-dropdown.css +354 -0
- package/dist/runtime/public/scss/element-plus/select-dropdown.scss +60 -0
- package/dist/runtime/public/scss/element-plus/select-v2.css +852 -0
- package/dist/runtime/public/scss/element-plus/select-v2.scss +4 -0
- package/dist/runtime/public/scss/element-plus/select.css +852 -0
- package/dist/runtime/public/scss/element-plus/select.scss +354 -0
- package/dist/runtime/public/scss/element-plus/skeleton-item.css +372 -0
- package/dist/runtime/public/scss/element-plus/skeleton-item.scss +83 -0
- package/dist/runtime/public/scss/element-plus/skeleton.css +335 -0
- package/dist/runtime/public/scss/element-plus/skeleton.scss +39 -0
- package/dist/runtime/public/scss/element-plus/slider.css +480 -0
- package/dist/runtime/public/scss/element-plus/slider.scss +212 -0
- package/dist/runtime/public/scss/element-plus/space.css +317 -0
- package/dist/runtime/public/scss/element-plus/space.scss +20 -0
- package/dist/runtime/public/scss/element-plus/spinner.css +342 -0
- package/dist/runtime/public/scss/element-plus/spinner.scss +43 -0
- package/dist/runtime/public/scss/element-plus/statistic.css +336 -0
- package/dist/runtime/public/scss/element-plus/statistic.scss +35 -0
- package/dist/runtime/public/scss/element-plus/step.css +586 -0
- package/dist/runtime/public/scss/element-plus/step.scss +316 -0
- package/dist/runtime/public/scss/element-plus/steps.css +319 -0
- package/dist/runtime/public/scss/element-plus/steps.scss +21 -0
- package/dist/runtime/public/scss/element-plus/sub-menu.css +0 -0
- package/dist/runtime/public/scss/element-plus/sub-menu.scss +0 -0
- package/dist/runtime/public/scss/element-plus/switch.css +595 -0
- package/dist/runtime/public/scss/element-plus/switch.scss +327 -0
- package/dist/runtime/public/scss/element-plus/tab-pane.css +0 -0
- package/dist/runtime/public/scss/element-plus/tab-pane.scss +0 -0
- package/dist/runtime/public/scss/element-plus/table-column.css +382 -0
- package/dist/runtime/public/scss/element-plus/table-column.scss +98 -0
- package/dist/runtime/public/scss/element-plus/table-v2.css +521 -0
- package/dist/runtime/public/scss/element-plus/table-v2.scss +234 -0
- package/dist/runtime/public/scss/element-plus/table.css +980 -0
- package/dist/runtime/public/scss/element-plus/table.scss +868 -0
- package/dist/runtime/public/scss/element-plus/tabs.css +892 -0
- package/dist/runtime/public/scss/element-plus/tabs.scss +654 -0
- package/dist/runtime/public/scss/element-plus/tag.css +655 -0
- package/dist/runtime/public/scss/element-plus/tag.scss +193 -0
- package/dist/runtime/public/scss/element-plus/text.css +378 -0
- package/dist/runtime/public/scss/element-plus/text.scss +58 -0
- package/dist/runtime/public/scss/element-plus/time-picker.css +1029 -0
- package/dist/runtime/public/scss/element-plus/time-picker.scss +5 -0
- package/dist/runtime/public/scss/element-plus/time-select.css +952 -0
- package/dist/runtime/public/scss/element-plus/time-select.scss +37 -0
- package/dist/runtime/public/scss/element-plus/timeline-item.css +415 -0
- package/dist/runtime/public/scss/element-plus/timeline-item.scss +84 -0
- package/dist/runtime/public/scss/element-plus/timeline.css +334 -0
- package/dist/runtime/public/scss/element-plus/timeline.scss +46 -0
- package/dist/runtime/public/scss/element-plus/tooltip-v2.css +410 -0
- package/dist/runtime/public/scss/element-plus/tooltip-v2.scss +86 -0
- package/dist/runtime/public/scss/element-plus/tooltip.css +308 -0
- package/dist/runtime/public/scss/element-plus/tooltip.scss +15 -0
- package/dist/runtime/public/scss/element-plus/tour.css +461 -0
- package/dist/runtime/public/scss/element-plus/tour.scss +170 -0
- package/dist/runtime/public/scss/element-plus/transfer.css +497 -0
- package/dist/runtime/public/scss/element-plus/transfer.scss +204 -0
- package/dist/runtime/public/scss/element-plus/tree-select.css +325 -0
- package/dist/runtime/public/scss/element-plus/tree-select.scss +38 -0
- package/dist/runtime/public/scss/element-plus/tree.css +538 -0
- package/dist/runtime/public/scss/element-plus/tree.scss +132 -0
- package/dist/runtime/public/scss/element-plus/upload.css +862 -0
- package/dist/runtime/public/scss/element-plus/upload.scss +656 -0
- package/dist/runtime/public/scss/element-plus/var.css +398 -0
- package/dist/runtime/public/scss/element-plus/var.scss +86 -0
- package/dist/runtime/public/scss/element-plus/virtual-list.css +330 -0
- package/dist/runtime/public/scss/element-plus/virtual-list.scss +40 -0
- package/dist/runtime/public/scss/theme.css +1299 -0
- package/dist/runtime/public/scss/theme.scss +68 -0
- package/dist/runtime/server/tsconfig.json +6 -0
- package/dist/runtime/types.d.ts +61 -0
- package/dist/types.d.mts +7 -0
- package/dist/types.d.ts +7 -0
- package/package.json +73 -4
|
@@ -0,0 +1,333 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="flex flex-col gap-8 mb-16">
|
|
3
|
+
<h1 class="">Table</h1>
|
|
4
|
+
<p>Display multiple data with similar format. You can sort, filter, compare your data in a table.</p>
|
|
5
|
+
|
|
6
|
+
<el-card>
|
|
7
|
+
<template #header> Basic table </template>
|
|
8
|
+
<div class="flex flex-col gap-7.5 items-start">
|
|
9
|
+
<p>
|
|
10
|
+
Basic table is just for data display. After setting attribute <el-text tag="mark">data</el-text> of <el-text tag="mark">el-table</el-text> with an object array, you can
|
|
11
|
+
use prop (corresponding to a key of the object in data array) in <el-text tag="mark">el-table-column</el-text> to insert data to table columns, and set the attribute
|
|
12
|
+
<el-text tag="mark">label</el-text> to define the column name. You can also use the attribute <el-text tag="mark">width</el-text> to define the width of columns.
|
|
13
|
+
</p>
|
|
14
|
+
<el-table :data="tableData" style="width: 100%" flexible height="300">
|
|
15
|
+
<el-table-column type="selection" width="16" />
|
|
16
|
+
<el-table-column label="Date" width="120" show-overflow-tooltip>
|
|
17
|
+
<template #default="scope">{{ scope.row.date }}</template>
|
|
18
|
+
</el-table-column>
|
|
19
|
+
<el-table-column property="name" label="Name" width="120" show-overflow-tooltip />
|
|
20
|
+
<el-table-column property="state" label="State" width="240" show-overflow-tooltip />
|
|
21
|
+
<el-table-column property="city" label="City" show-overflow-tooltip />
|
|
22
|
+
<el-table-column property="zip" label="Zip" show-overflow-tooltip />
|
|
23
|
+
<el-table-column property="address" label="Address" width="140" show-overflow-tooltip />
|
|
24
|
+
<el-table-column min-width="37" width="37" fixed="right">
|
|
25
|
+
<el-dropdown>
|
|
26
|
+
<el-icon class="more-icon"><el-icon-more-filled /></el-icon>
|
|
27
|
+
<template #dropdown>
|
|
28
|
+
<el-dropdown-menu data-testid="pages-customers-index-yisqvkendj">
|
|
29
|
+
<el-dropdown-item value="1"> Action 01 </el-dropdown-item>
|
|
30
|
+
<el-dropdown-item value="2"> Action 02 </el-dropdown-item>
|
|
31
|
+
<el-dropdown-item value="3"> Action 03 </el-dropdown-item>
|
|
32
|
+
</el-dropdown-menu>
|
|
33
|
+
</template>
|
|
34
|
+
</el-dropdown>
|
|
35
|
+
</el-table-column>
|
|
36
|
+
</el-table>
|
|
37
|
+
|
|
38
|
+
<el-pagination
|
|
39
|
+
v-model:current-page="current_page"
|
|
40
|
+
v-model:page-size="page_size"
|
|
41
|
+
:page-sizes="[10, 20, 50, 100]"
|
|
42
|
+
:disabled="disabled"
|
|
43
|
+
:background="background"
|
|
44
|
+
layout="total, prev, pager, next, jumper, sizes"
|
|
45
|
+
:total="40000"
|
|
46
|
+
@size-change="handleSizeChange"
|
|
47
|
+
@current-change="handleCurrentChange"
|
|
48
|
+
/>
|
|
49
|
+
</div>
|
|
50
|
+
<template #footer>
|
|
51
|
+
<code class="flex flex-col gap-3 items-start">
|
|
52
|
+
<html-encode :tag="snippets.basic" />
|
|
53
|
+
</code>
|
|
54
|
+
</template>
|
|
55
|
+
</el-card>
|
|
56
|
+
|
|
57
|
+
<el-card>
|
|
58
|
+
<template #header> Without Border </template>
|
|
59
|
+
<div class="flex flex-col gap-7.5 items-start">
|
|
60
|
+
<p>Just add <el-text tag="mark">.t-border-none</el-text> to table class attribute.</p>
|
|
61
|
+
<el-table :data="tableData" style="width: 100%" flexible height="300" class="t-border-none">
|
|
62
|
+
<el-table-column type="selection" width="16" />
|
|
63
|
+
<el-table-column label="Date" width="120" show-overflow-tooltip>
|
|
64
|
+
<template #default="scope">{{ scope.row.date }}</template>
|
|
65
|
+
</el-table-column>
|
|
66
|
+
<el-table-column property="name" label="Name" width="120" show-overflow-tooltip />
|
|
67
|
+
<el-table-column property="state" label="State" width="240" show-overflow-tooltip />
|
|
68
|
+
<el-table-column property="city" label="City" show-overflow-tooltip />
|
|
69
|
+
<el-table-column property="zip" label="Zip" show-overflow-tooltip />
|
|
70
|
+
<el-table-column property="address" label="Address" width="140" show-overflow-tooltip />
|
|
71
|
+
<el-table-column min-width="37" width="37" fixed="right">
|
|
72
|
+
<el-dropdown>
|
|
73
|
+
<el-icon class="more-icon"><el-icon-more-filled /></el-icon>
|
|
74
|
+
<template #dropdown>
|
|
75
|
+
<el-dropdown-menu data-testid="pages-customers-index-yisqvkendj">
|
|
76
|
+
<el-dropdown-item value="1"> Action 01 </el-dropdown-item>
|
|
77
|
+
<el-dropdown-item value="2"> Action 02 </el-dropdown-item>
|
|
78
|
+
<el-dropdown-item value="3"> Action 03 </el-dropdown-item>
|
|
79
|
+
</el-dropdown-menu>
|
|
80
|
+
</template>
|
|
81
|
+
</el-dropdown>
|
|
82
|
+
</el-table-column>
|
|
83
|
+
</el-table>
|
|
84
|
+
</div>
|
|
85
|
+
<template #footer>
|
|
86
|
+
<code class="flex flex-col gap-3 items-start">
|
|
87
|
+
<html-encode :tag="snippets.borderless" />
|
|
88
|
+
</code>
|
|
89
|
+
</template>
|
|
90
|
+
</el-card>
|
|
91
|
+
|
|
92
|
+
<el-card>
|
|
93
|
+
<template #header> Top and Bottom Border </template>
|
|
94
|
+
<div class="flex flex-col gap-7.5 items-start">
|
|
95
|
+
<p>Just add <el-text tag="mark">.t-border-y</el-text> to table class attribute for top and bottom border.</p>
|
|
96
|
+
<el-table :data="tableData" style="width: 100%" flexible height="300" class="t-border-y">
|
|
97
|
+
<el-table-column type="selection" width="16" />
|
|
98
|
+
<el-table-column label="Date" width="120" show-overflow-tooltip>
|
|
99
|
+
<template #default="scope">{{ scope.row.date }}</template>
|
|
100
|
+
</el-table-column>
|
|
101
|
+
<el-table-column property="name" label="Name" width="120" show-overflow-tooltip />
|
|
102
|
+
<el-table-column property="state" label="State" width="240" show-overflow-tooltip />
|
|
103
|
+
<el-table-column property="city" label="City" show-overflow-tooltip />
|
|
104
|
+
<el-table-column property="zip" label="Zip" show-overflow-tooltip />
|
|
105
|
+
<el-table-column property="address" label="Address" width="140" show-overflow-tooltip />
|
|
106
|
+
<el-table-column min-width="37" width="37" fixed="right">
|
|
107
|
+
<el-dropdown>
|
|
108
|
+
<el-icon class="more-icon"><el-icon-more-filled /></el-icon>
|
|
109
|
+
<template #dropdown>
|
|
110
|
+
<el-dropdown-menu data-testid="pages-customers-index-yisqvkendj">
|
|
111
|
+
<el-dropdown-item value="1"> Action 01 </el-dropdown-item>
|
|
112
|
+
<el-dropdown-item value="2"> Action 02 </el-dropdown-item>
|
|
113
|
+
<el-dropdown-item value="3"> Action 03 </el-dropdown-item>
|
|
114
|
+
</el-dropdown-menu>
|
|
115
|
+
</template>
|
|
116
|
+
</el-dropdown>
|
|
117
|
+
</el-table-column>
|
|
118
|
+
</el-table>
|
|
119
|
+
</div>
|
|
120
|
+
<template #footer>
|
|
121
|
+
<code class="flex flex-col gap-3 items-start">
|
|
122
|
+
<html-encode :tag="snippets.top_and_bottom_border" />
|
|
123
|
+
</code>
|
|
124
|
+
</template>
|
|
125
|
+
</el-card>
|
|
126
|
+
|
|
127
|
+
<el-card>
|
|
128
|
+
<template #header>Just Top Border </template>
|
|
129
|
+
<div class="flex flex-col gap-7.5 items-start">
|
|
130
|
+
<p>Just add <el-text tag="mark">.t-border-t</el-text> to table class attribute for top border.</p>
|
|
131
|
+
<el-table :data="tableData" style="width: 100%" flexible height="300" class="t-border-t">
|
|
132
|
+
<el-table-column type="selection" width="16" />
|
|
133
|
+
<el-table-column label="Date" width="120" show-overflow-tooltip>
|
|
134
|
+
<template #default="scope">{{ scope.row.date }}</template>
|
|
135
|
+
</el-table-column>
|
|
136
|
+
<el-table-column property="name" label="Name" width="120" show-overflow-tooltip />
|
|
137
|
+
<el-table-column property="state" label="State" width="240" show-overflow-tooltip />
|
|
138
|
+
<el-table-column property="city" label="City" show-overflow-tooltip />
|
|
139
|
+
<el-table-column property="zip" label="Zip" show-overflow-tooltip />
|
|
140
|
+
<el-table-column property="address" label="Address" width="140" show-overflow-tooltip />
|
|
141
|
+
<el-table-column min-width="37" width="37" fixed="right">
|
|
142
|
+
<el-dropdown>
|
|
143
|
+
<el-icon class="more-icon"><el-icon-more-filled /></el-icon>
|
|
144
|
+
<template #dropdown>
|
|
145
|
+
<el-dropdown-menu data-testid="pages-customers-index-yisqvkendj">
|
|
146
|
+
<el-dropdown-item value="1"> Action 01 </el-dropdown-item>
|
|
147
|
+
<el-dropdown-item value="2"> Action 02 </el-dropdown-item>
|
|
148
|
+
<el-dropdown-item value="3"> Action 03 </el-dropdown-item>
|
|
149
|
+
</el-dropdown-menu>
|
|
150
|
+
</template>
|
|
151
|
+
</el-dropdown>
|
|
152
|
+
</el-table-column>
|
|
153
|
+
</el-table>
|
|
154
|
+
</div>
|
|
155
|
+
<template #footer>
|
|
156
|
+
<code class="flex flex-col gap-3 items-start">
|
|
157
|
+
<html-encode :tag="snippets.top_border" />
|
|
158
|
+
</code>
|
|
159
|
+
</template>
|
|
160
|
+
</el-card>
|
|
161
|
+
|
|
162
|
+
<el-card>
|
|
163
|
+
<template #header>Just Bottom Border </template>
|
|
164
|
+
<div class="flex flex-col gap-7.5 items-start">
|
|
165
|
+
<p>Just add <el-text tag="mark">.t-border-b</el-text> to table class attribute for bottom border.</p>
|
|
166
|
+
<el-table :data="tableData" style="width: 100%" flexible height="300" class="t-border-b">
|
|
167
|
+
<el-table-column type="selection" width="16" />
|
|
168
|
+
<el-table-column label="Date" width="120" show-overflow-tooltip>
|
|
169
|
+
<template #default="scope">{{ scope.row.date }}</template>
|
|
170
|
+
</el-table-column>
|
|
171
|
+
<el-table-column property="name" label="Name" width="120" show-overflow-tooltip />
|
|
172
|
+
<el-table-column property="state" label="State" width="240" show-overflow-tooltip />
|
|
173
|
+
<el-table-column property="city" label="City" show-overflow-tooltip />
|
|
174
|
+
<el-table-column property="zip" label="Zip" show-overflow-tooltip />
|
|
175
|
+
<el-table-column property="address" label="Address" width="140" show-overflow-tooltip />
|
|
176
|
+
<el-table-column min-width="37" width="37" fixed="right">
|
|
177
|
+
<el-dropdown>
|
|
178
|
+
<el-icon class="more-icon"><el-icon-more-filled /></el-icon>
|
|
179
|
+
<template #dropdown>
|
|
180
|
+
<el-dropdown-menu data-testid="pages-customers-index-yisqvkendj">
|
|
181
|
+
<el-dropdown-item value="1"> Action 01 </el-dropdown-item>
|
|
182
|
+
<el-dropdown-item value="2"> Action 02 </el-dropdown-item>
|
|
183
|
+
<el-dropdown-item value="3"> Action 03 </el-dropdown-item>
|
|
184
|
+
</el-dropdown-menu>
|
|
185
|
+
</template>
|
|
186
|
+
</el-dropdown>
|
|
187
|
+
</el-table-column>
|
|
188
|
+
</el-table>
|
|
189
|
+
</div>
|
|
190
|
+
<template #footer>
|
|
191
|
+
<code class="flex flex-col gap-3 items-start">
|
|
192
|
+
<html-encode :tag="snippets.bottom_border" />
|
|
193
|
+
</code>
|
|
194
|
+
</template>
|
|
195
|
+
</el-card>
|
|
196
|
+
</div>
|
|
197
|
+
</template>
|
|
198
|
+
<script lang="ts" setup>
|
|
199
|
+
import { ElTable } from 'element-plus';
|
|
200
|
+
import { reactive, ref, toRefs } from 'vue';
|
|
201
|
+
|
|
202
|
+
interface User {
|
|
203
|
+
date: string;
|
|
204
|
+
name: string;
|
|
205
|
+
state: string;
|
|
206
|
+
city: string;
|
|
207
|
+
zip: string;
|
|
208
|
+
address: string;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
interface PaginationState {
|
|
212
|
+
current_page: number;
|
|
213
|
+
size: string;
|
|
214
|
+
page_size: number;
|
|
215
|
+
disabled: boolean;
|
|
216
|
+
background: boolean;
|
|
217
|
+
handleSizeChange: (pageSize: number) => void;
|
|
218
|
+
handleCurrentChange: (page: number) => void;
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
const paginationState = reactive<PaginationState>({
|
|
222
|
+
current_page: 2,
|
|
223
|
+
size: 'small',
|
|
224
|
+
page_size: 20,
|
|
225
|
+
disabled: false,
|
|
226
|
+
background: false,
|
|
227
|
+
handleSizeChange: (pageSize: number) => {
|
|
228
|
+
console.log(pageSize);
|
|
229
|
+
},
|
|
230
|
+
handleCurrentChange: (page: number) => {
|
|
231
|
+
console.log(page);
|
|
232
|
+
},
|
|
233
|
+
});
|
|
234
|
+
|
|
235
|
+
const { current_page, page_size, disabled, background, handleSizeChange, handleCurrentChange } = toRefs(paginationState);
|
|
236
|
+
|
|
237
|
+
const tableData: User[] = [
|
|
238
|
+
{
|
|
239
|
+
date: '2016-05-03',
|
|
240
|
+
name: 'Tom',
|
|
241
|
+
state: 'California',
|
|
242
|
+
city: 'Los Angeles',
|
|
243
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
244
|
+
zip: 'CA 90036',
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
date: '2016-05-02',
|
|
248
|
+
name: 'Tom',
|
|
249
|
+
state: 'California',
|
|
250
|
+
city: 'Los Angeles',
|
|
251
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
252
|
+
zip: 'CA 90036',
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
date: '2016-05-04',
|
|
256
|
+
name: 'Tom',
|
|
257
|
+
state: 'California',
|
|
258
|
+
city: 'Los Angeles',
|
|
259
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
260
|
+
zip: 'CA 90036',
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
date: '2016-05-01',
|
|
264
|
+
name: 'Tom',
|
|
265
|
+
state: 'California',
|
|
266
|
+
city: 'Los Angeles',
|
|
267
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
268
|
+
zip: 'CA 90036',
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
date: '2016-05-08',
|
|
272
|
+
name: 'Tom',
|
|
273
|
+
state: 'California',
|
|
274
|
+
city: 'Los Angeles',
|
|
275
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
276
|
+
zip: 'CA 90036',
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
date: '2016-05-06',
|
|
280
|
+
name: 'Tom',
|
|
281
|
+
state: 'California',
|
|
282
|
+
city: 'Los Angeles',
|
|
283
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
284
|
+
zip: 'CA 90036',
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
date: '2016-05-07',
|
|
288
|
+
name: 'Tom',
|
|
289
|
+
state: 'California',
|
|
290
|
+
city: 'Los Angeles',
|
|
291
|
+
address: 'No. 189, Grove St, Los Angeles',
|
|
292
|
+
zip: 'CA 90036',
|
|
293
|
+
},
|
|
294
|
+
];
|
|
295
|
+
|
|
296
|
+
const snippets = ref({
|
|
297
|
+
basic: `
|
|
298
|
+
<el-table :data="tableData" style="width: 100%">
|
|
299
|
+
<el-table-column prop="date" label="Date" width="180" />
|
|
300
|
+
<el-table-column prop="name" label="Name" width="180" />
|
|
301
|
+
<el-table-column prop="address" label="Address" />
|
|
302
|
+
</el-table>
|
|
303
|
+
`,
|
|
304
|
+
borderless: `
|
|
305
|
+
<el-table :data="tableData" class="no-border">
|
|
306
|
+
<el-table-column prop="date" label="Date" width="180" />
|
|
307
|
+
<el-table-column prop="name" label="Name" width="180" />
|
|
308
|
+
<el-table-column prop="address" label="Address" />
|
|
309
|
+
</el-table>
|
|
310
|
+
`,
|
|
311
|
+
top_and_bottom_border: `
|
|
312
|
+
<el-table :data="tableData" class="t-border-y">
|
|
313
|
+
<el-table-column prop="date" label="Date" width="180" />
|
|
314
|
+
<el-table-column prop="name" label="Name" width="180" />
|
|
315
|
+
<el-table-column prop="address" label="Address" />
|
|
316
|
+
</el-table>
|
|
317
|
+
`,
|
|
318
|
+
bottom_border: `
|
|
319
|
+
<el-table :data="tableData" class="t-border-b">
|
|
320
|
+
<el-table-column prop="date" label="Date" width="180" />
|
|
321
|
+
<el-table-column prop="name" label="Name" width="180" />
|
|
322
|
+
<el-table-column prop="address" label="Address" />
|
|
323
|
+
</el-table>
|
|
324
|
+
`,
|
|
325
|
+
top_border: `
|
|
326
|
+
<el-table :data="tableData" class="t-border-t">
|
|
327
|
+
<el-table-column prop="date" label="Date" width="180" />
|
|
328
|
+
<el-table-column prop="name" label="Name" width="180" />
|
|
329
|
+
<el-table-column prop="address" label="Address" />
|
|
330
|
+
</el-table>
|
|
331
|
+
`,
|
|
332
|
+
});
|
|
333
|
+
</script>
|
|
@@ -0,0 +1,268 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="flex flex-col gap-8 mb-16">
|
|
3
|
+
<h1 class="">Tag</h1>
|
|
4
|
+
<p>Used for marking and selection.</p>
|
|
5
|
+
|
|
6
|
+
<el-card>
|
|
7
|
+
<template #header>Types</template>
|
|
8
|
+
<div class="flex flex-col gap-3 items-start">
|
|
9
|
+
<p>
|
|
10
|
+
Use the <el-text tag="mark">type</el-text> attribute to define Tag's type. In addition, the <el-text tag="mark">color</el-text> attribute can be used to set the
|
|
11
|
+
background color of the Tag.
|
|
12
|
+
</p>
|
|
13
|
+
<div class="flex gap-2">
|
|
14
|
+
<el-tag v-for="(color, key) in colors" :key="key + color" :type="color">{{ color }}</el-tag>
|
|
15
|
+
</div>
|
|
16
|
+
</div>
|
|
17
|
+
<template #footer><html-encode :tag="snippets.types" /> </template>
|
|
18
|
+
</el-card>
|
|
19
|
+
|
|
20
|
+
<el-card>
|
|
21
|
+
<template #header> Sizes </template>
|
|
22
|
+
<div class="flex flex-col gap-3 items-start">
|
|
23
|
+
<p>
|
|
24
|
+
Besides default size, Tag component provides three additional sizes for you to choose among different scenarios. Use attribute size to set additional sizes with
|
|
25
|
+
<el-text tag="mark">
|
|
26
|
+
{{ sizes.join(', ') }}
|
|
27
|
+
</el-text>
|
|
28
|
+
</p>
|
|
29
|
+
<div class="flex gap-2">
|
|
30
|
+
<el-tag v-for="(size, key) in sizes" :key="key + size" :size="size">{{ size }}</el-tag>
|
|
31
|
+
</div>
|
|
32
|
+
</div>
|
|
33
|
+
<template #footer> <html-encode :tag="snippets.sizes" /> </template>
|
|
34
|
+
</el-card>
|
|
35
|
+
|
|
36
|
+
<el-card>
|
|
37
|
+
<template #header> Removable Tag </template>
|
|
38
|
+
<div class="flex flex-col gap-3 items-start">
|
|
39
|
+
<p>
|
|
40
|
+
<el-text tag="mark">closable</el-text> attribute can be used to define a removable tag. It accepts a Boolean. By default the removal of Tag has a fading animation. If you
|
|
41
|
+
don't want to use it, you can set the <el-text tag="mark">disable-transitions</el-text> attribute, which accepts a Boolean, to true. close event triggers when Tag is
|
|
42
|
+
removed.
|
|
43
|
+
</p>
|
|
44
|
+
<div class="flex gap-2">
|
|
45
|
+
<el-tag v-for="tag in tags" :key="tag.name" closable :type="tag.type">
|
|
46
|
+
{{ tag.name }}
|
|
47
|
+
</el-tag>
|
|
48
|
+
</div>
|
|
49
|
+
</div>
|
|
50
|
+
<template #footer> <html-encode :tag="snippets.closable" /> </template>
|
|
51
|
+
</el-card>
|
|
52
|
+
|
|
53
|
+
<el-card>
|
|
54
|
+
<template #header> Edit Dynamically </template>
|
|
55
|
+
<div class="flex flex-col gap-3 items-start">
|
|
56
|
+
<p>You can use the <el-text tag="mark">close</el-text> event to add and remove tag dynamically.</p>
|
|
57
|
+
<div class="flex gap-2">
|
|
58
|
+
<el-tag v-for="tag in dynamicTags" :key="tag" closable :disable-transitions="false" @close="handleClose(tag)">
|
|
59
|
+
{{ tag }}
|
|
60
|
+
</el-tag>
|
|
61
|
+
<el-input v-if="inputVisible" ref="InputRef" v-model="inputValue" class="!w-20" size="mini" @keyup.enter="handleInputConfirm" @blur="handleInputConfirm" />
|
|
62
|
+
<el-button v-else class="button-new-tag" size="mini" @click="showInput"> + New Tag </el-button>
|
|
63
|
+
</div>
|
|
64
|
+
</div>
|
|
65
|
+
<template #footer> <html-encode :tag="snippets.dynamic" /> </template>
|
|
66
|
+
</el-card>
|
|
67
|
+
|
|
68
|
+
<el-card>
|
|
69
|
+
<template #header> Theme </template>
|
|
70
|
+
<div class="flex flex-col gap-3 items-start">
|
|
71
|
+
<p>Tag provide three different themes: dark、light and plain Using effect to change, default is light</p>
|
|
72
|
+
<div class="flex flex-col gap-2">
|
|
73
|
+
<div class="flex gap-2">
|
|
74
|
+
<span>Dark</span>
|
|
75
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="dark">
|
|
76
|
+
{{ item.label }}
|
|
77
|
+
</el-tag>
|
|
78
|
+
</div>
|
|
79
|
+
<div class="flex gap-2 mt-4">
|
|
80
|
+
<span>Light</span>
|
|
81
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="light">
|
|
82
|
+
{{ item.label }}
|
|
83
|
+
</el-tag>
|
|
84
|
+
</div>
|
|
85
|
+
<div class="flex gap-2 mt-4">
|
|
86
|
+
<span>Plain</span>
|
|
87
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="plain">
|
|
88
|
+
{{ item.label }}
|
|
89
|
+
</el-tag>
|
|
90
|
+
</div>
|
|
91
|
+
</div>
|
|
92
|
+
</div>
|
|
93
|
+
<template #footer> <html-encode :tag="snippets.theme" /> </template>
|
|
94
|
+
</el-card>
|
|
95
|
+
|
|
96
|
+
<el-card>
|
|
97
|
+
<template #header> Rounded </template>
|
|
98
|
+
<div class="flex flex-col gap-3 items-start">
|
|
99
|
+
<p>Tag can also be rounded like button.</p>
|
|
100
|
+
<div class="flex flex-col gap-2">
|
|
101
|
+
<div class="flex gap-2">
|
|
102
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="dark" round>
|
|
103
|
+
{{ item.label }}
|
|
104
|
+
</el-tag>
|
|
105
|
+
</div>
|
|
106
|
+
<div class="flex gap-2 mt-4">
|
|
107
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="light" round>
|
|
108
|
+
{{ item.label }}
|
|
109
|
+
</el-tag>
|
|
110
|
+
</div>
|
|
111
|
+
<div class="flex gap-2 mt-4">
|
|
112
|
+
<el-tag v-for="item in items" :key="item.label" :type="item.type" effect="plain" round>
|
|
113
|
+
{{ item.label }}
|
|
114
|
+
</el-tag>
|
|
115
|
+
</div>
|
|
116
|
+
</div>
|
|
117
|
+
</div>
|
|
118
|
+
<template #footer> <html-encode :tag="snippets.rounded" /> </template>
|
|
119
|
+
</el-card>
|
|
120
|
+
|
|
121
|
+
<el-card>
|
|
122
|
+
<template #header> Checkable Tag </template>
|
|
123
|
+
<div class="flex flex-col gap-3 items-start">
|
|
124
|
+
<p>
|
|
125
|
+
Sometimes because of the business needs, we might need checkbox like tag, but button like checkbox cannot meet our needs, here comes
|
|
126
|
+
<el-text tag="mark">check-tag</el-text>. You can use type prop in 2.5.4. basic check-tag usage, the API is rather simple.
|
|
127
|
+
</p>
|
|
128
|
+
<div class="flex gap-2">
|
|
129
|
+
<div class="flex gap-2">
|
|
130
|
+
<el-check-tag checked>Checked</el-check-tag>
|
|
131
|
+
<el-check-tag :checked="checked" @change="onChange">Toggle me</el-check-tag>
|
|
132
|
+
</div>
|
|
133
|
+
<el-check-tag :checked="checked1" type="primary" @change="onChange1"> Tag 1 </el-check-tag>
|
|
134
|
+
<el-check-tag :checked="checked2" type="success" @change="onChange2"> Tag 2 </el-check-tag>
|
|
135
|
+
<el-check-tag :checked="checked3" type="info" @change="onChange3"> Tag 3 </el-check-tag>
|
|
136
|
+
<el-check-tag :checked="checked4" type="warning" @change="onChange4"> Tag 4 </el-check-tag>
|
|
137
|
+
<el-check-tag :checked="checked5" type="danger" @change="onChange5"> Tag 5 </el-check-tag>
|
|
138
|
+
</div>
|
|
139
|
+
</div>
|
|
140
|
+
<template #footer> <html-encode :tag="snippets.checked" /> </template>
|
|
141
|
+
</el-card>
|
|
142
|
+
</div>
|
|
143
|
+
</template>
|
|
144
|
+
|
|
145
|
+
<script lang="ts" setup>
|
|
146
|
+
import type { InputInstance } from 'element-plus';
|
|
147
|
+
import type { TagProps } from 'element-plus';
|
|
148
|
+
import { ElInput } from 'element-plus';
|
|
149
|
+
import { nextTick, ref } from 'vue';
|
|
150
|
+
|
|
151
|
+
interface TagsItem {
|
|
152
|
+
name: string;
|
|
153
|
+
type: TagProps['type'];
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
type Item = { type: TagProps['type']; label: string };
|
|
157
|
+
|
|
158
|
+
const checked = ref(false);
|
|
159
|
+
const checked1 = ref(true);
|
|
160
|
+
const checked2 = ref(true);
|
|
161
|
+
const checked3 = ref(true);
|
|
162
|
+
const checked4 = ref(true);
|
|
163
|
+
const checked5 = ref(true);
|
|
164
|
+
|
|
165
|
+
const onChange = (status: boolean) => {
|
|
166
|
+
checked.value = status;
|
|
167
|
+
};
|
|
168
|
+
|
|
169
|
+
const onChange1 = (status: boolean) => {
|
|
170
|
+
checked1.value = status;
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
const onChange2 = (status: boolean) => {
|
|
174
|
+
checked2.value = status;
|
|
175
|
+
};
|
|
176
|
+
|
|
177
|
+
const onChange3 = (status: boolean) => {
|
|
178
|
+
checked3.value = status;
|
|
179
|
+
};
|
|
180
|
+
|
|
181
|
+
const onChange4 = (status: boolean) => {
|
|
182
|
+
checked4.value = status;
|
|
183
|
+
};
|
|
184
|
+
|
|
185
|
+
const onChange5 = (status: boolean) => {
|
|
186
|
+
checked5.value = status;
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
const items = ref<Array<Item>>([
|
|
190
|
+
{ type: 'primary', label: 'Tag 1' },
|
|
191
|
+
{ type: 'secondary', label: 'Tag 2' },
|
|
192
|
+
{ type: 'neutral', label: 'Tag 2' },
|
|
193
|
+
{ type: 'success', label: 'Tag 2' },
|
|
194
|
+
{ type: 'info', label: 'Tag 3' },
|
|
195
|
+
{ type: 'warning', label: 'Tag 4' },
|
|
196
|
+
{ type: 'danger', label: 'Tag 5' },
|
|
197
|
+
]);
|
|
198
|
+
|
|
199
|
+
const tags = ref<TagsItem[]>([
|
|
200
|
+
{ name: 'Tag 1', type: 'primary' },
|
|
201
|
+
{ name: 'Tag 1', type: 'secondary' },
|
|
202
|
+
{ name: 'Tag 1', type: 'neutral' },
|
|
203
|
+
{ name: 'Tag 2', type: 'success' },
|
|
204
|
+
{ name: 'Tag 3', type: 'info' },
|
|
205
|
+
{ name: 'Tag 4', type: 'warning' },
|
|
206
|
+
{ name: 'Tag 5', type: 'danger' },
|
|
207
|
+
]);
|
|
208
|
+
|
|
209
|
+
const inputValue = ref('');
|
|
210
|
+
const dynamicTags = ref(['Tag 1', 'Tag 2', 'Tag 3']);
|
|
211
|
+
const inputVisible = ref(false);
|
|
212
|
+
const InputRef = ref<InputInstance>();
|
|
213
|
+
|
|
214
|
+
const handleClose = (tag: string) => {
|
|
215
|
+
dynamicTags.value.splice(dynamicTags.value.indexOf(tag), 1);
|
|
216
|
+
};
|
|
217
|
+
|
|
218
|
+
const showInput = () => {
|
|
219
|
+
inputVisible.value = true;
|
|
220
|
+
nextTick(() => {
|
|
221
|
+
InputRef.value!.input!.focus();
|
|
222
|
+
});
|
|
223
|
+
};
|
|
224
|
+
|
|
225
|
+
const handleInputConfirm = () => {
|
|
226
|
+
if (inputValue.value) {
|
|
227
|
+
dynamicTags.value.push(inputValue.value);
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
inputVisible.value = false;
|
|
231
|
+
inputValue.value = '';
|
|
232
|
+
};
|
|
233
|
+
</script>
|
|
234
|
+
|
|
235
|
+
<script lang="ts">
|
|
236
|
+
import { defineComponent } from 'vue';
|
|
237
|
+
|
|
238
|
+
export default defineComponent({
|
|
239
|
+
name: 'BerqnetTag',
|
|
240
|
+
data() {
|
|
241
|
+
return {
|
|
242
|
+
sizes: ['default', 'large', 'medium', 'small', 'mini'],
|
|
243
|
+
colors: ['primary', 'secondary', 'neutral', 'success', 'warning', 'info', 'danger'],
|
|
244
|
+
value: '',
|
|
245
|
+
snippets: {
|
|
246
|
+
types: `<el-tag type="success">tag</el-tag>`,
|
|
247
|
+
sizes: `<el-tag size="large">tag</el-tag>`,
|
|
248
|
+
closable: `<el-tag size="large" type="success" closable>tag</el-tag>`,
|
|
249
|
+
dynamic: `<el-tag closable :disable-transitions="false" @close="handleClose(tag)"> tag </el-tag>`,
|
|
250
|
+
theme: `
|
|
251
|
+
<el-tag effect="dark"> tag </el-tag>
|
|
252
|
+
<el-tag effect="light"> tag </el-tag>
|
|
253
|
+
<el-tag effect="plain"> tag </el-tag>
|
|
254
|
+
`,
|
|
255
|
+
rounded: `<el-tag round>tag</el-tag>`,
|
|
256
|
+
checked: `<el-check-tag :checked="checked1" type="primary" @change="onChange1"> Tag 1 </el-check-tag>`,
|
|
257
|
+
},
|
|
258
|
+
};
|
|
259
|
+
},
|
|
260
|
+
methods: {
|
|
261
|
+
capitalize(value: string): string {
|
|
262
|
+
const text = String(value);
|
|
263
|
+
|
|
264
|
+
return text.charAt(0).toUpperCase() + text.slice(1);
|
|
265
|
+
},
|
|
266
|
+
},
|
|
267
|
+
});
|
|
268
|
+
</script>
|