@astryxdesign/cli 0.1.0 → 0.1.1-canary.13763f6

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.
Files changed (141) hide show
  1. package/CHANGELOG.md +68 -0
  2. package/README.md +117 -75
  3. package/bin/astryx.mjs +22 -7
  4. package/docs/getting-started.doc.mjs +11 -11
  5. package/docs/icons.doc.mjs +1 -1
  6. package/docs/migration.doc.mjs +2 -2
  7. package/docs/shape.doc.mjs +1 -1
  8. package/docs/styling.doc.mjs +3 -4
  9. package/docs/theme.doc.dense.mjs +2 -2
  10. package/docs/theme.doc.mjs +14 -0
  11. package/docs/theme.doc.zh.mjs +2 -2
  12. package/docs/working-with-ai.doc.mjs +4 -4
  13. package/package.json +8 -8
  14. package/src/api/doctor.mjs +3 -3
  15. package/src/api/search.mjs +207 -13
  16. package/src/api/template.mjs +62 -11
  17. package/src/api/template.test.mjs +2 -0
  18. package/src/codemods/__tests__/registry.test.mjs +1 -0
  19. package/src/codemods/registry.mjs +1 -0
  20. package/src/codemods/runner.mjs +105 -51
  21. package/src/codemods/transforms/v0.1.0/__tests__/migrate-xds-config-surfaces.test.mjs +116 -0
  22. package/src/codemods/transforms/v0.1.0/__tests__/migrate-xds-module-specifiers.test.mjs +51 -0
  23. package/src/codemods/transforms/v0.1.0/index.mjs +28 -0
  24. package/src/codemods/transforms/v0.1.0/migrate-xds-config-surfaces.mjs +230 -0
  25. package/src/codemods/transforms/v0.1.0/migrate-xds-module-specifiers.mjs +84 -0
  26. package/src/commands/agent-docs.mjs +119 -66
  27. package/src/commands/agent-docs.path-safety.test.mjs +1 -1
  28. package/src/commands/agent-docs.test.mjs +87 -31
  29. package/src/commands/build-theme.import-path.test.mjs +1 -1
  30. package/src/commands/build-theme.path-safety.test.mjs +1 -1
  31. package/src/commands/build-theme.prose.test.mjs +1 -1
  32. package/src/commands/build.mjs +196 -0
  33. package/src/commands/component-package.test.mjs +1 -1
  34. package/src/commands/component.test.mjs +1 -1
  35. package/src/commands/docs.test.mjs +1 -1
  36. package/src/commands/doctor.test.mjs +1 -1
  37. package/src/commands/external-showcase.test.mjs +1 -1
  38. package/src/commands/init.mjs +10 -2
  39. package/src/commands/interactive-guard.test.mjs +1 -1
  40. package/src/commands/json-contract.test.mjs +10 -3
  41. package/src/commands/swizzle-gap-safety.test.mjs +1 -1
  42. package/src/commands/swizzle.path-safety.test.mjs +1 -1
  43. package/src/commands/template.path-safety.test.mjs +1 -1
  44. package/src/commands/template.test.mjs +1 -1
  45. package/src/commands/upgrade.mjs +353 -169
  46. package/src/commands/upgrade.test.mjs +41 -27
  47. package/src/index.mjs +1 -0
  48. package/src/lib/config.mjs +12 -0
  49. package/src/lib/config.test.mjs +42 -0
  50. package/src/lib/error-codes.mjs +3 -0
  51. package/src/types/error-codes.d.ts +1 -0
  52. package/src/utils/interactive.mjs +1 -1
  53. package/src/utils/interactive.test.mjs +2 -0
  54. package/src/utils/package-manager.mjs +1 -1
  55. package/src/utils/package-manager.test.mjs +1 -1
  56. package/src/utils/path-safety.test.mjs +1 -1
  57. package/src/utils/paths.test.mjs +8 -8
  58. package/src/utils/update-check.mjs +4 -26
  59. package/src/utils/update-check.test.mjs +2 -64
  60. package/templates/blocks/components/AppShell/AppShellContentOnly.tsx +1 -9
  61. package/templates/blocks/components/AppShell/AppShellShowcase.tsx +1 -10
  62. package/templates/blocks/components/AppShell/AppShellSideNavOnly.tsx +1 -9
  63. package/templates/blocks/components/AppShell/AppShellTopNavOnly.tsx +1 -9
  64. package/templates/blocks/components/AppShell/AppShellTopNavWithSideNav.tsx +1 -9
  65. package/templates/blocks/components/AppShell/AppShellWithBanner.tsx +1 -9
  66. package/templates/blocks/components/AspectRatio/AspectRatioShowcase.tsx +12 -19
  67. package/templates/blocks/components/Banner/BannerShowcase.tsx +1 -8
  68. package/templates/blocks/components/Blockquote/BlockquoteShowcase.tsx +1 -8
  69. package/templates/blocks/components/Carousel/CarouselShowcase.tsx +2 -12
  70. package/templates/blocks/components/ChatComposerDrawer/ChatComposerDrawerShowcase.tsx +6 -9
  71. package/templates/blocks/components/ChatLayout/ChatLayoutPanelChat.tsx +10 -12
  72. package/templates/blocks/components/ChatMessageList/ChatMessageListDensity.tsx +1 -9
  73. package/templates/blocks/components/ChatMessageList/ChatMessageListFullFeatured.tsx +1 -9
  74. package/templates/blocks/components/ChatMessageList/ChatMessageListShowcase.tsx +1 -9
  75. package/templates/blocks/components/ChatMessageMetadata/ChatMessageMetadataShowcase.tsx +1 -8
  76. package/templates/blocks/components/ChatSendButton/ChatSendButtonInComposer.tsx +1 -8
  77. package/templates/blocks/components/Citation/CitationInlineText.tsx +4 -4
  78. package/templates/blocks/components/Code/CodeInlineInParagraph.tsx +1 -8
  79. package/templates/blocks/components/CodeBlock/CodeBlockBashCommand.tsx +1 -1
  80. package/templates/blocks/components/CodeBlock/CodeBlockJSONConfig.tsx +1 -1
  81. package/templates/blocks/components/CommandPaletteItem/CommandPaletteItemShowcase.tsx +9 -12
  82. package/templates/blocks/components/ContextMenu/ContextMenuShowcase.tsx +13 -15
  83. package/templates/blocks/components/Divider/DividerShowcase.tsx +1 -8
  84. package/templates/blocks/components/Divider/DividerVertical.tsx +7 -9
  85. package/templates/blocks/components/Field/FieldShowcase.tsx +1 -8
  86. package/templates/blocks/components/FormLayout/FormLayoutHorizontal.tsx +1 -6
  87. package/templates/blocks/components/Grid/GridResponsiveAutoFit.tsx +1 -9
  88. package/templates/blocks/components/HoverCard/HoverCardInlineTextHoverCard.tsx +4 -6
  89. package/templates/blocks/components/HoverCard/HoverCardInteractiveContent.tsx +1 -6
  90. package/templates/blocks/components/HoverCard/HoverCardProfileHoverCard.tsx +2 -8
  91. package/templates/blocks/components/HoverCard/HoverCardShowcase.tsx +1 -8
  92. package/templates/blocks/components/MoreMenu/MoreMenuInToolbar.tsx +2 -12
  93. package/templates/blocks/components/OverflowList/OverflowListOverflowBadges.tsx +8 -11
  94. package/templates/blocks/components/OverflowList/OverflowListOverflowDropdownActions.tsx +9 -12
  95. package/templates/blocks/components/Overlay/OverlayBottomStrip.tsx +4 -17
  96. package/templates/blocks/components/Overlay/OverlayHoverReveal.tsx +15 -16
  97. package/templates/blocks/components/Overlay/OverlayShowcase.tsx +5 -21
  98. package/templates/blocks/components/Pagination/PaginationDotsCarousel.tsx +2 -14
  99. package/templates/blocks/components/Pagination/PaginationPageSize.tsx +12 -14
  100. package/templates/blocks/components/Pagination/PaginationVariants.tsx +1 -8
  101. package/templates/blocks/components/Pagination/PaginationWithTable.tsx +2 -14
  102. package/templates/blocks/components/Tokenizer/TokenizerClear.tsx +1 -6
  103. package/templates/blocks/components/Tokenizer/TokenizerCreatable.tsx +2 -7
  104. package/templates/blocks/components/Tokenizer/TokenizerEndContent.tsx +1 -6
  105. package/templates/blocks/components/Tokenizer/TokenizerIcon.tsx +1 -6
  106. package/templates/blocks/components/Tokenizer/TokenizerMaxEntries.tsx +1 -6
  107. package/templates/blocks/components/Tokenizer/TokenizerOverflow.tsx +2 -7
  108. package/templates/blocks/components/Tokenizer/TokenizerShowcase.tsx +1 -6
  109. package/templates/blocks/components/Tokenizer/TokenizerStates.tsx +4 -9
  110. package/templates/blocks/components/Toolbar/ToolbarCardHeader.tsx +1 -10
  111. package/templates/blocks/components/Toolbar/ToolbarSizes.tsx +1 -8
  112. package/templates/blocks/components/Toolbar/ToolbarTableFilter.tsx +1 -8
  113. package/templates/blocks/components/Toolbar/ToolbarThreeSlot.tsx +1 -10
  114. package/templates/blocks/components/Toolbar/ToolbarWithTabs.tsx +8 -11
  115. package/templates/pages/ai-chat/page.tsx +71 -64
  116. package/templates/pages/ai-chat-landing/page.tsx +8 -12
  117. package/templates/pages/centered-hero/page.tsx +13 -15
  118. package/templates/pages/classic-gallery/page.tsx +27 -34
  119. package/templates/pages/detail-page/page.tsx +18 -18
  120. package/templates/pages/documentation/page.tsx +42 -58
  121. package/templates/pages/documentation-design/page.tsx +82 -60
  122. package/templates/pages/documentation-technical/page.tsx +101 -60
  123. package/templates/pages/editor/page.tsx +42 -54
  124. package/templates/pages/file-explorer/page.tsx +13 -16
  125. package/templates/pages/form-two-column/page.tsx +13 -17
  126. package/templates/pages/gallery-hero/page.tsx +13 -15
  127. package/templates/pages/ide/page.tsx +188 -264
  128. package/templates/pages/library/page.tsx +16 -23
  129. package/templates/pages/login/page.tsx +14 -18
  130. package/templates/pages/login-card/page.tsx +14 -18
  131. package/templates/pages/login-split/page.tsx +50 -48
  132. package/templates/pages/login-sso/page.tsx +9 -13
  133. package/templates/pages/mixed-gallery/page.tsx +51 -45
  134. package/templates/pages/payment-form/page.tsx +56 -70
  135. package/templates/pages/product-detail/page.tsx +27 -33
  136. package/templates/pages/product-gallery/page.tsx +7 -13
  137. package/templates/pages/settings-dialog/page.tsx +35 -43
  138. package/templates/pages/settings-sidebar/page.tsx +39 -47
  139. package/templates/pages/side-gallery/page.tsx +6 -9
  140. package/templates/pages/table-grouped/page.tsx +11 -15
  141. package/templates/pages/theme-showcase/page.tsx +33 -37
