rappel-ui 1.0.32 → 1.0.34
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 +7 -1
- package/cjs/components/button/index.js +1 -1
- package/cjs/components/button/src/button-group.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/button/src/button.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/button/src/constants.d.ts +1 -1
- package/cjs/components/button/src/constants.js +1 -1
- package/cjs/components/button/src/types.d.ts +1 -0
- package/cjs/components/dropdown/index.d.ts +157 -0
- package/cjs/components/dropdown/index.js +1 -0
- package/cjs/components/dropdown/src/constants.d.ts +15 -0
- package/cjs/components/dropdown/src/constants.js +1 -0
- package/cjs/components/dropdown/src/dropdown-item.js +1 -0
- package/cjs/components/dropdown/src/dropdown-item.vue.d.ts +21 -0
- package/cjs/components/dropdown/src/dropdown-item.vue_vue_type_script_setup_true_lang.js +1 -0
- package/cjs/components/dropdown/src/dropdown-menu.js +1 -0
- package/cjs/components/dropdown/src/dropdown-menu.vue.d.ts +14 -0
- package/cjs/components/dropdown/src/dropdown-menu.vue_vue_type_script_setup_true_lang.js +1 -0
- package/cjs/components/dropdown/src/dropdown-submenu.js +1 -0
- package/cjs/components/dropdown/src/dropdown-submenu.vue.d.ts +17 -0
- package/cjs/components/dropdown/src/dropdown-submenu.vue_vue_type_script_setup_true_lang.js +1 -0
- package/cjs/components/dropdown/src/dropdown.js +1 -0
- package/cjs/components/dropdown/src/dropdown.vue.d.ts +51 -0
- package/cjs/components/dropdown/src/dropdown.vue_vue_type_script_setup_true_lang.js +1 -0
- package/cjs/components/dropdown/src/types.d.ts +30 -0
- package/cjs/components/dropdown/src/use-dropdown-emit.d.ts +13 -0
- package/cjs/components/dropdown/src/use-dropdown-emit.js +1 -0
- package/cjs/components/dropdown/style/css.d.ts +0 -0
- package/cjs/components/dropdown/style/css.js +2 -0
- package/cjs/components/dropdown/style/index.d.ts +0 -0
- package/cjs/components/dropdown/style/index.js +2 -0
- package/cjs/components/index.d.ts +1 -0
- package/cjs/components/index.js +1 -1
- package/cjs/components/message/src/use-message-emit.d.ts +8 -8
- package/cjs/components/popconfirm/src/popconfirm.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/popconfirm/src/use-popconfirm-emit.d.ts +8 -8
- package/cjs/components/popover/src/popover.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/popover/src/use-popover-emit.d.ts +8 -8
- package/cjs/components/svg-icon/src/svg-icon.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/svg-icon/src/types.d.ts +1 -1
- package/cjs/components/tooltip/index.d.ts +8 -1
- package/cjs/components/tooltip/src/tooltip.vue.d.ts +4 -1
- package/cjs/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/tooltip/src/types.d.ts +2 -0
- package/cjs/components/tooltip/src/use-tooltip-emit.d.ts +8 -8
- package/cjs/components/transition/src/transition.vue_vue_type_script_setup_true_lang.js +1 -1
- package/cjs/components/transition/src/use-transition-emit.d.ts +8 -8
- package/cjs/composables/use-namespace/index.d.ts +2 -0
- package/cjs/composables/use-namespace/index.js +1 -1
- package/cjs/index.d.ts +473 -454
- package/cjs/index.js +1 -1
- package/cjs/svg-icons/create-icon.d.ts +3 -12
- package/cjs/svg-icons/create-icon.js +1 -1
- package/cjs/svg-icons/get-async-icon.js +1 -1
- package/cjs/svg-icons/icon-names.d.ts +1 -1
- package/cjs/svg-icons/icon-names.js +1 -1
- package/cjs/svg-icons/index.d.ts +5 -0
- package/cjs/svg-icons/index.js +1 -1
- package/cjs/svg-icons/src/arrow-backward.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-backward.js +1 -1
- package/cjs/svg-icons/src/arrow-down.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-down.js +1 -1
- package/cjs/svg-icons/src/arrow-downward.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-downward.js +1 -1
- package/cjs/svg-icons/src/arrow-forward.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-forward.js +1 -1
- package/cjs/svg-icons/src/arrow-left.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-left.js +1 -1
- package/cjs/svg-icons/src/arrow-right.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-right.js +1 -1
- package/cjs/svg-icons/src/arrow-up.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-up.js +1 -1
- package/cjs/svg-icons/src/arrow-upward.d.ts +3 -12
- package/cjs/svg-icons/src/arrow-upward.js +1 -1
- package/cjs/svg-icons/src/check-circle.d.ts +3 -12
- package/cjs/svg-icons/src/check-circle.js +1 -1
- package/cjs/svg-icons/src/check-fill.d.ts +3 -12
- package/cjs/svg-icons/src/check-fill.js +1 -1
- package/cjs/svg-icons/src/check.d.ts +3 -12
- package/cjs/svg-icons/src/check.js +1 -1
- package/cjs/svg-icons/src/close-circle.d.ts +3 -12
- package/cjs/svg-icons/src/close-circle.js +1 -1
- package/cjs/svg-icons/src/close-fill.d.ts +3 -12
- package/cjs/svg-icons/src/close-short.d.ts +3 -12
- package/cjs/svg-icons/src/close-short.js +1 -1
- package/cjs/svg-icons/src/close.d.ts +3 -12
- package/cjs/svg-icons/src/close.js +1 -1
- package/cjs/svg-icons/src/copy-closure.d.ts +3 -12
- package/cjs/svg-icons/src/copy-closure.js +1 -1
- package/cjs/svg-icons/src/copy.d.ts +3 -12
- package/cjs/svg-icons/src/copy.js +1 -1
- package/cjs/svg-icons/src/delete.d.ts +3 -12
- package/cjs/svg-icons/src/delete.js +1 -1
- package/cjs/svg-icons/src/exclam-fill.d.ts +3 -12
- package/cjs/svg-icons/src/exclam.d.ts +3 -12
- package/cjs/svg-icons/src/exclam.js +1 -1
- package/cjs/svg-icons/src/help.d.ts +3 -12
- package/cjs/svg-icons/src/help.js +1 -1
- package/cjs/svg-icons/src/info-circle.d.ts +3 -12
- package/cjs/svg-icons/src/info-circle.js +1 -1
- package/cjs/svg-icons/src/info-fill.d.ts +3 -12
- package/cjs/svg-icons/src/loading.d.ts +3 -12
- package/cjs/svg-icons/src/loading.js +1 -1
- package/cjs/svg-icons/src/more-dot-circle-horizontal.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-circle-horizontal.js +1 -1
- package/cjs/svg-icons/src/more-dot-circle-outline-horizontal.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-circle-outline-horizontal.js +1 -1
- package/cjs/svg-icons/src/more-dot-circle-outline-vertical.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-circle-outline-vertical.js +1 -1
- package/cjs/svg-icons/src/more-dot-circle.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-circle.js +1 -1
- package/cjs/svg-icons/src/more-dot-square-horizontal.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-square-horizontal.js +1 -1
- package/cjs/svg-icons/src/more-dot-square.d.ts +3 -12
- package/cjs/svg-icons/src/more-dot-square.js +1 -1
- package/cjs/svg-icons/src/more-line.d.ts +3 -12
- package/cjs/svg-icons/src/more-line.js +1 -1
- package/cjs/svg-icons/src/play.d.ts +34 -0
- package/cjs/svg-icons/src/play.js +1 -0
- package/cjs/svg-icons/src/search-bold.d.ts +3 -12
- package/cjs/svg-icons/src/search-bold.js +1 -1
- package/cjs/svg-icons/src/search.d.ts +3 -12
- package/cjs/svg-icons/src/search.js +1 -1
- package/cjs/svg-icons/src/star-fill.d.ts +3 -12
- package/cjs/svg-icons/src/star.d.ts +3 -12
- package/cjs/svg-icons/src/star.js +1 -1
- package/cjs/svg-icons/src/triangle-backward-fill.d.ts +34 -0
- package/cjs/svg-icons/src/triangle-backward-fill.js +1 -0
- package/cjs/svg-icons/src/triangle-downward-fill.d.ts +34 -0
- package/cjs/svg-icons/src/triangle-downward-fill.js +1 -0
- package/cjs/svg-icons/src/triangle-forward-fill.d.ts +34 -0
- package/cjs/svg-icons/src/triangle-forward-fill.js +1 -0
- package/cjs/svg-icons/src/triangle-upward-fill.d.ts +34 -0
- package/cjs/svg-icons/src/triangle-upward-fill.js +1 -0
- package/cjs/svg-icons/types.d.ts +1 -1
- package/cjs/utils/index.js +1 -1
- package/cjs/utils/util.d.ts +76 -94
- package/cjs/utils/util.js +1 -3
- package/cjs/utils/vue/index.js +1 -1
- package/dist/index.css +1 -1
- package/dist/index.umd.js +9 -11
- package/es/components/button/index.mjs +2 -2
- package/es/components/button/src/button-group.vue_vue_type_script_setup_true_lang.mjs +23 -12
- package/es/components/button/src/button.vue_vue_type_script_setup_true_lang.mjs +50 -46
- package/es/components/button/src/constants.d.ts +1 -1
- package/es/components/button/src/constants.mjs +2 -2
- package/es/components/button/src/types.d.ts +1 -0
- package/es/components/dropdown/index.d.ts +157 -0
- package/es/components/dropdown/index.mjs +15 -0
- package/es/components/dropdown/src/constants.d.ts +15 -0
- package/es/components/dropdown/src/constants.mjs +17 -0
- package/es/components/dropdown/src/dropdown-item.mjs +5 -0
- package/es/components/dropdown/src/dropdown-item.vue.d.ts +21 -0
- package/es/components/dropdown/src/dropdown-item.vue_vue_type_script_setup_true_lang.mjs +70 -0
- package/es/components/dropdown/src/dropdown-menu.mjs +5 -0
- package/es/components/dropdown/src/dropdown-menu.vue.d.ts +14 -0
- package/es/components/dropdown/src/dropdown-menu.vue_vue_type_script_setup_true_lang.mjs +14 -0
- package/es/components/dropdown/src/dropdown-submenu.mjs +5 -0
- package/es/components/dropdown/src/dropdown-submenu.vue.d.ts +17 -0
- package/es/components/dropdown/src/dropdown-submenu.vue_vue_type_script_setup_true_lang.mjs +43 -0
- package/es/components/dropdown/src/dropdown.mjs +5 -0
- package/es/components/dropdown/src/dropdown.vue.d.ts +51 -0
- package/es/components/dropdown/src/dropdown.vue_vue_type_script_setup_true_lang.mjs +226 -0
- package/es/components/dropdown/src/types.d.ts +30 -0
- package/es/components/dropdown/src/use-dropdown-emit.d.ts +13 -0
- package/es/components/dropdown/src/use-dropdown-emit.mjs +11 -0
- package/es/components/dropdown/style/css.d.ts +0 -0
- package/es/components/dropdown/style/css.mjs +2 -0
- package/es/components/dropdown/style/index.d.ts +0 -0
- package/es/components/dropdown/style/index.mjs +2 -0
- package/es/components/index.d.ts +1 -0
- package/es/components/index.mjs +11 -4
- package/es/components/message/src/use-message-emit.d.ts +8 -8
- package/es/components/popconfirm/src/popconfirm.vue_vue_type_script_setup_true_lang.mjs +6 -4
- package/es/components/popconfirm/src/use-popconfirm-emit.d.ts +8 -8
- package/es/components/popover/src/popover.vue_vue_type_script_setup_true_lang.mjs +4 -2
- package/es/components/popover/src/use-popover-emit.d.ts +8 -8
- package/es/components/svg-icon/src/svg-icon.vue_vue_type_script_setup_true_lang.mjs +2 -2
- package/es/components/svg-icon/src/types.d.ts +1 -1
- package/es/components/tooltip/index.d.ts +8 -1
- package/es/components/tooltip/src/tooltip.vue.d.ts +4 -1
- package/es/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.mjs +123 -111
- package/es/components/tooltip/src/types.d.ts +2 -0
- package/es/components/tooltip/src/use-tooltip-emit.d.ts +8 -8
- package/es/components/transition/src/transition.vue_vue_type_script_setup_true_lang.mjs +1 -1
- package/es/components/transition/src/use-transition-emit.d.ts +8 -8
- package/es/composables/use-namespace/index.d.ts +2 -0
- package/es/composables/use-namespace/index.mjs +2 -0
- package/es/index.d.ts +473 -454
- package/es/index.mjs +77 -71
- package/es/svg-icons/create-icon.d.ts +3 -12
- package/es/svg-icons/create-icon.mjs +3 -7
- package/es/svg-icons/get-async-icon.mjs +48 -42
- package/es/svg-icons/icon-names.d.ts +1 -1
- package/es/svg-icons/icon-names.mjs +1 -1
- package/es/svg-icons/index.d.ts +5 -0
- package/es/svg-icons/index.mjs +12 -2
- package/es/svg-icons/src/arrow-backward.d.ts +3 -12
- package/es/svg-icons/src/arrow-backward.mjs +3 -1
- package/es/svg-icons/src/arrow-down.d.ts +3 -12
- package/es/svg-icons/src/arrow-down.mjs +3 -1
- package/es/svg-icons/src/arrow-downward.d.ts +3 -12
- package/es/svg-icons/src/arrow-downward.mjs +3 -1
- package/es/svg-icons/src/arrow-forward.d.ts +3 -12
- package/es/svg-icons/src/arrow-forward.mjs +3 -1
- package/es/svg-icons/src/arrow-left.d.ts +3 -12
- package/es/svg-icons/src/arrow-left.mjs +3 -1
- package/es/svg-icons/src/arrow-right.d.ts +3 -12
- package/es/svg-icons/src/arrow-right.mjs +3 -1
- package/es/svg-icons/src/arrow-up.d.ts +3 -12
- package/es/svg-icons/src/arrow-up.mjs +3 -1
- package/es/svg-icons/src/arrow-upward.d.ts +3 -12
- package/es/svg-icons/src/arrow-upward.mjs +3 -1
- package/es/svg-icons/src/check-circle.d.ts +3 -12
- package/es/svg-icons/src/check-circle.mjs +3 -1
- package/es/svg-icons/src/check-fill.d.ts +3 -12
- package/es/svg-icons/src/check-fill.mjs +4 -2
- package/es/svg-icons/src/check.d.ts +3 -12
- package/es/svg-icons/src/check.mjs +3 -1
- package/es/svg-icons/src/close-circle.d.ts +3 -12
- package/es/svg-icons/src/close-circle.mjs +3 -1
- package/es/svg-icons/src/close-fill.d.ts +3 -12
- package/es/svg-icons/src/close-fill.mjs +1 -0
- package/es/svg-icons/src/close-short.d.ts +3 -12
- package/es/svg-icons/src/close-short.mjs +3 -1
- package/es/svg-icons/src/close.d.ts +3 -12
- package/es/svg-icons/src/close.mjs +3 -1
- package/es/svg-icons/src/copy-closure.d.ts +3 -12
- package/es/svg-icons/src/copy-closure.mjs +3 -1
- package/es/svg-icons/src/copy.d.ts +3 -12
- package/es/svg-icons/src/copy.mjs +3 -1
- package/es/svg-icons/src/delete.d.ts +3 -12
- package/es/svg-icons/src/delete.mjs +3 -1
- package/es/svg-icons/src/exclam-fill.d.ts +3 -12
- package/es/svg-icons/src/exclam-fill.mjs +1 -0
- package/es/svg-icons/src/exclam.d.ts +3 -12
- package/es/svg-icons/src/exclam.mjs +3 -1
- package/es/svg-icons/src/help.d.ts +3 -12
- package/es/svg-icons/src/help.mjs +3 -1
- package/es/svg-icons/src/info-circle.d.ts +3 -12
- package/es/svg-icons/src/info-circle.mjs +3 -1
- package/es/svg-icons/src/info-fill.d.ts +3 -12
- package/es/svg-icons/src/info-fill.mjs +1 -0
- package/es/svg-icons/src/loading.d.ts +3 -12
- package/es/svg-icons/src/loading.mjs +3 -1
- package/es/svg-icons/src/more-dot-circle-horizontal.d.ts +3 -12
- package/es/svg-icons/src/more-dot-circle-horizontal.mjs +3 -1
- package/es/svg-icons/src/more-dot-circle-outline-horizontal.d.ts +3 -12
- package/es/svg-icons/src/more-dot-circle-outline-horizontal.mjs +3 -1
- package/es/svg-icons/src/more-dot-circle-outline-vertical.d.ts +3 -12
- package/es/svg-icons/src/more-dot-circle-outline-vertical.mjs +3 -1
- package/es/svg-icons/src/more-dot-circle.d.ts +3 -12
- package/es/svg-icons/src/more-dot-circle.mjs +3 -1
- package/es/svg-icons/src/more-dot-square-horizontal.d.ts +3 -12
- package/es/svg-icons/src/more-dot-square-horizontal.mjs +3 -1
- package/es/svg-icons/src/more-dot-square.d.ts +3 -12
- package/es/svg-icons/src/more-dot-square.mjs +3 -1
- package/es/svg-icons/src/more-line.d.ts +3 -12
- package/es/svg-icons/src/more-line.mjs +3 -1
- package/es/svg-icons/src/play.d.ts +34 -0
- package/es/svg-icons/src/play.mjs +9 -0
- package/es/svg-icons/src/search-bold.d.ts +3 -12
- package/es/svg-icons/src/search-bold.mjs +3 -1
- package/es/svg-icons/src/search.d.ts +3 -12
- package/es/svg-icons/src/search.mjs +3 -1
- package/es/svg-icons/src/star-fill.d.ts +3 -12
- package/es/svg-icons/src/star-fill.mjs +1 -0
- package/es/svg-icons/src/star.d.ts +3 -12
- package/es/svg-icons/src/star.mjs +3 -1
- package/es/svg-icons/src/triangle-backward-fill.d.ts +34 -0
- package/es/svg-icons/src/triangle-backward-fill.mjs +9 -0
- package/es/svg-icons/src/triangle-downward-fill.d.ts +34 -0
- package/es/svg-icons/src/triangle-downward-fill.mjs +9 -0
- package/es/svg-icons/src/triangle-forward-fill.d.ts +34 -0
- package/es/svg-icons/src/triangle-forward-fill.mjs +9 -0
- package/es/svg-icons/src/triangle-upward-fill.d.ts +34 -0
- package/es/svg-icons/src/triangle-upward-fill.mjs +9 -0
- package/es/svg-icons/types.d.ts +1 -1
- package/es/utils/index.mjs +2 -2
- package/es/utils/util.d.ts +76 -94
- package/es/utils/util.mjs +41 -74
- package/es/utils/vue/index.mjs +4 -1
- package/package.json +3 -2
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/re-button-group.css +1 -1
- package/theme-chalk/re-button.css +1 -1
- package/theme-chalk/re-dropdown.css +1 -0
- package/theme-chalk/re-message.css +1 -1
- package/theme-chalk/re-popconfirm.css +1 -1
- package/theme-chalk/re-popover.css +1 -1
- package/theme-chalk/re-tooltip.css +1 -1
- package/theme-chalk/src/button-group.scss +32 -8
- package/theme-chalk/src/dropdown.scss +97 -0
- package/theme-chalk/src/function/index.scss +1 -1
- package/theme-chalk/src/index.scss +1 -0
- package/theme-chalk/src/message.scss +2 -28
- package/theme-chalk/src/mixins/_button.scss +1 -1
- package/theme-chalk/src/mixins/_dropdown.scss +17 -0
- package/theme-chalk/src/mixins/_transition.scss +29 -0
- package/theme-chalk/src/mixins/index.scss +6 -0
- package/theme-chalk/src/popconfirm.scss +3 -0
- package/theme-chalk/src/popover.scss +3 -0
- package/theme-chalk/src/tooltip.scss +3 -10
- package/cjs/_virtual/_rolldown_dynamic_import_helper.js +0 -1
- package/cjs/rappel-ui/resolvers.js +0 -1
- package/es/_virtual/_rolldown_dynamic_import_helper.mjs +0 -9
- package/es/rappel-ui/resolvers.mjs +0 -18
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { _buttonGroupProvideKey as e, buttonSizes as t, buttonTypes as n } from "./constants.mjs";
|
|
2
2
|
import { useNamespace as r } from "../../../composables/use-namespace/index.mjs";
|
|
3
3
|
import "../../../composables/index.mjs";
|
|
4
|
-
import { Fragment as i, computed as a, createBlock as o, createCommentVNode as s, createElementBlock as c, defineComponent as l, inject as u,
|
|
5
|
-
import { computedAsync as
|
|
6
|
-
import { Loading as
|
|
4
|
+
import { Fragment as i, computed as a, createBlock as o, createCommentVNode as s, createElementBlock as c, defineComponent as l, inject as u, normalizeClass as d, openBlock as f, renderSlot as p, resolveDynamicComponent as m, unref as h, useTemplateRef as g } from "vue";
|
|
5
|
+
import { computedAsync as _ } from "@vueuse/core";
|
|
6
|
+
import { Loading as v, getAsyncIcon as y } from "@rappel-ui/svg-icons";
|
|
7
7
|
//#region packages/components/button/src/button.vue?vue&type=script&setup=true&lang.ts
|
|
8
|
-
var
|
|
8
|
+
var b = [
|
|
9
9
|
"type",
|
|
10
10
|
"disabled",
|
|
11
11
|
"autofocus",
|
|
12
12
|
"aria-disabled"
|
|
13
|
-
],
|
|
13
|
+
], x = l({
|
|
14
14
|
name: "ReButton",
|
|
15
15
|
__name: "button",
|
|
16
16
|
props: {
|
|
@@ -41,7 +41,7 @@ var x = [
|
|
|
41
41
|
type: Boolean,
|
|
42
42
|
default: () => void 0
|
|
43
43
|
},
|
|
44
|
-
loadingIcon: { default: () =>
|
|
44
|
+
loadingIcon: { default: () => v },
|
|
45
45
|
text: {
|
|
46
46
|
type: Boolean,
|
|
47
47
|
default: () => void 0
|
|
@@ -67,73 +67,77 @@ var x = [
|
|
|
67
67
|
nativeType: { default: "button" }
|
|
68
68
|
},
|
|
69
69
|
emits: ["click"],
|
|
70
|
-
setup(l, { expose:
|
|
71
|
-
let
|
|
70
|
+
setup(l, { expose: v, emit: x }) {
|
|
71
|
+
let S = x, { n: C, nm: w, ns: T, is: E, has: D } = r("button"), O = u(e, null), k = a(() => {
|
|
72
72
|
var e;
|
|
73
73
|
return l.type || (O == null || (e = O.type) == null ? void 0 : e.value) || "";
|
|
74
74
|
}), A = a(() => {
|
|
75
75
|
var e;
|
|
76
76
|
return l.size || (O == null || (e = O.size) == null ? void 0 : e.value) || "";
|
|
77
|
-
}), j = a(() =>
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
77
|
+
}), j = a(() => {
|
|
78
|
+
var e;
|
|
79
|
+
return (O == null || (e = O.gap) == null ? void 0 : e.value) || "";
|
|
80
|
+
}), M = a(() => [
|
|
81
|
+
C(),
|
|
82
|
+
k.value && n.includes(k.value) ? w(k.value) : "",
|
|
83
|
+
A.value && t.includes(A.value) ? w(A.value) : "",
|
|
84
|
+
E("text", l.text),
|
|
85
|
+
E("text-padding", l.text && l.padding),
|
|
86
|
+
E("text-bg", l.text && l.bg),
|
|
87
|
+
E("link", l.link),
|
|
88
|
+
E("plain", l.plain),
|
|
89
|
+
E("round", l.round),
|
|
90
|
+
E("circle", l.circle),
|
|
91
|
+
E("dashed", l.dashed),
|
|
92
|
+
E("loading", l.loading),
|
|
93
|
+
E("disabled", l.disabled),
|
|
94
|
+
D("group-gap", !!j.value)
|
|
95
|
+
]), N = _(async () => await y(l.loadingIcon)), P = _(async () => await y(l.icon));
|
|
96
|
+
function F(e) {
|
|
93
97
|
if (l.disabled || l.loading) {
|
|
94
98
|
e.stopPropagation();
|
|
95
99
|
return;
|
|
96
100
|
}
|
|
97
|
-
|
|
101
|
+
S("click", e);
|
|
98
102
|
}
|
|
99
|
-
let
|
|
100
|
-
return
|
|
103
|
+
let I = g("ref");
|
|
104
|
+
return v({ ref: I }), (e, t) => {
|
|
101
105
|
var n;
|
|
102
|
-
return
|
|
106
|
+
return f(), c("button", {
|
|
103
107
|
ref_key: "ref",
|
|
104
|
-
ref:
|
|
105
|
-
class:
|
|
108
|
+
ref: I,
|
|
109
|
+
class: d(M.value),
|
|
106
110
|
type: l.nativeType,
|
|
107
111
|
disabled: l.disabled || l.loading,
|
|
108
112
|
autofocus: l.autofocus,
|
|
109
113
|
"aria-disabled": l.disabled,
|
|
110
|
-
onClick:
|
|
111
|
-
}
|
|
112
|
-
|
|
114
|
+
onClick: F
|
|
115
|
+
}, [
|
|
116
|
+
p(e.$slots, "loading", {}, () => [l.loading ? (f(), c(i, { key: 0 }, [typeof h(N) == "string" ? (f(), c("i", {
|
|
113
117
|
key: 0,
|
|
114
|
-
class:
|
|
118
|
+
class: d([h(T)("loading"), h(N)]),
|
|
115
119
|
"aria-hidden": "true"
|
|
116
|
-
}, null, 2)) : (
|
|
120
|
+
}, null, 2)) : (f(), o(m(h(N)), {
|
|
117
121
|
key: 1,
|
|
118
|
-
class:
|
|
122
|
+
class: d([h(T)("loading")]),
|
|
119
123
|
"aria-hidden": "true"
|
|
120
124
|
}, null, 8, ["class"]))], 64)) : s("", !0)]),
|
|
121
|
-
|
|
125
|
+
p(e.$slots, "icon", {}, () => [l.icon ? (f(), c(i, { key: 0 }, [typeof h(P) == "string" ? (f(), c("i", {
|
|
122
126
|
key: 0,
|
|
123
|
-
class:
|
|
127
|
+
class: d([h(T)("icon"), h(P)]),
|
|
124
128
|
"aria-hidden": "true"
|
|
125
|
-
}, null, 2)) : (
|
|
129
|
+
}, null, 2)) : (f(), o(m(h(P)), {
|
|
126
130
|
key: 1,
|
|
127
|
-
class:
|
|
131
|
+
class: d([h(T)("icon")]),
|
|
128
132
|
"aria-hidden": "true"
|
|
129
133
|
}, null, 8, ["class"]))], 64)) : s("", !0)]),
|
|
130
|
-
(n = e.$slots) != null && n.default ? (
|
|
134
|
+
(n = e.$slots) != null && n.default ? (f(), c("span", {
|
|
131
135
|
key: 0,
|
|
132
|
-
class:
|
|
133
|
-
}, [
|
|
134
|
-
],
|
|
136
|
+
class: d([h(T)("content")])
|
|
137
|
+
}, [p(e.$slots, "default")], 2)) : s("", !0)
|
|
138
|
+
], 10, b);
|
|
135
139
|
};
|
|
136
140
|
}
|
|
137
141
|
});
|
|
138
142
|
//#endregion
|
|
139
|
-
export {
|
|
143
|
+
export { x as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export declare const buttonTypes: readonly ["primary", "success", "warning", "danger", "error", "info", ""];
|
|
2
2
|
export declare const buttonSizes: readonly ["mini", "small", "", "large"];
|
|
3
3
|
export declare const buttonNativeTypes: readonly ["button", "submit", "reset"];
|
|
4
|
-
export declare const
|
|
4
|
+
export declare const _buttonGroupProvideKey: unique symbol;
|
|
@@ -16,6 +16,6 @@ var e = [
|
|
|
16
16
|
"button",
|
|
17
17
|
"submit",
|
|
18
18
|
"reset"
|
|
19
|
-
], r = Symbol("
|
|
19
|
+
], r = Symbol("_buttonGroupProvideKey");
|
|
20
20
|
//#endregion
|
|
21
|
-
export { r as
|
|
21
|
+
export { r as _buttonGroupProvideKey, n as buttonNativeTypes, t as buttonSizes, e as buttonTypes };
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
import { CreateComponentPublicInstanceWithMixins, ComponentOptionsMixin, PublicProps, GlobalComponents, GlobalDirectives, ComponentProvideOptions, ComponentOptionsBase, VNodeProps, AllowedComponentProps, ComponentCustomProps } from 'vue';
|
|
2
|
+
import { DropdownProps, OptionsItem, DropdownSubmenuProps } from './index.ts';
|
|
3
|
+
export * from './src/types.ts';
|
|
4
|
+
export * from './src/use-dropdown-emit.ts';
|
|
5
|
+
export declare const ReDropdown: {
|
|
6
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly< DropdownProps & {
|
|
7
|
+
visible?: boolean;
|
|
8
|
+
}> & Readonly<{
|
|
9
|
+
onSelect?: ((value: any, item: OptionsItem) => any) | undefined;
|
|
10
|
+
onBeforeEnter?: ((el: HTMLElement) => any) | undefined;
|
|
11
|
+
onEnter?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
12
|
+
onEnterCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
13
|
+
onAfterEnter?: ((el: HTMLElement) => any) | undefined;
|
|
14
|
+
onBeforeLeave?: ((el: HTMLElement) => any) | undefined;
|
|
15
|
+
onLeave?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
16
|
+
onLeaveCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
17
|
+
onAfterLeave?: ((el: HTMLElement) => any) | undefined;
|
|
18
|
+
"onUpdate:visible"?: ((value: boolean | undefined) => any) | undefined;
|
|
19
|
+
}>, {
|
|
20
|
+
tooltipRef: any;
|
|
21
|
+
select: (value: any, item: OptionsItem) => void;
|
|
22
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
23
|
+
select: (value: any, item: OptionsItem) => any;
|
|
24
|
+
beforeEnter: (el: HTMLElement) => any;
|
|
25
|
+
enter: (el: HTMLElement, done: () => void) => any;
|
|
26
|
+
enterCancelled: (el: HTMLElement) => any;
|
|
27
|
+
afterEnter: (el: HTMLElement) => any;
|
|
28
|
+
beforeLeave: (el: HTMLElement) => any;
|
|
29
|
+
leave: (el: HTMLElement, done: () => void) => any;
|
|
30
|
+
leaveCancelled: (el: HTMLElement) => any;
|
|
31
|
+
afterLeave: (el: HTMLElement) => any;
|
|
32
|
+
"update:visible": (value: boolean | undefined) => any;
|
|
33
|
+
}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
34
|
+
P: {};
|
|
35
|
+
B: {};
|
|
36
|
+
D: {};
|
|
37
|
+
C: {};
|
|
38
|
+
M: {};
|
|
39
|
+
Defaults: {};
|
|
40
|
+
}, Readonly< DropdownProps & {
|
|
41
|
+
visible?: boolean;
|
|
42
|
+
}> & Readonly<{
|
|
43
|
+
onSelect?: ((value: any, item: OptionsItem) => any) | undefined;
|
|
44
|
+
onBeforeEnter?: ((el: HTMLElement) => any) | undefined;
|
|
45
|
+
onEnter?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
46
|
+
onEnterCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
47
|
+
onAfterEnter?: ((el: HTMLElement) => any) | undefined;
|
|
48
|
+
onBeforeLeave?: ((el: HTMLElement) => any) | undefined;
|
|
49
|
+
onLeave?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
50
|
+
onLeaveCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
51
|
+
onAfterLeave?: ((el: HTMLElement) => any) | undefined;
|
|
52
|
+
"onUpdate:visible"?: ((value: boolean | undefined) => any) | undefined;
|
|
53
|
+
}>, {
|
|
54
|
+
tooltipRef: any;
|
|
55
|
+
select: (value: any, item: OptionsItem) => void;
|
|
56
|
+
}, {}, {}, {}, {}>;
|
|
57
|
+
__isFragment?: never;
|
|
58
|
+
__isTeleport?: never;
|
|
59
|
+
__isSuspense?: never;
|
|
60
|
+
} & ComponentOptionsBase<Readonly< DropdownProps & {
|
|
61
|
+
visible?: boolean;
|
|
62
|
+
}> & Readonly<{
|
|
63
|
+
onSelect?: ((value: any, item: OptionsItem) => any) | undefined;
|
|
64
|
+
onBeforeEnter?: ((el: HTMLElement) => any) | undefined;
|
|
65
|
+
onEnter?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
66
|
+
onEnterCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
67
|
+
onAfterEnter?: ((el: HTMLElement) => any) | undefined;
|
|
68
|
+
onBeforeLeave?: ((el: HTMLElement) => any) | undefined;
|
|
69
|
+
onLeave?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
70
|
+
onLeaveCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
71
|
+
onAfterLeave?: ((el: HTMLElement) => any) | undefined;
|
|
72
|
+
"onUpdate:visible"?: ((value: boolean | undefined) => any) | undefined;
|
|
73
|
+
}>, {
|
|
74
|
+
tooltipRef: any;
|
|
75
|
+
select: (value: any, item: OptionsItem) => void;
|
|
76
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
77
|
+
select: (value: any, item: OptionsItem) => any;
|
|
78
|
+
beforeEnter: (el: HTMLElement) => any;
|
|
79
|
+
enter: (el: HTMLElement, done: () => void) => any;
|
|
80
|
+
enterCancelled: (el: HTMLElement) => any;
|
|
81
|
+
afterEnter: (el: HTMLElement) => any;
|
|
82
|
+
beforeLeave: (el: HTMLElement) => any;
|
|
83
|
+
leave: (el: HTMLElement, done: () => void) => any;
|
|
84
|
+
leaveCancelled: (el: HTMLElement) => any;
|
|
85
|
+
afterLeave: (el: HTMLElement) => any;
|
|
86
|
+
"update:visible": (value: boolean | undefined) => any;
|
|
87
|
+
}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & (new () => {
|
|
88
|
+
$slots: {
|
|
89
|
+
menu?: (props: {
|
|
90
|
+
options: OptionsItem[];
|
|
91
|
+
}) => any;
|
|
92
|
+
} & {
|
|
93
|
+
item?: (props: {
|
|
94
|
+
options: OptionsItem[];
|
|
95
|
+
}) => any;
|
|
96
|
+
};
|
|
97
|
+
});
|
|
98
|
+
export declare const ReDropdownMenu: {
|
|
99
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, true, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
100
|
+
P: {};
|
|
101
|
+
B: {};
|
|
102
|
+
D: {};
|
|
103
|
+
C: {};
|
|
104
|
+
M: {};
|
|
105
|
+
Defaults: {};
|
|
106
|
+
}, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
107
|
+
__isFragment?: never;
|
|
108
|
+
__isTeleport?: never;
|
|
109
|
+
__isSuspense?: never;
|
|
110
|
+
} & ComponentOptionsBase<Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & (new () => {
|
|
111
|
+
$slots: {
|
|
112
|
+
default?: (props: {}) => any;
|
|
113
|
+
};
|
|
114
|
+
});
|
|
115
|
+
export declare const ReDropdownSubmenu: {
|
|
116
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly< DropdownSubmenuProps> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
117
|
+
P: {};
|
|
118
|
+
B: {};
|
|
119
|
+
D: {};
|
|
120
|
+
C: {};
|
|
121
|
+
M: {};
|
|
122
|
+
Defaults: {};
|
|
123
|
+
}, Readonly< DropdownSubmenuProps> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
124
|
+
__isFragment?: never;
|
|
125
|
+
__isTeleport?: never;
|
|
126
|
+
__isSuspense?: never;
|
|
127
|
+
} & ComponentOptionsBase<Readonly< DropdownSubmenuProps> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & (new () => {
|
|
128
|
+
$slots: {
|
|
129
|
+
label?: (props: {}) => any;
|
|
130
|
+
} & {
|
|
131
|
+
default?: (props: {}) => any;
|
|
132
|
+
};
|
|
133
|
+
});
|
|
134
|
+
export declare const ReDropdownItem: {
|
|
135
|
+
new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly< OptionsItem> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {}, false, {}, {}, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
136
|
+
P: {};
|
|
137
|
+
B: {};
|
|
138
|
+
D: {};
|
|
139
|
+
C: {};
|
|
140
|
+
M: {};
|
|
141
|
+
Defaults: {};
|
|
142
|
+
}, Readonly< OptionsItem> & Readonly<{}>, {}, {}, {}, {}, {}>;
|
|
143
|
+
__isFragment?: never;
|
|
144
|
+
__isTeleport?: never;
|
|
145
|
+
__isSuspense?: never;
|
|
146
|
+
} & ComponentOptionsBase<Readonly< OptionsItem> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, {}, {}, string, {}, GlobalComponents, GlobalDirectives, string, ComponentProvideOptions> & VNodeProps & AllowedComponentProps & ComponentCustomProps & (new () => {
|
|
147
|
+
$slots: {
|
|
148
|
+
icon?: (props: {}) => any;
|
|
149
|
+
} & {
|
|
150
|
+
default?: (props: {}) => any;
|
|
151
|
+
} & {
|
|
152
|
+
'sub-icon'?: (props: {}) => any;
|
|
153
|
+
} & {
|
|
154
|
+
submenu?: (props: {}) => any;
|
|
155
|
+
};
|
|
156
|
+
});
|
|
157
|
+
export default ReDropdown;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { withInstall as e } from "../../utils/vue/index.mjs";
|
|
2
|
+
import "../../utils/index.mjs";
|
|
3
|
+
import t from "./src/dropdown-menu.mjs";
|
|
4
|
+
import n from "./src/dropdown-item.mjs";
|
|
5
|
+
import r from "./src/dropdown-submenu.mjs";
|
|
6
|
+
import { useDropdownEmits as i } from "./src/use-dropdown-emit.mjs";
|
|
7
|
+
import a from "./src/dropdown.mjs";
|
|
8
|
+
//#region packages/components/dropdown/index.ts
|
|
9
|
+
var o = e(a, {
|
|
10
|
+
DropdownMenu: t,
|
|
11
|
+
DropdownItem: n,
|
|
12
|
+
DropdownSubmenu: r
|
|
13
|
+
}), s = e(t), c = e(r), l = e(n);
|
|
14
|
+
//#endregion
|
|
15
|
+
export { o as ReDropdown, o as default, l as ReDropdownItem, s as ReDropdownMenu, c as ReDropdownSubmenu, i as useDropdownEmits };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const originsMap: {
|
|
2
|
+
readonly top: "bottom center";
|
|
3
|
+
readonly 'top-start': "bottom left";
|
|
4
|
+
readonly 'top-end': "bottom right";
|
|
5
|
+
readonly bottom: "top center";
|
|
6
|
+
readonly 'bottom-start': "top left";
|
|
7
|
+
readonly 'bottom-end': "top right";
|
|
8
|
+
readonly left: "right center";
|
|
9
|
+
readonly 'left-start': "right top";
|
|
10
|
+
readonly 'left-end': "right bottom";
|
|
11
|
+
readonly right: "center left";
|
|
12
|
+
readonly 'right-start': "left top";
|
|
13
|
+
readonly 'right-end': "left bottom";
|
|
14
|
+
};
|
|
15
|
+
export declare const _dropdownProvideKey: unique symbol;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//#region packages/components/dropdown/src/constants.ts
|
|
2
|
+
var e = {
|
|
3
|
+
top: "bottom center",
|
|
4
|
+
"top-start": "bottom left",
|
|
5
|
+
"top-end": "bottom right",
|
|
6
|
+
bottom: "top center",
|
|
7
|
+
"bottom-start": "top left",
|
|
8
|
+
"bottom-end": "top right",
|
|
9
|
+
left: "right center",
|
|
10
|
+
"left-start": "right top",
|
|
11
|
+
"left-end": "right bottom",
|
|
12
|
+
right: "center left",
|
|
13
|
+
"right-start": "left top",
|
|
14
|
+
"right-end": "left bottom"
|
|
15
|
+
}, t = Symbol("_dropdownProvideKey");
|
|
16
|
+
//#endregion
|
|
17
|
+
export { t as _dropdownProvideKey, e as originsMap };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { OptionsItem } from './types';
|
|
2
|
+
import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
declare var __VLS_1: {}, __VLS_8: {}, __VLS_10: {}, __VLS_17: {};
|
|
4
|
+
type __VLS_Slots = {} & {
|
|
5
|
+
icon?: (props: typeof __VLS_1) => any;
|
|
6
|
+
} & {
|
|
7
|
+
default?: (props: typeof __VLS_8) => any;
|
|
8
|
+
} & {
|
|
9
|
+
'sub-icon'?: (props: typeof __VLS_10) => any;
|
|
10
|
+
} & {
|
|
11
|
+
submenu?: (props: typeof __VLS_17) => any;
|
|
12
|
+
};
|
|
13
|
+
declare const __VLS_base: DefineComponent<OptionsItem, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<OptionsItem> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
15
|
+
declare const _default: typeof __VLS_export;
|
|
16
|
+
export default _default;
|
|
17
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
18
|
+
new (): {
|
|
19
|
+
$slots: S;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { useNamespace as e } from "../../../composables/use-namespace/index.mjs";
|
|
2
|
+
import "../../../composables/index.mjs";
|
|
3
|
+
import { _dropdownProvideKey as t } from "./constants.mjs";
|
|
4
|
+
import { computed as n, createBlock as r, createCommentVNode as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, defineComponent as l, inject as u, normalizeClass as d, openBlock as f, renderSlot as p, resolveDynamicComponent as m, toDisplayString as h, unref as g } from "vue";
|
|
5
|
+
import { computedAsync as _ } from "@vueuse/core";
|
|
6
|
+
import { ArrowBackward as v, getAsyncIcon as y } from "@rappel-ui/svg-icons";
|
|
7
|
+
//#region packages/components/dropdown/src/dropdown-item.vue?vue&type=script&setup=true&lang.ts
|
|
8
|
+
var b = l({
|
|
9
|
+
name: "ReDropdownItem",
|
|
10
|
+
__name: "dropdown-item",
|
|
11
|
+
props: {
|
|
12
|
+
value: { default: "" },
|
|
13
|
+
label: { default: "" },
|
|
14
|
+
disabled: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: !1
|
|
17
|
+
},
|
|
18
|
+
children: { default: () => [] },
|
|
19
|
+
hasChildren: {
|
|
20
|
+
type: Boolean,
|
|
21
|
+
default: !1
|
|
22
|
+
},
|
|
23
|
+
icon: { default: "" }
|
|
24
|
+
},
|
|
25
|
+
setup(l) {
|
|
26
|
+
let { ns: b, is: x, has: S } = e("dropdown"), C = n(() => {
|
|
27
|
+
var e;
|
|
28
|
+
return [
|
|
29
|
+
b("item"),
|
|
30
|
+
x("disabled", l.disabled),
|
|
31
|
+
S("children", l.hasChildren || ((e = l.children) == null ? void 0 : e.length) > 0)
|
|
32
|
+
];
|
|
33
|
+
}), w = u(t, null), T = (e) => {
|
|
34
|
+
var t;
|
|
35
|
+
e.stopPropagation(), !(l.hasChildren || ((t = l.children) == null ? void 0 : t.length) > 0) && (w == null || w.select(l.value, {
|
|
36
|
+
label: l.label,
|
|
37
|
+
disabled: l.disabled,
|
|
38
|
+
value: l.value,
|
|
39
|
+
children: l.children
|
|
40
|
+
}));
|
|
41
|
+
}, E = _(async () => await y(l.icon));
|
|
42
|
+
return (e, t) => {
|
|
43
|
+
var n;
|
|
44
|
+
return f(), a("li", {
|
|
45
|
+
class: d(C.value),
|
|
46
|
+
onClick: T
|
|
47
|
+
}, [
|
|
48
|
+
l.icon ? (f(), a("div", {
|
|
49
|
+
key: 0,
|
|
50
|
+
class: d([g(b)("icon")])
|
|
51
|
+
}, [p(e.$slots, "icon", {}, () => [typeof g(E) == "string" ? (f(), a("i", {
|
|
52
|
+
key: 0,
|
|
53
|
+
class: d([g(E)]),
|
|
54
|
+
"aria-hidden": "true"
|
|
55
|
+
}, null, 2)) : (f(), r(m(g(E)), {
|
|
56
|
+
key: 1,
|
|
57
|
+
"aria-hidden": "true"
|
|
58
|
+
}))])], 2)) : i("", !0),
|
|
59
|
+
o("div", { class: d([g(b)("label")]) }, [p(e.$slots, "default", {}, () => [s(h(l.label), 1)])], 2),
|
|
60
|
+
l.hasChildren || (n = l.children) != null && n.length ? (f(), a("div", {
|
|
61
|
+
key: 1,
|
|
62
|
+
class: d([g(b)("subicon")])
|
|
63
|
+
}, [p(e.$slots, "sub-icon", {}, () => [c(g(v))])], 2)) : i("", !0),
|
|
64
|
+
p(e.$slots, "submenu")
|
|
65
|
+
], 2);
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
//#endregion
|
|
70
|
+
export { b as default };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
2
|
+
declare var __VLS_1: {};
|
|
3
|
+
type __VLS_Slots = {} & {
|
|
4
|
+
default?: (props: typeof __VLS_1) => any;
|
|
5
|
+
};
|
|
6
|
+
declare const __VLS_base: DefineComponent<{}, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
7
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
8
|
+
declare const _default: typeof __VLS_export;
|
|
9
|
+
export default _default;
|
|
10
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
11
|
+
new (): {
|
|
12
|
+
$slots: S;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { useNamespace as e } from "../../../composables/use-namespace/index.mjs";
|
|
2
|
+
import "../../../composables/index.mjs";
|
|
3
|
+
import { createElementBlock as t, defineComponent as n, normalizeClass as r, openBlock as i, renderSlot as a, unref as o } from "vue";
|
|
4
|
+
//#region packages/components/dropdown/src/dropdown-menu.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
+
var s = n({
|
|
6
|
+
name: "ReDropdownMenu",
|
|
7
|
+
__name: "dropdown-menu",
|
|
8
|
+
setup(n) {
|
|
9
|
+
let { ns: s } = e("dropdown");
|
|
10
|
+
return (e, n) => (i(), t("ul", { class: r([o(s)("menu")]) }, [a(e.$slots, "default")], 2));
|
|
11
|
+
}
|
|
12
|
+
});
|
|
13
|
+
//#endregion
|
|
14
|
+
export { s as default };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { DropdownSubmenuProps } from './types.ts';
|
|
2
|
+
import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
declare var __VLS_8: {}, __VLS_17: {};
|
|
4
|
+
type __VLS_Slots = {} & {
|
|
5
|
+
label?: (props: typeof __VLS_8) => any;
|
|
6
|
+
} & {
|
|
7
|
+
default?: (props: typeof __VLS_17) => any;
|
|
8
|
+
};
|
|
9
|
+
declare const __VLS_base: DefineComponent<DropdownSubmenuProps, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly<DropdownSubmenuProps> & Readonly<{}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
10
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
11
|
+
declare const _default: typeof __VLS_export;
|
|
12
|
+
export default _default;
|
|
13
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
14
|
+
new (): {
|
|
15
|
+
$slots: S;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { useNamespace as e } from "../../../composables/use-namespace/index.mjs";
|
|
2
|
+
import "../../../composables/index.mjs";
|
|
3
|
+
import t from "./dropdown-menu.mjs";
|
|
4
|
+
import n from "./dropdown-item.mjs";
|
|
5
|
+
import { Fragment as r, createBlock as i, createElementBlock as a, createElementVNode as o, createTextVNode as s, createVNode as c, defineComponent as l, mergeProps as u, normalizeClass as d, openBlock as f, renderList as p, renderSlot as m, resolveComponent as h, toDisplayString as g, unref as _, withCtx as v } from "vue";
|
|
6
|
+
//#region packages/components/dropdown/src/dropdown-submenu.vue?vue&type=script&setup=true&lang.ts
|
|
7
|
+
var y = l({
|
|
8
|
+
name: "ReDropdownSubmenu",
|
|
9
|
+
__name: "dropdown-submenu",
|
|
10
|
+
props: { item: { default: () => ({
|
|
11
|
+
value: "",
|
|
12
|
+
children: []
|
|
13
|
+
}) } },
|
|
14
|
+
setup(l) {
|
|
15
|
+
let { n: y, ns: b } = e("dropdown");
|
|
16
|
+
return (e, x) => {
|
|
17
|
+
let S = h("dropdown-submenu", !0);
|
|
18
|
+
return f(), i(n, u(l.item, { "has-children": "" }), {
|
|
19
|
+
submenu: v(() => [o("div", { class: d([
|
|
20
|
+
_(y)("dropdown"),
|
|
21
|
+
_(y)("tooltip"),
|
|
22
|
+
_(b)("children")
|
|
23
|
+
]) }, [c(t, null, {
|
|
24
|
+
default: v(() => [m(e.$slots, "default", {}, () => [(f(!0), a(r, null, p(l.item.children, (e) => {
|
|
25
|
+
var t;
|
|
26
|
+
return f(), a(r, { key: e.value }, [e != null && (t = e.children) != null && t.length ? (f(), i(S, {
|
|
27
|
+
key: 0,
|
|
28
|
+
item: e
|
|
29
|
+
}, null, 8, ["item"])) : (f(), i(n, u({
|
|
30
|
+
key: 1,
|
|
31
|
+
ref_for: !0
|
|
32
|
+
}, e), null, 16))], 64);
|
|
33
|
+
}), 128))])]),
|
|
34
|
+
_: 3
|
|
35
|
+
})], 2)]),
|
|
36
|
+
default: v(() => [m(e.$slots, "label", {}, () => [s(g(l.item.label), 1)])]),
|
|
37
|
+
_: 3
|
|
38
|
+
}, 16);
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
//#endregion
|
|
43
|
+
export { y as default };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { DropdownProps, OptionsItem } from './types';
|
|
2
|
+
import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
|
|
3
|
+
type __VLS_Props = DropdownProps;
|
|
4
|
+
type __VLS_ModelProps = {
|
|
5
|
+
'visible'?: boolean;
|
|
6
|
+
};
|
|
7
|
+
type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
8
|
+
declare var __VLS_24: {
|
|
9
|
+
options: OptionsItem[];
|
|
10
|
+
}, __VLS_32: {
|
|
11
|
+
options: OptionsItem[];
|
|
12
|
+
};
|
|
13
|
+
type __VLS_Slots = {} & {
|
|
14
|
+
menu?: (props: typeof __VLS_24) => any;
|
|
15
|
+
} & {
|
|
16
|
+
item?: (props: typeof __VLS_32) => any;
|
|
17
|
+
};
|
|
18
|
+
declare const __VLS_base: DefineComponent<__VLS_PublicProps, {
|
|
19
|
+
tooltipRef: any;
|
|
20
|
+
select: (value: any, item: OptionsItem) => void;
|
|
21
|
+
}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
22
|
+
select: (value: any, item: OptionsItem) => any;
|
|
23
|
+
beforeEnter: (el: HTMLElement) => any;
|
|
24
|
+
enter: (el: HTMLElement, done: () => void) => any;
|
|
25
|
+
enterCancelled: (el: HTMLElement) => any;
|
|
26
|
+
afterEnter: (el: HTMLElement) => any;
|
|
27
|
+
beforeLeave: (el: HTMLElement) => any;
|
|
28
|
+
leave: (el: HTMLElement, done: () => void) => any;
|
|
29
|
+
leaveCancelled: (el: HTMLElement) => any;
|
|
30
|
+
afterLeave: (el: HTMLElement) => any;
|
|
31
|
+
"update:visible": (value: boolean | undefined) => any;
|
|
32
|
+
}, string, PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
33
|
+
onSelect?: ((value: any, item: OptionsItem) => any) | undefined;
|
|
34
|
+
onBeforeEnter?: ((el: HTMLElement) => any) | undefined;
|
|
35
|
+
onEnter?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
36
|
+
onEnterCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
37
|
+
onAfterEnter?: ((el: HTMLElement) => any) | undefined;
|
|
38
|
+
onBeforeLeave?: ((el: HTMLElement) => any) | undefined;
|
|
39
|
+
onLeave?: ((el: HTMLElement, done: () => void) => any) | undefined;
|
|
40
|
+
onLeaveCancelled?: ((el: HTMLElement) => any) | undefined;
|
|
41
|
+
onAfterLeave?: ((el: HTMLElement) => any) | undefined;
|
|
42
|
+
"onUpdate:visible"?: ((value: boolean | undefined) => any) | undefined;
|
|
43
|
+
}>, {}, {}, {}, {}, string, ComponentProvideOptions, false, {}, any>;
|
|
44
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
45
|
+
declare const _default: typeof __VLS_export;
|
|
46
|
+
export default _default;
|
|
47
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
48
|
+
new (): {
|
|
49
|
+
$slots: S;
|
|
50
|
+
};
|
|
51
|
+
};
|