@uva-glass/component-library 1.25.0 → 1.26.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/StatusPill.css +1 -0
- package/dist/components/StatusPill/StatusPill.d.ts +6 -0
- package/dist/components/StatusPill/StatusPill.js +32 -0
- package/dist/components/StatusPill/StatusPill.js.map +1 -0
- package/dist/components/StatusPill/StatusPill.stories.d.ts +5 -0
- package/dist/components/StatusPill/StatusPill.stories.js +17 -0
- package/dist/components/StatusPill/StatusPill.stories.js.map +1 -0
- package/dist/components/StatusPill/index.d.ts +1 -0
- package/dist/components/StatusPill/index.js +5 -0
- package/dist/components/StatusPill/index.js.map +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +14 -12
- package/dist/components/index.js.map +1 -1
- package/dist/index.js +14 -12
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._status-pill_x7rv2_1{align-items:center;border-radius:1.5rem;display:flex;gap:.25rem;padding:.25rem .5rem;width:fit-content}._status-pill__possible_x7rv2_10{background-color:var(--color-mint-cream);color:var(--color-san-felix)}._status-pill__impossible_x7rv2_15{background-color:var(--color-amour);color:var(--color-uva-red-dark)}._status-pill--bar_x7rv2_20{border-radius:0;justify-content:center;padding:.5rem;width:100%}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { jsxs as p, jsx as _ } from "react/jsx-runtime";
|
|
2
|
+
import { c as e } from "../../clsx-DB4S2d7J.js";
|
|
3
|
+
import { Icon as a } from "../Icon/Icon.js";
|
|
4
|
+
import '../../assets/StatusPill.css';const l = {
|
|
5
|
+
"status-pill": "_status-pill_x7rv2_1",
|
|
6
|
+
"status-pill__possible": "_status-pill__possible_x7rv2_10",
|
|
7
|
+
"status-pill__impossible": "_status-pill__impossible_x7rv2_15",
|
|
8
|
+
"status-pill--bar": "_status-pill--bar_x7rv2_20"
|
|
9
|
+
}, o = {
|
|
10
|
+
possible: "CheckCircleFillMini",
|
|
11
|
+
impossible: "CrossCircleFillMini"
|
|
12
|
+
};
|
|
13
|
+
function m({ status: s, variant: i = "default", label: t }) {
|
|
14
|
+
return /* @__PURE__ */ p(
|
|
15
|
+
"span",
|
|
16
|
+
{
|
|
17
|
+
className: e(
|
|
18
|
+
l["status-pill"],
|
|
19
|
+
l[`status-pill__${s}`],
|
|
20
|
+
i !== "default" && l[`status-pill--${i}`]
|
|
21
|
+
),
|
|
22
|
+
children: [
|
|
23
|
+
/* @__PURE__ */ _(a, { name: o[s], title: s, size: 16 }),
|
|
24
|
+
t
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
export {
|
|
30
|
+
m as StatusPill
|
|
31
|
+
};
|
|
32
|
+
//# sourceMappingURL=StatusPill.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatusPill.js","sources":["../../../src/components/StatusPill/StatusPill.tsx"],"sourcesContent":["import { clsx } from 'clsx';\n\nimport type { IconProps } from 'components/Icon';\n\nimport styles from './StatusPill.module.css';\n\nimport { Icon } from 'components/Icon';\n\nexport interface StatusPillProps {\n status: 'possible' | 'impossible';\n variant?: 'default' | 'bar';\n label: string;\n}\n\nconst iconNameMap: Partial<Record<StatusPillProps['status'], IconProps['name']>> = {\n possible: 'CheckCircleFillMini',\n impossible: 'CrossCircleFillMini',\n};\n\nexport function StatusPill({ status, variant = 'default', label }: StatusPillProps) {\n return (\n <span\n className={clsx(\n styles['status-pill'],\n styles[`status-pill__${status}`],\n variant !== 'default' && styles[`status-pill--${variant}`]\n )}\n >\n <Icon name={iconNameMap[status]!} title={status} size={16} />\n {label}\n </span>\n );\n}\n"],"names":["iconNameMap","StatusPill","status","variant","label","jsxs","clsx","styles","jsx","Icon"],"mappings":";;;;;;;;GAcMA,IAA6E;AAAA,EACjF,UAAU;AAAA,EACV,YAAY;AACd;AAEO,SAASC,EAAW,EAAE,QAAAC,GAAQ,SAAAC,IAAU,WAAW,OAAAC,KAA0B;AAEhF,SAAA,gBAAAC;AAAA,IAAC;AAAA,IAAA;AAAA,MACC,WAAWC;AAAA,QACTC,EAAO,aAAa;AAAA,QACpBA,EAAO,gBAAgBL,CAAM,EAAE;AAAA,QAC/BC,MAAY,aAAaI,EAAO,gBAAgBJ,CAAO,EAAE;AAAA,MAC3D;AAAA,MAEA,UAAA;AAAA,QAAC,gBAAAK,EAAAC,GAAA,EAAK,MAAMT,EAAYE,CAAM,GAAI,OAAOA,GAAQ,MAAM,IAAI;AAAA,QAC1DE;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGP;"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { StatusPillProps } from './StatusPill';
|
|
2
|
+
|
|
3
|
+
declare const _default: import('@storybook/types').ComponentAnnotations<import('@storybook/react').ReactRenderer, StatusPillProps>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const StatusPillExample: import('@storybook/types').AnnotatedStoryFn<import('@storybook/react').ReactRenderer, StatusPillProps>;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { StatusPill as l } from "./StatusPill.js";
|
|
3
|
+
import { Container as a } from "../storyComponents/Container/Container.js";
|
|
4
|
+
const n = {
|
|
5
|
+
title: "Molecules/StatusPill",
|
|
6
|
+
component: l
|
|
7
|
+
}, e = (s) => /* @__PURE__ */ t(a, { children: /* @__PURE__ */ t(l, { ...s }) }), o = e.bind({});
|
|
8
|
+
o.args = {
|
|
9
|
+
status: "possible",
|
|
10
|
+
variant: "default",
|
|
11
|
+
label: "Example Status Pill"
|
|
12
|
+
};
|
|
13
|
+
export {
|
|
14
|
+
o as StatusPillExample,
|
|
15
|
+
n as default
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=StatusPill.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StatusPill.stories.js","sources":["../../../src/components/StatusPill/StatusPill.stories.tsx"],"sourcesContent":["import type { Meta, StoryFn } from '@storybook/react';\nimport type { StatusPillProps } from './StatusPill';\n\nimport { StatusPill } from './StatusPill';\n\nimport { Container } from 'components/storyComponents/Container';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n title: 'Molecules/StatusPill',\n component: StatusPill,\n} as Meta<StatusPillProps>;\n\nconst Template: StoryFn<StatusPillProps> = (args) => (\n <Container>\n <StatusPill {...args} />\n </Container>\n);\n\nexport const StatusPillExample = Template.bind({});\nStatusPillExample.args = {\n status: 'possible',\n variant: 'default',\n label: 'Example Status Pill',\n};\n"],"names":["StatusPill_stories","StatusPill","Template","args","jsx","Container","StatusPillExample"],"mappings":";;;AAQA,MAAeA,IAAA;AAAA,EACb,OAAO;AAAA,EACP,WAAWC;AACb,GAEMC,IAAqC,CAACC,MAC1C,gBAAAC,EAACC,KACC,UAAC,gBAAAD,EAAAH,GAAA,EAAY,GAAGE,EAAM,CAAA,EACxB,CAAA,GAGWG,IAAoBJ,EAAS,KAAK,EAAE;AACjDI,EAAkB,OAAO;AAAA,EACvB,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,OAAO;AACT;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './StatusPill';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
package/dist/components/index.js
CHANGED
|
@@ -2,16 +2,16 @@ import { Accordion as t } from "./Accordion/Accordion.js";
|
|
|
2
2
|
import { AppStatusBar as p } from "./AppStatusBar/AppStatusBar.js";
|
|
3
3
|
import { Backdrop as f } from "./Backdrop/Backdrop.js";
|
|
4
4
|
import { Button as a } from "./Button/Button.js";
|
|
5
|
-
import { ButtonGroup as
|
|
6
|
-
import { Card as
|
|
5
|
+
import { ButtonGroup as n } from "./ButtonGroup/ButtonGroup.js";
|
|
6
|
+
import { Card as u } from "./Card/Card.js";
|
|
7
7
|
import { Checkbox as d } from "./Checkbox/Checkbox.js";
|
|
8
8
|
import { FieldHint as B } from "./FieldHint/FieldHint.js";
|
|
9
|
-
import { FormField as
|
|
9
|
+
import { FormField as M } from "./FormField/FormField.js";
|
|
10
10
|
import { Icon as C } from "./Icon/Icon.js";
|
|
11
11
|
import { IconButton as L } from "./IconButton/IconButton.js";
|
|
12
12
|
import { InfoMessage as g } from "./InfoMessage/InfoMessage.js";
|
|
13
|
-
import { Input as
|
|
14
|
-
import { InputField as
|
|
13
|
+
import { Input as P } from "./Input/Input.js";
|
|
14
|
+
import { InputField as A } from "./InputField/InputField.js";
|
|
15
15
|
import { Label as R } from "./Label/Label.js";
|
|
16
16
|
import { M as y } from "../MenuLink-CLEqkVVh.js";
|
|
17
17
|
import { MetaDataList as H } from "./MetaDataList/MetaDataList.js";
|
|
@@ -24,22 +24,23 @@ import { SectionNotification as U } from "./SectionNotification/SectionNotificat
|
|
|
24
24
|
import { SelectListbox as W } from "./SelectListbox/SelectListbox.js";
|
|
25
25
|
import { SelectProvider as Y, useSelect as Z } from "./SelectListbox/SelectProvider.js";
|
|
26
26
|
import { Spinner as $ } from "./Spinner/Spinner.js";
|
|
27
|
-
import {
|
|
27
|
+
import { StatusPill as ro } from "./StatusPill/StatusPill.js";
|
|
28
|
+
import { Tooltip as eo } from "./Tooltip/Tooltip.js";
|
|
28
29
|
export {
|
|
29
30
|
t as Accordion,
|
|
30
31
|
p as AppStatusBar,
|
|
31
32
|
f as Backdrop,
|
|
32
33
|
a as Button,
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
n as ButtonGroup,
|
|
35
|
+
u as Card,
|
|
35
36
|
d as Checkbox,
|
|
36
37
|
B as FieldHint,
|
|
37
|
-
|
|
38
|
+
M as FormField,
|
|
38
39
|
C as Icon,
|
|
39
40
|
L as IconButton,
|
|
40
41
|
g as InfoMessage,
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
P as Input,
|
|
43
|
+
A as InputField,
|
|
43
44
|
R as Label,
|
|
44
45
|
y as MenuLink,
|
|
45
46
|
H as MetaDataList,
|
|
@@ -52,7 +53,8 @@ export {
|
|
|
52
53
|
W as SelectListbox,
|
|
53
54
|
Y as SelectProvider,
|
|
54
55
|
$ as Spinner,
|
|
55
|
-
ro as
|
|
56
|
+
ro as StatusPill,
|
|
57
|
+
eo as Tooltip,
|
|
56
58
|
Z as useSelect
|
|
57
59
|
};
|
|
58
60
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index.js
CHANGED
|
@@ -2,16 +2,16 @@ import { Accordion as t } from "./components/Accordion/Accordion.js";
|
|
|
2
2
|
import { AppStatusBar as p } from "./components/AppStatusBar/AppStatusBar.js";
|
|
3
3
|
import { Backdrop as f } from "./components/Backdrop/Backdrop.js";
|
|
4
4
|
import { Button as a } from "./components/Button/Button.js";
|
|
5
|
-
import { ButtonGroup as
|
|
6
|
-
import { Card as
|
|
5
|
+
import { ButtonGroup as n } from "./components/ButtonGroup/ButtonGroup.js";
|
|
6
|
+
import { Card as u } from "./components/Card/Card.js";
|
|
7
7
|
import { Checkbox as d } from "./components/Checkbox/Checkbox.js";
|
|
8
8
|
import { FieldHint as B } from "./components/FieldHint/FieldHint.js";
|
|
9
|
-
import { FormField as
|
|
9
|
+
import { FormField as M } from "./components/FormField/FormField.js";
|
|
10
10
|
import { Icon as C } from "./components/Icon/Icon.js";
|
|
11
11
|
import { IconButton as L } from "./components/IconButton/IconButton.js";
|
|
12
12
|
import { InfoMessage as g } from "./components/InfoMessage/InfoMessage.js";
|
|
13
|
-
import { Input as
|
|
14
|
-
import { InputField as
|
|
13
|
+
import { Input as P } from "./components/Input/Input.js";
|
|
14
|
+
import { InputField as A } from "./components/InputField/InputField.js";
|
|
15
15
|
import { Label as R } from "./components/Label/Label.js";
|
|
16
16
|
import { M as y } from "./MenuLink-CLEqkVVh.js";
|
|
17
17
|
import { MetaDataList as H } from "./components/MetaDataList/MetaDataList.js";
|
|
@@ -24,22 +24,23 @@ import { SectionNotification as U } from "./components/SectionNotification/Secti
|
|
|
24
24
|
import { SelectListbox as W } from "./components/SelectListbox/SelectListbox.js";
|
|
25
25
|
import { SelectProvider as Y, useSelect as Z } from "./components/SelectListbox/SelectProvider.js";
|
|
26
26
|
import { Spinner as $ } from "./components/Spinner/Spinner.js";
|
|
27
|
-
import {
|
|
27
|
+
import { StatusPill as ro } from "./components/StatusPill/StatusPill.js";
|
|
28
|
+
import { Tooltip as eo } from "./components/Tooltip/Tooltip.js";
|
|
28
29
|
export {
|
|
29
30
|
t as Accordion,
|
|
30
31
|
p as AppStatusBar,
|
|
31
32
|
f as Backdrop,
|
|
32
33
|
a as Button,
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
n as ButtonGroup,
|
|
35
|
+
u as Card,
|
|
35
36
|
d as Checkbox,
|
|
36
37
|
B as FieldHint,
|
|
37
|
-
|
|
38
|
+
M as FormField,
|
|
38
39
|
C as Icon,
|
|
39
40
|
L as IconButton,
|
|
40
41
|
g as InfoMessage,
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
P as Input,
|
|
43
|
+
A as InputField,
|
|
43
44
|
R as Label,
|
|
44
45
|
y as MenuLink,
|
|
45
46
|
H as MetaDataList,
|
|
@@ -52,7 +53,8 @@ export {
|
|
|
52
53
|
W as SelectListbox,
|
|
53
54
|
Y as SelectProvider,
|
|
54
55
|
$ as Spinner,
|
|
55
|
-
ro as
|
|
56
|
+
ro as StatusPill,
|
|
57
|
+
eo as Tooltip,
|
|
56
58
|
Z as useSelect
|
|
57
59
|
};
|
|
58
60
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|