@hortiview/shared-components 2.8.7 → 2.8.8

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/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## [2.8.8](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/compare/v2.8.7...v2.8.8) (2025-12-19)
2
+
3
+ ### Bug Fixes
4
+
5
+ * alignment issue with helpertext for select component ([8eba98f](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/commit/8eba98f4872a84c755e3719b375478cb9b73f508))
6
+
1
7
  ## [2.8.7](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/compare/v2.8.6...v2.8.7) (2025-12-18)
2
8
 
3
9
  ### Code Refactoring
@@ -1 +1 @@
1
- ._invalidHelperText_1qcz0_1+*[class*=mdc-select-helper-text]{color:var(--lmnt-theme-danger)!important}._invalidBorder_1qcz0_5 *[class*=mdc-notched-outline]{border-color:var(--lmnt-theme-danger)!important}._invalidPlaceholder_1qcz0_9 *[class*=lmnt-select-label]{color:var(--lmnt-theme-danger)!important}._invalidDropdownIcon_1qcz0_13 *[class*=mdc-select__dropdown-icon]{fill:var(--lmnt-theme-danger)!important}._formSelectContainer_1qcz0_18{display:flex;flex-wrap:wrap;width:100%}._formSelectContainer_1qcz0_18 *[class*=mdc-select-helper-text]{color:var(--lmnt-helper-text-color)}._formSelectContainer_1qcz0_18 *[class*=lmnt__multi-value__label]{overflow:visible}._formSelect_1qcz0_18 *[class*=lmnt-select-menu]{z-index:2001}._multiText_1qcz0_40 *[class*=lmnt-select-value-container]{white-space:nowrap;overflow:hidden!important;text-overflow:ellipsis;display:block!important;padding:1.125rem 0!important}._tooltip_1qcz0_49{z-index:42}._disabled_1qcz0_54+*[class*=mdc-select-helper-text]{color:var(--lmnt-theme-on-surface-disabled)}[id*=select-container][class*=top] [class*=mdc-menu-surface--open]{bottom:0}[id*=select-container][class*=bottom] [class*=mdc-menu-surface--open]{top:0}
1
+ ._invalidHelperText_u3es9_1+*[class*=mdc-select-helper-text]{color:var(--lmnt-theme-danger)!important}._invalidBorder_u3es9_5 *[class*=mdc-notched-outline]{border-color:var(--lmnt-theme-danger)!important}._invalidPlaceholder_u3es9_9 *[class*=lmnt-select-label]{color:var(--lmnt-theme-danger)!important}._invalidDropdownIcon_u3es9_13 *[class*=mdc-select__dropdown-icon]{fill:var(--lmnt-theme-danger)!important}._formSelectContainer_u3es9_18{display:flex;flex-wrap:wrap;width:100%}._formSelectContainer_u3es9_18>*[class*=lmnt-select-container]{flex-direction:column}._formSelectContainer_u3es9_18 *[class*=mdc-select-helper-text]{color:var(--lmnt-helper-text-color);align-self:flex-start}._formSelectContainer_u3es9_18 *[class*=lmnt__multi-value__label]{overflow:visible}._formSelect_u3es9_18 *[class*=lmnt-select-menu]{z-index:2001}._multiText_u3es9_45 *[class*=lmnt-select-value-container]{white-space:nowrap;overflow:hidden!important;text-overflow:ellipsis;display:block!important;padding:1.125rem 0!important}._tooltip_u3es9_54{z-index:42}._disabled_u3es9_59+*[class*=mdc-select-helper-text]{color:var(--lmnt-theme-on-surface-disabled)}[id*=select-container][class*=top] [class*=mdc-menu-surface--open]{bottom:0}[id*=select-container][class*=bottom] [class*=mdc-menu-surface--open]{top:0}
@@ -1,13 +1,13 @@
1
- import { jsx as o, Fragment as g, jsxs as k } from "react/jsx-runtime";
2
- import { g as x } from "../../../get-DuK51wnj.js";
1
+ import { jsx as o, Fragment as C, jsxs as z } from "react/jsx-runtime";
2
+ import { g as _ } from "../../../get-DuK51wnj.js";
3
3
  import { i as G } from "../../../isArray-Dub1wGJM.js";
