@adyen/bento-vue2 1.45.0 → 1.47.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/@types/index.d.ts +16740 -18774
- package/dist/accordion.js +1 -1
- package/dist/action-bar.js +1 -1
- package/dist/alert.js +1 -1
- package/dist/assets/accordion-item.css +1 -1
- package/dist/assets/action-bar.css +1 -1
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/calendar.css +1 -1
- package/dist/assets/card.css +1 -1
- package/dist/assets/data-grid.css +1 -1
- package/dist/assets/date-picker.css +1 -1
- package/dist/assets/date-range-picker.css +1 -1
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/divider.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/file-uploader.css +1 -1
- package/dist/assets/input-field-password.css +1 -1
- package/dist/assets/input-field.css +1 -1
- package/dist/assets/inspector.css +1 -1
- package/dist/assets/menu.css +1 -1
- package/dist/assets/modal-fullscreen.css +1 -1
- package/dist/assets/popover.css +1 -1
- package/dist/assets/radio-group.css +1 -1
- package/dist/assets/radio-input.css +1 -1
- package/dist/assets/sidepanel.css +1 -1
- package/dist/assets/status.css +1 -1
- package/dist/assets/step.css +1 -1
- package/dist/button.js +1 -1
- package/dist/card.js +1 -1
- package/dist/checkbox.js +2 -2
- package/dist/chunks/{accordion-item.CzKttO4w.js → accordion-item.CTxrEQEW.js} +5 -5
- package/dist/chunks/{accordion-item.CzKttO4w.js.map → accordion-item.CTxrEQEW.js.map} +1 -1
- package/dist/chunks/{action-bar.BXemSuq4.js → action-bar.EcN2I7Az.js} +11 -11
- package/dist/chunks/{action-bar.BXemSuq4.js.map → action-bar.EcN2I7Az.js.map} +1 -1
- package/dist/chunks/{alert.CAIp-87f.js → alert.BRN8cpXl.js} +7 -7
- package/dist/chunks/{alert.CAIp-87f.js.map → alert.BRN8cpXl.js.map} +1 -1
- package/dist/chunks/{base-modal.4JSNBM4T.js → base-modal.BgTZ8iQ6.js} +5 -5
- package/dist/chunks/{base-modal.4JSNBM4T.js.map → base-modal.BgTZ8iQ6.js.map} +1 -1
- package/dist/chunks/{button-actions-with-menu.ieopdfI7.js → button-actions-with-menu.C8EjGVCT.js} +4 -4
- package/dist/chunks/{button-actions-with-menu.ieopdfI7.js.map → button-actions-with-menu.C8EjGVCT.js.map} +1 -1
- package/dist/chunks/{button-actions.CtFB6iRj.js → button-actions.BU173IFE.js} +5 -5
- package/dist/chunks/{button-actions.CtFB6iRj.js.map → button-actions.BU173IFE.js.map} +1 -1
- package/dist/chunks/{calendar.BouORZfb.js → calendar.DlOcbH6E.js} +161 -148
- package/dist/chunks/{calendar.BouORZfb.js.map → calendar.DlOcbH6E.js.map} +1 -1
- package/dist/chunks/{card.BabmUkTG.js → card.DoyCGJay.js} +10 -10
- package/dist/chunks/{card.BabmUkTG.js.map → card.DoyCGJay.js.map} +1 -1
- package/dist/chunks/{checkbox-group.DbLznnsa.js → checkbox-group.BQN9gjgH.js} +4 -4
- package/dist/chunks/{checkbox-group.DbLznnsa.js.map → checkbox-group.BQN9gjgH.js.map} +1 -1
- package/dist/chunks/{checkbox.fhQLs-NN.js → checkbox.O1CbmNdS.js} +22 -22
- package/dist/chunks/{checkbox.fhQLs-NN.js.map → checkbox.O1CbmNdS.js.map} +1 -1
- package/dist/chunks/{code-snippet.5iJcUZSo.js → code-snippet.BDBD85qD.js} +117 -87
- package/dist/chunks/code-snippet.BDBD85qD.js.map +1 -0
- package/dist/chunks/{codemirror.CXFEqvAi.js → codemirror.0fz2cWJS.js} +4970 -4661
- package/dist/chunks/codemirror.0fz2cWJS.js.map +1 -0
- package/dist/chunks/{controls-group.CnXzOQkX.js → controls-group.C3RDqB9H.js} +2 -2
- package/dist/chunks/{controls-group.CnXzOQkX.js.map → controls-group.C3RDqB9H.js.map} +1 -1
- package/dist/chunks/{copy.DN0tClPm.js → copy.BuMSGw23.js} +5 -5
- package/dist/chunks/{copy.DN0tClPm.js.map → copy.BuMSGw23.js.map} +1 -1
- package/dist/chunks/{country.Bft91V1L.js → country.2-ZtYkh7.js} +2 -2
- package/dist/chunks/{country.Bft91V1L.js.map → country.2-ZtYkh7.js.map} +1 -1
- package/dist/chunks/{country.types.pilf5B3F.js → country.types.CLjbulKL.js} +4114 -4114
- package/dist/chunks/{country.types.pilf5B3F.js.map → country.types.CLjbulKL.js.map} +1 -1
- package/dist/chunks/{dashboard-section.DYXZhtop.js → dashboard-section.COWO5SVw.js} +3 -3
- package/dist/chunks/{dashboard-section.DYXZhtop.js.map → dashboard-section.COWO5SVw.js.map} +1 -1
- package/dist/chunks/{dashed-underline.BvSZS1-m.js → dashed-underline.BEAEmTCb.js} +2 -2
- package/dist/chunks/{dashed-underline.BvSZS1-m.js.map → dashed-underline.BEAEmTCb.js.map} +1 -1
- package/dist/chunks/{data-grid-template.Du92TEFY.js → data-grid-template.vBl7u2cB.js} +2 -2
- package/dist/chunks/{data-grid-template.Du92TEFY.js.map → data-grid-template.vBl7u2cB.js.map} +1 -1
- package/dist/chunks/{data-grid.Kwtf1DMq.js → data-grid.DQ0578m9.js} +46 -46
- package/dist/chunks/{data-grid.Kwtf1DMq.js.map → data-grid.DQ0578m9.js.map} +1 -1
- package/dist/chunks/{date-picker.B7mTNghB.js → date-picker.Bym2OEd9.js} +47 -39
- package/dist/chunks/date-picker.Bym2OEd9.js.map +1 -0
- package/dist/chunks/{date-range-picker.DPLri9D-.js → date-range-picker.P2Q5FNB-.js} +310 -306
- package/dist/chunks/date-range-picker.P2Q5FNB-.js.map +1 -0
- package/dist/chunks/divider.Cc4JFWG_.js +35 -0
- package/dist/chunks/divider.Cc4JFWG_.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.DBoSso4J.js → dropdown-default-textbox.CC9Z_RFG.js} +4 -4
- package/dist/chunks/{dropdown-default-textbox.DBoSso4J.js.map → dropdown-default-textbox.CC9Z_RFG.js.map} +1 -1
- package/dist/chunks/{dropdown-tag.XIlES6IT.js → dropdown-tag.CiCDvGyN.js} +4 -4
- package/dist/chunks/{dropdown-tag.XIlES6IT.js.map → dropdown-tag.CiCDvGyN.js.map} +1 -1
- package/dist/chunks/{dropdown.BqsoncJr.js → dropdown.hc9ZuuTt.js} +197 -193
- package/dist/chunks/dropdown.hc9ZuuTt.js.map +1 -0
- package/dist/chunks/{error-message.Ccc1sTTp.js → error-message.Da-p1QIA.js} +8 -8
- package/dist/chunks/{error-message.Ccc1sTTp.js.map → error-message.Da-p1QIA.js.map} +1 -1
- package/dist/chunks/{es6.jIyAPBgt.js → es6.BtaxuP0b.js} +7 -7
- package/dist/chunks/es6.BtaxuP0b.js.map +1 -0
- package/dist/chunks/file-uploader.DVyryYaq.js +1879 -0
- package/dist/chunks/file-uploader.DVyryYaq.js.map +1 -0
- package/dist/chunks/{filter-bar.DT_-lVmf.js → filter-bar.DzcNo5nF.js} +53 -53
- package/dist/chunks/{filter-bar.DT_-lVmf.js.map → filter-bar.DzcNo5nF.js.map} +1 -1
- package/dist/chunks/{footer-actions.D0uH9JWq.js → footer-actions.Cbe_YLjP.js} +2 -2
- package/dist/chunks/{footer-actions.D0uH9JWq.js.map → footer-actions.Cbe_YLjP.js.map} +1 -1
- package/dist/chunks/{form-layout-title.DN0jonFa.js → form-layout-title.Xdsi84v2.js} +2 -2
- package/dist/chunks/{form-layout-title.DN0jonFa.js.map → form-layout-title.Xdsi84v2.js.map} +1 -1
- package/dist/chunks/{header.BvZxtIOD.js → header.BIZTUAJE.js} +4 -4
- package/dist/chunks/{header.BvZxtIOD.js.map → header.BIZTUAJE.js.map} +1 -1
- package/dist/chunks/{info-icon-with-popover.DEjsASNU.js → info-icon-with-popover.Bly2e0uy.js} +5 -5
- package/dist/chunks/{info-icon-with-popover.DEjsASNU.js.map → info-icon-with-popover.Bly2e0uy.js.map} +1 -1
- package/dist/chunks/{input-field-password.HRDEb0jL.js → input-field-password.CosL-n__.js} +27 -27
- package/dist/chunks/{input-field-password.HRDEb0jL.js.map → input-field-password.CosL-n__.js.map} +1 -1
- package/dist/chunks/input-field.DgDFJbg7.js +231 -0
- package/dist/chunks/input-field.DgDFJbg7.js.map +1 -0
- package/dist/chunks/{inspector.types.2YEArjPi.js → inspector.types.8071wkf0.js} +5 -5
- package/dist/chunks/{inspector.types.2YEArjPi.js.map → inspector.types.8071wkf0.js.map} +1 -1
- package/dist/chunks/{menu.CLaN9Eys.js → menu.Dq7RlryT.js} +5 -5
- package/dist/chunks/{menu.CLaN9Eys.js.map → menu.Dq7RlryT.js.map} +1 -1
- package/dist/chunks/{modal-fullscreen.B-qr1Szh.js → modal-fullscreen.CfrgVR_K.js} +5 -5
- package/dist/chunks/{modal-fullscreen.B-qr1Szh.js.map → modal-fullscreen.CfrgVR_K.js.map} +1 -1
- package/dist/chunks/{modal.wU3uUJKq.js → modal.CuUUMIU_.js} +4 -4
- package/dist/chunks/{modal.wU3uUJKq.js.map → modal.CuUUMIU_.js.map} +1 -1
- package/dist/chunks/{pagination.BM3FhtxJ.js → pagination.QF1EEUfX.js} +45 -45
- package/dist/chunks/{pagination.BM3FhtxJ.js.map → pagination.QF1EEUfX.js.map} +1 -1
- package/dist/chunks/{popover.DsUymZWJ.js → popover.nev0GndY.js} +2 -2
- package/dist/chunks/{popover.DsUymZWJ.js.map → popover.nev0GndY.js.map} +1 -1
- package/dist/chunks/radio-group.D1q0VKvv.js +229 -0
- package/dist/chunks/radio-group.D1q0VKvv.js.map +1 -0
- package/dist/chunks/{radio-input.C1DZbkcT.js → radio-input.uJAhxKRs.js} +29 -25
- package/dist/chunks/{radio-input.C1DZbkcT.js.map → radio-input.uJAhxKRs.js.map} +1 -1
- package/dist/chunks/{search-bar.rubkdbcD.js → search-bar.fmMx-zRN.js} +7 -7
- package/dist/chunks/{search-bar.rubkdbcD.js.map → search-bar.fmMx-zRN.js.map} +1 -1
- package/dist/chunks/{secondary-nav.DKSjc5bn.js → secondary-nav.ldVrzGbB.js} +7 -7
- package/dist/chunks/{secondary-nav.DKSjc5bn.js.map → secondary-nav.ldVrzGbB.js.map} +1 -1
- package/dist/chunks/{selection-card-group.iYyZ9yX4.js → selection-card-group.CdkrhyZV.js} +11 -11
- package/dist/chunks/{selection-card-group.iYyZ9yX4.js.map → selection-card-group.CdkrhyZV.js.map} +1 -1
- package/dist/chunks/{sidepanel.CQnLpV8A.js → sidepanel.D-KuHnwI.js} +5 -5
- package/dist/chunks/{sidepanel.CQnLpV8A.js.map → sidepanel.D-KuHnwI.js.map} +1 -1
- package/dist/chunks/{status.types.Cv6hHRMu.js → status.types.Ce018tQy.js} +18 -17
- package/dist/chunks/status.types.Ce018tQy.js.map +1 -0
- package/dist/chunks/{structured-list-item.BhBbmkbw.js → structured-list-item.Dk8Z-FPn.js} +5 -5
- package/dist/chunks/{structured-list-item.BhBbmkbw.js.map → structured-list-item.Dk8Z-FPn.js.map} +1 -1
- package/dist/chunks/{summary-grid-item-custom.CicAOBVQ.js → summary-grid-item-custom.atXX3GY9.js} +2 -2
- package/dist/chunks/{summary-grid-item-custom.CicAOBVQ.js.map → summary-grid-item-custom.atXX3GY9.js.map} +1 -1
- package/dist/chunks/{textarea.Cf21WMwL.js → textarea.BVzGn3zO.js} +2 -2
- package/dist/chunks/{textarea.Cf21WMwL.js.map → textarea.BVzGn3zO.js.map} +1 -1
- package/dist/chunks/{timeline-item.Cu5b-Mqj.js → timeline-item.D_YNHlRi.js} +13 -13
- package/dist/chunks/{timeline-item.Cu5b-Mqj.js.map → timeline-item.D_YNHlRi.js.map} +1 -1
- package/dist/chunks/{tutorial.w2ZqeOh1.js → tutorial.cQXPvqV4.js} +10 -10
- package/dist/chunks/{tutorial.w2ZqeOh1.js.map → tutorial.cQXPvqV4.js.map} +1 -1
- package/dist/chunks/{use-cached-selected-values.impKjAIS.js → use-cached-selected-values.BGlHmPhX.js} +10 -10
- package/dist/chunks/{use-cached-selected-values.impKjAIS.js.map → use-cached-selected-values.BGlHmPhX.js.map} +1 -1
- package/dist/chunks/{use-country-items.DPBbl1KK.js → use-country-items.eWARMT6I.js} +2 -2
- package/dist/chunks/{use-country-items.DPBbl1KK.js.map → use-country-items.eWARMT6I.js.map} +1 -1
- package/dist/code-snippet.js +1 -1
- package/dist/country.js +2 -2
- package/dist/dashboard-template.js +1 -1
- package/dist/dashed-underline.js +1 -1
- package/dist/data-grid-template.js +1 -1
- package/dist/data-grid.js +1 -1
- package/dist/date-picker.js +2 -2
- package/dist/date-range-picker.js +2 -2
- package/dist/divider.js +1 -1
- package/dist/dropdown.js +4 -4
- package/dist/file-uploader.js +1 -1
- package/dist/filter-bar.js +1 -1
- package/dist/form-layout.js +1 -1
- package/dist/header.js +1 -1
- package/dist/index.js +47 -47
- package/dist/input-field-password.js +1 -1
- package/dist/input-field.js +1 -1
- package/dist/inspector.js +1 -1
- package/dist/internal.js +8 -8
- package/dist/menu.js +1 -1
- package/dist/modal-fullscreen.js +1 -1
- package/dist/modal.js +2 -2
- package/dist/pagination.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/radio-group.js +2 -2
- package/dist/search-bar.js +2 -2
- package/dist/secondary-nav.js +1 -1
- package/dist/selection-card.js +1 -1
- package/dist/sidepanel.js +1 -1
- package/dist/status.js +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/styles/bento-dark.css +2 -0
- package/dist/styles/bento-light.css +2 -0
- package/dist/styles/bento.css +2 -0
- package/dist/styles/legacy.css +7 -5
- package/dist/styles/styleguide.css +2 -0
- package/dist/summary-grid.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/timeline.js +1 -1
- package/dist/tutorial.js +1 -1
- package/dist/web-types.json +42 -3
- package/package.json +12 -7
- package/dist/chunks/code-snippet.5iJcUZSo.js.map +0 -1
- package/dist/chunks/codemirror.CXFEqvAi.js.map +0 -1
- package/dist/chunks/date-picker.B7mTNghB.js.map +0 -1
- package/dist/chunks/date-range-picker.DPLri9D-.js.map +0 -1
- package/dist/chunks/divider.BZfeYmB9.js +0 -30
- package/dist/chunks/divider.BZfeYmB9.js.map +0 -1
- package/dist/chunks/dropdown.BqsoncJr.js.map +0 -1
- package/dist/chunks/es6.jIyAPBgt.js.map +0 -1
- package/dist/chunks/file-uploader.C6kcnhqp.js +0 -729
- package/dist/chunks/file-uploader.C6kcnhqp.js.map +0 -1
- package/dist/chunks/input-field.D6N2kt7s.js +0 -228
- package/dist/chunks/input-field.D6N2kt7s.js.map +0 -1
- package/dist/chunks/radio-group.DMob8x2J.js +0 -219
- package/dist/chunks/radio-group.DMob8x2J.js.map +0 -1
- package/dist/chunks/status.types.Cv6hHRMu.js.map +0 -1
|
@@ -1,219 +0,0 @@
|
|
|
1
|
-
import { defineComponent as v, useSlots as S, toRefs as I, computed as s, toRef as h, watch as R } from "vue";
|
|
2
|
-
import { u as T } from "./use-form-layout-loading.D3lALhtC.js";
|
|
3
|
-
import { u as C } from "./use-has-slot.C9lQZ6nz.js";
|
|
4
|
-
import { g as b } from "./generate-uid.NJ8tVoha.js";
|
|
5
|
-
import { B as M, d as L } from "./typography.J1v_SPG3.js";
|
|
6
|
-
import { B as x } from "./tag.-YNhsBv7.js";
|
|
7
|
-
import { u as O } from "./aria-label.CaUURpnB.js";
|
|
8
|
-
import { u as N } from "./use-default-slot-validator.BDn0wkYP.js";
|
|
9
|
-
import { g as V } from "./get-slot-text.Cgn-E48s.js";
|
|
10
|
-
import { R as g, a as w } from "./radio-input.C1DZbkcT.js";
|
|
11
|
-
import { n as B } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
12
|
-
import { C as A } from "./controls-group.CnXzOQkX.js";
|
|
13
|
-
import { E as k } from "./error-message.Ccc1sTTp.js";
|
|
14
|
-
import "../assets/radio-group.css";
|
|
15
|
-
const $ = {
|
|
16
|
-
name: "bento-radio-button",
|
|
17
|
-
model: { prop: "modelValue" }
|
|
18
|
-
}, q = /* @__PURE__ */ v({
|
|
19
|
-
...$,
|
|
20
|
-
props: {
|
|
21
|
-
/**
|
|
22
|
-
* Disable the radio button (optional)
|
|
23
|
-
*/
|
|
24
|
-
disabled: { type: Boolean, default: !1 },
|
|
25
|
-
/**
|
|
26
|
-
* Shows bento-radio-button in error state (optional)
|
|
27
|
-
*/
|
|
28
|
-
hasError: { type: Boolean, default: !1 },
|
|
29
|
-
/**
|
|
30
|
-
* This property should not be used directly.
|
|
31
|
-
* It will be used by v-model directive on radio component.
|
|
32
|
-
*/
|
|
33
|
-
modelValue: {
|
|
34
|
-
type: [String, Number],
|
|
35
|
-
default: null
|
|
36
|
-
},
|
|
37
|
-
/**
|
|
38
|
-
* Sets the radio button to readonly (optional)
|
|
39
|
-
*/
|
|
40
|
-
readonly: { type: Boolean, default: !1 },
|
|
41
|
-
/**
|
|
42
|
-
* Sets the properties of the BentoTag component that is placed next to the label.
|
|
43
|
-
* {@see BentoTag}
|
|
44
|
-
*/
|
|
45
|
-
tag: { type: Object, default: void 0 },
|
|
46
|
-
/**
|
|
47
|
-
* Indicates the value of the input that will be returned when it's checked
|
|
48
|
-
*/
|
|
49
|
-
value: {
|
|
50
|
-
type: [String, Number],
|
|
51
|
-
required: !0
|
|
52
|
-
},
|
|
53
|
-
/**
|
|
54
|
-
* Sets the name of the radio input.
|
|
55
|
-
* Used for differentiating radio groups or accessing input via form submission.
|
|
56
|
-
*/
|
|
57
|
-
name: {
|
|
58
|
-
type: String,
|
|
59
|
-
default: null
|
|
60
|
-
}
|
|
61
|
-
},
|
|
62
|
-
emits: ["input", "update:model-value"],
|
|
63
|
-
setup(r, { emit: e }) {
|
|
64
|
-
const o = r, t = S(), a = C(t), { value: l } = I(o), p = b("bento-radio-button"), c = b("description");
|
|
65
|
-
N("bento-radio-button", t.default, t.description);
|
|
66
|
-
const n = s(() => ({
|
|
67
|
-
[`b-radio-button--${g.DISABLED}`]: o.disabled,
|
|
68
|
-
[`b-radio-button--${g.READONLY}`]: o.readonly
|
|
69
|
-
})), f = O({
|
|
70
|
-
ariaLabel: V(t)("default"),
|
|
71
|
-
label: l.value
|
|
72
|
-
}), _ = s(() => o.value === o.modelValue);
|
|
73
|
-
return { __sfc: !0, slots: t, hasSlot: a, props: o, emit: e, value: l, radioButtonId: p, descriptionId: c, conditionalClassContainer: n, ariaLabel: f, isChecked: _, onChange: () => {
|
|
74
|
-
!o.disabled && !o.readonly && (e("update:model-value", o.value), e("input", o.value));
|
|
75
|
-
}, BentoTag: x, BentoTypography: M, RadioInput: w };
|
|
76
|
-
}
|
|
77
|
-
});
|
|
78
|
-
var D = function() {
|
|
79
|
-
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
80
|
-
return o("div", { staticClass: "b-radio-button", class: t.conditionalClassContainer, attrs: { "data-testid": "radio-button-container" } }, [o(t.RadioInput, { attrs: { id: t.radioButtonId, "aria-label": t.ariaLabel, "aria-describedby": t.hasSlot("description") ? t.descriptionId : "", checked: t.isChecked, disabled: e.disabled, readonly: e.readonly, "has-error": e.hasError, value: t.value, "model-value": e.modelValue, name: e.name }, on: { "update:model-value": t.onChange } }), o("div", [t.hasSlot("default") ? o("label", { staticClass: "b-radio-button__label-container", attrs: { for: t.radioButtonId } }, [t.hasSlot("default") ? o("span", { staticClass: "b-radio-button__primary-label" }, [o(t.BentoTypography, { staticClass: "b-radio-button__label", attrs: { el: "span", variant: "body" } }, [e._t("default")], 2), e.tag ? o(t.BentoTag, e._b({ staticClass: "b-radio-button__label-tag" }, "bento-tag", e.tag, !1)) : e._e()], 1) : e._e(), t.hasSlot("default") && t.hasSlot("description") ? o(t.BentoTypography, { staticClass: "b-radio-button__description", attrs: { id: t.descriptionId, el: "span", variant: "body" } }, [e._t("description")], 2) : e._e()], 1) : e._e(), t.hasSlot("content") && t.isChecked ? o(t.BentoTypography, { staticClass: "b-radio-button__content", attrs: { el: "div" } }, [e._t("content")], 2) : e._e()], 1)], 1);
|
|
81
|
-
}, F = [], G = /* @__PURE__ */ B(
|
|
82
|
-
q,
|
|
83
|
-
D,
|
|
84
|
-
F,
|
|
85
|
-
!1,
|
|
86
|
-
null,
|
|
87
|
-
"58d8904d"
|
|
88
|
-
);
|
|
89
|
-
const H = G.exports;
|
|
90
|
-
var u = /* @__PURE__ */ ((r) => (r.HORIZONTAL = "horizontal", r.VERTICAL = "vertical", r))(u || {});
|
|
91
|
-
const P = {
|
|
92
|
-
name: "bento-radio-group",
|
|
93
|
-
model: { prop: "modelValue" }
|
|
94
|
-
}, z = /* @__PURE__ */ v({
|
|
95
|
-
...P,
|
|
96
|
-
props: {
|
|
97
|
-
/**
|
|
98
|
-
* Descriptive supporting text visbile underneath the label.
|
|
99
|
-
*/
|
|
100
|
-
description: { type: String, default: null },
|
|
101
|
-
/**
|
|
102
|
-
* If set to true, renders all bento-radio-buttons in the group in a disabled state.
|
|
103
|
-
*/
|
|
104
|
-
disabled: { type: Boolean, default: !1 },
|
|
105
|
-
/**
|
|
106
|
-
* If passed as a prop, all bento-radio-buttons in an error state and renders the string beneath the buttons.
|
|
107
|
-
*/
|
|
108
|
-
errorMessage: { type: String, default: null },
|
|
109
|
-
/**
|
|
110
|
-
* The form id the radio group is associated with. Defaults to null, as a radio group can also be used standalone.
|
|
111
|
-
*/
|
|
112
|
-
formId: { type: String, default: null },
|
|
113
|
-
/**
|
|
114
|
-
* If set to true, renders all bento-radio-buttons in the group in an error state.
|
|
115
|
-
*
|
|
116
|
-
* @deprecated Use "errorMessage" prop instead
|
|
117
|
-
*/
|
|
118
|
-
hasError: { type: Boolean, default: !1 },
|
|
119
|
-
/**
|
|
120
|
-
* Shows/hides the group label.
|
|
121
|
-
*/
|
|
122
|
-
hideLabel: { type: Boolean, default: null },
|
|
123
|
-
/**
|
|
124
|
-
* The radio group's items.
|
|
125
|
-
*/
|
|
126
|
-
items: {
|
|
127
|
-
type: Array,
|
|
128
|
-
required: !0
|
|
129
|
-
},
|
|
130
|
-
/**
|
|
131
|
-
* The name associated with the group. Required for accessibility purposes.
|
|
132
|
-
*/
|
|
133
|
-
label: { type: String, required: !0 },
|
|
134
|
-
/**
|
|
135
|
-
* Determines the initially selected value of the group. Corresponds to the BentoRadioButtonItem's value.
|
|
136
|
-
* Defaults to no value selected.
|
|
137
|
-
*/
|
|
138
|
-
modelValue: {
|
|
139
|
-
type: [Number, String],
|
|
140
|
-
default: null
|
|
141
|
-
},
|
|
142
|
-
/**
|
|
143
|
-
* Indicates the field is optional.
|
|
144
|
-
*/
|
|
145
|
-
optional: { type: Boolean, default: !1 },
|
|
146
|
-
/**
|
|
147
|
-
* If set to true, renders all bento-radio-button in the group in a readonly state.
|
|
148
|
-
*/
|
|
149
|
-
readonly: { type: Boolean, default: !1 },
|
|
150
|
-
/**
|
|
151
|
-
* Indicates the field is required.
|
|
152
|
-
*/
|
|
153
|
-
required: { type: Boolean, default: !1 },
|
|
154
|
-
/**
|
|
155
|
-
* Tooltip message.
|
|
156
|
-
*/
|
|
157
|
-
tooltipText: { type: String, default: null },
|
|
158
|
-
/**
|
|
159
|
-
* The radio group's layout. It can be vertical or horizontal. Defaults to vertical.
|
|
160
|
-
*/
|
|
161
|
-
variant: {
|
|
162
|
-
type: String,
|
|
163
|
-
default: u.VERTICAL,
|
|
164
|
-
validator: (r) => Object.values(u).includes(r)
|
|
165
|
-
}
|
|
166
|
-
},
|
|
167
|
-
emits: ["input", "update:model-value"],
|
|
168
|
-
setup(r, { emit: e }) {
|
|
169
|
-
const o = r, t = "bento-radio-group", a = S(), l = C(a), p = h(o, "modelValue"), c = b("error"), { isReadOnly: n } = T(h(o, "readonly")), f = s(
|
|
170
|
-
() => !o.disabled && !n.value && (!!o.errorMessage || o.hasError)
|
|
171
|
-
), _ = s(() => !o.disabled && !n.value && !!o.errorMessage), m = s(() => ({
|
|
172
|
-
"b-radio-group__buttons--horizontal": o.variant === u.HORIZONTAL
|
|
173
|
-
})), d = s(() => o.variant === "vertical"), y = s(() => l("content") && !(d != null && d.value)), E = (i) => {
|
|
174
|
-
e("update:model-value", i), e("input", i);
|
|
175
|
-
};
|
|
176
|
-
return o.hasError && L(
|
|
177
|
-
'BentoRadioGroup "hasError" property',
|
|
178
|
-
`Use the BentoRadioGroup "errorMessage" property instead to indicate that there is a modifier error.
|
|
179
|
-
Having the field as "undefined" will hide/remove the error.
|
|
180
|
-
<bento-radio-group errorMessage="Error message text" />`,
|
|
181
|
-
"2.0.0"
|
|
182
|
-
), R(
|
|
183
|
-
y,
|
|
184
|
-
(i) => {
|
|
185
|
-
if (i)
|
|
186
|
-
throw new Error("The content slot is only available for the vertical radio group layout");
|
|
187
|
-
},
|
|
188
|
-
{
|
|
189
|
-
immediate: !0
|
|
190
|
-
}
|
|
191
|
-
), { __sfc: !0, COMPONENT_NAME: t, slots: a, hasSlot: l, emit: e, props: o, inputValue: p, errorId: c, isReadOnly: n, shouldShowError: f, shouldShowErrorMessage: _, conditionalClasses: m, isVertical: d, shouldShowSlotError: y, onInput: E, ControlsGroup: A, ErrorMessage: k, BentoRadioButton: H };
|
|
192
|
-
}
|
|
193
|
-
});
|
|
194
|
-
var j = function() {
|
|
195
|
-
var e = this, o = e._self._c, t = e._self._setupProxy;
|
|
196
|
-
return o("div", { staticClass: "b-radio-group" }, [o(t.ControlsGroup, { staticClass: "b-radio-group__buttons", class: t.conditionalClasses, attrs: { "aria-describedby": t.shouldShowErrorMessage ? t.errorId : "", "component-name": t.COMPONENT_NAME, description: e.description, disabled: e.disabled, form: e.formId, label: e.label, optional: e.optional, required: e.required, "hide-label": e.hideLabel, "tooltip-text": e.tooltipText } }, e._l(e.items, function(a) {
|
|
197
|
-
return o(t.BentoRadioButton, { key: a.value, attrs: { "model-value": t.inputValue, value: a.value, disabled: e.disabled || a.disabled, readonly: t.isReadOnly || a.readonly, "has-error": t.shouldShowError || a.hasError, tag: a.tag, name: e.formId || e.label }, on: { "update:model-value": t.onInput }, scopedSlots: e._u([{ key: "default", fn: function() {
|
|
198
|
-
return [e._v(e._s(a.label))];
|
|
199
|
-
}, proxy: !0 }, a.description ? { key: "description", fn: function() {
|
|
200
|
-
return [e._v(e._s(a.description))];
|
|
201
|
-
}, proxy: !0 } : null, t.hasSlot("content") && t.isVertical ? { key: "content", fn: function() {
|
|
202
|
-
return [e._t("content")];
|
|
203
|
-
}, proxy: !0 } : null], null, !0) });
|
|
204
|
-
}), 1), t.shouldShowErrorMessage ? o(t.ErrorMessage, { staticClass: "b-radio-group__error-message", attrs: { id: t.errorId, "error-message": e.errorMessage } }) : e._e()], 1);
|
|
205
|
-
}, U = [], Z = /* @__PURE__ */ B(
|
|
206
|
-
z,
|
|
207
|
-
j,
|
|
208
|
-
U,
|
|
209
|
-
!1,
|
|
210
|
-
null,
|
|
211
|
-
"e1dc2c5c"
|
|
212
|
-
);
|
|
213
|
-
const ne = Z.exports;
|
|
214
|
-
export {
|
|
215
|
-
ne as B,
|
|
216
|
-
u as a,
|
|
217
|
-
H as b
|
|
218
|
-
};
|
|
219
|
-
//# sourceMappingURL=radio-group.DMob8x2J.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"radio-group.DMob8x2J.js","sources":["../../src/components/radio-group/components/radio-button/radio-button.vue","../../src/components/radio-group/radio-group.types.ts","../../src/components/radio-group/radio-group.vue"],"sourcesContent":["<template>\n <div class=\"b-radio-button\" data-testid=\"radio-button-container\" :class=\"conditionalClassContainer\">\n <radio-input\n :id=\"radioButtonId\"\n :aria-label=\"ariaLabel\"\n :aria-describedby=\"hasSlot('description') ? descriptionId : ''\"\n :checked=\"isChecked\"\n :disabled=\"disabled\"\n :readonly=\"readonly\"\n :has-error=\"hasError\"\n :value=\"value\"\n :model-value=\"modelValue\"\n :name=\"name\"\n @update:model-value=\"onChange\"\n />\n <div>\n <label v-if=\"hasSlot('default')\" :for=\"radioButtonId\" class=\"b-radio-button__label-container\">\n <span v-if=\"hasSlot('default')\" class=\"b-radio-button__primary-label\">\n <bento-typography class=\"b-radio-button__label\" el=\"span\" variant=\"body\"><slot /></bento-typography>\n <bento-tag v-if=\"tag\" class=\"b-radio-button__label-tag\" v-bind=\"tag\" />\n </span>\n <bento-typography\n v-if=\"hasSlot('default') && hasSlot('description')\"\n :id=\"descriptionId\"\n class=\"b-radio-button__description\"\n el=\"span\"\n variant=\"body\"\n >\n <slot name=\"description\"></slot>\n </bento-typography>\n </label>\n <bento-typography v-if=\"hasSlot('content') && isChecked\" class=\"b-radio-button__content\" el=\"div\">\n <slot name=\"content\"></slot>\n </bento-typography>\n </div>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoTag } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n import { RadioInput } from '../../../internal/radio-input';\n import { useAriaLabel } from '@/utils/ts/aria-label';\n import { generateUid } from '@/core/utils/ts';\n import { computed, ComputedRef, PropType, toRefs, useSlots } from 'vue';\n import { useDefaultSlotValidator, useHasSlot } from '@/composables';\n import { BentoRadioButtonStateClass, BentoRadioButtonTag, BentoRadioButtonValue } from './radio-button.types';\n import { getSlotText } from '@/utils/ts/get-slot-text';\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const props = defineProps({\n /**\n * Disable the radio button (optional)\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * Shows bento-radio-button in error state (optional)\n */\n hasError: { type: Boolean, default: false },\n\n /**\n * This property should not be used directly.\n * It will be used by v-model directive on radio component.\n */\n modelValue: {\n type: [String, Number] as PropType<BentoRadioButtonValue>,\n default: null,\n },\n\n /**\n * Sets the radio button to readonly (optional)\n */\n readonly: { type: Boolean, default: false },\n\n /**\n * Sets the properties of the BentoTag component that is placed next to the label.\n * {@see BentoTag}\n */\n tag: { type: Object as PropType<BentoRadioButtonTag>, default: undefined },\n\n /**\n * Indicates the value of the input that will be returned when it's checked\n */\n value: {\n type: [String, Number] as PropType<BentoRadioButtonValue>,\n required: true,\n },\n\n /**\n * Sets the name of the radio input.\n * Used for differentiating radio groups or accessing input via form submission.\n */\n name: {\n type: String,\n default: null,\n },\n });\n\n const emit = defineEmits([\"input\", \"update:model-value\"]);\n\n const { value } = toRefs(props);\n const radioButtonId = generateUid('bento-radio-button');\n const descriptionId = generateUid('description');\n\n useDefaultSlotValidator('bento-radio-button', slots.default, slots.description);\n\n const conditionalClassContainer = computed(() => ({\n [`b-radio-button--${BentoRadioButtonStateClass.DISABLED}`]: props.disabled,\n [`b-radio-button--${BentoRadioButtonStateClass.READONLY}`]: props.readonly,\n }));\n\n const ariaLabel = useAriaLabel({\n ariaLabel: getSlotText(slots)('default'),\n label: value.value as string,\n });\n\n const isChecked: ComputedRef<boolean> = computed(() => props.value === props.modelValue);\n\n const onChange = () => {\n if (!props.disabled && !props.readonly) {\n emit('update:model-value', props.value);\n emit('input', props.value);\n }\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * Radio buttons are used when two or more options are mutually exclusive,\n * the user can only select a single option from a list of pre-defined options.\n * The label tag area is also clickable.\n * Only to be used internally.\n *\n * @example\n * import { BentoRadioButton } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoRadioButton },\n * template: `\n * <bento-radio-button\n * disabled\n * value=\"inputRadio\"\n * model-value.sync=\"modelValue\"\n * >\n * Label text\n * <template #description>Description text below label</template>\n * <template #content>Content shown when checked</template>\n * </bento-radio-button>\n * `,\n * setup() {\n * const modelValue = ref('anyValue')\n * const value = 'option-value'\n *\n * return {\n * modelValue,\n * value,\n * }\n * }\n * }\n */\n export default {\n name: 'bento-radio-button',\n model: { prop: 'modelValue' },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./radio-button.scss\" />\n","import type { BentoRadioButtonTag, BentoRadioButtonValue } from './components/radio-button';\n\n/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoRadioGroupVariant {\n HORIZONTAL = 'horizontal',\n VERTICAL = 'vertical',\n}\n\nexport type BentoRadioGroupValue = BentoRadioButtonValue;\n\nexport interface BentoRadioGroupItem {\n value: BentoRadioGroupValue;\n label: string;\n description?: string;\n disabled?: boolean;\n readonly?: boolean;\n hasError?: boolean;\n tag?: BentoRadioButtonTag;\n}\n\nexport type BentoRadioGroupItems = Array<BentoRadioGroupItem>;\n","<template>\n <div class=\"b-radio-group\">\n <controls-group\n class=\"b-radio-group__buttons\"\n :aria-describedby=\"shouldShowErrorMessage ? errorId : ''\"\n :component-name=\"COMPONENT_NAME\"\n :class=\"conditionalClasses\"\n :description=\"description\"\n :disabled=\"disabled\"\n :form=\"formId\"\n :label=\"label\"\n :optional=\"optional\"\n :required=\"required\"\n :hide-label=\"hideLabel\"\n :tooltip-text=\"tooltipText\"\n >\n <bento-radio-button\n v-for=\"item in items\"\n :key=\"item.value\"\n :model-value=\"inputValue\"\n :value=\"item.value\"\n :disabled=\"disabled || item.disabled\"\n :readonly=\"isReadOnly || item.readonly\"\n :has-error=\"shouldShowError || item.hasError\"\n :tag=\"item.tag\"\n :name=\"formId || label\"\n @update:model-value=\"onInput\"\n >\n <template #default>{{ item.label }}</template>\n <template v-if=\"item.description\" #description>{{ item.description }}</template>\n <template v-if=\"hasSlot('content') && isVertical\" #content>\n <slot name=\"content\"></slot>\n </template>\n </bento-radio-button>\n </controls-group>\n <error-message\n v-if=\"shouldShowErrorMessage\"\n :id=\"errorId\"\n :error-message=\"errorMessage\"\n class=\"b-radio-group__error-message\"\n />\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, PropType, toRef, useSlots, watch } from 'vue';\n import { ControlsGroup, ErrorMessage } from '@/components/internal';\n import { BentoRadioButton } from './components/radio-button';\n import { useHasSlot } from '@/composables';\n import { generateUid } from '@/core/utils/ts';\n import { deprecate } from '@/utils/ts/deprecate';\n import { BentoRadioGroupItems, BentoRadioGroupValue, BentoRadioGroupVariant } from './radio-group.types';\n import { useFormLayoutFieldLoading } from '@/composables/use-form-layout-loading/use-form-layout-loading';\n\n /**\n * The name of the component to be used in the Vue devtools and console warnings.\n */\n const COMPONENT_NAME = 'bento-radio-group';\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n\n const emit = defineEmits([\"input\", \"update:model-value\"]);\n\n const props = defineProps({\n /**\n * Descriptive supporting text visbile underneath the label.\n */\n description: { type: String, default: null },\n\n /**\n * If set to true, renders all bento-radio-buttons in the group in a disabled state.\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * If passed as a prop, all bento-radio-buttons in an error state and renders the string beneath the buttons.\n */\n errorMessage: { type: String, default: null },\n\n /**\n * The form id the radio group is associated with. Defaults to null, as a radio group can also be used standalone.\n */\n formId: { type: String, default: null },\n\n /**\n * If set to true, renders all bento-radio-buttons in the group in an error state.\n *\n * @deprecated Use \"errorMessage\" prop instead\n */\n hasError: { type: Boolean, default: false },\n\n /**\n * Shows/hides the group label.\n */\n hideLabel: { type: Boolean, default: null },\n\n /**\n * The radio group's items.\n */\n items: {\n type: Array as PropType<BentoRadioGroupItems>,\n required: true,\n },\n\n /**\n * The name associated with the group. Required for accessibility purposes.\n */\n label: { type: String, required: true },\n\n /**\n * Determines the initially selected value of the group. Corresponds to the BentoRadioButtonItem's value.\n * Defaults to no value selected.\n */\n modelValue: {\n type: [Number, String] as PropType<BentoRadioGroupValue>,\n default: null,\n },\n\n /**\n * Indicates the field is optional.\n */\n optional: { type: Boolean, default: false },\n\n /**\n * If set to true, renders all bento-radio-button in the group in a readonly state.\n */\n readonly: { type: Boolean, default: false },\n\n /**\n * Indicates the field is required.\n */\n required: { type: Boolean, default: false },\n\n /**\n * Tooltip message.\n */\n tooltipText: { type: String, default: null },\n\n /**\n * The radio group's layout. It can be vertical or horizontal. Defaults to vertical.\n */\n variant: {\n type: String as PropType<BentoRadioGroupVariant | `${BentoRadioGroupVariant}`>,\n default: BentoRadioGroupVariant.VERTICAL,\n validator: (value: BentoRadioGroupVariant) => Object.values(BentoRadioGroupVariant).includes(value),\n },\n });\n\n const inputValue = toRef(props, 'modelValue');\n const errorId = generateUid('error');\n const { isReadOnly } = useFormLayoutFieldLoading(toRef(props, 'readonly'));\n\n const shouldShowError = computed(\n () => !props.disabled && !isReadOnly.value && (!!props.errorMessage || props.hasError)\n );\n const shouldShowErrorMessage = computed(() => !props.disabled && !isReadOnly.value && !!props.errorMessage);\n\n const conditionalClasses = computed(() => ({\n 'b-radio-group__buttons--horizontal': props.variant === BentoRadioGroupVariant.HORIZONTAL,\n }));\n\n // Content slot logic\n const isVertical = computed(() => props.variant === 'vertical');\n const shouldShowSlotError = computed(() => hasSlot('content') && !isVertical?.value);\n\n const onInput = value => {\n emit('update:model-value', value);\n emit('input', value);\n };\n\n if (props.hasError) {\n deprecate(\n 'BentoRadioGroup \"hasError\" property',\n `Use the BentoRadioGroup \"errorMessage\" property instead to indicate that there is a modifier error.\n Having the field as \"undefined\" will hide/remove the error.\n <bento-radio-group errorMessage=\"Error message text\" />`,\n '2.0.0'\n );\n }\n\n watch(\n shouldShowSlotError,\n newVal => {\n if (newVal) {\n throw new Error('The content slot is only available for the vertical radio group layout');\n }\n },\n {\n immediate: true,\n }\n );\n</script>\n\n<script lang=\"ts\">\n /**\n * A radio group component should be used whenever it is necessary to use a set of radio buttons\n * This component conforms to the official WAI-ARIA guidelines for grouping controls: https://www.w3.org/WAI/tutorials/forms/grouping/\n *\n * import { BentoRadioGroup } from '@adyen/bento-vue2/';\n *\n * export default {\n * components: { BentoRadioGroup },\n * template: `\n * <bento-radio-group\n * label=\"Your group label\"\n * :items=\"[\n * { value: 1, label: 'Your label' },\n * { value: 2, label: 'Another label', description: 'Your descriptive sub label' },\n * ]\"\n * variant=\"horizontal\"\n * />\n * `\n * };\n */\n export default {\n name: 'bento-radio-group',\n model: { prop: 'modelValue' },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./radio-group.scss\" />\n"],"names":["__default__$1","slots","useSlots","hasSlot","useHasSlot","value","toRefs","props","radioButtonId","generateUid","descriptionId","useDefaultSlotValidator","conditionalClassContainer","computed","RadioInputStateClass","ariaLabel","useAriaLabel","getSlotText","isChecked","emit","BentoRadioGroupVariant","BentoRadioGroupVariant2","__default__","COMPONENT_NAME","inputValue","toRef","errorId","isReadOnly","useFormLayoutFieldLoading","shouldShowError","shouldShowErrorMessage","conditionalClasses","isVertical","shouldShowSlotError","onInput","deprecate","watch","newVal"],"mappings":";;;;;;;;;;;;;;AAkKI,MAAAA,IAAA;AAAA,EAAe,MAAA;AAAA,EACL,OAAA,EAAA,MAAA,aAAA;AAEV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBApHAC,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GAoDA,EAAA,OAAAI,EAAA,IAAAC,EAAAC,CAAA,GACAC,IAAAC,EAAA,oBAAA,GACAC,IAAAD,EAAA,aAAA;AAEA,IAAAE,EAAA,sBAAAV,EAAA,SAAAA,EAAA,WAAA;AAEA,UAAAW,IAAAC,EAAA,OAAA;AAAA,MAAkD,CAAA,mBAAAC,EAAA,QAAA,EAAA,GAAAP,EAAA;AAAA,MACoB,CAAA,mBAAAO,EAAA,QAAA,EAAA,GAAAP,EAAA;AAAA,IACA,EAAA,GAGtEQ,IAAAC,EAAA;AAAA,MAA+B,WAAAC,EAAAhB,CAAA,EAAA,SAAA;AAAA,MACY,OAAAI,EAAA;AAAA,IAC1B,CAAA,GAGjBa,IAAAL,EAAA,MAAAN,EAAA,UAAAA,EAAA,UAAA;mLAEA,MAAA;AACI,MAAA,CAAAA,EAAA,YAAA,CAAAA,EAAA,aACIY,EAAA,sBAAAZ,EAAA,KAAA,GACAY,EAAA,SAAAZ,EAAA,KAAA;AAAA,IACJ;;;;;;;;;;;;;;;ACvHI,IAAAa,IAAA,kBAAAC,OACRA,EAAA,aAAA,cACAA,EAAA,WAAA,YAFQA,IAAAD,KAAA,CAAA,CAAA;ACkNR,MAAAE,IAAA;AAAA,EAAe,MAAA;AAAA,EACL,OAAA,EAAA,MAAA,aAAA;AAEV;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAjKAC,IAAA,qBAEAtB,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GAyFAuB,IAAAC,EAAAlB,GAAA,YAAA,GACAmB,IAAAjB,EAAA,OAAA,GACA,EAAA,YAAAkB,EAAA,IAAAC,EAAAH,EAAAlB,GAAA,UAAA,CAAA,GAEAsB,IAAAhB;AAAA,MAAwB,MAAA,CAAAN,EAAA,YAAA,CAAAoB,EAAA,UAAA,CAAA,CAAApB,EAAA,gBAAAA,EAAA;AAAA,IACyD,GAEjFuB,IAAAjB,EAAA,MAAA,CAAAN,EAAA,YAAA,CAAAoB,EAAA,SAAA,CAAA,CAAApB,EAAA,YAAA,GAEAwB,IAAAlB,EAAA,OAAA;AAAA,MAA2C,sCAAAN,EAAA,YAAAa,EAAA;AAAA,IACwC,EAAA,GAInFY,IAAAnB,EAAA,MAAAN,EAAA,YAAA,UAAA,GACA0B,IAAApB,EAAA,MAAAV,EAAA,SAAA,KAAA,EAAA6B,KAAA,QAAAA,EAAA,MAAA,GAEAE,IAAA,CAAA7B,MAAA;AACI,MAAAc,EAAA,sBAAAd,CAAA,GACAc,EAAA,SAAAd,CAAA;AAAA,IAAmB;AAGvB,WAAAE,EAAA,YACI4B;AAAA,MAAA;AAAA,MACI;AAAA;AAAA;AAAA,MACA;AAAA,IAGA,GAIRC;AAAA,MAAAH;AAAA,MACI,CAAAI,MAAA;AAEI,YAAAA;AACI,gBAAA,IAAA,MAAA,wEAAA;AAAA,MACJ;AAAA,MACJ;AAAA,QACA,WAAA;AAAA,MACe;AAAA,IACf;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"status.types.Cv6hHRMu.js","sources":["../../src/components/status/status.vue","../../src/components/status/status.types.ts"],"sourcesContent":["<template>\n <div class=\"b-status\" role=\"status\">\n <div class=\"b-status__indicator-wrapper\">\n <span class=\"b-status__indicator\" :class=\"conditionalClass\" role=\"presentation\"></span>\n </div>\n <bento-typography class=\"b-status__label\" el=\"span\" variant=\"body\">\n <slot></slot>\n </bento-typography>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { BentoStatusVariant } from './status.types';\n\n const props = defineProps({\n variant: null\n});\n\n const conditionalClass = computed(() => ({\n [`b-status__indicator--${props.variant}`]: true,\n }));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Status component is used to indicate a\n * passage of time or a particular step of a process.\n *\n * @example\n * import { BentoStatus } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStatus },\n * template: `\n * <bento-status variant=\"red\">\n * 1 week ago\n * </bento-status>\n * `\n * }\n */\n export default {\n name: 'bento-status',\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./status.scss\" />\n","/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoStatusVariant {\n BLUE = 'blue',\n GREEN = 'green',\n GREY = 'grey',\n ORANGE = 'orange',\n RED = 'red',\n YELLOW = 'yellow',\n}\n"],"names":["__default__","conditionalClass","computed","props","BentoStatusVariant","BentoStatusVariant2"],"mappings":";;;;AA0CI,MAAAA,IAAA;AAAA,EAAe,MAAA;AAEf;;;;;;iBAxBAC,IAAAC,EAAA,OAAA;AAAA,MAAyC,CAAA,wBAAAC,EAAA,OAAA,EAAA,GAAA;AAAA,IACM,EAAA;;;;;;;;;;;;;;;;AClBvC,IAAAC,IAAA,kBAAAC,OACRA,EAAA,OAAA,QACAA,EAAA,QAAA,SACAA,EAAA,OAAA,QACAA,EAAA,SAAA,UACAA,EAAA,MAAA,OACAA,EAAA,SAAA,UANQA,IAAAD,KAAA,CAAA,CAAA;"}
|