@adyen/bento-vue3 1.77.1 → 1.78.1

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.
Files changed (106) hide show
  1. package/dist/@types/index.d.ts +145 -99
  2. package/dist/assets/accordion-item.css +1 -1
  3. package/dist/assets/action-bar.css +1 -1
  4. package/dist/assets/base-modal.css +1 -1
  5. package/dist/assets/button-actions.css +1 -1
  6. package/dist/assets/card.css +1 -1
  7. package/dist/assets/checkbox-group.css +1 -1
  8. package/dist/assets/data-grid.css +1 -1
  9. package/dist/assets/date-range-picker.css +1 -1
  10. package/dist/assets/dialog-page.css +1 -1
  11. package/dist/assets/file-uploader.css +1 -1
  12. package/dist/assets/filter-bar.css +1 -1
  13. package/dist/assets/index.css +1 -0
  14. package/dist/assets/inspector.css +1 -1
  15. package/dist/assets/modal-fullscreen.css +1 -1
  16. package/dist/assets/radio-group.css +1 -1
  17. package/dist/assets/selection-card-group.css +1 -1
  18. package/dist/assets/sidepanel.css +1 -1
  19. package/dist/checkbox.js +2 -2
  20. package/dist/chunks/checkbox-group.B-qxqvNL.js +176 -0
  21. package/dist/chunks/checkbox-group.B-qxqvNL.js.map +1 -0
  22. package/dist/chunks/{checkbox.SffuKyNj.js → checkbox.8m_kxm2B.js} +18 -18
  23. package/dist/chunks/{checkbox.SffuKyNj.js.map → checkbox.8m_kxm2B.js.map} +1 -1
  24. package/dist/chunks/{code-snippet.ByoBEM00.js → code-snippet.B5NUDrZ-.js} +2 -2
  25. package/dist/chunks/{code-snippet.ByoBEM00.js.map → code-snippet.B5NUDrZ-.js.map} +1 -1
  26. package/dist/chunks/{data-grid.CMIG82Xt.js → data-grid.CC3OZcgU.js} +574 -569
  27. package/dist/chunks/data-grid.CC3OZcgU.js.map +1 -0
  28. package/dist/chunks/{date-picker.CsGq3iSK.js → date-picker.x9GeC_UO.js} +2 -2
  29. package/dist/chunks/{date-picker.CsGq3iSK.js.map → date-picker.x9GeC_UO.js.map} +1 -1
  30. package/dist/chunks/date-range-picker.CXeFdxAA.js +1100 -0
  31. package/dist/chunks/date-range-picker.CXeFdxAA.js.map +1 -0
  32. package/dist/chunks/date-range-picker.types.Ckt7zxGy.js +5 -0
  33. package/dist/chunks/date-range-picker.types.Ckt7zxGy.js.map +1 -0
  34. package/dist/chunks/{dropdown-tag.B90dpg8J.js → dropdown-tag.DIlF7mOi.js} +3 -3
  35. package/dist/chunks/{dropdown-tag.B90dpg8J.js.map → dropdown-tag.DIlF7mOi.js.map} +1 -1
  36. package/dist/chunks/{dropdown.DYDHM__3.js → dropdown.CdsjtT9_.js} +2 -2
  37. package/dist/chunks/{dropdown.DYDHM__3.js.map → dropdown.CdsjtT9_.js.map} +1 -1
  38. package/dist/chunks/es6.MoTTyETW.js.map +1 -1
  39. package/dist/chunks/{file-uploader.BDXQ7Ccv.js → file-uploader.R0NZXIsS.js} +2 -2
  40. package/dist/chunks/{file-uploader.BDXQ7Ccv.js.map → file-uploader.R0NZXIsS.js.map} +1 -1
  41. package/dist/chunks/{filter-bar.CmF92iAr.js → filter-bar.CvSdAVYh.js} +84 -84
  42. package/dist/chunks/filter-bar.CvSdAVYh.js.map +1 -0
  43. package/dist/chunks/form-field.D_2g7vaP.js +10 -0
  44. package/dist/chunks/{form-field.BBqLu-vs.js.map → form-field.D_2g7vaP.js.map} +1 -1
  45. package/dist/chunks/{header-with-views.xPfeOz0Y.js → header-with-views.ggjZJvKA.js} +3 -3
  46. package/dist/chunks/{header-with-views.xPfeOz0Y.js.map → header-with-views.ggjZJvKA.js.map} +1 -1
  47. package/dist/chunks/{input-field-password.BZBYVyAb.js → input-field-password.-xEY2VB8.js} +3 -3
  48. package/dist/chunks/{input-field-password.BZBYVyAb.js.map → input-field-password.-xEY2VB8.js.map} +1 -1
  49. package/dist/chunks/{input-field-phone-number.a8Mw5PAW.js → input-field-phone-number.DcxhP_qK.js} +3 -3
  50. package/dist/chunks/{input-field-phone-number.a8Mw5PAW.js.map → input-field-phone-number.DcxhP_qK.js.map} +1 -1
  51. package/dist/chunks/{input-field.CYGGIK48.js → input-field.B6nL7d8O.js} +2 -2
  52. package/dist/chunks/{input-field.CYGGIK48.js.map → input-field.B6nL7d8O.js.map} +1 -1
  53. package/dist/chunks/{pagination.CYdGcyMA.js → pagination.DCn_tenp.js} +2 -2
  54. package/dist/chunks/{pagination.CYdGcyMA.js.map → pagination.DCn_tenp.js.map} +1 -1
  55. package/dist/chunks/{radio-group.B_8R6vGx.js → radio-group.Br-N309Y.js} +102 -101
  56. package/dist/chunks/radio-group.Br-N309Y.js.map +1 -0
  57. package/dist/chunks/{rich-text-editor.B6Ftqv55.js → rich-text-editor.CkuTqHGk.js} +2 -2
  58. package/dist/chunks/{rich-text-editor.B6Ftqv55.js.map → rich-text-editor.CkuTqHGk.js.map} +1 -1
  59. package/dist/chunks/{search-bar.D3Ri_RUK.js → search-bar.BmNEcy0L.js} +3 -3
  60. package/dist/chunks/{search-bar.D3Ri_RUK.js.map → search-bar.BmNEcy0L.js.map} +1 -1
  61. package/dist/chunks/{secondary-nav.CAb20jWW.js → secondary-nav.CPosCncv.js} +2 -2
  62. package/dist/chunks/{secondary-nav.CAb20jWW.js.map → secondary-nav.CPosCncv.js.map} +1 -1
  63. package/dist/chunks/selection-card-group.bur3Z8vZ.js +415 -0
  64. package/dist/chunks/{selection-card-group.F8alOPtl.js.map → selection-card-group.bur3Z8vZ.js.map} +1 -1
  65. package/dist/chunks/{textarea.C_gnXj6b.js → textarea.XRETLCSj.js} +2 -2
  66. package/dist/chunks/{textarea.C_gnXj6b.js.map → textarea.XRETLCSj.js.map} +1 -1
  67. package/dist/chunks/{timeline-item.rSY0Xce3.js → timeline-item.19zg_gBi.js} +2 -2
  68. package/dist/chunks/{timeline-item.rSY0Xce3.js.map → timeline-item.19zg_gBi.js.map} +1 -1
  69. package/dist/code-snippet.js +1 -1
  70. package/dist/data-grid.js +1 -1
  71. package/dist/date-picker.js +1 -1
  72. package/dist/date-range-picker.js +5 -4
  73. package/dist/date-range-picker.js.map +1 -1
  74. package/dist/dropdown.js +2 -2
  75. package/dist/file-uploader.js +1 -1
  76. package/dist/filter-bar.js +1 -1
  77. package/dist/header-with-views.js +1 -1
  78. package/dist/index.js +381 -356
  79. package/dist/index.js.map +1 -1
  80. package/dist/input-field-password.js +1 -1
  81. package/dist/input-field-phone-number.js +1 -1
  82. package/dist/input-field.js +1 -1
  83. package/dist/pagination.js +1 -1
  84. package/dist/radio-group.js +1 -1
  85. package/dist/rich-text-editor.js +1 -1
  86. package/dist/search-bar.js +2 -2
  87. package/dist/secondary-nav.js +1 -1
  88. package/dist/selection-card.js +1 -1
  89. package/dist/styles/bento-dark.css +5 -0
  90. package/dist/styles/bento-light.css +5 -0
  91. package/dist/styles/bento.css +5 -0
  92. package/dist/styles/legacy.css +5 -0
  93. package/dist/styles/styleguide.css +5 -0
  94. package/dist/textarea.js +1 -1
  95. package/dist/timeline.js +1 -1
  96. package/dist/web-types.json +1 -1
  97. package/package.json +6 -6
  98. package/dist/chunks/checkbox-group.COUx8Ne8.js +0 -192
  99. package/dist/chunks/checkbox-group.COUx8Ne8.js.map +0 -1
  100. package/dist/chunks/data-grid.CMIG82Xt.js.map +0 -1
  101. package/dist/chunks/date-range-picker.C19CWG27.js +0 -1149
  102. package/dist/chunks/date-range-picker.C19CWG27.js.map +0 -1
  103. package/dist/chunks/filter-bar.CmF92iAr.js.map +0 -1
  104. package/dist/chunks/form-field.BBqLu-vs.js +0 -10
  105. package/dist/chunks/radio-group.B_8R6vGx.js.map +0 -1
  106. package/dist/chunks/selection-card-group.F8alOPtl.js +0 -412
