@bridge-ui/vue 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Actions/BridgeUIHosts.js +5 -0
- package/dist/Actions/BridgeUIHosts.vue.d.ts +18 -0
- package/dist/Actions/BridgeUIHosts.vue_vue_type_script_setup_true_lang.js +27 -0
- package/dist/Actions/Dialog/BridgeDialogAction.js +5 -0
- package/dist/Actions/Dialog/BridgeDialogAction.vue.d.ts +8 -0
- package/dist/Actions/Dialog/BridgeDialogAction.vue_vue_type_script_setup_true_lang.js +62 -0
- package/dist/Actions/Dialog/BridgeDialogHost.js +5 -0
- package/dist/Actions/Dialog/BridgeDialogHost.vue.d.ts +14 -0
- package/dist/Actions/Dialog/BridgeDialogHost.vue_vue_type_script_setup_true_lang.js +26 -0
- package/dist/Actions/Dialog/BridgeDialogItem.js +5 -0
- package/dist/Actions/Dialog/BridgeDialogItem.vue.d.ts +4 -0
- package/dist/Actions/Dialog/BridgeDialogItem.vue_vue_type_script_setup_true_lang.js +47 -0
- package/dist/Actions/Dialog/ResolveBridgeDialogFooter.js +5 -0
- package/dist/Actions/Dialog/ResolveBridgeDialogFooter.vue.d.ts +4 -0
- package/dist/Actions/Dialog/ResolveBridgeDialogFooter.vue_vue_type_script_setup_true_lang.js +35 -0
- package/dist/Actions/Dialog/bridgeDialog.types.d.ts +128 -0
- package/dist/Actions/Dialog/bridgeDialogInjectionKey.d.ts +3 -0
- package/dist/Actions/Dialog/bridgeDialogInjectionKey.js +4 -0
- package/dist/Actions/Dialog/createBridgeDialogApi.d.ts +2 -0
- package/dist/Actions/Dialog/createBridgeDialogApi.js +49 -0
- package/dist/Actions/Dialog/index.d.ts +3 -0
- package/dist/Actions/Dialog/index.js +3 -0
- package/dist/Actions/Dialog/useDialogAction.d.ts +5 -0
- package/dist/Actions/Dialog/useDialogAction.js +26 -0
- package/dist/Actions/Modal/BridgeModalHost.js +5 -0
- package/dist/Actions/Modal/BridgeModalHost.vue.d.ts +14 -0
- package/dist/Actions/Modal/BridgeModalHost.vue_vue_type_script_setup_true_lang.js +35 -0
- package/dist/Actions/Modal/bridgeModal.types.d.ts +44 -0
- package/dist/Actions/Modal/bridgeModalInjectionKey.d.ts +3 -0
- package/dist/Actions/Modal/bridgeModalInjectionKey.js +4 -0
- package/dist/Actions/Modal/createBridgeModalApi.d.ts +2 -0
- package/dist/Actions/Modal/createBridgeModalApi.js +49 -0
- package/dist/Actions/Modal/index.d.ts +3 -0
- package/dist/Actions/Modal/index.js +3 -0
- package/dist/Actions/Modal/useModalAction.d.ts +5 -0
- package/dist/Actions/Modal/useModalAction.js +26 -0
- package/dist/Actions/Snackbar/BridgeSnackbarAction.js +5 -0
- package/dist/Actions/Snackbar/BridgeSnackbarAction.vue.d.ts +8 -0
- package/dist/Actions/Snackbar/BridgeSnackbarAction.vue_vue_type_script_setup_true_lang.js +86 -0
- package/dist/Actions/Snackbar/BridgeSnackbarHost.js +5 -0
- package/dist/Actions/Snackbar/BridgeSnackbarHost.vue.d.ts +16 -0
- package/dist/Actions/Snackbar/BridgeSnackbarHost.vue_vue_type_script_setup_true_lang.js +55 -0
- package/dist/Actions/Snackbar/BridgeSnackbarItem.js +5 -0
- package/dist/Actions/Snackbar/BridgeSnackbarItem.vue.d.ts +4 -0
- package/dist/Actions/Snackbar/BridgeSnackbarItem.vue_vue_type_script_setup_true_lang.js +117 -0
- package/dist/Actions/Snackbar/bridgeSnackbar.types.d.ts +127 -0
- package/dist/Actions/Snackbar/bridgeSnackbarInjectionKey.d.ts +3 -0
- package/dist/Actions/Snackbar/bridgeSnackbarInjectionKey.js +4 -0
- package/dist/Actions/Snackbar/createBridgeSnackbarApi.d.ts +14 -0
- package/dist/Actions/Snackbar/createBridgeSnackbarApi.js +59 -0
- package/dist/Actions/Snackbar/index.d.ts +3 -0
- package/dist/Actions/Snackbar/index.js +3 -0
- package/dist/Actions/Snackbar/useSnackbarAction.d.ts +5 -0
- package/dist/Actions/Snackbar/useSnackbarAction.js +27 -0
- package/dist/Actions/bridgeUIHosts.types.d.ts +17 -0
- package/dist/Actions/index.d.ts +8 -0
- package/dist/Actions/index.js +8 -0
- package/dist/Components/Alert/Alert.js +5 -0
- package/dist/Components/Alert/Alert.vue.d.ts +11 -0
- package/dist/Components/Alert/Alert.vue_vue_type_script_setup_true_lang.js +43 -0
- package/dist/Components/Alert/alert.types.d.ts +134 -0
- package/dist/Components/Alert/alertDefaultIcons.d.ts +4 -0
- package/dist/Components/Alert/alertDefaultIcons.js +13 -0
- package/dist/Components/Alert/composables/useAlert.d.ts +18 -0
- package/dist/Components/Alert/composables/useAlert.js +71 -0
- package/dist/Components/Alert/index.d.ts +3 -0
- package/dist/Components/Alert/index.js +3 -0
- package/dist/Components/Avatar/Avatar.js +5 -0
- package/dist/Components/Avatar/Avatar.vue.d.ts +11 -0
- package/dist/Components/Avatar/Avatar.vue_vue_type_script_setup_true_lang.js +32 -0
- package/dist/Components/Avatar/avatar.types.d.ts +81 -0
- package/dist/Components/Avatar/composables/useAvatar.d.ts +23 -0
- package/dist/Components/Avatar/composables/useAvatar.js +73 -0
- package/dist/Components/Avatar/index.d.ts +3 -0
- package/dist/Components/Avatar/index.js +3 -0
- package/dist/Components/Badge/Badge.js +5 -0
- package/dist/Components/Badge/Badge.vue.d.ts +4 -0
- package/dist/Components/Badge/Badge.vue_vue_type_script_setup_true_lang.js +29 -0
- package/dist/Components/Badge/badge.types.d.ts +64 -0
- package/dist/Components/Badge/composables/useBadge.d.ts +9 -0
- package/dist/Components/Badge/composables/useBadge.js +47 -0
- package/dist/Components/Badge/index.d.ts +3 -0
- package/dist/Components/Badge/index.js +3 -0
- package/dist/Components/Button/Button.js +5 -0
- package/dist/Components/Button/Button.vue.d.ts +11 -0
- package/dist/Components/Button/Button.vue_vue_type_script_setup_true_lang.js +74 -0
- package/dist/Components/Button/button.types.d.ts +181 -0
- package/dist/Components/Button/composables/useButton.d.ts +22 -0
- package/dist/Components/Button/composables/useButton.js +91 -0
- package/dist/Components/Button/index.d.ts +3 -0
- package/dist/Components/Button/index.js +3 -0
- package/dist/Components/Card/Card.js +5 -0
- package/dist/Components/Card/Card.vue.d.ts +11 -0
- package/dist/Components/Card/Card.vue_vue_type_script_setup_true_lang.js +33 -0
- package/dist/Components/Card/card.types.d.ts +124 -0
- package/dist/Components/Card/composables/useCard.d.ts +18 -0
- package/dist/Components/Card/composables/useCard.js +80 -0
- package/dist/Components/Card/index.d.ts +3 -0
- package/dist/Components/Card/index.js +3 -0
- package/dist/Components/Checkbox/Checkbox.js +5 -0
- package/dist/Components/Checkbox/Checkbox.vue.d.ts +20 -0
- package/dist/Components/Checkbox/Checkbox.vue_vue_type_script_setup_true_lang.js +70 -0
- package/dist/Components/Checkbox/checkbox.types.d.ts +98 -0
- package/dist/Components/Checkbox/composables/useCheckbox.d.ts +279 -0
- package/dist/Components/Checkbox/composables/useCheckbox.js +76 -0
- package/dist/Components/Checkbox/index.d.ts +3 -0
- package/dist/Components/Checkbox/index.js +3 -0
- package/dist/Components/FormControl/FormControl.js +5 -0
- package/dist/Components/FormControl/FormControl.vue.d.ts +17 -0
- package/dist/Components/FormControl/FormControl.vue_vue_type_script_setup_true_lang.js +31 -0
- package/dist/Components/FormControl/composables/useFormControl.d.ts +45 -0
- package/dist/Components/FormControl/composables/useFormControl.js +110 -0
- package/dist/Components/FormControl/formControl.types.d.ts +198 -0
- package/dist/Components/FormControl/index.d.ts +4 -0
- package/dist/Components/FormControl/index.js +3 -0
- package/dist/Components/FormField/FilledFormField.js +5 -0
- package/dist/Components/FormField/FilledFormField.vue.d.ts +17 -0
- package/dist/Components/FormField/FilledFormField.vue_vue_type_script_setup_true_lang.js +39 -0
- package/dist/Components/FormField/FormField.js +5 -0
- package/dist/Components/FormField/FormField.vue.d.ts +15 -0
- package/dist/Components/FormField/FormField.vue_vue_type_script_setup_true_lang.js +37 -0
- package/dist/Components/FormField/NotchedFormField.js +5 -0
- package/dist/Components/FormField/NotchedFormField.vue.d.ts +17 -0
- package/dist/Components/FormField/NotchedFormField.vue_vue_type_script_setup_true_lang.js +38 -0
- package/dist/Components/FormField/OutlinedFormField.js +5 -0
- package/dist/Components/FormField/OutlinedFormField.vue.d.ts +17 -0
- package/dist/Components/FormField/OutlinedFormField.vue_vue_type_script_setup_true_lang.js +39 -0
- package/dist/Components/FormField/StackedFormField.js +5 -0
- package/dist/Components/FormField/StackedFormField.vue.d.ts +17 -0
- package/dist/Components/FormField/StackedFormField.vue_vue_type_script_setup_true_lang.js +42 -0
- package/dist/Components/FormField/UnderlinedFormField.js +5 -0
- package/dist/Components/FormField/UnderlinedFormField.vue.d.ts +17 -0
- package/dist/Components/FormField/UnderlinedFormField.vue_vue_type_script_setup_true_lang.js +39 -0
- package/dist/Components/FormField/composables/useFormField.d.ts +474 -0
- package/dist/Components/FormField/composables/useFormField.js +219 -0
- package/dist/Components/FormField/formField.types.d.ts +294 -0
- package/dist/Components/FormField/index.d.ts +4 -0
- package/dist/Components/FormField/index.js +3 -0
- package/dist/Components/Icon/Icon.js +5 -0
- package/dist/Components/Icon/Icon.vue.d.ts +4 -0
- package/dist/Components/Icon/Icon.vue_vue_type_script_setup_true_lang.js +17 -0
- package/dist/Components/Icon/composables/useIcon.d.ts +9 -0
- package/dist/Components/Icon/composables/useIcon.js +26 -0
- package/dist/Components/Icon/icon.types.d.ts +17 -0
- package/dist/Components/Icon/index.d.ts +3 -0
- package/dist/Components/Icon/index.js +3 -0
- package/dist/Components/Label/Label.js +5 -0
- package/dist/Components/Label/Label.vue.d.ts +4 -0
- package/dist/Components/Label/Label.vue_vue_type_script_setup_true_lang.js +21 -0
- package/dist/Components/Label/composables/useLabel.d.ts +10 -0
- package/dist/Components/Label/composables/useLabel.js +44 -0
- package/dist/Components/Label/index.d.ts +3 -0
- package/dist/Components/Label/index.js +3 -0
- package/dist/Components/Label/label.types.d.ts +52 -0
- package/dist/Components/Link/Link.js +5 -0
- package/dist/Components/Link/Link.vue.d.ts +11 -0
- package/dist/Components/Link/Link.vue_vue_type_script_setup_true_lang.js +52 -0
- package/dist/Components/Link/composables/useLink.d.ts +18 -0
- package/dist/Components/Link/composables/useLink.js +66 -0
- package/dist/Components/Link/index.d.ts +3 -0
- package/dist/Components/Link/index.js +3 -0
- package/dist/Components/Link/link.types.d.ts +113 -0
- package/dist/Components/List/List.js +5 -0
- package/dist/Components/List/List.vue.d.ts +9 -0
- package/dist/Components/List/List.vue_vue_type_script_setup_true_lang.js +31 -0
- package/dist/Components/List/composables/useList.d.ts +11 -0
- package/dist/Components/List/composables/useList.js +44 -0
- package/dist/Components/List/index.d.ts +5 -0
- package/dist/Components/List/index.js +4 -0
- package/dist/Components/List/list.types.d.ts +57 -0
- package/dist/Components/List/listInjectionKey.d.ts +5 -0
- package/dist/Components/List/listInjectionKey.js +4 -0
- package/dist/Components/ListItem/ListItem.js +5 -0
- package/dist/Components/ListItem/ListItem.vue.d.ts +19 -0
- package/dist/Components/ListItem/ListItem.vue_vue_type_script_setup_true_lang.js +57 -0
- package/dist/Components/ListItem/composables/useListItem.d.ts +40 -0
- package/dist/Components/ListItem/composables/useListItem.js +104 -0
- package/dist/Components/ListItem/index.d.ts +3 -0
- package/dist/Components/ListItem/index.js +3 -0
- package/dist/Components/ListItem/listItem.types.d.ts +164 -0
- package/dist/Components/ListSection/ListSection.js +5 -0
- package/dist/Components/ListSection/ListSection.vue.d.ts +15 -0
- package/dist/Components/ListSection/ListSection.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/Components/ListSection/composables/useListSection.d.ts +13 -0
- package/dist/Components/ListSection/composables/useListSection.js +51 -0
- package/dist/Components/ListSection/index.d.ts +3 -0
- package/dist/Components/ListSection/index.js +3 -0
- package/dist/Components/ListSection/listSection.types.d.ts +71 -0
- package/dist/Components/Listbox/Listbox.js +5 -0
- package/dist/Components/Listbox/Listbox.vue.d.ts +34 -0
- package/dist/Components/Listbox/Listbox.vue_vue_type_script_setup_true_lang.js +157 -0
- package/dist/Components/Listbox/composables/useListbox.d.ts +13 -0
- package/dist/Components/Listbox/composables/useListbox.js +47 -0
- package/dist/Components/Listbox/composables/useListboxNavigation.d.ts +16 -0
- package/dist/Components/Listbox/composables/useListboxNavigation.js +62 -0
- package/dist/Components/Listbox/index.d.ts +4 -0
- package/dist/Components/Listbox/index.js +4 -0
- package/dist/Components/Listbox/listbox.types.d.ts +170 -0
- package/dist/Components/Menu/Menu.js +5 -0
- package/dist/Components/Menu/Menu.vue.d.ts +36 -0
- package/dist/Components/Menu/Menu.vue_vue_type_script_setup_true_lang.js +80 -0
- package/dist/Components/Menu/composables/useMenu.d.ts +54 -0
- package/dist/Components/Menu/composables/useMenu.js +217 -0
- package/dist/Components/Menu/index.d.ts +4 -0
- package/dist/Components/Menu/index.js +3 -0
- package/dist/Components/Menu/menu.types.d.ts +172 -0
- package/dist/Components/Modal/Modal.js +5 -0
- package/dist/Components/Modal/Modal.vue.d.ts +38 -0
- package/dist/Components/Modal/Modal.vue_vue_type_script_setup_true_lang.js +94 -0
- package/dist/Components/Modal/composables/useModal.d.ts +61 -0
- package/dist/Components/Modal/composables/useModal.js +191 -0
- package/dist/Components/Modal/index.d.ts +4 -0
- package/dist/Components/Modal/index.js +3 -0
- package/dist/Components/Modal/modal.types.d.ts +177 -0
- package/dist/Components/NumberField/NumberField.js +5 -0
- package/dist/Components/NumberField/NumberField.vue.d.ts +24 -0
- package/dist/Components/NumberField/NumberField.vue_vue_type_script_setup_true_lang.js +83 -0
- package/dist/Components/NumberField/composables/useNumberField.d.ts +696 -0
- package/dist/Components/NumberField/composables/useNumberField.js +64 -0
- package/dist/Components/NumberField/index.d.ts +4 -0
- package/dist/Components/NumberField/index.js +3 -0
- package/dist/Components/NumberField/numberField.types.d.ts +52 -0
- package/dist/Components/PasswordField/PasswordField.js +5 -0
- package/dist/Components/PasswordField/PasswordField.vue.d.ts +24 -0
- package/dist/Components/PasswordField/PasswordField.vue_vue_type_script_setup_true_lang.js +67 -0
- package/dist/Components/PasswordField/composables/usePasswordField.d.ts +691 -0
- package/dist/Components/PasswordField/composables/usePasswordField.js +40 -0
- package/dist/Components/PasswordField/index.d.ts +4 -0
- package/dist/Components/PasswordField/index.js +3 -0
- package/dist/Components/PasswordField/passwordField.types.d.ts +34 -0
- package/dist/Components/Radio/Radio.js +5 -0
- package/dist/Components/Radio/Radio.vue.d.ts +20 -0
- package/dist/Components/Radio/Radio.vue_vue_type_script_setup_true_lang.js +57 -0
- package/dist/Components/Radio/composables/useRadio.d.ts +278 -0
- package/dist/Components/Radio/composables/useRadio.js +78 -0
- package/dist/Components/Radio/index.d.ts +3 -0
- package/dist/Components/Radio/index.js +3 -0
- package/dist/Components/Radio/radio.types.d.ts +104 -0
- package/dist/Components/Select/Select.js +5 -0
- package/dist/Components/Select/Select.vue.d.ts +40 -0
- package/dist/Components/Select/Select.vue_vue_type_script_setup_true_lang.js +191 -0
- package/dist/Components/Select/SelectOption.js +5 -0
- package/dist/Components/Select/SelectOption.vue.d.ts +4 -0
- package/dist/Components/Select/SelectOption.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/Components/Select/composables/useSelect.d.ts +733 -0
- package/dist/Components/Select/composables/useSelect.js +305 -0
- package/dist/Components/Select/index.d.ts +4 -0
- package/dist/Components/Select/index.js +4 -0
- package/dist/Components/Select/select.types.d.ts +231 -0
- package/dist/Components/Select/selectInjectionKey.d.ts +7 -0
- package/dist/Components/Select/selectInjectionKey.js +4 -0
- package/dist/Components/Snackbar/Snackbar.js +5 -0
- package/dist/Components/Snackbar/Snackbar.vue.d.ts +32 -0
- package/dist/Components/Snackbar/Snackbar.vue_vue_type_script_setup_true_lang.js +156 -0
- package/dist/Components/Snackbar/composables/useSnackbar.d.ts +248 -0
- package/dist/Components/Snackbar/composables/useSnackbar.js +210 -0
- package/dist/Components/Snackbar/index.d.ts +4 -0
- package/dist/Components/Snackbar/index.js +3 -0
- package/dist/Components/Snackbar/snackbar.types.d.ts +214 -0
- package/dist/Components/Snackbar/snackbarDefaultIcons.d.ts +4 -0
- package/dist/Components/Snackbar/snackbarDefaultIcons.js +13 -0
- package/dist/Components/Switch/Switch.js +5 -0
- package/dist/Components/Switch/Switch.vue.d.ts +20 -0
- package/dist/Components/Switch/Switch.vue_vue_type_script_setup_true_lang.js +61 -0
- package/dist/Components/Switch/composables/useSwitch.d.ts +278 -0
- package/dist/Components/Switch/composables/useSwitch.js +73 -0
- package/dist/Components/Switch/index.d.ts +3 -0
- package/dist/Components/Switch/index.js +3 -0
- package/dist/Components/Switch/switch.types.d.ts +92 -0
- package/dist/Components/TextField/TextField.js +5 -0
- package/dist/Components/TextField/TextField.vue.d.ts +22 -0
- package/dist/Components/TextField/TextField.vue_vue_type_script_setup_true_lang.js +49 -0
- package/dist/Components/TextField/composables/useTextField.d.ts +680 -0
- package/dist/Components/TextField/composables/useTextField.js +21 -0
- package/dist/Components/TextField/index.d.ts +3 -0
- package/dist/Components/TextField/index.js +3 -0
- package/dist/Components/TextField/textField.types.d.ts +15 -0
- package/dist/Components/Textarea/Textarea.js +5 -0
- package/dist/Components/Textarea/Textarea.vue.d.ts +22 -0
- package/dist/Components/Textarea/Textarea.vue_vue_type_script_setup_true_lang.js +57 -0
- package/dist/Components/Textarea/composables/useTextarea.d.ts +685 -0
- package/dist/Components/Textarea/composables/useTextarea.js +72 -0
- package/dist/Components/Textarea/index.d.ts +3 -0
- package/dist/Components/Textarea/index.js +3 -0
- package/dist/Components/Textarea/textarea.types.d.ts +34 -0
- package/dist/Provider/BridgeUIProvider.js +5 -0
- package/dist/Provider/BridgeUIProvider.vue.d.ts +18 -0
- package/dist/Provider/BridgeUIProvider.vue_vue_type_script_setup_true_lang.js +20 -0
- package/dist/Provider/bridgeUITypes.d.ts +8 -0
- package/dist/Provider/createBridgeUI.d.ts +3 -0
- package/dist/Provider/createBridgeUI.js +15 -0
- package/dist/Provider/createBridgeUIApi.d.ts +7 -0
- package/dist/Provider/createBridgeUIApi.js +36 -0
- package/dist/Provider/index.d.ts +5 -0
- package/dist/Provider/index.js +4 -0
- package/dist/Provider/injectionKey.d.ts +3 -0
- package/dist/Provider/injectionKey.js +4 -0
- package/dist/Provider/useBridgeUI.d.ts +2 -0
- package/dist/Provider/useBridgeUI.js +8 -0
- package/dist/Utils/index.d.ts +47 -0
- package/dist/Utils/index.js +55 -0
- package/dist/Utils/slotOrProp.d.ts +28 -0
- package/dist/Utils/slotOrProp.js +23 -0
- package/dist/Utils/useHoldRepeat.d.ts +13 -0
- package/dist/Utils/useHoldRepeat.js +38 -0
- package/dist/augments.d.ts +113 -0
- package/dist/index.d.ts +54 -0
- package/dist/index.js +53 -0
- package/dist/theme.css +205 -0
- package/package.json +90 -0
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { mergePartBind as e, useBridgeUIComponent as t, useBridgeUIMergedRegistryClasses as n } from "../../../Utils/index.js";
|
|
2
|
+
import { computed as r, useAttrs as i } from "vue";
|
|
3
|
+
import { get as a } from "es-toolkit/compat";
|
|
4
|
+
import { cn as o, mergeBridgeUILayeredClasses as s, splitComponentProps as c } from "@bridge-ui/core";
|
|
5
|
+
import { invalidatedProps as l, sizeProps as u } from "@bridge-ui/core/Components/Label";
|
|
6
|
+
//#region src/Components/Label/composables/useLabel.ts
|
|
7
|
+
var d = [
|
|
8
|
+
"size",
|
|
9
|
+
"error",
|
|
10
|
+
"classes",
|
|
11
|
+
"required"
|
|
12
|
+
];
|
|
13
|
+
function f(f, p) {
|
|
14
|
+
let m = i(), h = r(() => c({
|
|
15
|
+
bridgeKeys: d,
|
|
16
|
+
props: {
|
|
17
|
+
...m,
|
|
18
|
+
...f
|
|
19
|
+
}
|
|
20
|
+
})), { merged: g, entry: _ } = t({
|
|
21
|
+
libDefaults: p,
|
|
22
|
+
componentName: "Label",
|
|
23
|
+
props: () => h.value.componentProps
|
|
24
|
+
}), v = n({
|
|
25
|
+
entry: _,
|
|
26
|
+
props: () => h.value.componentProps
|
|
27
|
+
}), y = r(() => a(s(u, _.value?.customProps?.size), g.value.size)), b = r(() => s(l, _.value?.customProps?.invalidated)), x = r(() => e({}, {}, o({
|
|
28
|
+
[b.value.required ?? ""]: !0,
|
|
29
|
+
[v.value.required ?? ""]: !0
|
|
30
|
+
})));
|
|
31
|
+
return {
|
|
32
|
+
merged: g,
|
|
33
|
+
rootBind: r(() => e({}, h.value.inheritedAttrs, o({
|
|
34
|
+
"inline-flex items-center gap-x-0.5 font-medium leading-none": !0,
|
|
35
|
+
"text-gray-700 dark:text-gray-300": !g.value.error,
|
|
36
|
+
[b.value.label ?? ""]: g.value.error,
|
|
37
|
+
[y.value ?? ""]: !0,
|
|
38
|
+
[v.value.root ?? ""]: !0
|
|
39
|
+
}))),
|
|
40
|
+
requiredBind: x
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
//#endregion
|
|
44
|
+
export { f as useLabel };
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { HTMLAttributes, Slot } from 'vue';
|
|
2
|
+
import { LabelSize, MergeHtmlProps, MergeProps } from '@bridge-ui/core';
|
|
3
|
+
export interface LabelSizeOverrides {}
|
|
4
|
+
export interface LabelClasses {
|
|
5
|
+
/**
|
|
6
|
+
* Classes merged onto the required asterisk.
|
|
7
|
+
*/
|
|
8
|
+
required?: string;
|
|
9
|
+
/**
|
|
10
|
+
* Classes merged onto the `<label>` element.
|
|
11
|
+
*/
|
|
12
|
+
root?: string;
|
|
13
|
+
}
|
|
14
|
+
export interface LabelOwnProps {
|
|
15
|
+
/**
|
|
16
|
+
* The classes to apply to the label.
|
|
17
|
+
*
|
|
18
|
+
* @default undefined
|
|
19
|
+
*/
|
|
20
|
+
classes?: LabelClasses;
|
|
21
|
+
/**
|
|
22
|
+
* Applies error label colors.
|
|
23
|
+
*
|
|
24
|
+
* @default false
|
|
25
|
+
*/
|
|
26
|
+
error?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* Associates the label with a form control.
|
|
29
|
+
*
|
|
30
|
+
* @default undefined
|
|
31
|
+
*/
|
|
32
|
+
for?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Shows a red required asterisk after the label text.
|
|
35
|
+
*
|
|
36
|
+
* @default false
|
|
37
|
+
*/
|
|
38
|
+
required?: boolean;
|
|
39
|
+
/**
|
|
40
|
+
* Typography scale aligned with TextField sizes.
|
|
41
|
+
*
|
|
42
|
+
* @default "md"
|
|
43
|
+
*/
|
|
44
|
+
size?: MergeProps<LabelSize, LabelSizeOverrides>;
|
|
45
|
+
}
|
|
46
|
+
export interface LabelSlots {
|
|
47
|
+
/**
|
|
48
|
+
* Label content.
|
|
49
|
+
*/
|
|
50
|
+
default?: Slot;
|
|
51
|
+
}
|
|
52
|
+
export type LabelProps = MergeHtmlProps<LabelOwnProps, HTMLAttributes>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LinkOwnProps, LinkSlots } from './link.types';
|
|
2
|
+
type __VLS_Slots = LinkSlots;
|
|
3
|
+
declare const __VLS_base: import('vue').DefineComponent<LinkOwnProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<LinkOwnProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
4
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
5
|
+
declare const _default: typeof __VLS_export;
|
|
6
|
+
export default _default;
|
|
7
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
8
|
+
new (): {
|
|
9
|
+
$slots: S;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { hasNamedSlot as e, resolveNamedSlot as t } from "../../Utils/slotOrProp.js";
|
|
2
|
+
import n from "../Icon/Icon.js";
|
|
3
|
+
import { useLink as r } from "./composables/useLink.js";
|
|
4
|
+
import { createBlock as i, createCommentVNode as a, createElementBlock as o, defineComponent as s, mergeProps as c, openBlock as l, resolveDynamicComponent as u, unref as d } from "vue";
|
|
5
|
+
//#region src/Components/Link/Link.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
+
var f = [
|
|
7
|
+
"rel",
|
|
8
|
+
"href",
|
|
9
|
+
"target",
|
|
10
|
+
"aria-disabled"
|
|
11
|
+
], p = /* @__PURE__ */ s({
|
|
12
|
+
inheritAttrs: !1,
|
|
13
|
+
__name: "Link",
|
|
14
|
+
props: {
|
|
15
|
+
classes: {},
|
|
16
|
+
color: {},
|
|
17
|
+
customProps: {},
|
|
18
|
+
disabled: { type: Boolean },
|
|
19
|
+
external: { type: Boolean },
|
|
20
|
+
href: {},
|
|
21
|
+
leftIcon: { type: [Function, Object] },
|
|
22
|
+
rightIcon: { type: [Function, Object] },
|
|
23
|
+
size: {},
|
|
24
|
+
underline: {}
|
|
25
|
+
},
|
|
26
|
+
setup(s) {
|
|
27
|
+
let { slots: p, merged: m, rootRel: h, rootBind: g, rootHref: _, rootTarget: v, leftIconBind: y, rightIconBind: b, rootAriaDisabled: x } = r(s, {
|
|
28
|
+
size: "md",
|
|
29
|
+
color: "primary",
|
|
30
|
+
underline: "hover"
|
|
31
|
+
});
|
|
32
|
+
return (r, s) => (l(), o("a", c({
|
|
33
|
+
rel: d(h),
|
|
34
|
+
href: d(_)
|
|
35
|
+
}, d(g), {
|
|
36
|
+
target: d(v),
|
|
37
|
+
"aria-disabled": d(x)
|
|
38
|
+
}), [
|
|
39
|
+
d(e)(d(p), "prepend") ? (l(), i(u(d(t)(d(p), "prepend")), { key: 0 })) : d(m).leftIcon ? (l(), i(d(n), c({
|
|
40
|
+
key: 1,
|
|
41
|
+
size: d(m).size
|
|
42
|
+
}, d(y), { icon: d(m).leftIcon }), null, 16, ["size", "icon"])) : a("", !0),
|
|
43
|
+
(l(), i(u(d(t)(d(p), "default")))),
|
|
44
|
+
d(e)(d(p), "append") ? (l(), i(u(d(t)(d(p), "append")), { key: 2 })) : d(m).rightIcon ? (l(), i(d(n), c({
|
|
45
|
+
key: 3,
|
|
46
|
+
size: d(m).size
|
|
47
|
+
}, d(b), { icon: d(m).rightIcon }), null, 16, ["size", "icon"])) : a("", !0)
|
|
48
|
+
], 16, f));
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
//#endregion
|
|
52
|
+
export { p as default };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { LibDefaultsShape, MergeLibDefaults } from '@bridge-ui/core';
|
|
2
|
+
import { LinkOwnProps, LinkProps } from '../link.types';
|
|
3
|
+
type LinkLibDefaults = LibDefaultsShape<LinkOwnProps, "size" | "color" | "underline">;
|
|
4
|
+
type LinkMerged = MergeLibDefaults<LinkOwnProps, LinkLibDefaults>;
|
|
5
|
+
export declare function useLink(props: LinkOwnProps, libDefaults: LinkLibDefaults): {
|
|
6
|
+
slots: Readonly<{
|
|
7
|
+
[name: string]: import('vue').Slot<any> | undefined;
|
|
8
|
+
}>;
|
|
9
|
+
merged: import('vue').ComputedRef<LinkMerged>;
|
|
10
|
+
rootRel: import('vue').ComputedRef<"noopener noreferrer" | undefined>;
|
|
11
|
+
rootBind: import('vue').ComputedRef<import('@bridge-ui/core').MergePartBind<object, "class", import('vue').HTMLAttributes | undefined, Omit<LinkProps, "color" | "href" | "size" | "classes" | "customProps" | "disabled" | "external" | "leftIcon" | "rightIcon" | "underline">>>;
|
|
12
|
+
rootHref: import('vue').ComputedRef<string | undefined>;
|
|
13
|
+
rootTarget: import('vue').ComputedRef<"_blank" | undefined>;
|
|
14
|
+
leftIconBind: import('vue').ComputedRef<import('@bridge-ui/core').MergePartBind<object, "class", Partial<Omit<import('../../Icon').IconProps, "icon">> | undefined, {}>>;
|
|
15
|
+
rightIconBind: import('vue').ComputedRef<import('@bridge-ui/core').MergePartBind<object, "class", Partial<Omit<import('../../Icon').IconProps, "icon">> | undefined, {}>>;
|
|
16
|
+
rootAriaDisabled: import('vue').ComputedRef<true | undefined>;
|
|
17
|
+
};
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { mergePartBind as e, useBridgeUIComponent as t, useBridgeUIMergedRegistryClasses as n } from "../../../Utils/index.js";
|
|
2
|
+
import { computed as r, useAttrs as i, useSlots as a } from "vue";
|
|
3
|
+
import { get as o } from "es-toolkit/compat";
|
|
4
|
+
import { cn as s, mergeBridgeUILayeredClasses as c, splitComponentProps as l } from "@bridge-ui/core";
|
|
5
|
+
import { colorProps as u, sizeProps as d, underlineProps as f } from "@bridge-ui/core/Components/Link";
|
|
6
|
+
//#region src/Components/Link/composables/useLink.ts
|
|
7
|
+
var p = [
|
|
8
|
+
"href",
|
|
9
|
+
"size",
|
|
10
|
+
"color",
|
|
11
|
+
"classes",
|
|
12
|
+
"disabled",
|
|
13
|
+
"external",
|
|
14
|
+
"leftIcon",
|
|
15
|
+
"rightIcon",
|
|
16
|
+
"underline",
|
|
17
|
+
"customProps"
|
|
18
|
+
];
|
|
19
|
+
function m(m, h) {
|
|
20
|
+
let g = i(), _ = a(), v = r(() => l({
|
|
21
|
+
bridgeKeys: p,
|
|
22
|
+
props: {
|
|
23
|
+
...g,
|
|
24
|
+
...m
|
|
25
|
+
}
|
|
26
|
+
})), { merged: y, entry: b } = t({
|
|
27
|
+
libDefaults: h,
|
|
28
|
+
componentName: "Link",
|
|
29
|
+
props: () => v.value.componentProps
|
|
30
|
+
}), x = r(() => y.value.customProps), S = n({
|
|
31
|
+
entry: b,
|
|
32
|
+
props: () => v.value.componentProps
|
|
33
|
+
}), C = r(() => !!y.value.disabled), w = r(() => C.value ? !0 : void 0), T = r(() => C.value ? void 0 : y.value.href), E = r(() => {
|
|
34
|
+
if (y.value.external && !C.value) return "_blank";
|
|
35
|
+
}), D = r(() => {
|
|
36
|
+
if (y.value.external && !C.value) return "noopener noreferrer";
|
|
37
|
+
}), O = r(() => o(c(d, b.value?.customProps?.size), y.value.size)), k = r(() => o(c(u, b.value?.customProps?.color), y.value.color)), A = r(() => o(c(f, b.value?.customProps?.underline), y.value.underline));
|
|
38
|
+
return {
|
|
39
|
+
slots: _,
|
|
40
|
+
merged: y,
|
|
41
|
+
rootRel: D,
|
|
42
|
+
rootBind: r(() => e(x.value?.root, v.value.inheritedAttrs, s({
|
|
43
|
+
"inline-flex items-center gap-x-1 font-medium": !0,
|
|
44
|
+
"transition-colors duration-200": !0,
|
|
45
|
+
[O.value ?? ""]: !0,
|
|
46
|
+
[A.value ?? ""]: !0,
|
|
47
|
+
[o(k.value, "base") ?? ""]: !0,
|
|
48
|
+
[o(k.value, "hover") ?? ""]: !0,
|
|
49
|
+
"aria-disabled:opacity-80 aria-disabled:cursor-not-allowed aria-disabled:pointer-events-none": !0,
|
|
50
|
+
[S.value.root ?? ""]: !0
|
|
51
|
+
}))),
|
|
52
|
+
rootHref: T,
|
|
53
|
+
rootTarget: E,
|
|
54
|
+
leftIconBind: r(() => e(x.value?.leftIcon, {}, s({
|
|
55
|
+
"shrink-0": !0,
|
|
56
|
+
[S.value.leftIcon ?? ""]: !0
|
|
57
|
+
}))),
|
|
58
|
+
rightIconBind: r(() => e(x.value?.rightIcon, {}, s({
|
|
59
|
+
"shrink-0": !0,
|
|
60
|
+
[S.value.rightIcon ?? ""]: !0
|
|
61
|
+
}))),
|
|
62
|
+
rootAriaDisabled: w
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
//#endregion
|
|
66
|
+
export { m as useLink };
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { LucideIcon } from 'lucide-vue-next';
|
|
2
|
+
import { AnchorHTMLAttributes, HTMLAttributes, Slot } from 'vue';
|
|
3
|
+
import { LinkColor, LinkSize, LinkUnderline, MergeHtmlProps, MergeProps } from '@bridge-ui/core';
|
|
4
|
+
import { IconProps } from '../Icon';
|
|
5
|
+
export interface LinkSizeOverrides {}
|
|
6
|
+
export interface LinkColorOverrides {}
|
|
7
|
+
export interface LinkUnderlineOverrides {}
|
|
8
|
+
export interface LinkClasses {
|
|
9
|
+
/**
|
|
10
|
+
* The classes to apply to the left icon.
|
|
11
|
+
*/
|
|
12
|
+
leftIcon?: string;
|
|
13
|
+
/**
|
|
14
|
+
* The classes to apply to the right icon.
|
|
15
|
+
*/
|
|
16
|
+
rightIcon?: string;
|
|
17
|
+
/**
|
|
18
|
+
* The classes to apply to the root.
|
|
19
|
+
*/
|
|
20
|
+
root?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface LinkCustomProps {
|
|
23
|
+
/**
|
|
24
|
+
* Props forwarded to the left `Icon` (`icon` is set by the link).
|
|
25
|
+
*/
|
|
26
|
+
leftIcon?: Partial<Omit<IconProps, "icon">>;
|
|
27
|
+
/**
|
|
28
|
+
* Props forwarded to the right `Icon` (`icon` is set by the link).
|
|
29
|
+
*/
|
|
30
|
+
rightIcon?: Partial<Omit<IconProps, "icon">>;
|
|
31
|
+
/**
|
|
32
|
+
* Props forwarded to the root `<a>`.
|
|
33
|
+
*/
|
|
34
|
+
root?: HTMLAttributes;
|
|
35
|
+
}
|
|
36
|
+
export interface LinkOwnProps {
|
|
37
|
+
/**
|
|
38
|
+
* The classes to apply to the link.
|
|
39
|
+
*
|
|
40
|
+
* @default undefined
|
|
41
|
+
*/
|
|
42
|
+
classes?: LinkClasses;
|
|
43
|
+
/**
|
|
44
|
+
* The color to apply to the link.
|
|
45
|
+
*
|
|
46
|
+
* @default "primary"
|
|
47
|
+
*/
|
|
48
|
+
color?: MergeProps<LinkColor, LinkColorOverrides>;
|
|
49
|
+
/**
|
|
50
|
+
* Extra props for internal parts (`leftIcon`, `rightIcon`, etc.).
|
|
51
|
+
* Root HTML attributes stay on the component top level.
|
|
52
|
+
*
|
|
53
|
+
* @default undefined
|
|
54
|
+
*/
|
|
55
|
+
customProps?: LinkCustomProps;
|
|
56
|
+
/**
|
|
57
|
+
* Whether the link is disabled.
|
|
58
|
+
*
|
|
59
|
+
* @default false
|
|
60
|
+
*/
|
|
61
|
+
disabled?: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* Whether the link opens in a new tab.
|
|
64
|
+
*
|
|
65
|
+
* @default false
|
|
66
|
+
*/
|
|
67
|
+
external?: boolean;
|
|
68
|
+
/**
|
|
69
|
+
* The URL the link points to.
|
|
70
|
+
*
|
|
71
|
+
* @default undefined
|
|
72
|
+
*/
|
|
73
|
+
href?: string;
|
|
74
|
+
/**
|
|
75
|
+
* The icon to display before the link text.
|
|
76
|
+
*
|
|
77
|
+
* @default undefined
|
|
78
|
+
*/
|
|
79
|
+
leftIcon?: LucideIcon;
|
|
80
|
+
/**
|
|
81
|
+
* The icon to display after the link text.
|
|
82
|
+
*
|
|
83
|
+
* @default undefined
|
|
84
|
+
*/
|
|
85
|
+
rightIcon?: LucideIcon;
|
|
86
|
+
/**
|
|
87
|
+
* The size of the link.
|
|
88
|
+
*
|
|
89
|
+
* @default "md"
|
|
90
|
+
*/
|
|
91
|
+
size?: MergeProps<LinkSize, LinkSizeOverrides>;
|
|
92
|
+
/**
|
|
93
|
+
* The underline behavior of the link.
|
|
94
|
+
*
|
|
95
|
+
* @default "hover"
|
|
96
|
+
*/
|
|
97
|
+
underline?: MergeProps<LinkUnderline, LinkUnderlineOverrides>;
|
|
98
|
+
}
|
|
99
|
+
export interface LinkSlots {
|
|
100
|
+
/**
|
|
101
|
+
* Content after the label (inline end).
|
|
102
|
+
*/
|
|
103
|
+
append?: Slot;
|
|
104
|
+
/**
|
|
105
|
+
* The link label.
|
|
106
|
+
*/
|
|
107
|
+
default?: Slot;
|
|
108
|
+
/**
|
|
109
|
+
* Content before the label (inline start).
|
|
110
|
+
*/
|
|
111
|
+
prepend?: Slot;
|
|
112
|
+
}
|
|
113
|
+
export type LinkProps = MergeHtmlProps<LinkOwnProps, AnchorHTMLAttributes>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ListOwnProps } from './list.types';
|
|
2
|
+
declare const __VLS_export: import('vue').DefineComponent<ListOwnProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ListOwnProps> & Readonly<{}>, {
|
|
3
|
+
padding: import('@bridge-ui/core').MergeProps<import('@bridge-ui/core').ListPadding, import('./list.types').ListPaddingOverrides>;
|
|
4
|
+
as: "ol" | "ul" | "nav";
|
|
5
|
+
dense: boolean;
|
|
6
|
+
nested: boolean;
|
|
7
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
8
|
+
declare const _default: typeof __VLS_export;
|
|
9
|
+
export default _default;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { resolveNamedSlot as e } from "../../Utils/slotOrProp.js";
|
|
2
|
+
import { useList as t } from "./composables/useList.js";
|
|
3
|
+
import { computed as n, createBlock as r, defineComponent as i, guardReactiveProps as a, normalizeProps as o, openBlock as s, resolveDynamicComponent as c, unref as l, useSlots as u, withCtx as d } from "vue";
|
|
4
|
+
//#region src/Components/List/List.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
+
var f = /* @__PURE__ */ i({
|
|
6
|
+
inheritAttrs: !1,
|
|
7
|
+
__name: "List",
|
|
8
|
+
props: {
|
|
9
|
+
as: { default: "ul" },
|
|
10
|
+
classes: {},
|
|
11
|
+
customProps: {},
|
|
12
|
+
dense: {
|
|
13
|
+
type: Boolean,
|
|
14
|
+
default: !1
|
|
15
|
+
},
|
|
16
|
+
nested: {
|
|
17
|
+
type: Boolean,
|
|
18
|
+
default: !1
|
|
19
|
+
},
|
|
20
|
+
padding: { default: "normal" }
|
|
21
|
+
},
|
|
22
|
+
setup(i) {
|
|
23
|
+
let f = u(), { merged: p, rootBind: m } = t(i, { padding: "normal" }), h = n(() => p.value.as ?? "ul");
|
|
24
|
+
return (t, n) => (s(), r(c(h.value), o(a(l(m))), {
|
|
25
|
+
default: d(() => [(s(), r(c(l(e)(l(f), "default"))))]),
|
|
26
|
+
_: 1
|
|
27
|
+
}, 16));
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
//#endregion
|
|
31
|
+
export { f as default };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LibDefaultsShape, MergeLibDefaults } from '@bridge-ui/core';
|
|
2
|
+
import { ListOwnProps, ListProps } from '../list.types';
|
|
3
|
+
type ListLibDefaults = LibDefaultsShape<ListOwnProps, "padding">;
|
|
4
|
+
type ListMerged = MergeLibDefaults<ListOwnProps, ListLibDefaults>;
|
|
5
|
+
export declare function useList(props: ListOwnProps, libDefaults: ListLibDefaults): {
|
|
6
|
+
merged: import('vue').ComputedRef<ListMerged>;
|
|
7
|
+
rootBind: import('vue').ComputedRef<import('@bridge-ui/core').MergePartBind<{
|
|
8
|
+
class: string;
|
|
9
|
+
}, "class", import('vue').HTMLAttributes | undefined, Omit<Omit<ListProps, "classes" | "customProps" | "padding" | "as" | "dense" | "nested">, never>>>;
|
|
10
|
+
};
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { mergePartBind as e, useBridgeUIComponent as t, useBridgeUIMergedRegistryClasses as n } from "../../../Utils/index.js";
|
|
2
|
+
import { LIST_INJECTION_KEY as r } from "../listInjectionKey.js";
|
|
3
|
+
import { computed as i, provide as a, useAttrs as o } from "vue";
|
|
4
|
+
import { get as s, omit as c } from "es-toolkit/compat";
|
|
5
|
+
import { cn as l, mergeBridgeUILayeredClasses as u, splitComponentProps as d } from "@bridge-ui/core";
|
|
6
|
+
import { paddingProps as f } from "@bridge-ui/core/Components/List";
|
|
7
|
+
//#region src/Components/List/composables/useList.ts
|
|
8
|
+
var p = [
|
|
9
|
+
"as",
|
|
10
|
+
"dense",
|
|
11
|
+
"nested",
|
|
12
|
+
"classes",
|
|
13
|
+
"padding",
|
|
14
|
+
"customProps"
|
|
15
|
+
];
|
|
16
|
+
function m(m, h) {
|
|
17
|
+
let g = o(), _ = i(() => d({
|
|
18
|
+
bridgeKeys: p,
|
|
19
|
+
props: {
|
|
20
|
+
...g,
|
|
21
|
+
...m
|
|
22
|
+
}
|
|
23
|
+
})), { merged: v, entry: y } = t({
|
|
24
|
+
libDefaults: h,
|
|
25
|
+
componentName: "List",
|
|
26
|
+
props: () => _.value.componentProps
|
|
27
|
+
}), b = i(() => v.value.customProps), x = n({
|
|
28
|
+
entry: y,
|
|
29
|
+
props: () => _.value.componentProps
|
|
30
|
+
});
|
|
31
|
+
a(r, i(() => ({ dense: v.value.dense === !0 })));
|
|
32
|
+
let S = i(() => s(u(f, y.value?.customProps?.padding), v.value.padding)), C = i(() => c(_.value.inheritedAttrs, []));
|
|
33
|
+
return {
|
|
34
|
+
merged: v,
|
|
35
|
+
rootBind: i(() => e(b.value?.root, C.value, { class: l({
|
|
36
|
+
"m-0 list-none": !0,
|
|
37
|
+
[S.value ?? ""]: !0,
|
|
38
|
+
"pl-4": v.value.nested,
|
|
39
|
+
[s(x.value, "root") ?? ""]: !0
|
|
40
|
+
}) }))
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
//#endregion
|
|
44
|
+
export { m as useList };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { useList } from './composables/useList';
|
|
2
|
+
export type { ListClasses, ListCustomProps, ListOwnProps, ListPaddingOverrides, ListProps, } from './list.types';
|
|
3
|
+
export { default as List } from './List.vue';
|
|
4
|
+
export { LIST_INJECTION_KEY } from './listInjectionKey';
|
|
5
|
+
export type { ListContextValue } from './listInjectionKey';
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'vue';
|
|
2
|
+
import { ListPadding, MergeHtmlProps, MergeProps } from '@bridge-ui/core';
|
|
3
|
+
export interface ListPaddingOverrides {}
|
|
4
|
+
export interface ListClasses {
|
|
5
|
+
/**
|
|
6
|
+
* The classes to apply to the root.
|
|
7
|
+
*/
|
|
8
|
+
root?: string;
|
|
9
|
+
}
|
|
10
|
+
export interface ListCustomProps {
|
|
11
|
+
/**
|
|
12
|
+
* Props forwarded to the root element.
|
|
13
|
+
*/
|
|
14
|
+
root?: HTMLAttributes;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Vertical list container (MUI `List`-like). Use with `ListItem` and `ListSection`.
|
|
18
|
+
*/
|
|
19
|
+
export interface ListOwnProps {
|
|
20
|
+
/**
|
|
21
|
+
* The element to render as.
|
|
22
|
+
*
|
|
23
|
+
* @default "ul"
|
|
24
|
+
*/
|
|
25
|
+
as?: "ol" | "ul" | "nav";
|
|
26
|
+
/**
|
|
27
|
+
* The classes to apply to the list.
|
|
28
|
+
*
|
|
29
|
+
* @default undefined
|
|
30
|
+
*/
|
|
31
|
+
classes?: ListClasses;
|
|
32
|
+
/**
|
|
33
|
+
* Props forwarded to each list part.
|
|
34
|
+
*
|
|
35
|
+
* @default undefined
|
|
36
|
+
*/
|
|
37
|
+
customProps?: ListCustomProps;
|
|
38
|
+
/**
|
|
39
|
+
* Compact vertical spacing on items (`ListItem` / `ListSection`), not the list root.
|
|
40
|
+
*
|
|
41
|
+
* @default false
|
|
42
|
+
*/
|
|
43
|
+
dense?: boolean;
|
|
44
|
+
/**
|
|
45
|
+
* When true, indents the list for nested navigation/submenus.
|
|
46
|
+
*
|
|
47
|
+
* @default false
|
|
48
|
+
*/
|
|
49
|
+
nested?: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Root padding preset. Use `"none"` inside menus/cards (MUI `disablePadding`).
|
|
52
|
+
*
|
|
53
|
+
* @default "normal"
|
|
54
|
+
*/
|
|
55
|
+
padding?: MergeProps<ListPadding, ListPaddingOverrides>;
|
|
56
|
+
}
|
|
57
|
+
export type ListProps = MergeHtmlProps<ListOwnProps, HTMLAttributes>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { ListItemOwnProps, ListItemSlots } from './listItem.types';
|
|
2
|
+
type __VLS_Slots = ListItemSlots;
|
|
3
|
+
declare const __VLS_base: import('vue').DefineComponent<ListItemOwnProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ListItemOwnProps> & Readonly<{}>, {
|
|
4
|
+
role: "button" | "option" | "menuitem";
|
|
5
|
+
as: "li" | "div";
|
|
6
|
+
disabled: boolean;
|
|
7
|
+
align: import('@bridge-ui/core').MergeProps<import('@bridge-ui/core').ListItemAlign, import('./listItem.types').ListItemAlignOverrides>;
|
|
8
|
+
divider: boolean;
|
|
9
|
+
interactive: boolean;
|
|
10
|
+
selected: boolean;
|
|
11
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
12
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
13
|
+
declare const _default: typeof __VLS_export;
|
|
14
|
+
export default _default;
|
|
15
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
16
|
+
new (): {
|
|
17
|
+
$slots: S;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { resolveNamedSlot as e, resolveSlotOrProp as t } from "../../Utils/slotOrProp.js";
|
|
2
|
+
import { resolveListItemPrimary as n, useListItem as r } from "./composables/useListItem.js";
|
|
3
|
+
import { computed as i, createBlock as a, createCommentVNode as o, createElementBlock as s, createElementVNode as c, defineComponent as l, guardReactiveProps as u, mergeProps as d, normalizeClass as f, normalizeProps as p, openBlock as m, resolveDynamicComponent as h, unref as g, useSlots as _, withCtx as v } from "vue";
|
|
4
|
+
//#region src/Components/ListItem/ListItem.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
+
var y = /* @__PURE__ */ l({
|
|
6
|
+
inheritAttrs: !1,
|
|
7
|
+
__name: "ListItem",
|
|
8
|
+
props: {
|
|
9
|
+
align: { default: "center" },
|
|
10
|
+
as: { default: "li" },
|
|
11
|
+
classes: {},
|
|
12
|
+
customProps: {},
|
|
13
|
+
dense: { type: Boolean },
|
|
14
|
+
disabled: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: !1
|
|
17
|
+
},
|
|
18
|
+
divider: {
|
|
19
|
+
type: Boolean,
|
|
20
|
+
default: !1
|
|
21
|
+
},
|
|
22
|
+
interactive: {
|
|
23
|
+
type: Boolean,
|
|
24
|
+
default: !1
|
|
25
|
+
},
|
|
26
|
+
primary: {},
|
|
27
|
+
role: { default: "button" },
|
|
28
|
+
secondary: {},
|
|
29
|
+
selected: {
|
|
30
|
+
type: Boolean,
|
|
31
|
+
default: !1
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
setup(l) {
|
|
35
|
+
let y = _(), b = l, { merged: x, hasEnd: S, endBind: C, rootBind: w, rowClass: T, hasStart: E, startBind: D, hasPrimary: O, contentBind: k, primaryBind: A, hasSecondary: j, secondaryBind: M, interactiveBind: N } = r(b, {
|
|
36
|
+
role: "button",
|
|
37
|
+
align: "center"
|
|
38
|
+
}, y), P = i(() => x.value.as ?? "li"), F = i(() => n(y, b.primary)), I = i(() => t(y, "secondary", b.secondary));
|
|
39
|
+
return (t, n) => (m(), a(h(P.value), p(u(g(w))), {
|
|
40
|
+
default: v(() => [g(N) ? (m(), s("div", p(d({ key: 0 }, g(N))), [c("div", { class: f(g(T)) }, [
|
|
41
|
+
g(E) ? (m(), s("div", p(d({ key: 0 }, g(D))), [(m(), a(h(g(e)(g(y), "start"))))], 16)) : o("", !0),
|
|
42
|
+
c("div", p(u(g(k))), [g(O) ? (m(), s("span", p(d({ key: 0 }, g(A))), [(m(), a(h(F.value)))], 16)) : o("", !0), g(j) ? (m(), s("span", p(d({ key: 1 }, g(M))), [(m(), a(h(I.value)))], 16)) : o("", !0)], 16),
|
|
43
|
+
g(S) ? (m(), s("div", p(d({ key: 1 }, g(C))), [(m(), a(h(g(e)(g(y), "end"))))], 16)) : o("", !0)
|
|
44
|
+
], 2)], 16)) : (m(), s("div", {
|
|
45
|
+
key: 1,
|
|
46
|
+
class: f(g(T))
|
|
47
|
+
}, [
|
|
48
|
+
g(E) ? (m(), s("div", p(d({ key: 0 }, g(D))), [(m(), a(h(g(e)(g(y), "start"))))], 16)) : o("", !0),
|
|
49
|
+
c("div", p(u(g(k))), [g(O) ? (m(), s("span", p(d({ key: 0 }, g(A))), [(m(), a(h(F.value)))], 16)) : o("", !0), g(j) ? (m(), s("span", p(d({ key: 1 }, g(M))), [(m(), a(h(I.value)))], 16)) : o("", !0)], 16),
|
|
50
|
+
g(S) ? (m(), s("div", p(d({ key: 1 }, g(C))), [(m(), a(h(g(e)(g(y), "end"))))], 16)) : o("", !0)
|
|
51
|
+
], 2))]),
|
|
52
|
+
_: 1
|
|
53
|
+
}, 16));
|
|
54
|
+
}
|
|
55
|
+
});
|
|
56
|
+
//#endregion
|
|
57
|
+
export { y as default };
|