@adminide-stack/yantra-mobile 12.0.108-alpha.0 → 12.0.109-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/lib/compute.js +57 -1
  2. package/lib/compute.js.map +1 -1
  3. package/lib/config/env-config.js +8 -0
  4. package/lib/config/env-config.js.map +1 -1
  5. package/lib/features/apps/AppsCatalog.js +10 -0
  6. package/lib/features/apps/AppsCatalog.js.map +1 -1
  7. package/lib/features/apps/appArt.js +2 -1
  8. package/lib/features/apps/appArt.js.map +1 -1
  9. package/lib/features/apps/mobileAppCatalog.js +11 -0
  10. package/lib/features/apps/mobileAppCatalog.js.map +1 -1
  11. package/lib/features/apps/nativeAppHandoff.js +2 -1
  12. package/lib/features/apps/nativeAppHandoff.js.map +1 -1
  13. package/lib/features/health/healthSyncStore.js +7 -1
  14. package/lib/features/health/healthSyncStore.js.map +1 -1
  15. package/lib/features/messaging/NewGroupScreen.js.map +1 -1
  16. package/lib/features/messaging/useChatViewer.js +3 -2
  17. package/lib/features/messaging/useChatViewer.js.map +1 -1
  18. package/lib/features/webbuilder/WebBuilderExperience.js +474 -0
  19. package/lib/features/webbuilder/WebBuilderExperience.js.map +1 -0
  20. package/lib/features/webbuilder/brandKitStorage.js +69 -0
  21. package/lib/features/webbuilder/brandKitStorage.js.map +1 -0
  22. package/lib/features/webbuilder/buildFragments.js +360 -0
  23. package/lib/features/webbuilder/buildFragments.js.map +1 -0
  24. package/lib/features/webbuilder/components/BottomTabs.js +65 -0
  25. package/lib/features/webbuilder/components/BottomTabs.js.map +1 -0
  26. package/lib/features/webbuilder/components/BrandKitSheet.js +197 -0
  27. package/lib/features/webbuilder/components/BrandKitSheet.js.map +1 -0
  28. package/lib/features/webbuilder/components/CodeView.js +99 -0
  29. package/lib/features/webbuilder/components/CodeView.js.map +1 -0
  30. package/lib/features/webbuilder/components/Composer.js +217 -0
  31. package/lib/features/webbuilder/components/Composer.js.map +1 -0
  32. package/lib/features/webbuilder/components/PreviewFrame.js +72 -0
  33. package/lib/features/webbuilder/components/PreviewFrame.js.map +1 -0
  34. package/lib/features/webbuilder/components/PreviewPlaceholder.js +107 -0
  35. package/lib/features/webbuilder/components/PreviewPlaceholder.js.map +1 -0
  36. package/lib/features/webbuilder/components/PreviewScreen.js +200 -0
  37. package/lib/features/webbuilder/components/PreviewScreen.js.map +1 -0
  38. package/lib/features/webbuilder/components/ProjectChat.js +580 -0
  39. package/lib/features/webbuilder/components/ProjectChat.js.map +1 -0
  40. package/lib/features/webbuilder/components/ProjectsScreen.js +339 -0
  41. package/lib/features/webbuilder/components/ProjectsScreen.js.map +1 -0
  42. package/lib/features/webbuilder/components/PublishSheet.js +143 -0
  43. package/lib/features/webbuilder/components/PublishSheet.js.map +1 -0
  44. package/lib/features/webbuilder/components/SiteScoreSheet.js +73 -0
  45. package/lib/features/webbuilder/components/SiteScoreSheet.js.map +1 -0
  46. package/lib/features/webbuilder/components/StudioHome.js +367 -0
  47. package/lib/features/webbuilder/components/StudioHome.js.map +1 -0
  48. package/lib/features/webbuilder/components/TemplateCard.js +73 -0
  49. package/lib/features/webbuilder/components/TemplateCard.js.map +1 -0
  50. package/lib/features/webbuilder/components/TemplatesSheet.js +178 -0
  51. package/lib/features/webbuilder/components/TemplatesSheet.js.map +1 -0
  52. package/lib/features/webbuilder/components/VersionsSheet.js +57 -0
  53. package/lib/features/webbuilder/components/VersionsSheet.js.map +1 -0
  54. package/lib/features/webbuilder/components/ui.js +291 -0
  55. package/lib/features/webbuilder/components/ui.js.map +1 -0
  56. package/lib/features/webbuilder/nativeWebBuilderRegistry.js +15 -0
  57. package/lib/features/webbuilder/nativeWebBuilderRegistry.js.map +1 -0
  58. package/lib/features/webbuilder/studioCatalog.js +147 -0
  59. package/lib/features/webbuilder/studioCatalog.js.map +1 -0
  60. package/lib/features/webbuilder/webbuilderPrompts.js +42 -0
  61. package/lib/features/webbuilder/webbuilderPrompts.js.map +1 -0
  62. package/lib/features/webbuilder/webbuilderTheme.js +63 -0
  63. package/lib/features/webbuilder/webbuilderTheme.js.map +1 -0
  64. package/lib/features/webbuilder/workflow.js +540 -0
  65. package/lib/features/webbuilder/workflow.js.map +1 -0
  66. package/lib/hooks/useChatApi.js +7 -2
  67. package/lib/hooks/useChatApi.js.map +1 -1
  68. package/lib/hooks/useChatStream.js +1 -1
  69. package/lib/hooks/useChatStream.js.map +1 -1
  70. package/lib/index.js +1 -1
  71. package/lib/index.js.map +1 -1
  72. package/lib/routes.json +106 -0
  73. package/lib/screens/WebBuilderNative/index.js +71 -0
  74. package/lib/screens/WebBuilderNative/index.js.map +1 -0
  75. package/lib/screens/WebBuilderNative/useCodeAssistantCatalog.js +45 -0
  76. package/lib/screens/WebBuilderNative/useCodeAssistantCatalog.js.map +1 -0
  77. package/lib/screens/WebBuilderNative/useWebBuilderGallery.js +125 -0
  78. package/lib/screens/WebBuilderNative/useWebBuilderGallery.js.map +1 -0
  79. package/lib/screens/WebBuilderNative/useWebBuilderHost.js +408 -0
  80. package/lib/screens/WebBuilderNative/useWebBuilderHost.js.map +1 -0
  81. package/lib/screens/WebBuilderNative/webbuilderTransport.js +88 -0
  82. package/lib/screens/WebBuilderNative/webbuilderTransport.js.map +1 -0
  83. package/package.json +4 -4