4
- import { useMemo as z } from "react";
5
- import { useFormContext as J, Controller as C } from "react-hook-form";
4
+ import { useMemo as $ } from "react";
5
+ import { useFormContext as J, Controller as H } from "react-hook-form";
6
6
  import { M as L } from "../../../react-tooltip.min-DSY6KDqS.js";
7
7
  import { useHelperText as O } from "../../../hooks/useHelperText.js";
8
8
  import { Select as Q } from "../../Select/Select.js";
9
9
  import { SelectTooltipText as R } from "./SelectTooltipText.js";
10
- import '../../../assets/FormSelect.css';const U = "_invalidHelperText_1qcz0_1", W = "_invalidBorder_1qcz0_5", X = "_invalidPlaceholder_1qcz0_9", Y = "_invalidDropdownIcon_1qcz0_13", Z = "_formSelectContainer_1qcz0_18", N = "_formSelect_1qcz0_18", y = "_multiText_1qcz0_40", K = "_tooltip_1qcz0_49", ee = "_disabled_1qcz0_54", t = {
10
+ import '../../../assets/FormSelect.css';const U = "_invalidHelperText_u3es9_1", W = "_invalidBorder_u3es9_5", X = "_invalidPlaceholder_u3es9_9", Y = "_invalidDropdownIcon_u3es9_13", Z = "_formSelectContainer_u3es9_18", N = "_formSelect_u3es9_18", y = "_multiText_u3es9_45", K = "_tooltip_u3es9_54", ee = "_disabled_u3es9_59", t = {
11
11
  invalidHelperText: U,
12
12
  invalidBorder: W,
13
13
  invalidPlaceholder: X,
@@ -19,109 +19,109 @@ import '../../../assets/FormSelect.css';const U = "_invalidHelperText_1qcz0_1",
19
19
  disabled: ee
20
20
  }, fe = ({
21
21
  propertyName: i,
22
- label: s,
22
+ label: c,
23
23
  options: r,
24
24
  multi: a = !1,
25
- disabled: h = !1,
26
- hoisted: $ = !1,
27
- hidden: H = !1,
25
+ disabled: x = !1,
26
+ hoisted: I = !1,
27
+ hidden: w = !1,
28
28
  valueKey: n = "value",
29
- textKey: u = "text",
30
- clearable: I = !1,
31
- searchable: w = !0,
29
+ textKey: h = "text",
30
+ clearable: D = !1,
31
+ searchable: P = !0,
32
32
  noOptionsMessage: T = "",
33
33
  rules: f,
34
- menuPosition: D = "auto",
34
+ menuPosition: B = "auto",
35
35
  ...l
36
36
  }) => {
37
37
  const {
38
38
  control: v,
39
- getFieldState: P,
40
- formState: { errors: S, isValidating: q }
41
- } = J(), B = z(
42
- () => !q && x(S, i) !== void 0,
43
- [S, i, q]
44
- ), F = z(
39
+ getFieldState: F,
40
+ formState: { errors: S, isValidating: p }
41
+ } = J(), b = $(
42
+ () => !p && _(S, i) !== void 0,
43
+ [S, i, p]
44
+ ), M = $(
45
45
  () => f?.required?.message,
46
46
  [f]
47
- ), { helperText: b, helperTextPersistent: M } = O({
47
+ ), { helperText: j, helperTextPersistent: q } = O({
48
48
  propertyName: i,
49
49
  helperText: l.helperText,
50
- requiredText: F,
50
+ requiredText: M,
51
51
  hasCharacterCount: !1
52
52
  });
53
- return H ? /* @__PURE__ */ o(C, { name: i, control: v, render: () => /* @__PURE__ */ o(g, {}) }) : /* @__PURE__ */ o(
53
+ return w ? /* @__PURE__ */ o(H, { name: i, control: v, render: () => /* @__PURE__ */ o(C, {}) }) : /* @__PURE__ */ o(
54
54
  "div",
55
55
  {
56
56
  "data-testid": "form-select-container",
57
57
  className: t.formSelectContainer,
58
- "data-tooltip-id": s,
58
+ "data-tooltip-id": c,
59
59
  children: /* @__PURE__ */ o(
60
- C,
60
+ H,
61
61
  {
62
62
  name: i,
63
63
  rules: f,
64
64
  control: v,
65
- render: ({ field: { ref: te, onChange: m, value: p, ...j } }) => {
66
- let _ = r;
67
- G(r) && x(r[0], "options") !== void 0 && (_ = r.flatMap((e) => x(e, "options") ?? []));
68
- const d = a ? _?.filter(
69
- (e) => p?.includes(e[n])
70
- ) : _?.find((e) => e[n] === p), A = a && l.multiDisplayType === "text" && l.fixedHeightInput, c = P(i).invalid, E = `
65
+ render: ({ field: { ref: te, onChange: m, value: g, ...A } }) => {
66
+ let u = r;
67
+ G(r) && _(r[0], "options") !== void 0 && (u = r.flatMap((e) => _(e, "options") ?? []));
68
+ const d = a ? u?.filter(
69
+ (e) => g?.includes(e[n])
70
+ ) : u?.find((e) => e[n] === g), E = a && l.multiDisplayType === "text" && l.fixedHeightInput, s = F(i).invalid, V = `
71
71
  ${t.formSelect}
72
- ${c ? t.invalidHelperText : ""}
73
- ${c ? t.invalidDropdownIcon : ""}
74
- ${c ? t.invalidBorder : ""}
75
- ${c ? t.invalidPlaceholder : ""}
76
- ${A ? t.multiText : ""}
77
- ${h ? t.disabled : ""}`;
78
- return /* @__PURE__ */ k(g, { children: [
72
+ ${s ? t.invalidHelperText : ""}
73
+ ${s ? t.invalidDropdownIcon : ""}
74
+ ${s ? t.invalidBorder : ""}
75
+ ${s ? t.invalidPlaceholder : ""}
76
+ ${E ? t.multiText : ""}
77
+ ${x ? t.disabled : ""}`;
78
+ return /* @__PURE__ */ z(C, { children: [
79
79
  /* @__PURE__ */ o(
80
80
  Q,
81
81
  {
82
- ...j,
82
+ ...A,
83
83
  ...l,
84
84
  value: d ?? [],
85
- label: s,
85
+ label: c,
86
86
  variant: "outlined",
87
- helperText: b,
88
- helperTextPersistent: M,
87
+ helperText: j,
88
+ helperTextPersistent: q,
89
89
  options: r,
90
- valid: !B,
90
+ valid: !b,
91
91
  "data-testid": l["data-testid"] ?? `select-${i}`,
92
92
  multiSelect: !r?.length && T ? !1 : a,
93
- className: E,
94
- disabled: h,
93
+ className: V,
94
+ disabled: x,
95
95
  valueKey: n,
96
- textKey: u,
96
+ textKey: h,
97
97
  onChange: (e) => {
98
98
  if (e == null) {
99
99
  m(e);
100
100
  return;
101
101
  }
102
102
  if (a) {
103
- m(e.map((V) => V[n]));
103
+ m(e.map((k) => k[n]));
104
104
  return;
105
105
  }
106
106
  m(e[n]), l?.onChange?.(e);
107
107
  },
108
- hoisted: $,
108
+ hoisted: I,
109
109
  noOptionsMessage: T,
110
- searchable: w,
111
- clearable: I,
112
- menuPosition: D
110
+ searchable: P,
111
+ clearable: D,
112
+ menuPosition: B
113
113
  }
114
114
  ),
115
115
  /* @__PURE__ */ o(
116
116
  L,
117
117
  {
118
- id: s,
118
+ id: c,
119
119
  noArrow: !0,
120
120
  place: "bottom",
121
121
  delayShow: 420,
122
122
  className: t.tooltip,
123
123
  hidden: !d || d.length === 0 || !l.fixedHeightInput,
124
- children: /* @__PURE__ */ o(R, { value: d, textKey: u, valueKey: n })
124
+ children: /* @__PURE__ */ o(R, { value: d, textKey: h, valueKey: n })
125
125
  }
126
126
  )
127
127
  ] });
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@hortiview/shared-components",
3
3
  "description": "This is a shared component library. It should used in the HortiView platform and its modules.",
4
- "version": "2.8.7",
4
+ "version": "2.8.8",
5
5
  "type": "module",
6
6
  "repository": "https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared",
7
7
  "author": "Falk Menge <falk.menge.ext@bayer.com>",