@marwes-ui/vue 1.1.0 → 1.3.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/README.md +4 -2
- package/dist/index.d.ts +48 -12
- package/dist/index.js +331 -15
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { createMarwesThemeScript, createMarwesThemeStyle } from './chunk-DVJD5CQS.js';
|
|
2
2
|
import '@marwes-ui/presets/firstEdition/styles.css';
|
|
3
|
-
import { ThemeMode, resolveThemePreference, resolveThemeInput, resolveIconSize, resolveIconStrokeWidth, iconRegistry, resolveIconA11y, createSpinnerRecipe, createButtonRecipe, ButtonAction, ButtonVariant, IconName, createInputRecipe, createSelectRecipe, resolveSelectMode, createTextareaRecipe, createRichTextRecipe, resolveRichTextAllowedFormats, normalizeRichTextHtml, isRichTextHtmlEmpty, paragraphRecipe, buildInputFieldA11yIds, sanitizeInputOtpValue, createInputOtpRecipe, buildRichTextFieldA11yIds, buildCurrencyHelperText, getCurrencySymbol, sanitizeCurrencyValue, createAvatarRecipe, createPurposeSemanticAttributes, checkboxRecipe, buildCheckboxFieldA11yIds, buildCheckboxGroupFieldA11yIds, createDividerRecipe, createSpacingRecipe, createCardRecipe, createToastRecipe, createTooltipRecipe, createAccordionRecipe, buildAccordionFieldA11yIds, radioRecipe, buildRadioGroupFieldA11yIds, createBadgeRecipe, createSwitchRecipe, buildSwitchFieldA11yIds, createSliderRecipe, buildSliderFieldA11yIds, createTabRecipe, resolveTabValue, buildTabGroupA11yIds, createDialogRecipe, isThemePreference, nextThemeMode, themeToCSSVars, richTextCommandByFormat, headingRecipe, moveTabSelection, extractUsedWeights, extractFontFamilyName, shouldLoadGoogleFont, buildGoogleFontsUrl } from '@marwes-ui/core';
|
|
3
|
+
import { ThemeMode, resolveThemePreference, resolveThemeInput, resolveIconSize, resolveIconStrokeWidth, iconRegistry, resolveIconA11y, createSpinnerRecipe, createButtonRecipe, ButtonAction, ButtonVariant, IconName, createInputRecipe, createSelectRecipe, resolveSelectMode, createTextareaRecipe, createRichTextRecipe, resolveRichTextAllowedFormats, normalizeRichTextHtml, isRichTextHtmlEmpty, paragraphRecipe, buildInputFieldA11yIds, sanitizeInputOtpValue, createInputOtpRecipe, buildRichTextFieldA11yIds, buildCurrencyHelperText, getCurrencySymbol, sanitizeCurrencyValue, createAvatarRecipe, createPurposeSemanticAttributes, checkboxRecipe, buildCheckboxFieldA11yIds, buildCheckboxGroupFieldA11yIds, createDividerRecipe, createSkeletonRecipe, createSpacingRecipe, createStatTileRecipe, createDatePickerRecipe, createCardRecipe, createToastRecipe, createTooltipRecipe, createAccordionRecipe, buildAccordionFieldA11yIds, radioRecipe, buildRadioGroupFieldA11yIds, createBadgeRecipe, createSwitchRecipe, buildSwitchFieldA11yIds, createSliderRecipe, buildSliderFieldA11yIds, createTabRecipe, resolveTabValue, buildTabGroupA11yIds, createDialogRecipe, isThemePreference, nextThemeMode, themeToCSSVars, richTextCommandByFormat, headingRecipe, moveTabSelection, extractUsedWeights, extractFontFamilyName, shouldLoadGoogleFont, buildGoogleFontsUrl } from '@marwes-ui/core';
|
|
4
4
|
export { AvatarSize, AvatarType, BadgeVariant, ButtonAction, ButtonSize, ButtonVariant, IconName, Spacings, SwitchSize, ThemeMode, createFontStack, mwAvailableFonts, mwFontFallbacks, mwGoogleFontFamilies, mwStyledTheme, mwThemeVarNames, mwThemeVars, mwVar } from '@marwes-ui/core';
|
|
5
5
|
import { defineComponent, ref, computed, onMounted, onUnmounted, watch, provide, h, useAttrs, onBeforeUnmount, shallowRef, Fragment, nextTick, Teleport, inject } from 'vue';
|
|
6
6
|
|
|
@@ -2277,7 +2277,8 @@ var selectFieldPropKeys = [
|
|
|
2277
2277
|
"error",
|
|
2278
2278
|
"select",
|
|
2279
2279
|
"ariaDescribedBy",
|
|
2280
|
-
"modelValue"
|
|
2280
|
+
"modelValue",
|
|
2281
|
+
"variant"
|
|
2281
2282
|
];
|
|
2282
2283
|
function hasTextContent3(value) {
|
|
2283
2284
|
return value !== void 0 && value.trim().length > 0;
|
|
@@ -2375,11 +2376,15 @@ var SelectField = defineComponent(
|
|
|
2375
2376
|
const displayText = computed(
|
|
2376
2377
|
() => placeholderSelected.value ? sourceSelect.value.placeholder ?? "" : selectedOption.value?.label ?? ""
|
|
2377
2378
|
);
|
|
2379
|
+
const accessibleName = computed(
|
|
2380
|
+
() => sourceSelect.value.ariaLabel ?? (hasTextContent3(props.label) ? props.label : void 0) ?? (hasTextContent3(displayText.value) ? displayText.value : void 0)
|
|
2381
|
+
);
|
|
2378
2382
|
const wrapperClass = computed(
|
|
2379
2383
|
() => mergeClassNames(
|
|
2380
2384
|
"mw-input-field",
|
|
2381
2385
|
"mw-input-field--select",
|
|
2382
2386
|
mode.value === "marwes" && "mw-input-field--select-marwes",
|
|
2387
|
+
props.variant === "date" && "mw-input-field--select-date",
|
|
2383
2388
|
disabled.value && "mw-input-field--disabled",
|
|
2384
2389
|
invalid.value && "mw-input-field--invalid"
|
|
2385
2390
|
)
|
|
@@ -2576,6 +2581,7 @@ var SelectField = defineComponent(
|
|
|
2576
2581
|
"aria-controls": `${id.value}-listbox`,
|
|
2577
2582
|
"aria-expanded": open.value ? "true" : "false",
|
|
2578
2583
|
"aria-haspopup": "listbox",
|
|
2584
|
+
"aria-label": accessibleName.value,
|
|
2579
2585
|
"aria-describedby": a11yIds.value.describedBy,
|
|
2580
2586
|
"aria-invalid": invalid.value ? "true" : void 0,
|
|
2581
2587
|
"aria-required": sourceSelect.value.required ? "true" : void 0,
|
|
@@ -2908,9 +2914,9 @@ var SearchField = defineComponent({
|
|
|
2908
2914
|
inheritAttrs: false,
|
|
2909
2915
|
props: [...fieldPropKeys],
|
|
2910
2916
|
emits: ["update:modelValue", "value-change"],
|
|
2911
|
-
setup(
|
|
2917
|
+
setup(rawProps, { slots, emit }) {
|
|
2912
2918
|
return () => {
|
|
2913
|
-
const props =
|
|
2919
|
+
const props = rawProps;
|
|
2914
2920
|
return h("div", { "data-purpose": "search" }, [
|
|
2915
2921
|
h(
|
|
2916
2922
|
InputField,
|
|
@@ -2936,9 +2942,9 @@ var PasswordField = defineComponent({
|
|
|
2936
2942
|
inheritAttrs: false,
|
|
2937
2943
|
props: [...passwordFieldPropKeys],
|
|
2938
2944
|
emits: ["update:modelValue", "value-change"],
|
|
2939
|
-
setup(
|
|
2945
|
+
setup(rawProps, { slots, emit }) {
|
|
2940
2946
|
return () => {
|
|
2941
|
-
const props =
|
|
2947
|
+
const props = rawProps;
|
|
2942
2948
|
const autoComplete = props.autoComplete ?? "current-password";
|
|
2943
2949
|
return h("div", { "data-purpose": "password" }, [
|
|
2944
2950
|
h(
|
|
@@ -2964,9 +2970,9 @@ var EmailField = defineComponent({
|
|
|
2964
2970
|
inheritAttrs: false,
|
|
2965
2971
|
props: [...fieldPropKeys],
|
|
2966
2972
|
emits: ["update:modelValue", "value-change"],
|
|
2967
|
-
setup(
|
|
2973
|
+
setup(rawProps, { slots, emit }) {
|
|
2968
2974
|
return () => {
|
|
2969
|
-
const props =
|
|
2975
|
+
const props = rawProps;
|
|
2970
2976
|
return h("div", { "data-purpose": "email" }, [
|
|
2971
2977
|
h(
|
|
2972
2978
|
InputField,
|
|
@@ -3047,9 +3053,9 @@ var PhoneField = defineComponent({
|
|
|
3047
3053
|
inheritAttrs: false,
|
|
3048
3054
|
props: [...fieldPropKeys],
|
|
3049
3055
|
emits: ["update:modelValue", "value-change"],
|
|
3050
|
-
setup(
|
|
3056
|
+
setup(rawProps, { slots, emit }) {
|
|
3051
3057
|
return () => {
|
|
3052
|
-
const props =
|
|
3058
|
+
const props = rawProps;
|
|
3053
3059
|
return h("div", { "data-purpose": "phone" }, [
|
|
3054
3060
|
h(
|
|
3055
3061
|
InputField,
|
|
@@ -3075,9 +3081,9 @@ var URLField = defineComponent({
|
|
|
3075
3081
|
inheritAttrs: false,
|
|
3076
3082
|
props: [...fieldPropKeys],
|
|
3077
3083
|
emits: ["update:modelValue", "value-change"],
|
|
3078
|
-
setup(
|
|
3084
|
+
setup(rawProps, { slots, emit }) {
|
|
3079
3085
|
return () => {
|
|
3080
|
-
const props =
|
|
3086
|
+
const props = rawProps;
|
|
3081
3087
|
return h("div", { "data-purpose": "url" }, [
|
|
3082
3088
|
h(
|
|
3083
3089
|
InputField,
|
|
@@ -3811,6 +3817,61 @@ var Divider = defineComponent(
|
|
|
3811
3817
|
props: [...dividerPropKeys]
|
|
3812
3818
|
}
|
|
3813
3819
|
);
|
|
3820
|
+
var skeletonPropKeys = [
|
|
3821
|
+
"variant",
|
|
3822
|
+
"width",
|
|
3823
|
+
"height",
|
|
3824
|
+
"radius",
|
|
3825
|
+
"animation",
|
|
3826
|
+
"decorative",
|
|
3827
|
+
"ariaLabel",
|
|
3828
|
+
"id",
|
|
3829
|
+
"className",
|
|
3830
|
+
"dataAttributes"
|
|
3831
|
+
];
|
|
3832
|
+
var Skeleton = defineComponent(
|
|
3833
|
+
(props) => {
|
|
3834
|
+
const attrs = useAttrs();
|
|
3835
|
+
const ariaLabelFromAttrs = typeof attrs["aria-label"] === "string" ? attrs["aria-label"] : void 0;
|
|
3836
|
+
const renderKit = computed(
|
|
3837
|
+
() => createSkeletonRecipe({
|
|
3838
|
+
...props.variant !== void 0 ? { variant: props.variant } : {},
|
|
3839
|
+
...props.width !== void 0 ? { width: props.width } : {},
|
|
3840
|
+
...props.height !== void 0 ? { height: props.height } : {},
|
|
3841
|
+
...props.radius !== void 0 ? { radius: props.radius } : {},
|
|
3842
|
+
...props.animation !== void 0 ? { animation: props.animation } : {},
|
|
3843
|
+
...props.decorative !== void 0 ? { decorative: props.decorative } : {},
|
|
3844
|
+
...props.id !== void 0 ? { id: props.id } : {},
|
|
3845
|
+
...props.ariaLabel !== void 0 ? { ariaLabel: props.ariaLabel } : ariaLabelFromAttrs !== void 0 ? { ariaLabel: ariaLabelFromAttrs } : {}
|
|
3846
|
+
})
|
|
3847
|
+
);
|
|
3848
|
+
return () => {
|
|
3849
|
+
const skeletonRenderKit = renderKit.value;
|
|
3850
|
+
const passthroughAttrs = omitAttrs(attrs, [
|
|
3851
|
+
"class",
|
|
3852
|
+
"style",
|
|
3853
|
+
"aria-label"
|
|
3854
|
+
]);
|
|
3855
|
+
return h("span", {
|
|
3856
|
+
...passthroughAttrs,
|
|
3857
|
+
...skeletonRenderKit.dataAttributes,
|
|
3858
|
+
...props.dataAttributes ?? {},
|
|
3859
|
+
class: mergeClassNames(skeletonRenderKit.className, props.className, attrs.class),
|
|
3860
|
+
style: mergeStyles(skeletonRenderKit.vars, attrs.style),
|
|
3861
|
+
role: skeletonRenderKit.a11y.role,
|
|
3862
|
+
id: skeletonRenderKit.a11y.id,
|
|
3863
|
+
"aria-hidden": skeletonRenderKit.a11y.ariaHidden ? "true" : void 0,
|
|
3864
|
+
"aria-label": skeletonRenderKit.a11y.ariaLabel,
|
|
3865
|
+
"aria-live": skeletonRenderKit.a11y.ariaLive
|
|
3866
|
+
});
|
|
3867
|
+
};
|
|
3868
|
+
},
|
|
3869
|
+
{
|
|
3870
|
+
name: "MarwesSkeleton",
|
|
3871
|
+
inheritAttrs: false,
|
|
3872
|
+
props: [...skeletonPropKeys]
|
|
3873
|
+
}
|
|
3874
|
+
);
|
|
3814
3875
|
var spacingPropKeys = ["size", "spacing", "scale", "className"];
|
|
3815
3876
|
var Spacing = defineComponent(
|
|
3816
3877
|
(props) => {
|
|
@@ -3881,6 +3942,261 @@ function createHeadingComponent(level) {
|
|
|
3881
3942
|
var H1 = createHeadingComponent(1);
|
|
3882
3943
|
var H2 = createHeadingComponent(2);
|
|
3883
3944
|
var H3 = createHeadingComponent(3);
|
|
3945
|
+
var statTilePropKeys = [
|
|
3946
|
+
"className",
|
|
3947
|
+
"label",
|
|
3948
|
+
"value",
|
|
3949
|
+
"subtitle",
|
|
3950
|
+
"trendValue",
|
|
3951
|
+
"trendDirection",
|
|
3952
|
+
"tone",
|
|
3953
|
+
"dataAttributes"
|
|
3954
|
+
];
|
|
3955
|
+
var StatTile = defineComponent(
|
|
3956
|
+
(props) => {
|
|
3957
|
+
const attrs = useAttrs();
|
|
3958
|
+
const renderKit = computed(
|
|
3959
|
+
() => createStatTileRecipe({
|
|
3960
|
+
...props.tone !== void 0 ? { tone: props.tone } : {},
|
|
3961
|
+
...props.trendDirection !== void 0 ? { trendDirection: props.trendDirection } : {},
|
|
3962
|
+
...props.trendValue !== void 0 ? { trendValue: props.trendValue } : {},
|
|
3963
|
+
...props.dataAttributes !== void 0 ? { dataAttributes: props.dataAttributes } : {}
|
|
3964
|
+
})
|
|
3965
|
+
);
|
|
3966
|
+
return () => {
|
|
3967
|
+
const kit = renderKit.value;
|
|
3968
|
+
const passthroughAttrs = omitAttrs(attrs, ["class", "style"]);
|
|
3969
|
+
return h(
|
|
3970
|
+
"article",
|
|
3971
|
+
{
|
|
3972
|
+
...passthroughAttrs,
|
|
3973
|
+
...kit.dataAttributes,
|
|
3974
|
+
class: mergeClassNames(kit.className, props.className, attrs.class)
|
|
3975
|
+
},
|
|
3976
|
+
[
|
|
3977
|
+
h(
|
|
3978
|
+
"div",
|
|
3979
|
+
{ class: kit.slots.headerClassName },
|
|
3980
|
+
[
|
|
3981
|
+
h("span", { class: kit.slots.labelClassName }, props.label),
|
|
3982
|
+
props.trendValue ? h(
|
|
3983
|
+
"span",
|
|
3984
|
+
{
|
|
3985
|
+
...kit.trendDataAttributes,
|
|
3986
|
+
class: kit.slots.trendClassName,
|
|
3987
|
+
"aria-label": kit.a11y.trendAriaLabel
|
|
3988
|
+
},
|
|
3989
|
+
[
|
|
3990
|
+
kit.trendIcon ? h(
|
|
3991
|
+
"span",
|
|
3992
|
+
{ class: kit.slots.trendIconClassName, "aria-hidden": "true" },
|
|
3993
|
+
kit.trendIcon
|
|
3994
|
+
) : null,
|
|
3995
|
+
h("span", { class: kit.slots.trendValueClassName }, props.trendValue)
|
|
3996
|
+
].filter(Boolean)
|
|
3997
|
+
) : null
|
|
3998
|
+
].filter(Boolean)
|
|
3999
|
+
),
|
|
4000
|
+
h("div", { class: kit.slots.valueClassName }, props.value),
|
|
4001
|
+
props.subtitle ? h("div", { class: kit.slots.subtitleClassName }, props.subtitle) : null
|
|
4002
|
+
].filter(Boolean)
|
|
4003
|
+
);
|
|
4004
|
+
};
|
|
4005
|
+
},
|
|
4006
|
+
{
|
|
4007
|
+
name: "MarwesStatTile",
|
|
4008
|
+
inheritAttrs: false,
|
|
4009
|
+
props: [...statTilePropKeys]
|
|
4010
|
+
}
|
|
4011
|
+
);
|
|
4012
|
+
var datePickerPropKeys = [
|
|
4013
|
+
"className",
|
|
4014
|
+
"monthLabel",
|
|
4015
|
+
"weekdayLabels",
|
|
4016
|
+
"weeks",
|
|
4017
|
+
"device",
|
|
4018
|
+
"previousYearLabel",
|
|
4019
|
+
"previousMonthLabel",
|
|
4020
|
+
"nextMonthLabel",
|
|
4021
|
+
"nextYearLabel",
|
|
4022
|
+
"cancelLabel",
|
|
4023
|
+
"applyLabel",
|
|
4024
|
+
"calendarLabel",
|
|
4025
|
+
"dataAttributes"
|
|
4026
|
+
];
|
|
4027
|
+
var DatePicker = defineComponent(
|
|
4028
|
+
(props, { emit }) => {
|
|
4029
|
+
const attrs = useAttrs();
|
|
4030
|
+
const renderKit = computed(
|
|
4031
|
+
() => createDatePickerRecipe({
|
|
4032
|
+
...props.monthLabel !== void 0 ? { monthLabel: props.monthLabel } : {},
|
|
4033
|
+
...props.weekdayLabels !== void 0 ? { weekdayLabels: props.weekdayLabels } : {},
|
|
4034
|
+
...props.weeks !== void 0 ? { weeks: props.weeks } : {},
|
|
4035
|
+
...props.device !== void 0 ? { device: props.device } : {},
|
|
4036
|
+
...props.previousYearLabel !== void 0 ? { previousYearLabel: props.previousYearLabel } : {},
|
|
4037
|
+
...props.previousMonthLabel !== void 0 ? { previousMonthLabel: props.previousMonthLabel } : {},
|
|
4038
|
+
...props.nextMonthLabel !== void 0 ? { nextMonthLabel: props.nextMonthLabel } : {},
|
|
4039
|
+
...props.nextYearLabel !== void 0 ? { nextYearLabel: props.nextYearLabel } : {},
|
|
4040
|
+
...props.cancelLabel !== void 0 ? { cancelLabel: props.cancelLabel } : {},
|
|
4041
|
+
...props.applyLabel !== void 0 ? { applyLabel: props.applyLabel } : {},
|
|
4042
|
+
...props.calendarLabel !== void 0 ? { calendarLabel: props.calendarLabel } : {},
|
|
4043
|
+
...props.dataAttributes !== void 0 ? { dataAttributes: props.dataAttributes } : {}
|
|
4044
|
+
})
|
|
4045
|
+
);
|
|
4046
|
+
return () => {
|
|
4047
|
+
const kit = renderKit.value;
|
|
4048
|
+
const passthroughAttrs = omitAttrs(attrs, ["class", "style"]);
|
|
4049
|
+
return h(
|
|
4050
|
+
"section",
|
|
4051
|
+
{
|
|
4052
|
+
...passthroughAttrs,
|
|
4053
|
+
...kit.dataAttributes,
|
|
4054
|
+
class: mergeClassNames(kit.className, props.className, attrs.class),
|
|
4055
|
+
"aria-label": kit.labels.calendar
|
|
4056
|
+
},
|
|
4057
|
+
[
|
|
4058
|
+
h("header", { class: kit.slots.headerClassName }, [
|
|
4059
|
+
h("div", { class: kit.slots.navGroupClassName }, [
|
|
4060
|
+
h(
|
|
4061
|
+
"button",
|
|
4062
|
+
{
|
|
4063
|
+
type: "button",
|
|
4064
|
+
class: kit.slots.navButtonClassName,
|
|
4065
|
+
"aria-label": kit.labels.previousYear,
|
|
4066
|
+
onClick: () => emit("previousYear")
|
|
4067
|
+
},
|
|
4068
|
+
"\xAB"
|
|
4069
|
+
),
|
|
4070
|
+
h(
|
|
4071
|
+
"button",
|
|
4072
|
+
{
|
|
4073
|
+
type: "button",
|
|
4074
|
+
class: kit.slots.navButtonClassName,
|
|
4075
|
+
"aria-label": kit.labels.previousMonth,
|
|
4076
|
+
onClick: () => emit("previousMonth")
|
|
4077
|
+
},
|
|
4078
|
+
"\u2039"
|
|
4079
|
+
)
|
|
4080
|
+
]),
|
|
4081
|
+
h("div", { class: kit.slots.monthLabelClassName }, kit.monthLabel),
|
|
4082
|
+
h("div", { class: kit.slots.navGroupClassName }, [
|
|
4083
|
+
h(
|
|
4084
|
+
"button",
|
|
4085
|
+
{
|
|
4086
|
+
type: "button",
|
|
4087
|
+
class: kit.slots.navButtonClassName,
|
|
4088
|
+
"aria-label": kit.labels.nextMonth,
|
|
4089
|
+
onClick: () => emit("nextMonth")
|
|
4090
|
+
},
|
|
4091
|
+
"\u203A"
|
|
4092
|
+
),
|
|
4093
|
+
h(
|
|
4094
|
+
"button",
|
|
4095
|
+
{
|
|
4096
|
+
type: "button",
|
|
4097
|
+
class: kit.slots.navButtonClassName,
|
|
4098
|
+
"aria-label": kit.labels.nextYear,
|
|
4099
|
+
onClick: () => emit("nextYear")
|
|
4100
|
+
},
|
|
4101
|
+
"\xBB"
|
|
4102
|
+
)
|
|
4103
|
+
])
|
|
4104
|
+
]),
|
|
4105
|
+
h("table", { class: kit.slots.gridClassName, "aria-label": kit.monthLabel }, [
|
|
4106
|
+
h("thead", [
|
|
4107
|
+
h(
|
|
4108
|
+
"tr",
|
|
4109
|
+
{ class: "mw-date-picker__weekdays" },
|
|
4110
|
+
kit.weekdayLabels.map(
|
|
4111
|
+
(weekday) => h(
|
|
4112
|
+
"th",
|
|
4113
|
+
{ key: weekday, class: kit.slots.weekdayClassName, scope: "col" },
|
|
4114
|
+
weekday
|
|
4115
|
+
)
|
|
4116
|
+
)
|
|
4117
|
+
)
|
|
4118
|
+
]),
|
|
4119
|
+
h(
|
|
4120
|
+
"tbody",
|
|
4121
|
+
kit.weeks.map(
|
|
4122
|
+
(week, weekIndex) => h(
|
|
4123
|
+
"tr",
|
|
4124
|
+
{
|
|
4125
|
+
key: week.map((day) => day.date ?? day.label).join("-"),
|
|
4126
|
+
class: kit.slots.weekClassName
|
|
4127
|
+
},
|
|
4128
|
+
week.map((day, dayIndex) => {
|
|
4129
|
+
const dayKit = kit.dayKits[weekIndex]?.[dayIndex];
|
|
4130
|
+
if (!dayKit) return null;
|
|
4131
|
+
return h(
|
|
4132
|
+
"td",
|
|
4133
|
+
{
|
|
4134
|
+
key: day.date ?? `${weekIndex}-${dayIndex}`,
|
|
4135
|
+
class: kit.slots.cellClassName
|
|
4136
|
+
},
|
|
4137
|
+
[
|
|
4138
|
+
h(
|
|
4139
|
+
"button",
|
|
4140
|
+
{
|
|
4141
|
+
type: "button",
|
|
4142
|
+
...dayKit.dataAttributes,
|
|
4143
|
+
class: dayKit.className,
|
|
4144
|
+
"aria-label": dayKit.ariaLabel,
|
|
4145
|
+
"aria-pressed": dayKit.selected ? "true" : void 0,
|
|
4146
|
+
disabled: dayKit.disabled,
|
|
4147
|
+
onClick: () => emit("daySelect", day)
|
|
4148
|
+
},
|
|
4149
|
+
day.label
|
|
4150
|
+
)
|
|
4151
|
+
]
|
|
4152
|
+
);
|
|
4153
|
+
})
|
|
4154
|
+
)
|
|
4155
|
+
)
|
|
4156
|
+
)
|
|
4157
|
+
]),
|
|
4158
|
+
h("footer", { class: kit.slots.footerClassName }, [
|
|
4159
|
+
h(
|
|
4160
|
+
"button",
|
|
4161
|
+
{
|
|
4162
|
+
type: "button",
|
|
4163
|
+
class: kit.slots.footerButtonClassName,
|
|
4164
|
+
onClick: () => emit("cancel")
|
|
4165
|
+
},
|
|
4166
|
+
kit.labels.cancel
|
|
4167
|
+
),
|
|
4168
|
+
kit.labels.apply ? h(
|
|
4169
|
+
"button",
|
|
4170
|
+
{
|
|
4171
|
+
type: "button",
|
|
4172
|
+
class: mergeClassNames(
|
|
4173
|
+
kit.slots.footerButtonClassName,
|
|
4174
|
+
"mw-date-picker__footer-button--primary"
|
|
4175
|
+
),
|
|
4176
|
+
onClick: () => emit("apply")
|
|
4177
|
+
},
|
|
4178
|
+
kit.labels.apply
|
|
4179
|
+
) : null
|
|
4180
|
+
])
|
|
4181
|
+
]
|
|
4182
|
+
);
|
|
4183
|
+
};
|
|
4184
|
+
},
|
|
4185
|
+
{
|
|
4186
|
+
name: "MarwesDatePicker",
|
|
4187
|
+
inheritAttrs: false,
|
|
4188
|
+
props: [...datePickerPropKeys],
|
|
4189
|
+
emits: [
|
|
4190
|
+
"previousYear",
|
|
4191
|
+
"previousMonth",
|
|
4192
|
+
"nextMonth",
|
|
4193
|
+
"nextYear",
|
|
4194
|
+
"daySelect",
|
|
4195
|
+
"cancel",
|
|
4196
|
+
"apply"
|
|
4197
|
+
]
|
|
4198
|
+
}
|
|
4199
|
+
);
|
|
3884
4200
|
var cardPropKeys = ["className", "id", "dataAttributes"];
|
|
3885
4201
|
var Card = defineComponent(
|
|
3886
4202
|
(props, { slots }) => {
|
|
@@ -4883,7 +5199,7 @@ var RadioGroupField = defineComponent(
|
|
|
4883
5199
|
},
|
|
4884
5200
|
[
|
|
4885
5201
|
h("div", { class: "mw-radio-group-field__label", id: a11yIds.value.labelId }, [
|
|
4886
|
-
h(Paragraph, { size: "
|
|
5202
|
+
h(Paragraph, { size: "sm" }, { default: labelContent })
|
|
4887
5203
|
]),
|
|
4888
5204
|
hasDescription.value ? h(
|
|
4889
5205
|
"div",
|
|
@@ -6434,7 +6750,7 @@ var DialogModal = defineComponent(
|
|
|
6434
6750
|
);
|
|
6435
6751
|
const footerContent = computed(() => {
|
|
6436
6752
|
if (slots.footer) {
|
|
6437
|
-
return slots.footer();
|
|
6753
|
+
return slots.footer({ close });
|
|
6438
6754
|
}
|
|
6439
6755
|
if (typeof props.footer === "function") {
|
|
6440
6756
|
return props.footer({ close });
|
|
@@ -6718,6 +7034,6 @@ var InfoDialog = defineComponent({
|
|
|
6718
7034
|
}
|
|
6719
7035
|
});
|
|
6720
7036
|
|
|
6721
|
-
export { Accordion, AccordionField, Avatar, AvatarBadge, AvatarGroup, Badge, BadgeGroup, BrightnessSlider, Button, ButtonSpinner, CancelButton, Card, Checkbox, CheckboxField, CheckboxGroupField, CloseButton, ConfirmButton, ConfirmDialog, ContentTabs, CopyButton, CreateButton, CurrencyField, DateOfBirthField, DestructiveButton, DestructiveDialog, Dialog, DialogModal, Divider, DownloadButton, DropdownButton, DropdownField, EditButton, EmailField, EmptyStateSpinner, ErrorToast, FAQAccordion, FeatureToggle, FilterButton, H1, H2, H3, Icon, InfoDialog, InfoToast, Input, InputField, InputOtp, LinkButton, MarwesProvider, NavigationTabs, NotificationBadge, OptionRadioGroup, Paragraph, PasswordField, PermissionSwitch, PhoneField, PreferenceSwitch, PresenceAvatar, PrimaryButton, PriorityBadge, ProductCard, ProfileAvatar, ProfileCard, Radio, RadioGroupField, RadiusSlider, RatingRadioGroup, RefreshButton, RichText, RichTextField, SaveButton, SearchButton, SearchField, SecondaryButton, SectionsAccordion, Select, SelectField, SettingsAccordion, SettingsTabs, Slider, SliderField, SortButton, Spacer, Spacing, Spinner, StatCard, StatusBadge, SubmitButton, SuccessButton, SuccessToast, Switch, SwitchField, Tab, TabGroup, TabPanel, TeamAvatarGroup, TextButton, Textarea, TextareaField, Toast, ToastContainer, ToastProvider, Tooltip, TooltipGroup, URLField, UploadButton, VerifyButton, VolumeSlider, WarningToast, YesNoRadioGroup, ZipCodeField, createHeadingComponent, useTheme, useThemeMode, useToast };
|
|
7037
|
+
export { Accordion, AccordionField, Avatar, AvatarBadge, AvatarGroup, Badge, BadgeGroup, BrightnessSlider, Button, ButtonSpinner, CancelButton, Card, Checkbox, CheckboxField, CheckboxGroupField, CloseButton, ConfirmButton, ConfirmDialog, ContentTabs, CopyButton, CreateButton, CurrencyField, DateOfBirthField, DatePicker, DestructiveButton, DestructiveDialog, Dialog, DialogModal, Divider, DownloadButton, DropdownButton, DropdownField, EditButton, EmailField, EmptyStateSpinner, ErrorToast, FAQAccordion, FeatureToggle, FilterButton, H1, H2, H3, Icon, InfoDialog, InfoToast, Input, InputField, InputOtp, LinkButton, MarwesProvider, NavigationTabs, NotificationBadge, OptionRadioGroup, Paragraph, PasswordField, PermissionSwitch, PhoneField, PreferenceSwitch, PresenceAvatar, PrimaryButton, PriorityBadge, ProductCard, ProfileAvatar, ProfileCard, Radio, RadioGroupField, RadiusSlider, RatingRadioGroup, RefreshButton, RichText, RichTextField, SaveButton, SearchButton, SearchField, SecondaryButton, SectionsAccordion, Select, SelectField, SettingsAccordion, SettingsTabs, Skeleton, Slider, SliderField, SortButton, Spacer, Spacing, Spinner, StatCard, StatTile, StatusBadge, SubmitButton, SuccessButton, SuccessToast, Switch, SwitchField, Tab, TabGroup, TabPanel, TeamAvatarGroup, TextButton, Textarea, TextareaField, Toast, ToastContainer, ToastProvider, Tooltip, TooltipGroup, URLField, UploadButton, VerifyButton, VolumeSlider, WarningToast, YesNoRadioGroup, ZipCodeField, createHeadingComponent, useTheme, useThemeMode, useToast };
|
|
6722
7038
|
//# sourceMappingURL=index.js.map
|
|
6723
7039
|
//# sourceMappingURL=index.js.map
|