@sps-woodland/page-title 7.16.7 → 7.16.9

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/lib/index.cjs.js CHANGED
@@ -1,17 +1,6 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const d=require("react"),t=require("@sps-woodland/core"),r=require("@spscommerce/utils");function m(e){if(e&&e.__esModule)return e;const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const i=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(o,a,i.get?i:{enumerable:!0,get:()=>e[a]})}}return o.default=e,Object.freeze(o)}const n=m(d);var g="_14vazzb0",p="_14vazzb2",b="_14vazzb1";function c({children:e,className:o,...a}){const[[i],l]=t.selectChildren(e,[{type:t.Icon}]),u=i?t.addClassName(i,p):"";return n.createElement("div",{className:t.cl(g,o),...a},u,n.createElement("div",{className:b},l))}t.Metadata.set(c,{name:"Page Title"});var P="_30pzwb0",T="_30pzwb1";function s({children:e,className:o,...a}){const i=t.modChildren(e,l=>l.type===t.Icon?[{className:t.cl(l.props.className,T)}]:[]);return n.createElement("div",{className:t.cl(P,o),...a},i)}t.Metadata.set(s,{name:"Page Subtitle"});const S={components:[c,s],examples:{basic:{label:"Basic",examples:{basic:{react:r.code`
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const d=require("react"),t=require("@sps-woodland/core"),s=require("@spscommerce/utils");function m(e){if(e&&e.__esModule)return e;const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const l=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(o,a,l.get?l:{enumerable:!0,get:()=>e[a]})}}return o.default=e,Object.freeze(o)}const i=m(d);var g="_14vazzb0",p="_14vazzb2",b="_14vazzb1";function n({children:e,className:o,...a}){const[[l],r]=t.selectChildren(e,[{type:t.Icon}]),u=l?t.addClassName(l,p):"";return i.createElement("div",{className:t.cl(g,o),...a},u,i.createElement("div",{className:b},r))}t.Metadata.set(n,{name:"Page Title"});var P="_30pzwb0",T="_30pzwb1";function c({children:e,className:o,...a}){const l=t.modChildren(e,r=>r.type===t.Icon?[{className:t.cl(r.props.className,T)}]:[]);return i.createElement("div",{className:t.cl(P,o),...a},l)}t.Metadata.set(c,{name:"Page Subtitle"});const _={components:[n,c],examples:{basic:{label:"Basic",examples:{basic:{react:s.code`
2
2
  import { PageTitle } from "@sps-woodland/page-title";
3
3
 
4
- function Component() {
5
- return (
6
- <PageTitle>
7
- Cabela's Purchase Order #123456789012
8
- </PageTitle>
9
- );
10
- }
11
- `}}},withIcon:{label:"With Icon",examples:{withIcon:{react:r.code`
12
- import { PageTitle } from "@sps-woodland/page-title";
13
- import { Icon } from "@sps-woodland/core";
14
-
15
4
  function Component() {
16
5
  return (
17
6
  <PageTitle>
@@ -20,22 +9,7 @@
20
9
  </PageTitle>
21
10
  );
22
11
  }
23
- `}}},withSubtitle:{label:"With Subtitle",examples:{withSubtitle:{react:r.code`
24
- import { PageTitle, PageSubtitle } from "@sps-woodland/page-title";
25
- import { Icon } from "@sps-woodland/core";
26
-
27
- function Component() {
28
- return (
29
- <PageTitle>
30
- Cabela's Purchase Order #123456789012
31
- <PageSubtitle>Cabela's
32
- <Icon icon="outgoing" />
33
- MacNeil Automotive Parts
34
- </PageSubtitle>
35
- </PageTitle>
36
- );
37
- }
38
- `}}},withSubtitleAndIcon:{label:"With Subtitle And Icon",examples:{withSubtitleAndIcon:{react:r.code`
12
+ `}}},subtitle:{label:"Subtitle",examples:{withSubtitle:{react:s.code`
39
13
  import { PageTitle, PageSubtitle } from "@sps-woodland/page-title";
40
14
  import { Icon } from "@sps-woodland/core";
41
15
 
@@ -45,10 +19,10 @@
45
19
  <Icon aria-hidden="true" icon="status-error" color="red-medium" size="lg"/>
46
20
  Cabela's Purchase Order #123456789012
47
21
  <PageSubtitle>
48
- Cabela's <Icon aria-hidden="true" icon="outgoing" />
49
22
  MacNeil Automotive Parts
23
+ <Icon icon="outgoing" />
50
24
  </PageSubtitle>
51
25
  </PageTitle>
52
26
  );
53
27
  }
54
- `}}}}},f={"Page Title":S};exports.MANIFEST=f;exports.PageSubtitle=s;exports.PageTitle=c;
28
+ `}}}}},f={"Page Title":_};exports.MANIFEST=f;exports.PageSubtitle=c;exports.PageTitle=n;
package/lib/index.es.js CHANGED
@@ -1,38 +1,38 @@
1
- import * as n from "react";
2
- import { Metadata as s, selectChildren as u, Icon as c, addClassName as g, cl as r, modChildren as b } from "@sps-woodland/core";
3
- import { code as a } from "@spscommerce/utils";
4
- var P = "_14vazzb0", T = "_14vazzb2", h = "_14vazzb1";
1
+ import * as i from "react";
2
+ import { Metadata as n, selectChildren as u, Icon as c, addClassName as g, cl as r, modChildren as b } from "@sps-woodland/core";
3
+ import { code as s } from "@spscommerce/utils";
4
+ var P = "_14vazzb0", T = "_14vazzb2", v = "_14vazzb1";
5
5
  function m({
6
- children: o,
7
- className: i,
6
+ children: a,
7
+ className: o,
8
8
  ...l
9
9
  }) {
10
- const [[e], t] = u(o, [{ type: c }]), p = e ? g(e, T) : "";
11
- return /* @__PURE__ */ n.createElement("div", {
12
- className: r(P, i),
10
+ const [[e], t] = u(a, [{ type: c }]), p = e ? g(e, T) : "";
11
+ return /* @__PURE__ */ i.createElement("div", {
12
+ className: r(P, o),
13
13
  ...l
14
- }, p, /* @__PURE__ */ n.createElement("div", {
15
- className: h
14
+ }, p, /* @__PURE__ */ i.createElement("div", {
15
+ className: v
16
16
  }, t));
17
17
  }
18
- s.set(m, {
18
+ n.set(m, {
19
19
  name: "Page Title"
20
20
  });
21
- var I = "_30pzwb0", S = "_30pzwb1";
21
+ var S = "_30pzwb0", _ = "_30pzwb1";
22
22
  function d({
23
- children: o,
24
- className: i,
23
+ children: a,
24
+ className: o,
25
25
  ...l
26
26
  }) {
27
- const e = b(o, (t) => t.type === c ? [{
28
- className: r(t.props.className, S)
27
+ const e = b(a, (t) => t.type === c ? [{
28
+ className: r(t.props.className, _)
29
29
  }] : []);
30
- return /* @__PURE__ */ n.createElement("div", {
31
- className: r(I, i),
30
+ return /* @__PURE__ */ i.createElement("div", {
31
+ className: r(S, o),
32
32
  ...l
33
33
  }, e);
34
34
  }
35
- s.set(d, {
35
+ n.set(d, {
36
36
  name: "Page Subtitle"
37
37
  });
38
38
  const f = {
@@ -42,28 +42,9 @@ const f = {
42
42
  label: "Basic",
43
43
  examples: {
44
44
  basic: {
45
- react: a`
45
+ react: s`
46
46
  import { PageTitle } from "@sps-woodland/page-title";
47
47
 
48
- function Component() {
49
- return (
50
- <PageTitle>
51
- Cabela's Purchase Order #123456789012
52
- </PageTitle>
53
- );
54
- }
55
- `
56
- }
57
- }
58
- },
59
- withIcon: {
60
- label: "With Icon",
61
- examples: {
62
- withIcon: {
63
- react: a`
64
- import { PageTitle } from "@sps-woodland/page-title";
65
- import { Icon } from "@sps-woodland/core";
66
-
67
48
  function Component() {
68
49
  return (
69
50
  <PageTitle>
@@ -76,34 +57,11 @@ const f = {
76
57
  }
77
58
  }
78
59
  },
79
- withSubtitle: {
80
- label: "With Subtitle",
60
+ subtitle: {
61
+ label: "Subtitle",
81
62
  examples: {
82
63
  withSubtitle: {
83
- react: a`
84
- import { PageTitle, PageSubtitle } from "@sps-woodland/page-title";
85
- import { Icon } from "@sps-woodland/core";
86
-
87
- function Component() {
88
- return (
89
- <PageTitle>
90
- Cabela's Purchase Order #123456789012
91
- <PageSubtitle>Cabela's
92
- <Icon icon="outgoing" />
93
- MacNeil Automotive Parts
94
- </PageSubtitle>
95
- </PageTitle>
96
- );
97
- }
98
- `
99
- }
100
- }
101
- },
102
- withSubtitleAndIcon: {
103
- label: "With Subtitle And Icon",
104
- examples: {
105
- withSubtitleAndIcon: {
106
- react: a`
64
+ react: s`
107
65
  import { PageTitle, PageSubtitle } from "@sps-woodland/page-title";
108
66
  import { Icon } from "@sps-woodland/core";
109
67
 
@@ -113,8 +71,8 @@ const f = {
113
71
  <Icon aria-hidden="true" icon="status-error" color="red-medium" size="lg"/>
114
72
  Cabela's Purchase Order #123456789012
115
73
  <PageSubtitle>
116
- Cabela's <Icon aria-hidden="true" icon="outgoing" />
117
74
  MacNeil Automotive Parts
75
+ <Icon icon="outgoing" />
118
76
  </PageSubtitle>
119
77
  </PageTitle>
120
78
  );
@@ -124,11 +82,11 @@ const f = {
124
82
  }
125
83
  }
126
84
  }
127
- }, C = {
85
+ }, I = {
128
86
  "Page Title": f
129
87
  };
130
88
  export {
131
- C as MANIFEST,
89
+ I as MANIFEST,
132
90
  d as PageSubtitle,
133
91
  m as PageTitle
134
92
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sps-woodland/page-title",
3
3
  "description": "SPS Woodland Design System page title component",
4
- "version": "7.16.7",
4
+ "version": "7.16.9",
5
5
  "author": "SPS Commerce",
6
6
  "license": "UNLICENSED",
7
7
  "repository": "https://github.com/SPSCommerce/woodland/tree/main/packages/@sps-woodland/page-title",
@@ -29,16 +29,16 @@
29
29
  "@spscommerce/utils": "^6.12.1",
30
30
  "react": "^16.14.0",
31
31
  "react-dom": "^16.14.0",
32
- "@sps-woodland/core": "7.16.7",
33
- "@sps-woodland/tokens": "7.16.7"
32
+ "@sps-woodland/core": "7.16.9",
33
+ "@sps-woodland/tokens": "7.16.9"
34
34
  },
35
35
  "devDependencies": {
36
36
  "@spscommerce/utils": "^6.12.1",
37
37
  "@vanilla-extract/css": "^1.9.3",
38
38
  "react": "^16.14.0",
39
39
  "react-dom": "^16.14.0",
40
- "@sps-woodland/core": "7.16.7",
41
- "@sps-woodland/tokens": "7.16.7"
40
+ "@sps-woodland/core": "7.16.9",
41
+ "@sps-woodland/tokens": "7.16.9"
42
42
  },
43
43
  "scripts": {
44
44
  "build": "pnpm run build:js && pnpm run build:types",