@@ -0,0 +1,217 @@
1
+ import {jsxs,jsx}from'react/jsx-runtime';import {forwardRef}from'react';import {View,StyleSheet,TextInput,Text,ScrollView}from'react-native';import {MaterialCommunityIcons}from'@expo/vector-icons';import {Tap,DIM}from'../../inbox/components/Tap.js';import {hostLabel}from'../studioCatalog.js';function Tool({
2
+ icon,
3
+ label,
4
+ value,
5
+ onPress,
6
+ onClear,
7
+ theme,
8
+ leading,
9
+ testID
10
+ }) {
11
+ if (!value) {
12
+ return /* @__PURE__ */ jsx(Tap, { onPress, accessibilityRole: "button", accessibilityLabel: label, hitSlop: 4, style: [styles.toolIcon, {
13
+ borderColor: theme.border
14
+ }], pressedStyle: DIM, testID, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: icon, size: 19, color: theme.muted }) });
15
+ }
16
+ return /* @__PURE__ */ jsxs(View, { style: [styles.toolChip, {
17
+ backgroundColor: theme.accentSoft,
18
+ borderColor: theme.accentBorder
19
+ }], children: [
20
+ /* @__PURE__ */ jsxs(Tap, { onPress, accessibilityRole: "button", accessibilityLabel: `${label}: ${value}`, style: styles.toolChipMain, pressedStyle: DIM, testID, children: [
21
+ leading != null ? leading : /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: icon, size: 16, color: theme.accent }),
22
+ /* @__PURE__ */ jsx(Text, { style: [styles.toolChipLabel, {
23
+ color: theme.accent
24
+ }], numberOfLines: 1, children: value })
25
+ ] }),
26
+ onClear ? /* @__PURE__ */ jsx(Tap, { onPress: onClear, accessibilityRole: "button", accessibilityLabel: `Remove ${label.toLowerCase()}`, hitSlop: 8, style: styles.toolChipClear, pressedStyle: DIM, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "close-circle", size: 16, color: theme.accent }) }) : /* @__PURE__ */ jsx(View, { style: styles.toolChipEnd })
27
+ ] });
28
+ }
29
+ const Composer = forwardRef(function Composer2({
30
+ value,
31
+ onChangeText,
32
+ onSubmit,
33
+ template,
34
+ onTemplate,
35
+ onClearTemplate,
36
+ lookUrl,
37
+ onLookUrl,
38
+ lookInvalid,
39
+ lookOpen,
40
+ onLookOpen,
41
+ brand,
42
+ onBrand,
43
+ connecting = null,
44
+ canSubmit,
45
+ theme
46
+ }, ref) {
47
+ const lookHost = lookUrl && !lookInvalid ? hostLabel(lookUrl) : null;
48
+ const ready = canSubmit && !connecting;
49
+ return /* @__PURE__ */ jsxs(View, { style: [styles.box, {
50
+ backgroundColor: theme.card,
51
+ borderColor: theme.border,
52
+ shadowColor: theme.isDark ? "#000" : "#7c2d12"
53
+ }], children: [
54
+ /* @__PURE__ */ jsx(TextInput, { ref, value, onChangeText, placeholder: "Describe the site you want to build\u2026", placeholderTextColor: theme.faint, multiline: true, style: [styles.input, {
55
+ color: theme.ink
56
+ }], accessibilityLabel: "Describe what you want to build", testID: "webbuilder-brief" }),
57
+ lookOpen ? /* @__PURE__ */ jsxs(View, { style: [styles.look, {
58
+ backgroundColor: theme.chip,
59
+ borderColor: lookInvalid ? theme.crit : "transparent"
60
+ }], children: [
61
+ /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "web", size: 16, color: theme.muted }),
62
+ /* @__PURE__ */ jsx(TextInput, { value: lookUrl, onChangeText: onLookUrl, placeholder: "Look like\u2026 https://stripe.com", placeholderTextColor: theme.faint, autoCapitalize: "none", autoCorrect: false, keyboardType: "url", autoFocus: !lookUrl, onSubmitEditing: () => onLookOpen(false), style: [styles.lookInput, {
63
+ color: theme.ink
64
+ }], accessibilityLabel: "Make it look like this site", testID: "webbuilder-look" }),
65
+ /* @__PURE__ */ jsx(Tap, { onPress: () => {
66
+ onLookUrl("");
67
+ onLookOpen(false);
68
+ }, accessibilityRole: "button", accessibilityLabel: "Remove the look-alike site", hitSlop: 8, pressedStyle: DIM, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "close", size: 16, color: theme.muted }) })
69
+ ] }) : null,
70
+ connecting ? /* @__PURE__ */ jsxs(View, { style: styles.status, accessibilityLiveRegion: "polite", children: [
71
+ /* @__PURE__ */ jsx(View, { style: [styles.statusDot, {
72
+ backgroundColor: theme.warn
73
+ }] }),
74
+ /* @__PURE__ */ jsx(Text, { style: [styles.statusText, {
75
+ color: theme.muted
76
+ }], numberOfLines: 1, children: connecting })
77
+ ] }) : null,
78
+ /* @__PURE__ */ jsxs(View, { style: [styles.toolbar, {
79
+ borderTopColor: theme.border
80
+ }], children: [
81
+ /* @__PURE__ */ jsxs(ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, keyboardShouldPersistTaps: "handled", style: styles.tools, contentContainerStyle: styles.toolsContent, children: [
82
+ /* @__PURE__ */ jsx(Tool, { icon: "view-grid-plus-outline", label: "Template", value: template == null ? void 0 : template.title, onPress: onTemplate, onClear: onClearTemplate, theme, testID: "webbuilder-composer-template" }),
83
+ /* @__PURE__ */ jsx(Tool, { icon: "web", label: "Look like", value: lookOpen ? null : lookHost, onPress: () => onLookOpen(true), onClear: () => onLookUrl(""), theme, testID: "webbuilder-composer-look" }),
84
+ /* @__PURE__ */ jsx(Tool, { icon: "palette-outline", label: "Brand kit", value: brand ? brand.name || "Brand" : null, onPress: onBrand, theme, leading: (brand == null ? void 0 : brand.colors.length) ? /* @__PURE__ */ jsx(View, { style: styles.dots, children: brand.colors.slice(0, 3).map((c) => /* @__PURE__ */ jsx(View, { style: [styles.dot, {
85
+ backgroundColor: c,
86
+ borderColor: theme.card
87
+ }] }, c)) }) : void 0, testID: "webbuilder-composer-brand" })
88
+ ] }),
89
+ /* @__PURE__ */ jsx(Tap, { onPress: onSubmit, disabled: !ready, accessibilityRole: "button", accessibilityLabel: "Start building", accessibilityState: {
90
+ disabled: !ready
91
+ }, style: [styles.send, {
92
+ backgroundColor: ready ? theme.accent : theme.chip
93
+ }], pressedStyle: DIM, testID: "webbuilder-start", children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "arrow-up", size: 21, color: ready ? theme.accentInk : theme.faint }) })
94
+ ] })
95
+ ] });
96
+ });
97
+ const styles = StyleSheet.create({
98
+ box: {
99
+ borderRadius: 22,
100
+ borderWidth: StyleSheet.hairlineWidth,
101
+ paddingTop: 14,
102
+ paddingHorizontal: 14,
103
+ paddingBottom: 10,
104
+ gap: 10,
105
+ shadowOpacity: 0.07,
106
+ shadowRadius: 16,
107
+ shadowOffset: {
108
+ width: 0,
109
+ height: 6
110
+ },
111
+ elevation: 3
112
+ },
113
+ input: {
114
+ minHeight: 64,
115
+ maxHeight: 160,
116
+ fontSize: 17,
117
+ lineHeight: 24,
118
+ padding: 0,
119
+ textAlignVertical: "top"
120
+ },
121
+ look: {
122
+ flexDirection: "row",
123
+ alignItems: "center",
124
+ gap: 8,
125
+ borderRadius: 12,
126
+ borderWidth: 1,
127
+ paddingHorizontal: 10
128
+ },
129
+ lookInput: {
130
+ flex: 1,
131
+ fontSize: 15,
132
+ paddingVertical: 9
133
+ },
134
+ status: {
135
+ flexDirection: "row",
136
+ alignItems: "center",
137
+ gap: 8
138
+ },
139
+ statusDot: {
140
+ width: 7,
141
+ height: 7,
142
+ borderRadius: 4
143
+ },
144
+ statusText: {
145
+ flex: 1,
146
+ fontSize: 13
147
+ },
148
+ toolbar: {
149
+ flexDirection: "row",
150
+ alignItems: "center",
151
+ gap: 10,
152
+ paddingTop: 10,
153
+ borderTopWidth: StyleSheet.hairlineWidth
154
+ },
155
+ tools: {
156
+ flex: 1
157
+ },
158
+ toolsContent: {
159
+ gap: 8,
160
+ alignItems: "center"
161
+ },
162
+ toolIcon: {
163
+ width: 38,
164
+ height: 38,
165
+ borderRadius: 19,
166
+ borderWidth: StyleSheet.hairlineWidth,
167
+ alignItems: "center",
168
+ justifyContent: "center"
169
+ },
170
+ toolChip: {
171
+ flexDirection: "row",
172
+ alignItems: "center",
173
+ height: 38,
174
+ maxWidth: 200,
175
+ borderRadius: 19,
176
+ borderWidth: StyleSheet.hairlineWidth
177
+ },
178
+ toolChipMain: {
179
+ flexDirection: "row",
180
+ alignItems: "center",
181
+ gap: 6,
182
+ paddingLeft: 12,
183
+ flexShrink: 1
184
+ },
185
+ toolChipLabel: {
186
+ fontSize: 14,
187
+ fontWeight: "600",
188
+ flexShrink: 1
189
+ },
190
+ toolChipClear: {
191
+ paddingLeft: 6,
192
+ paddingRight: 10,
193
+ height: 38,
194
+ justifyContent: "center"
195
+ },
196
+ toolChipEnd: {
197
+ width: 12
198
+ },
199
+ dots: {
200
+ flexDirection: "row",
201
+ marginRight: 4
202
+ },
203
+ dot: {
204
+ width: 12,
205
+ height: 12,
206
+ borderRadius: 6,
207
+ borderWidth: 1.5,
208
+ marginRight: -4
209
+ },
210
+ send: {
211
+ width: 42,
212
+ height: 42,
213
+ borderRadius: 21,
214
+ alignItems: "center",
215
+ justifyContent: "center"
216
+ }
217
+ });export{Composer};//# sourceMappingURL=Composer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Composer.js","sources":["../../../../src/features/webbuilder/components/Composer.tsx"],"sourcesContent":["/**\n * The prompt box - what to build, and in one toolbar row the three ways the web\n * studio lets you shape it: a starter template, a site to look like, the brand\n * kit. A tool shows as a small icon until it is set, then as a chip naming the\n * choice, with a way to remove it. Send is the only filled control; while the\n * builder is still connecting it rests disabled and the box says so.\n */\nimport React, { forwardRef } from 'react';\nimport { ScrollView, StyleSheet, Text, TextInput, View } from 'react-native';\nimport { MaterialCommunityIcons } from '@expo/vector-icons';\nimport { DIM, Tap } from '../../inbox/components/Tap';\nimport { hostLabel, type BrandKit } from '../studioCatalog';\nimport type { WebBuilderTemplate } from '../workflow';\nimport type { WebBuilderTheme } from '../webbuilderTheme';\nimport type { IconName } from './ui';\n\nfunction Tool({\n icon,\n label,\n value,\n onPress,\n onClear,\n theme,\n leading,\n testID,\n}: {\n icon: IconName;\n /** What the tool does, for screen readers. */\n label: string;\n /** The choice once made (a template name, a host, a brand); unset when empty. */\n value?: string | null;\n onPress: () => void;\n onClear?: () => void;\n theme: WebBuilderTheme;\n leading?: React.ReactNode;\n testID?: string;\n}) {\n if (!value) {\n return (\n <Tap\n onPress={onPress}\n accessibilityRole=\"button\"\n accessibilityLabel={label}\n hitSlop={4}\n style={[styles.toolIcon, { borderColor: theme.border }]}\n pressedStyle={DIM}\n testID={testID}\n >\n <MaterialCommunityIcons name={icon} size={19} color={theme.muted} />\n </Tap>\n );\n }\n return (\n <View style={[styles.toolChip, { backgroundColor: theme.accentSoft, borderColor: theme.accentBorder }]}>\n <Tap\n onPress={onPress}\n accessibilityRole=\"button\"\n accessibilityLabel={`${label}: ${value}`}\n style={styles.toolChipMain}\n pressedStyle={DIM}\n testID={testID}\n >\n {leading ?? <MaterialCommunityIcons name={icon} size={16} color={theme.accent} />}\n <Text style={[styles.toolChipLabel, { color: theme.accent }]} numberOfLines={1}>\n {value}\n </Text>\n </Tap>\n {onClear ? (\n <Tap\n onPress={onClear}\n accessibilityRole=\"button\"\n accessibilityLabel={`Remove ${label.toLowerCase()}`}\n hitSlop={8}\n style={styles.toolChipClear}\n pressedStyle={DIM}\n >\n <MaterialCommunityIcons name=\"close-circle\" size={16} color={theme.accent} />\n </Tap>\n ) : (\n <View style={styles.toolChipEnd} />\n )}\n </View>\n );\n}\n\nexport interface ComposerProps {\n value: string;\n onChangeText: (text: string) => void;\n onSubmit: () => void;\n template: WebBuilderTemplate | null;\n onTemplate: () => void;\n onClearTemplate: () => void;\n lookUrl: string;\n onLookUrl: (url: string) => void;\n lookInvalid: boolean;\n /** The look-alike field is open (the home's \"A site you love\" card opens it too). */\n lookOpen: boolean;\n onLookOpen: (open: boolean) => void;\n brand: BrandKit | null;\n onBrand: () => void;\n /** The builder is still connecting: send waits, and this sentence says why. */\n connecting?: string | null;\n canSubmit: boolean;\n theme: WebBuilderTheme;\n}\n\nexport const Composer = forwardRef<TextInput, ComposerProps>(function Composer(\n {\n value,\n onChangeText,\n onSubmit,\n template,\n onTemplate,\n onClearTemplate,\n lookUrl,\n onLookUrl,\n lookInvalid,\n lookOpen,\n onLookOpen,\n brand,\n onBrand,\n connecting = null,\n canSubmit,\n theme,\n },\n ref,\n) {\n const lookHost = lookUrl && !lookInvalid ? hostLabel(lookUrl) : null;\n const ready = canSubmit && !connecting;\n return (\n <View\n style={[\n styles.box,\n {\n backgroundColor: theme.card,\n borderColor: theme.border,\n shadowColor: theme.isDark ? '#000' : '#7c2d12',\n },\n ]}\n >\n <TextInput\n ref={ref}\n value={value}\n onChangeText={onChangeText}\n placeholder=\"Describe the site you want to build…\"\n placeholderTextColor={theme.faint}\n multiline\n style={[styles.input, { color: theme.ink }]}\n accessibilityLabel=\"Describe what you want to build\"\n testID=\"webbuilder-brief\"\n />\n\n {lookOpen ? (\n <View\n style={[\n styles.look,\n { backgroundColor: theme.chip, borderColor: lookInvalid ? theme.crit : 'transparent' },\n ]}\n >\n <MaterialCommunityIcons name=\"web\" size={16} color={theme.muted} />\n <TextInput\n value={lookUrl}\n onChangeText={onLookUrl}\n placeholder=\"Look like… https://stripe.com\"\n placeholderTextColor={theme.faint}\n autoCapitalize=\"none\"\n autoCorrect={false}\n keyboardType=\"url\"\n autoFocus={!lookUrl}\n onSubmitEditing={() => onLookOpen(false)}\n style={[styles.lookInput, { color: theme.ink }]}\n accessibilityLabel=\"Make it look like this site\"\n testID=\"webbuilder-look\"\n />\n <Tap\n onPress={() => {\n onLookUrl('');\n onLookOpen(false);\n }}\n accessibilityRole=\"button\"\n accessibilityLabel=\"Remove the look-alike site\"\n hitSlop={8}\n pressedStyle={DIM}\n >\n <MaterialCommunityIcons name=\"close\" size={16} color={theme.muted} />\n </Tap>\n </View>\n ) : null}\n\n {connecting ? (\n <View style={styles.status} accessibilityLiveRegion=\"polite\">\n <View style={[styles.statusDot, { backgroundColor: theme.warn }]} />\n <Text style={[styles.statusText, { color: theme.muted }]} numberOfLines={1}>\n {connecting}\n </Text>\n </View>\n ) : null}\n\n <View style={[styles.toolbar, { borderTopColor: theme.border }]}>\n <ScrollView\n horizontal\n showsHorizontalScrollIndicator={false}\n keyboardShouldPersistTaps=\"handled\"\n style={styles.tools}\n contentContainerStyle={styles.toolsContent}\n >\n <Tool\n icon=\"view-grid-plus-outline\"\n label=\"Template\"\n value={template?.title}\n onPress={onTemplate}\n onClear={onClearTemplate}\n theme={theme}\n testID=\"webbuilder-composer-template\"\n />\n <Tool\n icon=\"web\"\n label=\"Look like\"\n value={lookOpen ? null : lookHost}\n onPress={() => onLookOpen(true)}\n onClear={() => onLookUrl('')}\n theme={theme}\n testID=\"webbuilder-composer-look\"\n />\n <Tool\n icon=\"palette-outline\"\n label=\"Brand kit\"\n value={brand ? brand.name || 'Brand' : null}\n onPress={onBrand}\n theme={theme}\n leading={\n brand?.colors.length ? (\n <View style={styles.dots}>\n {brand.colors.slice(0, 3).map((c) => (\n <View\n key={c}\n style={[styles.dot, { backgroundColor: c, borderColor: theme.card }]}\n />\n ))}\n </View>\n ) : undefined\n }\n testID=\"webbuilder-composer-brand\"\n />\n </ScrollView>\n <Tap\n onPress={onSubmit}\n disabled={!ready}\n accessibilityRole=\"button\"\n accessibilityLabel=\"Start building\"\n accessibilityState={{ disabled: !ready }}\n style={[styles.send, { backgroundColor: ready ? theme.accent : theme.chip }]}\n pressedStyle={DIM}\n testID=\"webbuilder-start\"\n >\n <MaterialCommunityIcons name=\"arrow-up\" size={21} color={ready ? theme.accentInk : theme.faint} />\n </Tap>\n </View>\n </View>\n );\n});\n\nconst styles = StyleSheet.create({\n box: {\n borderRadius: 22,\n borderWidth: StyleSheet.hairlineWidth,\n paddingTop: 14,\n paddingHorizontal: 14,\n paddingBottom: 10,\n gap: 10,\n shadowOpacity: 0.07,\n shadowRadius: 16,\n shadowOffset: { width: 0, height: 6 },\n elevation: 3,\n },\n input: {\n minHeight: 64,\n maxHeight: 160,\n fontSize: 17,\n lineHeight: 24,\n padding: 0,\n textAlignVertical: 'top',\n },\n look: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: 8,\n borderRadius: 12,\n borderWidth: 1,\n paddingHorizontal: 10,\n },\n lookInput: { flex: 1, fontSize: 15, paddingVertical: 9 },\n status: { flexDirection: 'row', alignItems: 'center', gap: 8 },\n statusDot: { width: 7, height: 7, borderRadius: 4 },\n statusText: { flex: 1, fontSize: 13 },\n toolbar: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: 10,\n paddingTop: 10,\n borderTopWidth: StyleSheet.hairlineWidth,\n },\n tools: { flex: 1 },\n toolsContent: { gap: 8, alignItems: 'center' },\n toolIcon: {\n width: 38,\n height: 38,\n borderRadius: 19,\n borderWidth: StyleSheet.hairlineWidth,\n alignItems: 'center',\n justifyContent: 'center',\n },\n toolChip: {\n flexDirection: 'row',\n alignItems: 'center',\n height: 38,\n maxWidth: 200,\n borderRadius: 19,\n borderWidth: StyleSheet.hairlineWidth,\n },\n toolChipMain: { flexDirection: 'row', alignItems: 'center', gap: 6, paddingLeft: 12, flexShrink: 1 },\n toolChipLabel: { fontSize: 14, fontWeight: '600', flexShrink: 1 },\n toolChipClear: { paddingLeft: 6, paddingRight: 10, height: 38, justifyContent: 'center' },\n toolChipEnd: { width: 12 },\n dots: { flexDirection: 'row', marginRight: 4 },\n dot: { width: 12, height: 12, borderRadius: 6, borderWidth: 1.5, marginRight: -4 },\n send: { width: 42, height: 42, borderRadius: 21, alignItems: 'center', justifyContent: 'center' },\n});\n"],"names":["Composer"],"mappings":"qSAeA,SAAS,IAAK,CAAA;AAAA,EACZ,IAAA;AAAA,EACA,KAAA;AAAA,EACA,KAAA;AAAA,EACA,OAAA;AAAA,EACA,OAAA;AAAA,EACA,KAAA;AAAA,EACA,OAAA;AAAA,EACA;AACF,CAWG,EAAA;AACD,EAAA,IAAI,CAAC,KAAO,EAAA;AACV,IAAA,uBAAQ,GAAA,CAAA,GAAA,EAAA,EAAI,OAAkB,EAAA,iBAAA,EAAkB,QAAS,EAAA,kBAAA,EAAoB,KAAO,EAAA,OAAA,EAAS,CAAG,EAAA,KAAA,EAAO,CAAC,MAAA,CAAO,QAAU,EAAA;AAAA,MACvH,aAAa,KAAM,CAAA;AAAA,KACpB,CAAA,EAAG,YAAc,EAAA,GAAA,EAAK,QACX,QAAC,kBAAA,GAAA,CAAA,sBAAA,EAAA,EAAuB,IAAM,EAAA,IAAA,EAAM,IAAM,EAAA,EAAA,EAAI,KAAO,EAAA,KAAA,CAAM,OAAO,CACtE,EAAA,CAAA;AAAA;AAEV,EAAA,uBAAQ,IAAA,CAAA,IAAA,EAAA,EAAK,KAAO,EAAA,CAAC,OAAO,QAAU,EAAA;AAAA,IACpC,iBAAiB,KAAM,CAAA,UAAA;AAAA,IACvB,aAAa,KAAM,CAAA;AAAA,GACpB,CACS,EAAA,QAAA,EAAA;AAAA,oBAAA,IAAA,CAAC,GAAI,EAAA,EAAA,OAAA,EAAkB,iBAAkB,EAAA,QAAA,EAAS,oBAAoB,CAAG,EAAA,KAA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AAA,IACR,YAAc,EAAA,EAAA;AAAA,IACd,UAAY,EAAA,QAAA;AAAA,IACZ,cAAgB,EAAA;AAAA;AAEpB,CAAC,CAAA"}
@@ -0,0 +1,72 @@
1
+ import {jsxs,jsx}from'react/jsx-runtime';import {useState,useMemo,useEffect}from'react';import {StyleSheet,View,Text}from'react-native';import {WebView}from'react-native-webview';import {cacheBustedUrl}from'../buildFragments.js';import {Tap,DIM}from'../../inbox/components/Tap.js';import {PreviewPlaceholder}from'./PreviewPlaceholder.js';var __defProp = Object.defineProperty;
2
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
3
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
4
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
5
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6
+ var __spreadValues = (a, b) => {
7
+ for (var prop in b || (b = {}))
8
+ if (__hasOwnProp.call(b, prop))
9
+ __defNormalProp(a, prop, b[prop]);
10
+ if (__getOwnPropSymbols)
11
+ for (var prop of __getOwnPropSymbols(b)) {
12
+ if (__propIsEnum.call(b, prop))
13
+ __defNormalProp(a, prop, b[prop]);
14
+ }
15
+ return a;
16
+ };
17
+ const DESKTOP_VIEWPORT_SCRIPT = `(function(){try{var m=document.querySelector('meta[name="viewport"]');if(!m){m=document.createElement('meta');m.setAttribute('name','viewport');(document.head||document.documentElement).appendChild(m);}m.setAttribute('content','width=1280');}catch(e){}})();true;`;
18
+ function PreviewFrame({
19
+ url,
20
+ nonce,
21
+ viewport,
22
+ theme,
23
+ onWake,
24
+ waking = false
25
+ }) {
26
+ const [state, setState] = useState("loading");
27
+ const [retry, setRetry] = useState(0);
28
+ const source = useMemo(() => ({
29
+ uri: nonce || retry ? cacheBustedUrl(url, `${nonce}-${retry}`) : url
30
+ }), [url, nonce, retry]);
31
+ useEffect(() => setState("loading"), [source.uri, viewport]);
32
+ useEffect(() => {
33
+ if (state === "asleep") onWake == null ? void 0 : onWake();
34
+ }, [state]);
35
+ if (state === "asleep" || state === "failed") {
36
+ const trying = state === "asleep" && waking;
37
+ return /* @__PURE__ */ jsxs(View, { style: [styles.fill, {
38
+ backgroundColor: theme.card
39
+ }], testID: "webbuilder-preview-down", children: [
40
+ /* @__PURE__ */ jsx(PreviewPlaceholder, { theme, label: trying || state === "asleep" ? "Loading preview, please wait\u2026" : "The preview didn't load. Check your connection." }),
41
+ !trying ? /* @__PURE__ */ jsx(Tap, { onPress: () => setRetry((n) => n + 1), accessibilityRole: "button", style: styles.retry, pressedStyle: DIM, testID: "webbuilder-preview-retry", children: /* @__PURE__ */ jsx(Text, { style: [styles.retryText, {
42
+ color: theme.accent
43
+ }], children: "Try again" }) }) : null
44
+ ] });
45
+ }
46
+ return /* @__PURE__ */ jsxs(View, { style: [styles.fill, {
47
+ backgroundColor: theme.card
48
+ }], children: [
49
+ /* @__PURE__ */ jsx(WebView, { source, style: styles.fill, originWhitelist: ["*"], javaScriptEnabled: true, domStorageEnabled: true, allowsInlineMediaPlayback: true, setSupportMultipleWindows: false, scalesPageToFit: viewport === "desktop", injectedJavaScript: viewport === "desktop" ? DESKTOP_VIEWPORT_SCRIPT : void 0, onLoadEnd: () => setState((s) => s === "loading" ? "ready" : s), onError: () => setState("failed"), onHttpError: (event) => {
50
+ if (event.nativeEvent.statusCode >= 500) setState("asleep");
51
+ }, testID: "webbuilder-preview" }, `${source.uri}-${viewport}`),
52
+ state === "loading" ? /* @__PURE__ */ jsx(View, { style: [styles.loading, {
53
+ backgroundColor: theme.card
54
+ }], pointerEvents: "none", children: /* @__PURE__ */ jsx(PreviewPlaceholder, { theme, label: "Loading preview, please wait\u2026" }) }) : null
55
+ ] });
56
+ }
57
+ const styles = StyleSheet.create({
58
+ fill: {
59
+ flex: 1
60
+ },
61
+ loading: __spreadValues({}, StyleSheet.absoluteFillObject),
62
+ retry: {
63
+ position: "absolute",
64
+ bottom: 40,
65
+ alignSelf: "center",
66
+ padding: 10
67
+ },
68
+ retryText: {
69
+ fontSize: 15,
70
+ fontWeight: "600"
71
+ }
72
+ });export{DESKTOP_VIEWPORT_SCRIPT,PreviewFrame};//# sourceMappingURL=PreviewFrame.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PreviewFrame.js","sources":["../../../../src/features/webbuilder/components/PreviewFrame.tsx"],"sourcesContent":["/**\n * The live preview: the build's sandbox dev server in a WebView, the phone\n * twin of the web CreationView iframe. `nonce` re-fetches it (the web\n * `?wb=<n>` cache-bust); `viewport` 'desktop' lays the page out at 1280px and\n * fits it to the screen, the way the web device toggle shows a wide layout.\n *\n * A sandbox that slept or whose dev server stopped answers 5xx from the\n * sandbox host (\"Closed Port\", \"Sandbox not found\"). That reads as asleep,\n * with a way to wake it, not as an error page inside the frame.\n */\nimport React, { useEffect, useMemo, useState } from 'react';\nimport { StyleSheet, Text, View } from 'react-native';\nimport { WebView } from 'react-native-webview';\nimport { cacheBustedUrl } from '../buildFragments';\nimport type { WebBuilderTheme } from '../webbuilderTheme';\nimport { DIM, Tap } from '../../inbox/components/Tap';\nimport { PreviewPlaceholder } from './PreviewPlaceholder';\n\nexport type PreviewViewport = 'phone' | 'desktop';\n\n/** Lays the page out at desktop width; the WebView then fits it to the frame. */\nexport const DESKTOP_VIEWPORT_SCRIPT = `(function(){try{var m=document.querySelector('meta[name=\"viewport\"]');if(!m){m=document.createElement('meta');m.setAttribute('name','viewport');(document.head||document.documentElement).appendChild(m);}m.setAttribute('content','width=1280');}catch(e){}})();true;`;\n\ntype FrameState = 'loading' | 'ready' | 'asleep' | 'failed';\n\nexport function PreviewFrame({\n url,\n nonce,\n viewport,\n theme,\n onWake,\n waking = false,\n}: {\n url: string;\n nonce: number;\n viewport: PreviewViewport;\n theme: WebBuilderTheme;\n /** Ask the agent to restart the preview. */\n onWake?: () => void;\n /** A wake (or any build) is running; the asleep state shows progress instead of the button. */\n waking?: boolean;\n}) {\n const [state, setState] = useState<FrameState>('loading');\n const [retry, setRetry] = useState(0);\n const source = useMemo(\n () => ({ uri: nonce || retry ? cacheBustedUrl(url, `${nonce}-${retry}`) : url }),\n [url, nonce, retry],\n );\n\n useEffect(() => setState('loading'), [source.uri, viewport]);\n // A sandbox that answers 5xx slept or stopped: start it right away, once per page load.\n useEffect(() => {\n if (state === 'asleep') onWake?.();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [state]);\n\n if (state === 'asleep' || state === 'failed') {\n // Asleep is not an error the person has to deal with: the wake already started\n // (effect above), so they see the page on its way, not the sandbox host's 502.\n const trying = state === 'asleep' && waking;\n return (\n <View style={[styles.fill, { backgroundColor: theme.card }]} testID=\"webbuilder-preview-down\">\n <PreviewPlaceholder\n theme={theme}\n label={\n trying || state === 'asleep'\n ? 'Loading preview, please wait…'\n : \"The preview didn't load. Check your connection.\"\n }\n />\n {!trying ? (\n <Tap\n onPress={() => setRetry((n) => n + 1)}\n accessibilityRole=\"button\"\n style={styles.retry}\n pressedStyle={DIM}\n testID=\"webbuilder-preview-retry\"\n >\n <Text style={[styles.retryText, { color: theme.accent }]}>Try again</Text>\n </Tap>\n ) : null}\n </View>\n );\n }\n\n return (\n <View style={[styles.fill, { backgroundColor: theme.card }]}>\n <WebView\n key={`${source.uri}-${viewport}`}\n source={source}\n style={styles.fill}\n originWhitelist={['*']}\n javaScriptEnabled\n domStorageEnabled\n allowsInlineMediaPlayback\n setSupportMultipleWindows={false}\n scalesPageToFit={viewport === 'desktop'}\n injectedJavaScript={viewport === 'desktop' ? DESKTOP_VIEWPORT_SCRIPT : undefined}\n onLoadEnd={() => setState((s) => (s === 'loading' ? 'ready' : s))}\n onError={() => setState('failed')}\n onHttpError={(event) => {\n if (event.nativeEvent.statusCode >= 500) setState('asleep');\n }}\n testID=\"webbuilder-preview\"\n />\n {state === 'loading' ? (\n <View style={[styles.loading, { backgroundColor: theme.card }]} pointerEvents=\"none\">\n <PreviewPlaceholder theme={theme} label=\"Loading preview, please wait…\" />\n </View>\n ) : null}\n </View>\n );\n}\n\nconst styles = StyleSheet.create({\n fill: { flex: 1 },\n loading: { ...StyleSheet.absoluteFillObject },\n retry: { position: 'absolute', bottom: 40, alignSelf: 'center', padding: 10 },\n retryText: { fontSize: 15, fontWeight: '600' },\n});\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAoBO,MAAM,uBAA0B,GAAA,CAAA,sQAAA;AAEhC,SAAS,YAAa,CAAA;AAAA,EAC3B,GAAA;AAAA,EACA,KAAA;AAAA,EACA,QAAA;AAAA,EACA,KAAA;AAAA,EACA,MAAA;AAAA,EACA,MAAS,GAAA;AACX,CASG,EAAA;AACD,EAAA,MAAM,CAAC,KAAA,EAAO,QAAQ,CAAA,GAAI,SAAqB,SAAS,CAAA;AACxD,EAAA,MAAM,CAAC,KAAA,EAAO,QAAQ,CAAA,GAAI,SAAS,CAAC,CAAA;AACpC,EAAM,MAAA,MAAA,GAAS,QAAQ,OAAO;AAAA,IAC5B,GAAA,EAAK,KAAS,IAAA,KAAA,GAAQ,cAAe,CAAA,GAAA,EAAK,GAAG,KAAK,CAAA,CAAA,EAAI,KAAK,CAAA,CAAE,CAAI,GAAA;AAAA,GAC/D,CAAA,EAAA,CAAC,GAAK,EAAA,KAAA,EAAO,KAAK,CAAC,CAAA;AACvB,EAAU,SAAA,CAAA,MAAM,SAAS,SAAS,CAAA,EAAG,CAAC,MAAO,CAAA,GAAA,EAAK,QAAQ,CAAC,CAAA;AAE3D,EAAA,SAAA,CAAU,MAAM;AACd,IAAA,IAAI,UAAU,QAAU,EAAA,MAAA,IAAA,IAAA,GAAA,MAAA,GAAA,MAAA,EAAA;AAAA,GAE1B,EAAG,CAAC,KAAK,CAAC,CAAA;AACV,EAAI,IAAA,KAAA,KAAU,QAAY,IAAA,KAAA,KAAU,QAAU,EAAA;AAG5C,IAAM,MAAA,MAAA,GAAS,UAAU,QAAY,IAAA,MAAA;AACrC,IAAA,uBAAQ,IAAA,CAAA,IAAA,EAAA,EAAK,KAAO,EAAA,CAAC,OAAO,IAA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AS,QAAQ,CAAA,EAAG,aAAa,CAAS,KAAA,KAAA;AAChc,MAAA,IAAI,KAAM,CAAA,WAAA,CAAY,UAAc,IAAA,GAAA,WAAc,QAAQ,CAAA;AAAA,KAC5D,EAAG,QAAO,oBAFY,EAAA,EAAA,CAAA,EAAG,OAAO,GAAG,CAAA,CAAA,EAAI,QAAQ,CAEhB,CAAA,CAAA;AAAA,IACtB,UAAU,SAAY,mBAAA,GAAA,CAAC,QAAK,KAAO,EAAA,CAAC,OAAO,OAAS,EAAA;AAAA,MAC3D,iBAAiB,KAAM,CAAA;AAAA,KACxB,CAAG,EAAA,aAAA,EAAc,MACF,EAAA,QAAA,kBAAA,GAAA,CAAC,sBAAmB,KAAc,EAAA,KAAA,EAAM,oCAAgC,EAAA,CAAA,EAC5E,CAAU,GAAA;AAAA,GAClB,EAAA,CAAA;AACR;AACA,MAAM,MAAA,GAAS,WAAW,MAAO,CAAA;AAAA,EAC/B,IAAM,EAAA;AAAA,IACJ,IAAM,EAAA;AAAA,GACR;AAAA,EACA,OAAA,EAAS,mBACJ,UAAW,CAAA,kBAAA,CAAA;AAAA,EAEhB,KAAO,EAAA;AAAA,IACL,QAAU,EAAA,UAAA;AAAA,IACV,MAAQ,EAAA,EAAA;AAAA,IACR,SAAW,EAAA,QAAA;AAAA,IACX,OAAS,EAAA;AAAA,GACX;AAAA,EACA,SAAW,EAAA;AAAA,IACT,QAAU,EAAA,EAAA;AAAA,IACV,UAAY,EAAA;AAAA;AAEhB,CAAC,CAAA"}
@@ -0,0 +1,107 @@
1
+ import {jsxs,jsx}from'react/jsx-runtime';import {StyleSheet,View,Text}from'react-native';function PreviewPlaceholder({
2
+ theme,
3
+ label,
4
+ compact = false
5
+ }) {
6
+ const block = {
7
+ backgroundColor: theme.chip
8
+ };
9
+ return /* @__PURE__ */ jsxs(View, { style: styles.center, accessibilityLabel: label != null ? label : "Loading preview", children: [
10
+ /* @__PURE__ */ jsxs(View, { style: [styles.window, compact && styles.windowCompact, {
11
+ borderColor: theme.border,
12
+ backgroundColor: theme.card
13
+ }], children: [
14
+ /* @__PURE__ */ jsx(View, { style: [styles.chrome, {
15
+ borderBottomColor: theme.border
16
+ }], children: [0, 1, 2].map((i) => /* @__PURE__ */ jsx(View, { style: [styles.dot, {
17
+ borderColor: theme.border
18
+ }] }, i)) }),
19
+ /* @__PURE__ */ jsxs(View, { style: styles.body, children: [
20
+ /* @__PURE__ */ jsxs(View, { style: styles.row, children: [
21
+ /* @__PURE__ */ jsx(View, { style: [styles.tile, styles.tileSmall, block] }),
22
+ /* @__PURE__ */ jsx(View, { style: [styles.tile, styles.tileWide, block] })
23
+ ] }),
24
+ /* @__PURE__ */ jsxs(View, { style: styles.row, children: [
25
+ /* @__PURE__ */ jsxs(View, { style: styles.lines, children: [
26
+ /* @__PURE__ */ jsx(View, { style: [styles.line, block] }),
27
+ /* @__PURE__ */ jsx(View, { style: [styles.line, block] }),
28
+ /* @__PURE__ */ jsx(View, { style: [styles.line, styles.lineShort, block] })
29
+ ] }),
30
+ /* @__PURE__ */ jsx(View, { style: [styles.tile, styles.tileSide, block] })
31
+ ] })
32
+ ] })
33
+ ] }),
34
+ label ? /* @__PURE__ */ jsx(Text, { style: [styles.label, {
35
+ color: theme.muted
36
+ }], children: label }) : null
37
+ ] });
38
+ }
39
+ const styles = StyleSheet.create({
40
+ center: {
41
+ flex: 1,
42
+ alignItems: "center",
43
+ justifyContent: "center",
44
+ padding: 24,
45
+ gap: 22
46
+ },
47
+ window: {
48
+ width: 220,
49
+ borderRadius: 14,
50
+ borderWidth: 1,
51
+ overflow: "hidden"
52
+ },
53
+ windowCompact: {
54
+ width: 180
55
+ },
56
+ chrome: {
57
+ flexDirection: "row",
58
+ gap: 5,
59
+ paddingHorizontal: 10,
60
+ paddingVertical: 8,
61
+ borderBottomWidth: 1
62
+ },
63
+ dot: {
64
+ width: 8,
65
+ height: 8,
66
+ borderRadius: 4,
67
+ borderWidth: 1
68
+ },
69
+ body: {
70
+ padding: 14,
71
+ gap: 10
72
+ },
73
+ row: {
74
+ flexDirection: "row",
75
+ gap: 8
76
+ },
77
+ tile: {
78
+ height: 42,
79
+ borderRadius: 8
80
+ },
81
+ tileSmall: {
82
+ flex: 4
83
+ },
84
+ tileWide: {
85
+ flex: 5
86
+ },
87
+ tileSide: {
88
+ flex: 4,
89
+ height: 44
90
+ },
91
+ lines: {
92
+ flex: 5,
93
+ gap: 6,
94
+ justifyContent: "center"
95
+ },
96
+ line: {
97
+ height: 9,
98
+ borderRadius: 5
99
+ },
100
+ lineShort: {
101
+ width: "55%"
102
+ },
103
+ label: {
104
+ fontSize: 15,
105
+ textAlign: "center"
106
+ }
107
+ });export{PreviewPlaceholder};//# sourceMappingURL=PreviewPlaceholder.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"PreviewPlaceholder.js","sources":["../../../../src/features/webbuilder/components/PreviewPlaceholder.tsx"],"sourcesContent":["/**\n * A page that is not there yet: a quiet wireframe of a browser window, the way\n * Manus waits for a preview. Shown while a sleeping sandbox is being started,\n * so the person sees \"it is coming\", never the sandbox host's error page.\n */\nimport React from 'react';\nimport { StyleSheet, Text, View } from 'react-native';\nimport type { WebBuilderTheme } from '../webbuilderTheme';\n\nexport function PreviewPlaceholder({\n theme,\n label,\n compact = false,\n}: {\n theme: WebBuilderTheme;\n /** One line under the wireframe, e.g. \"Loading preview, please wait…\". */\n label?: string | null;\n /** The chat card's smaller version. */\n compact?: boolean;\n}) {\n const block = { backgroundColor: theme.chip };\n return (\n <View style={styles.center} accessibilityLabel={label ?? 'Loading preview'}>\n <View\n style={[\n styles.window,\n compact && styles.windowCompact,\n { borderColor: theme.border, backgroundColor: theme.card },\n ]}\n >\n <View style={[styles.chrome, { borderBottomColor: theme.border }]}>\n {[0, 1, 2].map((i) => (\n <View key={i} style={[styles.dot, { borderColor: theme.border }]} />\n ))}\n </View>\n <View style={styles.body}>\n <View style={styles.row}>\n <View style={[styles.tile, styles.tileSmall, block]} />\n <View style={[styles.tile, styles.tileWide, block]} />\n </View>\n <View style={styles.row}>\n <View style={styles.lines}>\n <View style={[styles.line, block]} />\n <View style={[styles.line, block]} />\n <View style={[styles.line, styles.lineShort, block]} />\n </View>\n <View style={[styles.tile, styles.tileSide, block]} />\n </View>\n </View>\n </View>\n {label ? <Text style={[styles.label, { color: theme.muted }]}>{label}</Text> : null}\n </View>\n );\n}\n\nconst styles = StyleSheet.create({\n center: { flex: 1, alignItems: 'center', justifyContent: 'center', padding: 24, gap: 22 },\n window: { width: 220, borderRadius: 14, borderWidth: 1, overflow: 'hidden' },\n windowCompact: { width: 180 },\n chrome: { flexDirection: 'row', gap: 5, paddingHorizontal: 10, paddingVertical: 8, borderBottomWidth: 1 },\n dot: { width: 8, height: 8, borderRadius: 4, borderWidth: 1 },\n body: { padding: 14, gap: 10 },\n row: { flexDirection: 'row', gap: 8 },\n tile: { height: 42, borderRadius: 8 },\n tileSmall: { flex: 4 },\n tileWide: { flex: 5 },\n tileSide: { flex: 4, height: 44 },\n lines: { flex: 5, gap: 6, justifyContent: 'center' },\n line: { height: 9, borderRadius: 5 },\n lineShort: { width: '55%' },\n label: { fontSize: 15, textAlign: 'center' },\n});\n"],"names":[],"mappings":"yFAQO,SAAS,kBAAmB,CAAA;AAAA,EACjC,KAAA;AAAA,EACA,KAAA;AAAA,EACA,OAAU,GAAA;AACZ,CAMG,EAAA;AACD,EAAA,MAAM,KAAQ,GAAA;AAAA,IACZ,iBAAiB,KAAM,CAAA;AAAA,GACzB;AACA,EAAA,4BAAQ,IAAK,EAAA,EAAA,KAAA,EAAO,OAAO,MAAQ,EAAA,kBAAA,EAAoB,wBAAS,iBACtD,EAAA,QAAA,EAAA;AAAA,oBAAA,IAAA,CAAC,QAAK,KAAO,EAAA,CAAC,OAAO,MAAQ,EAAA,OAAA,IAAW,OAAO,aAAe,EAAA;AAAA,MACpE,aAAa,KAAM,CAAA,MAAA;AAAA,MACnB,iBAAiB,KAAM,CAAA;AAAA,KACxB,CACW,EAAA,QAAA,EAAA;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