@caseparts-org/caseblocks 0.0.255 → 0.0.257
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/Admonition.css +1 -1
- package/dist/assets/Root.css +1 -1
- package/dist/assets/Upsell.css +1 -0
- package/dist/main-client.js +76 -74
- package/dist/main-server.d.ts +2 -0
- package/dist/main-server.js +27 -25
- package/dist/molecules/Admonition/Admonition.d.ts +2 -2
- package/dist/molecules/Admonition/Admonition.js +49 -35
- package/dist/molecules/Admonition/Admonition.stories.d.ts +4 -2
- package/dist/molecules/Admonition/Admonition.stories.js +22 -8
- package/dist/molecules/Markdown/Markdown.js +740 -730
- package/dist/molecules/Markdown/Markdown.stories.js +13 -9
- package/dist/molecules/Markdown/remarkAdmonition.js +1 -1
- package/dist/molecules/Upsell/Upsell.d.ts +9 -0
- package/dist/molecules/Upsell/Upsell.js +34 -0
- package/dist/molecules/Upsell/Upsell.stories.d.ts +19 -0
- package/dist/molecules/Upsell/Upsell.stories.js +27 -0
- package/dist/styles/tokens.css +15 -0
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._upsell_14gph_1{display:flex;align-items:flex-start;gap:var(--spacing-spacing-3xs);margin:var(--spacing-spacing-2xs) 0}._icon_14gph_8{flex:none}._content_14gph_12{display:grid}
|
package/dist/main-client.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Button as t } from "./atoms/Button/Button.js";
|
|
2
|
-
import { Flex as
|
|
2
|
+
import { Flex as p } from "./atoms/Flex/Flex.js";
|
|
3
3
|
import { Column as f, Grid as x } from "./atoms/Grid/Grid.js";
|
|
4
4
|
import { HighlightedText as n } from "./atoms/HighlightedText/HighlightedText.js";
|
|
5
5
|
import { Head as l } from "./atoms/Root/Head.js";
|
|
@@ -18,104 +18,106 @@ import { getHideAtStyles as V } from "./atoms/HideAt.js";
|
|
|
18
18
|
import { Logo as E } from "./molecules/Logo/Logo.js";
|
|
19
19
|
import { QuantityInput as O } from "./molecules/QuantityInput/QuantityInput.js";
|
|
20
20
|
import { Pricing as R } from "./molecules/Pricing/Pricing.js";
|
|
21
|
-
import { ProgressBar as
|
|
22
|
-
import { Availability as
|
|
23
|
-
import { Avatar as
|
|
21
|
+
import { ProgressBar as W } from "./molecules/ProgressBar/ProgressBar.js";
|
|
22
|
+
import { Availability as j } from "./molecules/Availability/Availability.js";
|
|
23
|
+
import { Avatar as J } from "./molecules/Avatar/Avatar.js";
|
|
24
24
|
import { BannerCard as X } from "./molecules/BannerCard/BannerCard.js";
|
|
25
25
|
import { CardLink as _ } from "./molecules/CardLink/CardLink.js";
|
|
26
26
|
import { Breadcrumbs as oo } from "./molecules/Breadcrumbs/Breadcrumbs.js";
|
|
27
27
|
import { Disclaimer as to } from "./molecules/Disclaimer/Disclaimer.js";
|
|
28
|
-
import { Admonition as
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
import {
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
28
|
+
import { Admonition as po } from "./molecules/Admonition/Admonition.js";
|
|
29
|
+
import { Upsell as fo } from "./molecules/Upsell/Upsell.js";
|
|
30
|
+
import { CustomWizardBadge as ao } from "./molecules/CustomWizardBadge/CustomWizardBadge.js";
|
|
31
|
+
import { NotFound as io } from "./organisms/NotFound/NotFound.js";
|
|
32
|
+
import { StatusPage as uo } from "./organisms/StatusPage/StatusPage.js";
|
|
33
|
+
import { HorizontalScroll as co } from "./atoms/HorizontalScroll/HorizontalScroll.js";
|
|
34
|
+
import { SlideInPanel as Co } from "./atoms/SlideInPanel/SlideInPanel.js";
|
|
35
|
+
import { DropdownButton as Ao } from "./atoms/DropdownButton/DropdownButton.js";
|
|
36
|
+
import { Input as Bo } from "./atoms/Input/Input.js";
|
|
37
|
+
import { InputEndAdornmentButton as Io } from "./atoms/InputEndAdornmentButton/InputEndAdornmentButton.js";
|
|
38
|
+
import { Select as ho } from "./atoms/Select/Select.js";
|
|
39
|
+
import { Tooltip as vo } from "./atoms/Tooltip/Tooltip.js";
|
|
40
|
+
import { Popover as Ho } from "./atoms/Popover/Popover.js";
|
|
41
|
+
import { Accordion as yo } from "./molecules/Accordion/Accordion.js";
|
|
42
|
+
import { Account as Fo } from "./molecules/Account/Account.js";
|
|
43
|
+
import { Chip as No } from "./molecules/Chip/Chip.js";
|
|
44
|
+
import { ToggleView as zo } from "./molecules/ToggleView/ToggleView.js";
|
|
45
|
+
import { CartPart as Go } from "./molecules/Cart/CartPart.js";
|
|
46
|
+
import { AddToCartPart as Qo } from "./molecules/AddToCartPart/AddToCartPart.js";
|
|
47
|
+
import { CartSlideInPanel as Uo } from "./molecules/Cart/CartSlideInPanel.js";
|
|
48
|
+
import { StatefulButton as Zo } from "./molecules/StatefulButton/StatefulButton.js";
|
|
49
|
+
import { AnimatedCheckMark as qo } from "./molecules/StatefulButton/AnimatedCheckmark.js";
|
|
50
|
+
import { AddToCart as Ko } from "./molecules/AddToCart/AddToCart.js";
|
|
51
|
+
import { Modal as Yo } from "./molecules/Modal/Modal.js";
|
|
52
|
+
import { ImageViewer as $o } from "./molecules/ImageViewer/ImageViewer.js";
|
|
53
|
+
import { T as rr } from "./Table-_UT9976g.js";
|
|
54
|
+
import { Error as er } from "./molecules/Error/Error.js";
|
|
55
|
+
import { MainNav as mr } from "./organisms/MainNav/MainNav.js";
|
|
56
|
+
import { ChipSelector as xr } from "./organisms/ChipSelector/ChipSelector.js";
|
|
57
|
+
import { SuggestionDropdown as nr } from "./organisms/SuggestionDropdown/SuggestionDropdown.js";
|
|
58
|
+
import { Product as lr } from "./organisms/Product/Product.js";
|
|
59
|
+
import { Carousel as ur } from "./organisms/Carousel/Carousel.js";
|
|
60
|
+
import { Footer as cr } from "./organisms/Footer/Footer.js";
|
|
61
|
+
import { default as Cr } from "./organisms/SpinZoomViewer/SpinZoomViewer.js";
|
|
61
62
|
export {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
63
|
+
yo as Accordion,
|
|
64
|
+
Fo as Account,
|
|
65
|
+
Ko as AddToCart,
|
|
66
|
+
Qo as AddToCartPart,
|
|
67
|
+
po as Admonition,
|
|
68
|
+
qo as AnimatedCheckMark,
|
|
69
|
+
j as Availability,
|
|
70
|
+
J as Avatar,
|
|
70
71
|
X as BannerCard,
|
|
71
72
|
oo as Breadcrumbs,
|
|
72
73
|
t as Button,
|
|
73
74
|
_ as CardLink,
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
75
|
+
ur as Carousel,
|
|
76
|
+
Go as CartPart,
|
|
77
|
+
Uo as CartSlideInPanel,
|
|
78
|
+
No as Chip,
|
|
79
|
+
xr as ChipSelector,
|
|
79
80
|
f as Column,
|
|
80
|
-
|
|
81
|
+
ao as CustomWizardBadge,
|
|
81
82
|
to as Disclaimer,
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
83
|
+
Ao as DropdownButton,
|
|
84
|
+
er as Error,
|
|
85
|
+
p as Flex,
|
|
86
|
+
cr as Footer,
|
|
86
87
|
x as Grid,
|
|
87
88
|
l as Head,
|
|
88
89
|
n as HighlightedText,
|
|
89
|
-
|
|
90
|
+
co as HorizontalScroll,
|
|
90
91
|
u as Icon,
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
92
|
+
$o as ImageViewer,
|
|
93
|
+
Bo as Input,
|
|
94
|
+
Io as InputEndAdornmentButton,
|
|
94
95
|
I as Link,
|
|
95
96
|
b as LinkButton,
|
|
96
97
|
E as Logo,
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
98
|
+
mr as MainNav,
|
|
99
|
+
Yo as Modal,
|
|
100
|
+
io as NotFound,
|
|
100
101
|
D as Pill,
|
|
101
|
-
|
|
102
|
+
Ho as Popover,
|
|
102
103
|
R as Pricing,
|
|
103
|
-
|
|
104
|
-
|
|
104
|
+
lr as Product,
|
|
105
|
+
W as ProgressBar,
|
|
105
106
|
O as QuantityInput,
|
|
106
107
|
c as Root,
|
|
107
|
-
|
|
108
|
+
ho as Select,
|
|
108
109
|
C as Separator,
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
110
|
+
Co as SlideInPanel,
|
|
111
|
+
Cr as SpinZoomViewer,
|
|
112
|
+
Zo as StatefulButton,
|
|
113
|
+
uo as StatusPage,
|
|
114
|
+
nr as SuggestionDropdown,
|
|
115
|
+
rr as Table,
|
|
115
116
|
A as Text,
|
|
116
117
|
B as ToggleSwitch,
|
|
117
|
-
|
|
118
|
-
|
|
118
|
+
zo as ToggleView,
|
|
119
|
+
vo as Tooltip,
|
|
120
|
+
fo as Upsell,
|
|
119
121
|
M as configureImage,
|
|
120
122
|
v as configureLink,
|
|
121
123
|
V as getHideAtStyles,
|
package/dist/main-server.d.ts
CHANGED
|
@@ -50,6 +50,8 @@ export { Disclaimer } from './molecules/Disclaimer/Disclaimer';
|
|
|
50
50
|
export type { DisclaimerProps, DisclaimerColorToken, DisclaimerIcon, DisclaimerContentProps, DisclaimerIconProps, DisclaimerPrimaryProps, DisclaimerSubtextProps, DisclaimerCTAProps, } from './molecules/Disclaimer/Disclaimer';
|
|
51
51
|
export { Admonition } from './molecules/Admonition/Admonition';
|
|
52
52
|
export type { AdmonitionProps, AdmonitionVariant } from './molecules/Admonition/Admonition';
|
|
53
|
+
export { Upsell } from './molecules/Upsell/Upsell';
|
|
54
|
+
export type { UpsellProps, UpsellIcon } from './molecules/Upsell/Upsell';
|
|
53
55
|
export { CustomWizardBadge } from './molecules/CustomWizardBadge/CustomWizardBadge';
|
|
54
56
|
export type { CustomWizardBadgeProps } from './molecules/CustomWizardBadge/CustomWizardBadge';
|
|
55
57
|
export { NotFound } from './organisms/NotFound/NotFound';
|
package/dist/main-server.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Button as
|
|
1
|
+
import { Button as e } from "./atoms/Button/Button.js";
|
|
2
2
|
import { Flex as m } from "./atoms/Flex/Flex.js";
|
|
3
|
-
import { Column as
|
|
3
|
+
import { Column as x, Grid as f } from "./atoms/Grid/Grid.js";
|
|
4
4
|
import { HighlightedText as a } from "./atoms/HighlightedText/HighlightedText.js";
|
|
5
|
-
import { Head as
|
|
6
|
-
import { Icon as
|
|
5
|
+
import { Head as l } from "./atoms/Root/Head.js";
|
|
6
|
+
import { Icon as d } from "./atoms/Icon/Icon.js";
|
|
7
7
|
import { Root as s } from "./atoms/Root/Root.js";
|
|
8
8
|
import { Separator as B } from "./atoms/Separator/Separator.js";
|
|
9
9
|
import { Text as C } from "./atoms/Text/Text.js";
|
|
@@ -16,48 +16,50 @@ import { Pill as N } from "./atoms/Pill/Pill.js";
|
|
|
16
16
|
import { configureImage as z } from "./atoms/Image/configureImage.js";
|
|
17
17
|
import { getHideAtStyles as G } from "./atoms/HideAt.js";
|
|
18
18
|
import { Logo as Q } from "./molecules/Logo/Logo.js";
|
|
19
|
-
import { QuantityInput as
|
|
20
|
-
import { Pricing as
|
|
21
|
-
import { ProgressBar as
|
|
22
|
-
import { Availability as
|
|
19
|
+
import { QuantityInput as U } from "./molecules/QuantityInput/QuantityInput.js";
|
|
20
|
+
import { Pricing as j } from "./molecules/Pricing/Pricing.js";
|
|
21
|
+
import { ProgressBar as E } from "./molecules/ProgressBar/ProgressBar.js";
|
|
22
|
+
import { Availability as K } from "./molecules/Availability/Availability.js";
|
|
23
23
|
import { Avatar as V } from "./molecules/Avatar/Avatar.js";
|
|
24
24
|
import { BannerCard as Y } from "./molecules/BannerCard/BannerCard.js";
|
|
25
25
|
import { CardLink as _ } from "./molecules/CardLink/CardLink.js";
|
|
26
26
|
import { Breadcrumbs as rr } from "./molecules/Breadcrumbs/Breadcrumbs.js";
|
|
27
|
-
import { Disclaimer as
|
|
27
|
+
import { Disclaimer as er } from "./molecules/Disclaimer/Disclaimer.js";
|
|
28
28
|
import { Admonition as mr } from "./molecules/Admonition/Admonition.js";
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
29
|
+
import { Upsell as xr } from "./molecules/Upsell/Upsell.js";
|
|
30
|
+
import { CustomWizardBadge as ir } from "./molecules/CustomWizardBadge/CustomWizardBadge.js";
|
|
31
|
+
import { NotFound as nr } from "./organisms/NotFound/NotFound.js";
|
|
32
|
+
import { StatusPage as gr } from "./organisms/StatusPage/StatusPage.js";
|
|
32
33
|
export {
|
|
33
34
|
mr as Admonition,
|
|
34
|
-
|
|
35
|
+
K as Availability,
|
|
35
36
|
V as Avatar,
|
|
36
37
|
Y as BannerCard,
|
|
37
38
|
rr as Breadcrumbs,
|
|
38
|
-
|
|
39
|
+
e as Button,
|
|
39
40
|
_ as CardLink,
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
41
|
+
x as Column,
|
|
42
|
+
ir as CustomWizardBadge,
|
|
43
|
+
er as Disclaimer,
|
|
43
44
|
m as Flex,
|
|
44
|
-
|
|
45
|
-
|
|
45
|
+
f as Grid,
|
|
46
|
+
l as Head,
|
|
46
47
|
a as HighlightedText,
|
|
47
|
-
|
|
48
|
+
d as Icon,
|
|
48
49
|
S as Link,
|
|
49
50
|
b as LinkButton,
|
|
50
51
|
Q as Logo,
|
|
51
|
-
|
|
52
|
+
nr as NotFound,
|
|
52
53
|
N as Pill,
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
54
|
+
j as Pricing,
|
|
55
|
+
E as ProgressBar,
|
|
56
|
+
U as QuantityInput,
|
|
56
57
|
s as Root,
|
|
57
58
|
B as Separator,
|
|
58
|
-
|
|
59
|
+
gr as StatusPage,
|
|
59
60
|
C as Text,
|
|
60
61
|
A as ToggleSwitch,
|
|
62
|
+
xr as Upsell,
|
|
61
63
|
z as configureImage,
|
|
62
64
|
H as configureLink,
|
|
63
65
|
G as getHideAtStyles,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
|
-
export type AdmonitionVariant = "note" | "tip" | "
|
|
2
|
+
export type AdmonitionVariant = "note" | "tip" | "attention" | "caution" | "warning" | "unknown";
|
|
3
3
|
export type AdmonitionProps = ComponentPropsWithoutRef<"aside"> & {
|
|
4
4
|
admonitionType: string;
|
|
5
5
|
variant: AdmonitionVariant | string;
|
|
6
|
-
icon?: string;
|
|
6
|
+
icon?: string | false;
|
|
7
7
|
title?: string;
|
|
8
8
|
children?: ReactNode;
|
|
9
9
|
};
|
|
@@ -1,46 +1,60 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { Icon as
|
|
3
|
-
import { Text as
|
|
4
|
-
import { c as
|
|
5
|
-
import '../../assets/Admonition.css';const N = "
|
|
6
|
-
admonition:
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
1
|
+
import { jsxs as d, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { Icon as f } from "../../atoms/Icon/Icon.js";
|
|
3
|
+
import { Text as j } from "../../atoms/Text/Text.js";
|
|
4
|
+
import { c as s } from "../../clsx-OuTLNxxd.js";
|
|
5
|
+
import '../../assets/Admonition.css';const p = "_admonition_18jak_1", N = "_admonitionBorderLeft_18jak_8", g = "_admonitionPanel_18jak_13", k = "_admonitionWithIcon_18jak_25", C = "_admonitionIcon_18jak_29", h = "_admonitionContent_18jak_33", I = "_admonitionHeader_18jak_39", T = "_admonitionTitle_18jak_45", A = "_admonitionBody_18jak_52", B = "_admonitionNote_18jak_67", W = "_admonitionTip_18jak_73", x = "_admonitionAttention_18jak_88", L = "_admonitionCaution_18jak_103", P = "_admonitionWarning_18jak_118", w = "_admonitionNeutral_18jak_133", n = {
|
|
6
|
+
admonition: p,
|
|
7
|
+
admonitionBorderLeft: N,
|
|
8
|
+
admonitionPanel: g,
|
|
9
|
+
admonitionWithIcon: k,
|
|
10
|
+
admonitionIcon: C,
|
|
11
|
+
admonitionContent: h,
|
|
12
|
+
admonitionHeader: I,
|
|
13
|
+
admonitionTitle: T,
|
|
14
|
+
admonitionBody: A,
|
|
15
|
+
admonitionNote: B,
|
|
16
|
+
admonitionTip: W,
|
|
17
|
+
admonitionAttention: x,
|
|
18
|
+
admonitionCaution: L,
|
|
19
|
+
admonitionWarning: P,
|
|
20
|
+
admonitionNeutral: w
|
|
16
21
|
}, y = {
|
|
17
22
|
note: "Note",
|
|
18
23
|
tip: "Tip",
|
|
19
|
-
|
|
24
|
+
attention: "Attention",
|
|
20
25
|
caution: "Caution",
|
|
21
26
|
warning: "Warning"
|
|
22
|
-
},
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
}, H = {
|
|
28
|
+
note: "fa-regular fa-note",
|
|
29
|
+
tip: "fa-regular fa-circle-info",
|
|
30
|
+
attention: "fa-solid fa-triangle-exclamation",
|
|
31
|
+
caution: "fa-solid fa-circle-exclamation",
|
|
32
|
+
warning: "fa-solid fa-octagon-exclamation"
|
|
33
|
+
}, z = (o) => {
|
|
34
|
+
const a = o.trim().replace(/[_-]+/g, " ");
|
|
35
|
+
return a ? a.split(/\s+/).map((i) => `${i.charAt(0).toUpperCase()}${i.slice(1).toLowerCase()}`).join(" ") : "Admonition";
|
|
36
|
+
}, E = (o) => o === "note" ? n.admonitionNote : o === "tip" ? n.admonitionTip : o === "attention" ? n.admonitionAttention : o === "caution" ? n.admonitionCaution : o === "warning" ? n.admonitionWarning : n.admonitionNeutral;
|
|
37
|
+
function $({
|
|
38
|
+
admonitionType: o,
|
|
39
|
+
variant: a,
|
|
29
40
|
icon: i,
|
|
30
|
-
title:
|
|
31
|
-
className:
|
|
32
|
-
children:
|
|
33
|
-
...
|
|
41
|
+
title: c,
|
|
42
|
+
className: r,
|
|
43
|
+
children: m,
|
|
44
|
+
...l
|
|
34
45
|
}) {
|
|
35
|
-
const
|
|
36
|
-
return /* @__PURE__ */
|
|
37
|
-
/* @__PURE__ */
|
|
38
|
-
|
|
39
|
-
/* @__PURE__ */
|
|
40
|
-
|
|
41
|
-
|
|
46
|
+
const _ = c ?? y[o] ?? z(o), u = E(a), e = i === !1 ? void 0 : (i == null ? void 0 : i.trim()) || H[a];
|
|
47
|
+
return /* @__PURE__ */ d("aside", { ...l, className: s(n.admonition, u, r), "data-admonition": o, children: [
|
|
48
|
+
/* @__PURE__ */ t("span", { className: n.admonitionBorderLeft, "aria-hidden": "true" }),
|
|
49
|
+
/* @__PURE__ */ d("div", { className: s(n.admonitionPanel, e && n.admonitionWithIcon), children: [
|
|
50
|
+
e ? /* @__PURE__ */ t("span", { className: n.admonitionIcon, "aria-hidden": "true", children: /* @__PURE__ */ t(f, { iconKey: e, size: "md" }, e) }) : null,
|
|
51
|
+
/* @__PURE__ */ d("div", { className: n.admonitionContent, children: [
|
|
52
|
+
/* @__PURE__ */ t("div", { className: n.admonitionHeader, children: /* @__PURE__ */ t(j, { size: "md", weight: "semibold", className: n.admonitionTitle, children: _ }) }),
|
|
53
|
+
m != null ? /* @__PURE__ */ t("div", { className: n.admonitionBody, children: m }) : null
|
|
54
|
+
] })
|
|
55
|
+
] })
|
|
42
56
|
] });
|
|
43
57
|
}
|
|
44
58
|
export {
|
|
45
|
-
|
|
59
|
+
$ as Admonition
|
|
46
60
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { Meta, StoryObj } from '@storybook/react-vite';
|
|
2
2
|
type DemoArgs = {
|
|
3
3
|
admonitionType: string;
|
|
4
|
-
variant: "note" | "tip" | "
|
|
4
|
+
variant: "note" | "tip" | "attention" | "caution" | "warning" | "unknown";
|
|
5
5
|
title?: string;
|
|
6
|
-
icon?: string;
|
|
6
|
+
icon?: string | false;
|
|
7
7
|
body: string;
|
|
8
8
|
};
|
|
9
9
|
declare const meta: Meta<DemoArgs>;
|
|
@@ -11,3 +11,5 @@ export default meta;
|
|
|
11
11
|
type Story = StoryObj<DemoArgs>;
|
|
12
12
|
export declare const Playground: Story;
|
|
13
13
|
export declare const UnknownType: Story;
|
|
14
|
+
export declare const DefaultIcon: Story;
|
|
15
|
+
export declare const WithoutIcon: Story;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
|
2
2
|
import { Admonition as o } from "./Admonition.js";
|
|
3
|
-
const
|
|
3
|
+
const a = {
|
|
4
4
|
title: "Case Parts/Molecules/Admonition",
|
|
5
5
|
component: o,
|
|
6
6
|
tags: ["autodocs"],
|
|
@@ -11,7 +11,7 @@ const r = {
|
|
|
11
11
|
admonitionType: { control: "text" },
|
|
12
12
|
variant: {
|
|
13
13
|
control: { type: "radio" },
|
|
14
|
-
options: ["note", "tip", "
|
|
14
|
+
options: ["note", "tip", "attention", "caution", "warning", "unknown"]
|
|
15
15
|
},
|
|
16
16
|
title: { control: "text" },
|
|
17
17
|
icon: { control: "text" },
|
|
@@ -21,10 +21,9 @@ const r = {
|
|
|
21
21
|
admonitionType: "warning",
|
|
22
22
|
variant: "warning",
|
|
23
23
|
title: "Electrical Hazard",
|
|
24
|
-
icon: "fa-solid fa-bolt",
|
|
25
24
|
body: "Disconnect power before servicing this unit."
|
|
26
25
|
}
|
|
27
|
-
},
|
|
26
|
+
}, r = {
|
|
28
27
|
render: (t) => /* @__PURE__ */ n("div", { style: { width: 640 }, children: /* @__PURE__ */ n(
|
|
29
28
|
o,
|
|
30
29
|
{
|
|
@@ -35,7 +34,7 @@ const r = {
|
|
|
35
34
|
children: /* @__PURE__ */ n("p", { children: t.body })
|
|
36
35
|
}
|
|
37
36
|
) })
|
|
38
|
-
},
|
|
37
|
+
}, c = {
|
|
39
38
|
args: {
|
|
40
39
|
admonitionType: "custom-alert",
|
|
41
40
|
variant: "unknown",
|
|
@@ -43,9 +42,24 @@ const r = {
|
|
|
43
42
|
icon: "info",
|
|
44
43
|
body: "This renders neutral styling while preserving the custom type."
|
|
45
44
|
}
|
|
45
|
+
}, l = {
|
|
46
|
+
args: {
|
|
47
|
+
admonitionType: "attention",
|
|
48
|
+
variant: "attention",
|
|
49
|
+
body: "This uses the attention default icon."
|
|
50
|
+
}
|
|
51
|
+
}, s = {
|
|
52
|
+
args: {
|
|
53
|
+
admonitionType: "note",
|
|
54
|
+
variant: "note",
|
|
55
|
+
icon: !1,
|
|
56
|
+
body: "This omits the default icon."
|
|
57
|
+
}
|
|
46
58
|
};
|
|
47
59
|
export {
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
60
|
+
l as DefaultIcon,
|
|
61
|
+
r as Playground,
|
|
62
|
+
c as UnknownType,
|
|
63
|
+
s as WithoutIcon,
|
|
64
|
+
a as default
|
|
51
65
|
};
|