@oneplatformdev/ui 0.0.1-beta.37 → 0.0.1-beta.39

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,38 +1,40 @@
1
1
  import { jsx as e } from "react/jsx-runtime";
2
- import { FormControl as a } from "../Form/Form.mjs";
3
- import { FormRenderControl as f } from "../Form/FormRenderControl.mjs";
2
+ import { FormControl as f } from "../Form/Form.mjs";
3
+ import { FormRenderControl as d } from "../Form/FormRenderControl.mjs";
4
4
  import "../Select/SelectRoot.mjs";
5
- import { Select as d } from "../Select/Select.mjs";
6
- const x = (m) => {
5
+ import { Select as g } from "../Select/Select.mjs";
6
+ const S = (n) => {
7
7
  const {
8
- form: n,
8
+ form: m,
9
9
  label: i,
10
- name: l,
11
- options: p = [],
10
+ name: p,
11
+ options: l = [],
12
12
  onChange: r,
13
- ...c
14
- } = m;
13
+ containerProps: c,
14
+ ...s
15
+ } = n;
15
16
  return /* @__PURE__ */ e(
16
- f,
17
+ d,
17
18
  {
18
- form: n,
19
- name: l,
19
+ form: m,
20
+ name: p,
20
21
  label: i,
22
+ containerProps: c,
21
23
  render: ({ field: t }) => /* @__PURE__ */ e(
22
- d,
24
+ g,
23
25
  {
24
26
  value: t.value,
25
- options: p,
27
+ options: l,
26
28
  onChange: (o) => {
27
29
  t.onChange(o), r == null || r(o);
28
30
  },
29
- renderTrigger: (o, s) => /* @__PURE__ */ e(a, { children: s }),
30
- ...c
31
+ renderTrigger: (o, a) => /* @__PURE__ */ e(f, { children: a }),
32
+ ...s
31
33
  }
32
34
  )
33
35
  }
34
36
  );
35
37
  };
36
38
  export {
37
- x as FormSelect
39
+ S as FormSelect
38
40
  };
@@ -1,7 +1,6 @@
1
- import { PartialOne } from '../../../utils/src';
2
1
  import { SelectProps } from '../Select';
3
2
  import { FormRenderControlExtendProps } from '../Form';
4
3
  import { FieldValues } from 'react-hook-form/dist/types/fields';
5
4
 
6
- export interface FormSelectProps<Data extends FieldValues, ExtendOptionData> extends FormRenderControlExtendProps<Data>, PartialOne<SelectProps<ExtendOptionData>, 'onChange'> {
5
+ export interface FormSelectProps<Data extends FieldValues, ExtendOptionData> extends FormRenderControlExtendProps<Data>, SelectProps<ExtendOptionData> {
7
6
  }
@@ -1,26 +1,27 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { FormControl as l } from "../Form/Form.mjs";
3
- import { FormRenderControl as p } from "../Form/FormRenderControl.mjs";
4
- import { Textarea as f } from "../Textarea/Textarea.mjs";
5
- const u = (e) => {
6
- const { form: m, label: t, name: n, ...a } = e;
2
+ import { FormControl as p } from "../Form/Form.mjs";
3
+ import { FormRenderControl as i } from "../Form/FormRenderControl.mjs";
4
+ import { Textarea as s } from "../Textarea/Textarea.mjs";
5
+ const F = (e) => {
6
+ const { form: t, label: m, name: n, containerProps: a, ...l } = e;
7
7
  return /* @__PURE__ */ r(
8
- p,
8
+ i,
9
9
  {
10
- form: m,
10
+ form: t,
11
11
  name: n,
12
- label: t,
13
- render: ({ field: o }) => /* @__PURE__ */ r(l, { children: /* @__PURE__ */ r(
14
- f,
12
+ label: m,
13
+ containerProps: a,
14
+ render: ({ field: o }) => /* @__PURE__ */ r(p, { children: /* @__PURE__ */ r(
15
+ s,
15
16
  {
16
17
  ...o,
17
18
  value: o.value || "",
18
- ...a
19
+ ...l
19
20
  }
20
21
  ) })
21
22
  }
22
23
  );
23
24
  };
24
25
  export {
25
- u as FormTextarea
26
+ F as FormTextarea
26
27
  };
@@ -9,9 +9,9 @@ const u = ({
9
9
  f.useEffect(() => {
10
10
  const e = r.current;
11
11
  if (e) {
12
- c && (e.style.minHeight = `${s + 6}px`, t > s && (e.style.maxHeight = `${t}px`), i(!1)), e.style.height = `${s + 6}px`;
12
+ c && (e.style.minHeight = `${s + 0}px`, t > s && (e.style.maxHeight = `${t}px`), i(!1)), e.style.height = `${s + 0}px`;
13
13
  const o = e.scrollHeight;
14
- o > t ? e.style.height = `${t}px` : e.style.height = `${o + 6}px`;
14
+ o > t ? e.style.height = `${t}px` : e.style.height = `${o + 0}px`;
15
15
  }
16
16
  }, [r.current, l]);
17
17
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oneplatformdev/ui",
3
- "version": "0.0.1-beta.37",
3
+ "version": "0.0.1-beta.39",
4
4
  "description": "UI React Components.",
5
5
  "author": "One Platform Development Team",
6
6
  "keywords": [