@phillips/seldon 1.96.1 → 1.97.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/DatePicker/DatePicker.d.ts +1 -1
- package/dist/components/Filter/Filter.d.ts +25 -0
- package/dist/components/Filter/Filter.js +62 -0
- package/dist/components/Filter/Filter.stories.d.ts +29 -0
- package/dist/components/Filter/Filter.test.d.ts +1 -0
- package/dist/components/Filter/FilterHeader.d.ts +14 -0
- package/dist/components/Filter/FilterHeader.js +36 -0
- package/dist/components/Filter/FilterInput.d.ts +15 -0
- package/dist/components/Filter/FilterInput.js +27 -0
- package/dist/components/Filter/index.d.ts +3 -0
- package/dist/components/Input/Input.d.ts +5 -5
- package/dist/components/Input/Input.js +67 -53
- package/dist/components/Input/Input.stories.d.ts +0 -1
- package/dist/components/Pagination/Pagination.js +27 -26
- package/dist/components/Select/Select.d.ts +3 -2
- package/dist/components/Select/Select.js +53 -44
- package/dist/index.d.ts +3 -0
- package/dist/index.js +148 -140
- package/dist/patterns/FilterMenu/FilterMenu.d.ts +22 -0
- package/dist/patterns/FilterMenu/FilterMenu.js +23 -0
- package/dist/patterns/FilterMenu/FilterMenu.stories.d.ts +29 -0
- package/dist/patterns/FilterMenu/FilterMenu.test.d.ts +1 -0
- package/dist/patterns/FilterMenu/index.d.ts +1 -0
- package/dist/patterns/FilterMenu/utils.d.ts +10 -0
- package/dist/patterns/ViewingsList/ViewingsListCard.js +1 -1
- package/dist/patterns/ViewingsList/ViewingsListCardForm.js +30 -32
- package/dist/scss/componentStyles.scss +9 -7
- package/dist/scss/components/Filter/_filter.scss +112 -0
- package/dist/scss/components/Input/_input.scss +1 -1
- package/dist/scss/patterns/FilterMenu/_filterMenu.scss +15 -0
- package/package.json +2 -1
|
@@ -1,65 +1,74 @@
|
|
|
1
|
-
import { jsxs as p, jsx as
|
|
2
|
-
import * as
|
|
3
|
-
import
|
|
1
|
+
import { jsxs as p, jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import * as c from "react";
|
|
3
|
+
import a from "../../node_modules/classnames/index.js";
|
|
4
4
|
import { px as e, useNormalizedInputProps as z } from "../../utils/index.js";
|
|
5
|
-
import { SelectVariants as
|
|
5
|
+
import { SelectVariants as d } from "./types.js";
|
|
6
6
|
import D from "../../assets/chevronDown.svg.js";
|
|
7
|
-
const F =
|
|
7
|
+
const F = c.forwardRef(
|
|
8
8
|
({
|
|
9
|
-
children:
|
|
10
|
-
className:
|
|
11
|
-
defaultValue:
|
|
12
|
-
disabled:
|
|
13
|
-
hideLabel:
|
|
14
|
-
id:
|
|
9
|
+
children: m,
|
|
10
|
+
className: s,
|
|
11
|
+
defaultValue: u,
|
|
12
|
+
disabled: $,
|
|
13
|
+
hideLabel: _,
|
|
14
|
+
id: t,
|
|
15
15
|
showIcon: l = !0,
|
|
16
|
-
variant:
|
|
17
|
-
inline:
|
|
18
|
-
invalid:
|
|
19
|
-
invalidText:
|
|
20
|
-
labelText:
|
|
21
|
-
onChange:
|
|
16
|
+
variant: f = d.default,
|
|
17
|
+
inline: b,
|
|
18
|
+
invalid: v,
|
|
19
|
+
invalidText: h,
|
|
20
|
+
labelText: w,
|
|
21
|
+
onChange: C,
|
|
22
22
|
onClick: V,
|
|
23
23
|
readOnly: r,
|
|
24
|
-
size:
|
|
25
|
-
value:
|
|
26
|
-
warn:
|
|
27
|
-
warnText:
|
|
28
|
-
...
|
|
24
|
+
size: x = "md",
|
|
25
|
+
value: y,
|
|
26
|
+
warn: N,
|
|
27
|
+
warnText: S,
|
|
28
|
+
...g
|
|
29
29
|
}, j) => {
|
|
30
|
-
const o = "select",
|
|
31
|
-
|
|
30
|
+
const o = "select", I = c.useId(), n = z({
|
|
31
|
+
disabled: $,
|
|
32
|
+
id: t != null ? t : I,
|
|
33
|
+
invalid: v,
|
|
34
|
+
invalidText: h,
|
|
35
|
+
readOnly: r,
|
|
36
|
+
type: o,
|
|
37
|
+
warn: N,
|
|
38
|
+
warnText: S
|
|
39
|
+
}), P = a(`${e}-${o}-input`, `${e}-input`, `${e}-input--${x}`, {
|
|
40
|
+
[`${e}-input--inline`]: b,
|
|
32
41
|
[`${e}-input--readonly`]: r,
|
|
33
|
-
[`${e}-input--disabled`]:
|
|
34
|
-
[`${e}-input--invalid`]:
|
|
35
|
-
[`${e}-input--warn`]:
|
|
36
|
-
[`${
|
|
37
|
-
}), R =
|
|
38
|
-
[`${e}-input__select--tertiary`]:
|
|
39
|
-
}),
|
|
42
|
+
[`${e}-input--disabled`]: n.disabled,
|
|
43
|
+
[`${e}-input--invalid`]: n.invalid,
|
|
44
|
+
[`${e}-input--warn`]: n.warn,
|
|
45
|
+
[`${s}__wrapper`]: s
|
|
46
|
+
}), R = a(s, `${e}-input__input`, {
|
|
47
|
+
[`${e}-input__select--tertiary`]: f === d.tertiary
|
|
48
|
+
}), k = a(`${e}-select-container`, {
|
|
40
49
|
[`${e}-select-container--show__icon`]: l
|
|
41
50
|
});
|
|
42
51
|
return /* @__PURE__ */ p("div", { className: P, children: [
|
|
43
|
-
/* @__PURE__ */
|
|
44
|
-
/* @__PURE__ */ p("div", { className:
|
|
45
|
-
/* @__PURE__ */
|
|
52
|
+
/* @__PURE__ */ i("label", { htmlFor: t, className: a(`${e}-input__label`, { [`${e}-input__label--hidden`]: _ }), children: w }),
|
|
53
|
+
/* @__PURE__ */ p("div", { className: k, children: [
|
|
54
|
+
/* @__PURE__ */ i(
|
|
46
55
|
"select",
|
|
47
56
|
{
|
|
48
57
|
className: R,
|
|
49
|
-
"data-testid":
|
|
50
|
-
defaultValue:
|
|
51
|
-
disabled:
|
|
52
|
-
id:
|
|
53
|
-
onChange:
|
|
58
|
+
"data-testid": t,
|
|
59
|
+
defaultValue: u,
|
|
60
|
+
disabled: n.disabled,
|
|
61
|
+
id: t,
|
|
62
|
+
onChange: C,
|
|
54
63
|
ref: j,
|
|
55
|
-
value:
|
|
56
|
-
...
|
|
57
|
-
children:
|
|
64
|
+
value: y,
|
|
65
|
+
...g,
|
|
66
|
+
children: m
|
|
58
67
|
}
|
|
59
68
|
),
|
|
60
|
-
l ? /* @__PURE__ */
|
|
69
|
+
l ? /* @__PURE__ */ i(D, {}) : null
|
|
61
70
|
] }),
|
|
62
|
-
|
|
71
|
+
n.validation
|
|
63
72
|
] });
|
|
64
73
|
}
|
|
65
74
|
);
|
package/dist/index.d.ts
CHANGED
|
@@ -58,6 +58,9 @@ export * from './components/PinchZoom';
|
|
|
58
58
|
export * from './components/Tabs';
|
|
59
59
|
export * from './components/SeldonImage';
|
|
60
60
|
export * from './patterns/SaleHeaderBanner';
|
|
61
|
+
export * from './utils/hooks';
|
|
62
|
+
export * from './patterns/FilterMenu';
|
|
63
|
+
export * from './components/Filter';
|
|
61
64
|
export * from './components/Countdown';
|
|
62
65
|
export * from './components/Countdown/types';
|
|
63
66
|
export * from './patterns/ObjectTile';
|
package/dist/index.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { PaddingTokens as f, SpacingTokens as s, defaultYear as l, emailValidation as d, encodeURLSearchParams as
|
|
1
|
+
import { PaddingTokens as f, SpacingTokens as s, defaultYear as l, emailValidation as d, encodeURLSearchParams as p, findChildrenExcludingTypes as m, findChildrenOfType as u, generatePaddingClassName as x, getCommonProps as n, noOp as i, px as g, useNormalizedInputProps as c } from "./utils/index.js";
|
|
2
2
|
import { default as S } from "./assets/account_circle.svg.js";
|
|
3
3
|
import { default as L } from "./assets/arrowPrev.svg.js";
|
|
4
|
-
import { default as
|
|
4
|
+
import { default as I } from "./assets/calendar.svg.js";
|
|
5
5
|
import { default as T } from "./assets/calendarAlt.svg.js";
|
|
6
6
|
import { default as V } from "./assets/chevronDown.svg.js";
|
|
7
7
|
import { default as B } from "./assets/chevronNext.svg.js";
|
|
8
8
|
import { default as w } from "./assets/chevronRight.svg.js";
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
9
|
+
import { default as y } from "./assets/close.svg.js";
|
|
10
|
+
import { default as D } from "./assets/favorite.svg.js";
|
|
11
|
+
import { default as N } from "./assets/favoriteOutline.svg.js";
|
|
12
12
|
import { default as O } from "./assets/icon-footer-facebook.svg.js";
|
|
13
13
|
import { default as G } from "./assets/icon-footer-instagram.svg.js";
|
|
14
14
|
import { default as E } from "./assets/icon-footer-linkedin.svg.js";
|
|
@@ -18,24 +18,24 @@ import { default as q } from "./assets/instagram.svg.js";
|
|
|
18
18
|
import { default as K } from "./assets/lock.svg.js";
|
|
19
19
|
import { default as _ } from "./assets/minus.svg.js";
|
|
20
20
|
import { default as ee } from "./assets/PhillipsLogo.svg.js";
|
|
21
|
-
import { default as
|
|
21
|
+
import { default as oe } from "./assets/plus.svg.js";
|
|
22
22
|
import { default as ae } from "./assets/react.svg.js";
|
|
23
23
|
import "react";
|
|
24
24
|
import { default as se } from "./assets/share.svg.js";
|
|
25
25
|
import { default as de } from "./assets/spotify.svg.js";
|
|
26
|
-
import { default as
|
|
26
|
+
import { default as me } from "./assets/wechat.svg.js";
|
|
27
27
|
import { default as xe } from "./assets/youtube.svg.js";
|
|
28
28
|
import { default as ie } from "./pages/Page.js";
|
|
29
29
|
import { usePendingState as ce } from "./utils/hooks.js";
|
|
30
30
|
import { SSRMediaQuery as Se, ssrMediaQueryStyle as he } from "./providers/SeldonProvider/utils.js";
|
|
31
|
-
import { AuctionStatus as Pe, SupportedLanguages as
|
|
31
|
+
import { AuctionStatus as Pe, SupportedLanguages as Ie } from "./types/commonTypes.js";
|
|
32
32
|
import { default as Te } from "./components/Button/Button.js";
|
|
33
33
|
import { ButtonVariants as Ve } from "./components/Button/types.js";
|
|
34
34
|
import { default as Be } from "./components/IconButton/IconButton.js";
|
|
35
35
|
import { default as we } from "./components/ErrorBoundary/ErrorBoundary.js";
|
|
36
|
-
import { default as
|
|
37
|
-
import { Grid as
|
|
38
|
-
import { default as
|
|
36
|
+
import { default as ye } from "./site-furniture/Footer/Footer.js";
|
|
37
|
+
import { Grid as De } from "./components/Grid/Grid.js";
|
|
38
|
+
import { default as Ne } from "./site-furniture/Header/Header.js";
|
|
39
39
|
import { default as Oe } from "./components/Navigation/Navigation.js";
|
|
40
40
|
import { default as Ge } from "./components/Navigation/NavigationItem/NavigationItem.js";
|
|
41
41
|
import { default as Ee } from "./components/Navigation/NavigationItemTrigger/NavigationItemTrigger.js";
|
|
@@ -44,176 +44,184 @@ import { default as ze } from "./patterns/HeroBanner/HeroBanner.js";
|
|
|
44
44
|
import { default as qe } from "./components/Input/Input.js";
|
|
45
45
|
import { default as Ke } from "./components/Link/Link.js";
|
|
46
46
|
import { LinkVariants as _e } from "./components/Link/types.js";
|
|
47
|
-
import { default as
|
|
48
|
-
import { default as
|
|
49
|
-
import { default as
|
|
50
|
-
import { default as
|
|
51
|
-
import { GridItemAlign as
|
|
52
|
-
import { default as
|
|
53
|
-
import { default as
|
|
54
|
-
import { SelectVariants as
|
|
55
|
-
import { default as
|
|
56
|
-
import { default as
|
|
57
|
-
import { SubscriptionState as
|
|
58
|
-
import { default as
|
|
59
|
-
import { default as
|
|
60
|
-
import { default as
|
|
61
|
-
import { default as
|
|
62
|
-
import { default as
|
|
63
|
-
import { default as
|
|
64
|
-
import { default as
|
|
65
|
-
import { TextVariants as
|
|
66
|
-
import { default as
|
|
67
|
-
import { TextSymbolVariants as
|
|
68
|
-
import { default as
|
|
69
|
-
import { default as
|
|
70
|
-
import { default as
|
|
71
|
-
import { AccordionItemVariant as
|
|
72
|
-
import { default as
|
|
73
|
-
import { AuthState as
|
|
74
|
-
import { default as
|
|
47
|
+
import { default as et } from "./components/LinkBlock/LinkBlock.js";
|
|
48
|
+
import { default as ot } from "./components/LinkList/LinkList.js";
|
|
49
|
+
import { default as at } from "./components/Row/Row.js";
|
|
50
|
+
import { default as st } from "./components/GridItem/GridItem.js";
|
|
51
|
+
import { GridItemAlign as dt } from "./components/GridItem/types.js";
|
|
52
|
+
import { default as mt } from "./components/Search/Search.js";
|
|
53
|
+
import { default as xt } from "./components/Select/Select.js";
|
|
54
|
+
import { SelectVariants as it } from "./components/Select/types.js";
|
|
55
|
+
import { default as ct } from "./components/SplitPanel/SplitPanel.js";
|
|
56
|
+
import { default as St } from "./patterns/Subscribe/Subscribe.js";
|
|
57
|
+
import { SubscriptionState as Lt } from "./patterns/Subscribe/types.js";
|
|
58
|
+
import { default as It } from "./patterns/Social/Social.js";
|
|
59
|
+
import { default as Tt } from "./patterns/ViewingsList/ViewingsList.js";
|
|
60
|
+
import { default as Vt } from "./components/Modal/Modal.js";
|
|
61
|
+
import { default as Bt } from "./components/Drawer/Drawer.js";
|
|
62
|
+
import { default as wt } from "./components/Pagination/Pagination.js";
|
|
63
|
+
import { default as yt } from "./components/Tags/Tags.js";
|
|
64
|
+
import { default as Dt } from "./patterns/ViewingsList/StatefulViewingsList.js";
|
|
65
|
+
import { TextVariants as Nt } from "./components/Text/types.js";
|
|
66
|
+
import { default as Ot } from "./components/Text/Text.js";
|
|
67
|
+
import { TextSymbolVariants as Gt } from "./components/TextSymbol/types.js";
|
|
68
|
+
import { default as Et } from "./components/TextSymbol/TextSymbol.js";
|
|
69
|
+
import { default as Yt } from "./components/Accordion/Accordion.js";
|
|
70
|
+
import { default as zt } from "./components/Accordion/AccordionItem.js";
|
|
71
|
+
import { AccordionItemVariant as qt, AccordionVariants as Jt } from "./components/Accordion/types.js";
|
|
72
|
+
import { default as Xt } from "./patterns/UserManagement/UserManagement.js";
|
|
73
|
+
import { AuthState as $t } from "./patterns/UserManagement/types.js";
|
|
74
|
+
import { default as to } from "./components/Breadcrumb/Breadcrumb.js";
|
|
75
75
|
import "react/jsx-runtime";
|
|
76
76
|
import "./node_modules/classnames/index.js";
|
|
77
|
-
import { default as
|
|
78
|
-
import { default as
|
|
79
|
-
import { default as
|
|
80
|
-
import { default as
|
|
81
|
-
import { HeightUnits as
|
|
82
|
-
import { default as
|
|
83
|
-
import { default as
|
|
84
|
-
import { default as
|
|
85
|
-
import { SeldonProvider as
|
|
86
|
-
import { default as
|
|
87
|
-
import { default as
|
|
88
|
-
import { default as
|
|
89
|
-
import { default as
|
|
90
|
-
import { default as
|
|
91
|
-
import { default as
|
|
92
|
-
import { default as
|
|
93
|
-
import { DetailListAlignment as
|
|
94
|
-
import { default as
|
|
95
|
-
import { default as
|
|
96
|
-
import { default as
|
|
97
|
-
import { default as
|
|
98
|
-
import { default as
|
|
99
|
-
import { default as
|
|
100
|
-
import { AuctionState as
|
|
101
|
-
import { default as
|
|
102
|
-
import {
|
|
103
|
-
import { default as
|
|
104
|
-
import { default as ar } from "./
|
|
105
|
-
import { default as sr } from "./
|
|
106
|
-
import {
|
|
77
|
+
import { default as ro } from "./components/Dropdown/Dropdown.js";
|
|
78
|
+
import { default as fo } from "./components/Video/Video.js";
|
|
79
|
+
import { default as lo } from "./patterns/LanguageSelector/LanguageSelector.js";
|
|
80
|
+
import { default as mo } from "./components/ContentPeek/ContentPeek.js";
|
|
81
|
+
import { HeightUnits as xo } from "./components/ContentPeek/utils.js";
|
|
82
|
+
import { default as io } from "./components/Collapsible/Collapsible.js";
|
|
83
|
+
import { default as co } from "./components/Collapsible/CollapsibleContent.js";
|
|
84
|
+
import { default as So } from "./components/Collapsible/CollapsibleTrigger.js";
|
|
85
|
+
import { SeldonProvider as Lo } from "./providers/SeldonProvider/SeldonProvider.js";
|
|
86
|
+
import { default as Io } from "./components/PageContentWrapper/PageContentWrapper.js";
|
|
87
|
+
import { default as To } from "./components/Carousel/Carousel.js";
|
|
88
|
+
import { default as Vo } from "./components/Carousel/CarouselContent.js";
|
|
89
|
+
import { default as Bo } from "./components/Carousel/CarouselItem.js";
|
|
90
|
+
import { default as wo } from "./components/Carousel/CarouselDots.js";
|
|
91
|
+
import { default as yo } from "./components/Detail/Detail.js";
|
|
92
|
+
import { default as Do } from "./patterns/DetailList/DetailList.js";
|
|
93
|
+
import { DetailListAlignment as No } from "./patterns/DetailList/types.js";
|
|
94
|
+
import { default as Oo } from "./components/PinchZoom/PinchZoom.js";
|
|
95
|
+
import { default as Go } from "./components/Tabs/TabsContainer.js";
|
|
96
|
+
import { default as Eo } from "./components/Tabs/TabsContent.js";
|
|
97
|
+
import { default as Yo } from "./components/SeldonImage/SeldonImage.js";
|
|
98
|
+
import { default as zo } from "./patterns/SaleHeaderBanner/SaleHeaderBanner.js";
|
|
99
|
+
import { default as qo } from "./patterns/SaleHeaderBanner/SaleHeaderBrowseAuctions.js";
|
|
100
|
+
import { AuctionState as Ko } from "./patterns/SaleHeaderBanner/types.js";
|
|
101
|
+
import { default as _o } from "./patterns/FilterMenu/FilterMenu.js";
|
|
102
|
+
import { default as er } from "./components/Filter/Filter.js";
|
|
103
|
+
import { default as or } from "./components/Filter/FilterInput.js";
|
|
104
|
+
import { default as ar } from "./components/Filter/FilterHeader.js";
|
|
105
|
+
import { default as sr } from "./components/Countdown/Countdown.js";
|
|
106
|
+
import { CountdownVariants as dr } from "./components/Countdown/types.js";
|
|
107
|
+
import { default as mr } from "./patterns/ObjectTile/ObjectTile.js";
|
|
108
|
+
import { default as xr } from "./patterns/BidSnapshot/BidSnapshot.js";
|
|
109
|
+
import { default as ir } from "./patterns/BidSnapshot/BidMessage.js";
|
|
110
|
+
import { BidMessageVariants as cr } from "./patterns/BidSnapshot/types.js";
|
|
107
111
|
export {
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
+
Yt as Accordion,
|
|
113
|
+
zt as AccordionItem,
|
|
114
|
+
qt as AccordionItemVariant,
|
|
115
|
+
Jt as AccordionVariants,
|
|
112
116
|
S as AccountCircle,
|
|
113
117
|
L as ArrowPrev,
|
|
114
|
-
|
|
118
|
+
Ko as AuctionState,
|
|
115
119
|
Pe as AuctionStatus,
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
120
|
+
$t as AuthState,
|
|
121
|
+
ir as BidMessage,
|
|
122
|
+
cr as BidMessageVariants,
|
|
123
|
+
xr as BidSnapshot,
|
|
124
|
+
to as Breadcrumb,
|
|
121
125
|
Te as Button,
|
|
122
126
|
Ve as ButtonVariants,
|
|
123
|
-
|
|
127
|
+
I as Calendar,
|
|
124
128
|
T as CalendarAlt,
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
+
To as Carousel,
|
|
130
|
+
Vo as CarouselContent,
|
|
131
|
+
wo as CarouselDots,
|
|
132
|
+
Bo as CarouselItem,
|
|
129
133
|
V as ChevronDown,
|
|
130
134
|
B as ChevronNext,
|
|
131
135
|
w as ChevronRight,
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
136
|
+
y as Close,
|
|
137
|
+
io as Collapsible,
|
|
138
|
+
co as CollapsibleContent,
|
|
139
|
+
So as CollapsibleTrigger,
|
|
140
|
+
mo as ContentPeek,
|
|
141
|
+
xo as ContentPeekHeightUnits,
|
|
142
|
+
sr as Countdown,
|
|
143
|
+
dr as CountdownVariants,
|
|
144
|
+
yo as Detail,
|
|
145
|
+
Do as DetailList,
|
|
146
|
+
No as DetailListAlignment,
|
|
147
|
+
Bt as Drawer,
|
|
148
|
+
ro as Dropdown,
|
|
145
149
|
we as ErrorBoundary,
|
|
146
150
|
O as Facebook,
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
151
|
+
D as Favorite,
|
|
152
|
+
N as FavoriteOutline,
|
|
153
|
+
er as Filter,
|
|
154
|
+
ar as FilterHeader,
|
|
155
|
+
or as FilterInput,
|
|
156
|
+
_o as FilterMenu,
|
|
157
|
+
ye as Footer,
|
|
150
158
|
G as FooterInstagram,
|
|
151
159
|
z as FooterWeChat,
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
160
|
+
De as Grid,
|
|
161
|
+
st as GridItem,
|
|
162
|
+
dt as GridItemAlign,
|
|
163
|
+
Ne as Header,
|
|
156
164
|
ze as HeroBanner,
|
|
157
165
|
Be as IconButton,
|
|
158
166
|
qe as Input,
|
|
159
167
|
q as Instagram,
|
|
160
|
-
|
|
168
|
+
lo as LanguageSelector,
|
|
161
169
|
Ke as Link,
|
|
162
|
-
|
|
163
|
-
|
|
170
|
+
et as LinkBlock,
|
|
171
|
+
ot as LinkList,
|
|
164
172
|
_e as LinkVariants,
|
|
165
173
|
E as LinkedIn,
|
|
166
174
|
K as Lock,
|
|
167
175
|
_ as Minus,
|
|
168
|
-
|
|
176
|
+
Vt as Modal,
|
|
169
177
|
Oe as Navigation,
|
|
170
178
|
Ge as NavigationItem,
|
|
171
179
|
Ee as NavigationItemTrigger,
|
|
172
180
|
Ye as NavigationList,
|
|
173
|
-
|
|
181
|
+
mr as ObjectTile,
|
|
174
182
|
f as PaddingTokens,
|
|
175
183
|
ie as Page,
|
|
176
|
-
|
|
177
|
-
|
|
184
|
+
Io as PageContentWrapper,
|
|
185
|
+
wt as Pagination,
|
|
178
186
|
ee as PhillipsLogo,
|
|
179
|
-
|
|
180
|
-
|
|
187
|
+
Oo as PinchZoom,
|
|
188
|
+
oe as Plus,
|
|
181
189
|
ae as React,
|
|
182
190
|
Y as Reddit,
|
|
183
|
-
|
|
191
|
+
at as Row,
|
|
184
192
|
Se as SSRMediaQuery,
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
193
|
+
zo as SaleHeaderBanner,
|
|
194
|
+
qo as SaleHeaderBrowseAuctions,
|
|
195
|
+
mt as Search,
|
|
196
|
+
Yo as SeldonImage,
|
|
197
|
+
Lo as SeldonProvider,
|
|
198
|
+
xt as Select,
|
|
199
|
+
it as SelectVariants,
|
|
192
200
|
se as Share,
|
|
193
|
-
|
|
201
|
+
It as Social,
|
|
194
202
|
s as SpacingTokens,
|
|
195
|
-
|
|
203
|
+
ct as SplitPanel,
|
|
196
204
|
de as Spotify,
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
205
|
+
Dt as StatefulViewingsList,
|
|
206
|
+
St as Subscribe,
|
|
207
|
+
Lt as SubscriptionState,
|
|
208
|
+
Ie as SupportedLanguages,
|
|
209
|
+
Go as TabsContainer,
|
|
210
|
+
Eo as TabsContent,
|
|
211
|
+
yt as TagsList,
|
|
212
|
+
Ot as Text,
|
|
213
|
+
Gt as TextSymbolVariants,
|
|
214
|
+
Et as TextSymbols,
|
|
215
|
+
Nt as TextVariants,
|
|
216
|
+
Xt as UserManagement,
|
|
217
|
+
fo as Video,
|
|
218
|
+
Tt as ViewingsList,
|
|
219
|
+
me as WeChat,
|
|
212
220
|
xe as Youtube,
|
|
213
221
|
l as defaultYear,
|
|
214
222
|
d as emailValidation,
|
|
215
|
-
|
|
216
|
-
|
|
223
|
+
p as encodeURLSearchParams,
|
|
224
|
+
m as findChildrenExcludingTypes,
|
|
217
225
|
u as findChildrenOfType,
|
|
218
226
|
x as generatePaddingClassName,
|
|
219
227
|
n as getCommonProps,
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { default as React, ReactNode } from 'react';
|
|
2
|
+
export interface FilterMenuProps<ElementType = HTMLFormElement> extends React.HTMLAttributes<ElementType> {
|
|
3
|
+
/**
|
|
4
|
+
* Typically would be a Filter component
|
|
5
|
+
* */
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
/**
|
|
8
|
+
* Optional element to render as the top-level component e.g. 'div', Form, CustomComponent, etc. Defaults to 'form'.
|
|
9
|
+
*/
|
|
10
|
+
element?: React.ElementType;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* ## Overview
|
|
14
|
+
*
|
|
15
|
+
* A container for filters that controls the state of parent and child filters
|
|
16
|
+
*
|
|
17
|
+
* [Figma Link](https://www.figma.com/design/OvBXAq48blO1r4qYbeBPjW/RW---Sale-Page-(PLP)?node-id=892-71019&node-type=frame&t=AsBDn4UgUEjNUnf7-0)
|
|
18
|
+
*
|
|
19
|
+
* [Storybook Link](https://phillips-seldon.netlify.app/?path=/docs/patterns-filtercontrol--overview)
|
|
20
|
+
*/
|
|
21
|
+
declare const FilterMenu: React.ForwardRefExoticComponent<FilterMenuProps<HTMLFormElement> & React.RefAttributes<HTMLFormElement>>;
|
|
22
|
+
export default FilterMenu;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { jsx as u } from "react/jsx-runtime";
|
|
2
|
+
import d, { forwardRef as N, useState as C, Children as g, cloneElement as F } from "react";
|
|
3
|
+
import { getCommonProps as V } from "../../utils/index.js";
|
|
4
|
+
import a from "../../node_modules/classnames/index.js";
|
|
5
|
+
import w from "../../components/Filter/Filter.js";
|
|
6
|
+
const x = N(
|
|
7
|
+
({ className: t, children: m, element: n = "form", ...r }, l) => {
|
|
8
|
+
const { className: i, ...p } = V(r, "FilterMenu"), [s, f] = C(null), o = s == null ? void 0 : s.length, c = g.map(
|
|
9
|
+
m,
|
|
10
|
+
(e) => d.isValidElement(e) && e.type === w ? F(e, {
|
|
11
|
+
setViewAllFilter: f,
|
|
12
|
+
hidden: o ? s !== e.props.name : !1,
|
|
13
|
+
isViewingAll: o,
|
|
14
|
+
className: o && a(e.props.className, "is-opening")
|
|
15
|
+
}) : e
|
|
16
|
+
);
|
|
17
|
+
return /* @__PURE__ */ u(n, { ...p, ...r, className: a(i, t), ref: l, children: c });
|
|
18
|
+
}
|
|
19
|
+
);
|
|
20
|
+
x.displayName = "FilterControl";
|
|
21
|
+
export {
|
|
22
|
+
x as default
|
|
23
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
declare const meta: {
|
|
2
|
+
title: string;
|
|
3
|
+
component: import('react').ForwardRefExoticComponent<import('./FilterMenu').FilterMenuProps<HTMLFormElement> & import('react').RefAttributes<HTMLFormElement>>;
|
|
4
|
+
};
|
|
5
|
+
export default meta;
|
|
6
|
+
type FilterDimension = {
|
|
7
|
+
label: string;
|
|
8
|
+
active: boolean;
|
|
9
|
+
disabled?: boolean | undefined;
|
|
10
|
+
};
|
|
11
|
+
type FilterType = {
|
|
12
|
+
label: string;
|
|
13
|
+
id: string;
|
|
14
|
+
filterDimensions: FilterDimension[];
|
|
15
|
+
type: 'checkbox' | 'radio';
|
|
16
|
+
};
|
|
17
|
+
type PropTypes = {
|
|
18
|
+
isOpen: boolean;
|
|
19
|
+
filters: FilterType[];
|
|
20
|
+
onClose: () => void;
|
|
21
|
+
};
|
|
22
|
+
export declare const Playground: {
|
|
23
|
+
(props: PropTypes): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
args: {
|
|
25
|
+
isOpen: boolean;
|
|
26
|
+
filters: FilterType[];
|
|
27
|
+
};
|
|
28
|
+
argTypes: {};
|
|
29
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as FilterMenu, type FilterMenuProps } from './FilterMenu';
|