@sps-woodland/zero-state 7.17.12 → 7.19.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.
@@ -1,9 +1,9 @@
1
1
  import * as r from "react";
2
- import { Metadata as b, cl as v, Icon as w, contentOf as u } from "@sps-woodland/core";
3
- import { Illustrations as I } from "@sps-woodland/illustrations";
4
- import { code as s } from "@spscommerce/utils";
5
- import { sprinkles as f } from "@sps-woodland/tokens";
6
- function y(e, a, o) {
2
+ import { Metadata as v, cl as w, Icon as C, contentOf as u } from "@sps-woodland/core";
3
+ import { Illustrations as b } from "@sps-woodland/illustrations";
4
+ import { code as n } from "@spscommerce/utils";
5
+ import { sprinkles as _ } from "@sps-woodland/tokens";
6
+ function I(e, a, o) {
7
7
  return a in e ? Object.defineProperty(e, a, {
8
8
  value: o,
9
9
  enumerable: !0,
@@ -11,64 +11,64 @@ function y(e, a, o) {
11
11
  writable: !0
12
12
  }) : e[a] = o, e;
13
13
  }
14
- function S(e, a) {
14
+ function f(e, a) {
15
15
  var o = Object.keys(e);
16
16
  if (Object.getOwnPropertySymbols) {
17
17
  var t = Object.getOwnPropertySymbols(e);
18
- a && (t = t.filter(function(n) {
19
- return Object.getOwnPropertyDescriptor(e, n).enumerable;
18
+ a && (t = t.filter(function(s) {
19
+ return Object.getOwnPropertyDescriptor(e, s).enumerable;
20
20
  })), o.push.apply(o, t);
21
21
  }
22
22
  return o;
23
23
  }
24
- function g(e) {
24
+ function S(e) {
25
25
  for (var a = 1; a < arguments.length; a++) {
26
26
  var o = arguments[a] != null ? arguments[a] : {};
27
- a % 2 ? S(Object(o), !0).forEach(function(t) {
28
- y(e, t, o[t]);
29
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(o)) : S(Object(o)).forEach(function(t) {
27
+ a % 2 ? f(Object(o), !0).forEach(function(t) {
28
+ I(e, t, o[t]);
29
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(o)) : f(Object(o)).forEach(function(t) {
30
30
  Object.defineProperty(e, t, Object.getOwnPropertyDescriptor(o, t));
31
31
  });
32
32
  }
33
33
  return e;
34
34
  }
35
- var E = (e, a, o) => {
35
+ var y = (e, a, o) => {
36
36
  for (var t of Object.keys(e)) {
37
- var n;
38
- if (e[t] !== ((n = a[t]) !== null && n !== void 0 ? n : o[t]))
37
+ var s;
38
+ if (e[t] !== ((s = a[t]) !== null && s !== void 0 ? s : o[t]))
39
39
  return !1;
40
40
  }
41
41
  return !0;
42
- }, p = (e) => (a) => {
43
- var o = e.defaultClassName, t = g(g({}, e.defaultVariants), a);
44
- for (var n in t) {
45
- var i, d = (i = t[n]) !== null && i !== void 0 ? i : e.defaultVariants[n];
42
+ }, c = (e) => (a) => {
43
+ var o = e.defaultClassName, t = S(S({}, e.defaultVariants), a);
44
+ for (var s in t) {
45
+ var i, d = (i = t[s]) !== null && i !== void 0 ? i : e.defaultVariants[s];
46
46
  if (d != null) {
47
47
  var l = d;
48
48
  typeof l == "boolean" && (l = l === !0 ? "true" : "false");
49
- var m = e.variantClassNames[n][l];
50
- m && (o += " " + m);
49
+ var p = e.variantClassNames[s][l];
50
+ p && (o += " " + p);
51
51
  }
52
52
  }
53
- for (var [c, C] of e.compoundVariants)
54
- E(c, t, e.defaultVariants) && (o += " " + C);
53
+ for (var [m, g] of e.compoundVariants)
54
+ y(m, t, e.defaultVariants) && (o += " " + g);
55
55
  return o;
56
- }, Z = "jrytnlc", N = p({ defaultClassName: "jrytnl3", variantClassNames: { micro: { true: "jrytnl4", false: "jrytnl5" } }, defaultVariants: { micro: !1 }, compoundVariants: [] }), A = "jrytnlb", H = p({ defaultClassName: "jrytnl7", variantClassNames: { micro: { true: "jrytnl8", false: "jrytnl9" } }, defaultVariants: { micro: !1 }, compoundVariants: [] }), R = "jrytnl6", B = "jrytnla", O = p({ defaultClassName: "jrytnl0", variantClassNames: { micro: { true: "jrytnl1", false: "jrytnl2" } }, defaultVariants: {}, compoundVariants: [] });
56
+ }, E = "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlc", Z = c({ defaultClassName: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl3", variantClassNames: { micro: { true: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl4", false: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl5" } }, defaultVariants: { micro: !1 }, compoundVariants: [] }), N = "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlb", z = c({ defaultClassName: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl7", variantClassNames: { micro: { true: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl8", false: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl9" } }, defaultVariants: { micro: !1 }, compoundVariants: [] }), A = "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl6", H = "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnla", R = c({ defaultClassName: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl0", variantClassNames: { micro: { true: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl1", false: "pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl2" } }, defaultVariants: {}, compoundVariants: [] });
57
57
  function h({
58
58
  artwork: e,
59
59
  heading: a,
60
60
  illustration: o,
61
61
  subHeading: t,
62
- micro: n = !1,
62
+ micro: s = !1,
63
63
  children: i,
64
64
  className: d,
65
65
  icon: l,
66
- ...m
66
+ ...p
67
67
  }) {
68
- const c = o || e || I.Large.BUILDING;
69
- return /* @__PURE__ */ r.createElement("div", { className: O({ micro: n }) }, /* @__PURE__ */ r.createElement("div", { className: v(N({ micro: n }), d), ...m }, n ? /* @__PURE__ */ r.createElement(r.Fragment, null, l ? /* @__PURE__ */ r.createElement(w, { className: Z, icon: l, "aria-hidden": "true" }) : /* @__PURE__ */ r.createElement("img", { style: { height: "3rem" }, src: c })) : /* @__PURE__ */ r.createElement("img", { className: R, src: c, alt: "" }), a && (typeof a == "string" ? /* @__PURE__ */ r.createElement("h1", { className: H({ micro: n }) }, a) : u(a)), t && (typeof t == "string" ? /* @__PURE__ */ r.createElement("h2", { className: B }, t) : u(t)), /* @__PURE__ */ r.createElement("div", { className: A }, i)));
68
+ const m = o || e || b.Large.BUILDING;
69
+ return /* @__PURE__ */ r.createElement("div", { className: R({ micro: s }) }, /* @__PURE__ */ r.createElement("div", { className: w(Z({ micro: s }), d), ...p }, s ? /* @__PURE__ */ r.createElement(r.Fragment, null, l ? /* @__PURE__ */ r.createElement(C, { className: E, icon: l, "aria-hidden": "true" }) : /* @__PURE__ */ r.createElement("img", { style: { height: "3rem" }, src: m })) : /* @__PURE__ */ r.createElement("img", { className: A, src: m, alt: "" }), a && (typeof a == "string" ? /* @__PURE__ */ r.createElement("h1", { className: z({ micro: s }) }, a) : u(a)), t && (typeof t == "string" ? /* @__PURE__ */ r.createElement("h2", { className: H }, t) : u(t)), /* @__PURE__ */ r.createElement("div", { className: N }, i)));
70
70
  }
71
- b.set(h, {
71
+ v.set(h, {
72
72
  name: "ZeroState",
73
73
  props: {
74
74
  artwork: { type: "string" },
@@ -78,13 +78,13 @@ b.set(h, {
78
78
  micro: { type: "boolean", default: "false" }
79
79
  }
80
80
  });
81
- const j = {
81
+ const B = {
82
82
  description: () => /* @__PURE__ */ r.createElement("p", null, "Zero States are placeholders in content areas when there is no content to show. You can view all available illustrations on the Illustrations page."),
83
83
  components: [h],
84
84
  examples: {
85
85
  general: {
86
86
  label: "Sizes",
87
- description: () => /* @__PURE__ */ r.createElement(r.Fragment, null, /* @__PURE__ */ r.createElement("h5", { className: f({ mb: "md" }) }, "There are 2 sizes of Zero States: Large and Small. They differ in appearance and are used in different cases."), /* @__PURE__ */ r.createElement("h4", null, "Large Zero States"), /* @__PURE__ */ r.createElement("h5", { className: f({ mb: "md" }) }, "Use Large Zero States in primary or large areas of a page."), /* @__PURE__ */ r.createElement("h4", null, "Small Zero States"), /* @__PURE__ */ r.createElement("h5", null, "Use Small Zero States in secondary or small areas of a page."))
87
+ description: () => /* @__PURE__ */ r.createElement(r.Fragment, null, /* @__PURE__ */ r.createElement("h5", { className: _({ mb: "md" }) }, "There are 2 sizes of Zero States: Large and Small. They differ in appearance and are used in different cases."), /* @__PURE__ */ r.createElement("h4", null, "Large Zero States"), /* @__PURE__ */ r.createElement("h5", { className: _({ mb: "md" }) }, "Use Large Zero States in primary or large areas of a page."), /* @__PURE__ */ r.createElement("h4", null, "Small Zero States"), /* @__PURE__ */ r.createElement("h5", null, "Use Small Zero States in secondary or small areas of a page."))
88
88
  },
89
89
  regular: {
90
90
  label: "Usage: Large Zero States",
@@ -92,7 +92,7 @@ const j = {
92
92
  examples: {
93
93
  illustrationAndHeading: {
94
94
  description: "Illustration + Heading",
95
- react: s`
95
+ react: n`
96
96
  import { ZeroState } from "@sps-woodland/zero-state";
97
97
  import { Card } from "@sps-woodland/cards";
98
98
  import { Illustrations } from "@sps-woodland/core";
@@ -111,7 +111,7 @@ const j = {
111
111
  },
112
112
  illustrationHeadingAndSubtitle: {
113
113
  description: "Illustration + Heading + Subtitle",
114
- react: s`
114
+ react: n`
115
115
  import { ZeroState } from "@sps-woodland/zero-state";
116
116
  import { Card } from "@sps-woodland/cards";
117
117
  import { Illustrations } from "@sps-woodland/core";
@@ -131,7 +131,7 @@ const j = {
131
131
  },
132
132
  illustrationHeadingAndButton: {
133
133
  description: "Illustration + Heading + Button",
134
- react: s`
134
+ react: n`
135
135
  import { ZeroState } from "@sps-woodland/zero-state";
136
136
  import { Card } from "@sps-woodland/cards";
137
137
  import { Illustrations } from "@sps-woodland/core";
@@ -156,7 +156,7 @@ const j = {
156
156
  },
157
157
  illustrationHeadingSubtitleAndButton: {
158
158
  description: "Illustration + Heading + Subtitle + Button",
159
- react: s`
159
+ react: n`
160
160
  import { ZeroState } from "@sps-woodland/zero-state";
161
161
  import { Card } from "@sps-woodland/cards";
162
162
  import { Illustrations } from "@sps-woodland/core";
@@ -182,7 +182,7 @@ const j = {
182
182
  },
183
183
  illustrationHeadingSubtitleAndSearch: {
184
184
  description: "Illustration + Heading + Subtitle + Search",
185
- react: s`
185
+ react: n`
186
186
  import { ZeroState } from "@sps-woodland/zero-state";
187
187
  import { Card } from "@sps-woodland/cards";
188
188
  import { Illustrations } from "@sps-woodland/core";
@@ -225,7 +225,7 @@ const j = {
225
225
  examples: {
226
226
  illustrationAndHeading: {
227
227
  description: "Illustration + Heading",
228
- react: s`
228
+ react: n`
229
229
  import { ZeroState } from "@sps-woodland/zero-state";
230
230
  import { Card } from "@sps-woodland/cards";
231
231
  import { Illustrations } from "@sps-woodland/core";
@@ -249,7 +249,7 @@ const j = {
249
249
  },
250
250
  illustrationAndSubtitle: {
251
251
  description: "Illustration + Subtitle",
252
- react: s`
252
+ react: n`
253
253
  import { ZeroState } from "@sps-woodland/zero-state";
254
254
  import { Card } from "@sps-woodland/cards";
255
255
  import { Illustrations } from "@sps-woodland/core";
@@ -273,7 +273,7 @@ const j = {
273
273
  },
274
274
  illustrationHeadingAndSubtitle: {
275
275
  description: "Illustration + Heading + Subtitle",
276
- react: s`
276
+ react: n`
277
277
  import { ZeroState } from "@sps-woodland/zero-state";
278
278
  import { Card } from "@sps-woodland/cards";
279
279
  import { Illustrations } from "@sps-woodland/core";
@@ -299,10 +299,10 @@ const j = {
299
299
  }
300
300
  }
301
301
  }
302
- }, F = {
303
- "Zero States": j
302
+ }, x = {
303
+ "Zero States": B
304
304
  };
305
305
  export {
306
- F as MANIFEST,
306
+ x as MANIFEST,
307
307
  h as ZeroState
308
308
  };
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const C=require("react"),d=require("@sps-woodland/core"),v=require("@sps-woodland/illustrations"),s=require("@spscommerce/utils"),S=require("@sps-woodland/tokens");function w(e){if(e&&e.__esModule)return e;const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const o=w(C);function y(e,a,t){return a in e?Object.defineProperty(e,a,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[a]=t,e}function g(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);a&&(r=r.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),t.push.apply(t,r)}return t}function b(e){for(var a=1;a<arguments.length;a++){var t=arguments[a]!=null?arguments[a]:{};a%2?g(Object(t),!0).forEach(function(r){y(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):g(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}var I=(e,a,t)=>{for(var r of Object.keys(e)){var n;if(e[r]!==((n=a[r])!==null&&n!==void 0?n:t[r]))return!1}return!0},p=e=>a=>{var t=e.defaultClassName,r=b(b({},e.defaultVariants),a);for(var n in r){var i,c=(i=r[n])!==null&&i!==void 0?i:e.defaultVariants[n];if(c!=null){var l=c;typeof l=="boolean"&&(l=l===!0?"true":"false");var u=e.variantClassNames[n][l];u&&(t+=" "+u)}}for(var[m,h]of e.compoundVariants)I(m,r,e.defaultVariants)&&(t+=" "+h);return t},E="jrytnlc",N=p({defaultClassName:"jrytnl3",variantClassNames:{micro:{true:"jrytnl4",false:"jrytnl5"}},defaultVariants:{micro:!1},compoundVariants:[]}),Z="jrytnlb",O=p({defaultClassName:"jrytnl7",variantClassNames:{micro:{true:"jrytnl8",false:"jrytnl9"}},defaultVariants:{micro:!1},compoundVariants:[]}),A="jrytnl6",H="jrytnla",j=p({defaultClassName:"jrytnl0",variantClassNames:{micro:{true:"jrytnl1",false:"jrytnl2"}},defaultVariants:{},compoundVariants:[]});function f({artwork:e,heading:a,illustration:t,subHeading:r,micro:n=!1,children:i,className:c,icon:l,...u}){const m=t||e||v.Illustrations.Large.BUILDING;return o.createElement("div",{className:j({micro:n})},o.createElement("div",{className:d.cl(N({micro:n}),c),...u},n?o.createElement(o.Fragment,null,l?o.createElement(d.Icon,{className:E,icon:l,"aria-hidden":"true"}):o.createElement("img",{style:{height:"3rem"},src:m})):o.createElement("img",{className:A,src:m,alt:""}),a&&(typeof a=="string"?o.createElement("h1",{className:O({micro:n})},a):d.contentOf(a)),r&&(typeof r=="string"?o.createElement("h2",{className:H},r):d.contentOf(r)),o.createElement("div",{className:Z},i)))}d.Metadata.set(f,{name:"ZeroState",props:{artwork:{type:"string"},heading:{type:"string | ReactNodeOrRenderFn"},illustration:{type:"string"},subHeading:{type:"string | ReactNodeOrRenderFn"},micro:{type:"boolean",default:"false"}}});const R={description:()=>o.createElement("p",null,"Zero States are placeholders in content areas when there is no content to show. You can view all available illustrations on the Illustrations page."),components:[f],examples:{general:{label:"Sizes",description:()=>o.createElement(o.Fragment,null,o.createElement("h5",{className:S.sprinkles({mb:"md"})},"There are 2 sizes of Zero States: Large and Small. They differ in appearance and are used in different cases."),o.createElement("h4",null,"Large Zero States"),o.createElement("h5",{className:S.sprinkles({mb:"md"})},"Use Large Zero States in primary or large areas of a page."),o.createElement("h4",null,"Small Zero States"),o.createElement("h5",null,"Use Small Zero States in secondary or small areas of a page."))},regular:{label:"Usage: Large Zero States",description:({NavigateTo:e})=>o.createElement("p",null,"Large Zero States may be accompanied by other components such as Headings, Subtitles,"," ",o.createElement(e,{to:"Button"},"Buttons"),","," ",o.createElement(e,{to:"List Toolbar"},"Search Bars"),", or a combination of these"),examples:{illustrationAndHeading:{description:"Illustration + Heading",react:s.code`
1
+ (function(n,d){typeof exports=="object"&&typeof module<"u"?d(exports,require("react"),require("@sps-woodland/core"),require("@sps-woodland/illustrations"),require("@spscommerce/utils"),require("@sps-woodland/tokens")):typeof define=="function"&&define.amd?define(["exports","react","@sps-woodland/core","@sps-woodland/illustrations","@spscommerce/utils","@sps-woodland/tokens"],d):(n=typeof globalThis<"u"?globalThis:n||self,d(n.ZeroState={},n.React,n.core,n.illustrations,n.utils,n.tokens))})(this,function(n,d,c,v,l,h){"use strict";function b(e){if(e&&e.__esModule)return e;const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(a,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return a.default=e,Object.freeze(a)}const o=b(d),R="";function C(e,a,t){return a in e?Object.defineProperty(e,a,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[a]=t,e}function g(e,a){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);a&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),t.push.apply(t,r)}return t}function w(e){for(var a=1;a<arguments.length;a++){var t=arguments[a]!=null?arguments[a]:{};a%2?g(Object(t),!0).forEach(function(r){C(e,r,t[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):g(Object(t)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))})}return e}var y=(e,a,t)=>{for(var r of Object.keys(e)){var s;if(e[r]!==((s=a[r])!==null&&s!==void 0?s:t[r]))return!1}return!0},f=e=>a=>{var t=e.defaultClassName,r=w(w({},e.defaultVariants),a);for(var s in r){var p,u=(p=r[s])!==null&&p!==void 0?p:e.defaultVariants[s];if(u!=null){var i=u;typeof i=="boolean"&&(i=i===!0?"true":"false");var m=e.variantClassNames[s][i];m&&(t+=" "+m)}}for(var[_,H]of e.compoundVariants)y(_,r,e.defaultVariants)&&(t+=" "+H);return t},I="pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlc",E=f({defaultClassName:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl3",variantClassNames:{micro:{true:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl4",false:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl5"}},defaultVariants:{micro:!1},compoundVariants:[]}),Z="pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlb",N=f({defaultClassName:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl7",variantClassNames:{micro:{true:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl8",false:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl9"}},defaultVariants:{micro:!1},compoundVariants:[]}),O="pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl6",z="pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnla",A=f({defaultClassName:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl0",variantClassNames:{micro:{true:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl1",false:"pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl2"}},defaultVariants:{},compoundVariants:[]});function S({artwork:e,heading:a,illustration:t,subHeading:r,micro:s=!1,children:p,className:u,icon:i,...m}){const _=t||e||v.Illustrations.Large.BUILDING;return o.createElement("div",{className:A({micro:s})},o.createElement("div",{className:c.cl(E({micro:s}),u),...m},s?o.createElement(o.Fragment,null,i?o.createElement(c.Icon,{className:I,icon:i,"aria-hidden":"true"}):o.createElement("img",{style:{height:"3rem"},src:_})):o.createElement("img",{className:O,src:_,alt:""}),a&&(typeof a=="string"?o.createElement("h1",{className:N({micro:s})},a):c.contentOf(a)),r&&(typeof r=="string"?o.createElement("h2",{className:z},r):c.contentOf(r)),o.createElement("div",{className:Z},p)))}c.Metadata.set(S,{name:"ZeroState",props:{artwork:{type:"string"},heading:{type:"string | ReactNodeOrRenderFn"},illustration:{type:"string"},subHeading:{type:"string | ReactNodeOrRenderFn"},micro:{type:"boolean",default:"false"}}});const j={"Zero States":{description:()=>o.createElement("p",null,"Zero States are placeholders in content areas when there is no content to show. You can view all available illustrations on the Illustrations page."),components:[S],examples:{general:{label:"Sizes",description:()=>o.createElement(o.Fragment,null,o.createElement("h5",{className:h.sprinkles({mb:"md"})},"There are 2 sizes of Zero States: Large and Small. They differ in appearance and are used in different cases."),o.createElement("h4",null,"Large Zero States"),o.createElement("h5",{className:h.sprinkles({mb:"md"})},"Use Large Zero States in primary or large areas of a page."),o.createElement("h4",null,"Small Zero States"),o.createElement("h5",null,"Use Small Zero States in secondary or small areas of a page."))},regular:{label:"Usage: Large Zero States",description:({NavigateTo:e})=>o.createElement("p",null,"Large Zero States may be accompanied by other components such as Headings, Subtitles,"," ",o.createElement(e,{to:"Button"},"Buttons"),","," ",o.createElement(e,{to:"List Toolbar"},"Search Bars"),", or a combination of these"),examples:{illustrationAndHeading:{description:"Illustration + Heading",react:l.code`
2
2
  import { ZeroState } from "@sps-woodland/zero-state";
3
3
  import { Card } from "@sps-woodland/cards";
4
4
  import { Illustrations } from "@sps-woodland/core";
@@ -13,7 +13,7 @@
13
13
  </Card>
14
14
  );
15
15
  }
16
- `},illustrationHeadingAndSubtitle:{description:"Illustration + Heading + Subtitle",react:s.code`
16
+ `},illustrationHeadingAndSubtitle:{description:"Illustration + Heading + Subtitle",react:l.code`
17
17
  import { ZeroState } from "@sps-woodland/zero-state";
18
18
  import { Card } from "@sps-woodland/cards";
19
19
  import { Illustrations } from "@sps-woodland/core";
@@ -29,7 +29,7 @@
29
29
  </Card>
30
30
  );
31
31
  }
32
- `},illustrationHeadingAndButton:{description:"Illustration + Heading + Button",react:s.code`
32
+ `},illustrationHeadingAndButton:{description:"Illustration + Heading + Button",react:l.code`
33
33
  import { ZeroState } from "@sps-woodland/zero-state";
34
34
  import { Card } from "@sps-woodland/cards";
35
35
  import { Illustrations } from "@sps-woodland/core";
@@ -50,7 +50,7 @@
50
50
  </Card>
51
51
  );
52
52
  }
53
- `},illustrationHeadingSubtitleAndButton:{description:"Illustration + Heading + Subtitle + Button",react:s.code`
53
+ `},illustrationHeadingSubtitleAndButton:{description:"Illustration + Heading + Subtitle + Button",react:l.code`
54
54
  import { ZeroState } from "@sps-woodland/zero-state";
55
55
  import { Card } from "@sps-woodland/cards";
56
56
  import { Illustrations } from "@sps-woodland/core";
@@ -72,7 +72,7 @@
72
72
  </Card>
73
73
  );
74
74
  }
75
- `},illustrationHeadingSubtitleAndSearch:{description:"Illustration + Heading + Subtitle + Search",react:s.code`
75
+ `},illustrationHeadingSubtitleAndSearch:{description:"Illustration + Heading + Subtitle + Search",react:l.code`
76
76
  import { ZeroState } from "@sps-woodland/zero-state";
77
77
  import { Card } from "@sps-woodland/cards";
78
78
  import { Illustrations } from "@sps-woodland/core";
@@ -105,7 +105,7 @@
105
105
  </Card>
106
106
  );
107
107
  }
108
- `}}},micro:{label:"Usage: Small Zero State",description:"Small Zero States may be accompanied by Headings, Subtitles, or both.",examples:{illustrationAndHeading:{description:"Illustration + Heading",react:s.code`
108
+ `}}},micro:{label:"Usage: Small Zero State",description:"Small Zero States may be accompanied by Headings, Subtitles, or both.",examples:{illustrationAndHeading:{description:"Illustration + Heading",react:l.code`
109
109
  import { ZeroState } from "@sps-woodland/zero-state";
110
110
  import { Card } from "@sps-woodland/cards";
111
111
  import { Illustrations } from "@sps-woodland/core";
@@ -125,7 +125,7 @@
125
125
  </div>
126
126
  );
127
127
  }
128
- `},illustrationAndSubtitle:{description:"Illustration + Subtitle",react:s.code`
128
+ `},illustrationAndSubtitle:{description:"Illustration + Subtitle",react:l.code`
129
129
  import { ZeroState } from "@sps-woodland/zero-state";
130
130
  import { Card } from "@sps-woodland/cards";
131
131
  import { Illustrations } from "@sps-woodland/core";
@@ -145,7 +145,7 @@
145
145
  </div>
146
146
  );
147
147
  }
148
- `},illustrationHeadingAndSubtitle:{description:"Illustration + Heading + Subtitle",react:s.code`
148
+ `},illustrationHeadingAndSubtitle:{description:"Illustration + Heading + Subtitle",react:l.code`
149
149
  import { ZeroState } from "@sps-woodland/zero-state";
150
150
  import { Card } from "@sps-woodland/cards";
151
151
  import { Illustrations } from "@sps-woodland/core";
@@ -166,4 +166,4 @@
166
166
  </div>
167
167
  );
168
168
  }
169
- `}}}}},B={"Zero States":R};exports.MANIFEST=B;exports.ZeroState=f;
169
+ `}}}}}};n.MANIFEST=j,n.ZeroState=S,Object.defineProperties(n,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
package/lib/style.css CHANGED
@@ -1 +1 @@
1
- .jrytnl2{padding:1rem}.jrytnl3{margin:auto;padding-top:2rem;padding-right:0;padding-bottom:2rem;padding-left:0;text-align:center}.jrytnl4{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;width:auto}.jrytnl6{height:6.25rem;margin-bottom:1rem;width:12.5rem}.jrytnl7{margin-bottom:0}.jrytnl8{color:#4b5356;font-size:1rem;font-weight:600;line-height:1.25rem}.jrytnl9{color:#1f282c;font-size:1.5rem;line-height:1.5rem}.jrytnla{color:#4b5356;font-size:.875rem;line-height:1.25rem;margin-top:.25rem;margin-bottom:0}.jrytnlb{margin-top:1rem}.jrytnlc{color:#717779;font-size:3rem;line-height:3rem;padding-bottom:.25rem}@media screen and (min-width: 768px){.jrytnl3{width:75%}}@media screen and (min-width: 992px){.jrytnl3{width:50%}}
1
+ .pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl2{padding:1rem}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl3{margin:auto;padding-top:2rem;padding-right:0;padding-bottom:2rem;padding-left:0;text-align:center}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl4{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;width:auto}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl6{height:6.25rem;margin-bottom:1rem;width:12.5rem}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl7{margin-bottom:0}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl8{color:#4b5356;font-size:1rem;font-weight:600;line-height:1.25rem}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl9{color:#1f282c;font-size:1.5rem;line-height:1.5rem}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnla{color:#4b5356;font-size:.875rem;line-height:1.25rem;margin-top:.25rem;margin-bottom:0}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlb{margin-top:1rem}.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnlc{color:#717779;font-size:3rem;line-height:3rem;padding-bottom:.25rem}@media screen and (min-width: 768px){.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl3{width:75%}}@media screen and (min-width: 992px){.pkg_sps-woodland_zero-state__version_7_19_0__hash_jrytnl3{width:50%}}
package/package.json CHANGED
@@ -1,20 +1,20 @@
1
1
  {
2
2
  "name": "@sps-woodland/zero-state",
3
3
  "description": "SPS Woodland Design System zero state component",
4
- "version": "7.17.12",
4
+ "version": "7.19.0",
5
5
  "author": "SPS Commerce",
6
6
  "license": "UNLICENSED",
7
7
  "repository": "https://github.com/SPSCommerce/woodland/tree/main/packages/@sps-woodland/zero-state",
8
8
  "homepage": "https://github.com/SPSCommerce/woodland/tree/master/packages/@sps-woodland/zero-state#readme",
9
- "module": "./lib/index.es.js",
10
9
  "type": "module",
11
- "main": "./lib/index.cjs.js",
10
+ "module": "./lib/index.js",
11
+ "main": "./lib/index.umd.cjs",
12
12
  "types": "./lib/index.d.ts",
13
13
  "exports": {
14
14
  ".": {
15
- "import": "./lib/index.es.js",
16
- "require": "./lib/index.cjs.js",
17
- "default": "./lib/index.cjs.js",
15
+ "require": "./lib/index.umd.cjs",
16
+ "import": "./lib/index.js",
17
+ "default": "./lib/index.js",
18
18
  "types": "./lib/index.d.ts"
19
19
  },
20
20
  "./lib/style.css": {
@@ -26,22 +26,22 @@
26
26
  "access": "public"
27
27
  },
28
28
  "peerDependencies": {
29
- "@sps-woodland/core": "7.17.12",
30
- "@sps-woodland/illustrations": "7.17.12",
31
- "@sps-woodland/tokens": "7.17.12",
32
29
  "@spscommerce/utils": "^6.12.1",
33
30
  "react": "^16.14.0",
34
- "react-dom": "^16.14.0"
31
+ "react-dom": "^16.14.0",
32
+ "@sps-woodland/core": "7.19.0",
33
+ "@sps-woodland/illustrations": "7.19.0",
34
+ "@sps-woodland/tokens": "7.19.0"
35
35
  },
36
36
  "devDependencies": {
37
- "@sps-woodland/core": "7.17.12",
38
- "@sps-woodland/illustrations": "7.17.12",
39
- "@sps-woodland/tokens": "7.17.12",
40
37
  "@spscommerce/utils": "^6.12.1",
41
38
  "@vanilla-extract/css": "^1.9.3",
42
39
  "@vanilla-extract/recipes": "^0.2.5",
43
40
  "react": "^16.14.0",
44
- "react-dom": "^16.14.0"
41
+ "react-dom": "^16.14.0",
42
+ "@sps-woodland/core": "7.19.0",
43
+ "@sps-woodland/tokens": "7.19.0",
44
+ "@sps-woodland/illustrations": "7.19.0"
45
45
  },
46
46
  "scripts": {
47
47
  "build": "pnpm run build:js && pnpm run build:types",
package/vite.config.js CHANGED
@@ -1,16 +1,25 @@
1
1
  import path from "path";
2
2
  import { vanillaExtractPlugin } from "@vanilla-extract/vite-plugin";
3
3
  import { defineConfig } from "vite";
4
-
4
+ import { getVanillaExtractPluginProps } from "../../../scripts/vanilla-extract-plugin-props.js";
5
5
  import pkg from "./package.json";
6
6
 
7
+ const packageVersion = process.env.PREDICTED_VERSION || pkg.version;
8
+
7
9
  export default defineConfig({
8
- plugins: [vanillaExtractPlugin()],
10
+ plugins: [
11
+ vanillaExtractPlugin(
12
+ getVanillaExtractPluginProps({
13
+ packageName: pkg.name,
14
+ packageVersion,
15
+ })
16
+ ),
17
+ ],
9
18
  build: {
10
19
  lib: {
11
20
  entry: path.resolve(__dirname, "src/index.ts"),
12
- formats: ["es", "cjs"],
13
- fileName: (format) => `index.${format}.js`,
21
+ name: "ZeroState",
22
+ fileName: "index",
14
23
  },
15
24
  outDir: path.resolve(__dirname, "./lib"),
16
25
  emptyOutDir: false,
Binary file