@phillips/seldon 1.33.0 → 1.35.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/dist/components/Accordion/AccordionItem.d.ts +5 -1
- package/dist/components/Accordion/AccordionItem.js +59 -58
- package/dist/components/Button/Button.d.ts +2 -1
- package/dist/components/Button/Button.js +17 -16
- package/dist/components/Button/types.d.ts +5 -0
- package/dist/components/Button/types.js +4 -0
- package/dist/components/Footer/Footer.d.ts +1 -1
- package/dist/components/Footer/Footer.js +12 -10
- package/dist/components/Header/Header.js +34 -34
- package/dist/components/IconButton/IconButton.js +13 -12
- package/dist/components/Search/Search.d.ts +44 -3
- package/dist/components/Search/Search.js +113 -43
- package/dist/components/Search/SearchResults/SearchResults.d.ts +13 -0
- package/dist/components/Search/SearchResults/SearchResults.js +16 -0
- package/dist/components/Social/Social.d.ts +10 -1
- package/dist/components/Social/Social.js +19 -9
- package/dist/components/Subscribe/Subscribe.js +37 -27
- package/dist/components/ViewingsList/ViewingsListCard.js +145 -114
- package/dist/index.d.ts +1 -0
- package/dist/index.js +84 -80
- package/dist/scss/components/Footer/_footer.scss +79 -32
- package/dist/scss/components/Input/_input.scss +2 -1
- package/dist/scss/components/Navigation/NavigationItem/_navigationItem.scss +2 -2
- package/dist/scss/components/Search/_search.scss +54 -5
- package/dist/scss/components/Social/_social.scss +44 -6
- package/dist/utils/index.d.ts +10 -0
- package/dist/utils/index.js +40 -31
- package/package.json +2 -2
|
@@ -32,6 +32,10 @@ export interface AccordionItemProps extends React.HTMLAttributes<HTMLDivElement>
|
|
|
32
32
|
* When true applied the transition keyframe animation on item expand. Default as false.
|
|
33
33
|
*/
|
|
34
34
|
hasTransition?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* When true, isCollapsed won't be toggled.
|
|
37
|
+
*/
|
|
38
|
+
isControlled?: boolean;
|
|
35
39
|
}
|
|
36
|
-
declare const AccordionItem: ({ isLocked, isLockedVariation, variation, label, isLastItem, hasTransition, children, type, ...props }: AccordionItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
declare const AccordionItem: ({ isLocked, isLockedVariation, variation, label, isLastItem, hasTransition, children, type, isControlled, ...props }: AccordionItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
37
41
|
export default AccordionItem;
|
|
@@ -1,38 +1,38 @@
|
|
|
1
1
|
import { jsxs as f, jsx as e, Fragment as h } from "react/jsx-runtime";
|
|
2
|
-
import { useState as
|
|
3
|
-
import { getCommonProps as x } from "../../utils/index.js";
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import { Item as
|
|
9
|
-
const
|
|
10
|
-
children:
|
|
2
|
+
import { useState as p } from "react";
|
|
3
|
+
import { getCommonProps as v, noOp as x } from "../../utils/index.js";
|
|
4
|
+
import C from "../../assets/plus.svg.js";
|
|
5
|
+
import A from "../../assets/minus.svg.js";
|
|
6
|
+
import T from "../../assets/lock.svg.js";
|
|
7
|
+
import s from "../../node_modules/classnames/index.js";
|
|
8
|
+
import { Item as j, Trigger as k, Content as N } from "../../node_modules/@radix-ui/react-accordion/dist/index.js";
|
|
9
|
+
const B = ({
|
|
10
|
+
children: n,
|
|
11
11
|
className: c,
|
|
12
12
|
baseClassName: t,
|
|
13
|
-
disable:
|
|
14
|
-
isCollapsed:
|
|
13
|
+
disable: o,
|
|
14
|
+
isCollapsed: r,
|
|
15
15
|
setIsCollapsed: d,
|
|
16
|
-
isLargeVariation:
|
|
17
|
-
isLockedVariation:
|
|
18
|
-
id:
|
|
16
|
+
isLargeVariation: i,
|
|
17
|
+
isLockedVariation: m,
|
|
18
|
+
id: a
|
|
19
19
|
}) => {
|
|
20
|
-
const
|
|
20
|
+
const l = () => !o && d((I) => !I), u = o ? T : r ? C : A, $ = `${a}-` + (o ? "lockedIcon" : m ? "lockBlueIcon" : r ? "plusIcon" : "minusIcon");
|
|
21
21
|
return /* @__PURE__ */ e(
|
|
22
|
-
|
|
22
|
+
k,
|
|
23
23
|
{
|
|
24
|
-
"data-disabled":
|
|
24
|
+
"data-disabled": o,
|
|
25
25
|
asChild: !0,
|
|
26
|
-
className:
|
|
27
|
-
children: /* @__PURE__ */ f("div", { onClick:
|
|
28
|
-
/* @__PURE__ */ e("div", { className:
|
|
26
|
+
className: s(t, { [`${t}--hoverable`]: !o }, c),
|
|
27
|
+
children: /* @__PURE__ */ f("div", { onClick: l, "data-testid": `${a}-trigger`, children: [
|
|
28
|
+
/* @__PURE__ */ e("div", { className: s(`${t}__text`, { [`${t}__text--lg`]: i }), children: n }),
|
|
29
29
|
/* @__PURE__ */ e(
|
|
30
30
|
"img",
|
|
31
31
|
{
|
|
32
|
-
className:
|
|
32
|
+
className: s(
|
|
33
33
|
`${t}__icon`,
|
|
34
|
-
{ [`${t}__icon--lg`]:
|
|
35
|
-
|
|
34
|
+
{ [`${t}__icon--lg`]: i },
|
|
35
|
+
m && `${t}--blue-fill`
|
|
36
36
|
),
|
|
37
37
|
src: u,
|
|
38
38
|
"data-testid": $,
|
|
@@ -42,67 +42,68 @@ const N = ({
|
|
|
42
42
|
] })
|
|
43
43
|
}
|
|
44
44
|
);
|
|
45
|
-
},
|
|
46
|
-
children:
|
|
45
|
+
}, F = ({
|
|
46
|
+
children: n,
|
|
47
47
|
baseClassName: c,
|
|
48
48
|
disable: t,
|
|
49
|
-
hasTransition:
|
|
50
|
-
isLargeVariation:
|
|
49
|
+
hasTransition: o,
|
|
50
|
+
isLargeVariation: r,
|
|
51
51
|
isCollapsed: d,
|
|
52
|
-
className:
|
|
53
|
-
}) => /* @__PURE__ */ e(h, { children: t &&
|
|
54
|
-
|
|
52
|
+
className: i
|
|
53
|
+
}) => /* @__PURE__ */ e(h, { children: t && n ? /* @__PURE__ */ e("div", { children: n }) : /* @__PURE__ */ e(
|
|
54
|
+
N,
|
|
55
55
|
{
|
|
56
56
|
asChild: !0,
|
|
57
|
-
className:
|
|
58
|
-
{ [`${c}__content--lg`]:
|
|
59
|
-
{ [`${c}--transition`]:
|
|
57
|
+
className: s(
|
|
58
|
+
{ [`${c}__content--lg`]: r },
|
|
59
|
+
{ [`${c}--transition`]: o },
|
|
60
60
|
{ [`${c}--expanded`]: !d },
|
|
61
|
-
|
|
61
|
+
i
|
|
62
62
|
),
|
|
63
|
-
children:
|
|
63
|
+
children: n
|
|
64
64
|
}
|
|
65
|
-
) }),
|
|
66
|
-
isLocked:
|
|
65
|
+
) }), D = ({
|
|
66
|
+
isLocked: n,
|
|
67
67
|
isLockedVariation: c,
|
|
68
68
|
variation: t,
|
|
69
|
-
label:
|
|
70
|
-
isLastItem:
|
|
69
|
+
label: o,
|
|
70
|
+
isLastItem: r,
|
|
71
71
|
hasTransition: d = !1,
|
|
72
|
-
children:
|
|
73
|
-
type:
|
|
74
|
-
|
|
72
|
+
children: i,
|
|
73
|
+
type: m = "single",
|
|
74
|
+
isControlled: a = !0,
|
|
75
|
+
...l
|
|
75
76
|
}) => {
|
|
76
|
-
const [
|
|
77
|
+
const [u, $] = p(!0), { className: I } = v(l, "Accordion"), _ = t === "lg", g = `${I}-item`;
|
|
77
78
|
return /* @__PURE__ */ f(
|
|
78
|
-
|
|
79
|
+
j,
|
|
79
80
|
{
|
|
80
|
-
disabled:
|
|
81
|
-
value:
|
|
82
|
-
className:
|
|
81
|
+
disabled: n,
|
|
82
|
+
value: o,
|
|
83
|
+
className: s(g, { [`${g}__border-bottom`]: !r }),
|
|
83
84
|
children: [
|
|
84
85
|
/* @__PURE__ */ e(
|
|
85
|
-
|
|
86
|
+
B,
|
|
86
87
|
{
|
|
87
|
-
disable:
|
|
88
|
+
disable: n,
|
|
88
89
|
isLargeVariation: _,
|
|
89
90
|
isLockedVariation: c,
|
|
90
|
-
isCollapsed:
|
|
91
|
-
setIsCollapsed:
|
|
92
|
-
id:
|
|
91
|
+
isCollapsed: u,
|
|
92
|
+
setIsCollapsed: a ? $ : x,
|
|
93
|
+
id: m === "single" ? l == null ? void 0 : l.id : void 0,
|
|
93
94
|
baseClassName: `${g}-label`,
|
|
94
|
-
children:
|
|
95
|
+
children: o
|
|
95
96
|
}
|
|
96
97
|
),
|
|
97
98
|
/* @__PURE__ */ e(
|
|
98
|
-
|
|
99
|
+
F,
|
|
99
100
|
{
|
|
100
|
-
disable:
|
|
101
|
+
disable: n,
|
|
101
102
|
hasTransition: d,
|
|
102
103
|
isLargeVariation: _,
|
|
103
|
-
isCollapsed:
|
|
104
|
+
isCollapsed: u,
|
|
104
105
|
baseClassName: g,
|
|
105
|
-
children:
|
|
106
|
+
children: i
|
|
106
107
|
}
|
|
107
108
|
)
|
|
108
109
|
]
|
|
@@ -110,5 +111,5 @@ const N = ({
|
|
|
110
111
|
);
|
|
111
112
|
};
|
|
112
113
|
export {
|
|
113
|
-
|
|
114
|
+
D as default
|
|
114
115
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ButtonVariants } from './types';
|
|
1
2
|
export interface ButtonProps extends React.HTMLAttributes<HTMLButtonElement> {
|
|
2
3
|
/**
|
|
3
4
|
* Button contents
|
|
@@ -14,7 +15,7 @@ export interface ButtonProps extends React.HTMLAttributes<HTMLButtonElement> {
|
|
|
14
15
|
/**
|
|
15
16
|
* Is this the principal call to action on the page?
|
|
16
17
|
*/
|
|
17
|
-
|
|
18
|
+
variant?: ButtonVariants;
|
|
18
19
|
/**
|
|
19
20
|
* How large should the button be?
|
|
20
21
|
*/
|
|
@@ -1,42 +1,43 @@
|
|
|
1
1
|
import { jsx as c } from "react/jsx-runtime";
|
|
2
2
|
import p from "../../node_modules/classnames/index.js";
|
|
3
3
|
import { getCommonProps as u } from "../../utils/index.js";
|
|
4
|
-
import {
|
|
5
|
-
|
|
4
|
+
import { ButtonVariants as d } from "./types.js";
|
|
5
|
+
import { forwardRef as $ } from "react";
|
|
6
|
+
const b = $(
|
|
6
7
|
({
|
|
7
|
-
|
|
8
|
+
variant: s = d.primary,
|
|
8
9
|
size: a = "md",
|
|
9
10
|
children: m,
|
|
10
11
|
className: r,
|
|
11
|
-
isIconLast:
|
|
12
|
-
type:
|
|
13
|
-
isDisabled:
|
|
14
|
-
...
|
|
12
|
+
isIconLast: n = !1,
|
|
13
|
+
type: e = "button",
|
|
14
|
+
isDisabled: i = !1,
|
|
15
|
+
...t
|
|
15
16
|
}, f) => {
|
|
16
|
-
const { className: o, ...
|
|
17
|
+
const { className: o, ...l } = u(t, "Button");
|
|
17
18
|
return /* @__PURE__ */ c(
|
|
18
19
|
"button",
|
|
19
20
|
{
|
|
20
|
-
...
|
|
21
|
+
...l,
|
|
21
22
|
ref: f,
|
|
22
|
-
type:
|
|
23
|
+
type: e,
|
|
23
24
|
className: p(
|
|
24
25
|
`${o}`,
|
|
25
26
|
`${o}--${a}`,
|
|
26
|
-
`${o}--${
|
|
27
|
+
`${o}--${s}`,
|
|
27
28
|
{
|
|
28
|
-
[`${o}--icon-last`]:
|
|
29
|
+
[`${o}--icon-last`]: n
|
|
29
30
|
},
|
|
30
31
|
r
|
|
31
32
|
),
|
|
32
|
-
disabled:
|
|
33
|
-
...
|
|
33
|
+
disabled: i,
|
|
34
|
+
...t,
|
|
34
35
|
children: m
|
|
35
36
|
}
|
|
36
37
|
);
|
|
37
38
|
}
|
|
38
39
|
);
|
|
39
|
-
|
|
40
|
+
b.displayName = "Button";
|
|
40
41
|
export {
|
|
41
|
-
|
|
42
|
+
b as default
|
|
42
43
|
};
|
|
@@ -17,5 +17,5 @@ export interface FooterProps extends React.HTMLAttributes<HTMLElement> {
|
|
|
17
17
|
*
|
|
18
18
|
* [Storybook Link](https://phillips-seldon.netlify.app/?path=/docs/components-footer--overview)
|
|
19
19
|
*/
|
|
20
|
-
declare const Footer: ({ children, className, copyright, id,
|
|
20
|
+
declare const Footer: ({ children, className, copyright, id, }: FooterProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
21
|
export default Footer;
|
|
@@ -1,17 +1,19 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as a, jsx as o } from "react/jsx-runtime";
|
|
2
2
|
import i from "../../node_modules/classnames/index.js";
|
|
3
|
-
import { px as
|
|
4
|
-
import
|
|
3
|
+
import { px as e, defaultYear as m } from "../../utils/index.js";
|
|
4
|
+
import f from "../SplitPanel/SplitPanel.js";
|
|
5
|
+
import c from "../../assets/PhillipsLogo.svg.js";
|
|
5
6
|
const _ = ({
|
|
6
7
|
children: t,
|
|
7
|
-
className:
|
|
8
|
+
className: l,
|
|
8
9
|
copyright: s = `© ${m} Phillips Auctioneers, LLC`,
|
|
9
|
-
id:
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
/* @__PURE__ */
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
id: r
|
|
11
|
+
}) => /* @__PURE__ */ a("footer", { "data-testid": r || "footer", id: r, className: i(`${e}-footer`, { className: l }), children: [
|
|
12
|
+
/* @__PURE__ */ o(f, { className: `${e}-footer__content`, hasBorder: !1, children: t }),
|
|
13
|
+
/* @__PURE__ */ a("div", { className: `${e}-footer__copyright`, children: [
|
|
14
|
+
/* @__PURE__ */ o("h1", { "data-testid": "header-logo", className: `${e}-header__logo`, children: /* @__PURE__ */ o("a", { href: "/", "aria-label": "logo", children: /* @__PURE__ */ o(c, {}) }) }),
|
|
15
|
+
s
|
|
16
|
+
] })
|
|
15
17
|
] });
|
|
16
18
|
export {
|
|
17
19
|
_ as default
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as N, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import r from "../../node_modules/classnames/index.js";
|
|
3
|
-
import * as
|
|
4
|
-
import { px as a } from "../../utils/index.js";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
const
|
|
3
|
+
import * as i from "react";
|
|
4
|
+
import { findChildrenOfType as _, px as a } from "../../utils/index.js";
|
|
5
|
+
import x from "../Search/Search.js";
|
|
6
|
+
import P from "../../assets/PhillipsLogo.svg.js";
|
|
7
|
+
const j = i.createContext({
|
|
8
8
|
defaultMobileMenuLabel: "",
|
|
9
9
|
expandedItem: "",
|
|
10
10
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function
|
|
@@ -14,28 +14,28 @@ const N = c.createContext({
|
|
|
14
14
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function
|
|
15
15
|
onSelect: (t) => {
|
|
16
16
|
}
|
|
17
|
-
}),
|
|
17
|
+
}), R = ({
|
|
18
18
|
defaultMobileMenuLabel: t = "Main Menu",
|
|
19
|
-
logo:
|
|
20
|
-
className:
|
|
21
|
-
children:
|
|
22
|
-
toggleOpenText:
|
|
23
|
-
toggleCloseText:
|
|
24
|
-
logoText:
|
|
25
|
-
...
|
|
19
|
+
logo: s = /* @__PURE__ */ e(P, {}),
|
|
20
|
+
className: v,
|
|
21
|
+
children: l,
|
|
22
|
+
toggleOpenText: m = "Open Menu",
|
|
23
|
+
toggleCloseText: h = "Close Menu",
|
|
24
|
+
logoText: f = "Home Page",
|
|
25
|
+
...S
|
|
26
26
|
}) => {
|
|
27
|
-
const [
|
|
28
|
-
|
|
29
|
-
},
|
|
30
|
-
|
|
27
|
+
const $ = _(l, x), u = _(l, x, !0), [d, E] = i.useState(!1), [p, c] = i.useState(t), o = d ? h : m, y = p !== t, g = function() {
|
|
28
|
+
E((n) => !n), c(t);
|
|
29
|
+
}, I = function(n) {
|
|
30
|
+
c((C) => C === t ? n : t);
|
|
31
31
|
};
|
|
32
|
-
return /* @__PURE__ */
|
|
32
|
+
return /* @__PURE__ */ N("header", { ...S, className: r(`${a}-header`, v), children: [
|
|
33
33
|
/* @__PURE__ */ e(
|
|
34
34
|
"div",
|
|
35
35
|
{
|
|
36
|
-
className: r(`${a}-header__overlay`, { [`${a}-header__overlay--active`]:
|
|
36
|
+
className: r(`${a}-header__overlay`, { [`${a}-header__overlay--active`]: d }),
|
|
37
37
|
"data-testid": "header-overlay",
|
|
38
|
-
onClick:
|
|
38
|
+
onClick: g
|
|
39
39
|
}
|
|
40
40
|
),
|
|
41
41
|
/* @__PURE__ */ e(
|
|
@@ -44,31 +44,31 @@ const N = c.createContext({
|
|
|
44
44
|
"aria-label": o,
|
|
45
45
|
"data-testid": "mobile-menu-toggle",
|
|
46
46
|
type: "button",
|
|
47
|
-
onClick:
|
|
47
|
+
onClick: g,
|
|
48
48
|
className: r(`${a}-header__toggle-btn`, {
|
|
49
|
-
[`${a}-header__toggle-btn--open`]: o ===
|
|
49
|
+
[`${a}-header__toggle-btn--open`]: o === h
|
|
50
50
|
}),
|
|
51
51
|
children: /* @__PURE__ */ e("span", { children: o })
|
|
52
52
|
}
|
|
53
53
|
),
|
|
54
|
-
/* @__PURE__ */ e("h1", { "data-testid": "header-logo", className: `${a}-header__logo`, tabIndex: o ===
|
|
55
|
-
/* @__PURE__ */ e("div", { className: r(`${a}-header__nav`, { [`${a}-header__nav--open`]:
|
|
56
|
-
|
|
54
|
+
/* @__PURE__ */ e("h1", { "data-testid": "header-logo", className: `${a}-header__logo`, tabIndex: o === m ? 0 : -1, children: /* @__PURE__ */ e("a", { href: "/", "aria-label": f, children: typeof s == "object" ? s : /* @__PURE__ */ e("img", { alt: "Phillips", "data-testid": "header-logo-img", src: s, height: "14" }) }) }),
|
|
55
|
+
/* @__PURE__ */ e("div", { className: r(`${a}-header__nav`, { [`${a}-header__nav--open`]: d }), children: /* @__PURE__ */ e(
|
|
56
|
+
j.Provider,
|
|
57
57
|
{
|
|
58
58
|
value: {
|
|
59
59
|
defaultMobileMenuLabel: t,
|
|
60
|
-
expandedItem:
|
|
61
|
-
setExpandedItem: (n) =>
|
|
62
|
-
isExpanded:
|
|
63
|
-
onSelect: (n) =>
|
|
60
|
+
expandedItem: p,
|
|
61
|
+
setExpandedItem: (n) => c(n),
|
|
62
|
+
isExpanded: y,
|
|
63
|
+
onSelect: (n) => I(n)
|
|
64
64
|
},
|
|
65
|
-
children:
|
|
65
|
+
children: u
|
|
66
66
|
}
|
|
67
67
|
) }),
|
|
68
|
-
|
|
68
|
+
$
|
|
69
69
|
] });
|
|
70
70
|
};
|
|
71
71
|
export {
|
|
72
|
-
|
|
73
|
-
|
|
72
|
+
j as HeaderContext,
|
|
73
|
+
R as default
|
|
74
74
|
};
|
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { getCommonProps as
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import { jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import c from "../../node_modules/classnames/index.js";
|
|
3
|
+
import e from "../Button/Button.js";
|
|
4
|
+
import { getCommonProps as i } from "../../utils/index.js";
|
|
5
|
+
import { ButtonVariants as p } from "../Button/types.js";
|
|
6
|
+
const x = ({ children: m, size: r = "md", className: s, ...o }) => {
|
|
7
|
+
const { className: t, ...a } = i(o, "IconButton");
|
|
8
|
+
return /* @__PURE__ */ n(
|
|
9
|
+
e,
|
|
9
10
|
{
|
|
10
|
-
...
|
|
11
|
-
|
|
12
|
-
className:
|
|
11
|
+
...a,
|
|
12
|
+
variant: p.primary,
|
|
13
|
+
className: c(t, `${t}--${r}`, s),
|
|
13
14
|
...o,
|
|
14
15
|
children: m
|
|
15
16
|
}
|
|
16
17
|
);
|
|
17
18
|
};
|
|
18
19
|
export {
|
|
19
|
-
|
|
20
|
+
x as default
|
|
20
21
|
};
|
|
@@ -1,7 +1,48 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
import { type SearchResultsProps } from './SearchResults/SearchResults';
|
|
3
|
+
export interface SearchProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
/**
|
|
5
|
+
* If true will show an icon instead of text in the button
|
|
6
|
+
*/
|
|
4
7
|
useIcon?: boolean;
|
|
8
|
+
/**
|
|
9
|
+
*
|
|
10
|
+
* @param searchQuery called when the search input changes
|
|
11
|
+
* @returns void
|
|
12
|
+
*/
|
|
13
|
+
onSearch?: (searchQuery: string) => void;
|
|
14
|
+
/**
|
|
15
|
+
* The search results to display
|
|
16
|
+
*/
|
|
17
|
+
searchResults?: SearchResultsProps['autoCompleteResults'];
|
|
18
|
+
/**
|
|
19
|
+
* additional state information
|
|
20
|
+
*/
|
|
21
|
+
state?: 'loading' | 'invalid' | 'idle';
|
|
22
|
+
/**
|
|
23
|
+
* allows override of the default placeholder (i.e. for internationalization)
|
|
24
|
+
*/
|
|
25
|
+
placeholder?: string;
|
|
26
|
+
/**
|
|
27
|
+
* allows override of the search button label (i.e. for internationalization)
|
|
28
|
+
*/
|
|
29
|
+
searchButtonText?: string;
|
|
30
|
+
/**
|
|
31
|
+
* allows override of the default loading text (i.e. for internationalization)
|
|
32
|
+
*/
|
|
33
|
+
loadingText?: string;
|
|
34
|
+
/**
|
|
35
|
+
* allows override of the default allResults text (i.e. for internationalization)
|
|
36
|
+
*/
|
|
37
|
+
getAllResultsText?: (searchQuery: string) => string;
|
|
38
|
+
/**
|
|
39
|
+
* allows override of the default allResults link in case this component should not launch not the default all results landing point
|
|
40
|
+
*/
|
|
41
|
+
getAllResultsLink?: (searchQuery: string) => string;
|
|
42
|
+
/**
|
|
43
|
+
* allows override of the default invalid text (i.e. for internationalization)
|
|
44
|
+
*/
|
|
45
|
+
invalidText?: string;
|
|
5
46
|
}
|
|
6
|
-
declare const Search: ({
|
|
47
|
+
declare const Search: ({ useIcon, onSearch, searchResults, state, defaultValue, className, placeholder, searchButtonText, loadingText, invalidText, getAllResultsText, getAllResultsLink, ...props }: React.PropsWithChildren<SearchProps>) => import("react/jsx-runtime").JSX.Element;
|
|
7
48
|
export default Search;
|