@purpurds/card 5.11.0 → 5.11.2
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/LICENSE.txt +5 -5
- package/dist/card-badge.d.ts +1 -0
- package/dist/card-badge.d.ts.map +1 -1
- package/dist/card-content-container.d.ts +2 -2
- package/dist/card-content-container.d.ts.map +1 -1
- package/dist/card-content.d.ts +2 -2
- package/dist/card-content.d.ts.map +1 -1
- package/dist/card.cjs.js +7 -7
- package/dist/card.cjs.js.map +1 -1
- package/dist/card.es.js +78 -76
- package/dist/card.es.js.map +1 -1
- package/package.json +20 -20
- package/src/card-badge.tsx +1 -0
- package/src/card-content-container.tsx +2 -2
- package/src/card-content.tsx +2 -2
- package/src/card.stories.tsx +26 -3
- package/readme.mdx +0 -78
package/dist/LICENSE.txt
CHANGED
|
@@ -33,34 +33,34 @@ SOFTWARE.
|
|
|
33
33
|
---
|
|
34
34
|
|
|
35
35
|
Name: @purpurds/badge
|
|
36
|
-
Version: 5.
|
|
36
|
+
Version: 5.11.1
|
|
37
37
|
License: AGPL-3.0-only
|
|
38
38
|
Private: false
|
|
39
39
|
|
|
40
40
|
---
|
|
41
41
|
|
|
42
42
|
Name: @purpurds/icon
|
|
43
|
-
Version: 5.
|
|
43
|
+
Version: 5.11.1
|
|
44
44
|
License: AGPL-3.0-only
|
|
45
45
|
Private: false
|
|
46
46
|
|
|
47
47
|
---
|
|
48
48
|
|
|
49
49
|
Name: @purpurds/paragraph
|
|
50
|
-
Version: 5.
|
|
50
|
+
Version: 5.11.1
|
|
51
51
|
License: AGPL-3.0-only
|
|
52
52
|
Private: false
|
|
53
53
|
|
|
54
54
|
---
|
|
55
55
|
|
|
56
56
|
Name: @purpurds/spinner
|
|
57
|
-
Version: 5.
|
|
57
|
+
Version: 5.11.1
|
|
58
58
|
License: AGPL-3.0-only
|
|
59
59
|
Private: false
|
|
60
60
|
|
|
61
61
|
---
|
|
62
62
|
|
|
63
63
|
Name: @purpurds/visually-hidden
|
|
64
|
-
Version: 5.
|
|
64
|
+
Version: 5.11.1
|
|
65
65
|
License: AGPL-3.0-only
|
|
66
66
|
Private: false
|
package/dist/card-badge.d.ts
CHANGED
|
@@ -8,6 +8,7 @@ export type CardBadgeProps = {
|
|
|
8
8
|
["data-testid"]?: string;
|
|
9
9
|
/**
|
|
10
10
|
* The variant (color) of the badge in the top right corner of the card. This is coupled with the text prop. Both needs to be set for the badge to be displayed.
|
|
11
|
+
* `BadgeVariant = "attention" | "special" | "neutral" | "information" | "success" | "warning" | "error"`
|
|
11
12
|
*/
|
|
12
13
|
variant?: BadgeVariant;
|
|
13
14
|
/**
|
package/dist/card-badge.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card-badge.d.ts","sourceRoot":"","sources":["../src/card-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAS,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAOtD,MAAM,MAAM,cAAc,GAAG;IAC3B;;OAEG;IACH,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC;IACzB
|
|
1
|
+
{"version":3,"file":"card-badge.d.ts","sourceRoot":"","sources":["../src/card-badge.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAS,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAOtD,MAAM,MAAM,cAAc,GAAG;IAC3B;;OAEG;IACH,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC;IACzB;;;OAGG;IACH,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAIF,eAAO,MAAM,SAAS,oDAInB,cAAc,6BAWhB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { default as React } from 'react';
|
|
1
|
+
import { default as React, ReactNode } from 'react';
|
|
2
2
|
|
|
3
3
|
type CardContentContainerProps = {
|
|
4
4
|
/**
|
|
@@ -8,7 +8,7 @@ type CardContentContainerProps = {
|
|
|
8
8
|
/**
|
|
9
9
|
* The child elements of the content container (React.ReactNode)
|
|
10
10
|
*/
|
|
11
|
-
children:
|
|
11
|
+
children: ReactNode;
|
|
12
12
|
/**
|
|
13
13
|
* Flag to remove the top padding
|
|
14
14
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card-content-container.d.ts","sourceRoot":"","sources":["../src/card-content-container.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"card-content-container.d.ts","sourceRoot":"","sources":["../src/card-content-container.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AASzC,KAAK,yBAAyB,GAAG;IAC/B;;OAEG;IACH,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC;IACzB;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;IACpB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,eAAO,MAAM,oBAAoB,yDAI9B,yBAAyB,sBAc3B,CAAC"}
|
package/dist/card-content.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { default as React } from 'react';
|
|
1
|
+
import { default as React, ReactNode } from 'react';
|
|
2
2
|
|
|
3
3
|
type CardContentProps = {
|
|
4
4
|
/**
|
|
@@ -8,7 +8,7 @@ type CardContentProps = {
|
|
|
8
8
|
/**
|
|
9
9
|
* The child elements of the content (React.ReactNode)
|
|
10
10
|
*/
|
|
11
|
-
children:
|
|
11
|
+
children: ReactNode;
|
|
12
12
|
};
|
|
13
13
|
export declare const CardContent: ({ ["data-testid"]: dataTestId, children, }: CardContentProps) => React.JSX.Element;
|
|
14
14
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"card-content.d.ts","sourceRoot":"","sources":["../src/card-content.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"card-content.d.ts","sourceRoot":"","sources":["../src/card-content.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AASzC,KAAK,gBAAgB,GAAG;IACtB;;OAEG;IACH,CAAC,aAAa,CAAC,CAAC,EAAE,MAAM,CAAC;IACzB;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,WAAW,+CAGrB,gBAAgB,sBAMlB,CAAC"}
|
package/dist/card.cjs.js
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),o=require("react");require("react-dom");function K(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),o=require("react");require("react-dom");function K(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var P={exports:{}};/*!
|
|
2
2
|
Copyright (c) 2018 Jed Watson.
|
|
3
3
|
Licensed under the MIT License (MIT), see
|
|
4
4
|
http://jedwatson.github.io/classnames
|
|
5
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(
|
|
5
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(P);var J=P.exports;const c=K(J),Q={"purpur-card":"_purpur-card_5j8zb_1"};function Y(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var q={exports:{}};/*!
|
|
6
6
|
Copyright (c) 2018 Jed Watson.
|
|
7
7
|
Licensed under the MIT License (MIT), see
|
|
8
8
|
http://jedwatson.github.io/classnames
|
|
9
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(
|
|
9
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(q);var rr=q.exports;const er=Y(rr),tr={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},ar={name:"alert",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="m13.038 7.067-.247 6.876h-1.566l-.247-6.876a1.03 1.03 0 1 1 2.06 0Zm.212 8.917c0 .649-.586 1.234-1.25 1.234-.649 0-1.25-.585-1.25-1.234 0-.633.601-1.234 1.25-1.234.664 0 1.25.601 1.25 1.234Z"/><path fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-1.75 0a8.25 8.25 0 1 1-16.5 0 8.25 8.25 0 0 1 16.5 0Z" clip-rule="evenodd"/></svg>',keywords:["alert"],category:"status"},nr={name:"check-circle",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M16.487 9.514a.872.872 0 1 0-1.42-1.014l-4.248 5.948-2.18-2.18a.872.872 0 0 0-1.233 1.234l2.908 2.908a.872.872 0 0 0 1.326-.11l4.847-6.786Z"/><path fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-1.75 0a8.25 8.25 0 1 1-16.5 0 8.25 8.25 0 0 1 16.5 0Z" clip-rule="evenodd"/></svg>',keywords:["check-circle"],category:"status"},ur={name:"error",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M10.354 3.05c.732-1.267 2.56-1.267 3.291 0l8.66 15c.732 1.267-.182 2.85-1.645 2.85H3.34c-1.463 0-2.377-1.583-1.646-2.85l8.66-15Zm1.595.862a.092.092 0 0 0-.036.038l-8.66 15a.092.092 0 0 0-.015.05c0 .014.005.032.015.05a.11.11 0 0 0 .036.038.09.09 0 0 0 .05.012H20.66a.088.088 0 0 0 .05-.012.106.106 0 0 0 .037-.038.105.105 0 0 0 .015-.05.092.092 0 0 0-.015-.05l-8.66-15a.092.092 0 0 0-.036-.038A.106.106 0 0 0 12 3.9a.105.105 0 0 0-.05.012Z" clip-rule="evenodd"/><path d="m12.523 14.922.412-6.25a.936.936 0 1 0-1.868 0l.421 6.25h1.035ZM12 17.52c.44 0 .826-.387.826-.815 0-.418-.387-.816-.826-.816-.428 0-.825.398-.825.816 0 .428.397.815.825.815Z"/><path fill-rule="evenodd" d="M12.691 15.096h-1.37l-.431-6.53a1 1 0 0 1 .997-1.066h.227a1 1 0 0 1 .998 1.064l-.42 6.532Zm.244-6.425a.936.936 0 1 0-1.868.002l.421 6.249h1.035l.412-6.25ZM13 16.706c0 .526-.466.99-1 .99-.522 0-1-.463-1-.99 0-.264.125-.51.304-.689.18-.178.429-.301.696-.301.536 0 1 .475 1 .99Zm-.174 0c0 .428-.387.815-.826.815-.428 0-.825-.387-.825-.815 0-.418.397-.816.825-.816.44 0 .826.398.826.816Z" clip-rule="evenodd"/></svg>',keywords:["error"],category:"status"},pr={name:"info",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M11 8.18c0 .537.469.979 1.007.979.524 0 .993-.442.993-.98s-.469-.979-.993-.979c-.538 0-1.007.441-1.007.98Zm.152 1.958v6.897h1.696v-6.897h-1.696Z"/><path fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-1.75 0a8.25 8.25 0 1 1-16.5 0 8.25 8.25 0 0 1 16.5 0Z" clip-rule="evenodd"/></svg>',keywords:["info"],category:"status"},ir={name:"offering",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M7.118 4.6H7a1.9 1.9 0 0 0-1.9 1.9V8a1.9 1.9 0 0 0 1.5 1.858v.642a.9.9 0 1 0 1.8 0v-.6h3.2v.6a.9.9 0 0 0 1.8 0v-.6h3.7V11a.9.9 0 0 0 1.8 0V9.858A1.9 1.9 0 0 0 20.4 8V6.5a1.9 1.9 0 0 0-1.9-1.9h-.618c-.063-.708-.3-1.394-.756-1.943-.56-.674-1.384-1.057-2.376-1.057-.92 0-1.696.33-2.25.915-.554-.585-1.33-.915-2.25-.915-.992 0-1.816.383-2.376 1.057-.457.549-.693 1.235-.756 1.943Zm1.812 0h2.64c-.053-.34-.174-.607-.328-.792-.192-.232-.493-.408-.992-.408s-.8.176-.992.408c-.154.185-.275.452-.328.792Zm4.5 0h2.64c-.053-.34-.174-.607-.328-.792-.192-.232-.493-.408-.992-.408s-.8.176-.992.408c-.154.185-.275.452-.328.792Zm-.03 3.5h5.1a.1.1 0 0 0 .1-.1V6.5a.1.1 0 0 0-.1-.1h-5.1v1.7Zm-1.8-1.7H7a.1.1 0 0 0-.1.1V8a.1.1 0 0 0 .1.1h4.6V6.4Zm8.335 5.147c.743-.107 1.52.135 2.201.817.474.473.695 1.011.708 1.548.012.508-.163.927-.318 1.2-.185.326-.47.607-.634.77l-.049.047-4.414 4.414a1.9 1.9 0 0 1-1.343.557H7.914a.1.1 0 0 0-.07.03l-.5.5a1.9 1.9 0 0 1-2.687 0L2.57 19.342a1.9 1.9 0 0 1 0-2.686l4-4a1.9 1.9 0 0 1 1.343-.557H14.5v.9-.9h.041l.065.004a2.73 2.73 0 0 1 .79.185 2.665 2.665 0 0 1 1.46 1.417c.188-.162.375-.324.551-.479.46-.401.815-.722.957-.863.338-.34.882-.719 1.571-.817ZM15.088 15.1a1.06 1.06 0 0 0 .08-.145c.1-.207.113-.38.027-.553a.867.867 0 0 0-.668-.497.628.628 0 0 0-.042-.005h-6.57a.1.1 0 0 0-.071.03l-4 4a.1.1 0 0 0 0 .14l2.085 2.087a.1.1 0 0 0 .142 0l.5-.5a1.9 1.9 0 0 1 1.343-.557h8.172a.1.1 0 0 0 .07-.03l4.415-4.414c.225-.225.334-.335.39-.434a.539.539 0 0 0 .083-.266.283.283 0 0 0-.026-.11.712.712 0 0 0-.154-.21c-.319-.318-.542-.326-.674-.307-.186.026-.392.146-.554.307-.191.192-.595.553-1.043.946-.904.79-2.143 1.838-2.561 2.144l-.238.174H10.5a.9.9 0 0 1 0-1.8h4.588Z" clip-rule="evenodd"/></svg>',keywords:["offering"],category:"other"},sr={name:"question",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path d="M13.672 12.056c-.635.547-1.242 1.07-1.164 2.062h-1.385c-.309-1.553.504-2.214 1.23-2.805.514-.419.986-.802.986-1.442 0-.593-.489-1.068-1.267-1.068-.764 0-1.345.422-1.872 1.187L9 9.067C9.712 7.92 10.807 7.3 12.086 7.3 13.906 7.3 15 8.42 15 9.78c0 1.133-.678 1.717-1.328 2.277Zm-.822 3.763c0 .54-.487 1.028-1.041 1.028-.554 0-1.042-.488-1.042-1.028 0-.528.488-1.029 1.042-1.029s1.042.501 1.042 1.029Z"/><path fill-rule="evenodd" d="M22 12c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10Zm-1.75 0a8.25 8.25 0 1 1-16.5 0 8.25 8.25 0 0 1 16.5 0Z" clip-rule="evenodd"/></svg>',keywords:["question"],category:"status"},or=er.bind(tr),N="purpur-icon",lr="md",cr=e=>e.filter(n=>Object.keys(n).length>=1).map(n=>`${n.name}="${n.value}"`).join(" "),dr=({content:e="",title:n}={})=>{const t=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},n?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],p=n?`<title>${n}</title>`:"";return`<svg ${cr(t)}>${p}${e}</svg>`},_r=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),gr=({["data-testid"]:e,svg:n,allyTitle:t,className:p,size:i=lr,...r})=>{const a=dr({content:_r(n.svg),title:t}),u=or(p,N,`${N}--${i}`);return s.jsx("span",{"aria-label":t,className:u,"data-testid":e,dangerouslySetInnerHTML:{__html:a},...r})};function hr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var I={exports:{}};/*!
|
|
10
10
|
Copyright (c) 2018 Jed Watson.
|
|
11
11
|
Licensed under the MIT License (MIT), see
|
|
12
12
|
http://jedwatson.github.io/classnames
|
|
13
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(
|
|
13
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(I);var mr=I.exports;const fr=hr(mr),C={"purpur-badge":"_purpur-badge_stlab_1","purpur-badge--attention":"_purpur-badge--attention_stlab_13","purpur-badge--special":"_purpur-badge--special_stlab_17","purpur-badge--neutral":"_purpur-badge--neutral_stlab_21","purpur-badge--information":"_purpur-badge--information_stlab_25","purpur-badge--success":"_purpur-badge--success_stlab_29","purpur-badge--warning":"_purpur-badge--warning_stlab_33","purpur-badge--error":"_purpur-badge--error_stlab_37"},S="purpur-badge",_={ATTENTION:"attention",SPECIAL:"special",NEUTRAL:"neutral",INFORMATION:"information",SUCCESS:"success",WARNING:"warning",ERROR:"error"},vr=e=>{switch(e){case _.ATTENTION:case _.SPECIAL:return ir;case _.INFORMATION:return pr;case _.SUCCESS:return nr;case _.WARNING:return ar;case _.ERROR:return ur;case _.NEUTRAL:return sr;default:return}},wr=({children:e,showIcon:n=!0,variant:t,["data-testid"]:p,allyLabel:i,className:r="",...a})=>{const u=vr(t),l=fr([r,C[S],C[`${S}--${t}`]]);return s.jsxs("span",{"aria-label":i,className:l,"data-testid":p,...a,children:[n&&u&&s.jsx(gr,{"data-testid":`${p}-icon`,allyTitle:i,size:"xs",svg:u}),e]})},yr={"purpur-card-badge":"_purpur-card-badge_r7moe_1"},xr=c.bind(yr),br="purpur-card-badge",$r=({["data-testid"]:e="purpur-card-badge",variant:n,text:t})=>n&&t?s.jsx(wr,{className:xr(br),variant:n,showIcon:!1,"data-testid":e,children:t}):null,jr={"purpur-card-content":"_purpur-card-content_2uc00_1"},Nr=c.bind(jr),Cr="purpur-card-content",Sr=({["data-testid"]:e="purpur-card-content",children:n})=>s.jsx("div",{className:Nr(Cr),"data-testid":e,children:n}),kr={"purpur-card-content-container":"_purpur-card-content-container_dx1e4_1","purpur-card-content-container--footer":"_purpur-card-content-container--footer_dx1e4_7"},Ar=c.bind(kr),k="purpur-card-content-container",Or=({["data-testid"]:e="purpur-card-content-container",children:n,isFooter:t=!1})=>s.jsx("div",{className:Ar([k,{[`${k}--footer`]:t}]),"data-testid":e,children:n});function Er(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var L={exports:{}};/*!
|
|
14
14
|
Copyright (c) 2018 Jed Watson.
|
|
15
15
|
Licensed under the MIT License (MIT), see
|
|
16
16
|
http://jedwatson.github.io/classnames
|
|
17
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(
|
|
17
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p.call(this,u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,this&&this[u]||u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(L);var Mr=L.exports;const Zr=Er(Mr),Rr={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},zr={name:"arrow-right",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M20.9 12a.9.9 0 0 1-.264.636l-5.5 5.5a.9.9 0 0 1-1.272-1.272l3.963-3.964H4a.9.9 0 0 1 0-1.8h13.827l-3.963-3.964a.9.9 0 1 1 1.272-1.272l5.5 5.5A.9.9 0 0 1 20.9 12Z" clip-rule="evenodd"/></svg>',keywords:["arrow-right"],category:"utility"},Pr={name:"checkmark",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M21.06 3.795a.9.9 0 0 1 .145 1.264l-11.5 14.5a.9.9 0 0 1-1.341.077l-6-6a.9.9 0 0 1 1.272-1.272l5.286 5.286L19.795 3.94a.9.9 0 0 1 1.264-.145Z" clip-rule="evenodd"/></svg>',keywords:["checkmark"],category:"utility"},B=e=>s.jsx(T,{...e,svg:zr});B.displayName="IconArrowRight";const H=e=>s.jsx(T,{...e,svg:Pr});H.displayName="IconCheckmark";const qr=Zr.bind(Rr),A="purpur-icon",Ir="md",Lr=e=>e.filter(n=>Object.keys(n).length>=1).map(n=>`${n.name}="${n.value}"`).join(" "),Br=({content:e="",title:n}={})=>{const t=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},n?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],p=n?`<title>${n}</title>`:"";return`<svg ${Lr(t)}>${p}${e}</svg>`},Hr=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),T=({["data-testid"]:e,svg:n,allyTitle:t,className:p,size:i=Ir,...r})=>{const a=Br({content:Hr(n.svg),title:t}),u=qr(p,A,`${A}--${i}`);return s.jsx("span",{"aria-label":t,className:u,"data-testid":e,dangerouslySetInnerHTML:{__html:a},...r})};function Tr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var V={exports:{}};/*!
|
|
18
18
|
Copyright (c) 2018 Jed Watson.
|
|
19
19
|
Licensed under the MIT License (MIT), see
|
|
20
20
|
http://jedwatson.github.io/classnames
|
|
21
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(
|
|
21
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(V);var Vr=V.exports;const Dr=Tr(Vr),f={"purpur-paragraph":"_purpur-paragraph_1rh57_1","purpur-paragraph--disabled":"_purpur-paragraph--disabled_1rh57_7","purpur-paragraph--hyphens":"_purpur-paragraph--hyphens_1rh57_10","purpur-paragraph--negative":"_purpur-paragraph--negative_1rh57_13","purpur-paragraph--paragraph-100":"_purpur-paragraph--paragraph-100_1rh57_16","purpur-paragraph--paragraph-100-medium":"_purpur-paragraph--paragraph-100-medium_1rh57_22","purpur-paragraph--paragraph-100-bold":"_purpur-paragraph--paragraph-100-bold_1rh57_29","purpur-paragraph--paragraph-200":"_purpur-paragraph--paragraph-200_1rh57_36","purpur-paragraph--preamble-100":"_purpur-paragraph--preamble-100_1rh57_42","purpur-paragraph--preamble-200":"_purpur-paragraph--preamble-200_1rh57_48","purpur-paragraph--additional-100":"_purpur-paragraph--additional-100_1rh57_54","purpur-paragraph--additional-100-medium":"_purpur-paragraph--additional-100-medium_1rh57_60","purpur-paragraph--overline-100":"_purpur-paragraph--overline-100_1rh57_67","purpur-paragraph--overline-200":"_purpur-paragraph--overline-200_1rh57_75"},Gr={PARAGRAPH100:"paragraph-100",PARAGRAPH100MEDIUM:"paragraph-100-medium",PARAGRAPH100BOLD:"paragraph-100-bold",PARAGRAPH200:"paragraph-200",PREAMBLE100:"preamble-100",PREAMBLE200:"preamble-200",ADDITIONAL100:"additional-100",ADDITIONAL100MEDIUM:"additional-100-medium",OVERLINE100:"overline-100",OVERLINE200:"overline-200"},v="purpur-paragraph",j=({["data-testid"]:e,children:n,className:t,disabled:p,enableHyphenation:i=!1,negative:r=!1,variant:a=Gr.PARAGRAPH100,...u})=>{const l=Dr([t,f[v],f[`${v}--${a}`],{[f[`${v}--hyphens`]]:i,[f[`${v}--disabled`]]:p,[f[`${v}--negative`]]:r}]);return s.jsx("p",{...u,className:l,"data-testid":e,children:n})};j.displayName="Paragraph";const Fr={"purpur-card-feature-list":"_purpur-card-feature-list_ej4qm_1","purpur-card-feature-list__list-item":"_purpur-card-feature-list__list-item_ej4qm_6"},O=c.bind(Fr),E="purpur-card-feature-list",Ur=({["data-testid"]:e="purpur-card-feature-list",listItems:n})=>n&&n.length>0?s.jsx("ul",{className:O(E),"data-testid":e,children:n.map(t=>s.jsxs("li",{className:O(`${E}__list-item`),"data-testid":`${e}-item`,children:[s.jsx(H,{size:"xs"}),s.jsx(j,{children:t})]},t))}):null;function Wr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var D={exports:{}};/*!
|
|
22
22
|
Copyright (c) 2018 Jed Watson.
|
|
23
23
|
Licensed under the MIT License (MIT), see
|
|
24
24
|
http://jedwatson.github.io/classnames
|
|
25
|
-
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(D);var Xr=D.exports;const
|
|
25
|
+
*/(function(e){(function(){var n={}.hasOwnProperty;function t(){for(var r="",a=0;a<arguments.length;a++){var u=arguments[a];u&&(r=i(r,p(u)))}return r}function p(r){if(typeof r=="string"||typeof r=="number")return r;if(typeof r!="object")return"";if(Array.isArray(r))return t.apply(null,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var a="";for(var u in r)n.call(r,u)&&r[u]&&(a=i(a,u));return a}function i(r,a){return a?r?r+" "+a:r+a:r}e.exports?(t.default=t,e.exports=t):window.classNames=t})()})(D);var Xr=D.exports;const M=Wr(Xr),Kr="_rotate_1xozj_1",Jr="_dash_1xozj_1",w={"purpur-spinner":"_purpur-spinner_1xozj_1",rotate:Kr,"purpur-spinner--xxs":"_purpur-spinner--xxs_1xozj_4","purpur-spinner--xs":"_purpur-spinner--xs_1xozj_8","purpur-spinner--sm":"_purpur-spinner--sm_1xozj_12","purpur-spinner--md":"_purpur-spinner--md_1xozj_16","purpur-spinner--lg":"_purpur-spinner--lg_1xozj_20","purpur-spinner__circle":"_purpur-spinner__circle_1xozj_24",dash:Jr,"purpur-spinner__circle--disabled":"_purpur-spinner__circle--disabled_1xozj_33","purpur-spinner__circle--negative":"_purpur-spinner__circle--negative_1xozj_36"},y="purpur-spinner",Qr={XXS:"xxs",XS:"xs",SM:"sm",MD:"md",LG:"lg"},Yr=({["data-testid"]:e,disabled:n=!1,negative:t=!1,size:p=Qr.SM,...i})=>s.jsx("div",{className:M([w[y],w[`${y}--${p}`]]),"data-testid":e,...i,children:s.jsx("svg",{viewBox:"0 0 50 50",children:s.jsx("circle",{className:M(w[`${y}__circle`],{[w[`${y}__circle--disabled`]]:n,[w[`${y}__circle--negative`]]:t}),cx:"25",cy:"25",r:"20"})})}),re={"purpur-card-link-arrow":"_purpur-card-link-arrow_1r4zu_1","purpur-card-link-arrow--sm":"_purpur-card-link-arrow--sm_1r4zu_33","purpur-card-link-arrow--icon-only":"_purpur-card-link-arrow--icon-only_1r4zu_36","purpur-card-link-arrow--md":"_purpur-card-link-arrow--md_1r4zu_39","purpur-card-link-arrow--lg":"_purpur-card-link-arrow--lg_1r4zu_45","purpur-card-link-arrow--full-width":"_purpur-card-link-arrow--full-width_1r4zu_51","purpur-card-link-arrow--primary":"_purpur-card-link-arrow--primary_1r4zu_54","purpur-card-link-arrow--disabled":"_purpur-card-link-arrow--disabled_1r4zu_58","purpur-card-link-arrow--primary-negative":"_purpur-card-link-arrow--primary-negative_1r4zu_64","purpur-card-link-arrow--secondary":"_purpur-card-link-arrow--secondary_1r4zu_76","purpur-card-link-arrow--secondary-negative":"_purpur-card-link-arrow--secondary-negative_1r4zu_87","purpur-card-link-arrow--expressive":"_purpur-card-link-arrow--expressive_1r4zu_98","purpur-card-link-arrow--expressive-negative":"_purpur-card-link-arrow--expressive-negative_1r4zu_108"},ee=c.bind(re),h="purpur-card-link-arrow",te=({["data-testid"]:e="purpur-card-link-arrow",className:n,disabled:t=!1,loading:p=!1,...i})=>s.jsx("div",{className:`${ee([h,n,`${h}--md`,`${h}--icon-only`,`${h}--secondary`,{[`${h}--disabled`]:t}])} ${h}`,"data-testid":e,...i,children:p?s.jsx(Yr,{"data-testid":`${e}-spinner`,size:"xs",disabled:t}):s.jsx(B,{"data-testid":`${e}-arrow`,size:"md"})}),ae={"purpur-card-overline":"_purpur-card-overline_142el_1"},ne=c.bind(ae),ue="purpur-card-overline",pe=({["data-testid"]:e="purpur-card-overline",overline:n})=>n?s.jsx(j,{className:ne(ue),"data-testid":e,children:n}):null,ie={"purpur-card-root":"_purpur-card-root_bqk1d_1","purpur-card-root--primary":"_purpur-card-root--primary_bqk1d_8","purpur-card-root--secondary":"_purpur-card-root--secondary_bqk1d_11","purpur-card-root--full-height":"_purpur-card-root--full-height_bqk1d_14"},se={"purpur-card-trigger-item":"_purpur-card-trigger-item_1sp43_1","purpur-card-trigger-item--button":"_purpur-card-trigger-item--button_1sp43_6","purpur-card-trigger-item--disabled":"_purpur-card-trigger-item--disabled_1sp43_11"};function m(){return m=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var p in t)Object.prototype.hasOwnProperty.call(t,p)&&(e[p]=t[p])}return e},m.apply(this,arguments)}function oe(e,n){typeof e=="function"?e(n):e!=null&&(e.current=n)}function le(...e){return n=>e.forEach(t=>oe(t,n))}const G=o.forwardRef((e,n)=>{const{children:t,...p}=e,i=o.Children.toArray(t),r=i.find(de);if(r){const a=r.props.children,u=i.map(l=>l===r?o.Children.count(a)>1?o.Children.only(null):o.isValidElement(a)?a.props.children:null:l);return o.createElement($,m({},p,{ref:n}),o.isValidElement(a)?o.cloneElement(a,void 0,u):null)}return o.createElement($,m({},p,{ref:n}),t)});G.displayName="Slot";const $=o.forwardRef((e,n)=>{const{children:t,...p}=e;return o.isValidElement(t)?o.cloneElement(t,{..._e(p,t.props),ref:n?le(n,t.ref):t.ref}):o.Children.count(t)>1?o.Children.only(null):null});$.displayName="SlotClone";const ce=({children:e})=>o.createElement(o.Fragment,null,e);function de(e){return o.isValidElement(e)&&e.type===ce}function _e(e,n){const t={...n};for(const p in n){const i=e[p],r=n[p];/^on[A-Z]/.test(p)?i&&r?t[p]=(...a)=>{r(...a),i(...a)}:i&&(t[p]=i):p==="style"?t[p]={...i,...r}:p==="className"&&(t[p]=[i,r].filter(Boolean).join(" "))}return{...e,...t}}const ge=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],he=ge.reduce((e,n)=>{const t=o.forwardRef((p,i)=>{const{asChild:r,...a}=p,u=r?G:n;return o.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),o.createElement(u,m({},a,{ref:i}))});return t.displayName=`Primitive.${n}`,{...e,[n]:t}},{}),me=o.forwardRef((e,n)=>o.createElement(he.span,m({},e,{ref:n,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}))),fe=me,Z=({asChild:e,children:n,className:t="",["data-testid"]:p})=>s.jsx(fe,{asChild:e,"data-testid":p,className:t,children:n}),R=c.bind(se),g="purpur-card-trigger-item",ve=({["data-testid"]:e="purpur-card-trigger-item",disabled:n=!1,href:t,onClick:p,screenReaderText:i})=>{const r=u=>{n?u.preventDefault():p&&p()},a=`${g} ${n?`${g}--disabled`:""}`;return t?s.jsx("a",{"aria-disabled":n,className:`${R([g,{[`${g}--disabled`]:n}])} ${a}`,"data-testid":e,href:n?void 0:t,tabIndex:n?0:void 0,children:s.jsx(Z,{children:i})}):s.jsx("button",{"aria-disabled":n,className:`${R([g,`${g}--button`,{[`${g}--disabled`]:n}])} ${a}`,"data-testid":e,type:"button",onClick:r,children:s.jsx(Z,{children:i})})},we=c.bind(ie),x="purpur-card-root",F=o.forwardRef(({["data-testid"]:e="purpur-card-root",children:n,className:t,disabled:p,fullHeight:i,href:r,onClick:a,screenReaderText:u,variant:l,...U},W)=>{const X=we([x,t,{[`${x}--${l}`]:l,[`${x}--full-height`]:i}]);return s.jsxs("div",{className:X,"data-testid":e,ref:W,...U,children:[n,(a||r)&&u&&s.jsx(ve,{disabled:p,href:r,onClick:a,screenReaderText:u})]})});F.displayName="CardRoot";const z=c.bind(Q),b="purpur-card",d=({children:e,className:n,...t})=>{const p=z([b,n,{[`${b}--is-interactive`]:t.onClick||t.href,[`${b}--disabled`]:t.disabled}]);return s.jsx(F,{className:z(p),...t,children:e})};d.Badge=$r;d.LinkArrow=te;d.Content=Sr;d.ContentContainer=Or;d.FeatureList=Ur;d.Overline=pe;d.displayName="Card";exports.Card=d;
|
|
26
26
|
//# sourceMappingURL=card.cjs.js.map
|