@phillips/seldon 1.59.1 → 1.60.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.
Files changed (53) hide show
  1. package/dist/components/Accordion/Accordion.js +2 -2
  2. package/dist/components/Accordion/AccordionItem.js +4 -4
  3. package/dist/components/Button/Button.js +7 -7
  4. package/dist/components/Carousel/Carousel.d.ts +52 -0
  5. package/dist/components/Carousel/Carousel.js +72 -0
  6. package/dist/components/Carousel/CarouselContent.d.ts +19 -0
  7. package/dist/components/Carousel/CarouselContent.js +33 -0
  8. package/dist/components/Carousel/CarouselDots.d.ts +26 -0
  9. package/dist/components/Carousel/CarouselDots.js +75 -0
  10. package/dist/components/Carousel/CarouselItem.d.ts +11 -0
  11. package/dist/components/Carousel/CarouselItem.js +25 -0
  12. package/dist/components/Carousel/index.d.ts +4 -0
  13. package/dist/components/Carousel/utils.d.ts +8 -0
  14. package/dist/components/Carousel/utils.js +11 -0
  15. package/dist/components/ContentPeek/ContentPeek.js +5 -5
  16. package/dist/components/Drawer/Drawer.js +3 -3
  17. package/dist/components/Dropdown/Dropdown.js +3 -3
  18. package/dist/components/Grid/Grid.js +3 -3
  19. package/dist/components/Grid/utils.js +4 -4
  20. package/dist/components/GridItem/GridItem.js +8 -8
  21. package/dist/components/IconButton/IconButton.js +2 -2
  22. package/dist/components/Link/Link.js +6 -6
  23. package/dist/components/LinkList/LinkList.js +5 -5
  24. package/dist/components/Navigation/Navigation.js +4 -4
  25. package/dist/components/Navigation/NavigationList/NavigationList.js +3 -3
  26. package/dist/components/PageContentWrapper/PageContentWrapper.js +4 -4
  27. package/dist/components/Pagination/Pagination.js +6 -6
  28. package/dist/components/Row/Row.js +4 -4
  29. package/dist/components/Search/Search.js +7 -7
  30. package/dist/components/SplitPanel/SplitPanel.js +2 -2
  31. package/dist/components/Video/Video.js +2 -2
  32. package/dist/index.d.ts +1 -0
  33. package/dist/index.js +42 -34
  34. package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.js +1198 -0
  35. package/dist/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js +24 -0
  36. package/dist/node_modules/embla-carousel-reactive-utils/esm/embla-carousel-reactive-utils.esm.js +35 -0
  37. package/dist/node_modules/embla-carousel-wheel-gestures/dist/embla-carousel-wheel-gestures.esm.js +91 -0
  38. package/dist/node_modules/exenv/index.js +1 -1
  39. package/dist/node_modules/prop-types/node_modules/react-is/index.js +1 -1
  40. package/dist/node_modules/wheel-gestures/dist/wheel-gestures.esm.js +269 -0
  41. package/dist/patterns/LanguageSelector/LanguageSelector.js +4 -4
  42. package/dist/patterns/Social/Social.js +5 -5
  43. package/dist/patterns/Subscribe/Subscribe.js +7 -7
  44. package/dist/patterns/UserManagement/UserManagement.js +2 -2
  45. package/dist/patterns/ViewingsList/ViewingsList.js +10 -10
  46. package/dist/patterns/ViewingsList/ViewingsListCard.js +12 -12
  47. package/dist/patterns/ViewingsList/ViewingsListCardForm.js +6 -6
  48. package/dist/scss/componentStyles.scss +1 -0
  49. package/dist/scss/components/Carousel/_carousel.scss +84 -0
  50. package/dist/scss/components/Modal/_modal.scss +1 -0
  51. package/dist/site-furniture/Footer/Footer.js +2 -2
  52. package/dist/site-furniture/Header/Header.js +4 -4
  53. package/package.json +3 -1
@@ -1,15 +1,15 @@
1
1
  import { jsx as l, jsxs as x } from "react/jsx-runtime";
2
- import e, { forwardRef as E } from "react";
3
- import { findChildrenOfType as d, findChildrenExcludingTypes as N, px as m } from "../../utils/index.js";
2
+ import e, { forwardRef as N } from "react";
3
+ import { findChildrenOfType as d, findChildrenExcludingTypes as E, px as m } from "../../utils/index.js";
4
4
  import S from "../../node_modules/classnames/index.js";
5
5
  import { HeaderContext as y } from "../../site-furniture/Header/Header.js";
