@hortiview/shared-components 2.19.0 → 2.20.0
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,17 @@
|
|
|
1
|
+
## [2.20.0](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/compare/v2.19.1...v2.20.0) (2026-03-24)
|
|
2
|
+
|
|
3
|
+
### Features
|
|
4
|
+
|
|
5
|
+
* add new country keys for Netherlands and Canada in AVAILABLE_COUNTRY_KEYS ([2fdd83d](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/commit/2fdd83dd30c4e72f54b8a3401f98a9ab0ed55ec9))
|
|
6
|
+
|
|
7
|
+
## [2.19.1](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/compare/v2.19.0...v2.19.1) (2026-03-24)
|
|
8
|
+
|
|
9
|
+
### Code Refactoring
|
|
10
|
+
|
|
11
|
+
* add variant prop to SearchBar and update ListArea usage ([49dda20](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/commit/49dda20ad8db46234d2f87f24519736f6b9ec746))
|
|
12
|
+
* remove centered layout from stories and add BasicLayout as decorator to preview ([7c03c49](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/commit/7c03c497c96978eea35b98256627ded9378827c8))
|
|
13
|
+
* replace FullWidthDecorator with BasicLayout in Storybook preview ([b44d297](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/commit/b44d29716a79f80ddae02774fcd8fedae397078b))
|
|
14
|
+
|
|
1
15
|
## [2.19.0](https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared/compare/v2.18.1...v2.19.0) (2026-03-18)
|
|
2
16
|
|
|
3
17
|
### Features
|
|
@@ -3,8 +3,8 @@ import { D } from "../../index.es-C27R5Xae.js";
|
|
|
3
3
|
import { E as j } from "../../index.es-DhlgTSuU.js";
|
|
4
4
|
import { L as A } from "../../index.es-Cg57snrN.js";
|
|
5
5
|
import { c as p } from "../../index-Df2FYN-K.js";
|
|
6
|
-
import { o as
|
|
7
|
-
import { useState as E, useMemo as
|
|
6
|
+
import { o as v } from "../../orderBy-Ce85KqD6.js";
|
|
7
|
+
import { useState as E, useMemo as w } from "react";
|
|
8
8
|
import { SearchBar as I } from "../SearchBar/SearchBar.js";
|
|
9
9
|
import { g as M, a as N, s as e } from "../../ListAreaService-Y8wR14Xq.js";
|
|
10
10
|
const G = ({
|
|
@@ -15,21 +15,21 @@ const G = ({
|
|
|
15
15
|
searchPlaceholder: g = "",
|
|
16
16
|
isIntegrated: x = !0,
|
|
17
17
|
isSorted: l = !0,
|
|
18
|
-
itemClassName:
|
|
18
|
+
itemClassName: d = "",
|
|
19
19
|
maxHeight: T = "100%",
|
|
20
|
-
noElementsView:
|
|
20
|
+
noElementsView: b,
|
|
21
21
|
hasLastItemNoRoundedEdges: m = !1,
|
|
22
|
-
"data-testid":
|
|
22
|
+
"data-testid": y,
|
|
23
23
|
nonInteractive: n = !1,
|
|
24
|
-
routerLinkElement:
|
|
24
|
+
routerLinkElement: c
|
|
25
25
|
}) => {
|
|
26
|
-
const [r,
|
|
27
|
-
if (!r) return l ?
|
|
26
|
+
const [r, C] = E(""), s = w(() => {
|
|
27
|
+
if (!r) return l ? v(t, "title") : t;
|
|
28
28
|
const u = t.filter((f) => f.title.toLowerCase().includes(r.toLowerCase()) || f.subTitle?.toLowerCase().includes(r.toLowerCase()) || f.overlineTitle?.toLowerCase().includes(r.toLowerCase()));
|
|
29
|
-
return l ?
|
|
30
|
-
}, [r, t, l]), B =
|
|
31
|
-
() => i ? M(s, o,
|
|
32
|
-
[s, o,
|
|
29
|
+
return l ? v(u, "title") : u;
|
|
30
|
+
}, [r, t, l]), B = w(
|
|
31
|
+
() => i ? M(s, o, d, c) : N(s, o, d, c),
|
|
32
|
+
[s, o, d, i, c]
|
|
33
33
|
);
|
|
34
34
|
return /* @__PURE__ */ a(
|
|
35
35
|
j,
|
|
@@ -43,19 +43,20 @@ const G = ({
|
|
|
43
43
|
I,
|
|
44
44
|
{
|
|
45
45
|
searchTerm: r,
|
|
46
|
-
setSearchTerm:
|
|
46
|
+
setSearchTerm: C,
|
|
47
47
|
className: e.searchbar,
|
|
48
|
-
placeholder: g
|
|
48
|
+
placeholder: g,
|
|
49
|
+
variant: "embedded"
|
|
49
50
|
}
|
|
50
51
|
),
|
|
51
52
|
/* @__PURE__ */ a(D, {})
|
|
52
53
|
] }),
|
|
53
|
-
s.length === 0 &&
|
|
54
|
+
s.length === 0 && b,
|
|
54
55
|
/* @__PURE__ */ a(
|
|
55
56
|
A,
|
|
56
57
|
{
|
|
57
58
|
nonInteractive: n,
|
|
58
|
-
"data-testid":
|
|
59
|
+
"data-testid": y,
|
|
59
60
|
items: B,
|
|
60
61
|
className: p(
|
|
61
62
|
e.list,
|
|
@@ -9,6 +9,11 @@ type SearchBarProps = Pick<TextfieldProps, 'placeholder' | 'dense' | 'className'
|
|
|
9
9
|
* the function to set the search term
|
|
10
10
|
*/
|
|
11
11
|
setSearchTerm: (value: string) => void;
|
|
12
|
+
/**
|
|
13
|
+
* Applies the selected styling to the SearchBar.
|
|
14
|
+
* @default outlined
|
|
15
|
+
*/
|
|
16
|
+
variant?: 'embedded' | 'outlined' | 'filled';
|
|
12
17
|
};
|
|
13
|
-
export declare const SearchBar: ({ className, dense, searchTerm, setSearchTerm, placeholder, fullWidth, label }: SearchBarProps) => import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare const SearchBar: ({ className, dense, searchTerm, setSearchTerm, placeholder, fullWidth, label, variant, }: SearchBarProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
19
|
export {};
|
|
@@ -1,30 +1,31 @@
|
|
|
1
1
|
import { jsx as o } from "react/jsx-runtime";
|
|
2
|
-
import { I as
|
|
3
|
-
import { T as
|
|
4
|
-
import '../../assets/SearchBar.css';const
|
|
5
|
-
searchbar:
|
|
6
|
-
},
|
|
2
|
+
import { I as u } from "../../index.es-CkB4776y.js";
|
|
3
|
+
import { T as b } from "../../index.es-B9BUXRQn.js";
|
|
4
|
+
import '../../assets/SearchBar.css';const d = "_searchbar_g83qp_1", p = {
|
|
5
|
+
searchbar: d
|
|
6
|
+
}, m = ({
|
|
7
7
|
className: r = "",
|
|
8
8
|
dense: e = !1,
|
|
9
9
|
searchTerm: t,
|
|
10
10
|
setSearchTerm: a,
|
|
11
|
-
placeholder:
|
|
12
|
-
fullWidth:
|
|
13
|
-
label: c
|
|
11
|
+
placeholder: s,
|
|
12
|
+
fullWidth: n = !0,
|
|
13
|
+
label: c,
|
|
14
|
+
variant: i = "outlined"
|
|
14
15
|
}) => /* @__PURE__ */ o(
|
|
15
|
-
|
|
16
|
+
b,
|
|
16
17
|
{
|
|
17
18
|
"data-testid": "search-bar-input",
|
|
18
|
-
className: `${r ?? ""} ${
|
|
19
|
+
className: `${r ?? ""} ${p.searchbar}`,
|
|
19
20
|
dense: e,
|
|
20
21
|
label: c,
|
|
21
|
-
variant:
|
|
22
|
-
placeholder:
|
|
22
|
+
variant: i,
|
|
23
|
+
placeholder: s,
|
|
23
24
|
value: t,
|
|
24
|
-
onChange: (
|
|
25
|
-
fullWidth:
|
|
25
|
+
onChange: (l) => a(l.target.value),
|
|
26
|
+
fullWidth: n,
|
|
26
27
|
trailingIcon: /* @__PURE__ */ o(
|
|
27
|
-
|
|
28
|
+
u,
|
|
28
29
|
{
|
|
29
30
|
"data-testid": "search-bar-icon-button",
|
|
30
31
|
icon: t ? "close" : "search",
|
|
@@ -35,5 +36,5 @@ import '../../assets/SearchBar.css';const b = "_searchbar_g83qp_1", d = {
|
|
|
35
36
|
}
|
|
36
37
|
);
|
|
37
38
|
export {
|
|
38
|
-
|
|
39
|
+
m as SearchBar
|
|
39
40
|
};
|
package/dist/types/Languages.js
CHANGED
|
@@ -7,17 +7,17 @@ const A = "bb8077e3-ad50-4c1d-8b17-b768b1c9f041", e = "bb8077e3-ad50-4c1d-8b17-b
|
|
|
7
7
|
"es",
|
|
8
8
|
"tr"
|
|
9
9
|
// 'de' currently not supported
|
|
10
|
-
],
|
|
10
|
+
], n = {
|
|
11
11
|
en: "en-US",
|
|
12
12
|
es: "es-MX",
|
|
13
13
|
tr: "tr-TR"
|
|
14
|
-
},
|
|
14
|
+
}, t = ["esp", "mex", "tur", "nld", "can"];
|
|
15
15
|
export {
|
|
16
|
-
|
|
16
|
+
t as AVAILABLE_COUNTRY_KEYS,
|
|
17
17
|
_ as AVAILABLE_LOCALES,
|
|
18
18
|
A as ENGLISH_LANGUAGE_ID,
|
|
19
19
|
e as GERMAN_LANGUAGE_ID,
|
|
20
|
-
|
|
20
|
+
n as LANGUAGE_CODES_MAPPER,
|
|
21
21
|
E as LANGUAGE_ID_MAPPER,
|
|
22
22
|
b as SPANISH_LANGUAGE_ID,
|
|
23
23
|
c as TURKISH_LANGUAGE_ID
|
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.
|
|
4
|
+
"version": "2.20.0",
|
|
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>",
|