@astryxdesign/cli 0.1.1 → 0.1.2-canary.2149fa3
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/CHANGELOG.md +50 -0
- package/docs/theme.doc.mjs +2 -2
- package/docs/working-with-ai.doc.mjs +6 -6
- package/package.json +19 -8
- package/src/api/discover.mjs +78 -26
- package/src/api/index.mjs +1 -0
- package/src/api/layout.mjs +301 -0
- package/src/api/layout.test.mjs +238 -0
- package/src/api/template.mjs +191 -50
- package/src/api/template.test.mjs +2 -0
- package/src/api/theme-add.mjs +182 -0
- package/src/codemods/__tests__/registry.test.mjs +1 -0
- package/src/codemods/registry.mjs +1 -0
- package/src/codemods/transforms/v0.1.2/__tests__/rename-text-color-active-to-accent.test.mjs +120 -0
- package/src/codemods/transforms/v0.1.2/index.mjs +19 -0
- package/src/codemods/transforms/v0.1.2/rename-text-color-active-to-accent.mjs +136 -0
- package/src/commands/build-theme.import-path.test.mjs +22 -2
- package/src/commands/build-theme.mjs +185 -16
- package/src/commands/gap-report.mjs +17 -9
- package/src/commands/gap-report.test.mjs +21 -16
- package/src/commands/init.mjs +34 -8
- package/src/commands/init.next-steps.test.mjs +46 -0
- package/src/commands/layout.mjs +139 -0
- package/src/commands/swizzle.mjs +51 -23
- package/src/commands/upgrade.mjs +2 -71
- package/src/config.mjs +31 -0
- package/src/config.test.mjs +24 -0
- package/src/index.mjs +6 -0
- package/src/lib/config-schema.mjs +119 -0
- package/src/lib/config.mjs +34 -7
- package/src/lib/config.test.mjs +51 -2
- package/src/lib/error-codes.mjs +11 -0
- package/src/lib/integrations.mjs +155 -0
- package/src/lib/integrations.test.mjs +154 -0
- package/src/lib/levenshtein.mjs +29 -0
- package/src/lib/manifest.mjs +10 -0
- package/src/lib/package-scanner.mjs +31 -7
- package/src/lib/string-utils.mjs +5 -14
- package/src/lib/xle/browser.d.ts +100 -0
- package/src/lib/xle/browser.mjs +120 -0
- package/src/lib/xle/expand.mjs +622 -0
- package/src/lib/xle/parse.mjs +581 -0
- package/src/lib/xle/print.mjs +174 -0
- package/src/lib/xle/registry-core.mjs +170 -0
- package/src/lib/xle/registry.mjs +237 -0
- package/src/lib/xle/splice.mjs +137 -0
- package/src/lib/xle/validate.mjs +356 -0
- package/src/lib/xle/xle.test.mjs +333 -0
- package/src/types/config.d.ts +99 -0
- package/src/utils/github.mjs +12 -27
- package/templates/blocks/components/Card/ClickableCardWithNestedButton.doc.mjs +1 -1
- package/templates/blocks/components/Card/SelectableCardMulti.doc.mjs +1 -1
- package/templates/blocks/components/ChatComposerDrawer/ChatComposerDrawerWithProgress.tsx +1 -1
- package/templates/blocks/components/ChatDictationButton/ChatDictationButtonShowcase.tsx +3 -3
- package/templates/blocks/components/CommandPaletteEmpty/CommandPaletteEmptyShowcase.doc.mjs +15 -0
- package/templates/blocks/components/CommandPaletteEmpty/CommandPaletteEmptyShowcase.tsx +26 -0
- package/templates/blocks/components/DateInput/DateInputDateRange.doc.mjs +2 -2
- package/templates/blocks/components/FileInput/FileInputShowcase.tsx +4 -2
- package/templates/blocks/components/LinkProvider/LinkProviderCustomLink.doc.mjs +14 -0
- package/templates/blocks/components/LinkProvider/LinkProviderCustomLink.tsx +43 -0
- package/templates/blocks/components/MultiSelector/MultiSelectorShowcase.tsx +6 -2
- package/templates/blocks/components/NumberInput/NumberInputShowcase.tsx +6 -2
- package/templates/blocks/components/Outline/OutlineShowcase.doc.mjs +15 -0
- package/templates/blocks/components/Outline/OutlineShowcase.tsx +22 -0
- package/templates/blocks/components/RadioList/RadioListShowcase.tsx +8 -1
- package/templates/blocks/components/SegmentedControl/SegmentedControlShowcase.tsx +3 -1
- package/templates/blocks/components/Selector/SelectorShowcase.tsx +4 -1
- package/templates/blocks/components/Slider/SliderShowcase.tsx +10 -1
- package/templates/blocks/components/Tab/TabShowcase.tsx +3 -1
- package/templates/blocks/components/TabList/TabListShowcase.tsx +3 -1
- package/templates/blocks/components/TabMenu/TabMenuShowcase.tsx +3 -1
- package/templates/blocks/components/Table/ColumnResizeHookUsage.doc.mjs +14 -0
- package/templates/blocks/components/Table/ColumnResizeHookUsage.tsx +59 -0
- package/templates/blocks/components/Table/StickyColumnsHookUsage.doc.mjs +14 -0
- package/templates/blocks/components/Table/StickyColumnsHookUsage.tsx +104 -0
- package/templates/blocks/components/Text/TextColors.tsx +20 -5
- package/templates/blocks/components/TextArea/TextAreaShowcase.tsx +4 -2
- package/templates/blocks/components/TextInput/TextInputShowcase.tsx +4 -2
- package/templates/blocks/components/Thumbnail/ThumbnailDisabled.tsx +11 -6
- package/templates/blocks/components/Thumbnail/ThumbnailGallery.tsx +43 -7
- package/templates/blocks/components/Thumbnail/ThumbnailRemovable.tsx +40 -3
- package/templates/blocks/components/Thumbnail/ThumbnailShowcase.tsx +6 -5
- package/templates/blocks/components/Thumbnail/ThumbnailStates.tsx +11 -6
- package/templates/blocks/components/Timestamp/TimestampColors.tsx +2 -2
- package/templates/blocks/components/ToggleButton/ToggleButtonGroup.doc.mjs +1 -1
- package/templates/blocks/components/Tokenizer/TokenizerShowcase.tsx +8 -6
- package/templates/blocks/components/Toolbar/ToolbarTableFilter.doc.mjs +2 -2
- package/templates/blocks/components/Toolbar/ToolbarTableFilter.tsx +23 -14
- package/templates/blocks/components/Typeahead/TypeaheadShowcase.tsx +6 -2
- package/templates/pages/shell-nav/page.tsx +321 -0
- package/templates/pages/shell-nav/template.doc.mjs +12 -0
- package/templates/pages/shell-side-nav/page.tsx +242 -0
- package/templates/pages/shell-side-nav/template.doc.mjs +12 -0
- package/templates/pages/shell-top-nav/page.tsx +224 -0
- package/templates/pages/shell-top-nav/template.doc.mjs +12 -0
- package/templates/pages/theme-showcase/page.tsx +8 -19
- package/templates/themes/butter/butterTheme.ts +916 -0
- package/templates/themes/butter/icons.tsx +77 -0
- package/templates/themes/chocolate/chocolateTheme.ts +230 -0
- package/templates/themes/chocolate/icons.tsx +77 -0
- package/templates/themes/gothic/gothicTheme.ts +657 -0
- package/templates/themes/gothic/icons.tsx +77 -0
- package/templates/themes/manifest.json +90 -0
- package/templates/themes/matcha/icons.tsx +67 -0
- package/templates/themes/matcha/matchaTheme.ts +247 -0
- package/templates/themes/neutral/icons.tsx +77 -0
- package/templates/themes/neutral/neutralTheme.ts +603 -0
- package/templates/themes/stone/icons.tsx +77 -0
- package/templates/themes/stone/stoneTheme.ts +652 -0
- package/templates/themes/y2k/icons.tsx +67 -0
- package/templates/themes/y2k/y2kTheme.ts +617 -0
- package/templates/blocks/components/MoreMenu/MoreMenuInToolbar.doc.mjs +0 -14
- package/templates/blocks/components/MoreMenu/MoreMenuInToolbar.tsx +0 -57
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
// Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* @file icons.tsx
|
|
5
|
+
* @input Uses lucide-react icon components, IconRegistry type
|
|
6
|
+
* @output Exports stoneIconRegistry for the neutral theme
|
|
7
|
+
* @position Icon configuration for the neutral theme; consumed by index.ts
|
|
8
|
+
*
|
|
9
|
+
* Maps semantic icon names to Lucide icon components.
|
|
10
|
+
* These icons are bundled with the theme, not with @astryxdesign/core.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
import React from 'react';
|
|
14
|
+
import type {IconRegistry} from '@astryxdesign/core/Icon';
|
|
15
|
+
|
|
16
|
+
import {
|
|
17
|
+
X,
|
|
18
|
+
ChevronDown,
|
|
19
|
+
ChevronLeft,
|
|
20
|
+
ChevronRight,
|
|
21
|
+
Check,
|
|
22
|
+
CheckCircle,
|
|
23
|
+
XCircle,
|
|
24
|
+
AlertTriangle,
|
|
25
|
+
Info,
|
|
26
|
+
Calendar,
|
|
27
|
+
Clock,
|
|
28
|
+
ExternalLink,
|
|
29
|
+
Menu,
|
|
30
|
+
MoreHorizontal,
|
|
31
|
+
Search,
|
|
32
|
+
ArrowUp,
|
|
33
|
+
ArrowDown,
|
|
34
|
+
ArrowUpDown,
|
|
35
|
+
Filter,
|
|
36
|
+
EyeOff,
|
|
37
|
+
Columns,
|
|
38
|
+
Copy,
|
|
39
|
+
CheckCheck,
|
|
40
|
+
Wrench,
|
|
41
|
+
Square,
|
|
42
|
+
Mic,
|
|
43
|
+
} from 'lucide-react';
|
|
44
|
+
|
|
45
|
+
const iconProps = {
|
|
46
|
+
size: '1em',
|
|
47
|
+
'aria-hidden': true as const,
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
export const stoneIconRegistry: IconRegistry = {
|
|
51
|
+
close: <X {...iconProps} />,
|
|
52
|
+
chevronDown: <ChevronDown {...iconProps} />,
|
|
53
|
+
chevronLeft: <ChevronLeft {...iconProps} />,
|
|
54
|
+
chevronRight: <ChevronRight {...iconProps} />,
|
|
55
|
+
check: <Check {...iconProps} />,
|
|
56
|
+
success: <CheckCircle {...iconProps} />,
|
|
57
|
+
error: <XCircle {...iconProps} />,
|
|
58
|
+
warning: <AlertTriangle {...iconProps} />,
|
|
59
|
+
info: <Info {...iconProps} />,
|
|
60
|
+
calendar: <Calendar {...iconProps} />,
|
|
61
|
+
clock: <Clock {...iconProps} />,
|
|
62
|
+
externalLink: <ExternalLink {...iconProps} />,
|
|
63
|
+
menu: <Menu {...iconProps} />,
|
|
64
|
+
moreHorizontal: <MoreHorizontal {...iconProps} />,
|
|
65
|
+
search: <Search {...iconProps} />,
|
|
66
|
+
arrowUp: <ArrowUp {...iconProps} />,
|
|
67
|
+
arrowDown: <ArrowDown {...iconProps} />,
|
|
68
|
+
arrowsUpDown: <ArrowUpDown {...iconProps} />,
|
|
69
|
+
funnel: <Filter {...iconProps} />,
|
|
70
|
+
eyeSlash: <EyeOff {...iconProps} />,
|
|
71
|
+
viewColumns: <Columns {...iconProps} />,
|
|
72
|
+
copy: <Copy {...iconProps} />,
|
|
73
|
+
checkDouble: <CheckCheck {...iconProps} />,
|
|
74
|
+
wrench: <Wrench {...iconProps} />,
|
|
75
|
+
stop: <Square {...iconProps} />,
|
|
76
|
+
microphone: <Mic {...iconProps} />,
|
|
77
|
+
};
|