@frollo/frollo-web-ui 8.4.1 → 8.4.3
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/cjs/index.js +63 -24
- package/esm/{fw-button-LhSQ6Fx_.js → fw-button-NJeYig99.js} +25 -5
- package/esm/fw-button.js +1 -1
- package/esm/fw-drawer.js +1 -1
- package/esm/{fw-input-BPFFMpc2.js → fw-input-XeI-IKly.js} +18 -4
- package/esm/fw-input.js +1 -1
- package/esm/fw-media-picker.js +1 -1
- package/esm/fw-modal.js +1 -1
- package/esm/fw-navigation-menu.js +1 -1
- package/esm/fw-period-selector.js +15 -10
- package/esm/fw-provider-list.js +4 -4
- package/esm/fw-sidebar-menu.js +1 -1
- package/esm/{fw-table-row-suFSeIN3.js → fw-table-row-D2KYRG5K.js} +1 -1
- package/esm/fw-table.js +2 -2
- package/esm/{fw-tag-CziUTbtg.js → fw-tag-D-U6RKuG.js} +1 -1
- package/esm/fw-tag.js +2 -2
- package/esm/index.js +4 -4
- package/frollo-web-ui.esm.js +62 -23
- package/index.d.ts +47 -2
- package/package.json +1 -1
- package/styles/tailwind.scss +3 -0
- package/tailwind.config.js +4 -0
- package/types/components/fw-button/fw-button.vue.d.ts +30 -0
- package/types/components/fw-button/index.types.d.ts +3 -1
- package/types/components/fw-input/fw-input.vue.d.ts +5 -1
- package/types/components/fw-period-selector/fw-period-selector.vue.d.ts +9 -0
- package/web-components/index.js +64 -25
package/frollo-web-ui.esm.js
CHANGED
|
@@ -6913,7 +6913,7 @@ function uniqueId(prefix) {
|
|
|
6913
6913
|
|
|
6914
6914
|
var script$o = defineComponent({
|
|
6915
6915
|
name: 'FwInput',
|
|
6916
|
-
emits: ['update:modelValue'],
|
|
6916
|
+
emits: ['update:modelValue', 'focus', 'blur'],
|
|
6917
6917
|
components: {
|
|
6918
6918
|
InputField: Field
|
|
6919
6919
|
},
|
|
@@ -7033,10 +7033,18 @@ var script$o = defineComponent({
|
|
|
7033
7033
|
return ctx.emit('update:modelValue', state);
|
|
7034
7034
|
}
|
|
7035
7035
|
});
|
|
7036
|
+
var onFocus = function onFocus(e) {
|
|
7037
|
+
return ctx.emit('focus', e);
|
|
7038
|
+
};
|
|
7039
|
+
var onBlur = function onBlur(e) {
|
|
7040
|
+
return ctx.emit('blur', e);
|
|
7041
|
+
};
|
|
7036
7042
|
return {
|
|
7037
7043
|
uuid: uuid,
|
|
7038
7044
|
inputBaseClass: inputBaseClass,
|
|
7039
|
-
inputValue: inputValue
|
|
7045
|
+
inputValue: inputValue,
|
|
7046
|
+
onFocus: onFocus,
|
|
7047
|
+
onBlur: onBlur
|
|
7040
7048
|
};
|
|
7041
7049
|
}
|
|
7042
7050
|
});
|
|
@@ -7081,7 +7089,7 @@ function render$1d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
7081
7089
|
var _component_InputField = resolveComponent("InputField");
|
|
7082
7090
|
return openBlock(), createElementBlock("div", _hoisted_1$1j, [createVNode(_component_InputField, {
|
|
7083
7091
|
modelValue: _ctx.inputValue,
|
|
7084
|
-
"onUpdate:modelValue": _cache[
|
|
7092
|
+
"onUpdate:modelValue": _cache[2] || (_cache[2] = function ($event) {
|
|
7085
7093
|
return _ctx.inputValue = $event;
|
|
7086
7094
|
}),
|
|
7087
7095
|
name: _ctx.name,
|
|
@@ -7116,7 +7124,13 @@ function render$1d(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
7116
7124
|
'pr-20': !!_ctx.$slots.suffix
|
|
7117
7125
|
}, (errorMessage || errors[0]) && meta.touched ? 'border-error text-error' : 'border-grey-40', _ctx.inputBaseClass, _ctx.rounded ? 'rounded-full' : 'rounded', {
|
|
7118
7126
|
'text-center': _ctx.centerAlignInput
|
|
7119
|
-
}]]
|
|
7127
|
+
}]],
|
|
7128
|
+
onFocus: _cache[0] || (_cache[0] = function () {
|
|
7129
|
+
return _ctx.onFocus && _ctx.onFocus.apply(_ctx, arguments);
|
|
7130
|
+
}),
|
|
7131
|
+
onBlur: _cache[1] || (_cache[1] = function () {
|
|
7132
|
+
return _ctx.onBlur && _ctx.onBlur.apply(_ctx, arguments);
|
|
7133
|
+
})
|
|
7120
7134
|
}), null, 16, _hoisted_8$a), _ctx.$slots.suffix ? (openBlock(), createElementBlock("div", _hoisted_9$9, [renderSlot(_ctx.$slots, "suffix", {
|
|
7121
7135
|
"class": "h-full"
|
|
7122
7136
|
})])) : createCommentVNode("", true)]), _ctx.enableErrors ? (openBlock(), createElementBlock("div", _hoisted_10$6, [createVNode(Transition, {
|
|
@@ -8645,6 +8659,20 @@ var script$h = defineComponent({
|
|
|
8645
8659
|
*/
|
|
8646
8660
|
external: {
|
|
8647
8661
|
type: Boolean
|
|
8662
|
+
},
|
|
8663
|
+
/**
|
|
8664
|
+
* Whether the button is disabled or not
|
|
8665
|
+
*/
|
|
8666
|
+
disabled: {
|
|
8667
|
+
type: Boolean,
|
|
8668
|
+
"default": false
|
|
8669
|
+
},
|
|
8670
|
+
/**
|
|
8671
|
+
* Whether the button is preselected or not
|
|
8672
|
+
*/
|
|
8673
|
+
active: {
|
|
8674
|
+
type: Boolean,
|
|
8675
|
+
"default": false
|
|
8648
8676
|
}
|
|
8649
8677
|
},
|
|
8650
8678
|
setup: function setup(props, ctx) {
|
|
@@ -8689,6 +8717,11 @@ var script$h = defineComponent({
|
|
|
8689
8717
|
text: 'text-grey-base hover:text-primary active:text-primary',
|
|
8690
8718
|
background: 'bg-none hover:bg-white focus:bg-white active:bg-white',
|
|
8691
8719
|
border: 'border-transparent focus-visible:ring-1 focus-visible:ring-primary'
|
|
8720
|
+
},
|
|
8721
|
+
disabled: {
|
|
8722
|
+
text: 'text-white',
|
|
8723
|
+
background: 'bg-grey-base bg-opacity-60',
|
|
8724
|
+
border: ''
|
|
8692
8725
|
}
|
|
8693
8726
|
});
|
|
8694
8727
|
var sizes = ref({
|
|
@@ -8779,13 +8812,14 @@ var _hoisted_1$v = {
|
|
|
8779
8812
|
function render$o(_ctx, _cache, $props, $setup, $data, $options) {
|
|
8780
8813
|
var _component_FwLoadingSpinner = resolveComponent("FwLoadingSpinner");
|
|
8781
8814
|
return openBlock(), createBlock(resolveDynamicComponent(_ctx.tagName), {
|
|
8782
|
-
"class": normalizeClass(["fw-button", [_ctx.baseClass, _ctx.textColorClass, _ctx.bgColorClass, _ctx.sizeClass, _ctx.borderClass, _ctx.rounded && _ctx.variant !== 'link' ? 'rounded-full' : 'rounded', _ctx.variant === 'link' ? 'pl-0 pr-0 pt-0 pb-0 font-normal rounded-1' : 'font-semibold', _ctx.animation === 'fade' ? 'animation--fade' : 'animation--alternate', _ctx.loading === true ? 'fw-button--loading cursor-progress' : 'cursor-pointer']]),
|
|
8815
|
+
"class": normalizeClass(["fw-button", [_ctx.baseClass, _ctx.textColorClass, _ctx.bgColorClass, _ctx.sizeClass, _ctx.borderClass, _ctx.rounded && _ctx.variant !== 'link' ? 'rounded-full' : 'rounded', _ctx.variant === 'link' ? 'pl-0 pr-0 pt-0 pb-0 font-normal rounded-1' : 'font-semibold', _ctx.animation === 'fade' ? 'animation--fade' : 'animation--alternate', _ctx.loading === true ? 'fw-button--loading cursor-progress' : 'cursor-pointer', _ctx.disabled && !_ctx.loading ? 'pointer-events-none text-grey-light' : '', _ctx.disabled && _ctx.active ? 'fw-button--disabled-active' : '']]),
|
|
8783
8816
|
type: _ctx.tagName === 'button' ? _ctx.buttonType : null,
|
|
8784
8817
|
to: _ctx.to ? _ctx.to : null,
|
|
8785
8818
|
href: _ctx.href ? _ctx.href : null,
|
|
8786
8819
|
tabindex: _ctx.to ? 0 : null,
|
|
8787
|
-
disabled: _ctx.loading,
|
|
8820
|
+
disabled: _ctx.loading || _ctx.disabled,
|
|
8788
8821
|
target: !!_ctx.external ? '_blank' : null,
|
|
8822
|
+
active: _ctx.active,
|
|
8789
8823
|
onClick: _ctx.onClick,
|
|
8790
8824
|
onFocusin: _ctx.onFocusin,
|
|
8791
8825
|
onFocusout: _ctx.onFocusout,
|
|
@@ -8807,11 +8841,11 @@ function render$o(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
8807
8841
|
})], 2)) : createCommentVNode("", true)])) : createCommentVNode("", true)];
|
|
8808
8842
|
}),
|
|
8809
8843
|
_: 3
|
|
8810
|
-
}, 40, ["class", "type", "to", "href", "tabindex", "disabled", "target", "onClick", "onFocusin", "onFocusout", "onMouseover", "onMouseout"]);
|
|
8844
|
+
}, 40, ["class", "type", "to", "href", "tabindex", "disabled", "target", "active", "onClick", "onFocusin", "onFocusout", "onMouseover", "onMouseout"]);
|
|
8811
8845
|
}
|
|
8812
8846
|
|
|
8813
|
-
var css_248z$f = ".fw-button{line-height:normal}.fw-button--label-wrapper{-webkit-transition-duration:.2s;-moz-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:margin,padding;-moz-transition-property:margin,padding;transition-property:margin,padding;-webkit-transition-timing-function:ease-in-out;-moz-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out}.fw-button--primary{background:var(--colorButtonPrimary);color:var(--colorButtonPrimaryText)}.fw-button--primary.fw-button--loading,.fw-button--primary:hover{background:var(--colorButtonPrimaryFade);border-color:var(--colorButtonPrimaryFade)}.fw-button--secondary{background:var(--colorButtonSecondary);color:var(--colorButtonSecondaryText)}.fw-button--secondary.animation--alternate.fw-button--loading,.fw-button--secondary.animation--alternate:hover{background:var(--colorButtonSecondaryText);color:var(--colorButtonSecondary)}.fw-button--secondary.animation--fade.fw-button--loading,.fw-button--secondary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--tertiary{background:var(--colorButtonTertiary);color:var(--colorButtonTertiaryText)}.fw-button--tertiary.animation--alternate.fw-button--loading,.fw-button--tertiary.animation--alternate:hover{background:var(--colorButtonTertiaryText);color:var(--colorButtonTertiary)}.fw-button--tertiary.animation--fade.fw-button--loading,.fw-button--tertiary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}";
|
|
8814
|
-
var stylesheet$f = ".fw-button{line-height:normal}.fw-button--label-wrapper{-webkit-transition-duration:.2s;-moz-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:margin,padding;-moz-transition-property:margin,padding;transition-property:margin,padding;-webkit-transition-timing-function:ease-in-out;-moz-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out}.fw-button--primary{background:var(--colorButtonPrimary);color:var(--colorButtonPrimaryText)}.fw-button--primary.fw-button--loading,.fw-button--primary:hover{background:var(--colorButtonPrimaryFade);border-color:var(--colorButtonPrimaryFade)}.fw-button--secondary{background:var(--colorButtonSecondary);color:var(--colorButtonSecondaryText)}.fw-button--secondary.animation--alternate.fw-button--loading,.fw-button--secondary.animation--alternate:hover{background:var(--colorButtonSecondaryText);color:var(--colorButtonSecondary)}.fw-button--secondary.animation--fade.fw-button--loading,.fw-button--secondary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--tertiary{background:var(--colorButtonTertiary);color:var(--colorButtonTertiaryText)}.fw-button--tertiary.animation--alternate.fw-button--loading,.fw-button--tertiary.animation--alternate:hover{background:var(--colorButtonTertiaryText);color:var(--colorButtonTertiary)}.fw-button--tertiary.animation--fade.fw-button--loading,.fw-button--tertiary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}";
|
|
8847
|
+
var css_248z$f = ".fw-button{line-height:normal}.fw-button--label-wrapper{-webkit-transition-duration:.2s;-moz-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:margin,padding;-moz-transition-property:margin,padding;transition-property:margin,padding;-webkit-transition-timing-function:ease-in-out;-moz-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out}.fw-button--primary{background:var(--colorButtonPrimary);color:var(--colorButtonPrimaryText)}.fw-button--primary.fw-button--loading,.fw-button--primary:hover{background:var(--colorButtonPrimaryFade);border-color:var(--colorButtonPrimaryFade)}.fw-button--secondary{background:var(--colorButtonSecondary);color:var(--colorButtonSecondaryText)}.fw-button--secondary.animation--alternate.fw-button--loading,.fw-button--secondary.animation--alternate:hover{background:var(--colorButtonSecondaryText);color:var(--colorButtonSecondary)}.fw-button--secondary.animation--fade.fw-button--loading,.fw-button--secondary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--tertiary{background:var(--colorButtonTertiary);color:var(--colorButtonTertiaryText)}.fw-button--tertiary.animation--alternate.fw-button--loading,.fw-button--tertiary.animation--alternate:hover{background:var(--colorButtonTertiaryText);color:var(--colorButtonTertiary)}.fw-button--tertiary.animation--fade.fw-button--loading,.fw-button--tertiary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--disabled-active{background:var(--colorButtonDisabled)!important;color:rgb(from var(--colorButtonDisabledText) r g b/.6)!important}";
|
|
8848
|
+
var stylesheet$f = ".fw-button{line-height:normal}.fw-button--label-wrapper{-webkit-transition-duration:.2s;-moz-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:margin,padding;-moz-transition-property:margin,padding;transition-property:margin,padding;-webkit-transition-timing-function:ease-in-out;-moz-transition-timing-function:ease-in-out;transition-timing-function:ease-in-out}.fw-button--primary{background:var(--colorButtonPrimary);color:var(--colorButtonPrimaryText)}.fw-button--primary.fw-button--loading,.fw-button--primary:hover{background:var(--colorButtonPrimaryFade);border-color:var(--colorButtonPrimaryFade)}.fw-button--secondary{background:var(--colorButtonSecondary);color:var(--colorButtonSecondaryText)}.fw-button--secondary.animation--alternate.fw-button--loading,.fw-button--secondary.animation--alternate:hover{background:var(--colorButtonSecondaryText);color:var(--colorButtonSecondary)}.fw-button--secondary.animation--fade.fw-button--loading,.fw-button--secondary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--tertiary{background:var(--colorButtonTertiary);color:var(--colorButtonTertiaryText)}.fw-button--tertiary.animation--alternate.fw-button--loading,.fw-button--tertiary.animation--alternate:hover{background:var(--colorButtonTertiaryText);color:var(--colorButtonTertiary)}.fw-button--tertiary.animation--fade.fw-button--loading,.fw-button--tertiary.animation--fade:hover{-webkit-filter:brightness(135%);filter:brightness(135%)}.fw-button--disabled-active{background:var(--colorButtonDisabled)!important;color:rgb(from var(--colorButtonDisabledText) r g b/.6)!important}";
|
|
8815
8849
|
styleInject(css_248z$f);
|
|
8816
8850
|
|
|
8817
8851
|
script$h.render = render$o;
|
|
@@ -34669,7 +34703,7 @@ function usePage() {
|
|
|
34669
34703
|
"Page context missing. Please verify this component is nested within a valid context provider."
|
|
34670
34704
|
);
|
|
34671
34705
|
}
|
|
34672
|
-
const _hoisted_1$5
|
|
34706
|
+
const _hoisted_1$5 = { class: "vc-nav-header" };
|
|
34673
34707
|
const _hoisted_2$4$1 = ["disabled"];
|
|
34674
34708
|
const _hoisted_3$3 = ["disabled"];
|
|
34675
34709
|
const _hoisted_4$2$1 = { class: "vc-nav-items" };
|
|
@@ -34819,7 +34853,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
34819
34853
|
ref_key: "navContainer",
|
|
34820
34854
|
ref: navContainer
|
|
34821
34855
|
}, [
|
|
34822
|
-
createElementVNode("div", _hoisted_1$5
|
|
34856
|
+
createElementVNode("div", _hoisted_1$5, [
|
|
34823
34857
|
createElementVNode("button", {
|
|
34824
34858
|
type: "button",
|
|
34825
34859
|
class: "vc-nav-arrow is-left vc-focus",
|
|
@@ -36661,7 +36695,7 @@ __default__$3.setup = __setup__$3 ? function (props, ctx) {
|
|
|
36661
36695
|
return __setup__$3(props, ctx);
|
|
36662
36696
|
} : __injectCSSVars__$3;
|
|
36663
36697
|
|
|
36664
|
-
var _hoisted_1$
|
|
36698
|
+
var _hoisted_1$4 = {
|
|
36665
36699
|
"class": "fw-date-picker w-full"
|
|
36666
36700
|
};
|
|
36667
36701
|
var _hoisted_2$4 = {
|
|
@@ -36710,7 +36744,7 @@ var _hoisted_18 = {
|
|
|
36710
36744
|
function render$5(_ctx, _cache, $props, $setup, $data, $options) {
|
|
36711
36745
|
var _component_CalendarDaySvg = resolveComponent("CalendarDaySvg");
|
|
36712
36746
|
var _component_DatePicker = resolveComponent("DatePicker");
|
|
36713
|
-
return openBlock(), createElementBlock("div", _hoisted_1$
|
|
36747
|
+
return openBlock(), createElementBlock("div", _hoisted_1$4, [createVNode(_component_DatePicker, {
|
|
36714
36748
|
modelValue: _ctx.dateModel,
|
|
36715
36749
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = function ($event) {
|
|
36716
36750
|
return _ctx.dateModel = $event;
|
|
@@ -37045,7 +37079,7 @@ __default__$2.setup = __setup__$2 ? function (props, ctx) {
|
|
|
37045
37079
|
var _withScopeId$2 = function _withScopeId(n) {
|
|
37046
37080
|
return pushScopeId("data-v-6df01fae"), n = n(), popScopeId(), n;
|
|
37047
37081
|
};
|
|
37048
|
-
var _hoisted_1$
|
|
37082
|
+
var _hoisted_1$3 = ["id", "aria-hidden"];
|
|
37049
37083
|
var _hoisted_2$3 = {
|
|
37050
37084
|
key: 0,
|
|
37051
37085
|
"data-popper-arrow": "",
|
|
@@ -37085,7 +37119,7 @@ function render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
37085
37119
|
})
|
|
37086
37120
|
}, [renderSlot(_ctx.$slots, "content", {}, function () {
|
|
37087
37121
|
return [createTextVNode(toDisplayString(_ctx.title), 1)];
|
|
37088
|
-
}), _ctx.showArrow ? (openBlock(), createElementBlock("span", _hoisted_2$3)) : createCommentVNode("", true)], 10, _hoisted_1$
|
|
37122
|
+
}), _ctx.showArrow ? (openBlock(), createElementBlock("span", _hoisted_2$3)) : createCommentVNode("", true)], 10, _hoisted_1$3)], 2);
|
|
37089
37123
|
}
|
|
37090
37124
|
|
|
37091
37125
|
var css_248z$3 = ".fw-popover__content[data-v-6df01fae]{opacity:0;-webkit-transition:all .3s ease;-moz-transition:all .3s ease;transition:all .3s ease;white-space:normal;z-index:9999}.fw-popover__content--center[data-v-6df01fae]{text-align:center}.fw-popover__content--left[data-v-6df01fae]{text-align:left}.fw-popover__content--right[data-v-6df01fae]{text-align:right}.fw-popover--visible .fw-popover__content[data-v-6df01fae]{opacity:1;pointer-events:all}.fw-popover__arrow[data-v-6df01fae]:after{height:var(--bf2f5546);left:0;top:0;-webkit-transform:translate(-50%,-50%) rotate(45deg);-moz-transform:translate(-50%,-50%) rotate(45deg);-ms-transform:translate(-50%,-50%) rotate(45deg);transform:translate(-50%,-50%) rotate(45deg);width:var(--bf2f5546)}.fw-popover__content[data-popper-placement^=top][data-v-6df01fae]{margin-bottom:var(--bf2f5546)!important}.fw-popover__content[data-popper-placement^=right][data-v-6df01fae]{margin-left:var(--bf2f5546)!important}.fw-popover__content[data-popper-placement^=bottom][data-v-6df01fae]{margin-top:var(--bf2f5546)!important}.fw-popover__content[data-popper-placement^=left][data-v-6df01fae]{margin-right:var(--bf2f5546)!important}.fw-popover__content[data-popper-placement^=top] .fw-popover__arrow[data-v-6df01fae]{bottom:0}.fw-popover__content[data-popper-placement^=right] .fw-popover__arrow[data-v-6df01fae]{left:0}.fw-popover__content[data-popper-placement^=bottom] .fw-popover__arrow[data-v-6df01fae]{top:0}.fw-popover__content[data-popper-placement^=left] .fw-popover__arrow[data-v-6df01fae]{right:0}.fw-popover__content[data-popper-placement^=top] .fw-popover__arrow[data-v-6df01fae]{bottom:-1px}.fw-popover__content[data-popper-placement^=top] .fw-popover__arrow[data-v-6df01fae]:after{border-left:none;border-top:none}.fw-popover__content[data-popper-placement^=right] .fw-popover__arrow[data-v-6df01fae]{left:-1px}.fw-popover__content[data-popper-placement^=right] .fw-popover__arrow[data-v-6df01fae]:after{border-right:none;border-top:none}.fw-popover__content[data-popper-placement^=bottom] .fw-popover__arrow[data-v-6df01fae]{top:-1px}.fw-popover__content[data-popper-placement^=bottom] .fw-popover__arrow[data-v-6df01fae]:after{border-bottom:none;border-right:none}.fw-popover__content[data-popper-placement^=left] .fw-popover__arrow[data-v-6df01fae]{right:-1px}.fw-popover__content[data-popper-placement^=left] .fw-popover__arrow[data-v-6df01fae]:after{border-bottom:none;border-left:none}";
|
|
@@ -37121,6 +37155,10 @@ var script$1 = defineComponent({
|
|
|
37121
37155
|
validator: function validator(value) {
|
|
37122
37156
|
return ['sm', 'md', 'lg', 'xl', '2xl'].includes(value);
|
|
37123
37157
|
}
|
|
37158
|
+
},
|
|
37159
|
+
disabled: {
|
|
37160
|
+
type: Boolean,
|
|
37161
|
+
"default": false
|
|
37124
37162
|
}
|
|
37125
37163
|
},
|
|
37126
37164
|
setup: function setup(props, ctx) {
|
|
@@ -37142,27 +37180,28 @@ var script$1 = defineComponent({
|
|
|
37142
37180
|
}
|
|
37143
37181
|
});
|
|
37144
37182
|
|
|
37145
|
-
var _hoisted_1$3 = {
|
|
37146
|
-
"class": "fw-period-selector w-fit bg-grey-light bg-opacity-10 border-grey-light border-2 border-opacity-40 gap-x-1"
|
|
37147
|
-
};
|
|
37148
37183
|
function render$3(_ctx, _cache, $props, $setup, $data, $options) {
|
|
37149
37184
|
var _component_FwButton = resolveComponent("FwButton");
|
|
37150
|
-
return openBlock(), createElementBlock("div",
|
|
37185
|
+
return openBlock(), createElementBlock("div", {
|
|
37186
|
+
"class": normalizeClass(["fw-period-selector w-fit bg-grey-light bg-opacity-10 border-grey-light border-2 border-opacity-40 gap-x-1", _ctx.disabled === true ? 'hover:none cursor:none pointer-events-none' : ''])
|
|
37187
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.periodOptions, function (period) {
|
|
37151
37188
|
return openBlock(), createBlock(_component_FwButton, {
|
|
37152
37189
|
key: period,
|
|
37153
|
-
variant: _ctx.selectedPeriod === period ? 'tertiary' : 'transparent',
|
|
37190
|
+
variant: _ctx.selectedPeriod === period ? _ctx.disabled ? 'disabled' : 'tertiary' : 'transparent',
|
|
37154
37191
|
"class": "hover:!border-button-primary-bg -m-[2px] flex-1",
|
|
37155
37192
|
size: _ctx.size,
|
|
37156
37193
|
onClick: function onClick($event) {
|
|
37157
37194
|
return _ctx.selectedPeriod = period;
|
|
37158
|
-
}
|
|
37195
|
+
},
|
|
37196
|
+
disabled: _ctx.disabled,
|
|
37197
|
+
active: _ctx.disabled && _ctx.selectedPeriod === period
|
|
37159
37198
|
}, {
|
|
37160
37199
|
"default": withCtx(function () {
|
|
37161
37200
|
return [createTextVNode(toDisplayString(_ctx.generateButtonLabel(period)), 1)];
|
|
37162
37201
|
}),
|
|
37163
37202
|
_: 2
|
|
37164
|
-
}, 1032, ["variant", "size", "onClick"]);
|
|
37165
|
-
}), 128))]);
|
|
37203
|
+
}, 1032, ["variant", "size", "onClick", "disabled", "active"]);
|
|
37204
|
+
}), 128))], 2);
|
|
37166
37205
|
}
|
|
37167
37206
|
|
|
37168
37207
|
var css_248z$2 = ".fw-period-selector{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-moz-box-orient:horizontal;-moz-box-direction:normal;border-radius:9999px;display:-webkit-box;display:-webkit-flex;display:-moz-box;display:-ms-flexbox;display:flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row}";
|
package/index.d.ts
CHANGED
|
@@ -131,7 +131,9 @@ declare const _default$o: vue.DefineComponent<{
|
|
|
131
131
|
uuid: string;
|
|
132
132
|
inputBaseClass: vue.Ref<string>;
|
|
133
133
|
inputValue: vue.WritableComputedRef<string>;
|
|
134
|
-
|
|
134
|
+
onFocus: (e: FocusEvent) => void;
|
|
135
|
+
onBlur: (e: FocusEvent) => void;
|
|
136
|
+
}, unknown, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, ("update:modelValue" | "focus" | "blur")[], "update:modelValue" | "focus" | "blur", vue.PublicProps, Readonly<vue.ExtractPropTypes<{
|
|
135
137
|
/**
|
|
136
138
|
* The input v-model
|
|
137
139
|
*/
|
|
@@ -235,6 +237,8 @@ declare const _default$o: vue.DefineComponent<{
|
|
|
235
237
|
};
|
|
236
238
|
}>> & {
|
|
237
239
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
240
|
+
onFocus?: ((...args: any[]) => any) | undefined;
|
|
241
|
+
onBlur?: ((...args: any[]) => any) | undefined;
|
|
238
242
|
}, {
|
|
239
243
|
modelValue: string;
|
|
240
244
|
type: FwInputType;
|
|
@@ -604,7 +608,7 @@ declare const _default$l: vue.DefineComponent<{
|
|
|
604
608
|
isBordered: boolean;
|
|
605
609
|
}, {}>;
|
|
606
610
|
|
|
607
|
-
type ButtonVariantName = 'primary' | 'secondary' | 'tertiary' | 'error' | 'success' | 'link' | 'text' | 'transparent';
|
|
611
|
+
type ButtonVariantName = 'primary' | 'secondary' | 'tertiary' | 'error' | 'success' | 'link' | 'text' | 'transparent' | 'disabled';
|
|
608
612
|
declare interface ButtonDefinition {
|
|
609
613
|
text: string;
|
|
610
614
|
background: string;
|
|
@@ -630,6 +634,8 @@ declare interface FwButtonProps {
|
|
|
630
634
|
rounded?: boolean;
|
|
631
635
|
loading?: boolean;
|
|
632
636
|
external?: boolean;
|
|
637
|
+
disabled?: boolean;
|
|
638
|
+
active?: boolean;
|
|
633
639
|
}
|
|
634
640
|
|
|
635
641
|
declare const _default$k: vue.DefineComponent<{
|
|
@@ -704,6 +710,20 @@ declare const _default$k: vue.DefineComponent<{
|
|
|
704
710
|
external: {
|
|
705
711
|
type: BooleanConstructor;
|
|
706
712
|
};
|
|
713
|
+
/**
|
|
714
|
+
* Whether the button is disabled or not
|
|
715
|
+
*/
|
|
716
|
+
disabled: {
|
|
717
|
+
type: BooleanConstructor;
|
|
718
|
+
default: boolean;
|
|
719
|
+
};
|
|
720
|
+
/**
|
|
721
|
+
* Whether the button is preselected or not
|
|
722
|
+
*/
|
|
723
|
+
active: {
|
|
724
|
+
type: BooleanConstructor;
|
|
725
|
+
default: boolean;
|
|
726
|
+
};
|
|
707
727
|
}, {
|
|
708
728
|
baseClass: vue.Ref<string>;
|
|
709
729
|
textColorClass: vue.ComputedRef<string>;
|
|
@@ -804,6 +824,20 @@ declare const _default$k: vue.DefineComponent<{
|
|
|
804
824
|
external: {
|
|
805
825
|
type: BooleanConstructor;
|
|
806
826
|
};
|
|
827
|
+
/**
|
|
828
|
+
* Whether the button is disabled or not
|
|
829
|
+
*/
|
|
830
|
+
disabled: {
|
|
831
|
+
type: BooleanConstructor;
|
|
832
|
+
default: boolean;
|
|
833
|
+
};
|
|
834
|
+
/**
|
|
835
|
+
* Whether the button is preselected or not
|
|
836
|
+
*/
|
|
837
|
+
active: {
|
|
838
|
+
type: BooleanConstructor;
|
|
839
|
+
default: boolean;
|
|
840
|
+
};
|
|
807
841
|
}>> & {
|
|
808
842
|
onClick?: ((...args: any[]) => any) | undefined;
|
|
809
843
|
onMouseover?: ((...args: any[]) => any) | undefined;
|
|
@@ -812,12 +846,14 @@ declare const _default$k: vue.DefineComponent<{
|
|
|
812
846
|
onFocusout?: ((...args: any[]) => any) | undefined;
|
|
813
847
|
}, {
|
|
814
848
|
size: ButtonSize;
|
|
849
|
+
disabled: boolean;
|
|
815
850
|
variant: ButtonVariantName;
|
|
816
851
|
buttonType: ButtonTypeAttribute;
|
|
817
852
|
animation: ButtonAnimation;
|
|
818
853
|
rounded: boolean;
|
|
819
854
|
loading: boolean;
|
|
820
855
|
external: boolean;
|
|
856
|
+
active: boolean;
|
|
821
857
|
}, {}>;
|
|
822
858
|
|
|
823
859
|
declare interface NavMenuItem {
|
|
@@ -2889,6 +2925,10 @@ declare const _default$2: vue.DefineComponent<{
|
|
|
2889
2925
|
default: string;
|
|
2890
2926
|
validator: (value: string) => boolean;
|
|
2891
2927
|
};
|
|
2928
|
+
disabled: {
|
|
2929
|
+
type: BooleanConstructor;
|
|
2930
|
+
default: boolean;
|
|
2931
|
+
};
|
|
2892
2932
|
}, {
|
|
2893
2933
|
generateButtonLabel: (month: number) => string;
|
|
2894
2934
|
selectedPeriod: vue.WritableComputedRef<number | undefined>;
|
|
@@ -2910,10 +2950,15 @@ declare const _default$2: vue.DefineComponent<{
|
|
|
2910
2950
|
default: string;
|
|
2911
2951
|
validator: (value: string) => boolean;
|
|
2912
2952
|
};
|
|
2953
|
+
disabled: {
|
|
2954
|
+
type: BooleanConstructor;
|
|
2955
|
+
default: boolean;
|
|
2956
|
+
};
|
|
2913
2957
|
}>> & {
|
|
2914
2958
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
2915
2959
|
}, {
|
|
2916
2960
|
size: ButtonSize;
|
|
2961
|
+
disabled: boolean;
|
|
2917
2962
|
}, {}>;
|
|
2918
2963
|
|
|
2919
2964
|
declare const _default$1: vue.DefineComponent<{
|
package/package.json
CHANGED
package/styles/tailwind.scss
CHANGED
package/tailwind.config.js
CHANGED
|
@@ -72,6 +72,20 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
72
72
|
external: {
|
|
73
73
|
type: BooleanConstructor;
|
|
74
74
|
};
|
|
75
|
+
/**
|
|
76
|
+
* Whether the button is disabled or not
|
|
77
|
+
*/
|
|
78
|
+
disabled: {
|
|
79
|
+
type: BooleanConstructor;
|
|
80
|
+
default: boolean;
|
|
81
|
+
};
|
|
82
|
+
/**
|
|
83
|
+
* Whether the button is preselected or not
|
|
84
|
+
*/
|
|
85
|
+
active: {
|
|
86
|
+
type: BooleanConstructor;
|
|
87
|
+
default: boolean;
|
|
88
|
+
};
|
|
75
89
|
}, {
|
|
76
90
|
baseClass: import("vue").Ref<string>;
|
|
77
91
|
textColorClass: import("vue").ComputedRef<string>;
|
|
@@ -172,6 +186,20 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
172
186
|
external: {
|
|
173
187
|
type: BooleanConstructor;
|
|
174
188
|
};
|
|
189
|
+
/**
|
|
190
|
+
* Whether the button is disabled or not
|
|
191
|
+
*/
|
|
192
|
+
disabled: {
|
|
193
|
+
type: BooleanConstructor;
|
|
194
|
+
default: boolean;
|
|
195
|
+
};
|
|
196
|
+
/**
|
|
197
|
+
* Whether the button is preselected or not
|
|
198
|
+
*/
|
|
199
|
+
active: {
|
|
200
|
+
type: BooleanConstructor;
|
|
201
|
+
default: boolean;
|
|
202
|
+
};
|
|
175
203
|
}>> & {
|
|
176
204
|
onClick?: ((...args: any[]) => any) | undefined;
|
|
177
205
|
onMouseover?: ((...args: any[]) => any) | undefined;
|
|
@@ -180,11 +208,13 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
180
208
|
onFocusout?: ((...args: any[]) => any) | undefined;
|
|
181
209
|
}, {
|
|
182
210
|
size: ButtonSize;
|
|
211
|
+
disabled: boolean;
|
|
183
212
|
variant: ButtonVariantName;
|
|
184
213
|
buttonType: ButtonTypeAttribute;
|
|
185
214
|
animation: ButtonAnimation;
|
|
186
215
|
rounded: boolean;
|
|
187
216
|
loading: boolean;
|
|
188
217
|
external: boolean;
|
|
218
|
+
active: boolean;
|
|
189
219
|
}, {}>;
|
|
190
220
|
export default _default;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type ButtonVariantName = 'primary' | 'secondary' | 'tertiary' | 'error' | 'success' | 'link' | 'text' | 'transparent';
|
|
1
|
+
export type ButtonVariantName = 'primary' | 'secondary' | 'tertiary' | 'error' | 'success' | 'link' | 'text' | 'transparent' | 'disabled';
|
|
2
2
|
export declare interface ButtonDefinition {
|
|
3
3
|
text: string;
|
|
4
4
|
background: string;
|
|
@@ -24,4 +24,6 @@ export declare interface FwButtonProps {
|
|
|
24
24
|
rounded?: boolean;
|
|
25
25
|
loading?: boolean;
|
|
26
26
|
external?: boolean;
|
|
27
|
+
disabled?: boolean;
|
|
28
|
+
active?: boolean;
|
|
27
29
|
}
|
|
@@ -106,7 +106,9 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
106
106
|
uuid: string;
|
|
107
107
|
inputBaseClass: import("vue").Ref<string>;
|
|
108
108
|
inputValue: import("vue").WritableComputedRef<string>;
|
|
109
|
-
|
|
109
|
+
onFocus: (e: FocusEvent) => void;
|
|
110
|
+
onBlur: (e: FocusEvent) => void;
|
|
111
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "focus" | "blur")[], "update:modelValue" | "focus" | "blur", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
110
112
|
/**
|
|
111
113
|
* The input v-model
|
|
112
114
|
*/
|
|
@@ -210,6 +212,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
210
212
|
};
|
|
211
213
|
}>> & {
|
|
212
214
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
215
|
+
onFocus?: ((...args: any[]) => any) | undefined;
|
|
216
|
+
onBlur?: ((...args: any[]) => any) | undefined;
|
|
213
217
|
}, {
|
|
214
218
|
modelValue: string;
|
|
215
219
|
type: FwInputType;
|
|
@@ -18,6 +18,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
18
18
|
default: string;
|
|
19
19
|
validator: (value: string) => boolean;
|
|
20
20
|
};
|
|
21
|
+
disabled: {
|
|
22
|
+
type: BooleanConstructor;
|
|
23
|
+
default: boolean;
|
|
24
|
+
};
|
|
21
25
|
}, {
|
|
22
26
|
generateButtonLabel: (month: number) => string;
|
|
23
27
|
selectedPeriod: import("vue").WritableComputedRef<number | undefined>;
|
|
@@ -39,9 +43,14 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
39
43
|
default: string;
|
|
40
44
|
validator: (value: string) => boolean;
|
|
41
45
|
};
|
|
46
|
+
disabled: {
|
|
47
|
+
type: BooleanConstructor;
|
|
48
|
+
default: boolean;
|
|
49
|
+
};
|
|
42
50
|
}>> & {
|
|
43
51
|
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
44
52
|
}, {
|
|
45
53
|
size: ButtonSize;
|
|
54
|
+
disabled: boolean;
|
|
46
55
|
}, {}>;
|
|
47
56
|
export default _default;
|