reactive-bulma 4.3.0 → 4.3.2

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.
@@ -1,51 +1,56 @@
1
- import { jsxs as C, jsx as m } from "react/jsx-runtime";
2
- import { parseClasses as f, parseTestId as l } from "../../../functions/parsers.js";
3
- const t = (s) => s ? "-with-component" : "", v = ({
4
- testId: s = null,
5
- containerTestId: a = null,
6
- cssClasses: o = null,
7
- containerCssClasses: c = null,
8
- style: n = null,
9
- containerStyle: d = null,
10
- content: e = null,
11
- name: r,
12
- isDisabled: i = null,
13
- onClick: p,
14
- onChange: u,
15
- onBlur: x
1
+ import { jsxs as y, jsx as t } from "react/jsx-runtime";
2
+ import { parseClasses as f, parseTestId as c } from "../../../functions/parsers.js";
3
+ const l = (e) => e ? "-with-component" : "", v = ({
4
+ testId: e = null,
5
+ containerTestId: o = null,
6
+ cssClasses: a = null,
7
+ containerCssClasses: n = null,
8
+ style: d = null,
9
+ containerStyle: i = null,
10
+ label: s = null,
11
+ isChecked: r,
12
+ name: h,
13
+ isDisabled: p = !1,
14
+ onClick: x,
15
+ onChange: k,
16
+ onBlur: b
16
17
  }) => {
17
- const b = f([
18
+ const u = f([
18
19
  "checkbox",
19
- c
20
- ]), h = a ?? l({
20
+ n
21
+ ]), C = o ?? c({
21
22
  tag: "checkbox-container",
22
- parsedClasses: t(e)
23
- }), k = s ?? l({
23
+ parsedClasses: l(s)
24
+ }), m = e ?? c({
24
25
  tag: "checkbox",
25
- parsedClasses: t(e)
26
+ parsedClasses: l(s)
26
27
  });
27
- return /* @__PURE__ */ C(
28
+ return /* @__PURE__ */ y(
28
29
  "label",
29
30
  {
30
- "data-testid": h,
31
- className: b,
32
- style: d ?? void 0,
31
+ "data-testid": C,
32
+ className: u,
33
+ style: i ?? void 0,
33
34
  children: [
34
- /* @__PURE__ */ m(
35
+ /* @__PURE__ */ t(
35
36
  "input",
36
37
  {
37
- "data-testid": k,
38
+ "data-testid": m,
38
39
  type: "checkbox",
39
- name: r,
40
- className: o ?? void 0,
41
- style: n ?? void 0,
42
- disabled: i ?? !1,
43
- onClick: p,
44
- onChange: u,
45
- onBlur: x
40
+ name: h,
41
+ className: a ?? void 0,
42
+ style: d ?? void 0,
43
+ defaultChecked: r,
44
+ disabled: p,
45
+ onClick: x,
46
+ onChange: k,
47
+ onBlur: b
46
48
  }
47
49
  ),
48
- e
50
+ /* @__PURE__ */ t("p", { style: {
51
+ display: "inline-block",
52
+ marginLeft: "5px"
53
+ }, children: s })
49
54
  ]
50
55
  }
51
56
  );
@@ -3,4 +3,5 @@ import { default as Checkbox } from '.';
3
3
  declare const _default: Meta<typeof Checkbox>;
4
4
  export default _default;
5
5
  export declare const BasicExample: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/atomProps').CheckBoxProps>;
6
+ export declare const Checked: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/atomProps').CheckBoxProps>;
6
7
  export declare const Disabled: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/atomProps').CheckBoxProps>;
@@ -1,7 +1,7 @@
1
- import { jsx as m, jsxs as f } from "react/jsx-runtime";
2
- import { useMemo as C } from "react";
3
- import { parseClasses as B, parseTestId as b } from "../../../functions/parsers.js";
4
- const h = (d, t) => {
1
+ import { jsx as m, jsxs as B } from "react/jsx-runtime";
2
+ import { useMemo as f } from "react";
3
+ import { parseClasses as y, parseTestId as C } from "../../../functions/parsers.js";
4
+ const b = (d, t) => {
5
5
  const {
6
6
  testId: r = null,
7
7
  label: e,
@@ -13,7 +13,7 @@ const h = (d, t) => {
13
13
  onChange: i,
14
14
  onBlur: u
15
15
  } = d, c = r ?? `test-radio-button-item-${t}`;
16
- return /* @__PURE__ */ f(
16
+ return /* @__PURE__ */ B(
17
17
  "label",
18
18
  {
19
19
  className: "radio",
@@ -32,12 +32,15 @@ const h = (d, t) => {
32
32
  onBlur: u
33
33
  }
34
34
  ),
35
- e
35
+ /* @__PURE__ */ m("p", { style: {
36
+ display: "inline-block",
37
+ marginLeft: "5px"
38
+ }, children: e })
36
39
  ]
37
40
  },
38
41
  t
39
42
  );
40
- }, T = ({
43
+ }, x = ({
41
44
  containerTestId: d = null,
42
45
  containerCssClasses: t = null,
43
46
  containerStyle: r = null,
@@ -47,15 +50,15 @@ const h = (d, t) => {
47
50
  onChange: o,
48
51
  onBlur: n
49
52
  }) => {
50
- const l = B([
53
+ const l = y([
51
54
  "control",
52
55
  t
53
- ]), i = d ?? b({
56
+ ]), i = d ?? C({
54
57
  tag: "container-",
55
58
  parsedClasses: l
56
- }), u = C(
59
+ }), u = f(
57
60
  () => e.map(
58
- (c, p) => h(
61
+ (c, p) => b(
59
62
  {
60
63
  ...c,
61
64
  name: s,
@@ -79,5 +82,5 @@ const h = (d, t) => {
79
82
  );
80
83
  };
81
84
  export {
82
- T as default
85
+ x as default
83
86
  };
@@ -0,0 +1,4 @@
1
+ import { default as React } from 'react';
2
+ import { FormFieldInputProps } from '../../../interfaces/moleculeProps';
3
+ declare const FormFieldInput: React.FC<FormFieldInputProps>;
4
+ export default FormFieldInput;
@@ -0,0 +1,109 @@
1
+ import { jsxs as f, Fragment as p, jsx as s } from "react/jsx-runtime";
2
+ import { useMemo as n } from "react";
3
+ import { parseClasses as u, parseTestId as I } from "../../../functions/parsers.js";
4
+ import T from "../../atoms/TextArea/index.js";
5
+ import h from "../../atoms/Select/index.js";
6
+ import b from "../../atoms/Checkbox/index.js";
7
+ import C from "../../atoms/RadioButton/index.js";
8
+ import E from "../InputControl/index.js";
9
+ import { FormFieldType as l } from "../../../interfaces/moleculeProps.js";
10
+ const x = (r, t) => {
11
+ const e = r !== null ? /* @__PURE__ */ s(
12
+ "label",
13
+ {
14
+ "data-testid": "test-form-field-label",
15
+ className: "label",
16
+ children: r
17
+ }
18
+ ) : null;
19
+ return t ? /* @__PURE__ */ s("section", { className: "field-label", children: e }) : e;
20
+ }, F = ({
21
+ testId: r,
22
+ type: t,
23
+ input: e
24
+ }) => {
25
+ const o = {
26
+ testId: r ?? `test-form-field-${t}`,
27
+ containerTestId: r ?? `test-form-field-container-${t}`
28
+ };
29
+ switch (t) {
30
+ case l.INPUT:
31
+ return /* @__PURE__ */ s(
32
+ E,
33
+ {
34
+ ...e,
35
+ ...o
36
+ }
37
+ );
38
+ case l.SELECT:
39
+ return /* @__PURE__ */ s(
40
+ h,
41
+ {
42
+ ...e,
43
+ ...o
44
+ }
45
+ );
46
+ case l.CHECKBOX:
47
+ return /* @__PURE__ */ s(
48
+ b,
49
+ {
50
+ ...e,
51
+ ...o
52
+ }
53
+ );
54
+ case l.RADIOBUTTON:
55
+ return /* @__PURE__ */ s(
56
+ C,
57
+ {
58
+ ...e,
59
+ ...o
60
+ }
61
+ );
62
+ case l.TEXTAREA:
63
+ return /* @__PURE__ */ s(
64
+ T,
65
+ {
66
+ ...e,
67
+ ...o
68
+ }
69
+ );
70
+ }
71
+ }, N = (r) => {
72
+ if (!r) return null;
73
+ const t = u(["help", r.color]), e = I({
74
+ tag: "form-field-help",
75
+ parsedClasses: t,
76
+ rules: [{ regExp: /help|is/gm, replacer: "" }]
77
+ });
78
+ return /* @__PURE__ */ s(
79
+ "p",
80
+ {
81
+ "data-testid": e,
82
+ className: t,
83
+ children: r.text
84
+ }
85
+ );
86
+ }, j = ({
87
+ testId: r = null,
88
+ labelText: t,
89
+ type: e,
90
+ input: o,
91
+ helper: m,
92
+ isHorizontal: a
93
+ }) => {
94
+ const c = n(
95
+ () => x(t, a),
96
+ [t, a]
97
+ ), d = n(
98
+ () => F({ testId: r ?? void 0, type: e, input: o }),
99
+ [r, e, o]
100
+ ), i = n(() => N(m), [m]);
101
+ return /* @__PURE__ */ f(p, { children: [
102
+ c,
103
+ d,
104
+ i
105
+ ] });
106
+ };
107
+ export {
108
+ j as default
109
+ };
@@ -0,0 +1,13 @@
1
+ import { Meta } from '@storybook/react';
2
+ import { default as FormFieldInput } from '.';
3
+ import { FormFieldInputProps } from '../../../interfaces/moleculeProps';
4
+ declare const _default: Meta<typeof FormFieldInput>;
5
+ export default _default;
6
+ export declare const BasicExample: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
7
+ export declare const WithLabel: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
8
+ export declare const WithLabelAndHelper: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
9
+ export declare const ErrorCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
10
+ export declare const SelectCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
11
+ export declare const CheckboxCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
12
+ export declare const RadiobuttonCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
13
+ export declare const TextareaCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, FormFieldInputProps>;
@@ -20,3 +20,4 @@ export { default as Section } from './Section';
20
20
  export { default as NavBarBrand } from './NavBarBrand';
21
21
  export { default as NavBarDropdown } from './NavBarDropdown';
22
22
  export { default as TableRow } from './TableRow';
23
+ export { default as FormFieldInput } from './FormFieldInput';
@@ -2,17 +2,17 @@ import { default as e } from "./ButtonGroup/index.js";
2
2
  import { default as t } from "./ColumnGroup/index.js";
3
3
  import { default as l } from "./Notification/index.js";
4
4
  import { default as d } from "./Breadcrumbs/index.js";
5
- import { default as p } from "./Dropdown/index.js";
5
+ import { default as s } from "./Dropdown/index.js";
6
6
  import { default as x } from "./Message/index.js";
7
7
  import { default as i } from "./Menu/index.js";
8
8
  import { default as M } from "./MenuList/index.js";
9
9
  import { default as c } from "./Pagination/index.js";
10
10
  import { default as v } from "./Modal/index.js";
11
- import { default as N } from "./Tabs/index.js";
12
- import { default as g } from "./InputControl/index.js";
13
- import { default as D } from "./PanelBlock/index.js";
14
- import { default as I } from "./PanelTabs/index.js";
15
- import { default as k } from "./LevelItem/index.js";
11
+ import { default as F } from "./Tabs/index.js";
12
+ import { default as N } from "./InputControl/index.js";
13
+ import { default as g } from "./PanelBlock/index.js";
14
+ import { default as D } from "./PanelTabs/index.js";
15
+ import { default as L } from "./LevelItem/index.js";
16
16
  import { default as R } from "./TileBox/index.js";
17
17
  import { default as h } from "./Footer/index.js";
18
18
  import { default as q } from "./Media/index.js";
@@ -20,14 +20,16 @@ import { default as z } from "./Section/index.js";
20
20
  import { default as E } from "./NavBarBrand/index.js";
21
21
  import { default as J } from "./NavBarDropdown/index.js";
22
22
  import { default as O } from "./TableRow/index.js";
23
+ import { default as U } from "./FormFieldInput/index.js";
23
24
  export {
24
25
  d as Breadcrumbs,
25
26
  e as ButtonGroup,
26
27
  t as ColumnGroup,
27
- p as Dropdown,
28
+ s as Dropdown,
28
29
  h as Footer,
29
- g as InputControl,
30
- k as LevelItem,
30
+ U as FormFieldInput,
31
+ N as InputControl,
32
+ L as LevelItem,
31
33
  q as Media,
32
34
  i as Menu,
33
35
  M as MenuList,
@@ -37,10 +39,10 @@ export {
37
39
  J as NavBarDropdown,
38
40
  l as Notification,
39
41
  c as Pagination,
40
- D as PanelBlock,
41
- I as PanelTabs,
42
+ g as PanelBlock,
43
+ D as PanelTabs,
42
44
  z as Section,
43
45
  O as TableRow,
44
- N as Tabs,
46
+ F as Tabs,
45
47
  R as TileBox
46
48
  };
@@ -1,150 +1,68 @@
1
- import { jsx as t, jsxs as c, Fragment as a } from "react/jsx-runtime";
2
- import B, { useMemo as F } from "react";
3
- import E from "../../molecules/InputControl/index.js";
4
- import { parseClasses as T, parseTestId as I } from "../../../functions/parsers.js";
5
- import $ from "../../atoms/TextArea/index.js";
6
- import x from "../../atoms/Select/index.js";
7
- import S from "../../atoms/Checkbox/index.js";
8
- import K from "../../atoms/RadioButton/index.js";
9
- import { FormFieldType as n } from "../../../interfaces/organismProps.js";
10
- import { generateKey as h } from "../../../functions/generators.js";
11
- const m = (e) => {
12
- if (!e) return null;
13
- const s = T(["help", e.color]), l = I({
14
- tag: "form-field-help",
15
- parsedClasses: s,
16
- rules: [{ regExp: /help|is/gm, replacer: "" }]
17
- });
18
- return /* @__PURE__ */ t(
19
- "p",
20
- {
21
- "data-testid": l,
22
- className: s,
23
- children: e.text
24
- }
25
- );
26
- }, f = (e, s, l) => {
27
- const r = {
28
- key: s,
29
- testId: l ?? `test-form-field-${e.type}`,
30
- containerTestId: l ?? `test-form-field-container-${e.type}`
31
- };
32
- switch (e.type) {
33
- case n.INPUT:
34
- return /* @__PURE__ */ c(a, { children: [
35
- /* @__PURE__ */ t(
36
- E,
37
- {
38
- ...e.config,
39
- ...r
40
- }
41
- ),
42
- m(e.helper)
43
- ] });
44
- case n.SELECT:
45
- return /* @__PURE__ */ c(a, { children: [
46
- /* @__PURE__ */ t(
47
- x,
48
- {
49
- ...e.config,
50
- ...r
51
- }
52
- ),
53
- m(e.helper)
54
- ] });
55
- case n.CHECKBOX:
56
- return /* @__PURE__ */ c(a, { children: [
57
- /* @__PURE__ */ t(
58
- S,
59
- {
60
- ...e.config,
61
- ...r
62
- }
63
- ),
64
- m(e.helper)
65
- ] });
66
- case n.RADIOBUTTON:
67
- return /* @__PURE__ */ c(a, { children: [
68
- /* @__PURE__ */ t(
69
- K,
70
- {
71
- ...e.config,
72
- ...r
73
- }
74
- ),
75
- m(e.helper)
76
- ] });
77
- case n.TEXTAREA:
78
- return /* @__PURE__ */ c(a, { children: [
79
- /* @__PURE__ */ t(
80
- $,
81
- {
82
- ...e.config,
83
- ...r
84
- }
85
- ),
86
- m(e.helper)
87
- ] });
88
- default:
89
- return null;
1
+ import { jsx as s } from "react/jsx-runtime";
2
+ import { useMemo as i } from "react";
3
+ import m from "../../molecules/FormFieldInput/index.js";
4
+ import { parseClasses as u, parseTestId as y } from "../../../functions/parsers.js";
5
+ import { generateKey as c } from "../../../functions/generators.js";
6
+ const F = (e, o, r) => {
7
+ const a = o ? `grouped-input-control-body-${c()}` : `input-control-body-${c()}`;
8
+ if (o)
9
+ return Array.isArray(e) ? e.map((l, t) => {
10
+ const d = {
11
+ ...l,
12
+ isHorizontal: l.isHorizontal ?? r,
13
+ testId: `test-grouped-input-control-${t}`
14
+ };
15
+ return /* @__PURE__ */ s(
16
+ m,
17
+ {
18
+ ...d
19
+ },
20
+ a
21
+ );
22
+ }) : /* @__PURE__ */ s(
23
+ m,
24
+ {
25
+ labelText: e.labelText,
26
+ input: e.input,
27
+ type: e.type,
28
+ helper: e.helper,
29
+ isHorizontal: e.isHorizontal ?? r
30
+ }
31
+ );
32
+ {
33
+ const l = Array.isArray(e) ? null : {
34
+ ...e,
35
+ isHorizontal: e.isHorizontal ?? r
36
+ };
37
+ return l !== null ? /* @__PURE__ */ s(m, { ...l }) : null;
90
38
  }
91
- }, R = (e, s) => {
92
- const l = s ? `grouped-input-control-body-${h()}` : `input-control-body-${h()}`;
93
- return s ? Array.isArray(e) ? e.map(
94
- (r, i) => f(
95
- r,
96
- l,
97
- `test-grouped-input-control-${i}`
98
- )
99
- ) : f(e) : Array.isArray(e) ? f(e[0], l) : f(e, l);
100
- }, M = ({
39
+ }, z = ({
101
40
  testId: e = null,
102
- cssClasses: s = null,
103
- style: l = null,
104
- labelText: r = null,
105
- inputControlConfig: i,
106
- isHorizontal: o = !1,
107
- isGrouped: p = !1
41
+ cssClasses: o = null,
42
+ style: r = null,
43
+ config: a,
44
+ isHorizontal: l = !1,
45
+ isGrouped: t = !1
108
46
  }) => {
109
- const y = T([
47
+ const d = u([
110
48
  "field",
111
- o ? "is-horizontal" : null,
112
- p ? "is-grouped" : null,
113
- s
114
- ]), b = e ?? I({ tag: "field", parsedClasses: y }), A = F(() => {
115
- const d = r !== null ? /* @__PURE__ */ t(
116
- "label",
117
- {
118
- "data-testid": "test-form-field-label",
119
- className: "label",
120
- children: r
121
- }
122
- ) : null;
123
- return o ? /* @__PURE__ */ t("section", { className: "field-label", children: d }) : d;
124
- }, [o, r]), N = F(() => {
125
- const d = R(i, p), u = `input-control-container-${h()}`;
126
- return o ? /* @__PURE__ */ t(
127
- "section",
128
- {
129
- className: "field-body",
130
- children: d
131
- },
132
- u
133
- ) : /* @__PURE__ */ t(B.Fragment, { children: d }, u);
134
- }, [o, i, p]);
135
- return /* @__PURE__ */ c(
49
+ l ? "is-horizontal" : null,
50
+ t ? "is-grouped" : null,
51
+ o
52
+ ]), p = e ?? y({ tag: "field", parsedClasses: d }), n = i(
53
+ () => F(a, t, l),
54
+ [a, t, l]
55
+ );
56
+ return /* @__PURE__ */ s(
136
57
  "section",
137
58
  {
138
- "data-testid": b,
139
- className: y,
140
- style: l ?? void 0,
141
- children: [
142
- A,
143
- N
144
- ]
59
+ "data-testid": p,
60
+ className: d,
61
+ style: r ?? void 0,
62
+ children: l ? /* @__PURE__ */ s("section", { className: "field-body", children: n }) : n
145
63
  }
146
64
  );
147
65
  };
148
66
  export {
149
- M as default
67
+ z as default
150
68
  };
@@ -3,12 +3,5 @@ import { default as FormField } from '.';
3
3
  declare const _default: Meta<typeof FormField>;
4
4
  export default _default;
5
5
  export declare const BasicExample: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
6
- export declare const WithLabel: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
7
- export declare const WithLabelAndHelper: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
8
- export declare const ErrorCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
6
+ export declare const InHorizontalMode: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
9
7
  export declare const GroupedInputs: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
10
- export declare const Horizontal: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
11
- export declare const SelectCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
12
- export declare const CheckboxCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
13
- export declare const RadiobuttonCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
14
- export declare const TextareaCase: import('@storybook/csf').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, import('../../../interfaces/organismProps').FormFieldProps>;
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { default as o } from "./components/atoms/Button/index.js";
1
+ import { default as a } from "./components/atoms/Button/index.js";
2
2
  import { default as t } from "./components/atoms/Column/index.js";
3
3
  import { default as l } from "./components/atoms/ProgressBar/index.js";
4
4
  import { default as d } from "./components/atoms/Block/index.js";
@@ -9,9 +9,9 @@ import { default as T } from "./components/atoms/Icon/index.js";
9
9
  import { default as b } from "./components/atoms/Input/index.js";
10
10
  import { default as g } from "./components/atoms/TextArea/index.js";
11
11
  import { default as C } from "./components/atoms/Delete/index.js";
12
- import { default as P } from "./components/atoms/Select/index.js";
13
- import { default as D } from "./components/atoms/File/index.js";
14
- import { default as F } from "./components/atoms/Checkbox/index.js";
12
+ import { default as M } from "./components/atoms/Select/index.js";
13
+ import { default as w } from "./components/atoms/File/index.js";
14
+ import { default as N } from "./components/atoms/Checkbox/index.js";
15
15
  import { default as k } from "./components/atoms/RadioButton/index.js";
16
16
  import { default as H } from "./components/atoms/BreadcrumbItem/index.js";
17
17
  import { default as S } from "./components/atoms/DropdownTrigger/index.js";
@@ -25,7 +25,7 @@ import { default as W } from "./components/atoms/Tile/index.js";
25
25
  import { default as Y } from "./components/atoms/NavBarItem/index.js";
26
26
  import { default as _ } from "./components/atoms/TableHeadCell/index.js";
27
27
  import { default as ee } from "./components/atoms/TableCell/index.js";
28
- import { default as oe } from "./components/molecules/ButtonGroup/index.js";
28
+ import { default as ae } from "./components/molecules/ButtonGroup/index.js";
29
29
  import { default as te } from "./components/molecules/ColumnGroup/index.js";
30
30
  import { default as le } from "./components/molecules/Notification/index.js";
31
31
  import { default as de } from "./components/molecules/Breadcrumbs/index.js";
@@ -36,9 +36,9 @@ import { default as Te } from "./components/molecules/MenuList/index.js";
36
36
  import { default as be } from "./components/molecules/Pagination/index.js";
37
37
  import { default as ge } from "./components/molecules/Modal/index.js";
38
38
  import { default as Ce } from "./components/molecules/Tabs/index.js";
39
- import { default as Pe } from "./components/molecules/InputControl/index.js";
40
- import { default as De } from "./components/molecules/PanelBlock/index.js";
41
- import { default as Fe } from "./components/molecules/PanelTabs/index.js";
39
+ import { default as Me } from "./components/molecules/InputControl/index.js";
40
+ import { default as we } from "./components/molecules/PanelBlock/index.js";
41
+ import { default as Ne } from "./components/molecules/PanelTabs/index.js";
42
42
  import { default as ke } from "./components/molecules/LevelItem/index.js";
43
43
  import { default as He } from "./components/molecules/TileBox/index.js";
44
44
  import { default as Se } from "./components/molecules/Footer/index.js";
@@ -47,38 +47,40 @@ import { default as qe } from "./components/molecules/Section/index.js";
47
47
  import { default as ze } from "./components/molecules/NavBarBrand/index.js";
48
48
  import { default as Je } from "./components/molecules/NavBarDropdown/index.js";
49
49
  import { default as Oe } from "./components/molecules/TableRow/index.js";
50
- import { default as Ue } from "./components/organisms/FormField/index.js";
51
- import { default as We } from "./components/organisms/Panel/index.js";
52
- import { default as Ye } from "./components/organisms/Level/index.js";
53
- import { default as _e } from "./components/organisms/Hero/index.js";
54
- import { default as ea } from "./components/organisms/TileGroup/index.js";
55
- import { default as oa } from "./components/organisms/NavBar/index.js";
56
- import { default as ta } from "./components/organisms/Card/index.js";
57
- import { default as la } from "./components/organisms/Table/index.js";
50
+ import { default as Ue } from "./components/molecules/FormFieldInput/index.js";
51
+ import { default as We } from "./components/organisms/FormField/index.js";
52
+ import { default as Ye } from "./components/organisms/Panel/index.js";
53
+ import { default as _e } from "./components/organisms/Level/index.js";
54
+ import { default as eo } from "./components/organisms/Hero/index.js";
55
+ import { default as ao } from "./components/organisms/TileGroup/index.js";
56
+ import { default as to } from "./components/organisms/NavBar/index.js";
57
+ import { default as lo } from "./components/organisms/Card/index.js";
58
+ import { default as mo } from "./components/organisms/Table/index.js";
58
59
  export {
59
60
  d as Block,
60
61
  x as Box,
61
62
  H as BreadcrumbItem,
62
63
  de as Breadcrumbs,
63
- o as Button,
64
- oe as ButtonGroup,
65
- ta as Card,
66
- F as Checkbox,
64
+ a as Button,
65
+ ae as ButtonGroup,
66
+ lo as Card,
67
+ N as Checkbox,
67
68
  t as Column,
68
69
  te as ColumnGroup,
69
70
  C as Delete,
70
71
  pe as Dropdown,
71
72
  A as DropdownItem,
72
73
  S as DropdownTrigger,
73
- D as File,
74
+ w as File,
74
75
  Se as Footer,
75
- Ue as FormField,
76
- _e as Hero,
76
+ We as FormField,
77
+ Ue as FormFieldInput,
78
+ eo as Hero,
77
79
  T as Icon,
78
80
  z as Image,
79
81
  b as Input,
80
- Pe as InputControl,
81
- Ye as Level,
82
+ Me as InputControl,
83
+ _e as Level,
82
84
  U as LevelHeader,
83
85
  ke as LevelItem,
84
86
  Ae as Media,
@@ -87,22 +89,22 @@ export {
87
89
  Te as MenuList,
88
90
  xe as Message,
89
91
  ge as Modal,
90
- oa as NavBar,
92
+ to as NavBar,
91
93
  ze as NavBarBrand,
92
94
  Je as NavBarDropdown,
93
95
  Y as NavBarItem,
94
96
  le as Notification,
95
97
  be as Pagination,
96
98
  J as PaginationItem,
97
- We as Panel,
98
- De as PanelBlock,
99
- Fe as PanelTabs,
99
+ Ye as Panel,
100
+ we as PanelBlock,
101
+ Ne as PanelTabs,
100
102
  l as ProgressBar,
101
103
  k as RadioButton,
102
104
  qe as Section,
103
- P as Select,
105
+ M as Select,
104
106
  O as TabItem,
105
- la as Table,
107
+ mo as Table,
106
108
  ee as TableCell,
107
109
  _ as TableHeadCell,
108
110
  Oe as TableRow,
@@ -111,6 +113,6 @@ export {
111
113
  g as TextArea,
112
114
  W as Tile,
113
115
  He as TileBox,
114
- ea as TileGroup,
116
+ ao as TileGroup,
115
117
  i as Title
116
118
  };
@@ -198,15 +198,17 @@ export interface FileProps extends ComposedElementProps, InteractiveProps, Named
198
198
  size?: ElementSizeType;
199
199
  }
200
200
  export interface CheckBoxProps extends ComposedElementProps, InteractiveOnChangeProps, NamedInputProps {
201
+ /** `Attribute` Shows the checkbox as checked or unchecked */
202
+ isChecked?: boolean;
201
203
  /** `Attribute` Sets checkbox's text that will be shown next to its control */
202
- content?: string;
204
+ label?: string;
203
205
  /** `Attribute` Will disable the checkbox */
204
206
  isDisabled?: boolean;
205
207
  }
206
208
  export interface RadioButtonItemProps extends Pick<ElementProps, 'testId' | 'style'>, InteractiveOnChangeProps, NamedInputProps {
207
- /** `Attribute` `Required` Sets checkbox's text*/
209
+ /** `Attribute` `Required` Sets radiobutton's text*/
208
210
  label: string;
209
- /** `Attribute` Shows the checkbox as checked or unchecked */
211
+ /** `Attribute` Shows the radiobutton as checked or unchecked */
210
212
  isChecked?: boolean;
211
213
  /** `Attribute` Will disable the checkbox */
212
214
  isDisabled?: boolean;
@@ -1,5 +1,5 @@
1
1
  import { ClickeableProps, ComposedElementProps, ElementProps } from './commonProps';
2
- import { BreadcrumbItemProps, ButtonProps, ColumnProps, DeleteProps, DropdownItemProps, IconProps, ImageProps, InputProps, MenuItemProps, NavBarItemProps, PaginationItemProps, TabItemProps, TableCellProps, TableHeadCellProps } from './atomProps';
2
+ import { BreadcrumbItemProps, ButtonProps, CheckBoxProps, ColumnProps, DeleteProps, DropdownItemProps, IconProps, ImageProps, InputProps, MenuItemProps, NavBarItemProps, PaginationItemProps, RadioButtonProps, SelectProps, TabItemProps, TableCellProps, TableHeadCellProps, TextAreaProps } from './atomProps';
3
3
  import { BasicColorType, RightCenteredAlignType, BreadcrumbSeparatorType, ColumnGapType, SizeWithoutNormalType, TabsFormatType, MediumAndLargeSizeType, RightLeftAlignType } from '../types/styleTypes';
4
4
  import { ChildrenType, SingleChildType, PanelBlockItemType } from '../types/domTypes';
5
5
  export interface ButtonGroupProps extends ElementProps {
@@ -226,4 +226,26 @@ export interface TableRowProps extends ElementProps, ClickeableProps {
226
226
  /** `Styling` Used for `Table` styling purpose only. Will set row's background color to indicate it has been selected by the user */
227
227
  isSelected?: boolean;
228
228
  }
229
+ export declare enum FormFieldType {
230
+ INPUT = "input",
231
+ SELECT = "select",
232
+ CHECKBOX = "checkbox",
233
+ RADIOBUTTON = "radiobutton",
234
+ TEXTAREA = "textarea"
235
+ }
236
+ export type FormFieldConfig = InputControlProps | SelectProps | CheckBoxProps | RadioButtonProps | TextAreaProps;
237
+ export interface FormFieldHelper {
238
+ text?: string;
239
+ color?: BasicColorType;
240
+ }
241
+ export interface FormFieldInputProps extends ElementProps {
242
+ /** `Attribute` Sets a custom text before the wrapped input to indicate its usage */
243
+ labelText?: string;
244
+ type: FormFieldType;
245
+ input: FormFieldConfig;
246
+ /** `Attribute` Sets a custom text below the input to show a message */
247
+ helper?: FormFieldHelper;
248
+ /** `Styling` Will adjust field's sections (label, input/s and helper) in horizontal position */
249
+ isHorizontal?: boolean;
250
+ }
229
251
  export {};
@@ -1 +1,4 @@
1
-
1
+ var E = /* @__PURE__ */ ((t) => (t.INPUT = "input", t.SELECT = "select", t.CHECKBOX = "checkbox", t.RADIOBUTTON = "radiobutton", t.TEXTAREA = "textarea", t))(E || {});
2
+ export {
3
+ E as FormFieldType
4
+ };
@@ -1,30 +1,11 @@
1
1
  import { ClickeableProps, ElementProps } from './commonProps';
2
- import { InputControlProps, LevelItemProps, NavBarBrandProps, NavBarDropdownProps, PanelBlockProps, PanelTabsProps, TableRowProps } from './moleculeProps';
3
- import { CheckBoxProps, ImageProps, NavBarItemProps, RadioButtonProps, SelectProps, TableHeadCellProps, TextAreaProps, TileProps } from './atomProps';
2
+ import { FormFieldInputProps, LevelItemProps, NavBarBrandProps, NavBarDropdownProps, PanelBlockProps, PanelTabsProps, TableRowProps } from './moleculeProps';
3
+ import { ImageProps, NavBarItemProps, TableHeadCellProps, TileProps } from './atomProps';
4
4
  import { BasicColorType, SizeWithHeightType } from '../types/styleTypes';
5
5
  import { ChildrenType, NavBarFixedPositionType } from '../types/domTypes';
6
- export declare enum FormFieldType {
7
- INPUT = "input",
8
- SELECT = "select",
9
- CHECKBOX = "checkbox",
10
- RADIOBUTTON = "radiobutton",
11
- TEXTAREA = "textarea"
12
- }
13
- export type FormFieldConfig = InputControlProps | SelectProps | CheckBoxProps | RadioButtonProps | TextAreaProps;
14
- export interface FormFieldHelper {
15
- text?: string;
16
- color?: BasicColorType;
17
- }
18
- export interface FormFieldInputProps {
19
- type: FormFieldType;
20
- config: FormFieldConfig;
21
- helper?: FormFieldHelper;
22
- }
23
6
  export interface FormFieldProps extends ElementProps {
24
7
  /** `Attribute` `Required` Single or multiple `FormFieldConfig` config objects which will be wrapped around the `FormField` */
25
- inputControlConfig: FormFieldInputProps | FormFieldInputProps[];
26
- /** `Attribute` Sets a custom text before the wrapped input to indicate its usage */
27
- labelText?: string;
8
+ config: FormFieldInputProps | FormFieldInputProps[];
28
9
  /** `Styling` Will adjust field's sections (label, input/s and helper) in horizontal position */
29
10
  isHorizontal?: boolean;
30
11
  /** `Styling` Will group the list of inputs in a same wrapper (useful for several inputs with same usage, as a complex address) */
@@ -1,4 +1 @@
1
- var E = /* @__PURE__ */ ((t) => (t.INPUT = "input", t.SELECT = "select", t.CHECKBOX = "checkbox", t.RADIOBUTTON = "radiobutton", t.TEXTAREA = "textarea", t))(E || {});
2
- export {
3
- E as FormFieldType
4
- };
1
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "reactive-bulma",
3
- "version": "4.3.0",
3
+ "version": "4.3.2",
4
4
  "type": "module",
5
5
  "description": "A component library based on React, Bulma, Typescript and Vite",
6
6
  "keywords": [
@@ -41,7 +41,7 @@
41
41
  "prettier": "prettier src/**/*.{tsx,ts} --write",
42
42
  "prettier:ci": "prettier src/**/*.{tsx,ts} --check",
43
43
  "lint-staged": "lint-staged -v",
44
- "setup": "npm ci && husky",
44
+ "setup": "npm ci",
45
45
  "compile": "tsc -b",
46
46
  "build": "npm run compile && vite build",
47
47
  "build:storybook": "storybook build",
@@ -86,7 +86,7 @@
86
86
  "@types/css-modules": "^1.0.5",
87
87
  "@types/jest": "^29.5.14",
88
88
  "@types/node": "^22.10.2",
89
- "@types/react": "^19.0.1",
89
+ "@types/react": "^19.0.2",
90
90
  "@types/react-dom": "^19.0.2",
91
91
  "@typescript-eslint/eslint-plugin": "^8.18.1",
92
92
  "@typescript-eslint/parser": "^8.18.1",
@@ -101,13 +101,12 @@
101
101
  "eslint-plugin-react-refresh": "^0.4.16",
102
102
  "eslint-plugin-storybook": "^0.11.1",
103
103
  "glob": "^11.0.0",
104
- "globals": "^15.13.0",
105
- "husky": "^9.1.7",
104
+ "globals": "^15.14.0",
106
105
  "hygen": "^6.2.11",
107
106
  "jest": "^29.7.0",
108
107
  "jest-environment-jsdom": "^29.7.0",
109
108
  "lint-staged": "^15.2.11",
110
- "npm-check-updates": "^17.1.11",
109
+ "npm-check-updates": "^17.1.12",
111
110
  "prettier": "^3.4.2",
112
111
  "react": "^18.3.1",
113
112
  "react-dom": "^18.3.1",
@@ -116,8 +115,8 @@
116
115
  "tslib": "^2.8.1",
117
116
  "typescript": "~5.7.2",
118
117
  "typescript-eslint": "^8.18.1",
119
- "vite": "^6.0.3",
120
- "vite-plugin-dts": "^4.3.0"
118
+ "vite": "^6.0.5",
119
+ "vite-plugin-dts": "^4.4.0"
121
120
  },
122
121
  "lint-staged": {
123
122
  "src/**/*.(ts|tsx)": [