@@ -1,25 +1,26 @@
1
- import { defineComponent as q, useSlots as D, toRefs as G, ref as H, computed as u, createElementBlock as h, openBlock as l, normalizeClass as U, createVNode as V, createElementVNode as P, unref as e, createCommentVNode as p, createBlock as g, withCtx as n, renderSlot as B, mergeProps as Z, toRef as M, watch as j, createSlots as $, Fragment as Y, renderList as J, createTextVNode as O, toDisplayString as w } from "vue";
2
- import { u as K } from "./use-form-layout-loading.D3lALhtC.js";
3
- import { u as z } from "./use-has-slot.B7eQSabc.js";
4
- import { g as L } from "./generate-uid.NJ8tVoha.js";
5
- import { B as C, d as Q } from "./typography.yBEME_Gu.js";
6
- import { C as W } from "./controls-group.cbGiHr7n.js";
7
- import { B as X } from "./tag.CjaB9DxL.js";
8
- import { u as x } from "./aria-label.CaUURpnB.js";
9
- import { u as ee } from "./use-default-slot-validator.O02rzsob.js";
10
- import { g as oe } from "./get-slot-text.CQRAP2_q.js";
11
- import { R as A, a as ae } from "./radio-input.CBNE-AkM.js";
12
- import { _ as F } from "./_plugin-vue_export-helper.CHgC5LLL.js";
13
- import { E as te } from "./field-label.C97CrBI_.js";
1
+ import { defineComponent as q, useSlots as D, toRefs as P, ref as F, computed as c, createElementBlock as b, openBlock as l, normalizeClass as U, createVNode as R, createElementVNode as Z, unref as e, createCommentVNode as f, createBlock as v, withCtx as i, renderSlot as y, mergeProps as j, toRef as M, watch as Y, createSlots as $, Fragment as J, renderList as K, createTextVNode as O, toDisplayString as w } from "vue";
2
+ import { u as Q } from "./use-form-layout-loading.D3lALhtC.js";
3
+ import { u as H } from "./use-has-slot.B7eQSabc.js";
4
+ import { g as C } from "./generate-uid.NJ8tVoha.js";
5
+ import { B as V, d as W } from "./typography.yBEME_Gu.js";
6
+ import { u as X } from "./form-field.D_2g7vaP.js";
7
+ import { C as x } from "./controls-group.cbGiHr7n.js";
8
+ import { B as ee } from "./tag.CjaB9DxL.js";
9
+ import { u as oe } from "./aria-label.CaUURpnB.js";
10
+ import { u as ae } from "./use-default-slot-validator.O02rzsob.js";
11
+ import { g as te } from "./get-slot-text.CQRAP2_q.js";
12
+ import { R as A, a as re } from "./radio-input.CBNE-AkM.js";
13
+ import { _ as z } from "./_plugin-vue_export-helper.CHgC5LLL.js";
14
+ import { E as le } from "./field-label.C97CrBI_.js";
14
15
  import "../assets/radio-group.css";