6
6
  import c from "./NavigationList/NavigationList.js";
7
7
  import f from "../../patterns/LanguageSelector/LanguageSelector.js";
8
8
  import { SSRMediaQuery as C } from "../../providers/utils.js";
9
- const _ = E(
9
+ const _ = N(
10
10
  ({ children: i, className: p, id: a, visible: v = !0, ...g }, h) => {
11
11
  var r, s;
12
- const { isSearchExpanded: n } = e.useContext(y), o = (r = d(i, c)) == null ? void 0 : r[0], u = N(i, [c, f]), t = (s = d(i, f)) == null ? void 0 : s[0];
12
+ const { isSearchExpanded: n } = e.useContext(y), o = (r = d(i, c)) == null ? void 0 : r[0], u = E(i, [c, f]), t = (s = d(i, f)) == null ? void 0 : s[0];
13
13
  return /* @__PURE__ */ l(
14
14
  "nav",
15
15
  {
@@ -4,7 +4,7 @@ import { px as t } from "../../../utils/index.js";
4
4
  import l from "../../../node_modules/classnames/index.js";
5
5
  import { TextVariants as p } from "../../Text/types.js";
6
6
  import f from "../../Text/Text.js";
7
- const h = i.forwardRef(
7
+ const N = i.forwardRef(
8
8
  ({ id: o, children: n, className: d, isOffScreen: _, leftSectionHeading: m, rightSectionHeading: v }, u) => {
9
9
  const s = i.Children.toArray(n).filter((a) => {
10
10
  if (a && a.props.navGroup === "nav-link-start")
@@ -37,7 +37,7 @@ const h = i.forwardRef(
37
37
  );
38
38
  }
39
39
  );
40
- h.displayName = "NavigationList";
40
+ N.displayName = "NavigationList";
41
41
  export {
42
- h as default
42
+ N as default
43
43
  };
@@ -1,10 +1,10 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
- import { forwardRef as n } from "react";
3
- import { getCommonProps as p } from "../../utils/index.js";
2
+ import { forwardRef as p } from "react";
3
+ import { getCommonProps as n } from "../../utils/index.js";
4
4
  import f from "../../node_modules/classnames/index.js";
5
- const c = n(
5
+ const c = p(
6
6
  ({ children: e, className: o, ...a }, r) => {
7
- const { className: m, ...s } = p(a, "PageContentWrapper");
7
+ const { className: m, ...s } = n(a, "PageContentWrapper");
8
8
  return /* @__PURE__ */ t("div", { ...s, className: f(m, o), ...a, ref: r, children: e });
9
9
  }
10
10
  );
@@ -7,10 +7,10 @@ import u from "../IconButton/IconButton.js";
7
7
  import { ButtonVariants as f } from "../Button/types.js";
8
8
  const B = ({
9
9
  className: g,
10
- onChange: n,
10
+ onChange: e,
11
11
  variant: p = "inline",
12
12
  options: t = [],
13
- value: e,
13
+ value: n,
14
14
  isDisabled: o,
15
15
  previousLabel: $ = "Previous",
16
16
  nextLabel: b = "Next",
@@ -29,7 +29,7 @@ const B = ({
29
29
  u,
30
30
  {
31
31
  className: s(`${i}__pagination-button`, `${i}-left-arrow`),
32
- onClick: () => n(t.at(t.findIndex((a) => a === e) - 1) || ""),
32
+ onClick: () => e(t.at(t.findIndex((a) => a === n) - 1) || ""),
33
33
  "data-testid": `${m}-previous-button`,
34
34
  isDisabled: o,
35
35
  "aria-label": $,
@@ -42,8 +42,8 @@ const B = ({
42
42
  {
43
43
  className: p === "inline" && `${i}--inline-pagination`,
44
44
  "aria-label": h,
45
- value: e,
46
- onChange: (a) => n(a == null ? void 0 : a.currentTarget.value, a),
45
+ value: n,
46
+ onChange: (a) => e(a == null ? void 0 : a.currentTarget.value, a),
47
47
  "data-testid": `${m}-select-button`,
48
48
  hideLabel: !0,
49
49
  disabled: o,
@@ -54,7 +54,7 @@ const B = ({
54
54
  u,
55
55
  {
56
56
  className: `${i}__pagination-button`,
57
- onClick: () => n(t[(t.findIndex((a) => a === e) + 1) % t.length] || ""),
57
+ onClick: () => e(t[(t.findIndex((a) => a === n) + 1) % t.length] || ""),
58
58
  "data-testid": `${m}-next-button`,
59
59
  isDisabled: o,
60
60
  "aria-label": b,
@@ -3,21 +3,21 @@ import { getCommonProps as p, generatePaddingClassName as e, PaddingTokens as m
3
3
  import C from "../../node_modules/classnames/index.js";
4
4
  const g = ({
5
5
  children: s,
6
- element: n,
6
+ element: a,
7
7
  padding: o = { top: m.lg, bottom: m.lg },
8
- className: a,
8
+ className: n,
9
9
  ...t
10
10
  }) => {
11
11
  const { className: r, ...l } = p(t, "Row");
12
12
  return /* @__PURE__ */ c(
13
- n || "section",
13
+ a || "section",
14
14
  {
15
15
  ...l,
16
16
  className: C(
17
17
  r,
18
18
  o.top && e(o.top, "start"),
19
19
  o.bottom && e(o.bottom, "end"),
20
- a
20
+ n
21
21
  ),
22
22
  ...t,
23
23
  children: s
@@ -1,6 +1,6 @@
1
1
  import { jsx as a, jsxs as f } from "react/jsx-runtime";
2
2
  import i, { useEffect as y } from "react";
3
- import { getCommonProps as j, px as D, encodeURLSearchParams as C } from "../../utils/index.js";
3
+ import { getCommonProps as j, px as D, encodeURLSearchParams as g } from "../../utils/index.js";
4
4
  import p from "../../node_modules/classnames/index.js";
5
5
  import H from "../Input/Input.js";
6
6
  import O from "../Link/Link.js";
@@ -13,7 +13,7 @@ import { SearchButton as U } from "./SearchButton.js";
13
13
  import q from "../../node_modules/react-transition-group/esm/CSSTransition.js";
14
14
  const ne = ({
15
15
  onSearch: u,
16
- searchResults: N = [],
16
+ searchResults: C = [],
17
17
  state: c = "idle",
18
18
  defaultValue: E = "",
19
19
  className: I,
@@ -25,8 +25,8 @@ const ne = ({
25
25
  getAllResultsLink: _ = (e) => `/Search?Search=${e}`,
26
26
  ...S
27
27
  }) => {
28
- var g;
29
- const { className: e, "data-testid": d, ...L } = j(S, "Search"), o = i.useContext(M), m = i.useRef(null), h = i.useRef(null), v = i.useRef(null), t = o.isSearchExpanded, n = (g = m.current) == null ? void 0 : g.value, T = u ? (r) => {
28
+ var N;
29
+ const { className: e, "data-testid": d, ...L } = j(S, "Search"), o = i.useContext(M), m = i.useRef(null), h = i.useRef(null), v = i.useRef(null), t = o.isSearchExpanded, n = (N = m.current) == null ? void 0 : N.value, T = u ? (r) => {
30
30
  u(r.target.value);
31
31
  } : void 0;
32
32
  K(v, () => $(!1));
@@ -34,7 +34,7 @@ const ne = ({
34
34
  var s;
35
35
  if (r.stopPropagation(), r.key === "Enter") {
36
36
  if (r.preventDefault(), n && n.length > 2) {
37
- const P = C(_(n));
37
+ const P = g(_(n));
38
38
  window.location.href = P;
39
39
  }
40
40
  r.currentTarget instanceof HTMLAnchorElement && r.currentTarget.click();
@@ -130,14 +130,14 @@ const ne = ({
130
130
  n && n.length > 2 ? /* @__PURE__ */ a(
131
131
  V,
132
132
  {
133
- autoCompleteResults: N,
133
+ autoCompleteResults: C,
134
134
  isLoading: c === "loading",
135
135
  loadingText: b,
136
136
  onKeyDown: x,
137
137
  children: /* @__PURE__ */ a("li", { className: `${e}__result`, children: /* @__PURE__ */ a(
138
138
  O,
139
139
  {
140
- href: ((r) => C(_(r)))(n),
140
+ href: ((r) => g(_(r)))(n),
141
141
  children: /* @__PURE__ */ a("p", { children: k(n) })
142
142
  }
143
143
  ) }, "viewAllSearchResults")
@@ -1,7 +1,7 @@
1
1
  import { jsx as l } from "react/jsx-runtime";
2
2
  import n from "../../node_modules/classnames/index.js";
3
3
  import { getCommonProps as c } from "../../utils/index.js";
4
- const P = ({
4
+ const N = ({
5
5
  children: o,
6
6
  className: m,
7
7
  element: t = "section",
@@ -20,5 +20,5 @@ const P = ({
20
20
  );
21
21
  };
22
22
  export {
23
- P as default
23
+ N as default
24
24
  };
@@ -1,7 +1,7 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import { getCommonProps as d } from "../../utils/index.js";
3
3
  import l from "../../node_modules/classnames/index.js";
4
- const u = ({ aspectRatio: s = 16 / 9, className: o, videoSource: m, ...e }) => {
4
+ const N = ({ aspectRatio: s = 16 / 9, className: o, videoSource: m, ...e }) => {
5
5
  const { className: a, "data-testid": r, ...i } = d(e, "Video"), c = {
6
6
  className: l(a, o),
7
7
  "data-testid": r,
@@ -22,5 +22,5 @@ const u = ({ aspectRatio: s = 16 / 9, className: o, videoSource: m, ...e }) => {
22
22
  ) });
23
23
  };
24
24
  export {
25
- u as default
25
+ N as default
26
26
  };
package/dist/index.d.ts CHANGED
@@ -44,3 +44,4 @@ export * from './components/ContentPeek';
44
44
  export * from './components/Collapsible';
45
45
  export * from './providers/SeldonProvider';
46
46
  export { default as PageContentWrapper } from './components/PageContentWrapper/PageContentWrapper';
47
+ export * from './components/Carousel';
package/dist/index.js CHANGED
@@ -1,13 +1,13 @@
1
- import { PaddingTokens as a, SpacingTokens as f, defaultYear as p, emailValidation as d, encodeURLSearchParams as l, findChildrenExcludingTypes as m, findChildrenOfType as s, generatePaddingClassName as i, getCommonProps as u, noOp as n, px as x, useNormalizedInputProps as g } from "./utils/index.js";
2
- import { default as S } from "./pages/Page.js";
3
- import { default as P } from "./components/Button/Button.js";
4
- import { ButtonVariants as k } from "./components/Button/types.js";
1
+ import { PaddingTokens as a, SpacingTokens as f, defaultYear as l, emailValidation as p, encodeURLSearchParams as s, findChildrenExcludingTypes as d, findChildrenOfType as m, generatePaddingClassName as u, getCommonProps as n, noOp as x, px as i, useNormalizedInputProps as g } from "./utils/index.js";
2
+ import { default as C } from "./pages/Page.js";
3
+ import { default as L } from "./components/Button/Button.js";
4
+ import { ButtonVariants as I } from "./components/Button/types.js";
5
5
  import { default as T } from "./components/IconButton/IconButton.js";
6
6
  import { default as B } from "./components/ErrorBoundary/ErrorBoundary.js";
7
7
  import { default as N } from "./site-furniture/Footer/Footer.js";
8
8
  import { Grid as v } from "./components/Grid/Grid.js";
9
9
  import { default as A } from "./site-furniture/Header/Header.js";
10
- import { default as G } from "./components/Navigation/Navigation.js";
10
+ import { default as D } from "./components/Navigation/Navigation.js";
11
11
  import { default as E } from "./components/Navigation/NavigationItem/NavigationItem.js";
12
12
  import { default as M } from "./components/Navigation/NavigationItemTrigger/NavigationItemTrigger.js";
13
13
  import { default as R } from "./components/Navigation/NavigationList/NavigationList.js";
@@ -21,20 +21,20 @@ import { default as $ } from "./components/Row/Row.js";
21
21
  import { default as oe } from "./components/GridItem/GridItem.js";
22
22
  import { GridItemAlign as te } from "./components/GridItem/types.js";
23
23
  import { default as fe } from "./components/Search/Search.js";
24
- import { default as de } from "./components/Select/Select.js";
25
- import { default as me } from "./components/SplitPanel/SplitPanel.js";
26
- import { default as ie } from "./patterns/Subscribe/Subscribe.js";
27
- import { SubscriptionState as ne } from "./patterns/Subscribe/types.js";
24
+ import { default as pe } from "./components/Select/Select.js";
25
+ import { default as de } from "./components/SplitPanel/SplitPanel.js";
26
+ import { default as ue } from "./patterns/Subscribe/Subscribe.js";
27
+ import { SubscriptionState as xe } from "./patterns/Subscribe/types.js";
28
28
  import { default as ge } from "./patterns/Social/Social.js";
29
- import { default as Se } from "./patterns/ViewingsList/ViewingsList.js";
30
- import { default as Pe } from "./components/Modal/Modal.js";
31
- import { default as ke } from "./components/Drawer/Drawer.js";
29
+ import { default as Ce } from "./patterns/ViewingsList/ViewingsList.js";
30
+ import { default as Le } from "./components/Modal/Modal.js";
31
+ import { default as Ie } from "./components/Drawer/Drawer.js";
32
32
  import { default as Te } from "./components/Pagination/Pagination.js";
33
33
  import { default as Be } from "./patterns/ViewingsList/StatefulViewingsList.js";
34
34
  import { TextVariants as Ne } from "./components/Text/types.js";
35
35
  import { default as ve } from "./components/Text/Text.js";
36
36
  import { default as Ae } from "./components/Accordion/Accordion.js";
37
- import { default as Ge } from "./components/Accordion/AccordionItem.js";
37
+ import { default as De } from "./components/Accordion/AccordionItem.js";
38
38
  import { default as Ee } from "./patterns/UserManagement/UserManagement.js";
39
39
  import { AuthState as Me } from "./patterns/UserManagement/types.js";
40
40
  import { SupportedLanguages as Re } from "./types/commonTypes.js";
@@ -50,18 +50,26 @@ import { default as $e } from "./components/Collapsible/CollapsibleContent.js";
50
50
  import { default as oo } from "./components/Collapsible/CollapsibleTrigger.js";
51
51
  import { SeldonProvider as to } from "./providers/SeldonProvider.js";
52
52
  import { default as fo } from "./components/PageContentWrapper/PageContentWrapper.js";
53
+ import { default as po } from "./components/Carousel/Carousel.js";
54
+ import { default as mo } from "./components/Carousel/CarouselContent.js";
55
+ import { default as no } from "./components/Carousel/CarouselItem.js";
56
+ import { default as io } from "./components/Carousel/CarouselDots.js";
53
57
  export {
54
58
  Ae as Accordion,
55
- Ge as AccordionItem,
59
+ De as AccordionItem,
56
60
  Me as AuthState,
57
61
  ze as Breadcrumb,
58
- P as Button,
59
- k as ButtonVariants,
62
+ L as Button,
63
+ I as ButtonVariants,
64
+ po as Carousel,
65
+ mo as CarouselContent,
66
+ io as CarouselDots,
67
+ no as CarouselItem,
60
68
  Ze as Collapsible,
61
69
  $e as CollapsibleContent,
62
70
  oo as CollapsibleTrigger,
63
71
  Qe as ContentPeek,
64
- ke as Drawer,
72
+ Ie as Drawer,
65
73
  We as Dropdown,
66
74
  B as ErrorBoundary,
67
75
  N as Footer,
@@ -77,39 +85,39 @@ export {
77
85
  Q as LinkBlock,
78
86
  Z as LinkList,
79
87
  J as LinkVariants,
80
- Pe as Modal,
81
- G as Navigation,
88
+ Le as Modal,
89
+ D as Navigation,
82
90
  E as NavigationItem,
83
91
  M as NavigationItemTrigger,
84
92
  R as NavigationList,
85
93
  a as PaddingTokens,
86
- S as Page,
94
+ C as Page,
87
95
  fo as PageContentWrapper,
88
96
  Te as Pagination,
89
97
  $ as Row,
90
98
  fe as Search,
91
99
  to as SeldonProvider,
92
- de as Select,
100
+ pe as Select,
93
101
  ge as Social,
94
102
  f as SpacingTokens,
95
- me as SplitPanel,
103
+ de as SplitPanel,
96
104
  Be as StatefulViewingsList,
97
- ie as Subscribe,
98
- ne as SubscriptionState,
105
+ ue as Subscribe,
106
+ xe as SubscriptionState,
99
107
  Re as SupportedLanguages,
100
108
  ve as Text,
101
109
  Ne as TextVariants,
102
110
  Ee as UserManagement,
103
111
  je as Video,
104
- Se as ViewingsList,
105
- p as defaultYear,
106
- d as emailValidation,
107
- l as encodeURLSearchParams,
108
- m as findChildrenExcludingTypes,
109
- s as findChildrenOfType,
110
- i as generatePaddingClassName,
111
- u as getCommonProps,
112
- n as noOp,
113
- x as px,
112
+ Ce as ViewingsList,
113
+ l as defaultYear,
114
+ p as emailValidation,
115
+ s as encodeURLSearchParams,
116
+ d as findChildrenExcludingTypes,
117
+ m as findChildrenOfType,
118
+ u as generatePaddingClassName,
119
+ n as getCommonProps,
120
+ x as noOp,
121
+ i as px,
114
122
  g as useNormalizedInputProps
115
123
  };