@alphacifer/slidev-addon-theme 0.0.10 → 0.0.11
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/README.md +133 -75
- package/components/card/chevron-card/ChevronCard.vue +44 -32
- package/components/card/chevron-card/ChevronCardBadge.vue +14 -8
- package/components/card/chevron-card/ChevronCardContent.vue +15 -13
- package/components/card/chevron-card/style.css +12 -0
- package/components/card/{horiz-card/HorizCard.vue → horizontal-card/HorizontalCard.vue} +78 -85
- package/components/card/{horiz-card/HorizCardBadge.vue → horizontal-card/HorizontalCardBadge.vue} +15 -10
- package/components/card/{horiz-card/HorizCardContent.vue → horizontal-card/HorizontalCardContent.vue} +11 -11
- package/components/card/{horiz-card/HorizCardIcon.vue → horizontal-card/HorizontalCardIcon.vue} +24 -38
- package/components/card/horizontal-card/style.css +17 -0
- package/components/card/{vert-card/VertCard.vue → vertical-card/VerticalCard.vue} +80 -103
- package/components/card/{vert-card/VertCardBadge.vue → vertical-card/VerticalCardBadge.vue} +15 -10
- package/components/card/{vert-card/VertCardContent.vue → vertical-card/VerticalCardContent.vue} +13 -12
- package/components/card/{vert-card/VertCardIcon.vue → vertical-card/VerticalCardIcon.vue} +15 -33
- package/components/card/vertical-card/style.css +19 -0
- package/components/comparisons/arc-comparison/ArcComparison.vue +376 -80
- package/components/comparisons/arc-comparison/ArcComparisonBadge.vue +9 -4
- package/components/comparisons/arc-comparison/ArcComparisonContent.vue +9 -4
- package/components/comparisons/arc-comparison/ArcComparisonHeading.vue +9 -4
- package/components/comparisons/arc-comparison/ArcComparisonLeft.vue +39 -63
- package/components/comparisons/arc-comparison/ArcComparisonOrbit.vue +9 -8
- package/components/comparisons/arc-comparison/ArcComparisonRight.vue +39 -63
- package/components/comparisons/arc-comparison/style.css +27 -0
- package/components/comparisons/table-comparison/TableComparison.vue +17 -97
- package/components/comparisons/table-comparison/TableComparisonCell.vue +22 -20
- package/components/comparisons/table-comparison/{TableComparisonCol.vue → TableComparisonColumn.vue} +16 -14
- package/components/comparisons/table-comparison/{TableComparisonCols.vue → TableComparisonColumns.vue} +5 -8
- package/components/comparisons/table-comparison/TableComparisonRow.vue +10 -14
- package/components/comparisons/table-comparison/TableComparisonRows.vue +1 -4
- package/components/comparisons/table-comparison/style.css +15 -0
- package/components/core/Date.vue +2 -5
- package/components/core/QnA.vue +1 -1
- package/components/core/Quote.vue +3 -6
- package/components/core/ReflectedTitle.vue +2 -6
- package/components/core/Speaker.vue +5 -10
- package/components/core/TransitionHeading.vue +2 -5
- package/components/core/arc-orbit/ArcOrbit.vue +65 -84
- package/components/core/arc-orbit/ArcOrbitBadge.vue +9 -11
- package/components/core/arc-orbit/ArcOrbitCallout.vue +30 -32
- package/components/core/arc-orbit/ArcOrbitContent.vue +6 -12
- package/components/core/arc-orbit/ArcOrbitHeading.vue +13 -11
- package/components/core/arc-orbit/style.css +20 -0
- package/components/core/style.css +9 -0
- package/components/core/thanks/{ThanksContent.vue → SquareThanks.vue} +36 -31
- package/components/core/thanks/SquareThanksContent.vue +89 -0
- package/components/core/thanks/ThanksOutlineSquare.vue +2 -5
- package/components/core/thanks/ThanksSquare.vue +2 -5
- package/components/core/thanks/style.css +30 -0
- package/components/defense-in-depth/{arc-did/ArcDiD.vue → arc-defense-in-depth/ArcDefenseInDepth.vue} +167 -97
- package/components/defense-in-depth/arc-defense-in-depth/ArcDefenseInDepthLayer.vue +240 -0
- package/components/defense-in-depth/{arc-did/ArcDiDLayerTitle.vue → arc-defense-in-depth/ArcDefenseInDepthLayerHeading.vue} +27 -29
- package/components/defense-in-depth/{arc-did/ArcDiDLayerPart.vue → arc-defense-in-depth/ArcDefenseInDepthLayerPart.vue} +91 -39
- package/components/defense-in-depth/{arc-did/ArcDiDLayerSector.vue → arc-defense-in-depth/ArcDefenseInDepthLayerSector.vue} +37 -23
- package/components/defense-in-depth/arc-defense-in-depth/style.css +38 -0
- package/components/facets/tetrad/{rect-orbit-tetrad/RectOrbitTetrad.vue → rectangle-orbit-tetrad/RectangleOrbitTetrad.vue} +66 -63
- package/components/facets/tetrad/{rect-orbit-tetrad/RectOrbitTetradCallout.vue → rectangle-orbit-tetrad/RectangleOrbitTetradCallout.vue} +62 -48
- package/components/facets/tetrad/rectangle-orbit-tetrad/RectangleOrbitTetradCenter.vue +54 -0
- package/components/facets/tetrad/rectangle-orbit-tetrad/RectangleOrbitTetradContent.vue +44 -0
- package/components/facets/tetrad/rectangle-orbit-tetrad/RectangleOrbitTetradHeading.vue +27 -0
- package/components/facets/tetrad/{rect-orbit-tetrad/RectOrbitTetradIcon.vue → rectangle-orbit-tetrad/RectangleOrbitTetradIcon.vue} +23 -13
- package/components/facets/tetrad/rectangle-orbit-tetrad/style.css +22 -0
- package/components/facets/triad/arrow-triad/ArrowTriad.vue +99 -109
- package/components/facets/triad/arrow-triad/ArrowTriadCallout.vue +31 -59
- package/components/facets/triad/arrow-triad/ArrowTriadContent.vue +18 -13
- package/components/facets/triad/arrow-triad/ArrowTriadHeading.vue +20 -13
- package/components/facets/triad/arrow-triad/ArrowTriadIcon.vue +14 -9
- package/components/facets/triad/arrow-triad/style.css +15 -0
- package/components/facets/triad/gear-triad/GearTriad.vue +73 -64
- package/components/facets/triad/gear-triad/GearTriadCallout.vue +58 -53
- package/components/facets/triad/gear-triad/GearTriadCenter.vue +9 -4
- package/components/facets/triad/gear-triad/GearTriadContent.vue +21 -36
- package/components/facets/triad/gear-triad/GearTriadDetail.vue +92 -0
- package/components/facets/triad/gear-triad/GearTriadDetails.vue +169 -0
- package/components/facets/triad/gear-triad/GearTriadDetailsContent.vue +18 -0
- package/components/facets/triad/gear-triad/GearTriadDetailsHeading.vue +60 -0
- package/components/facets/triad/gear-triad/GearTriadHeading.vue +19 -13
- package/components/facets/triad/gear-triad/GearTriadIcon.vue +22 -9
- package/components/facets/triad/gear-triad/style.css +26 -0
- package/components/facets/triad/{hex-triad/HexTriad.vue → hexagon-triad/HexagonTriad.vue} +81 -63
- package/components/facets/triad/{hex-triad/HexTriadBadge.vue → hexagon-triad/HexagonTriadBadge.vue} +38 -12
- package/components/facets/triad/{hex-triad/HexTriadCallout.vue → hexagon-triad/HexagonTriadCallout.vue} +35 -31
- package/components/facets/triad/hexagon-triad/HexagonTriadCenterBadge.vue +74 -0
- package/components/facets/triad/hexagon-triad/HexagonTriadContent.vue +34 -0
- package/components/facets/triad/hexagon-triad/HexagonTriadHeading.vue +44 -0
- package/components/facets/triad/{hex-triad/HexTriadLayer.vue → hexagon-triad/HexagonTriadLayer.vue} +12 -4
- package/components/facets/triad/hexagon-triad/style.css +22 -0
- package/components/process/arc-arrow-process/ArcArrowProcess.vue +13 -35
- package/components/process/arc-arrow-process/ArcArrowProcessArrow.vue +20 -21
- package/components/process/arc-arrow-process/ArcArrowProcessCallout.vue +30 -71
- package/components/process/arc-arrow-process/ArcArrowProcessContent.vue +18 -13
- package/components/process/arc-arrow-process/ArcArrowProcessHeading.vue +18 -18
- package/components/process/arc-arrow-process/ArcArrowProcessIcon.vue +23 -11
- package/components/process/arc-arrow-process/style.css +20 -0
- package/components/pyramid/circular-pyramid/CircularPyramid.vue +269 -170
- package/components/pyramid/circular-pyramid/CircularPyramidStack.vue +70 -52
- package/components/pyramid/circular-pyramid/CircularPyramidStackContent.vue +47 -37
- package/components/pyramid/circular-pyramid/{CircularPyramidStackTitle.vue → CircularPyramidStackHeading.vue} +49 -45
- package/components/pyramid/circular-pyramid/style.css +26 -0
- package/components/pyramid/square-pyramid/SquarePyramid.vue +191 -62
- package/components/pyramid/square-pyramid/SquarePyramidStack.vue +74 -49
- package/components/pyramid/square-pyramid/SquarePyramidStackContent.vue +47 -33
- package/components/pyramid/square-pyramid/{SquarePyramidStackTitle.vue → SquarePyramidStackHeading.vue} +49 -41
- package/components/pyramid/square-pyramid/style.css +48 -0
- package/components/style.css +35 -0
- package/layouts/core/arc-toc.vue +40 -45
- package/layouts/core/bg-center.vue +7 -6
- package/layouts/core/style.css +17 -0
- package/layouts/shifting-heading/shifting-intro.vue +4 -13
- package/layouts/thanks/thanks.vue +5 -5
- package/package.json +8 -6
- package/style.css +17 -0
- package/uno.config.ts +1 -0
- package/utils/activateOnKeyboard.ts +14 -0
- package/utils/{chevronCard → card/chevron-card}/context.ts +1 -1
- package/utils/card/chevron-card/index.ts +1 -0
- package/utils/card/horizontal-card/context.ts +12 -0
- package/utils/{horizCard/createHorizCardGeometry.ts → card/horizontal-card/createHorizontalCardGeometry.ts} +10 -45
- package/utils/card/horizontal-card/index.ts +2 -0
- package/utils/card/vertical-card/context.ts +19 -0
- package/utils/{vertCard/createVertCardGeometry.ts → card/vertical-card/createVerticalCardGeometry.ts} +9 -130
- package/utils/card/vertical-card/index.ts +2 -0
- package/utils/colors.ts +93 -0
- package/utils/{arcComparison → comparisons/arc-comparison}/context.ts +0 -11
- package/utils/{arcComparison → comparisons/arc-comparison}/createArcComparisonGeometry.ts +1 -1
- package/utils/comparisons/arc-comparison/resolveArcComparisonItems.ts +33 -0
- package/utils/comparisons/table-comparison/constants.ts +47 -0
- package/utils/{tableComparison → comparisons/table-comparison}/context.ts +2 -2
- package/utils/{arcOrbit → core/arc-orbit}/resolveArcOrbitItems.ts +11 -15
- package/utils/{defenseInDepth/arcDid → defense-in-depth/arc-defense-in-depth}/context.ts +34 -31
- package/utils/{defenseInDepth/arcDid/createArcDiDGeometry.ts → defense-in-depth/arc-defense-in-depth/createArcDefenseInDepthGeometry.ts} +69 -39
- package/utils/{defenseInDepth/arcDid → defense-in-depth/arc-defense-in-depth}/types.ts +39 -35
- package/utils/defense-in-depth/shared/colors.ts +51 -0
- package/utils/defense-in-depth/shared/constants.ts +22 -0
- package/utils/{defenseInDepth → defense-in-depth}/shared/types.ts +0 -5
- package/utils/facets/tetrad/rectangle-orbit-tetrad/context.ts +31 -0
- package/utils/{rectOrbitTetrad/createRectOrbitTetradGeometry.ts → facets/tetrad/rectangle-orbit-tetrad/createRectangleOrbitTetradGeometry.ts} +5 -104
- package/utils/facets/tetrad/rectangle-orbit-tetrad/index.ts +3 -0
- package/utils/{rectOrbitTetrad/resolveRectOrbitTetradItems.ts → facets/tetrad/rectangle-orbit-tetrad/resolveRectangleOrbitTetradItems.ts} +41 -49
- package/utils/{arrowTriad → facets/triad/arrow-triad}/resolveArrowTriadItems.ts +27 -28
- package/utils/{gearTriad → facets/triad/gear-triad}/context.ts +5 -5
- package/utils/{gearTriad → facets/triad/gear-triad}/createGearTriadGeometry.ts +2 -0
- package/utils/{gearTriad → facets/triad/gear-triad}/resolveGearTriadItems.ts +23 -24
- package/utils/facets/triad/hexagon-triad/context.ts +25 -0
- package/utils/{hexTriad/createHexTriadGeometry.ts → facets/triad/hexagon-triad/createHexagonTriadGeometry.ts} +11 -27
- package/utils/facets/triad/hexagon-triad/index.ts +3 -0
- package/utils/facets/triad/hexagon-triad/resolveHexagonTriadItems.ts +60 -0
- package/utils/{shiftingHeading → layouts/shifting-heading}/collectShiftingIntroNodes.ts +1 -0
- package/utils/layouts/table-of-contents/calculateTocCenterAlignmentOffset.ts +17 -0
- package/utils/{tableOfContents → layouts/table-of-contents}/calculateTocMarkerPositions.ts +0 -12
- package/utils/{tableOfContents → layouts/table-of-contents}/createTocConnectorPath.ts +11 -5
- package/utils/{mergeUno → merge-uno}/classifyVisual.ts +1 -1
- package/utils/{mergeUno → merge-uno}/collectClassNames.ts +9 -3
- package/utils/process/arc-arrow-process/resolveArcArrowProcessItems.ts +180 -0
- package/utils/pyramid/circular-pyramid/context.ts +1 -4
- package/utils/pyramid/circular-pyramid/createCircularPyramidGeometry.ts +6 -10
- package/utils/pyramid/shared/colors.ts +33 -83
- package/utils/pyramid/shared/constants.ts +2 -2
- package/utils/pyramid/shared/types.ts +0 -5
- package/utils/pyramid/square-pyramid/context.ts +1 -4
- package/utils/pyramid/square-pyramid/createSquarePyramidGeometry.ts +6 -10
- package/utils/useDiagramAutoScale.ts +8 -6
- package/utils/useMergedUnoAttrs.ts +9 -5
- package/components/card/chevron-card/ChevronCardHeading.vue +0 -39
- package/components/card/horiz-card/HorizCardHeading.vue +0 -47
- package/components/card/vert-card/VertCardHeading.vue +0 -68
- package/components/card/vert-card/VertCardTitle.vue +0 -76
- package/components/comparisons/arc-comparison/ArcComparisonContents.vue +0 -17
- package/components/comparisons/arc-comparison/ArcComparisonTitle.vue +0 -29
- package/components/core/arc-orbit/ArcOrbitContents.vue +0 -18
- package/components/core/arc-orbit/ArcOrbitTitle.vue +0 -50
- package/components/defense-in-depth/arc-did/ArcDiDLayer.vue +0 -321
- package/components/defense-in-depth/arc-did/ArcDiDLayerParts.vue +0 -11
- package/components/facets/tetrad/rect-orbit-tetrad/RectOrbitTetradCenter.vue +0 -53
- package/components/facets/tetrad/rect-orbit-tetrad/RectOrbitTetradContent.vue +0 -39
- package/components/facets/tetrad/rect-orbit-tetrad/RectOrbitTetradHeading.vue +0 -44
- package/components/facets/triad/gear-triad/GearTriadContents.vue +0 -111
- package/components/facets/triad/gear-triad/GearTriadDescription.vue +0 -38
- package/components/facets/triad/hex-triad/HexTriadCenterBadge.vue +0 -51
- package/components/facets/triad/hex-triad/HexTriadContent.vue +0 -20
- package/components/facets/triad/hex-triad/HexTriadHeading.vue +0 -28
- package/layouts/core/table-of-contents.vue +0 -30
- package/utils/arcArrowProcess/resolveArcArrowProcessItems.ts +0 -189
- package/utils/arcComparison/resolveArcComparisonItems.ts +0 -102
- package/utils/chevronCard/createChevronCardGeometry.ts +0 -48
- package/utils/chevronCard/index.ts +0 -2
- package/utils/defenseInDepth/arcDid/index.ts +0 -3
- package/utils/defenseInDepth/index.ts +0 -2
- package/utils/defenseInDepth/shared/colors.ts +0 -121
- package/utils/defenseInDepth/shared/constants.ts +0 -14
- package/utils/defenseInDepth/shared/index.ts +0 -3
- package/utils/hexTriad/context.ts +0 -25
- package/utils/hexTriad/index.ts +0 -3
- package/utils/hexTriad/resolveHexTriadItems.ts +0 -63
- package/utils/horizCard/context.ts +0 -13
- package/utils/horizCard/index.ts +0 -2
- package/utils/pyramid/index.ts +0 -3
- package/utils/rectOrbitTetrad/context.ts +0 -31
- package/utils/rectOrbitTetrad/index.ts +0 -3
- package/utils/tableComparison/constants.ts +0 -72
- package/utils/tableOfContents/calculateTocCenterAlignmentOffset.ts +0 -11
- package/utils/vertCard/context.ts +0 -18
- package/utils/vertCard/index.ts +0 -2
- package/utils/{arcComparison → comparisons/arc-comparison}/index.ts +0 -0
- package/utils/{tableComparison → comparisons/table-comparison}/index.ts +0 -0
- package/utils/{arcOrbit → core/arc-orbit}/context.ts +0 -0
- package/utils/{arcOrbit → core/arc-orbit}/createArcOrbitGeometry.ts +0 -0
- package/utils/{arcOrbit → core/arc-orbit}/index.ts +0 -0
- package/utils/{arrowTriad → facets/triad/arrow-triad}/context.ts +0 -0
- package/utils/{arrowTriad → facets/triad/arrow-triad}/createArrowTriadGeometry.ts +0 -0
- package/utils/{arrowTriad → facets/triad/arrow-triad}/index.ts +0 -0
- package/utils/{gearTriad → facets/triad/gear-triad}/index.ts +0 -0
- package/utils/{tableOfContents → layouts/table-of-contents}/calculateUniformTocArticleWidth.ts +0 -0
- package/utils/{tableOfContents → layouts/table-of-contents}/createTocArcPath.ts +0 -0
- package/utils/{tableOfContents → layouts/table-of-contents}/index.ts +0 -0
- package/utils/{mergeUno → merge-uno}/classifyLayout.ts +0 -0
- package/utils/{mergeUno → merge-uno}/classifySimple.ts +0 -0
- package/utils/{mergeUno → merge-uno}/classifyTypography.ts +0 -0
- package/utils/{mergeUno → merge-uno}/classifyUtility.ts +0 -0
- package/utils/{mergeUno → merge-uno}/index.ts +0 -0
- package/utils/{mergeUno → merge-uno}/mergeClassValues.ts +0 -0
- package/utils/{mergeUno → merge-uno}/splitVariantScope.ts +1 -1
- package/utils/{mergeUno → merge-uno}/types.ts +0 -0
- package/utils/{arcArrowProcess → process/arc-arrow-process}/context.ts +1 -1
- /package/utils/{arcArrowProcess → process/arc-arrow-process}/createArcArrowProcessGeometry.ts +0 -0
- /package/utils/{arcArrowProcess → process/arc-arrow-process}/index.ts +0 -0
|
@@ -5,33 +5,29 @@ import {
|
|
|
5
5
|
Fragment,
|
|
6
6
|
provide,
|
|
7
7
|
useSlots,
|
|
8
|
+
isVNode,
|
|
8
9
|
type VNode,
|
|
9
10
|
} from 'vue';
|
|
10
11
|
|
|
11
12
|
import { useMergedUnoAttrs } from '../../../utils/useMergedUnoAttrs';
|
|
12
13
|
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
type TVertCardBadgeVariant,
|
|
14
|
+
createVerticalCardBottomBlobPath,
|
|
15
|
+
createVerticalCardTopRightBlobPath,
|
|
16
|
+
type TVerticalCardBadgeVariant,
|
|
17
17
|
VERT_CARD_KEY,
|
|
18
|
-
} from '../../../utils/
|
|
18
|
+
} from '../../../utils/card/vertical-card';
|
|
19
19
|
|
|
20
20
|
defineOptions({
|
|
21
|
-
name: '
|
|
21
|
+
name: 'VerticalCard',
|
|
22
22
|
inheritAttrs: false,
|
|
23
23
|
});
|
|
24
24
|
|
|
25
|
-
export interface
|
|
25
|
+
export interface IVerticalCardProps {
|
|
26
26
|
readonly color?: string;
|
|
27
27
|
readonly dots?: boolean;
|
|
28
|
-
readonly title?: string;
|
|
28
|
+
readonly title?: string | VNode;
|
|
29
29
|
readonly cardBg?: string;
|
|
30
30
|
readonly textColor?: string;
|
|
31
|
-
readonly titleColor?: string;
|
|
32
|
-
readonly lightColor?: string;
|
|
33
|
-
readonly stripeColor?: string;
|
|
34
|
-
readonly description?: string;
|
|
35
31
|
readonly hasDivider?: boolean;
|
|
36
32
|
readonly step?: string | number;
|
|
37
33
|
readonly icon?: string | object;
|
|
@@ -42,24 +38,20 @@ export interface IVertCardProps {
|
|
|
42
38
|
* - 'inside': badge displayed inside the card body (future state)
|
|
43
39
|
* - 'none' | 'hidden': badge is completely hidden
|
|
44
40
|
*/
|
|
45
|
-
readonly variant?:
|
|
46
|
-
readonly badgeVariant?:
|
|
41
|
+
readonly variant?: TVerticalCardBadgeVariant;
|
|
42
|
+
readonly badgeVariant?: TVerticalCardBadgeVariant;
|
|
47
43
|
}
|
|
48
44
|
|
|
49
|
-
const props = withDefaults(defineProps<
|
|
45
|
+
const props = withDefaults(defineProps<IVerticalCardProps>(), {
|
|
50
46
|
dots: true,
|
|
51
47
|
step: '01',
|
|
52
48
|
icon: undefined,
|
|
53
49
|
hasDivider: true,
|
|
54
50
|
title: undefined,
|
|
55
|
-
color: '
|
|
56
|
-
cardBg: '
|
|
51
|
+
color: 'var(--alpha-vertical-card-accent)',
|
|
52
|
+
cardBg: 'var(--alpha-vertical-card-bg)',
|
|
57
53
|
variant: undefined,
|
|
58
54
|
textColor: undefined,
|
|
59
|
-
lightColor: undefined,
|
|
60
|
-
titleColor: undefined,
|
|
61
|
-
stripeColor: undefined,
|
|
62
|
-
description: undefined,
|
|
63
55
|
badgeVariant: 'outside',
|
|
64
56
|
hasIconCircle: undefined,
|
|
65
57
|
});
|
|
@@ -93,22 +85,15 @@ function flattenVNodes(nodes: VNode[]): VNode[] {
|
|
|
93
85
|
}
|
|
94
86
|
|
|
95
87
|
function isBadgeNode(node: VNode): boolean {
|
|
96
|
-
return hasComponentName(node.type, '
|
|
88
|
+
return hasComponentName(node.type, 'VerticalCardBadge');
|
|
97
89
|
}
|
|
98
90
|
|
|
99
91
|
function isIconNode(node: VNode): boolean {
|
|
100
|
-
return hasComponentName(node.type, '
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
function isTitleNode(node: VNode): boolean {
|
|
104
|
-
return (
|
|
105
|
-
hasComponentName(node.type, 'VertCardTitle') ||
|
|
106
|
-
hasComponentName(node.type, 'VertCardHeading')
|
|
107
|
-
);
|
|
92
|
+
return hasComponentName(node.type, 'VerticalCardIcon');
|
|
108
93
|
}
|
|
109
94
|
|
|
110
95
|
function isContentNode(node: VNode): boolean {
|
|
111
|
-
return hasComponentName(node.type, '
|
|
96
|
+
return hasComponentName(node.type, 'VerticalCardContent');
|
|
112
97
|
}
|
|
113
98
|
|
|
114
99
|
const defaultNodes = computed(() => {
|
|
@@ -127,58 +112,38 @@ const slottedIcon = computed(() => {
|
|
|
127
112
|
return defaultNodes.value.find(isIconNode);
|
|
128
113
|
});
|
|
129
114
|
|
|
130
|
-
const slottedTitle = computed(() => {
|
|
131
|
-
return defaultNodes.value.find(isTitleNode);
|
|
132
|
-
});
|
|
133
|
-
|
|
134
115
|
const slottedContent = computed(() => {
|
|
135
116
|
return defaultNodes.value.find(isContentNode);
|
|
136
117
|
});
|
|
137
118
|
|
|
138
119
|
const otherSlottedNodes = computed(() => {
|
|
139
120
|
return defaultNodes.value.filter((node) => {
|
|
140
|
-
return (
|
|
141
|
-
!isBadgeNode(node) &&
|
|
142
|
-
!isIconNode(node) &&
|
|
143
|
-
!isTitleNode(node) &&
|
|
144
|
-
!isContentNode(node)
|
|
145
|
-
);
|
|
121
|
+
return !isBadgeNode(node) && !isIconNode(node) && !isContentNode(node);
|
|
146
122
|
});
|
|
147
123
|
});
|
|
148
124
|
|
|
149
|
-
const
|
|
150
|
-
return props.color
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
const resolvedLightColor = computed(() => {
|
|
154
|
-
return (
|
|
155
|
-
props.lightColor ??
|
|
156
|
-
hexToRgba({
|
|
157
|
-
alpha: 0.16,
|
|
158
|
-
hex: props.color,
|
|
159
|
-
})
|
|
160
|
-
);
|
|
125
|
+
const customColor = computed(() => {
|
|
126
|
+
return props.color !== 'var(--alpha-vertical-card-accent)'
|
|
127
|
+
? props.color
|
|
128
|
+
: undefined;
|
|
161
129
|
});
|
|
162
130
|
|
|
163
|
-
const
|
|
164
|
-
return props.
|
|
131
|
+
const resolvedColor = computed(() => {
|
|
132
|
+
return props.color;
|
|
165
133
|
});
|
|
166
134
|
|
|
167
135
|
const resolvedStripeLightColor = computed(() => {
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
136
|
+
if (customColor.value) {
|
|
137
|
+
return `color-mix(in srgb, ${props.color} 55%, transparent)`;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
return `var(--alpha-vertical-card-stripe-light, color-mix(in srgb, ${props.color} 55%, transparent))`;
|
|
172
141
|
});
|
|
173
142
|
|
|
174
143
|
const resolvedCardBg = computed(() => {
|
|
175
144
|
return props.cardBg;
|
|
176
145
|
});
|
|
177
146
|
|
|
178
|
-
const resolvedTitleColor = computed(() => {
|
|
179
|
-
return props.titleColor ?? props.color;
|
|
180
|
-
});
|
|
181
|
-
|
|
182
147
|
const resolvedTextColor = computed(() => {
|
|
183
148
|
return props.textColor;
|
|
184
149
|
});
|
|
@@ -187,7 +152,7 @@ const resolvedStep = computed(() => {
|
|
|
187
152
|
return props.step;
|
|
188
153
|
});
|
|
189
154
|
|
|
190
|
-
const resolvedBadgeVariant = computed<
|
|
155
|
+
const resolvedBadgeVariant = computed<TVerticalCardBadgeVariant>(() => {
|
|
191
156
|
return props.variant ?? props.badgeVariant ?? 'outside';
|
|
192
157
|
});
|
|
193
158
|
|
|
@@ -204,21 +169,18 @@ const isBadgeOutside = computed(() => {
|
|
|
204
169
|
|
|
205
170
|
provide(VERT_CARD_KEY, {
|
|
206
171
|
step: resolvedStep,
|
|
207
|
-
color:
|
|
172
|
+
color: customColor as ComputedRef<string>,
|
|
208
173
|
cardBg: resolvedCardBg,
|
|
209
|
-
lightColor: resolvedLightColor,
|
|
210
|
-
titleColor: resolvedTitleColor,
|
|
211
174
|
badgeVariant: resolvedBadgeVariant,
|
|
212
|
-
stripeColor: resolvedStripeDarkColor,
|
|
213
175
|
hasDivider: computed(() => props.hasDivider),
|
|
214
|
-
textColor: resolvedTextColor
|
|
176
|
+
textColor: resolvedTextColor,
|
|
215
177
|
});
|
|
216
178
|
|
|
217
179
|
const BLOB_WIDTH = 128;
|
|
218
180
|
const BLOB_HEIGHT = 112;
|
|
219
181
|
|
|
220
182
|
const bottomBlobPath = computed(() => {
|
|
221
|
-
return
|
|
183
|
+
return createVerticalCardBottomBlobPath({
|
|
222
184
|
blobHeight: 96,
|
|
223
185
|
blobWidth: 128,
|
|
224
186
|
borderRadius: 21,
|
|
@@ -228,7 +190,7 @@ const bottomBlobPath = computed(() => {
|
|
|
228
190
|
});
|
|
229
191
|
|
|
230
192
|
const topRightInnerBlobPath = computed(() => {
|
|
231
|
-
return
|
|
193
|
+
return createVerticalCardTopRightBlobPath({
|
|
232
194
|
blobHeight: 96,
|
|
233
195
|
blobWidth: 128,
|
|
234
196
|
borderRadius: 21,
|
|
@@ -238,7 +200,7 @@ const topRightInnerBlobPath = computed(() => {
|
|
|
238
200
|
});
|
|
239
201
|
|
|
240
202
|
const topRightOuterBlobPath = computed(() => {
|
|
241
|
-
return
|
|
203
|
+
return createVerticalCardTopRightBlobPath({
|
|
242
204
|
blobHeight: 76,
|
|
243
205
|
blobWidth: 104,
|
|
244
206
|
borderRadius: 21,
|
|
@@ -257,7 +219,7 @@ const isIconActive = computed(() => {
|
|
|
257
219
|
});
|
|
258
220
|
|
|
259
221
|
const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
260
|
-
'alpha-
|
|
222
|
+
'alpha-vertical-card relative flex flex-col w-full h-full select-none rounded-3xl border-[2.75px] border-solid border-(--alpha-vertical-card-accent) bg-(--alpha-vertical-card-bg) font-sans',
|
|
261
223
|
);
|
|
262
224
|
</script>
|
|
263
225
|
|
|
@@ -266,8 +228,12 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
266
228
|
v-bind="forwardedAttrs()"
|
|
267
229
|
:class="className()"
|
|
268
230
|
:style="{
|
|
269
|
-
|
|
270
|
-
|
|
231
|
+
'--alpha-vertical-card-accent': customColor,
|
|
232
|
+
'--alpha-vertical-card-title': customColor,
|
|
233
|
+
'--alpha-vertical-card-bg':
|
|
234
|
+
props.cardBg !== 'var(--alpha-vertical-card-bg)'
|
|
235
|
+
? resolvedCardBg
|
|
236
|
+
: undefined,
|
|
271
237
|
}"
|
|
272
238
|
>
|
|
273
239
|
<!-- Clipped decorative accent layers (responsive and symmetrical in opposite corners) -->
|
|
@@ -276,45 +242,47 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
276
242
|
>
|
|
277
243
|
<!-- Bottom-left organic wave blob (kept as requested) -->
|
|
278
244
|
<svg
|
|
245
|
+
aria-hidden="true"
|
|
279
246
|
class="absolute bottom-0 left-0 w-32 h-28 pointer-events-none overflow-visible"
|
|
280
247
|
viewBox="0 0 128 112"
|
|
281
248
|
xmlns="http://www.w3.org/2000/svg"
|
|
282
249
|
>
|
|
283
250
|
<path
|
|
284
|
-
class="alpha-
|
|
251
|
+
class="alpha-vertical-card__blob"
|
|
285
252
|
:d="bottomBlobPath"
|
|
286
253
|
:fill="resolvedColor"
|
|
287
254
|
/>
|
|
288
255
|
</svg>
|
|
289
256
|
<!-- Top-right corner organic wave blob (symmetrical with bottom-left) -->
|
|
290
257
|
<svg
|
|
258
|
+
aria-hidden="true"
|
|
291
259
|
class="absolute top-0 right-0 w-32 h-28 pointer-events-none overflow-visible"
|
|
292
260
|
viewBox="0 0 128 112"
|
|
293
261
|
xmlns="http://www.w3.org/2000/svg"
|
|
294
262
|
>
|
|
295
263
|
<!-- Inner diagonal wave band (lighter tone) -->
|
|
296
264
|
<path
|
|
297
|
-
class="alpha-
|
|
265
|
+
class="alpha-vertical-card__blob-top-inner"
|
|
298
266
|
:d="topRightInnerBlobPath"
|
|
299
267
|
:fill="resolvedStripeLightColor"
|
|
300
268
|
/>
|
|
301
269
|
<!-- Outer diagonal wave accent (accent tone) -->
|
|
302
270
|
<path
|
|
303
|
-
class="alpha-
|
|
271
|
+
class="alpha-vertical-card__blob-top-outer"
|
|
304
272
|
:d="topRightOuterBlobPath"
|
|
305
|
-
:fill="
|
|
273
|
+
:fill="resolvedColor"
|
|
306
274
|
/>
|
|
307
275
|
</svg>
|
|
308
276
|
</div>
|
|
309
277
|
<!-- Ribbon Step Badge on left edge (pointing right into the card) -->
|
|
310
278
|
<div
|
|
311
279
|
v-if="isBadgeOutside && isBadgeVisible"
|
|
312
|
-
class="absolute -left-
|
|
313
|
-
:class="isIconActive ? 'top-
|
|
280
|
+
class="absolute -left-5 z-10"
|
|
281
|
+
:class="isIconActive ? 'top-18' : 'top-15'"
|
|
314
282
|
>
|
|
315
283
|
<slot name="badge">
|
|
316
284
|
<component :is="slottedBadge" v-if="slottedBadge" />
|
|
317
|
-
<
|
|
285
|
+
<VerticalCardBadge v-else :step="resolvedStep" :color="customColor" />
|
|
318
286
|
</slot>
|
|
319
287
|
</div>
|
|
320
288
|
<!-- Card Content Layer -->
|
|
@@ -323,14 +291,13 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
323
291
|
>
|
|
324
292
|
<!-- Optional Icon Circle (rendered when icon/slot is provided) -->
|
|
325
293
|
<template v-if="isIconActive">
|
|
326
|
-
<div class="flex items-center justify-center
|
|
294
|
+
<div class="flex items-center justify-center shrink-0 mb-3">
|
|
327
295
|
<slot name="icon">
|
|
328
296
|
<component :is="slottedIcon" v-if="slottedIcon" />
|
|
329
|
-
<
|
|
297
|
+
<VerticalCardIcon
|
|
330
298
|
v-else
|
|
331
299
|
:icon="props.icon"
|
|
332
|
-
:color="
|
|
333
|
-
:light-color="resolvedLightColor"
|
|
300
|
+
:color="customColor"
|
|
334
301
|
:size="108"
|
|
335
302
|
/>
|
|
336
303
|
</slot>
|
|
@@ -341,24 +308,31 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
341
308
|
class="flex flex-col items-center justify-center flex-1 w-full min-w-0"
|
|
342
309
|
:class="{ 'my-auto py-4': !isIconActive }"
|
|
343
310
|
>
|
|
344
|
-
<
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
311
|
+
<div
|
|
312
|
+
v-if="$slots.title || props.title != null"
|
|
313
|
+
class="flex flex-col items-center w-full"
|
|
314
|
+
>
|
|
315
|
+
<h3
|
|
316
|
+
class="alpha-vertical-card-title font-sans font-bold tracking-tight leading-tight text-center text-(--alpha-vertical-card-title)"
|
|
350
317
|
>
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
318
|
+
<slot v-if="$slots.title" name="title" />
|
|
319
|
+
<component :is="props.title" v-else-if="isVNode(props.title)" />
|
|
320
|
+
<template v-else-if="typeof props.title === 'string'">{{
|
|
321
|
+
props.title
|
|
322
|
+
}}</template>
|
|
323
|
+
</h3>
|
|
324
|
+
<div
|
|
325
|
+
v-if="props.hasDivider"
|
|
326
|
+
class="mt-2.5 flex items-center justify-center w-32 relative"
|
|
359
327
|
>
|
|
360
|
-
|
|
361
|
-
|
|
328
|
+
<div class="w-full h-[1.5px] bg-(--alpha-vertical-card-title)" />
|
|
329
|
+
<span
|
|
330
|
+
class="absolute w-2 h-2 rounded-full bg-(--alpha-vertical-card-title)"
|
|
331
|
+
/>
|
|
332
|
+
</div>
|
|
333
|
+
</div>
|
|
334
|
+
<slot name="content">
|
|
335
|
+
<component :is="slottedContent" v-if="slottedContent" />
|
|
362
336
|
</slot>
|
|
363
337
|
<!-- Any other custom slotted components -->
|
|
364
338
|
<component
|
|
@@ -368,7 +342,10 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
368
342
|
/>
|
|
369
343
|
</div>
|
|
370
344
|
<!-- Bottom Row: Centered Decorative Indicator Dots -->
|
|
371
|
-
<div
|
|
345
|
+
<div
|
|
346
|
+
v-if="props.dots"
|
|
347
|
+
class="flex justify-center items-center gap-2 pt-1"
|
|
348
|
+
>
|
|
372
349
|
<slot name="dots">
|
|
373
350
|
<span
|
|
374
351
|
class="w-2.5 h-2.5 rounded-full inline-block"
|
|
@@ -3,16 +3,16 @@ import { computed, inject } from 'vue';
|
|
|
3
3
|
|
|
4
4
|
import { useMergedUnoAttrs } from '../../../utils/useMergedUnoAttrs';
|
|
5
5
|
import {
|
|
6
|
-
|
|
6
|
+
createVerticalCardBadgePath,
|
|
7
7
|
VERT_CARD_KEY,
|
|
8
|
-
} from '../../../utils/
|
|
8
|
+
} from '../../../utils/card/vertical-card';
|
|
9
9
|
|
|
10
10
|
defineOptions({
|
|
11
11
|
inheritAttrs: false,
|
|
12
|
-
name: '
|
|
12
|
+
name: 'VerticalCardBadge',
|
|
13
13
|
});
|
|
14
14
|
|
|
15
|
-
export interface
|
|
15
|
+
export interface IVerticalCardBadgeProps {
|
|
16
16
|
/**
|
|
17
17
|
* Badge fill color. Overrides context color.
|
|
18
18
|
*/
|
|
@@ -23,7 +23,7 @@ export interface IVertCardBadgeProps {
|
|
|
23
23
|
readonly step?: string | number;
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
const props = withDefaults(defineProps<
|
|
26
|
+
const props = withDefaults(defineProps<IVerticalCardBadgeProps>(), {
|
|
27
27
|
step: undefined,
|
|
28
28
|
color: undefined,
|
|
29
29
|
});
|
|
@@ -31,14 +31,18 @@ const props = withDefaults(defineProps<IVertCardBadgeProps>(), {
|
|
|
31
31
|
const context = inject(VERT_CARD_KEY, undefined);
|
|
32
32
|
|
|
33
33
|
const resolvedColor = computed(() => {
|
|
34
|
-
return
|
|
34
|
+
return (
|
|
35
|
+
props.color ??
|
|
36
|
+
context?.color.value ??
|
|
37
|
+
'var(--alpha-vertical-card-badge-bg, var(--alpha-vertical-card-accent))'
|
|
38
|
+
);
|
|
35
39
|
});
|
|
36
40
|
|
|
37
41
|
const resolvedStep = computed(() => {
|
|
38
42
|
return props.step ?? context?.step.value ?? '01';
|
|
39
43
|
});
|
|
40
44
|
|
|
41
|
-
const badgePath =
|
|
45
|
+
const badgePath = createVerticalCardBadgePath({
|
|
42
46
|
width: 62,
|
|
43
47
|
height: 48,
|
|
44
48
|
tipRadius: 6,
|
|
@@ -48,14 +52,15 @@ const badgePath = createVertCardBadgePath({
|
|
|
48
52
|
});
|
|
49
53
|
|
|
50
54
|
const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
51
|
-
'alpha-
|
|
55
|
+
'alpha-vertical-card-badge inline-flex items-center justify-center select-none',
|
|
52
56
|
);
|
|
53
57
|
</script>
|
|
54
58
|
|
|
55
59
|
<template>
|
|
56
60
|
<div v-bind="forwardedAttrs()" :class="className()">
|
|
57
61
|
<svg
|
|
58
|
-
|
|
62
|
+
aria-hidden="true"
|
|
63
|
+
class="w-15.5 h-12 overflow-visible drop-shadow-sm"
|
|
59
64
|
viewBox="0 0 62 48"
|
|
60
65
|
xmlns="http://www.w3.org/2000/svg"
|
|
61
66
|
>
|
|
@@ -65,7 +70,7 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
65
70
|
y="24"
|
|
66
71
|
text-anchor="middle"
|
|
67
72
|
dominant-baseline="central"
|
|
68
|
-
fill="
|
|
73
|
+
fill="var(--alpha-vertical-card-badge)"
|
|
69
74
|
class="font-sans font-bold text-[20px] tracking-tight"
|
|
70
75
|
>
|
|
71
76
|
<slot>{{ resolvedStep }}</slot>
|
package/components/card/{vert-card/VertCardContent.vue → vertical-card/VerticalCardContent.vue}
RENAMED
|
@@ -2,21 +2,21 @@
|
|
|
2
2
|
import { computed, inject } from 'vue';
|
|
3
3
|
|
|
4
4
|
import { useMergedUnoAttrs } from '../../../utils/useMergedUnoAttrs';
|
|
5
|
-
import { VERT_CARD_KEY } from '../../../utils/
|
|
5
|
+
import { VERT_CARD_KEY } from '../../../utils/card/vertical-card';
|
|
6
6
|
|
|
7
7
|
defineOptions({
|
|
8
8
|
inheritAttrs: false,
|
|
9
|
-
name: '
|
|
9
|
+
name: 'VerticalCardContent',
|
|
10
10
|
});
|
|
11
11
|
|
|
12
|
-
export interface
|
|
12
|
+
export interface IVerticalCardContentProps {
|
|
13
13
|
/**
|
|
14
14
|
* Content text color. Overrides context textColor.
|
|
15
15
|
*/
|
|
16
16
|
readonly color?: string;
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
const props = withDefaults(defineProps<
|
|
19
|
+
const props = withDefaults(defineProps<IVerticalCardContentProps>(), {
|
|
20
20
|
color: undefined,
|
|
21
21
|
});
|
|
22
22
|
|
|
@@ -27,19 +27,20 @@ const contentColor = computed(() => {
|
|
|
27
27
|
});
|
|
28
28
|
|
|
29
29
|
const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
30
|
-
'alpha-
|
|
30
|
+
'alpha-vertical-card-content mt-3 px-2 font-sans leading-relaxed text-(--alpha-vertical-card-content) opacity-90 text-center',
|
|
31
31
|
);
|
|
32
32
|
</script>
|
|
33
33
|
|
|
34
34
|
<template>
|
|
35
|
-
<
|
|
35
|
+
<p
|
|
36
36
|
v-bind="forwardedAttrs()"
|
|
37
37
|
:class="className()"
|
|
38
|
-
:style="
|
|
38
|
+
:style="
|
|
39
|
+
contentColor && !contentColor.includes('--alpha-vertical-card-content')
|
|
40
|
+
? { '--alpha-vertical-card-content': contentColor }
|
|
41
|
+
: undefined
|
|
42
|
+
"
|
|
39
43
|
>
|
|
40
|
-
<slot
|
|
41
|
-
|
|
42
|
-
quis, lorem nunc. Suspendisse viverra sodales mauris, cras pharetra proin.
|
|
43
|
-
</slot>
|
|
44
|
-
</div>
|
|
44
|
+
<slot />
|
|
45
|
+
</p>
|
|
45
46
|
</template>
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
import { computed, inject } from 'vue';
|
|
3
3
|
|
|
4
4
|
import { useMergedUnoAttrs } from '../../../utils/useMergedUnoAttrs';
|
|
5
|
-
import {
|
|
5
|
+
import { VERT_CARD_KEY } from '../../../utils/card/vertical-card';
|
|
6
6
|
|
|
7
7
|
defineOptions({
|
|
8
8
|
inheritAttrs: false,
|
|
9
|
-
name: '
|
|
9
|
+
name: 'VerticalCardIcon',
|
|
10
10
|
});
|
|
11
11
|
|
|
12
|
-
export interface
|
|
12
|
+
export interface IVerticalCardIconProps {
|
|
13
13
|
/**
|
|
14
14
|
* Optional icon class (e.g. 'i-carbon-search') or component.
|
|
15
15
|
*/
|
|
@@ -18,10 +18,6 @@ export interface IVertCardIconProps {
|
|
|
18
18
|
* Foreground icon color. Overrides context color.
|
|
19
19
|
*/
|
|
20
20
|
readonly color?: string;
|
|
21
|
-
/**
|
|
22
|
-
* Circular background color. Overrides context lightColor.
|
|
23
|
-
*/
|
|
24
|
-
readonly lightColor?: string;
|
|
25
21
|
/**
|
|
26
22
|
* Circle size in pixels or CSS string.
|
|
27
23
|
* @default 108
|
|
@@ -29,32 +25,24 @@ export interface IVertCardIconProps {
|
|
|
29
25
|
readonly size?: number | string;
|
|
30
26
|
}
|
|
31
27
|
|
|
32
|
-
const props = withDefaults(defineProps<
|
|
28
|
+
const props = withDefaults(defineProps<IVerticalCardIconProps>(), {
|
|
33
29
|
size: 108,
|
|
34
30
|
icon: undefined,
|
|
35
31
|
color: undefined,
|
|
36
|
-
lightColor: undefined,
|
|
37
32
|
});
|
|
38
33
|
|
|
39
34
|
const context = inject(VERT_CARD_KEY, undefined);
|
|
40
35
|
|
|
41
|
-
const
|
|
42
|
-
return props.color ?? context?.color.value
|
|
36
|
+
const customColor = computed(() => {
|
|
37
|
+
return props.color ?? context?.color.value;
|
|
43
38
|
});
|
|
44
39
|
|
|
45
|
-
const
|
|
46
|
-
if (
|
|
47
|
-
return
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
if (context?.lightColor.value) {
|
|
51
|
-
return context.lightColor.value;
|
|
40
|
+
const customLightColor = computed(() => {
|
|
41
|
+
if (customColor.value) {
|
|
42
|
+
return `color-mix(in srgb, ${customColor.value} 16%, transparent)`;
|
|
52
43
|
}
|
|
53
44
|
|
|
54
|
-
return
|
|
55
|
-
alpha: 0.16,
|
|
56
|
-
hex: resolvedColor.value,
|
|
57
|
-
});
|
|
45
|
+
return undefined;
|
|
58
46
|
});
|
|
59
47
|
|
|
60
48
|
const resolvedSize = computed(() => {
|
|
@@ -71,7 +59,7 @@ const isComponentIcon = computed(() => {
|
|
|
71
59
|
});
|
|
72
60
|
|
|
73
61
|
const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
74
|
-
'alpha-
|
|
62
|
+
'alpha-vertical-card-icon rounded-full border-2 border-(--alpha-vertical-card-icon) bg-(--alpha-vertical-card-icon-bg) text-(--alpha-vertical-card-icon) flex items-center justify-center shrink-0 transition-transform duration-300 select-none',
|
|
75
63
|
);
|
|
76
64
|
</script>
|
|
77
65
|
|
|
@@ -82,26 +70,20 @@ const { className, forwardedAttrs } = useMergedUnoAttrs(
|
|
|
82
70
|
:style="{
|
|
83
71
|
width: resolvedSize,
|
|
84
72
|
height: resolvedSize,
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
color: resolvedColor,
|
|
73
|
+
'--alpha-vertical-card-icon-bg': customLightColor,
|
|
74
|
+
'--alpha-vertical-card-icon': customColor,
|
|
88
75
|
}"
|
|
89
76
|
>
|
|
90
77
|
<slot>
|
|
91
|
-
<component
|
|
92
|
-
:is="props.icon"
|
|
93
|
-
v-if="isComponentIcon"
|
|
94
|
-
class="text-4xl"
|
|
95
|
-
:style="{ color: resolvedColor }"
|
|
96
|
-
/>
|
|
78
|
+
<component :is="props.icon" v-if="isComponentIcon" class="text-4xl" />
|
|
97
79
|
<div
|
|
98
80
|
v-else-if="isStringIcon && props.icon !== 'default'"
|
|
99
81
|
:class="props.icon"
|
|
100
82
|
class="text-4xl"
|
|
101
|
-
:style="{ color: resolvedColor }"
|
|
102
83
|
/>
|
|
103
84
|
<!-- Default search icon matching the reference card -->
|
|
104
85
|
<svg
|
|
86
|
+
aria-hidden="true"
|
|
105
87
|
v-else
|
|
106
88
|
class="w-12 h-12"
|
|
107
89
|
viewBox="0 0 24 24"
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/* Color defaults shared by this component family. */
|
|
2
|
+
@layer alpha-theme-tokens {
|
|
3
|
+
:root {
|
|
4
|
+
--alpha-vertical-card-accent: #ea583a;
|
|
5
|
+
--alpha-vertical-card-badge: #ffffff;
|
|
6
|
+
/* Resolved from the component accent or props unless overridden. */
|
|
7
|
+
--alpha-vertical-card-badge-bg: var(--alpha-vertical-card-accent);
|
|
8
|
+
--alpha-vertical-card-bg: #ffffff;
|
|
9
|
+
--alpha-vertical-card-content: var(--alpha-foreground-primary, #475569);
|
|
10
|
+
/* Resolved from the component accent or props unless overridden. */
|
|
11
|
+
--alpha-vertical-card-title: var(--alpha-vertical-card-accent);
|
|
12
|
+
/* Resolved from the component accent or props unless overridden. */
|
|
13
|
+
--alpha-vertical-card-icon: var(--alpha-vertical-card-accent);
|
|
14
|
+
/* Resolved from the component accent or props unless overridden. */
|
|
15
|
+
--alpha-vertical-card-icon-bg: color-mix(in srgb, var(--alpha-vertical-card-accent) 18%, transparent);
|
|
16
|
+
/* Resolved from the component accent or props unless overridden. */
|
|
17
|
+
--alpha-vertical-card-stripe-light: color-mix(in srgb, var(--alpha-vertical-card-accent) 45%, transparent);
|
|
18
|
+
}
|
|
19
|
+
}
|