15
- const re = ["for"], le = {
16
+ const de = ["for"], se = {
16
17
  key: 0,
17
18
  class: "b-radio-button__primary-label"
18
- }, de = {
19
+ }, ne = {
19
20
  name: "bento-radio-button",
20
21
  model: { prop: "modelValue" }
21
- }, se = /* @__PURE__ */ q({
22
- ...de,
22
+ }, ie = /* @__PURE__ */ q({
23
+ ...ne,
23
24
  props: {
24
25
  /**
25
26
  * Disable the radio button (optional)
@@ -63,96 +64,96 @@ const re = ["for"], le = {
63
64
  }
64
65
  },
65
66
  emits: ["input", "update:model-value"],
66
- setup(a, { expose: k, emit: I }) {
67
- const c = D(), s = z(c), t = a, f = I, { value: r } = G(t), _ = L("bento-radio-button"), b = L("description"), i = H(null);
68
- ee("bento-radio-button", c.default, c.description);
69
- const E = u(() => ({
67
+ setup(a, { expose: k, emit: S }) {
68
+ const p = D(), s = H(p), t = a, h = S, { value: r } = P(t), g = C("bento-radio-button"), m = C("description"), u = F(null);
69
+ ae("bento-radio-button", p.default, p.description);
70
+ const I = c(() => ({
70
71
  [`b-radio-button--${A.DISABLED}`]: t.disabled,
71
72
  [`b-radio-button--${A.READONLY}`]: t.readonly
72
- })), S = x({
73
- ariaLabel: oe(c)("default"),
73
+ })), B = oe({
74
+ ariaLabel: te(p)("default"),
74
75
  label: r.value
75
- }), m = u(() => t.value === t.modelValue), R = () => {
76
- !t.disabled && !t.readonly && (f("update:model-value", t.value), f("input", t.value));
76
+ }), _ = c(() => t.value === t.modelValue), E = () => {
77
+ !t.disabled && !t.readonly && (h("update:model-value", t.value), h("input", t.value));
77
78
  };
78
79
  return k({
79
80
  focus: () => {
80
- i.value.focus();
81
+ u.value.focus();
81
82
  }
82
- }), (y, T) => (l(), h("div", {
83
- class: U(["b-radio-button", E.value]),
83
+ }), (n, T) => (l(), b("div", {
84
+ class: U(["b-radio-button", I.value]),
84
85
  "data-testid": "radio-button-container"
85
86
  }, [
86
- V(e(ae), {
87
- id: e(_),
87
+ R(e(re), {
88
+ id: e(g),
88
89
  ref_key: "radioInputRef",
89
- ref: i,
90
- "aria-label": e(S),
91
- "aria-describedby": e(s)("description") ? e(b) : "",
92
- checked: m.value,
90
+ ref: u,
91
+ "aria-label": e(B),
92
+ "aria-describedby": e(s)("description") ? e(m) : "",
93
+ checked: _.value,
93
94
  disabled: a.disabled,
94
95
  readonly: a.readonly,
95
96
  "has-error": a.hasError,
96
97
  value: e(r),
97
98
  "model-value": a.modelValue,
98
99
  name: a.name,
99
- "onUpdate:modelValue": R
100
+ "onUpdate:modelValue": E
100
101
  }, null, 8, ["id", "aria-label", "aria-describedby", "checked", "disabled", "readonly", "has-error", "value", "model-value", "name"]),
101
- P("div", null, [
102
- e(s)("default") ? (l(), h("label", {
102
+ Z("div", null, [
103
+ e(s)("default") ? (l(), b("label", {
103
104
  key: 0,
104
- for: e(_),
105
+ for: e(g),
105
106
  class: "b-radio-button__label-container"
106
107
  }, [
107
- e(s)("default") ? (l(), h("span", le, [
108
- V(e(C), {
108
+ e(s)("default") ? (l(), b("span", se, [
109
+ R(e(V), {
109
110
  class: "b-radio-button__label",
110
111
  el: "span",
111
112
  variant: "body"
112
113
  }, {
113
- default: n(() => [
114
- B(y.$slots, "default", {}, void 0, !0)
114
+ default: i(() => [
115
+ y(n.$slots, "default", {}, void 0, !0)
115
116
  ]),
116
117
  _: 3
117
118
  }),
118
- a.tag ? (l(), g(e(X), Z({
119
+ a.tag ? (l(), v(e(ee), j({
119
120
  key: 0,
120
121
  class: "b-radio-button__label-tag"
121
- }, a.tag), null, 16)) : p("", !0)
122
- ])) : p("", !0),
123
- e(s)("default") && e(s)("description") ? (l(), g(e(C), {
122
+ }, a.tag), null, 16)) : f("", !0)
123
+ ])) : f("", !0),
124
+ e(s)("default") && e(s)("description") ? (l(), v(e(V), {
124
125
  key: 1,
125
- id: e(b),
126
+ id: e(m),
126
127
  class: "b-radio-button__description",
127
128
  el: "span",
128
129
  variant: "body"
129
130
  }, {
130
- default: n(() => [
131
- B(y.$slots, "description", {}, void 0, !0)
131
+ default: i(() => [
132
+ y(n.$slots, "description", {}, void 0, !0)
132
133
  ]),
133
134
  _: 3
134
- }, 8, ["id"])) : p("", !0)
135
- ], 8, re)) : p("", !0),
136
- e(s)("content") && m.value ? (l(), g(e(C), {
135
+ }, 8, ["id"])) : f("", !0)
136
+ ], 8, de)) : f("", !0),
137
+ e(s)("content") && _.value ? (l(), v(e(V), {
137
138
  key: 1,
138
139
  class: "b-radio-button__content",
139
140
  el: "div"
140
141
  }, {
141
- default: n(() => [
142
- B(y.$slots, "content", {}, void 0, !0)
142
+ default: i(() => [
143
+ y(n.$slots, "content", {}, void 0, !0)
143
144
  ]),
144
145
  _: 3
145
- })) : p("", !0)
146
+ })) : f("", !0)
146
147
  ])
147
148
  ], 2));
148
149
  }
149
- }), ne = /* @__PURE__ */ F(se, [["__scopeId", "data-v-db65f460"]]);
150
- var N = /* @__PURE__ */ ((a) => (a.HORIZONTAL = "horizontal", a.VERTICAL = "vertical", a))(N || {});
151
- const ie = { class: "b-radio-group" }, ue = {
150
+ }), ue = /* @__PURE__ */ z(ie, [["__scopeId", "data-v-db65f460"]]);
151
+ var L = /* @__PURE__ */ ((a) => (a.HORIZONTAL = "horizontal", a.VERTICAL = "vertical", a))(L || {});
152
+ const ce = { class: "b-radio-group" }, pe = {
152
153
  name: "bento-radio-group",
153
154
  model: { prop: "modelValue" }
154
- }, ce = /* @__PURE__ */ q({
155
- ...ue,
155
+ }, fe = /* @__PURE__ */ q({
156
+ ...pe,
156
157
  props: {
157
158
  formId: { default: null },
158
159
  hasError: { type: Boolean, default: !1 },
@@ -160,7 +161,7 @@ const ie = { class: "b-radio-group" }, ue = {
160
161
  items: {},
161
162
  label: {},
162
163
  modelValue: { default: null },
163
- variant: { default: N.VERTICAL },
164
+ variant: { default: L.VERTICAL },
164
165
  description: { default: null },
165
166
  disabled: { type: Boolean, default: !1 },
166
167
  errorMessage: { default: null },
@@ -170,23 +171,23 @@ const ie = { class: "b-radio-group" }, ue = {
170
171
  required: { type: Boolean, default: !1 },
171
172
  tooltipText: { default: null }
172
173
  },
173
- emits: ["input", "update:model-value"],
174
- setup(a, { expose: k, emit: I }) {
175
- const c = "bento-radio-group", s = D(), t = z(s), f = I, r = a, _ = M(r, "modelValue"), b = L("error"), { isReadOnly: i } = K(M(r, "readonly")), E = H(null), S = u(
176
- () => !r.disabled && !i.value && (!!r.errorMessage || r.hasError)
177
- ), m = u(() => !r.disabled && !i.value && !!r.errorMessage), R = u(() => ({
178
- "b-radio-group__buttons--horizontal": r.variant === N.HORIZONTAL
179
- })), v = u(() => r.variant === "vertical"), y = u(() => t("content") && !(v != null && v.value)), T = (o) => {
180
- f("update:model-value", o), f("input", o);
174
+ emits: ["update:model-value", "input"],
175
+ setup(a, { expose: k, emit: S }) {
176
+ const p = "bento-radio-group", s = D(), t = H(s), h = S, r = a, g = M(r, "modelValue"), m = C("error"), { isReadOnly: u } = Q(M(r, "readonly")), { emitValue: I } = X(h), B = F(null), _ = c(
177
+ () => !r.disabled && !u.value && (!!r.errorMessage || r.hasError)
178
+ ), E = c(() => !r.disabled && !u.value && !!r.errorMessage), N = c(() => ({
179
+ "b-radio-group__buttons--horizontal": r.variant === L.HORIZONTAL
180
+ })), n = c(() => r.variant === "vertical"), T = c(() => t("content") && !(n != null && n.value)), G = (o) => {
181
+ I(o);
181
182
  };
182
- return r.hasError && Q(
183
+ return r.hasError && W(
183
184
  'BentoRadioGroup "hasError" property',
184
185
  `Use the BentoRadioGroup "errorMessage" property instead to indicate that there is a modifier error.
185
186
  Having the field as "undefined" will hide/remove the error.
186
187
  <bento-radio-group errorMessage="Error message text" />`,
187
188
  "2.0.0"
188
- ), j(
189
- y,
189
+ ), Y(
190
+ T,
190
191
  (o) => {
191
192
  if (o)
192
193
  throw new Error("The content slot is only available for the vertical radio group layout");
@@ -196,13 +197,13 @@ const ie = { class: "b-radio-group" }, ue = {
196
197
  }
197
198
  ), k({
198
199
  focus: () => {
199
- E.value[0].focus();
200
+ B.value[0].focus();
200
201
  }
201
- }), (o, fe) => (l(), h("div", ie, [
202
- V(e(W), {
203
- class: U(["b-radio-group__buttons", R.value]),
204
- "aria-describedby": m.value ? e(b) : "",
205
- "component-name": c,
202
+ }), (o, be) => (l(), b("div", ce, [
203
+ R(e(x), {
204
+ class: U(["b-radio-group__buttons", N.value]),
205
+ "aria-describedby": E.value ? e(m) : "",
206
+ "component-name": p,
206
207
  description: o.description,
207
208
  disabled: o.disabled,
208
209
  form: o.formId,
@@ -212,39 +213,39 @@ const ie = { class: "b-radio-group" }, ue = {
212
213
  "hide-label": o.hideLabel,
213
214
  "tooltip-text": o.tooltipText,
214
215
  role: "radiogroup",
215
- "aria-readonly": e(i)
216
+ "aria-readonly": e(u)
216
217
  }, $({
217
- default: n(() => [
218
- (l(!0), h(Y, null, J(o.items, (d) => (l(), g(e(ne), {
218
+ default: i(() => [
219
+ (l(!0), b(J, null, K(o.items, (d) => (l(), v(e(ue), {
219
220
  ref_for: !0,
220
221
  ref_key: "radioButton",
221
- ref: E,
222
+ ref: B,
222
223
  key: d.value,
223
- "model-value": _.value,
224
+ "model-value": g.value,
224
225
  value: d.value,
225
226
  disabled: o.disabled || d.disabled,
226
- readonly: e(i) || d.readonly,
227
- "has-error": S.value || d.hasError,
227
+ readonly: e(u) || d.readonly,
228
+ "has-error": _.value || d.hasError,
228
229
  tag: d.tag,
229
230
  name: o.formId || o.label,
230
- "onUpdate:modelValue": T
231
+ "onUpdate:modelValue": G
231
232
  }, $({
232
- default: n(() => [
233
+ default: i(() => [
233
234
  O(w(d.label), 1)
234
235
  ]),
235
236
  _: 2
236
237
  }, [
237
238
  d.description ? {
238
239
  name: "description",
239
- fn: n(() => [
240
+ fn: i(() => [
240
241
  O(w(d.description), 1)
241
242
  ]),
242
243
  key: "0"
243
244
  } : void 0,
244
- e(t)("content") && v.value ? {
245
+ e(t)("content") && n.value ? {
245
246
  name: "content",
246
- fn: n(() => [
247
- B(o.$slots, "content", {}, void 0, !0)
247
+ fn: i(() => [
248
+ y(o.$slots, "content", {}, void 0, !0)
248
249
  ]),
249
250
  key: "1"
250
251
  } : void 0
@@ -254,24 +255,24 @@ const ie = { class: "b-radio-group" }, ue = {
254
255
  }, [
255
256
  e(t)("description") ? {
256
257
  name: "description",
257
- fn: n(() => [
258
- B(o.$slots, "description", {}, void 0, !0)
258
+ fn: i(() => [
259
+ y(o.$slots, "description", {}, void 0, !0)
259
260
  ]),
260
261
  key: "0"
261
262
  } : void 0
262
263
  ]), 1032, ["aria-describedby", "class", "description", "disabled", "form", "label", "optional", "required", "hide-label", "tooltip-text", "aria-readonly"]),
263
- m.value ? (l(), g(e(te), {
264
+ E.value ? (l(), v(e(le), {
264
265
  key: 0,
265
- id: e(b),
266
+ id: e(m),
266
267
  "error-message": o.errorMessage,
267
268
  class: "b-radio-group__error-message"
268
- }, null, 8, ["id", "error-message"])) : p("", !0)
269
+ }, null, 8, ["id", "error-message"])) : f("", !0)
269
270
  ]));
270
271
  }
271
- }), Ce = /* @__PURE__ */ F(ce, [["__scopeId", "data-v-1b005c71"]]);
272
+ }), Ne = /* @__PURE__ */ z(fe, [["__scopeId", "data-v-f123ff7b"]]);
272
273
  export {
273
- Ce as B,
274
- N as a,
275
- ne as b
274
+ Ne as B,
275
+ L as a,
276
+ ue as b
276
277
  };
277
- //# sourceMappingURL=radio-group.B_8R6vGx.js.map
278
+ //# sourceMappingURL=radio-group.Br-N309Y.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"radio-group.Br-N309Y.js","sources":["../../../vue2/src/components/radio-group/components/radio-button/radio-button.vue","../../../vue2/src/components/radio-group/radio-group.types.ts","../../../vue2/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 ref=\"radioInputRef\"\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, type ComputedRef, type PropType, ref, toRefs, useSlots } from 'vue';\n import { useDefaultSlotValidator, useHasSlot } from '@/composables';\n import { BentoRadioButtonStateClass, type BentoRadioButtonTag, type 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<{\n /**\n * Emitted when the radio button is clicked. Enables Vue2 \"v-model\"\n */\n (e: 'input', value: BentoRadioButtonValue);\n\n /**\n * Emitted when the radio button is clicked. Enables Vue3 \"v-model\"\n */\n (e: 'update:model-value', value: BentoRadioButtonValue);\n }>();\n\n const { value } = toRefs(props);\n const radioButtonId = generateUid('bento-radio-button');\n const descriptionId = generateUid('description');\n const radioInputRef = ref(null);\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\n const focus = () => {\n radioInputRef.value.focus();\n };\n\n defineExpose({\n focus,\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 { FormField, FormFieldEmits } from '../../types/form-field';\nimport 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\nexport type BentoRadioGroupEmits = FormFieldEmits<BentoRadioGroupValue>;\n\nexport interface BentoRadioGroupProps extends FormField {\n /**\n * The form id the radio group is associated with. Defaults to null, as a radio group can also be used standalone.\n * @default null\n */\n formId?: string | null;\n\n /**\n * If set to true, renders all bento-radio-buttons in the group in an error state.\n * @deprecated Use \"errorMessage\" prop instead\n * @default false\n */\n hasError?: boolean;\n\n /**\n * Shows/hides the group label.\n * @default null\n */\n hideLabel?: boolean | null;\n\n /**\n * The radio group's items.\n * Required.\n */\n items: BentoRadioGroupItems;\n\n /**\n * The name associated with the group. Required for accessibility purposes.\n * Required.\n */\n label: string;\n\n /**\n * Determines the initially selected value of the group. Corresponds to the BentoRadioButtonItem's value.\n * Defaults to no value selected.\n * @default null\n */\n modelValue?: BentoRadioGroupValue | null;\n\n /**\n * The radio group's layout. It can be vertical or horizontal. Defaults to vertical.\n * @default BentoRadioGroupVariant.VERTICAL\n */\n variant?: BentoRadioGroupVariant | `${BentoRadioGroupVariant}`;\n}\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 role=\"radiogroup\"\n :aria-readonly=\"isReadOnly\"\n >\n <bento-radio-button\n v-for=\"item in items\"\n ref=\"radioButton\"\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=\"onUpdateModelValue\"\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 <template v-if=\"hasSlot('description')\" #description>\n <slot name=\"description\" />\n </template>\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, ref, 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 { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n import { type BentoRadioGroupEmits, type BentoRadioGroupProps, 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<BentoRadioGroupEmits>();\n\n const props = withDefaults(defineProps<BentoRadioGroupProps>(), {\n description: null,\n disabled: false,\n errorMessage: null,\n formId: null,\n hasError: false,\n hideLabel: null,\n modelValue: null,\n optional: false,\n readonly: false,\n required: false,\n tooltipText: null,\n variant: BentoRadioGroupVariant.VERTICAL,\n });\n\n const inputValue = toRef(props, 'modelValue');\n const errorId = generateUid('error');\n const { isReadOnly } = useFormLayoutFieldLoading(toRef(props, 'readonly'));\n const { emitValue } = useFormFieldEmits(emit);\n const radioButton = ref(null);\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 onUpdateModelValue = value => {\n emitValue(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\n const focus = () => {\n radioButton.value[0].focus();\n };\n\n defineExpose({\n focus,\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","props","__props","emit","__emit","value","toRefs","radioButtonId","generateUid","descriptionId","radioInputRef","ref","useDefaultSlotValidator","conditionalClassContainer","computed","RadioInputStateClass","ariaLabel","useAriaLabel","getSlotText","isChecked","onChange","__expose","BentoRadioGroupVariant","BentoRadioGroupVariant2","__default__","COMPONENT_NAME","inputValue","toRef","errorId","isReadOnly","useFormLayoutFieldLoading","emitValue","useFormFieldEmits","radioButton","shouldShowError","shouldShowErrorMessage","conditionalClasses","isVertical","shouldShowSlotError","onUpdateModelValue","deprecate","watch","newVal"],"mappings":"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"}
@@ -4,7 +4,7 @@ import { B as gr } from "./segmented-control.BCHGDSrf.js";
4
4
  import { B as dr } from "./alert.C2pusd-_.js";
5
5
  import { _ as Fe } from "./_plugin-vue_export-helper.CHgC5LLL.js";
6
6
  import { B as kr } from "./link.cwPmWlsk.js";
7
- import { B as xr } from "./checkbox.SffuKyNj.js";
7
+ import { B as xr } from "./checkbox.8m_kxm2B.js";
8
8
  import { u as br } from "./index.pdBj0KQU.js";
9
9
  import { u as yr } from "./aria-label.CaUURpnB.js";
10
10
  import { g as Re } from "./generate-uid.NJ8tVoha.js";
@@ -6221,4 +6221,4 @@ const ao = {
6221
6221
  export {
6222
6222
  Ao as r
6223
6223
  };
6224
- //# sourceMappingURL=rich-text-editor.B6Ftqv55.js.map
6224
+ //# sourceMappingURL=rich-text-editor.CkuTqHGk.js.map