@tedi-design-system/react 16.0.0-rc.2 → 16.0.0-rc.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tedi-design-system/react",
3
- "version": "16.0.0-rc.2",
3
+ "version": "16.0.0-rc.3",
4
4
  "type": "module",
5
5
  "sideEffects": false,
6
6
  "exports": {
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const c=require("react/jsx-runtime"),o=require("../../../../../external/classnames/index.cjs.js"),f=require("react"),j=require("../../base/icon/icon.cjs.js"),S=require("../feedback-text/feedback-text.cjs.js"),T=require("../form-label/form-label.cjs.js"),e=require("./checkbox.module.scss.cjs.js"),$=require("../../layout/grid/row.cjs.js"),C=require("../../layout/grid/col.cjs.js"),N=q=>{const{id:d,label:l,value:x,className:g,disabled:b=!1,onChange:i,hideLabel:y=!1,helper:a,checked:s,defaultChecked:I,indeterminate:n,hover:R,name:v,tooltip:k,invalid:w,size:r="default",...z}=q,[m,L]=f.useState(I||!1),u=f.useRef(null),h=f.useMemo(()=>n?"mixed":i&&typeof s<"u"?s:m,[n,i,s,m]),M=t=>{typeof s>"u"&&L(t==null?void 0:t.target.checked),i==null||i(x,t==null?void 0:t.target.checked)},_=a?a.id??`${d}-helper`:void 0,F=k?`${d}-tooltip`:void 0,p=o.default(e.default["tedi-checkbox"],{[e.default["tedi-checkbox--disabled"]]:b});return c.jsxs("div",{"data-name":"check",...z,children:[c.jsxs($.Row,{gutter:0,children:[c.jsx(C.Col,{width:"auto",children:c.jsxs("div",{className:e.default["tedi-checkbox__outer-indicator-wrapper"],children:[c.jsx("input",{id:d,value:x,name:v,type:"checkbox",disabled:b,checked:h!=="mixed"?h:!1,"aria-checked":h,onChange:M,className:e.default["tedi-checkbox__input"],"aria-describedby":[_,F].filter(Boolean).join(" ")}),c.jsxs("div",{"aria-hidden":"true",onClick:()=>{var t;return(t=u.current)==null?void 0:t.click()},className:o.default(e.default["tedi-checkbox__indicator"],{[e.default["tedi-checkbox__indicator--hover"]]:R,[e.default["tedi-checkbox__indicator--indeterminate"]]:n,[e.default[`tedi-checkbox__indicator--size-${r}`]]:r,[e.default["tedi-checkbox__indicator--invalid"]]:w},g),"data-testid":"checkbox-indicator",children:[c.jsx(j.Icon,{size:r==="default"?16:18,name:"remove",className:o.default(e.default["tedi-checkbox__icon"],e.default["tedi-checkbox__icon--indeterminate"])}),c.jsx(j.Icon,{size:r==="default"?16:18,name:"check",className:o.default(e.default["tedi-checkbox__icon"],e.default["tedi-checkbox__icon--check"])})]})]})}),c.jsx(C.Col,{children:l&&typeof l=="string"?c.jsx(T.FormLabel,{ref:u,className:p,id:d,"data-testid":"checkbox-label",hideLabel:y,label:l,tooltip:k}):c.jsx("label",{ref:u,htmlFor:d,className:p,"data-testid":"checkbox-label",children:l})})]}),a&&c.jsx(S.FeedbackText,{id:_,...a,className:o.default(e.default["tedi-checkbox__helper"],a.className)})]})};exports.Checkbox=N;exports.default=N;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const c=require("react/jsx-runtime"),a=require("../../../../../external/classnames/index.cjs.js"),u=require("react"),p=require("../../base/icon/icon.cjs.js"),$=require("../feedback-text/feedback-text.cjs.js"),B=require("../form-label/form-label.cjs.js"),e=require("./checkbox.module.scss.cjs.js"),F=require("../../layout/grid/row.cjs.js"),j=require("../../layout/grid/col.cjs.js"),q=C=>{const{id:o,label:h,value:f,className:N,disabled:x=!1,onChange:d,hideLabel:g=!1,helper:i,checked:l,defaultChecked:y,indeterminate:s,hover:I,name:R,tooltip:b,invalid:v,size:r="default",required:w,...z}=C,[k,L]=u.useState(y||!1),_=u.useRef(null),n=u.useMemo(()=>s?"mixed":d&&typeof l<"u"?l:k,[s,d,l,k]),M=t=>{typeof l>"u"&&L(t==null?void 0:t.target.checked),d==null||d(f,t==null?void 0:t.target.checked)},m=i?i.id??`${o}-helper`:void 0,S=b?`${o}-tooltip`:void 0,T=a.default(e.default["tedi-checkbox__label"],{[e.default["tedi-checkbox--disabled"]]:x});return c.jsxs("div",{"data-name":"check",...z,children:[c.jsxs(F.Row,{gutter:0,children:[c.jsx(j.Col,{width:"auto",children:c.jsxs("div",{className:e.default["tedi-checkbox__outer-indicator-wrapper"],children:[c.jsx("input",{id:o,value:f,name:R,type:"checkbox",disabled:x,checked:n!=="mixed"?n:!1,"aria-checked":n,onChange:M,className:e.default["tedi-checkbox__input"],"aria-describedby":[m,S].filter(Boolean).join(" ")}),c.jsxs("div",{"aria-hidden":"true",onClick:()=>{var t;return(t=_.current)==null?void 0:t.click()},className:a.default(e.default["tedi-checkbox__indicator"],{[e.default["tedi-checkbox__indicator--hover"]]:I,[e.default["tedi-checkbox__indicator--indeterminate"]]:s,[e.default[`tedi-checkbox__indicator--size-${r}`]]:r,[e.default["tedi-checkbox__indicator--invalid"]]:v},N),"data-testid":"checkbox-indicator",children:[c.jsx(p.Icon,{size:r==="default"?16:18,name:"remove",className:a.default(e.default["tedi-checkbox__icon"],e.default["tedi-checkbox__icon--indeterminate"])}),c.jsx(p.Icon,{size:r==="default"?16:18,name:"check",className:a.default(e.default["tedi-checkbox__icon"],e.default["tedi-checkbox__icon--check"])})]})]})}),h&&c.jsx(j.Col,{children:c.jsx(B.FormLabel,{ref:_,className:T,id:o,"data-testid":"checkbox-label",hideLabel:g,label:h,tooltip:b,required:w})})]}),i&&c.jsx($.FeedbackText,{id:m,...i,className:a.default(e.default["tedi-checkbox__helper"],i.className)})]})};exports.Checkbox=q;exports.default=q;
@@ -1,84 +1,85 @@
1
- import { jsxs as n, jsx as i } from "react/jsx-runtime";
1
+ import { jsxs as s, jsx as i } from "react/jsx-runtime";
2
2
  import d from "../../../../../external/classnames/index.es.js";
3
- import b from "react";
4
- import { Icon as C } from "../../base/icon/icon.es.js";
5
- import { FeedbackText as M } from "../feedback-text/feedback-text.es.js";
3
+ import m from "react";
4
+ import { Icon as N } from "../../base/icon/icon.es.js";
5
+ import { FeedbackText as q } from "../feedback-text/feedback-text.es.js";
6
6
  import { FormLabel as E } from "../form-label/form-label.es.js";
7
7
  import e from "./checkbox.module.scss.es.js";
8
8
  import { Row as H } from "../../layout/grid/row.es.js";
9
- import { Col as g } from "../../layout/grid/col.es.js";
10
- const P = (y) => {
9
+ import { Col as C } from "../../layout/grid/col.es.js";
10
+ const Q = (g) => {
11
11
  const {
12
- id: t,
13
- label: r,
14
- value: f,
15
- className: z,
16
- disabled: _ = !1,
17
- onChange: o,
18
- hideLabel: I = !1,
19
- helper: a,
20
- checked: l,
21
- defaultChecked: R,
22
- indeterminate: h,
23
- hover: j,
24
- name: w,
25
- tooltip: p,
26
- invalid: F,
27
- size: s = "default",
28
- ...L
29
- } = y, [x, $] = b.useState(R || !1), m = b.useRef(null), k = b.useMemo(() => h ? "mixed" : o && typeof l < "u" ? l : x, [h, o, l, x]), v = (c) => {
30
- typeof l > "u" && $(c == null ? void 0 : c.target.checked), o == null || o(f, c == null ? void 0 : c.target.checked);
31
- }, u = a ? a.id ?? `${t}-helper` : void 0, B = p ? `${t}-tooltip` : void 0, N = d(e["tedi-checkbox"], { [e["tedi-checkbox--disabled"]]: _ });
32
- return /* @__PURE__ */ n("div", { "data-name": "check", ...L, children: [
33
- /* @__PURE__ */ n(H, { gutter: 0, children: [
34
- /* @__PURE__ */ i(g, { width: "auto", children: /* @__PURE__ */ n("div", { className: e["tedi-checkbox__outer-indicator-wrapper"], children: [
12
+ id: a,
13
+ label: k,
14
+ value: b,
15
+ className: y,
16
+ disabled: f = !1,
17
+ onChange: t,
18
+ hideLabel: z = !1,
19
+ helper: o,
20
+ checked: r,
21
+ defaultChecked: I,
22
+ indeterminate: n,
23
+ hover: R,
24
+ name: j,
25
+ tooltip: _,
26
+ invalid: w,
27
+ size: l = "default",
28
+ required: L,
29
+ ...$
30
+ } = g, [p, v] = m.useState(I || !1), x = m.useRef(null), h = m.useMemo(() => n ? "mixed" : t && typeof r < "u" ? r : p, [n, t, r, p]), B = (c) => {
31
+ typeof r > "u" && v(c == null ? void 0 : c.target.checked), t == null || t(b, c == null ? void 0 : c.target.checked);
32
+ }, u = o ? o.id ?? `${a}-helper` : void 0, F = _ ? `${a}-tooltip` : void 0, M = d(e["tedi-checkbox__label"], { [e["tedi-checkbox--disabled"]]: f });
33
+ return /* @__PURE__ */ s("div", { "data-name": "check", ...$, children: [
34
+ /* @__PURE__ */ s(H, { gutter: 0, children: [
35
+ /* @__PURE__ */ i(C, { width: "auto", children: /* @__PURE__ */ s("div", { className: e["tedi-checkbox__outer-indicator-wrapper"], children: [
35
36
  /* @__PURE__ */ i(
36
37
  "input",
37
38
  {
38
- id: t,
39
- value: f,
40
- name: w,
39
+ id: a,
40
+ value: b,
41
+ name: j,
41
42
  type: "checkbox",
42
- disabled: _,
43
- checked: k !== "mixed" ? k : !1,
44
- "aria-checked": k,
45
- onChange: v,
43
+ disabled: f,
44
+ checked: h !== "mixed" ? h : !1,
45
+ "aria-checked": h,
46
+ onChange: B,
46
47
  className: e["tedi-checkbox__input"],
47
- "aria-describedby": [u, B].filter(Boolean).join(" ")
48
+ "aria-describedby": [u, F].filter(Boolean).join(" ")
48
49
  }
49
50
  ),
50
- /* @__PURE__ */ n(
51
+ /* @__PURE__ */ s(
51
52
  "div",
52
53
  {
53
54
  "aria-hidden": "true",
54
55
  onClick: () => {
55
56
  var c;
56
- return (c = m.current) == null ? void 0 : c.click();
57
+ return (c = x.current) == null ? void 0 : c.click();
57
58
  },
58
59
  className: d(
59
60
  e["tedi-checkbox__indicator"],
60
61
  {
61
- [e["tedi-checkbox__indicator--hover"]]: j,
62
- [e["tedi-checkbox__indicator--indeterminate"]]: h,
63
- [e[`tedi-checkbox__indicator--size-${s}`]]: s,
64
- [e["tedi-checkbox__indicator--invalid"]]: F
62
+ [e["tedi-checkbox__indicator--hover"]]: R,
63
+ [e["tedi-checkbox__indicator--indeterminate"]]: n,
64
+ [e[`tedi-checkbox__indicator--size-${l}`]]: l,
65
+ [e["tedi-checkbox__indicator--invalid"]]: w
65
66
  },
66
- z
67
+ y
67
68
  ),
68
69
  "data-testid": "checkbox-indicator",
69
70
  children: [
70
71
  /* @__PURE__ */ i(
71
- C,
72
+ N,
72
73
  {
73
- size: s === "default" ? 16 : 18,
74
+ size: l === "default" ? 16 : 18,
74
75
  name: "remove",
75
76
  className: d(e["tedi-checkbox__icon"], e["tedi-checkbox__icon--indeterminate"])
76
77
  }
77
78
  ),
78
79
  /* @__PURE__ */ i(
79
- C,
80
+ N,
80
81
  {
81
- size: s === "default" ? 16 : 18,
82
+ size: l === "default" ? 16 : 18,
82
83
  name: "check",
83
84
  className: d(e["tedi-checkbox__icon"], e["tedi-checkbox__icon--check"])
84
85
  }
@@ -87,23 +88,24 @@ const P = (y) => {
87
88
  }
88
89
  )
89
90
  ] }) }),
90
- /* @__PURE__ */ i(g, { children: r && typeof r == "string" ? /* @__PURE__ */ i(
91
+ k && /* @__PURE__ */ i(C, { children: /* @__PURE__ */ i(
91
92
  E,
92
93
  {
93
- ref: m,
94
- className: N,
95
- id: t,
94
+ ref: x,
95
+ className: M,
96
+ id: a,
96
97
  "data-testid": "checkbox-label",
97
- hideLabel: I,
98
- label: r,
99
- tooltip: p
98
+ hideLabel: z,
99
+ label: k,
100
+ tooltip: _,
101
+ required: L
100
102
  }
101
- ) : /* @__PURE__ */ i("label", { ref: m, htmlFor: t, className: N, "data-testid": "checkbox-label", children: r }) })
103
+ ) })
102
104
  ] }),
103
- a && /* @__PURE__ */ i(M, { id: u, ...a, className: d(e["tedi-checkbox__helper"], a.className) })
105
+ o && /* @__PURE__ */ i(q, { id: u, ...o, className: d(e["tedi-checkbox__helper"], o.className) })
104
106
  ] });
105
107
  };
106
108
  export {
107
- P as Checkbox,
108
- P as default
109
+ Q as Checkbox,
110
+ Q as default
109
111
  };
@@ -7,7 +7,7 @@ export interface ChoiceInputProps {
7
7
  /**
8
8
  * Label text
9
9
  */
10
- label: string | React.ReactNode;
10
+ label: React.ReactNode;
11
11
  /**
12
12
  * Additional classes.
13
13
  */
@@ -60,4 +60,8 @@ export interface ChoiceInputProps {
60
60
  * Whether the input is marked as invalid.
61
61
  */
62
62
  invalid?: boolean;
63
+ /**
64
+ * Whether the input is marked as required.
65
+ */
66
+ required?: boolean;
63
67
  }
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("react/jsx-runtime"),c=require("../../../../../external/classnames/index.cjs.js"),n=require("react"),I=require("../feedback-text/feedback-text.cjs.js"),S=require("../form-label/form-label.cjs.js"),a=require("./radio.module.scss.cjs.js"),T=require("../../layout/grid/row.cjs.js"),x=require("../../layout/grid/col.cjs.js"),j=k=>{const{id:i,label:o,value:u,className:g,disabled:f,onChange:t,hideLabel:q,helper:r,checked:l,defaultChecked:C,hover:N,name:R,tooltip:h,size:b="default",invalid:y,...w}=k,[m,L]=n.useState(C||!1),s=n.useRef(null),M=n.useMemo(()=>t&&typeof l<"u"?l:m,[t,m,l]),v=d=>{typeof l>"u"&&L(d==null?void 0:d.target.checked),t==null||t(u,d==null?void 0:d.target.checked)},_=r?r.id??`${i}-helper`:void 0,F=h?`${i}-tooltip`:void 0,p=c.default(a.default["tedi-radio"],{[a.default["tedi-radio--disabled"]]:f});return e.jsxs("div",{"data-name":"radio",...w,children:[e.jsxs(T.Row,{gutter:0,children:[e.jsx(x.Col,{width:"auto",children:e.jsxs("div",{className:a.default["tedi-radio__outer-indicator-wrapper"],children:[e.jsx("input",{id:i,value:u,name:R,type:"radio",disabled:f,checked:M,onChange:v,className:a.default["tedi-radio__input"],"aria-describedby":[_,F].filter(Boolean).join(" ")}),e.jsx("div",{"aria-hidden":"true",onClick:()=>{var d;return(d=s.current)==null?void 0:d.click()},className:c.default(a.default["tedi-radio__indicator"],{[a.default["tedi-radio__indicator--hover"]]:N},{[a.default[`tedi-radio__indicator--size-${b}`]]:b},{[a.default["tedi-radio__indicator--invalid"]]:y},g),"data-testid":"radio-indicator"})]})}),e.jsx(x.Col,{children:o&&typeof o=="string"?e.jsx(S.FormLabel,{ref:s,className:p,id:i,"data-testid":"radio-label",hideLabel:q,label:o,tooltip:h}):e.jsx("label",{ref:s,htmlFor:i,className:p,"data-testid":"radio-label",children:o})})]}),r&&e.jsx(I.FeedbackText,{id:_,...r,className:c.default(a.default["tedi-radio__helper"],r.className)})]})};exports.Radio=j;exports.default=j;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const d=require("react/jsx-runtime"),l=require("../../../../../external/classnames/index.cjs.js"),s=require("react"),T=require("../feedback-text/feedback-text.cjs.js"),$=require("../form-label/form-label.cjs.js"),i=require("./radio.module.scss.cjs.js"),z=require("../../layout/grid/row.cjs.js"),p=require("../../layout/grid/col.cjs.js"),x=j=>{const{id:r,label:c,value:n,className:k,disabled:u,onChange:a,hideLabel:q,helper:t,checked:o,defaultChecked:C,hover:g,name:N,tooltip:f,size:h="default",invalid:R,required:y,...w}=j,[_,L]=s.useState(C||!1),b=s.useRef(null),M=s.useMemo(()=>a&&typeof o<"u"?o:_,[a,_,o]),v=e=>{typeof o>"u"&&L(e==null?void 0:e.target.checked),a==null||a(n,e==null?void 0:e.target.checked)},m=t?t.id??`${r}-helper`:void 0,I=f?`${r}-tooltip`:void 0,S=l.default(i.default["tedi-radio__label"],{[i.default["tedi-radio--disabled"]]:u});return d.jsxs("div",{"data-name":"radio",...w,children:[d.jsxs(z.Row,{gutter:0,children:[d.jsx(p.Col,{width:"auto",children:d.jsxs("div",{className:i.default["tedi-radio__outer-indicator-wrapper"],children:[d.jsx("input",{id:r,value:n,name:N,type:"radio",disabled:u,checked:M,onChange:v,className:i.default["tedi-radio__input"],"aria-describedby":[m,I].filter(Boolean).join(" ")}),d.jsx("div",{"aria-hidden":"true",onClick:()=>{var e;return(e=b.current)==null?void 0:e.click()},className:l.default(i.default["tedi-radio__indicator"],{[i.default["tedi-radio__indicator--hover"]]:g},{[i.default[`tedi-radio__indicator--size-${h}`]]:h},{[i.default["tedi-radio__indicator--invalid"]]:R},k),"data-testid":"radio-indicator"})]})}),c&&d.jsx(p.Col,{children:d.jsx($.FormLabel,{ref:b,className:S,id:r,"data-testid":"radio-label",hideLabel:q,label:c,tooltip:f,required:y})})]}),t&&d.jsx(T.FeedbackText,{id:m,...t,className:l.default(i.default["tedi-radio__helper"],t.className)})]})};exports.Radio=x;exports.default=x;
@@ -1,47 +1,48 @@
1
- import { jsxs as s, jsx as d } from "react/jsx-runtime";
2
- import n from "../../../../../external/classnames/index.es.js";
3
- import m from "react";
4
- import { FeedbackText as B } from "../feedback-text/feedback-text.es.js";
5
- import { FormLabel as M } from "../form-label/form-label.es.js";
1
+ import { jsxs as l, jsx as d } from "react/jsx-runtime";
2
+ import c from "../../../../../external/classnames/index.es.js";
3
+ import s from "react";
4
+ import { FeedbackText as M } from "../feedback-text/feedback-text.es.js";
5
+ import { FormLabel as q } from "../form-label/form-label.es.js";
6
6
  import i from "./radio.module.scss.es.js";
7
7
  import { Row as v } from "../../layout/grid/row.es.js";
8
- import { Col as N } from "../../layout/grid/col.es.js";
9
- const J = (C) => {
8
+ import { Col as k } from "../../layout/grid/col.es.js";
9
+ const K = (N) => {
10
10
  const {
11
- id: a,
12
- label: o,
13
- value: h,
14
- className: g,
15
- disabled: f,
16
- onChange: r,
17
- hideLabel: y,
18
- helper: t,
19
- checked: l,
20
- defaultChecked: R,
21
- hover: x,
22
- name: j,
11
+ id: o,
12
+ label: n,
13
+ value: m,
14
+ className: C,
15
+ disabled: h,
16
+ onChange: a,
17
+ hideLabel: g,
18
+ helper: r,
19
+ checked: t,
20
+ defaultChecked: y,
21
+ hover: R,
22
+ name: x,
23
23
  tooltip: p,
24
- size: u = "default",
25
- invalid: w,
26
- ...F
27
- } = C, [_, I] = m.useState(R || !1), c = m.useRef(null), L = m.useMemo(() => r && typeof l < "u" ? l : _, [r, _, l]), $ = (e) => {
28
- typeof l > "u" && I(e == null ? void 0 : e.target.checked), r == null || r(h, e == null ? void 0 : e.target.checked);
29
- }, b = t ? t.id ?? `${a}-helper` : void 0, z = p ? `${a}-tooltip` : void 0, k = n(i["tedi-radio"], { [i["tedi-radio--disabled"]]: f });
30
- return /* @__PURE__ */ s("div", { "data-name": "radio", ...F, children: [
31
- /* @__PURE__ */ s(v, { gutter: 0, children: [
32
- /* @__PURE__ */ d(N, { width: "auto", children: /* @__PURE__ */ s("div", { className: i["tedi-radio__outer-indicator-wrapper"], children: [
24
+ size: f = "default",
25
+ invalid: j,
26
+ required: w,
27
+ ...I
28
+ } = N, [u, L] = s.useState(y || !1), _ = s.useRef(null), $ = s.useMemo(() => a && typeof t < "u" ? t : u, [a, u, t]), z = (e) => {
29
+ typeof t > "u" && L(e == null ? void 0 : e.target.checked), a == null || a(m, e == null ? void 0 : e.target.checked);
30
+ }, b = r ? r.id ?? `${o}-helper` : void 0, B = p ? `${o}-tooltip` : void 0, F = c(i["tedi-radio__label"], { [i["tedi-radio--disabled"]]: h });
31
+ return /* @__PURE__ */ l("div", { "data-name": "radio", ...I, children: [
32
+ /* @__PURE__ */ l(v, { gutter: 0, children: [
33
+ /* @__PURE__ */ d(k, { width: "auto", children: /* @__PURE__ */ l("div", { className: i["tedi-radio__outer-indicator-wrapper"], children: [
33
34
  /* @__PURE__ */ d(
34
35
  "input",
35
36
  {
36
- id: a,
37
- value: h,
38
- name: j,
37
+ id: o,
38
+ value: m,
39
+ name: x,
39
40
  type: "radio",
40
- disabled: f,
41
- checked: L,
42
- onChange: $,
41
+ disabled: h,
42
+ checked: $,
43
+ onChange: z,
43
44
  className: i["tedi-radio__input"],
44
- "aria-describedby": [b, z].filter(Boolean).join(" ")
45
+ "aria-describedby": [b, B].filter(Boolean).join(" ")
45
46
  }
46
47
  ),
47
48
  /* @__PURE__ */ d(
@@ -50,36 +51,37 @@ const J = (C) => {
50
51
  "aria-hidden": "true",
51
52
  onClick: () => {
52
53
  var e;
53
- return (e = c.current) == null ? void 0 : e.click();
54
+ return (e = _.current) == null ? void 0 : e.click();
54
55
  },
55
- className: n(
56
+ className: c(
56
57
  i["tedi-radio__indicator"],
57
- { [i["tedi-radio__indicator--hover"]]: x },
58
- { [i[`tedi-radio__indicator--size-${u}`]]: u },
59
- { [i["tedi-radio__indicator--invalid"]]: w },
60
- g
58
+ { [i["tedi-radio__indicator--hover"]]: R },
59
+ { [i[`tedi-radio__indicator--size-${f}`]]: f },
60
+ { [i["tedi-radio__indicator--invalid"]]: j },
61
+ C
61
62
  ),
62
63
  "data-testid": "radio-indicator"
63
64
  }
64
65
  )
65
66
  ] }) }),
66
- /* @__PURE__ */ d(N, { children: o && typeof o == "string" ? /* @__PURE__ */ d(
67
- M,
67
+ n && /* @__PURE__ */ d(k, { children: /* @__PURE__ */ d(
68
+ q,
68
69
  {
69
- ref: c,
70
- className: k,
71
- id: a,
70
+ ref: _,
71
+ className: F,
72
+ id: o,
72
73
  "data-testid": "radio-label",
73
- hideLabel: y,
74
- label: o,
75
- tooltip: p
74
+ hideLabel: g,
75
+ label: n,
76
+ tooltip: p,
77
+ required: w
76
78
  }
77
- ) : /* @__PURE__ */ d("label", { ref: c, htmlFor: a, className: k, "data-testid": "radio-label", children: o }) })
79
+ ) })
78
80
  ] }),
79
- t && /* @__PURE__ */ d(B, { id: b, ...t, className: n(i["tedi-radio__helper"], t.className) })
81
+ r && /* @__PURE__ */ d(M, { id: b, ...r, className: c(i["tedi-radio__helper"], r.className) })
80
82
  ] });
81
83
  };
82
84
  export {
83
- J as Radio,
84
- J as default
85
+ K as Radio,
86
+ K as default
85
87
  };