@phillips/seldon 1.103.2 → 1.103.3

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.
@@ -3,7 +3,7 @@ import { getCommonProps as u, px as t } from "../../utils/index.js";
3
3
  import f from "../../node_modules/classnames/index.js";
4
4
  import p from "./BreadcrumbItem.js";
5
5
  import { SSRMediaQuery as c } from "../../providers/SeldonProvider/utils.js";
6
- import N from "../../assets/arrowPrev.svg.js";
6
+ import g from "../../assets/arrowPrev.svg.js";
7
7
  const v = ({
8
8
  className: s,
9
9
  items: a = [],
@@ -11,25 +11,25 @@ const v = ({
11
11
  linkElement: l = "a",
12
12
  ...e
13
13
  }) => {
14
- const { className: n, ...i } = u(e, "Breadcrumb"), { id: b } = e;
15
- return /* @__PURE__ */ h("nav", { "aria-label": "Breadcrumb", className: f(n, s), ...i, ...e, children: [
14
+ const { className: m, ...i } = u(e, "Breadcrumb"), { id: b } = e;
15
+ return /* @__PURE__ */ h("nav", { "aria-label": "Breadcrumb", className: f(m, s), ...i, ...e, children: [
16
16
  /* @__PURE__ */ r(c.Media, { lessThan: "md", children: /* @__PURE__ */ r(
17
17
  l,
18
18
  {
19
19
  href: a[1].href ? a[1].href : "/",
20
- className: `${t}-icon-button ${t}-icon-button--secondary`,
20
+ className: `${t}-icon-button ${t}-icon-button--primary ${m}__back-button`,
21
21
  "data-testid": `${b}-back-button`,
22
- children: /* @__PURE__ */ r(N, { className: `${n}__back-button` })
22
+ children: /* @__PURE__ */ r(g, {})
23
23
  }
24
24
  ) }),
25
- /* @__PURE__ */ r(c.Media, { greaterThanOrEqual: "md", children: /* @__PURE__ */ r("ol", { children: a.map((o, m) => /* @__PURE__ */ r(
25
+ /* @__PURE__ */ r(c.Media, { greaterThanOrEqual: "md", children: /* @__PURE__ */ r("ol", { children: a.map((o, n) => /* @__PURE__ */ r(
26
26
  p,
27
27
  {
28
28
  href: o.href,
29
29
  label: o.label,
30
30
  element: l,
31
- isCurrent: a.length - 1 === m,
32
- isTruncateText: d === m
31
+ isCurrent: a.length - 1 === n,
32
+ isTruncateText: d === n
33
33
  },
34
34
  o.label
35
35
  )) }) })
@@ -1,55 +1,55 @@
1
- import { jsxs as O, jsx as i } from "react/jsx-runtime";
1
+ import { jsxs as O, jsx as r } from "react/jsx-runtime";
2
2
  import f from "../../node_modules/classnames/index.js";
3
- import { getCommonProps as w, px as r } from "../../utils/index.js";
3
+ import { getCommonProps as w, px as u } from "../../utils/index.js";
4
4
  import V from "../Select/Select.js";
5
5
  import h from "../../assets/chevronRight.svg.js";
6
6
  import x from "../IconButton/IconButton.js";
7
7
  import { ButtonVariants as b } from "../Button/types.js";
8
- import { determineOptionValue as o, findOptionFromSelectString as j } from "./utils.js";
8
+ import { determineOptionValue as i, findOptionFromSelectString as j } from "./utils.js";
9
9
  import { usePendingState as k } from "../../utils/hooks.js";
10
10
  const G = ({
11
11
  className: P,
12
12
  onChange: $,
13
13
  variant: S = "inline",
14
14
  options: n = [],
15
- value: g,
15
+ value: p,
16
16
  isDisabled: l,
17
17
  previousLabel: v = "Previous",
18
18
  nextLabel: C = "Next",
19
- selectLabel: u = "Select",
19
+ selectLabel: g = "Select",
20
20
  ...s
21
21
  }) => {
22
- const N = "pagination", { className: p, ...I } = w(s, "Pagination"), { id: c } = s, { pendingState: _, setPendingState: y } = k(o(g)), m = _ || g, d = (t, e) => {
23
- const a = o(t);
22
+ const N = "pagination", { className: o, ...I } = w(s, "Pagination"), { id: c } = s, { pendingState: _, setPendingState: y } = k(i(p)), m = _ || p, d = (t, e) => {
23
+ const a = i(t);
24
24
  y(a), $(a, e);
25
25
  };
26
26
  return /* @__PURE__ */ O(
27
27
  "div",
28
28
  {
29
- className: f(`${r}-${N}`, { [`${p}__wrapper`]: p }, P),
29
+ className: f(`${u}-${N}`, { [`${o}__wrapper`]: o }, P),
30
30
  ...I,
31
31
  ...s,
32
32
  children: [
33
- /* @__PURE__ */ i(
33
+ /* @__PURE__ */ r(
34
34
  x,
35
35
  {
36
- className: f(`${r}__pagination-button`, `${r}-left-arrow`),
36
+ className: f(`${o}__button`, `${u}-left-arrow`),
37
37
  onClick: () => {
38
- const t = n.findIndex((a) => o(a) === m) - 1, e = n.at(t) || "";
38
+ const t = n.findIndex((a) => i(a) === m) - 1, e = n.at(t) || "";
39
39
  d(e);
40
40
  },
41
41
  "data-testid": `${c}-previous-button`,
42
42
  isDisabled: l,
43
43
  "aria-label": v,
44
- variant: b.tertiary,
45
- children: /* @__PURE__ */ i(h, {})
44
+ variant: b.primary,
45
+ children: /* @__PURE__ */ r(h, {})
46
46
  }
47
47
  ),
48
- /* @__PURE__ */ i(
48
+ /* @__PURE__ */ r(
49
49
  V,
50
50
  {
51
- className: S === "inline" ? `${r}--inline-pagination` : void 0,
52
- "aria-label": u,
51
+ className: S === "inline" ? `${u}--inline-pagination` : void 0,
52
+ "aria-label": g,
53
53
  value: m,
54
54
  onChange: (t) => {
55
55
  const e = j(n, t == null ? void 0 : t.currentTarget.value);
@@ -57,28 +57,28 @@ const G = ({
57
57
  },
58
58
  "data-testid": `${c}-select-button`,
59
59
  hideLabel: !0,
60
- labelText: u,
60
+ labelText: g,
61
61
  disabled: l,
62
62
  showIcon: !1,
63
63
  children: n.map((t) => {
64
- const e = o(t);
65
- return /* @__PURE__ */ i("option", { value: e, children: typeof t == "string" || typeof t == "number" ? t : t.label }, e);
64
+ const e = i(t);
65
+ return /* @__PURE__ */ r("option", { value: e, children: typeof t == "string" || typeof t == "number" ? t : t.label }, e);
66
66
  })
67
67
  }
68
68
  ),
69
- /* @__PURE__ */ i(
69
+ /* @__PURE__ */ r(
70
70
  x,
71
71
  {
72
- className: `${r}__pagination-button`,
72
+ className: `${o}__button`,
73
73
  onClick: () => {
74
- const t = (n.findIndex((a) => o(a) === m) + 1) % n.length, e = n[t];
74
+ const t = (n.findIndex((a) => i(a) === m) + 1) % n.length, e = n[t];
75
75
  d(e);
76
76
  },
77
77
  "data-testid": `${c}-next-button`,
78
78
  isDisabled: l,
79
79
  "aria-label": C,
80
- variant: b.tertiary,
81
- children: /* @__PURE__ */ i(h, {})
80
+ variant: b.primary,
81
+ children: /* @__PURE__ */ r(h, {})
82
82
  }
83
83
  )
84
84
  ]
@@ -5,11 +5,8 @@
5
5
 
6
6
  color: $pure-black;
7
7
 
8
- &__back-button {
9
- svg {
10
- height: 1rem;
11
- width: 1rem;
12
- }
8
+ &__back-button:hover svg path {
9
+ fill: $pure-black;
13
10
  }
14
11
 
15
12
  &__item {
@@ -4,68 +4,66 @@
4
4
  align-items: center;
5
5
  display: flex;
6
6
  flex-direction: row;
7
- gap: $spacing-sm;
8
- }
7
+ gap: $spacing-xsm;
9
8
 
10
- .#{$px} {
11
- &-icon-button {
9
+ &__button {
12
10
  &:disabled {
13
11
  border: unset;
14
12
  }
15
- &.#{$px}__pagination-button {
16
- @include media($breakpoint-md) {
17
- > svg {
18
- height: 1.75rem;
19
- width: 1.75rem;
20
- }
13
+
14
+ &:hover:not(:disabled) {
15
+ background-color: inherit;
16
+
17
+ svg path {
18
+ fill: $pure-black;
21
19
  }
22
20
  }
23
21
  }
22
+ }
24
23
 
25
- &--inline-pagination__wrapper {
26
- select {
27
- @include pText($body-size2);
28
-
29
- appearance: none;
30
- border: none;
31
- font-variation-settings: 'wght' 600;
32
- line-height: 1.75rem;
33
- margin-bottom: 0;
34
- outline: none;
35
- padding: 0 $spacing-xsm;
36
- text-align: center;
37
- text-align-last: center;
38
- text-decoration: underline;
39
- text-underline-offset: 6px;
24
+ .#{$px}--inline-pagination__wrapper {
25
+ select {
26
+ @include pText($body-size2);
40
27
 
41
- @include isHeaderDesktop {
42
- line-height: 2.5rem;
43
- text-underline-offset: 10px;
44
- }
28
+ appearance: none;
29
+ border: none;
30
+ font-variation-settings: 'wght' 600;
31
+ line-height: 1.75rem;
32
+ margin-bottom: 0;
33
+ outline: none;
34
+ padding: 0 $spacing-xsm;
35
+ text-align: center;
36
+ text-align-last: center;
37
+ text-decoration: underline;
38
+ text-underline-offset: 6px;
45
39
 
46
- &:disabled {
47
- border: 1px solid $medium-gray;
48
- margin: auto;
49
- max-height: 3.5rem;
50
- max-width: 5rem;
51
- padding: 0.5rem;
52
- text-decoration: none;
53
- }
40
+ @include isHeaderDesktop {
41
+ line-height: 2.5rem;
42
+ text-underline-offset: 10px;
43
+ }
54
44
 
55
- &:hover {
56
- cursor: pointer;
57
- }
45
+ &:disabled {
46
+ border: 1px solid $medium-gray;
47
+ margin: auto;
48
+ max-height: 3.5rem;
49
+ max-width: 5rem;
50
+ padding: 0.5rem;
51
+ text-decoration: none;
52
+ }
58
53
 
59
- &:focus-visible {
60
- outline: 1px solid $medium-gray;
61
- }
54
+ &:hover {
55
+ cursor: pointer;
62
56
  }
63
57
 
64
- select::-ms-expand {
65
- border: none;
66
- display: none;
58
+ &:focus-visible {
59
+ outline: 1px solid $medium-gray;
67
60
  }
68
61
  }
62
+
63
+ select::-ms-expand {
64
+ border: none;
65
+ display: none;
66
+ }
69
67
  }
70
68
 
71
69
  .#{$px}-left-arrow {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@phillips/seldon",
3
- "version": "1.103.2",
3
+ "version": "1.103.3",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/PhillipsAuctionHouse/seldon"