@@ -2,16 +2,14 @@
2
2
 
3
3
  'use client';
4
4
 
5
- import {useState, useMemo} from 'react';
6
- import * as stylex from '@stylexjs/stylex';
7
- import {SideNav, SideNavItem, SideNavSection} from '@astryxdesign/core/SideNav';
5
+ import {useState, useMemo, type CSSProperties} from 'react';
8
6
 
9
7
  import {Layout, LayoutContent, LayoutPanel} from '@astryxdesign/core/Layout';
10
8
  import {ResizeHandle, useResizable} from '@astryxdesign/core/Resizable';
11
9
  import {Text, Heading} from '@astryxdesign/core/Text';
12
10
  import {CodeBlock} from '@astryxdesign/core/CodeBlock';
13
- import {colorVars, spacingVars} from '@astryxdesign/core/theme/tokens.stylex';
14
- import {Stack} from '@astryxdesign/core/Layout';
11
+ import {Stack, StackItem} from '@astryxdesign/core/Layout';
12
+ import {useMediaQuery} from '@astryxdesign/core/hooks';
15
13
  import {TabList, Tab} from '@astryxdesign/core/TabList';
16
14
  import {
17
15
  SegmentedControl,
@@ -27,90 +25,71 @@ import type {TreeListItemData} from '@astryxdesign/core/TreeList';
27
25
  import {
28
26
  FolderIcon,
29
27
  DocumentTextIcon,
30
- CodeBracketIcon,
31
28
  MagnifyingGlassIcon,
32
- CommandLineIcon,
33
- ExclamationTriangleIcon,
34
- InformationCircleIcon,
35
- BugAntIcon,
36
- HomeIcon,
37
- FolderOpenIcon,
38
- PuzzlePieceIcon,
39
29
  } from '@heroicons/react/24/outline';
40
- import {
41
- HomeIcon as HomeIconSolid,
42
- FolderOpenIcon as FolderOpenSolid,
43
- MagnifyingGlassIcon as MagnifyingGlassSolid,
44
- PuzzlePieceIcon as PuzzlePieceSolid,
45
- } from '@heroicons/react/24/solid';
46
30
 
47
- const styles = stylex.create({
31
+ const styles: Record<string, CSSProperties> = {
48
32
  contentFill: {
49
33
  height: '100%',
50
34
  },
51
35
  terminalWrapper: {
52
- flex: 1,
53
36
  minHeight: 0,
54
37
  overflow: 'hidden',
55
38
  display: 'grid',
56
39
  },
57
40
  tabListPadding: {
58
- paddingTop: spacingVars['--spacing-2'],
41
+ paddingTop: 'var(--spacing-2)',
59
42
  },
60
43
  metadataCompact: {
61
- gap: `${spacingVars['--spacing-1']} ${spacingVars['--spacing-3']}`,
44
+ gap: 'var(--spacing-1) var(--spacing-3)',
62
45
  },
63
46
  historyTimelineDot: {
64
47
  width: 8,
65
48
  height: 8,
66
49
  borderRadius: '50%',
67
- backgroundColor: colorVars['--color-border-emphasized'],
50
+ backgroundColor: 'var(--color-border-emphasized)',
68
51
  marginTop: 6,
69
52
  flexShrink: 0,
70
53
  },
71
54
  editorArea: {
72
- flex: 1,
73
55
  overflow: 'auto',
56
+ minHeight: 0,
74
57
  },
75
58
  fileExplorer: {
76
59
  padding: 16,
60
+ minWidth: 0,
77
61
  },
78
- terminalArea: {
62
+ propertiesPanel: {
79
63
  height: '100%',
80
- overflow: 'hidden',
81
64
  },
82
- hideOnMobile: {
83
- display: {
84
- default: 'contents',
85
- '@media (max-width: 768px)': 'none',
86
- },
65
+ propertiesContent: {
66
+ flex: 1,
67
+ minHeight: 0,
87
68
  },
88
- hideSideNav: {
89
- display: {
90
- default: 'flex',
91
- '@media (max-width: 768px)': 'none',
92
- },
69
+ propertyActions: {
70
+ marginTop: 'auto',
71
+ },
72
+ terminalArea: {
73
+ height: '100%',
74
+ overflow: 'hidden',
93
75
  },
94
- });
76
+ };
95
77
 
96
78
  const EDITOR_CODE = `import {useState, useCallback} from 'react';
97
- import * as stylex from '@stylexjs/stylex';
98
79
  import {Button} from '@astryxdesign/core/Button';
99
80
  import {Text} from '@astryxdesign/core/Text';
100
81
 
101
- const styles = stylex.create({
102
- container: {
103
- display: 'flex',
104
- flexDirection: 'column',
105
- gap: 8,
106
- padding: 16,
107
- },
108
- counter: {
109
- fontSize: 48,
110
- fontWeight: 700,
111
- fontVariantNumeric: 'tabular-nums',
112
- },
113
- });
82
+ const containerStyle = {
83
+ display: 'flex',
84
+ flexDirection: 'column',
85
+ gap: 8,
86
+ padding: 16,
87
+ };
88
+ const counterStyle = {
89
+ fontSize: 48,
90
+ fontWeight: 700,
91
+ fontVariantNumeric: 'tabular-nums',
92
+ };
114
93
 
115
94
  export default function Counter() {
116
95
  const [count, setCount] = useState(0);
@@ -124,9 +103,9 @@ export default function Counter() {
124
103
  }, []);
125
104
 
126
105
  return (
127
- <div {...stylex.props(styles.container)}>
106
+ <div style={containerStyle}>
128
107
  <Text type="label">Counter</Text>
129
- <span {...stylex.props(styles.counter)}>
108
+ <span style={counterStyle}>
130
109
  {count}
131
110
  </span>
132
111
  <Button label="Increment" onClick={increment} />
@@ -151,22 +130,23 @@ $ `;
151
130
  function buildFileTree(
152
131
  onFileClick: (name: string) => void,
153
132
  ): TreeListItemData[] {
133
+ const label = (text: string) => <Text maxLines={1}>{text}</Text>;
154
134
  const file = (id: string): TreeListItemData => ({
155
135
  id,
156
- label: id,
136
+ label: label(id),
157
137
  startContent: <Icon icon={DocumentTextIcon} size="xsm" />,
158
138
  onClick: () => onFileClick(id),
159
139
  });
160
140
  return [
161
141
  {
162
142
  id: 'src',
163
- label: 'src',
143
+ label: label('src'),
164
144
  startContent: <Icon icon={FolderIcon} size="xsm" />,
165
145
  isExpanded: true,
166
146
  children: [
167
147
  {
168
148
  id: 'components',
169
- label: 'components',
149
+ label: label('components'),
170
150
  startContent: <Icon icon={FolderIcon} size="xsm" />,
171
151
  isExpanded: true,
172
152
  children: [
@@ -177,17 +157,17 @@ function buildFileTree(
177
157
  },
178
158
  {
179
159
  id: 'pages',
180
- label: 'pages',
160
+ label: label('pages'),
181
161
  startContent: <Icon icon={FolderIcon} size="xsm" />,
182
162
  isExpanded: true,
183
163
  children: [file('index.tsx'), file('about.tsx')],
184
164
  },
185
165
  {
186
166
  id: 'styles',
187
- label: 'styles',
167
+ label: label('styles'),
188
168
  startContent: <Icon icon={FolderIcon} size="xsm" />,
189
169
  isExpanded: true,
190
- children: [file('tokens.stylex.ts'), file('theme.ts')],
170
+ children: [file('tokens.ts'), file('theme.ts')],
191
171
  },
192
172
  ],
193
173
  },
@@ -211,12 +191,11 @@ const PROPERTIES = [
211
191
  const HISTORY_ITEMS = [
212
192
  {label: 'Opened Counter.tsx', time: '2 min ago'},
213
193
  {label: 'Opened Layout.tsx', time: '6 min ago'},
214
- {label: 'Viewed tokens.stylex.ts', time: '11 min ago'},
194
+ {label: 'Viewed tokens.ts', time: '11 min ago'},
215
195
  ];
216
196
 
217
197
  export default function ResizableWorkspacePage() {
218
198
  const [activeFile, setActiveFile] = useState('Counter.tsx');
219
- const [activeNavItem, setActiveNavItem] = useState('Explorer');
220
199
  const [activeTermTab, setActiveTermTab] = useState('terminal');
221
200
  const [activePropertiesTab, setActivePropertiesTab] = useState('properties');
222
201
  const fileTree = useMemo(() => buildFileTree(setActiveFile), []);
@@ -245,89 +224,48 @@ export default function ResizableWorkspacePage() {
245
224
  collapsedSize: 40,
246
225
  });
247
226
 
227
+ const isMobile = useMediaQuery('(max-width: 768px)');
228
+
248
229
  return (
249
230
  <Layout
250
231
  height="fill"
251
- start={
252
- <LayoutPanel hasDivider={false} padding={0}>
253
- <SideNav
254
- collapsible={{defaultIsCollapsed: true}}
255
- resizable
256
- xstyle={styles.hideSideNav}>
257
- <SideNavSection title="Navigation" isHeaderHidden>
258
- <SideNavItem
259
- label="Home"
260
- icon={HomeIcon}
261
- selectedIcon={HomeIconSolid}
262
- isSelected={activeNavItem === 'Home'}
263
- onClick={() => setActiveNavItem('Home')}
264
- />
265
- <SideNavItem
266
- label="Explorer"
267
- icon={FolderOpenIcon}
268
- selectedIcon={FolderOpenSolid}
269
- isSelected={activeNavItem === 'Explorer'}
270
- onClick={() => setActiveNavItem('Explorer')}
271
- />
272
- <SideNavItem
273
- label="Search"
274
- icon={MagnifyingGlassIcon}
275
- selectedIcon={MagnifyingGlassSolid}
276
- isSelected={activeNavItem === 'Search'}
277
- onClick={() => setActiveNavItem('Search')}
278
- />
279
- <SideNavItem
280
- label="Source Control"
281
- icon={CodeBracketIcon}
282
- isSelected={activeNavItem === 'Source Control'}
283
- onClick={() => setActiveNavItem('Source Control')}
284
- />
285
- <SideNavItem
286
- label="Extensions"
287
- icon={PuzzlePieceIcon}
288
- selectedIcon={PuzzlePieceSolid}
289
- isSelected={activeNavItem === 'Extensions'}
290
- onClick={() => setActiveNavItem('Extensions')}
291
- />
292
- </SideNavSection>
293
- </SideNav>
294
- </LayoutPanel>
295
- }
296
232
  content={
297
233
  <LayoutContent padding={0}>
298
234
  <Layout
299
235
  height="fill"
300
236
  start={
301
- <div {...stylex.props(styles.hideOnMobile)}>
302
- {!startPanel.isCollapsed && (
303
- <LayoutPanel
304
- width={startPanel.size}
305
- hasDivider={false}
306
- padding={0}>
307
- <Stack
308
- direction="vertical"
309
- xstyle={styles.fileExplorer}
310
- gap={2}>
311
- <TextInput
312
- label="Search files"
313
- isLabelHidden
314
- value=""
315
- placeholder="Search"
316
- size="md"
317
- startIcon={MagnifyingGlassIcon}
318
- />
319
- <TreeList items={fileTree} density="compact" />
320
- </Stack>
321
- </LayoutPanel>
322
- )}
323
- <ResizeHandle
324
- direction="horizontal"
325
- hasDivider
326
- isAlwaysVisible={false}
327
- resizable={startPanel.props}
328
- label="Resize file explorer"
329
- />
330
- </div>
237
+ isMobile ? undefined : (
238
+ <>
239
+ {!startPanel.isCollapsed && (
240
+ <LayoutPanel
241
+ width={startPanel.size}
242
+ hasDivider={false}
243
+ padding={0}>
244
+ <Stack
245
+ direction="vertical"
246
+ style={styles.fileExplorer}
247
+ gap={2}>
248
+ <TextInput
249
+ label="Search files"
250
+ isLabelHidden
251
+ value=""
252
+ placeholder="Search"
253
+ size="md"
254
+ startIcon={MagnifyingGlassIcon}
255
+ />
256
+ <TreeList items={fileTree} density="compact" />
257
+ </Stack>
258
+ </LayoutPanel>
259
+ )}
260
+ <ResizeHandle
261
+ direction="horizontal"
262
+ hasDivider
263
+ isAlwaysVisible={false}
264
+ resizable={startPanel.props}
265
+ label="Resize file explorer"
266
+ />
267
+ </>
268
+ )
331
269
  }
332
270
  content={
333
271
  <LayoutContent padding={0}>
@@ -335,13 +273,13 @@ export default function ResizableWorkspacePage() {
335
273
  height="fill"
336
274
  content={
337
275
  <LayoutContent padding={0}>
338
- <Stack
339
- direction="vertical"
340
- xstyle={styles.contentFill}>
341
- <div {...stylex.props(styles.editorArea)}>
276
+ <Stack direction="vertical" style={styles.contentFill}>
277
+ <StackItem size="fill" style={styles.editorArea}>
342
278
  <CodeBlock
343
279
  code={EDITOR_CODE}
344
280
  language="typescript"
281
+ container="section"
282
+ hasLanguageLabel={false}
345
283
  hasLineNumbers
346
284
  highlightLines={[21]}
347
285
  hasCopyButton={false}
@@ -353,7 +291,7 @@ export default function ResizableWorkspacePage() {
353
291
  borderRadius: 0,
354
292
  }}
355
293
  />
356
- </div>
294
+ </StackItem>
357
295
  <ResizeHandle
358
296
  direction="vertical"
359
297
  hasDivider
@@ -371,50 +309,26 @@ export default function ResizableWorkspacePage() {
371
309
  }}>
372
310
  <Stack
373
311
  direction="vertical"
374
- xstyle={styles.contentFill}>
312
+ style={styles.contentFill}>
375
313
  <TabList
376
314
  value={activeTermTab}
377
315
  onChange={val => setActiveTermTab(val)}
378
316
  size="sm"
379
317
  hasDivider={false}
380
- xstyle={styles.tabListPadding}>
381
- <Tab
382
- label="Terminal"
383
- value="terminal"
384
- icon={
385
- <Icon icon={CommandLineIcon} size="sm" />
386
- }
387
- />
388
- <Tab
389
- label="Problems"
390
- value="problems"
391
- icon={
392
- <Icon
393
- icon={ExclamationTriangleIcon}
394
- size="sm"
395
- />
396
- }
397
- />
398
- <Tab
399
- label="Output"
400
- value="output"
401
- icon={
402
- <Icon
403
- icon={InformationCircleIcon}
404
- size="sm"
405
- />
406
- }
407
- />
408
- <Tab
409
- label="Debug"
410
- value="debug"
411
- icon={<Icon icon={BugAntIcon} size="sm" />}
412
- />
318
+ style={styles.tabListPadding}>
319
+ <Tab label="Terminal" value="terminal" />
320
+ <Tab label="Problems" value="problems" />
321
+ <Tab label="Output" value="output" />
322
+ <Tab label="Debug" value="debug" />
413
323
  </TabList>
414
- <div {...stylex.props(styles.terminalWrapper)}>
324
+ <StackItem
325
+ size="fill"
326
+ style={styles.terminalWrapper}>
415
327
  <CodeBlock
416
328
  code={TERMINAL_OUTPUT}
417
329
  language="bash"
330
+ container="section"
331
+ hasLanguageLabel={false}
418
332
  hasCopyButton={false}
419
333
  size="sm"
420
334
  style={{
@@ -424,7 +338,7 @@ export default function ResizableWorkspacePage() {
424
338
  borderRadius: 0,
425
339
  }}
426
340
  />
427
- </div>
341
+ </StackItem>
428
342
  </Stack>
429
343
  </div>
430
344
  )}
@@ -432,106 +346,116 @@ export default function ResizableWorkspacePage() {
432
346
  </LayoutContent>
433
347
  }
434
348
  end={
435
- <div {...stylex.props(styles.hideOnMobile)}>
436
- <ResizeHandle
437
- direction="horizontal"
438
- hasDivider
439
- isReversed
440
- isAlwaysVisible={false}
441
- resizable={endPanel.props}
442
- label="Resize properties panel"
443
- />
444
- {!endPanel.isCollapsed && (
445
- <LayoutPanel
446
- width={endPanel.size}
447
- hasDivider={false}
448
- padding={4}>
449
- <Stack direction="vertical" gap={3}>
450
- <SegmentedControl
451
- label="Properties panel sections"
452
- value={activePropertiesTab}
453
- onChange={setActivePropertiesTab}
454
- size="sm"
455
- layout="fill">
456
- <SegmentedControlItem
457
- label="Properties"
458
- value="properties"
459
- />
460
- <SegmentedControlItem
461
- label="History"
462
- value="history"
463
- />
464
- </SegmentedControl>
465
- {activePropertiesTab === 'properties' ? (
466
- <>
467
- <Stack direction="vertical" gap={1}>
468
- <Heading level={3}>
469
- {activeFile}
470
- </Heading>
471
- <Text color="secondary" type="supporting">
472
- src/components/{activeFile}
473
- </Text>
474
- </Stack>
475
- <MetadataList
476
- xstyle={styles.metadataCompact}>
477
- {PROPERTIES.map(prop => (
478
- <MetadataListItem
479
- key={prop.label}
480
- label={prop.label}>
481
- {prop.value}
482
- </MetadataListItem>
483
- ))}
484
- </MetadataList>
485
- <Stack direction="vertical" gap={2}>
486
- <Stack direction="vertical" gap={2}>
349
+ isMobile ? undefined : (
350
+ <>
351
+ <ResizeHandle
352
+ direction="horizontal"
353
+ hasDivider
354
+ isReversed
355
+ isAlwaysVisible={false}
356
+ resizable={endPanel.props}
357
+ label="Resize properties panel"
358
+ />
359
+ {!endPanel.isCollapsed && (
360
+ <LayoutPanel
361
+ width={endPanel.size}
362
+ hasDivider={false}
363
+ padding={4}>
364
+ <Stack
365
+ direction="vertical"
366
+ gap={3}
367
+ style={styles.propertiesPanel}>
368
+ <SegmentedControl
369
+ label="Properties panel sections"
370
+ value={activePropertiesTab}
371
+ onChange={setActivePropertiesTab}
372
+ size="sm"
373
+ layout="fill">
374
+ <SegmentedControlItem
375
+ label="Properties"
376
+ value="properties"
377
+ />
378
+ <SegmentedControlItem
379
+ label="History"
380
+ value="history"
381
+ />
382
+ </SegmentedControl>
383
+ {activePropertiesTab === 'properties' ? (
384
+ <Stack
385
+ direction="vertical"
386
+ gap={3}
387
+ style={styles.propertiesContent}>
388
+ <Stack direction="vertical" gap={1}>
389
+ <Heading level={3} maxLines={1}>
390
+ {activeFile}
391
+ </Heading>
392
+ <Text
393
+ color="secondary"
394
+ type="supporting"
395
+ maxLines={1}>
396
+ src/components/{activeFile}
397
+ </Text>
398
+ </Stack>
399
+ <MetadataList style={styles.metadataCompact}>
400
+ {PROPERTIES.map(prop => (
401
+ <MetadataListItem
402
+ key={prop.label}
403
+ label={prop.label}>
404
+ {prop.value}
405
+ </MetadataListItem>
406
+ ))}
407
+ </MetadataList>
408
+ <Stack
409
+ direction="vertical"
410
+ gap={2}
411
+ style={styles.propertyActions}>
487
412
  <Button
488
413
  label="Format Document"
489
- size="md"
414
+ size="sm"
490
415
  variant="secondary"
491
416
  />
492
417
  <Button
493
418
  label="Go to Definition"
494
- size="md"
419
+ size="sm"
495
420
  variant="secondary"
496
421
  />
497
422
  <Button
498
423
  label="Find References"
499
- size="md"
424
+ size="sm"
500
425
  variant="secondary"
501
426
  />
502
427
  </Stack>
503
428
  </Stack>
504
- </>
505
- ) : (
506
- <Stack direction="vertical" gap={1}>
507
- <List>
508
- {HISTORY_ITEMS.map(item => (
509
- <ListItem
510
- key={item.label}
511
- label={item.label}
512
- endContent={
513
- <Text
514
- type="supporting"
515
- color="secondary">
516
- {item.time}
517
- </Text>
518
- }
519
- startContent={
520
- <span
521
- {...stylex.props(
522
- styles.historyTimelineDot,
523
- )}
524
- />
525
- }
526
- />
527
- ))}
528
- </List>
529
- </Stack>
530
- )}
531
- </Stack>
532
- </LayoutPanel>
533
- )}
534
- </div>
429
+ ) : (
430
+ <Stack direction="vertical" gap={1}>
431
+ <List>
432
+ {HISTORY_ITEMS.map(item => (
433
+ <ListItem
434
+ key={item.label}
435
+ label={item.label}
436
+ endContent={
437
+ <Text
438
+ type="supporting"
439
+ color="secondary"
440
+ maxLines={1}>
441
+ {item.time}
442
+ </Text>
443
+ }
444
+ startContent={
445
+ <span
446
+ style={styles.historyTimelineDot}
447
+ />
448
+ }
449
+ />
450
+ ))}
451
+ </List>
452
+ </Stack>
453
+ )}
454
+ </Stack>
455
+ </LayoutPanel>
456
+ )}
457
+ </>
458
+ )
535
459
  }
536
460
  />
537
461
  </LayoutContent>