@phillips/seldon 1.30.1 → 1.31.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/assets/PhillipsLogo.svg.js +5 -0
- package/dist/components/Button/Button.d.ts +5 -1
- package/dist/components/Button/Button.js +23 -21
- package/dist/components/Header/Header.d.ts +5 -1
- package/dist/components/Header/Header.js +35 -33
- package/dist/components/Navigation/NavigationList/NavigationList.js +5 -5
- package/dist/components/UserManagement/UserManagement.js +19 -12
- package/dist/scss/_utils.scss +12 -0
- package/dist/scss/_vars.scss +6 -0
- package/dist/scss/components/Button/_button.scss +11 -0
- package/dist/scss/components/Header/_header.scss +13 -13
- package/dist/scss/components/Input/_input.scss +6 -0
- package/dist/scss/components/Navigation/NavigationItem/_navigationItem.scss +16 -37
- package/dist/scss/components/Navigation/NavigationList/_navigationList.scss +7 -10
- package/dist/scss/components/Navigation/_navigation.scss +5 -3
- package/dist/scss/components/Search/_search.scss +8 -7
- package/dist/scss/components/UserManagement/_userManagement.scss +14 -8
- package/package.json +5 -5
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as e from "react";
|
|
2
|
+
const l = (t) => /* @__PURE__ */ e.createElement("svg", { "data-testid": "header-logo-svg", width: 131, height: 18, viewBox: "0 0 131 18", fill: "none", xmlns: "http://www.w3.org/2000/svg", ...t }, /* @__PURE__ */ e.createElement("g", { id: "Logo/ HP Button", clipPath: "url(#clip0_3288_4057)" }, /* @__PURE__ */ e.createElement("path", { id: "Phillips Logo", d: "M54.8166 0.274027H52.6224V13.726H63.7504V11.6083H54.8166V0.274027ZM41.3171 13.7273H43.5119V0.274027H41.3171V13.7273ZM21.276 0.274027H19.1214V13.726H21.2566V8.86215H30.0526V13.726H32.2079V0.274027H30.0526V6.80339H21.2566L21.276 0.274027ZM87.8477 13.7273H90.0425V0.274027H87.8477V13.7273ZM118.23 10.402L117.489 12.3843C119.214 13.3651 122.153 14 124.23 14C128.07 14 130.48 12.4912 130.48 9.84295C130.48 6.72565 127.521 6.17565 124.309 5.86211C122.252 5.66647 120.096 5.50969 120.096 4.01971C120.096 2.86206 121.135 2.11772 123.898 2.11772C125.543 2.11772 127.444 2.49021 129.031 3.15747L129.716 1.157C127.953 0.39193 125.817 0 123.936 0C120.058 0 117.863 1.52885 117.863 4.01971C117.863 7.1571 120.861 7.7058 124.034 7.99991C126.091 8.1962 128.227 8.37305 128.227 9.8436C128.227 11.0401 127.15 11.8829 124.25 11.8829C122.467 11.8823 120.004 11.3485 118.23 10.402ZM72.4298 0.274027H70.2357V13.726H81.3637V11.6083H72.4298V0.274027ZM106.676 0.274027H99.1724V13.726H101.367V9.27417H106.676C109.811 9.27417 111.614 7.39161 111.614 4.76406C111.614 2.15659 109.85 0.274027 106.676 0.274027ZM106.421 7.1571H101.367V2.39174H106.421C108.321 2.39174 109.379 3.27407 109.379 4.7647C109.38 6.25533 108.361 7.1571 106.421 7.1571ZM7.50343 0.274027H0V13.726H2.19414V9.27417H7.50343C10.638 9.27417 12.4399 7.39161 12.4399 4.76406C12.4406 2.15659 10.6775 0.274027 7.50343 0.274027ZM7.24907 7.1571H2.19414V2.39174H7.24907C9.14936 2.39174 10.2069 3.27407 10.2069 4.7647C10.2063 6.25533 9.18819 7.1571 7.24907 7.1571Z", fill: "black" })), /* @__PURE__ */ e.createElement("defs", null, /* @__PURE__ */ e.createElement("clipPath", { id: "clip0_3288_4057" }, /* @__PURE__ */ e.createElement("rect", { width: 130.667, height: 14, fill: "white" }))));
|
|
3
|
+
export {
|
|
4
|
+
l as default
|
|
5
|
+
};
|
|
@@ -23,6 +23,10 @@ export interface ButtonProps extends React.HTMLAttributes<HTMLButtonElement> {
|
|
|
23
23
|
* The type of the button.
|
|
24
24
|
*/
|
|
25
25
|
type?: 'button' | 'submit' | 'reset';
|
|
26
|
+
/**
|
|
27
|
+
* Should the button be disabled?
|
|
28
|
+
*/
|
|
29
|
+
isDisabled?: boolean;
|
|
26
30
|
}
|
|
27
31
|
/**
|
|
28
32
|
* ## Overview
|
|
@@ -33,5 +37,5 @@ export interface ButtonProps extends React.HTMLAttributes<HTMLButtonElement> {
|
|
|
33
37
|
*
|
|
34
38
|
* [Storybook Link](https://phillips-seldon.netlify.app/?path=/docs/components-button--overview)
|
|
35
39
|
*/
|
|
36
|
-
declare const Button: ({ buttonType, size, children, className, isIconLast: iconLast, type, ...props }: ButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
declare const Button: ({ buttonType, size, children, className, isIconLast: iconLast, type, isDisabled, ...props }: ButtonProps) => import("react/jsx-runtime").JSX.Element;
|
|
37
41
|
export default Button;
|
|
@@ -1,35 +1,37 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
1
|
+
import { jsx as i } from "react/jsx-runtime";
|
|
2
|
+
import f from "../../node_modules/classnames/index.js";
|
|
3
3
|
import { getCommonProps as u } from "../../utils/index.js";
|
|
4
|
-
const
|
|
4
|
+
const d = ({
|
|
5
5
|
buttonType: t = "primary",
|
|
6
|
-
size:
|
|
7
|
-
children:
|
|
8
|
-
className:
|
|
9
|
-
isIconLast:
|
|
10
|
-
type:
|
|
11
|
-
|
|
6
|
+
size: a = "md",
|
|
7
|
+
children: m,
|
|
8
|
+
className: e,
|
|
9
|
+
isIconLast: n = !1,
|
|
10
|
+
type: r = "button",
|
|
11
|
+
isDisabled: l = !1,
|
|
12
|
+
...o
|
|
12
13
|
}) => {
|
|
13
|
-
const { className:
|
|
14
|
-
return /* @__PURE__ */
|
|
14
|
+
const { className: s, ...c } = u(o, "Button");
|
|
15
|
+
return /* @__PURE__ */ i(
|
|
15
16
|
"button",
|
|
16
17
|
{
|
|
17
18
|
...c,
|
|
18
|
-
type:
|
|
19
|
-
className:
|
|
20
|
-
`${
|
|
21
|
-
`${
|
|
22
|
-
`${
|
|
19
|
+
type: r,
|
|
20
|
+
className: f(
|
|
21
|
+
`${s}`,
|
|
22
|
+
`${s}--${a}`,
|
|
23
|
+
`${s}--${t}`,
|
|
23
24
|
{
|
|
24
|
-
[`${
|
|
25
|
+
[`${s}--icon-last`]: n
|
|
25
26
|
},
|
|
26
|
-
|
|
27
|
+
e
|
|
27
28
|
),
|
|
28
|
-
|
|
29
|
-
|
|
29
|
+
disabled: l,
|
|
30
|
+
...o,
|
|
31
|
+
children: m
|
|
30
32
|
}
|
|
31
33
|
);
|
|
32
34
|
};
|
|
33
35
|
export {
|
|
34
|
-
|
|
36
|
+
d as default
|
|
35
37
|
};
|
|
@@ -16,6 +16,10 @@ export interface HeaderProps extends React.HTMLAttributes<HTMLElement> {
|
|
|
16
16
|
* Toggle close text
|
|
17
17
|
*/
|
|
18
18
|
toggleCloseText?: string;
|
|
19
|
+
/**
|
|
20
|
+
* label for the Logo link
|
|
21
|
+
*/
|
|
22
|
+
logoText?: string;
|
|
19
23
|
}
|
|
20
24
|
export declare const HeaderContext: React.Context<{
|
|
21
25
|
defaultMobileMenuLabel: string;
|
|
@@ -24,5 +28,5 @@ export declare const HeaderContext: React.Context<{
|
|
|
24
28
|
isExpanded: boolean;
|
|
25
29
|
onSelect: (_label: string) => void;
|
|
26
30
|
}>;
|
|
27
|
-
declare const Header: ({ defaultMobileMenuLabel, logo, className, children, toggleOpenText, toggleCloseText, ...props }: React.PropsWithChildren<HeaderProps>) => import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
declare const Header: ({ defaultMobileMenuLabel, logo, className, children, toggleOpenText, toggleCloseText, logoText, ...props }: React.PropsWithChildren<HeaderProps>) => import("react/jsx-runtime").JSX.Element;
|
|
28
32
|
export default Header;
|
|
@@ -1,72 +1,74 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import * as
|
|
1
|
+
import { jsxs as I, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import r from "../../node_modules/classnames/index.js";
|
|
3
|
+
import * as c from "react";
|
|
4
4
|
import { px as a } from "../../utils/index.js";
|
|
5
|
-
import
|
|
6
|
-
|
|
5
|
+
import y from "../Search/Search.js";
|
|
6
|
+
import E from "../../assets/PhillipsLogo.svg.js";
|
|
7
|
+
const N = c.createContext({
|
|
7
8
|
defaultMobileMenuLabel: "",
|
|
8
9
|
expandedItem: "",
|
|
9
10
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function
|
|
10
|
-
setExpandedItem: (
|
|
11
|
+
setExpandedItem: (t) => {
|
|
11
12
|
},
|
|
12
13
|
isExpanded: !1,
|
|
13
14
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars, @typescript-eslint/no-empty-function
|
|
14
|
-
onSelect: (
|
|
15
|
+
onSelect: (t) => {
|
|
15
16
|
}
|
|
16
17
|
}), k = ({
|
|
17
|
-
defaultMobileMenuLabel:
|
|
18
|
-
logo:
|
|
19
|
-
className:
|
|
20
|
-
children:
|
|
21
|
-
toggleOpenText:
|
|
22
|
-
toggleCloseText:
|
|
23
|
-
|
|
18
|
+
defaultMobileMenuLabel: t = "Main Menu",
|
|
19
|
+
logo: d = /* @__PURE__ */ e(E, {}),
|
|
20
|
+
className: g,
|
|
21
|
+
children: _,
|
|
22
|
+
toggleOpenText: l = "Open Menu",
|
|
23
|
+
toggleCloseText: m = "Close Menu",
|
|
24
|
+
logoText: x = "Home Page",
|
|
25
|
+
...v
|
|
24
26
|
}) => {
|
|
25
|
-
const [
|
|
26
|
-
|
|
27
|
+
const [s, f] = c.useState(!1), [h, i] = c.useState(t), o = s ? m : l, S = h !== t, p = function() {
|
|
28
|
+
f((n) => !n), i(t);
|
|
27
29
|
}, $ = function(n) {
|
|
28
|
-
|
|
30
|
+
i((u) => u === t ? n : t);
|
|
29
31
|
};
|
|
30
|
-
return /* @__PURE__ */
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
+
return /* @__PURE__ */ I("header", { ...v, className: r(`${a}-header`, g), children: [
|
|
33
|
+
/* @__PURE__ */ e(
|
|
32
34
|
"div",
|
|
33
35
|
{
|
|
34
|
-
className:
|
|
36
|
+
className: r(`${a}-header__overlay`, { [`${a}-header__overlay--active`]: s }),
|
|
35
37
|
"data-testid": "header-overlay",
|
|
36
38
|
onClick: p
|
|
37
39
|
}
|
|
38
40
|
),
|
|
39
|
-
/* @__PURE__ */
|
|
41
|
+
/* @__PURE__ */ e(
|
|
40
42
|
"button",
|
|
41
43
|
{
|
|
42
|
-
"aria-label":
|
|
44
|
+
"aria-label": o,
|
|
43
45
|
"data-testid": "mobile-menu-toggle",
|
|
44
46
|
type: "button",
|
|
45
47
|
onClick: p,
|
|
46
|
-
className:
|
|
47
|
-
[`${a}-header__toggle-btn--open`]:
|
|
48
|
+
className: r(`${a}-header__toggle-btn`, {
|
|
49
|
+
[`${a}-header__toggle-btn--open`]: o === m
|
|
48
50
|
}),
|
|
49
|
-
children: /* @__PURE__ */
|
|
51
|
+
children: /* @__PURE__ */ e("span", { children: o })
|
|
50
52
|
}
|
|
51
53
|
),
|
|
52
|
-
/* @__PURE__ */
|
|
53
|
-
/* @__PURE__ */
|
|
54
|
-
|
|
54
|
+
/* @__PURE__ */ e("h1", { "data-testid": "header-logo", className: `${a}-header__logo`, tabIndex: o === l ? 0 : -1, children: /* @__PURE__ */ e("a", { href: "/", "aria-label": x, children: typeof d == "object" ? d : /* @__PURE__ */ e("img", { alt: "Phillips", "data-testid": "header-logo-img", src: d, height: "14" }) }) }),
|
|
55
|
+
/* @__PURE__ */ e("div", { className: r(`${a}-header__nav`, { [`${a}-header__nav--open`]: s }), children: /* @__PURE__ */ e(
|
|
56
|
+
N.Provider,
|
|
55
57
|
{
|
|
56
58
|
value: {
|
|
57
|
-
defaultMobileMenuLabel:
|
|
59
|
+
defaultMobileMenuLabel: t,
|
|
58
60
|
expandedItem: h,
|
|
59
|
-
setExpandedItem: (n) =>
|
|
61
|
+
setExpandedItem: (n) => i(n),
|
|
60
62
|
isExpanded: S,
|
|
61
63
|
onSelect: (n) => $(n)
|
|
62
64
|
},
|
|
63
|
-
children:
|
|
65
|
+
children: _
|
|
64
66
|
}
|
|
65
67
|
) }),
|
|
66
|
-
/* @__PURE__ */
|
|
68
|
+
/* @__PURE__ */ e(y, {})
|
|
67
69
|
] });
|
|
68
70
|
};
|
|
69
71
|
export {
|
|
70
|
-
|
|
72
|
+
N as HeaderContext,
|
|
71
73
|
k as default
|
|
72
74
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsxs as p, jsx as
|
|
1
|
+
import { jsxs as p, jsx as _ } from "react/jsx-runtime";
|
|
2
2
|
import * as r from "react";
|
|
3
3
|
import { px as a } from "../../../utils/index.js";
|
|
4
4
|
import l from "../../../node_modules/classnames/index.js";
|
|
5
5
|
import { HeaderContext as v } from "../../Header/Header.js";
|
|
6
|
-
const x = ({ id: o, children: n, className:
|
|
6
|
+
const x = ({ id: o, children: n, className: m }) => {
|
|
7
7
|
const { isExpanded: i } = r.useContext(v), s = r.Children.toArray(n).filter((t) => {
|
|
8
8
|
if (t && t.props.navGroup === "nav-link-lg")
|
|
9
9
|
return t;
|
|
@@ -18,10 +18,10 @@ const x = ({ id: o, children: n, className: _ }) => {
|
|
|
18
18
|
"data-testid": o,
|
|
19
19
|
role: "list",
|
|
20
20
|
"aria-expanded": i,
|
|
21
|
-
className: l(
|
|
21
|
+
className: l(m, `${a}-nav__list`, { [`${a}-nav__list--expanded`]: i }),
|
|
22
22
|
children: [
|
|
23
|
-
s.length > 0 ? /* @__PURE__ */
|
|
24
|
-
e.length > 0 ? /* @__PURE__ */
|
|
23
|
+
s.length > 0 ? /* @__PURE__ */ _("div", { className: l(`${a}-nav__list__section`, `${a}-nav__list__section--large-cta`), children: s }) : null,
|
|
24
|
+
e.length > 0 ? /* @__PURE__ */ _("div", { className: l(`${a}-nav__list__section`, `${a}-nav__list__section--small-cta`), children: e }) : null,
|
|
25
25
|
!s.length && !e.length ? n : null
|
|
26
26
|
]
|
|
27
27
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as u, jsx as a } from "react/jsx-runtime";
|
|
2
2
|
import { getCommonProps as x, px as j, noOp as s } from "../../utils/index.js";
|
|
3
3
|
import A from "../Input/Input.js";
|
|
4
4
|
import E from "../../assets/account_circle.svg.js";
|
|
@@ -19,19 +19,26 @@ const H = ({
|
|
|
19
19
|
onLanguageChange: d = s,
|
|
20
20
|
isLoggedIn: r = !1,
|
|
21
21
|
onLogin: f = s,
|
|
22
|
-
onLogout:
|
|
23
|
-
loginLabel:
|
|
24
|
-
logoutLabel:
|
|
25
|
-
...
|
|
22
|
+
onLogout: _ = s,
|
|
23
|
+
loginLabel: h = "Login",
|
|
24
|
+
logoutLabel: N = "Logout",
|
|
25
|
+
...c
|
|
26
26
|
}) => {
|
|
27
|
-
var
|
|
28
|
-
const { className: l, ...b } = x(
|
|
29
|
-
return /* @__PURE__ */
|
|
30
|
-
/* @__PURE__ */
|
|
31
|
-
r && /* @__PURE__ */ a(
|
|
32
|
-
/* @__PURE__ */ a(
|
|
27
|
+
var t, g;
|
|
28
|
+
const { className: l, ...b } = x(c, "UserManagement"), $ = (g = (t = i.find((e) => e.value === n)) == null ? void 0 : t.label) != null ? g : "English", C = m != null ? m : "a";
|
|
29
|
+
return /* @__PURE__ */ u("div", { ...b, className: T(l, v), ...c, children: [
|
|
30
|
+
/* @__PURE__ */ u("ul", { className: `${l}__account-wrapper`, children: [
|
|
31
|
+
r && /* @__PURE__ */ a(C, { children: /* @__PURE__ */ a(E, { className: `${l}__account-icon` }) }),
|
|
32
|
+
/* @__PURE__ */ a(
|
|
33
|
+
S,
|
|
34
|
+
{
|
|
35
|
+
className: `${l}__login`,
|
|
36
|
+
onClick: r ? _ : f,
|
|
37
|
+
label: r ? N : h
|
|
38
|
+
}
|
|
39
|
+
)
|
|
33
40
|
] }),
|
|
34
|
-
/* @__PURE__ */ a(M, { className: `${l}__language`, label:
|
|
41
|
+
/* @__PURE__ */ a(M, { className: `${l}__language`, label: $, children: /* @__PURE__ */ a(P, { id: `${j}-langauge-selection-list`, className: `${l}__language__selections`, children: i.map((e) => /* @__PURE__ */ a("li", { children: /* @__PURE__ */ a(
|
|
35
42
|
A,
|
|
36
43
|
{
|
|
37
44
|
type: "radio",
|
package/dist/scss/_utils.scss
CHANGED
package/dist/scss/_vars.scss
CHANGED
|
@@ -229,6 +229,12 @@ $breakpoint-xl: 1801px;
|
|
|
229
229
|
///////////////////////
|
|
230
230
|
$max-site-width: 1560px;
|
|
231
231
|
|
|
232
|
+
////////////////////////
|
|
233
|
+
/// height Tokens
|
|
234
|
+
///////////////////////
|
|
235
|
+
$header-height: 60px;
|
|
236
|
+
$user-management-height: 30px;
|
|
237
|
+
|
|
232
238
|
////////////////////////
|
|
233
239
|
/// Our tokens usually support at least 4 sizes.
|
|
234
240
|
///////////////////////
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
@import '../../vars';
|
|
2
|
+
@import '../../utils';
|
|
2
3
|
|
|
3
4
|
.#{$px}-header {
|
|
4
5
|
align-items: center;
|
|
5
6
|
background-color: $white;
|
|
6
7
|
border-bottom: 1px solid rgba(0, 0, 0, 10%);
|
|
7
8
|
display: flex;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
top: 30px;
|
|
12
|
-
width: 100vw;
|
|
9
|
+
padding: $user-management-height $spacing-md 0; // save space for the user management
|
|
10
|
+
position: sticky;
|
|
11
|
+
top: 0;
|
|
13
12
|
|
|
14
|
-
@
|
|
13
|
+
@include isHeaderMobile {
|
|
14
|
+
padding: 0;
|
|
15
15
|
top: 0;
|
|
16
16
|
}
|
|
17
17
|
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
border: none;
|
|
23
23
|
cursor: pointer;
|
|
24
24
|
display: flex;
|
|
25
|
-
height:
|
|
25
|
+
height: $header-height;
|
|
26
26
|
justify-content: center;
|
|
27
27
|
left: 0;
|
|
28
28
|
overflow: hidden;
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
width: 60px;
|
|
33
33
|
z-index: 1;
|
|
34
34
|
|
|
35
|
-
@
|
|
35
|
+
@include isHeaderDesktop {
|
|
36
36
|
display: none;
|
|
37
37
|
}
|
|
38
38
|
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
&__logo {
|
|
89
89
|
margin: auto;
|
|
90
90
|
|
|
91
|
-
@
|
|
91
|
+
@include isHeaderDesktop {
|
|
92
92
|
margin: unset;
|
|
93
93
|
}
|
|
94
94
|
}
|
|
@@ -108,7 +108,7 @@
|
|
|
108
108
|
height: 100%;
|
|
109
109
|
opacity: 1;
|
|
110
110
|
|
|
111
|
-
@
|
|
111
|
+
@include isHeaderDesktop {
|
|
112
112
|
display: none;
|
|
113
113
|
}
|
|
114
114
|
|
|
@@ -134,8 +134,8 @@
|
|
|
134
134
|
top: 0;
|
|
135
135
|
transform: translateX(-100%);
|
|
136
136
|
|
|
137
|
-
@
|
|
138
|
-
height:
|
|
137
|
+
@include isHeaderDesktop {
|
|
138
|
+
height: $header-height;
|
|
139
139
|
position: relative;
|
|
140
140
|
transform: unset;
|
|
141
141
|
width: 100%;
|
|
@@ -144,7 +144,7 @@
|
|
|
144
144
|
&.#{$px}-header__nav--open {
|
|
145
145
|
transform: translateX(0);
|
|
146
146
|
|
|
147
|
-
@
|
|
147
|
+
@include isHeaderDesktop {
|
|
148
148
|
transform: unset;
|
|
149
149
|
}
|
|
150
150
|
}
|
|
@@ -130,10 +130,16 @@ $lg: #{$px}-input--lg;
|
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
+
.#{$px}-input__label:has(+ input[type='radio']),
|
|
134
|
+
.#{$px}-input__label:has(+ input[type='checkbox']) {
|
|
135
|
+
cursor: pointer;
|
|
136
|
+
}
|
|
137
|
+
|
|
133
138
|
.#{$px}-radio-input,
|
|
134
139
|
.#{$px}-checkbox-input {
|
|
135
140
|
.#{$px}-input__input {
|
|
136
141
|
align-self: flex-start;
|
|
142
|
+
cursor: pointer;
|
|
137
143
|
}
|
|
138
144
|
|
|
139
145
|
&.#{$px}-input--inline {
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
@import '../../../vars';
|
|
2
|
+
@import '../../../utils';
|
|
2
3
|
@import '../../../typography';
|
|
3
4
|
|
|
4
5
|
.#{$px}-nav__item {
|
|
5
|
-
@
|
|
6
|
+
@include isHeaderMobile {
|
|
6
7
|
border-bottom: 1px solid #ccc;
|
|
7
8
|
max-width: 320px;
|
|
8
9
|
width: 100%;
|
|
9
10
|
}
|
|
10
11
|
|
|
11
|
-
@
|
|
12
|
+
@include isHeaderDesktop {
|
|
12
13
|
align-items: center;
|
|
13
14
|
display: flex;
|
|
14
15
|
max-width: unset;
|
|
@@ -38,16 +39,14 @@
|
|
|
38
39
|
text-transform: uppercase;
|
|
39
40
|
width: 100%;
|
|
40
41
|
|
|
41
|
-
@
|
|
42
|
+
@include isHeaderMobile {
|
|
42
43
|
position: relative;
|
|
43
44
|
}
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
&--expanded ~ & &--label,
|
|
47
48
|
&--expanded ~ & > button {
|
|
48
|
-
@
|
|
49
|
-
display: none;
|
|
50
|
-
|
|
49
|
+
@include isHeaderMobile {
|
|
51
50
|
& > span::after {
|
|
52
51
|
content: '';
|
|
53
52
|
}
|
|
@@ -55,8 +54,7 @@
|
|
|
55
54
|
}
|
|
56
55
|
|
|
57
56
|
ul {
|
|
58
|
-
background: $
|
|
59
|
-
opacity: 0;
|
|
57
|
+
background: $off-white;
|
|
60
58
|
overflow: hidden scroll;
|
|
61
59
|
position: absolute;
|
|
62
60
|
right: 0;
|
|
@@ -65,7 +63,7 @@
|
|
|
65
63
|
z-index: -10;
|
|
66
64
|
}
|
|
67
65
|
|
|
68
|
-
@
|
|
66
|
+
@include isHeaderDesktop {
|
|
69
67
|
ul {
|
|
70
68
|
align-content: start;
|
|
71
69
|
background: #f4f4f4;
|
|
@@ -73,7 +71,6 @@
|
|
|
73
71
|
left: 0;
|
|
74
72
|
max-height: 0;
|
|
75
73
|
min-height: 0;
|
|
76
|
-
opacity: 0;
|
|
77
74
|
overflow: hidden;
|
|
78
75
|
position: fixed;
|
|
79
76
|
top: 90px;
|
|
@@ -83,12 +80,11 @@
|
|
|
83
80
|
li {
|
|
84
81
|
display: flex;
|
|
85
82
|
justify-content: end;
|
|
86
|
-
opacity: 0;
|
|
87
83
|
|
|
88
84
|
button,
|
|
89
85
|
a,
|
|
90
86
|
p {
|
|
91
|
-
@
|
|
87
|
+
@include isHeaderDesktop {
|
|
92
88
|
border: none;
|
|
93
89
|
}
|
|
94
90
|
}
|
|
@@ -110,22 +106,13 @@
|
|
|
110
106
|
&--expanded:focus-within ul {
|
|
111
107
|
max-height: 100vh;
|
|
112
108
|
min-height: 227px;
|
|
113
|
-
|
|
114
|
-
padding: 3.75rem;
|
|
109
|
+
padding: 2rem 3.75rem;
|
|
115
110
|
z-index: 1;
|
|
116
|
-
|
|
117
|
-
li {
|
|
118
|
-
opacity: 1;
|
|
119
|
-
|
|
120
|
-
ul li::after {
|
|
121
|
-
opacity: 0;
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
111
|
}
|
|
125
112
|
}
|
|
126
113
|
|
|
127
114
|
.#{$px}-nav__item-trigger > label::after {
|
|
128
|
-
@
|
|
115
|
+
@include isHeaderMobile {
|
|
129
116
|
content: '\203A';
|
|
130
117
|
display: inline-block;
|
|
131
118
|
font-size: 1.75rem;
|
|
@@ -136,13 +123,12 @@
|
|
|
136
123
|
transform: translateY(-50%);
|
|
137
124
|
}
|
|
138
125
|
|
|
139
|
-
@
|
|
126
|
+
@include isHeaderDesktop {
|
|
140
127
|
content: '';
|
|
141
128
|
}
|
|
142
129
|
}
|
|
143
130
|
|
|
144
131
|
&.#{$px}-nav__item--expanded ul {
|
|
145
|
-
opacity: 1;
|
|
146
132
|
z-index: 0;
|
|
147
133
|
}
|
|
148
134
|
|
|
@@ -150,11 +136,12 @@
|
|
|
150
136
|
& > button,
|
|
151
137
|
& > p {
|
|
152
138
|
background-color: transparent;
|
|
139
|
+
border: 0;
|
|
153
140
|
display: flex;
|
|
154
141
|
padding: 0.625rem;
|
|
155
142
|
}
|
|
156
143
|
|
|
157
|
-
@
|
|
144
|
+
@include isHeaderMobile {
|
|
158
145
|
& > a:focus,
|
|
159
146
|
& > button:focus,
|
|
160
147
|
& > p:focus {
|
|
@@ -170,7 +157,7 @@
|
|
|
170
157
|
}
|
|
171
158
|
}
|
|
172
159
|
|
|
173
|
-
@
|
|
160
|
+
@include isHeaderDesktop {
|
|
174
161
|
position: relative;
|
|
175
162
|
|
|
176
163
|
&:not(ul ul li) a:focus,
|
|
@@ -186,7 +173,6 @@
|
|
|
186
173
|
content: '';
|
|
187
174
|
height: 2px;
|
|
188
175
|
left: 50%;
|
|
189
|
-
opacity: 0;
|
|
190
176
|
position: absolute;
|
|
191
177
|
top: 70%;
|
|
192
178
|
transform: translateX(-50%);
|
|
@@ -197,7 +183,6 @@
|
|
|
197
183
|
&:not(ul ul li) a:focus::after,
|
|
198
184
|
&:not(ul ul li) button:focus::after,
|
|
199
185
|
&:not(ul ul li) p:focus::after {
|
|
200
|
-
opacity: 1;
|
|
201
186
|
width: 85%;
|
|
202
187
|
}
|
|
203
188
|
|
|
@@ -211,16 +196,10 @@
|
|
|
211
196
|
content: '';
|
|
212
197
|
height: 2px;
|
|
213
198
|
left: 0;
|
|
214
|
-
opacity: 0;
|
|
215
199
|
position: absolute;
|
|
216
200
|
top: 100%;
|
|
217
201
|
width: 100%;
|
|
218
202
|
}
|
|
219
|
-
|
|
220
|
-
&:hover > .#{$px}-nav__item-trigger::before,
|
|
221
|
-
&:focus > .#{$px}-nav__item-trigger::before {
|
|
222
|
-
opacity: 1;
|
|
223
|
-
}
|
|
224
203
|
}
|
|
225
204
|
}
|
|
226
205
|
|
|
@@ -228,7 +207,7 @@
|
|
|
228
207
|
&--large-cta {
|
|
229
208
|
margin-right: 1rem;
|
|
230
209
|
|
|
231
|
-
@
|
|
210
|
+
@include isHeaderMobile {
|
|
232
211
|
margin-right: 0;
|
|
233
212
|
}
|
|
234
213
|
.#{$px}-nav__item {
|
|
@@ -251,7 +230,7 @@
|
|
|
251
230
|
color: $keyline-gray;
|
|
252
231
|
}
|
|
253
232
|
|
|
254
|
-
@
|
|
233
|
+
@include isHeaderMobile {
|
|
255
234
|
/* TODO: Create token to handle these styles dynamically */
|
|
256
235
|
align-items: flex-start;
|
|
257
236
|
font-size: 0.6rem;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
@import '../../../vars';
|
|
2
|
+
@import '../../../utils';
|
|
2
3
|
|
|
3
4
|
.#{$px}-nav__list {
|
|
4
5
|
display: flex;
|
|
@@ -8,19 +9,19 @@
|
|
|
8
9
|
padding: 0;
|
|
9
10
|
width: 100%;
|
|
10
11
|
|
|
11
|
-
@
|
|
12
|
+
@include isHeaderMobile {
|
|
12
13
|
flex-direction: column;
|
|
13
14
|
height: calc(100vh - 102px);
|
|
14
15
|
justify-content: left;
|
|
15
16
|
min-width: 330px;
|
|
16
|
-
overflow:
|
|
17
|
+
overflow: auto;
|
|
17
18
|
padding: 0.5rem;
|
|
18
19
|
transform: translateX(0%);
|
|
19
20
|
transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1) 0.1s;
|
|
20
21
|
}
|
|
21
22
|
|
|
22
23
|
&--expanded {
|
|
23
|
-
@
|
|
24
|
+
@include isHeaderMobile {
|
|
24
25
|
&:not(li ul) {
|
|
25
26
|
transform: translateX(-50%);
|
|
26
27
|
width: 200%;
|
|
@@ -32,7 +33,7 @@
|
|
|
32
33
|
display: grid;
|
|
33
34
|
grid-template-columns: 20% 20% 20% 20% 20%;
|
|
34
35
|
|
|
35
|
-
@
|
|
36
|
+
@include isHeaderMobile {
|
|
36
37
|
display: none;
|
|
37
38
|
|
|
38
39
|
&--expanded {
|
|
@@ -72,7 +73,7 @@
|
|
|
72
73
|
grid-column: 4 / span 2;
|
|
73
74
|
height: fit-content;
|
|
74
75
|
|
|
75
|
-
@
|
|
76
|
+
@include isHeaderMobile {
|
|
76
77
|
margin-top: 2rem;
|
|
77
78
|
}
|
|
78
79
|
}
|
|
@@ -85,12 +86,8 @@
|
|
|
85
86
|
}
|
|
86
87
|
|
|
87
88
|
> li:not(.#{$px}-user-management) {
|
|
88
|
-
@
|
|
89
|
+
@include isHeaderDesktop {
|
|
89
90
|
height: 60px;
|
|
90
91
|
}
|
|
91
92
|
}
|
|
92
|
-
|
|
93
|
-
* {
|
|
94
|
-
cursor: pointer;
|
|
95
|
-
}
|
|
96
93
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
@import '../../vars';
|
|
2
|
+
@import '../../utils';
|
|
2
3
|
|
|
3
4
|
.#{$px}-nav {
|
|
4
|
-
background: $
|
|
5
|
+
background: $off-white;
|
|
5
6
|
color: $soft-black;
|
|
6
7
|
height: 100%;
|
|
7
8
|
overflow: hidden;
|
|
@@ -9,7 +10,8 @@
|
|
|
9
10
|
position: relative;
|
|
10
11
|
width: 100%;
|
|
11
12
|
|
|
12
|
-
@
|
|
13
|
+
@include isHeaderDesktop {
|
|
14
|
+
background: $pure-white;
|
|
13
15
|
display: flex;
|
|
14
16
|
flex-wrap: wrap;
|
|
15
17
|
overflow: visible;
|
|
@@ -53,7 +55,7 @@
|
|
|
53
55
|
background-color 0.5s;
|
|
54
56
|
}
|
|
55
57
|
|
|
56
|
-
@
|
|
58
|
+
@include isHeaderDesktop {
|
|
57
59
|
// Remove label and mobile buttons on larger screens
|
|
58
60
|
.#{$px}-nav__back-btn,
|
|
59
61
|
.#{$px}-nav__close-btn,
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
@import '../../vars';
|
|
2
2
|
@import '../../typography';
|
|
3
|
+
@import '../../utils';
|
|
3
4
|
|
|
4
5
|
.#{$px}-search {
|
|
5
6
|
align-items: center;
|
|
6
7
|
display: flex;
|
|
7
|
-
height:
|
|
8
|
+
height: $header-height;
|
|
8
9
|
justify-content: center;
|
|
9
10
|
padding: 0.47rem;
|
|
10
11
|
|
|
@@ -33,7 +34,7 @@
|
|
|
33
34
|
padding: 0;
|
|
34
35
|
width: 18px;
|
|
35
36
|
|
|
36
|
-
@
|
|
37
|
+
@include isHeaderMobile {
|
|
37
38
|
border: 2px solid black;
|
|
38
39
|
border-radius: 50%;
|
|
39
40
|
height: 35px;
|
|
@@ -57,20 +58,20 @@
|
|
|
57
58
|
overflow: hidden;
|
|
58
59
|
position: absolute;
|
|
59
60
|
right: 0;
|
|
60
|
-
top:
|
|
61
|
+
top: calc($header-height + $user-management-height);
|
|
61
62
|
transition: 0.5s ease;
|
|
62
63
|
width: 0;
|
|
63
64
|
z-index: 3;
|
|
64
65
|
|
|
65
|
-
@
|
|
66
|
-
top:
|
|
66
|
+
@include isHeaderMobile {
|
|
67
|
+
top: $header-height;
|
|
67
68
|
}
|
|
68
69
|
|
|
69
70
|
&--active {
|
|
70
71
|
width: 50%;
|
|
71
72
|
|
|
72
|
-
@
|
|
73
|
-
top:
|
|
73
|
+
@include isHeaderMobile {
|
|
74
|
+
top: $header-height;
|
|
74
75
|
width: 100%;
|
|
75
76
|
}
|
|
76
77
|
}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
@import '../../_vars';
|
|
2
|
+
@import '../../_utils';
|
|
2
3
|
|
|
3
4
|
.#{$px}-user-management {
|
|
4
5
|
align-items: center;
|
|
5
6
|
background-color: #f4f4f4;
|
|
6
7
|
display: flex;
|
|
7
|
-
height:
|
|
8
|
+
height: $user-management-height;
|
|
8
9
|
justify-content: flex-end;
|
|
9
10
|
left: 0;
|
|
10
11
|
padding: 0 $spacing-md;
|
|
@@ -13,7 +14,7 @@
|
|
|
13
14
|
top: 0;
|
|
14
15
|
width: 100%;
|
|
15
16
|
|
|
16
|
-
@
|
|
17
|
+
@include isHeaderMobile {
|
|
17
18
|
align-items: flex-start;
|
|
18
19
|
background: transparent;
|
|
19
20
|
flex-direction: column;
|
|
@@ -33,14 +34,13 @@
|
|
|
33
34
|
&__account-wrapper {
|
|
34
35
|
align-items: center;
|
|
35
36
|
display: flex;
|
|
36
|
-
gap: 1rem;
|
|
37
37
|
|
|
38
|
-
@
|
|
38
|
+
@include isHeaderMobile {
|
|
39
39
|
width: 100%;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
42
|
.#{$px}-link {
|
|
43
|
-
@
|
|
43
|
+
@include isHeaderMobile {
|
|
44
44
|
width: 100%;
|
|
45
45
|
}
|
|
46
46
|
|
|
@@ -53,7 +53,13 @@
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
+
&__login {
|
|
57
|
+
cursor: pointer;
|
|
58
|
+
}
|
|
59
|
+
|
|
56
60
|
&__account-icon {
|
|
61
|
+
cursor: pointer;
|
|
62
|
+
|
|
57
63
|
&:hover,
|
|
58
64
|
&:focus,
|
|
59
65
|
&:focus-within {
|
|
@@ -62,7 +68,7 @@
|
|
|
62
68
|
}
|
|
63
69
|
}
|
|
64
70
|
|
|
65
|
-
@
|
|
71
|
+
@include isHeaderMobile {
|
|
66
72
|
display: none;
|
|
67
73
|
}
|
|
68
74
|
}
|
|
@@ -82,7 +88,7 @@
|
|
|
82
88
|
}
|
|
83
89
|
.#{$px}-user-management__language {
|
|
84
90
|
&__selections {
|
|
85
|
-
@
|
|
91
|
+
@include isHeaderDesktop {
|
|
86
92
|
background: $off-white;
|
|
87
93
|
box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 85%);
|
|
88
94
|
display: block;
|
|
@@ -92,7 +98,7 @@
|
|
|
92
98
|
padding: 0;
|
|
93
99
|
position: absolute;
|
|
94
100
|
right: 0;
|
|
95
|
-
top:
|
|
101
|
+
top: $user-management-height;
|
|
96
102
|
width: 100%;
|
|
97
103
|
|
|
98
104
|
> li {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@phillips/seldon",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.31.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/PhillipsAuctionHouse/seldon"
|
|
@@ -52,14 +52,14 @@
|
|
|
52
52
|
"@semantic-release/changelog": "^6.0.3",
|
|
53
53
|
"@semantic-release/git": "^10.0.1",
|
|
54
54
|
"@semantic-release/github": "^10.1.0",
|
|
55
|
-
"@storybook/addon-essentials": "^8.2.
|
|
55
|
+
"@storybook/addon-essentials": "^8.2.4",
|
|
56
56
|
"@storybook/addon-interactions": "^8.1.4",
|
|
57
57
|
"@storybook/addon-links": "^8.1.4",
|
|
58
|
-
"@storybook/addon-mdx-gfm": "^8.
|
|
58
|
+
"@storybook/addon-mdx-gfm": "^8.2.4",
|
|
59
59
|
"@storybook/blocks": "^8.1.4",
|
|
60
60
|
"@storybook/react": "^8.1.4",
|
|
61
61
|
"@storybook/react-vite": "^8.1.4",
|
|
62
|
-
"@storybook/theming": "^8.2.
|
|
62
|
+
"@storybook/theming": "^8.2.4",
|
|
63
63
|
"@testing-library/jest-dom": "^6.4.6",
|
|
64
64
|
"@testing-library/react": "^16.0.0",
|
|
65
65
|
"@testing-library/user-event": "^14.5.2",
|
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
"rimraf": "^5.0.8",
|
|
87
87
|
"rollup-plugin-copy": "^3.5.0",
|
|
88
88
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
89
|
-
"sass": "^1.77.
|
|
89
|
+
"sass": "^1.77.8",
|
|
90
90
|
"semantic-release": "^23.1.1",
|
|
91
91
|
"storybook": "^8.1.4",
|
|
92
92
|
"stylelint": "^16.6.1",
|