@adminide-stack/yantra-mobile 12.0.125-alpha.1 → 12.0.126
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/lib/features/canvas/AudioEditorExperience.js +207 -109
- package/lib/features/canvas/AudioEditorExperience.js.map +1 -1
- package/lib/features/canvas/CanvasAgentChatPane.js +87 -72
- package/lib/features/canvas/CanvasAgentChatPane.js.map +1 -1
- package/lib/features/canvas/CanvasBoardsGrid.js +494 -387
- package/lib/features/canvas/CanvasBoardsGrid.js.map +1 -1
- package/lib/features/canvas/CanvasChatResultCard.js +78 -59
- package/lib/features/canvas/CanvasChatResultCard.js.map +1 -1
- package/lib/features/canvas/CanvasEditToolsPanel.js +126 -84
- package/lib/features/canvas/CanvasEditToolsPanel.js.map +1 -1
- package/lib/features/canvas/CanvasExperience.js +108 -126
- package/lib/features/canvas/CanvasExperience.js.map +1 -1
- package/lib/features/canvas/CanvasGeneratePanel.js +178 -166
- package/lib/features/canvas/CanvasGeneratePanel.js.map +1 -1
- package/lib/features/canvas/CanvasLibrarySheet.js +119 -123
- package/lib/features/canvas/CanvasLibrarySheet.js.map +1 -1
- package/lib/features/canvas/CanvasLooksPanel.js +113 -89
- package/lib/features/canvas/CanvasLooksPanel.js.map +1 -1
- package/lib/features/canvas/CanvasModelPicker.js +79 -79
- package/lib/features/canvas/CanvasModelPicker.js.map +1 -1
- package/lib/features/canvas/CanvasTasksPanel.js +193 -128
- package/lib/features/canvas/CanvasTasksPanel.js.map +1 -1
- package/lib/features/canvas/CanvasTemplatesPanel.js +106 -94
- package/lib/features/canvas/CanvasTemplatesPanel.js.map +1 -1
- package/lib/features/canvas/CanvasToolDock.js +195 -127
- package/lib/features/canvas/CanvasToolDock.js.map +1 -1
- package/lib/features/canvas/FrameExtractorExperience.js +163 -100
- package/lib/features/canvas/FrameExtractorExperience.js.map +1 -1
- package/lib/features/canvas/GeneratorReferenceSlots.js +132 -69
- package/lib/features/canvas/GeneratorReferenceSlots.js.map +1 -1
- package/lib/features/canvas/ImageEditorExperience.js +278 -209
- package/lib/features/canvas/ImageEditorExperience.js.map +1 -1
- package/lib/features/canvas/InfluencerStudioExperience.js +167 -125
- package/lib/features/canvas/InfluencerStudioExperience.js.map +1 -1
- package/lib/features/canvas/MoodboardExperience.js +102 -85
- package/lib/features/canvas/MoodboardExperience.js.map +1 -1
- package/lib/features/canvas/NativeCanvasViewer.js +203 -192
- package/lib/features/canvas/NativeCanvasViewer.js.map +1 -1
- package/lib/features/canvas/PromoContextFields.js +125 -92
- package/lib/features/canvas/PromoContextFields.js.map +1 -1
- package/lib/features/canvas/SetStudioExperience.js +225 -143
- package/lib/features/canvas/SetStudioExperience.js.map +1 -1
- package/lib/features/canvas/VideoClipsExperience.js +126 -92
- package/lib/features/canvas/VideoClipsExperience.js.map +1 -1
- package/lib/features/canvas/VideoEditExperience.js +154 -142
- package/lib/features/canvas/VideoEditExperience.js.map +1 -1
- package/lib/features/canvas/VideoEditorExperience.js +551 -492
- package/lib/features/canvas/VideoEditorExperience.js.map +1 -1
- package/lib/features/canvas/VideoGeneratorExperience.js +284 -131
- package/lib/features/canvas/VideoGeneratorExperience.js.map +1 -1
- package/lib/features/canvas/canvasTasks.js +7 -3
- package/lib/features/canvas/canvasTasks.js.map +1 -1
- package/lib/features/canvas/canvasTheme.js +265 -0
- package/lib/features/canvas/canvasTheme.js.map +1 -0
- package/lib/features/canvas/canvasUi.js +381 -0
- package/lib/features/canvas/canvasUi.js.map +1 -0
- package/lib/features/canvas/recorder/CameraRecorderExperience.js +109 -52
- package/lib/features/canvas/recorder/CameraRecorderExperience.js.map +1 -1
- package/lib/features/canvas/serverTasks.js +1 -1
- package/lib/features/canvas/serverTasks.js.map +1 -1
- package/lib/features/canvas/set/SetViewportWebView.js +1 -1
- package/lib/features/canvas/set/SetViewportWebView.js.map +1 -1
- package/lib/features/canvas/videoEditor/BlurBoxOverlay.js +8 -7
- package/lib/features/canvas/videoEditor/BlurBoxOverlay.js.map +1 -1
- package/lib/features/canvas/videoEditor/ExportTaskCard.js +44 -41
- package/lib/features/canvas/videoEditor/ExportTaskCard.js.map +1 -1
- package/lib/features/canvas/videoEditor/agent/AgentCutPane.js +50 -45
- package/lib/features/canvas/videoEditor/agent/AgentCutPane.js.map +1 -1
- package/lib/features/canvas/videoEditor/exportTask.js +3 -2
- package/lib/features/canvas/videoEditor/exportTask.js.map +1 -1
- package/lib/features/canvas/videoEditor/formWidgets.js +116 -64
- package/lib/features/canvas/videoEditor/formWidgets.js.map +1 -1
- package/lib/features/canvas/videoEditor/produce/ProduceVideoSheet.js +77 -63
- package/lib/features/canvas/videoEditor/produce/ProduceVideoSheet.js.map +1 -1
- package/lib/features/canvas/videoEditor/tools/ToolsDrawer.js +95 -79
- package/lib/features/canvas/videoEditor/tools/ToolsDrawer.js.map +1 -1
- package/lib/features/design/DesignEditorExperience.js +241 -160
- package/lib/features/design/DesignEditorExperience.js.map +1 -1
- package/lib/features/design/DesignExperience.js +300 -143
- package/lib/features/design/DesignExperience.js.map +1 -1
- package/lib/features/health/HealthSyncRunner.js +9 -1
- package/lib/features/health/HealthSyncRunner.js.map +1 -1
- package/lib/features/health/backgroundSync.js +41 -0
- package/lib/features/health/backgroundSync.js.map +1 -0
- package/lib/features/health/healthConnectBackground.js +32 -0
- package/lib/features/health/healthConnectBackground.js.map +1 -0
- package/lib/features/health/healthConnectReader.js +16 -2
- package/lib/features/health/healthConnectReader.js.map +1 -1
- package/lib/features/health/healthSync.js +31 -3
- package/lib/features/health/healthSync.js.map +1 -1
- package/lib/features/health/healthSyncStore.js +89 -5
- package/lib/features/health/healthSyncStore.js.map +1 -1
- package/lib/features/health/healthkitBackground.js +17 -0
- package/lib/features/health/healthkitBackground.js.map +1 -0
- package/lib/features/health/reader.js.map +1 -1
- package/lib/features/health/sessionVault.js +38 -0
- package/lib/features/health/sessionVault.js.map +1 -0
- package/lib/features/health/syncState.js.map +1 -1
- package/lib/features/webbuilder/WebBuilderExperience.js +1 -1
- package/lib/features/webbuilder/WebBuilderExperience.js.map +1 -1
- package/lib/features/webbuilder/buildFragments.js +3 -2
- package/lib/features/webbuilder/buildFragments.js.map +1 -1
- package/lib/features/webbuilder/components/PublishSheet.js +1 -1
- package/lib/features/webbuilder/components/PublishSheet.js.map +1 -1
- package/lib/features/webbuilder/webbuilderPrompts.js +2 -5
- package/lib/features/webbuilder/webbuilderPrompts.js.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/screens/Health/index.js +12 -2
- package/lib/screens/Health/index.js.map +1 -1
- package/lib/screens/WebBuilderNative/sandboxProxyApi.js +120 -0
- package/lib/screens/WebBuilderNative/sandboxProxyApi.js.map +1 -0
- package/lib/screens/WebBuilderNative/useRestoredSandboxes.js.map +1 -1
- package/lib/screens/WebBuilderNative/useWebBuilderHost.js +26 -4
- package/lib/screens/WebBuilderNative/useWebBuilderHost.js.map +1 -1
- package/lib/screens/WebBuilderNative/webbuilderTransport.js +110 -7
- package/lib/screens/WebBuilderNative/webbuilderTransport.js.map +1 -1
- package/package.json +6 -4
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import {jsxs,jsx,Fragment}from'react/jsx-runtime';import {useState,useMemo,useEffect,useCallback}from'react';import {
|
|
1
|
+
import {jsxs,jsx,Fragment}from'react/jsx-runtime';import {useState,useMemo,useEffect,useCallback}from'react';import {useWindowDimensions,View,Text,ScrollView,FlatList,StyleSheet}from'react-native';import {MaterialCommunityIcons}from'@expo/vector-icons';import {Image}from'expo-image';import {isUnsetBoardTitle}from'./canvasCore.js';import {CANVAS_BOARD_PAGE_SIZE}from'./canvasBoardsCatalog.js';import {mergeWork,availableFilters,matchesFilter,WORK_FILTERS,designNoun,pageCount,boardCover,videoCoverFrame}from'./homeWork.js';import {resultUrl}from'./videoEditor/mediaActions.js';import {unwrapProxyUrl}from'./videoEditor/remoteMediaClient.js';import {renewMediaUrl,useMediaSource}from'./useMediaSource.js';import {useCanvasTheme,themedStyles,CanvasThemeToggle}from'./canvasTheme.js';import {Pressable,pressedStyle,SectionHeader,Segmented,RADIUS,SPACE,CoverPlaceholder,Skeleton,TYPE}from'./canvasUi.js';var __defProp = Object.defineProperty;
|
|
2
|
+
var __defProps = Object.defineProperties;
|
|
3
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
2
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
6
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
@@ -14,19 +16,72 @@ var __spreadValues = (a, b) => {
|
|
|
14
16
|
}
|
|
15
17
|
return a;
|
|
16
18
|
};
|
|
19
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
17
20
|
const MINUTE = 6e4;
|
|
18
21
|
const HOUR = 60 * MINUTE;
|
|
19
22
|
const DAY = 24 * HOUR;
|
|
20
|
-
const GUTTER =
|
|
21
|
-
const
|
|
22
|
-
const THUMB_HEIGHT = 140;
|
|
23
|
+
const GUTTER = SPACE.lg;
|
|
24
|
+
const COVER_STALL_MS = 12e3;
|
|
23
25
|
function relativeTime(ts) {
|
|
24
26
|
const diff = Date.now() - ts;
|
|
25
27
|
if (diff < HOUR) return `${Math.max(1, Math.round(diff / MINUTE))}m ago`;
|
|
26
28
|
if (diff < DAY) return `${Math.round(diff / HOUR)}h ago`;
|
|
27
29
|
if (diff < 30 * DAY) return `${Math.round(diff / DAY)}d ago`;
|
|
28
|
-
return new Date(ts).toLocaleDateString(
|
|
30
|
+
return new Date(ts).toLocaleDateString(void 0, {
|
|
31
|
+
month: "short",
|
|
32
|
+
day: "numeric"
|
|
33
|
+
});
|
|
29
34
|
}
|
|
35
|
+
const LANE_HUES = {
|
|
36
|
+
image: {
|
|
37
|
+
light: ["#fef3c7", "#b45309"],
|
|
38
|
+
dark: ["rgba(251,191,36,0.14)", "#fcd34d"]
|
|
39
|
+
},
|
|
40
|
+
video: {
|
|
41
|
+
light: ["#ffe4e6", "#be123c"],
|
|
42
|
+
dark: ["rgba(251,113,133,0.14)", "#fda4af"]
|
|
43
|
+
},
|
|
44
|
+
audio: {
|
|
45
|
+
light: ["#e0f2fe", "#0369a1"],
|
|
46
|
+
dark: ["rgba(56,189,248,0.14)", "#7dd3fc"]
|
|
47
|
+
},
|
|
48
|
+
slides: {
|
|
49
|
+
light: ["#ede9fe", "#6d28d9"],
|
|
50
|
+
dark: ["rgba(167,139,250,0.16)", "#c4b5fd"]
|
|
51
|
+
},
|
|
52
|
+
clips: {
|
|
53
|
+
light: ["#d1fae5", "#047857"],
|
|
54
|
+
dark: ["rgba(52,211,153,0.14)", "#6ee7b7"]
|
|
55
|
+
},
|
|
56
|
+
promo: {
|
|
57
|
+
light: ["#ffedd5", "#c2410c"],
|
|
58
|
+
dark: ["rgba(251,146,60,0.14)", "#fdba74"]
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
const FORMAT_SHAPE = {
|
|
62
|
+
social: {
|
|
63
|
+
w: 1,
|
|
64
|
+
h: 1
|
|
65
|
+
},
|
|
66
|
+
carousel: {
|
|
67
|
+
w: 4,
|
|
68
|
+
h: 5,
|
|
69
|
+
stack: true
|
|
70
|
+
},
|
|
71
|
+
flyer: {
|
|
72
|
+
w: 3,
|
|
73
|
+
h: 4
|
|
74
|
+
},
|
|
75
|
+
logo: {
|
|
76
|
+
w: 1,
|
|
77
|
+
h: 1,
|
|
78
|
+
round: true
|
|
79
|
+
},
|
|
80
|
+
tshirt: {
|
|
81
|
+
w: 5,
|
|
82
|
+
h: 6
|
|
83
|
+
}
|
|
84
|
+
};
|
|
30
85
|
function CanvasBoardsGrid({
|
|
31
86
|
boards,
|
|
32
87
|
onOpen,
|
|
@@ -40,12 +95,16 @@ function CanvasBoardsGrid({
|
|
|
40
95
|
onRecreateLook,
|
|
41
96
|
runAction
|
|
42
97
|
}) {
|
|
98
|
+
const theme = useCanvasTheme();
|
|
99
|
+
const styles = makeStyles(theme);
|
|
43
100
|
const {
|
|
44
101
|
width
|
|
45
102
|
} = useWindowDimensions();
|
|
46
103
|
const tileWidth = Math.max(140, (width - GUTTER * 3) / 2);
|
|
104
|
+
const laneWidth = (width - GUTTER * 2 - SPACE.sm * 2) / 3;
|
|
47
105
|
const [visible, setVisible] = useState(CANVAS_BOARD_PAGE_SIZE);
|
|
48
106
|
const [filter, setFilter] = useState("all");
|
|
107
|
+
const renew = useMemo(() => renewMediaUrl(runAction), [runAction]);
|
|
49
108
|
const work = useMemo(() => mergeWork(boards, designs), [boards, designs]);
|
|
50
109
|
const filters = useMemo(() => availableFilters(work), [work]);
|
|
51
110
|
const active = filters.includes(filter) ? filter : "all";
|
|
@@ -63,77 +122,87 @@ function CanvasBoardsGrid({
|
|
|
63
122
|
}))], [shown, visible]);
|
|
64
123
|
const rows = useMemo(() => {
|
|
65
124
|
const chunked = [];
|
|
66
|
-
for (let i = 0; i < tiles.length; i += 2)
|
|
67
|
-
chunked.push(tiles.slice(i, i + 2));
|
|
68
|
-
}
|
|
125
|
+
for (let i = 0; i < tiles.length; i += 2) chunked.push(tiles.slice(i, i + 2));
|
|
69
126
|
return chunked;
|
|
70
127
|
}, [tiles]);
|
|
71
128
|
const loadMore = useCallback(() => {
|
|
72
|
-
setVisible((count) =>
|
|
73
|
-
if (count >= shown.length) return count;
|
|
74
|
-
return Math.min(count + CANVAS_BOARD_PAGE_SIZE, shown.length);
|
|
75
|
-
});
|
|
129
|
+
setVisible((count) => count >= shown.length ? count : Math.min(count + CANVAS_BOARD_PAGE_SIZE, shown.length));
|
|
76
130
|
}, [shown.length]);
|
|
131
|
+
const group = (id) => createGroups.find((g) => g.id === id);
|
|
132
|
+
const generate = group("generate");
|
|
133
|
+
const edit = group("edit");
|
|
134
|
+
const designGroup = group("design");
|
|
135
|
+
const lane = (tile) => {
|
|
136
|
+
const hue = LANE_HUES[tile.id];
|
|
137
|
+
const [wash, ink] = hue ? theme.isDark ? hue.dark : hue.light : [theme.card, theme.foreground];
|
|
138
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => onCreate == null ? void 0 : onCreate(tile.action, tile.id), style: ({
|
|
139
|
+
pressed
|
|
140
|
+
}) => [styles.lane, {
|
|
141
|
+
width: laneWidth,
|
|
142
|
+
backgroundColor: wash
|
|
143
|
+
}, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `${tile.label}: ${tile.hint}`, testID: `create-tile-${tile.id}`, children: [
|
|
144
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: tile.icon, size: 24, color: ink }),
|
|
145
|
+
/* @__PURE__ */ jsx(Text, { style: [styles.laneLabel, {
|
|
146
|
+
color: theme.isDark ? theme.foreground : ink
|
|
147
|
+
}], numberOfLines: 2, children: tile.label })
|
|
148
|
+
] }, tile.id);
|
|
149
|
+
};
|
|
77
150
|
const header = /* @__PURE__ */ jsxs(View, { style: styles.header, children: [
|
|
78
|
-
|
|
79
|
-
/* @__PURE__ */
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
}], accessibilityRole: "button", accessibilityLabel: `${tile.label}: ${tile.hint}`, testID: `create-tile-${tile.id}`, children: [
|
|
97
|
-
/* @__PURE__ */ jsx(View, { style: [styles.createIcon, {
|
|
98
|
-
backgroundColor: group.accent.bg
|
|
99
|
-
}], children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: tile.icon, size: 18, color: group.accent.fg }) }),
|
|
100
|
-
/* @__PURE__ */ jsxs(View, { style: styles.flexShrink, children: [
|
|
101
|
-
/* @__PURE__ */ jsx(Text, { style: styles.createLabel, numberOfLines: 1, children: tile.label }),
|
|
102
|
-
/* @__PURE__ */ jsx(Text, { style: styles.createHint, numberOfLines: 2, children: tile.hint })
|
|
103
|
-
] })
|
|
104
|
-
] }, tile.id)) })
|
|
105
|
-
] }, group.id))
|
|
151
|
+
/* @__PURE__ */ jsxs(View, { style: styles.titleRow, children: [
|
|
152
|
+
/* @__PURE__ */ jsx(Text, { style: styles.title, accessibilityRole: "header", children: "Create" }),
|
|
153
|
+
/* @__PURE__ */ jsx(CanvasThemeToggle, { size: 20, style: styles.toggle })
|
|
154
|
+
] }),
|
|
155
|
+
onAskAgent ? /* @__PURE__ */ jsxs(Pressable, { onPress: onAskAgent, style: ({
|
|
156
|
+
pressed
|
|
157
|
+
}) => [styles.prompt, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: "Ask AI Chat to make something", children: [
|
|
158
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "creation", size: 20, color: theme.mutedForeground }),
|
|
159
|
+
/* @__PURE__ */ jsx(Text, { style: styles.promptText, numberOfLines: 1, children: "Describe what you want to make" }),
|
|
160
|
+
/* @__PURE__ */ jsx(View, { style: styles.promptGo, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "arrow-up", size: 18, color: theme.primaryForeground }) })
|
|
161
|
+
] }) : null,
|
|
162
|
+
onCreate && generate ? /* @__PURE__ */ jsxs(View, { style: styles.section, children: [
|
|
163
|
+
/* @__PURE__ */ jsx(SectionHeader, { title: "Generate with AI" }),
|
|
164
|
+
/* @__PURE__ */ jsx(View, { style: styles.lanes, children: generate.tiles.map(lane) })
|
|
165
|
+
] }) : null,
|
|
166
|
+
onCreate && designGroup ? /* @__PURE__ */ jsxs(View, { style: styles.section, children: [
|
|
167
|
+
/* @__PURE__ */ jsx(SectionHeader, { title: "Design" }),
|
|
168
|
+
/* @__PURE__ */ jsx(ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, style: styles.bleed, contentContainerStyle: styles.railContent, children: designGroup.tiles.map((tile) => /* @__PURE__ */ jsx(FormatTile, { tile, onPress: () => onCreate(tile.action, tile.id) }, tile.id)) })
|
|
106
169
|
] }) : null,
|
|
107
|
-
|
|
108
|
-
/* @__PURE__ */ jsx(
|
|
109
|
-
/* @__PURE__ */ jsx(ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, contentContainerStyle: styles.
|
|
170
|
+
onCreate && edit ? /* @__PURE__ */ jsxs(View, { style: styles.section, children: [
|
|
171
|
+
/* @__PURE__ */ jsx(SectionHeader, { title: "Edit & produce" }),
|
|
172
|
+
/* @__PURE__ */ jsx(ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, style: styles.bleed, contentContainerStyle: styles.railContent, children: edit.tiles.map((tile) => /* @__PURE__ */ jsxs(Pressable, { onPress: () => onCreate(tile.action, tile.id), style: ({
|
|
173
|
+
pressed
|
|
174
|
+
}) => [styles.tool, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `${tile.label}: ${tile.hint}`, testID: `create-tile-${tile.id}`, children: [
|
|
175
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: tile.icon, size: 18, color: theme.foreground }),
|
|
176
|
+
/* @__PURE__ */ jsx(Text, { style: styles.toolLabel, children: tile.label })
|
|
177
|
+
] }, tile.id)) })
|
|
178
|
+
] }) : null,
|
|
179
|
+
featuredLooks.length > 0 && onRecreateLook ? /* @__PURE__ */ jsxs(View, { style: styles.section, children: [
|
|
180
|
+
/* @__PURE__ */ jsx(SectionHeader, { title: "Looks", detail: "Recreate a studio style" }),
|
|
181
|
+
/* @__PURE__ */ jsx(ScrollView, { horizontal: true, showsHorizontalScrollIndicator: false, style: styles.bleed, contentContainerStyle: styles.railContent, children: featuredLooks.map((look) => /* @__PURE__ */ jsxs(Pressable, { onPress: () => onRecreateLook(look), style: ({
|
|
182
|
+
pressed
|
|
183
|
+
}) => [styles.look, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `Recreate ${look.name}`, children: [
|
|
110
184
|
look.cover ? /* @__PURE__ */ jsx(Image, { source: {
|
|
111
185
|
uri: look.cover
|
|
112
|
-
}, style: styles.
|
|
113
|
-
/* @__PURE__ */ jsx(Text, { style: styles.lookName, numberOfLines: 2, children: look.name })
|
|
186
|
+
}, style: styles.fill, contentFit: "cover" }) : /* @__PURE__ */ jsx(View, { style: [styles.fill, styles.centered], children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "movie-open-outline", size: 22, color: theme.mutedForeground }) }),
|
|
187
|
+
/* @__PURE__ */ jsx(View, { style: styles.lookCaption, children: /* @__PURE__ */ jsx(Text, { style: styles.lookName, numberOfLines: 2, children: look.name }) })
|
|
114
188
|
] }, look.id)) })
|
|
115
189
|
] }) : null,
|
|
116
190
|
/* @__PURE__ */ jsxs(View, { style: styles.workHead, children: [
|
|
117
|
-
/* @__PURE__ */ jsx(
|
|
118
|
-
filters.length > 0 ? /* @__PURE__ */ jsx(
|
|
119
|
-
const on = f.id === active;
|
|
120
|
-
return /* @__PURE__ */ jsx(Pressable, { onPress: () => setFilter(f.id), style: [styles.filterChip, on && styles.filterChipOn], accessibilityRole: "button", accessibilityState: {
|
|
121
|
-
selected: on
|
|
122
|
-
}, children: /* @__PURE__ */ jsx(Text, { style: [styles.filterLabel, on && styles.filterLabelOn], children: f.label }) }, f.id);
|
|
123
|
-
}) }) : null
|
|
191
|
+
/* @__PURE__ */ jsx(SectionHeader, { title: "Your work", detail: work.length > 0 ? String(work.length) : void 0, style: styles.noMargin }),
|
|
192
|
+
filters.length > 0 ? /* @__PURE__ */ jsx(Segmented, { options: WORK_FILTERS.filter((f) => filters.includes(f.id)), value: active, onChange: setFilter, style: styles.segmented }) : null
|
|
124
193
|
] })
|
|
125
194
|
] });
|
|
126
195
|
const renderTile = (item) => {
|
|
127
196
|
var _a, _b;
|
|
128
197
|
if (item.kind === "new") {
|
|
129
|
-
return /* @__PURE__ */ jsxs(Pressable, { onPress: onNewCanvas, style:
|
|
198
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress: onNewCanvas, style: ({
|
|
199
|
+
pressed
|
|
200
|
+
}) => [{
|
|
130
201
|
width: tileWidth
|
|
131
|
-
}], accessibilityRole: "button", accessibilityLabel: "New canvas", children: [
|
|
132
|
-
/* @__PURE__ */
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
] }),
|
|
136
|
-
/* @__PURE__ */ jsx(View, { style: styles.meta, children: /* @__PURE__ */ jsx(Text, { style: styles.metaTitle, children: "New canvas" }) })
|
|
202
|
+
}, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: "New canvas", children: [
|
|
203
|
+
/* @__PURE__ */ jsx(View, { style: [styles.cover, styles.coverNew], children: /* @__PURE__ */ jsx(View, { style: styles.newPlus, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "plus", size: 24, color: theme.primaryForeground }) }) }),
|
|
204
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workTitle, children: "New canvas" }),
|
|
205
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workMeta, children: "Start blank" })
|
|
137
206
|
] });
|
|
138
207
|
}
|
|
139
208
|
const {
|
|
@@ -146,69 +215,102 @@ function CanvasBoardsGrid({
|
|
|
146
215
|
const noun = designNoun(design.doc);
|
|
147
216
|
const title2 = ((_a = design.title) == null ? void 0 : _a.trim()) || `Untitled ${noun.toLowerCase()}`;
|
|
148
217
|
const meta = [noun, pageCount(design.doc), relativeTime(design.savedAt)].filter(Boolean).join(" \xB7 ");
|
|
149
|
-
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => onOpenDesign == null ? void 0 : onOpenDesign(design.channelId), style:
|
|
218
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => onOpenDesign == null ? void 0 : onOpenDesign(design.channelId), style: ({
|
|
219
|
+
pressed
|
|
220
|
+
}) => [{
|
|
150
221
|
width: tileWidth
|
|
151
|
-
}], accessibilityRole: "button", accessibilityLabel: `Open ${noun.toLowerCase()} ${title2}`, children: [
|
|
152
|
-
/* @__PURE__ */ jsx(View, { style: styles.
|
|
153
|
-
/* @__PURE__ */
|
|
154
|
-
|
|
155
|
-
/* @__PURE__ */ jsx(Text, { style: styles.metaSub, numberOfLines: 1, children: meta })
|
|
156
|
-
] })
|
|
222
|
+
}, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `Open ${noun.toLowerCase()} ${title2}`, children: [
|
|
223
|
+
/* @__PURE__ */ jsx(View, { style: [styles.cover, styles.centered], children: /* @__PURE__ */ jsx(DesignThumb, { doc: design.doc, maxWidth: tileWidth - SPACE.xl * 2, maxHeight: tileWidth - SPACE.xl * 2 }) }),
|
|
224
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workTitle, numberOfLines: 1, children: title2 }),
|
|
225
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workMeta, numberOfLines: 1, children: meta })
|
|
157
226
|
] });
|
|
158
227
|
}
|
|
159
228
|
const {
|
|
160
229
|
board
|
|
161
230
|
} = entry;
|
|
162
231
|
const cover = boardCover(board.board.items);
|
|
163
|
-
const title = !isUnsetBoardTitle(board.title) ? board.title : ((_b = board.board.items.find((it) => it.generatedAssetName)) == null ? void 0 : _b.generatedAssetName) || "Untitled";
|
|
164
|
-
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => onOpen(board.channelId), style:
|
|
232
|
+
const title = !isUnsetBoardTitle(board.title) ? board.title : ((_b = board.board.items.find((it) => it.generatedAssetName)) == null ? void 0 : _b.generatedAssetName) || "Untitled canvas";
|
|
233
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress: () => onOpen(board.channelId), style: ({
|
|
234
|
+
pressed
|
|
235
|
+
}) => [{
|
|
165
236
|
width: tileWidth
|
|
166
|
-
}], accessibilityRole: "button", children: [
|
|
167
|
-
/* @__PURE__ */
|
|
168
|
-
|
|
169
|
-
/* @__PURE__ */ jsx(
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
" item",
|
|
174
|
-
board.itemCount === 1 ? "" : "s",
|
|
175
|
-
" \xB7",
|
|
176
|
-
" ",
|
|
177
|
-
relativeTime(board.savedAt)
|
|
178
|
-
] })
|
|
179
|
-
] })
|
|
237
|
+
}, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `Open canvas ${title}`, children: [
|
|
238
|
+
/* @__PURE__ */ jsxs(View, { style: [styles.cover, styles.centered], children: [
|
|
239
|
+
cover ? /* @__PURE__ */ jsx(BoardCover, { item: cover, seed: board.channelId, runAction, renew }, cover.src) : /* @__PURE__ */ jsx(CoverPlaceholder, { seed: board.channelId, icon: "image-multiple-outline" }),
|
|
240
|
+
board.itemCount > 1 ? /* @__PURE__ */ jsx(View, { style: styles.countBadge, pointerEvents: "none", children: /* @__PURE__ */ jsx(Text, { style: styles.countBadgeText, children: board.itemCount }) }) : null
|
|
241
|
+
] }),
|
|
242
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workTitle, numberOfLines: 1, children: title }),
|
|
243
|
+
/* @__PURE__ */ jsx(Text, { style: styles.workMeta, numberOfLines: 1, children: `Canvas \xB7 ${relativeTime(board.savedAt)}` })
|
|
180
244
|
] });
|
|
181
245
|
};
|
|
182
|
-
return /* @__PURE__ */
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
/* @__PURE__ */
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
246
|
+
return /* @__PURE__ */ jsx(View, { style: styles.plane, children: work.length === 0 ? /* @__PURE__ */ jsxs(ScrollView, { contentContainerStyle: styles.list, showsVerticalScrollIndicator: false, children: [
|
|
247
|
+
header,
|
|
248
|
+
/* @__PURE__ */ jsxs(View, { style: styles.empty, children: [
|
|
249
|
+
/* @__PURE__ */ jsx(View, { style: styles.emptyIcon, children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "image-multiple-outline", size: 26, color: theme.foreground }) }),
|
|
250
|
+
/* @__PURE__ */ jsx(Text, { style: styles.emptyTitle, children: "Nothing here yet" }),
|
|
251
|
+
/* @__PURE__ */ jsx(Text, { style: styles.emptyDetail, children: "Every chat gets its own canvas. Generate an image, video or audio and it lands here." }),
|
|
252
|
+
/* @__PURE__ */ jsxs(Pressable, { onPress: onNewCanvas, style: ({
|
|
253
|
+
pressed
|
|
254
|
+
}) => [styles.emptyCta, pressedStyle(pressed)], accessibilityRole: "button", children: [
|
|
255
|
+
/* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "plus", size: 18, color: theme.primaryForeground }),
|
|
256
|
+
/* @__PURE__ */ jsx(Text, { style: styles.emptyCtaLabel, children: "New canvas" })
|
|
193
257
|
] })
|
|
194
|
-
] })
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
258
|
+
] })
|
|
259
|
+
] }) : /* @__PURE__ */ jsx(FlatList, { data: rows, keyExtractor: (pair) => pair.map((item) => item.id).join(":"), contentContainerStyle: styles.list, showsVerticalScrollIndicator: false, onEndReached: loadMore, onEndReachedThreshold: 0.4, ListHeaderComponent: header, renderItem: ({
|
|
260
|
+
item: pair
|
|
261
|
+
}) => /* @__PURE__ */ jsxs(View, { style: styles.row, children: [
|
|
262
|
+
pair.map((entry) => /* @__PURE__ */ jsx(View, { children: renderTile(entry) }, entry.id)),
|
|
263
|
+
pair.length < 2 ? /* @__PURE__ */ jsx(View, { style: {
|
|
264
|
+
width: tileWidth
|
|
265
|
+
} }) : null
|
|
266
|
+
] }) }) });
|
|
267
|
+
}
|
|
268
|
+
function FormatTile({
|
|
269
|
+
tile,
|
|
270
|
+
onPress
|
|
271
|
+
}) {
|
|
272
|
+
var _a;
|
|
273
|
+
const theme = useCanvasTheme();
|
|
274
|
+
const styles = makeStyles(theme);
|
|
275
|
+
const shape = (_a = FORMAT_SHAPE[tile.id]) != null ? _a : {
|
|
276
|
+
w: 1,
|
|
277
|
+
h: 1
|
|
278
|
+
};
|
|
279
|
+
const box = 56;
|
|
280
|
+
const scale = box / Math.max(shape.w, shape.h);
|
|
281
|
+
const pageW = shape.w * scale;
|
|
282
|
+
const pageH = shape.h * scale;
|
|
283
|
+
return /* @__PURE__ */ jsxs(Pressable, { onPress, style: ({
|
|
284
|
+
pressed
|
|
285
|
+
}) => [styles.format, pressedStyle(pressed)], accessibilityRole: "button", accessibilityLabel: `${tile.label}: ${tile.hint}`, testID: `create-tile-${tile.id}`, children: [
|
|
286
|
+
/* @__PURE__ */ jsxs(View, { style: styles.formatWell, children: [
|
|
287
|
+
shape.stack ? /* @__PURE__ */ jsx(View, { style: [styles.formatPage, styles.formatPageBack, {
|
|
288
|
+
width: pageW,
|
|
289
|
+
height: pageH
|
|
290
|
+
}] }) : null,
|
|
291
|
+
/* @__PURE__ */ jsx(View, { style: [styles.formatPage, {
|
|
292
|
+
width: pageW,
|
|
293
|
+
height: pageH
|
|
294
|
+
}, shape.round && {
|
|
295
|
+
borderRadius: pageW / 2
|
|
296
|
+
}], children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: tile.icon, size: 18, color: theme.mutedForeground }) })
|
|
297
|
+
] }),
|
|
298
|
+
/* @__PURE__ */ jsx(Text, { style: styles.formatLabel, numberOfLines: 1, children: tile.label })
|
|
202
299
|
] });
|
|
203
300
|
}
|
|
204
301
|
function BoardCover({
|
|
205
302
|
item,
|
|
206
|
-
|
|
303
|
+
seed,
|
|
304
|
+
runAction,
|
|
305
|
+
renew
|
|
207
306
|
}) {
|
|
208
|
-
const
|
|
209
|
-
const
|
|
307
|
+
const theme = useCanvasTheme();
|
|
308
|
+
const styles = makeStyles(theme);
|
|
309
|
+
const isVideo = item.type === "video";
|
|
310
|
+
const [frame, setFrame] = useState(isVideo ? void 0 : item.src);
|
|
311
|
+
const [loaded, setLoaded] = useState(false);
|
|
210
312
|
useEffect(() => {
|
|
211
|
-
if (
|
|
313
|
+
if (!isVideo) return void 0;
|
|
212
314
|
if (!runAction) {
|
|
213
315
|
setFrame(null);
|
|
214
316
|
return void 0;
|
|
@@ -220,34 +322,62 @@ function BoardCover({
|
|
|
220
322
|
return () => {
|
|
221
323
|
live = false;
|
|
222
324
|
};
|
|
223
|
-
}, [item.src,
|
|
224
|
-
const
|
|
225
|
-
|
|
226
|
-
|
|
325
|
+
}, [item.src, isVideo, runAction]);
|
|
326
|
+
const media = useMediaSource(frame != null ? frame : "", "image", renew);
|
|
327
|
+
const [stalled, setStalled] = useState(false);
|
|
328
|
+
useEffect(() => {
|
|
329
|
+
setLoaded(false);
|
|
330
|
+
setStalled(false);
|
|
331
|
+
const timer = setTimeout(() => setStalled(true), COVER_STALL_MS);
|
|
332
|
+
return () => clearTimeout(timer);
|
|
333
|
+
}, [media.key]);
|
|
334
|
+
if (frame === null || media.phase === "broken") {
|
|
335
|
+
return /* @__PURE__ */ jsx(CoverPlaceholder, { seed, icon: isVideo ? "play" : "image-outline", label: isVideo ? "Video" : void 0 });
|
|
227
336
|
}
|
|
228
337
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
338
|
+
loaded && media.phase === "ok" ? null : stalled ? /* @__PURE__ */ jsx(CoverPlaceholder, { seed, icon: isVideo ? "play" : "image-outline" }) : /* @__PURE__ */ jsx(Skeleton, {}),
|
|
229
339
|
frame ? /* @__PURE__ */ jsx(Image, { source: {
|
|
230
|
-
uri:
|
|
231
|
-
}, style: styles.
|
|
232
|
-
isVideo ? /* @__PURE__ */ jsx(View, { style: styles.playBadge, pointerEvents: "none", children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "play", size:
|
|
340
|
+
uri: media.src
|
|
341
|
+
}, style: styles.fill, contentFit: "cover", transition: 200, onLoad: () => setLoaded(true), onError: media.onError }, media.key) : null,
|
|
342
|
+
isVideo && loaded ? /* @__PURE__ */ jsx(View, { style: styles.playBadge, pointerEvents: "none", children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "play", size: 16, color: "#fafafa" }) }) : null
|
|
233
343
|
] });
|
|
234
344
|
}
|
|
235
345
|
function DesignThumb({
|
|
236
346
|
doc,
|
|
237
|
-
maxWidth
|
|
347
|
+
maxWidth,
|
|
348
|
+
maxHeight
|
|
238
349
|
}) {
|
|
350
|
+
const theme = useCanvasTheme();
|
|
351
|
+
const styles = makeStyles(theme);
|
|
239
352
|
const page = doc.pages[0];
|
|
240
353
|
if (!page || !(page.width > 0) || !(page.height > 0)) {
|
|
241
|
-
return /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "shape-outline", size: 28, color:
|
|
354
|
+
return /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "shape-outline", size: 28, color: theme.mutedForeground });
|
|
242
355
|
}
|
|
243
|
-
const
|
|
244
|
-
const scale = Math.min(maxWidth / page.width, maxH / page.height);
|
|
356
|
+
const scale = Math.min(maxWidth / page.width, maxHeight / page.height);
|
|
245
357
|
const layers = [...page.layers].sort((a, b) => a.zIndex - b.zIndex);
|
|
246
358
|
return /* @__PURE__ */ jsx(View, { style: [styles.designPage, {
|
|
247
359
|
width: page.width * scale,
|
|
248
360
|
height: page.height * scale,
|
|
249
361
|
backgroundColor: page.background || "#ffffff"
|
|
250
|
-
}], pointerEvents: "none", children: layers.
|
|
362
|
+
}], pointerEvents: "none", children: layers.length === 0 ? (
|
|
363
|
+
// An untouched page: a faint layout sketch (title, lines, picture) instead of a blank sheet.
|
|
364
|
+
/* @__PURE__ */ jsxs(View, { style: styles.sketch, children: [
|
|
365
|
+
/* @__PURE__ */ jsx(View, { style: [styles.sketchBar, {
|
|
366
|
+
width: "62%",
|
|
367
|
+
height: "9%"
|
|
368
|
+
}] }),
|
|
369
|
+
/* @__PURE__ */ jsx(View, { style: [styles.sketchBar, {
|
|
370
|
+
width: "86%",
|
|
371
|
+
height: "5%"
|
|
372
|
+
}] }),
|
|
373
|
+
/* @__PURE__ */ jsx(View, { style: [styles.sketchBar, {
|
|
374
|
+
width: "70%",
|
|
375
|
+
height: "5%"
|
|
376
|
+
}] }),
|
|
377
|
+
/* @__PURE__ */ jsx(View, { style: [styles.sketchBar, styles.sketchBlock], children: /* @__PURE__ */ jsx(MaterialCommunityIcons, { name: "image-outline", size: 16, color: "#b4b4bb" }) }),
|
|
378
|
+
/* @__PURE__ */ jsx(Text, { style: styles.blankPage, children: designNoun(doc) })
|
|
379
|
+
] })
|
|
380
|
+
) : layers.map((layer) => /* @__PURE__ */ jsx(DesignThumbLayer, { layer, scale }, layer.id)) });
|
|
251
381
|
}
|
|
252
382
|
function DesignThumbLayer({
|
|
253
383
|
layer,
|
|
@@ -280,326 +410,303 @@ function DesignThumbLayer({
|
|
|
280
410
|
textAlign: layer.align
|
|
281
411
|
}], numberOfLines: 3, children: layer.text });
|
|
282
412
|
}
|
|
283
|
-
|
|
284
|
-
return /* @__PURE__ */ jsx(View, { pointerEvents: "none", style: styles.dots, children: Array.from({
|
|
285
|
-
length: 18
|
|
286
|
-
}).map((_, row) => /* @__PURE__ */ jsx(View, { style: styles.dotRow, children: Array.from({
|
|
287
|
-
length: 16
|
|
288
|
-
}).map((__, col) => /* @__PURE__ */ jsx(View, { style: styles.dotCell, children: /* @__PURE__ */ jsx(View, { style: styles.dot }) }, col)) }, row)) });
|
|
289
|
-
}
|
|
290
|
-
const styles = StyleSheet.create({
|
|
413
|
+
const makeStyles = themedStyles((theme) => StyleSheet.create({
|
|
291
414
|
plane: {
|
|
292
415
|
flex: 1,
|
|
293
|
-
backgroundColor:
|
|
294
|
-
overflow: "hidden"
|
|
416
|
+
backgroundColor: theme.background
|
|
295
417
|
},
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
418
|
+
list: {
|
|
419
|
+
paddingHorizontal: GUTTER,
|
|
420
|
+
paddingTop: SPACE.sm,
|
|
421
|
+
paddingBottom: SPACE.xxl
|
|
422
|
+
},
|
|
423
|
+
header: {
|
|
424
|
+
alignSelf: "stretch",
|
|
425
|
+
width: "100%"
|
|
300
426
|
},
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
height: 22,
|
|
427
|
+
titleRow: {
|
|
428
|
+
flexDirection: "row",
|
|
304
429
|
alignItems: "center",
|
|
305
|
-
justifyContent: "
|
|
430
|
+
justifyContent: "space-between",
|
|
431
|
+
marginBottom: SPACE.md
|
|
432
|
+
},
|
|
433
|
+
title: __spreadProps(__spreadValues({}, TYPE.display), {
|
|
434
|
+
color: theme.foreground
|
|
435
|
+
}),
|
|
436
|
+
toggle: {
|
|
437
|
+
width: 40,
|
|
438
|
+
height: 40,
|
|
439
|
+
borderRadius: 20,
|
|
440
|
+
alignItems: "center",
|
|
441
|
+
justifyContent: "center",
|
|
442
|
+
backgroundColor: theme.card
|
|
306
443
|
},
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
444
|
+
prompt: {
|
|
445
|
+
flexDirection: "row",
|
|
446
|
+
alignItems: "center",
|
|
447
|
+
gap: SPACE.md,
|
|
448
|
+
minHeight: 56,
|
|
449
|
+
paddingLeft: SPACE.lg,
|
|
450
|
+
paddingRight: SPACE.sm,
|
|
451
|
+
borderRadius: RADIUS.xl,
|
|
452
|
+
backgroundColor: theme.card,
|
|
453
|
+
borderWidth: StyleSheet.hairlineWidth,
|
|
454
|
+
borderColor: theme.border,
|
|
455
|
+
marginBottom: SPACE.xl
|
|
312
456
|
},
|
|
313
|
-
|
|
314
|
-
|
|
457
|
+
promptText: __spreadProps(__spreadValues({}, TYPE.body), {
|
|
458
|
+
flex: 1,
|
|
459
|
+
color: theme.mutedForeground
|
|
460
|
+
}),
|
|
461
|
+
promptGo: {
|
|
462
|
+
width: 40,
|
|
463
|
+
height: 40,
|
|
464
|
+
borderRadius: 20,
|
|
315
465
|
alignItems: "center",
|
|
316
|
-
|
|
317
|
-
|
|
466
|
+
justifyContent: "center",
|
|
467
|
+
backgroundColor: theme.primary
|
|
318
468
|
},
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
paddingHorizontal:
|
|
327
|
-
|
|
469
|
+
section: {
|
|
470
|
+
marginBottom: SPACE.xl
|
|
471
|
+
},
|
|
472
|
+
bleed: {
|
|
473
|
+
marginHorizontal: -16
|
|
474
|
+
},
|
|
475
|
+
railContent: {
|
|
476
|
+
paddingHorizontal: GUTTER,
|
|
477
|
+
gap: SPACE.sm
|
|
478
|
+
},
|
|
479
|
+
lanes: {
|
|
480
|
+
flexDirection: "row",
|
|
481
|
+
flexWrap: "wrap",
|
|
482
|
+
gap: SPACE.sm
|
|
483
|
+
},
|
|
484
|
+
lane: {
|
|
485
|
+
height: 92,
|
|
486
|
+
borderRadius: RADIUS.lg,
|
|
487
|
+
padding: SPACE.md,
|
|
488
|
+
justifyContent: "space-between"
|
|
489
|
+
},
|
|
490
|
+
laneLabel: __spreadProps(__spreadValues({}, TYPE.label), {
|
|
491
|
+
lineHeight: 17
|
|
492
|
+
}),
|
|
493
|
+
format: {
|
|
494
|
+
width: 84,
|
|
328
495
|
alignItems: "center",
|
|
329
|
-
|
|
330
|
-
shadowOpacity: 0.06,
|
|
331
|
-
shadowRadius: 16,
|
|
332
|
-
shadowOffset: {
|
|
333
|
-
width: 0,
|
|
334
|
-
height: 8
|
|
335
|
-
},
|
|
336
|
-
elevation: 2
|
|
496
|
+
gap: SPACE.sm
|
|
337
497
|
},
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
498
|
+
formatWell: {
|
|
499
|
+
width: 84,
|
|
500
|
+
height: 84,
|
|
501
|
+
borderRadius: RADIUS.lg,
|
|
502
|
+
backgroundColor: theme.card,
|
|
503
|
+
alignItems: "center",
|
|
504
|
+
justifyContent: "center"
|
|
343
505
|
},
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
506
|
+
formatPage: {
|
|
507
|
+
alignItems: "center",
|
|
508
|
+
justifyContent: "center",
|
|
509
|
+
borderRadius: 4,
|
|
510
|
+
backgroundColor: theme.isDark ? theme.secondary : theme.surface,
|
|
511
|
+
borderWidth: StyleSheet.hairlineWidth,
|
|
512
|
+
borderColor: theme.borderStrong
|
|
350
513
|
},
|
|
351
|
-
|
|
352
|
-
|
|
514
|
+
formatPageBack: {
|
|
515
|
+
position: "absolute",
|
|
516
|
+
transform: [{
|
|
517
|
+
translateX: 6
|
|
518
|
+
}, {
|
|
519
|
+
translateY: -6
|
|
520
|
+
}],
|
|
521
|
+
opacity: 0.6
|
|
522
|
+
},
|
|
523
|
+
formatLabel: __spreadProps(__spreadValues({}, TYPE.caption), {
|
|
524
|
+
color: theme.foreground
|
|
525
|
+
}),
|
|
526
|
+
tool: {
|
|
353
527
|
flexDirection: "row",
|
|
354
528
|
alignItems: "center",
|
|
355
|
-
gap:
|
|
356
|
-
|
|
357
|
-
paddingHorizontal:
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
},
|
|
361
|
-
|
|
362
|
-
color:
|
|
363
|
-
|
|
364
|
-
|
|
529
|
+
gap: SPACE.sm,
|
|
530
|
+
minHeight: 44,
|
|
531
|
+
paddingHorizontal: SPACE.lg - 2,
|
|
532
|
+
borderRadius: RADIUS.pill,
|
|
533
|
+
backgroundColor: theme.card
|
|
534
|
+
},
|
|
535
|
+
toolLabel: __spreadProps(__spreadValues({}, TYPE.label), {
|
|
536
|
+
color: theme.foreground
|
|
537
|
+
}),
|
|
538
|
+
look: {
|
|
539
|
+
width: 136,
|
|
540
|
+
height: 176,
|
|
541
|
+
borderRadius: RADIUS.lg,
|
|
542
|
+
overflow: "hidden",
|
|
543
|
+
backgroundColor: theme.card
|
|
544
|
+
},
|
|
545
|
+
lookCaption: {
|
|
546
|
+
position: "absolute",
|
|
547
|
+
left: 0,
|
|
548
|
+
right: 0,
|
|
549
|
+
bottom: 0,
|
|
550
|
+
paddingHorizontal: SPACE.md - 2,
|
|
551
|
+
paddingVertical: SPACE.sm + 2,
|
|
552
|
+
backgroundColor: "rgba(10,10,10,0.55)"
|
|
553
|
+
},
|
|
554
|
+
lookName: __spreadProps(__spreadValues({}, TYPE.label), {
|
|
555
|
+
color: "#fafafa"
|
|
556
|
+
}),
|
|
557
|
+
workHead: {
|
|
558
|
+
gap: SPACE.md,
|
|
559
|
+
marginBottom: SPACE.lg
|
|
365
560
|
},
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
561
|
+
noMargin: {
|
|
562
|
+
marginBottom: 0
|
|
563
|
+
},
|
|
564
|
+
segmented: {
|
|
565
|
+
flexGrow: 0,
|
|
566
|
+
alignSelf: "flex-start"
|
|
369
567
|
},
|
|
370
568
|
row: {
|
|
371
569
|
flexDirection: "row",
|
|
372
570
|
gap: GUTTER,
|
|
373
|
-
marginBottom:
|
|
571
|
+
marginBottom: SPACE.xl - 4
|
|
374
572
|
},
|
|
375
|
-
|
|
376
|
-
|
|
573
|
+
cover: {
|
|
574
|
+
aspectRatio: 1,
|
|
575
|
+
borderRadius: RADIUS.lg,
|
|
377
576
|
overflow: "hidden",
|
|
378
|
-
backgroundColor:
|
|
379
|
-
|
|
380
|
-
borderColor: "rgba(15,23,42,0.08)",
|
|
381
|
-
shadowColor: "#0f172a",
|
|
382
|
-
shadowOpacity: 0.05,
|
|
383
|
-
shadowRadius: 8,
|
|
384
|
-
shadowOffset: {
|
|
385
|
-
width: 0,
|
|
386
|
-
height: 2
|
|
387
|
-
},
|
|
388
|
-
elevation: 1
|
|
577
|
+
backgroundColor: theme.card,
|
|
578
|
+
marginBottom: SPACE.sm
|
|
389
579
|
},
|
|
390
|
-
|
|
580
|
+
coverNew: {
|
|
581
|
+
alignItems: "center",
|
|
582
|
+
justifyContent: "center",
|
|
583
|
+
borderWidth: 1.5,
|
|
391
584
|
borderStyle: "dashed",
|
|
392
|
-
|
|
585
|
+
borderColor: theme.borderStrong,
|
|
586
|
+
backgroundColor: "transparent"
|
|
393
587
|
},
|
|
394
|
-
|
|
395
|
-
|
|
588
|
+
newPlus: {
|
|
589
|
+
width: 48,
|
|
590
|
+
height: 48,
|
|
591
|
+
borderRadius: 24,
|
|
396
592
|
alignItems: "center",
|
|
397
593
|
justifyContent: "center",
|
|
398
|
-
backgroundColor:
|
|
399
|
-
|
|
400
|
-
|
|
594
|
+
backgroundColor: theme.primary
|
|
595
|
+
},
|
|
596
|
+
centered: {
|
|
597
|
+
alignItems: "center",
|
|
598
|
+
justifyContent: "center"
|
|
599
|
+
},
|
|
600
|
+
fill: __spreadValues({}, StyleSheet.absoluteFillObject),
|
|
601
|
+
workTitle: __spreadProps(__spreadValues({}, TYPE.label), {
|
|
602
|
+
fontSize: 14,
|
|
603
|
+
color: theme.foreground
|
|
604
|
+
}),
|
|
605
|
+
workMeta: __spreadProps(__spreadValues({}, TYPE.caption), {
|
|
606
|
+
marginTop: 1,
|
|
607
|
+
color: theme.mutedForeground
|
|
608
|
+
}),
|
|
609
|
+
countBadge: {
|
|
610
|
+
position: "absolute",
|
|
611
|
+
top: SPACE.sm,
|
|
612
|
+
right: SPACE.sm,
|
|
613
|
+
minWidth: 24,
|
|
614
|
+
height: 24,
|
|
615
|
+
paddingHorizontal: 7,
|
|
616
|
+
borderRadius: 12,
|
|
617
|
+
alignItems: "center",
|
|
618
|
+
justifyContent: "center",
|
|
619
|
+
backgroundColor: "rgba(10,10,10,0.55)"
|
|
620
|
+
},
|
|
621
|
+
countBadgeText: {
|
|
622
|
+
fontSize: 12,
|
|
623
|
+
fontWeight: "600",
|
|
624
|
+
color: "#fafafa"
|
|
401
625
|
},
|
|
402
|
-
thumbImage: __spreadValues({}, StyleSheet.absoluteFillObject),
|
|
403
626
|
playBadge: {
|
|
404
627
|
position: "absolute",
|
|
405
|
-
|
|
406
|
-
bottom:
|
|
628
|
+
left: SPACE.sm,
|
|
629
|
+
bottom: SPACE.sm,
|
|
407
630
|
width: 28,
|
|
408
631
|
height: 28,
|
|
409
632
|
borderRadius: 14,
|
|
410
633
|
alignItems: "center",
|
|
411
634
|
justifyContent: "center",
|
|
412
|
-
backgroundColor: "rgba(
|
|
635
|
+
backgroundColor: "rgba(10,10,10,0.55)"
|
|
413
636
|
},
|
|
414
637
|
designPage: {
|
|
415
638
|
overflow: "hidden",
|
|
416
|
-
borderRadius:
|
|
417
|
-
shadowColor: "#
|
|
418
|
-
shadowOpacity: 0.
|
|
419
|
-
shadowRadius:
|
|
639
|
+
borderRadius: 3,
|
|
640
|
+
shadowColor: "#000",
|
|
641
|
+
shadowOpacity: theme.isDark ? 0 : 0.1,
|
|
642
|
+
shadowRadius: 6,
|
|
420
643
|
shadowOffset: {
|
|
421
644
|
width: 0,
|
|
422
|
-
height:
|
|
645
|
+
height: 2
|
|
423
646
|
},
|
|
424
|
-
elevation:
|
|
647
|
+
elevation: 2
|
|
425
648
|
},
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
649
|
+
// The sketch sits on the design's own (usually white) page, so its ink is fixed, not themed.
|
|
650
|
+
sketch: __spreadProps(__spreadValues({}, StyleSheet.absoluteFillObject), {
|
|
651
|
+
padding: "10%",
|
|
652
|
+
gap: 6
|
|
653
|
+
}),
|
|
654
|
+
sketchBar: {
|
|
655
|
+
borderRadius: 3,
|
|
656
|
+
backgroundColor: "#ececef"
|
|
429
657
|
},
|
|
430
|
-
|
|
431
|
-
|
|
658
|
+
sketchBlock: {
|
|
659
|
+
flex: 1,
|
|
432
660
|
width: "100%",
|
|
433
|
-
|
|
434
|
-
},
|
|
435
|
-
createBlock: {
|
|
436
|
-
marginBottom: 16
|
|
437
|
-
},
|
|
438
|
-
createHead: {
|
|
439
|
-
flexDirection: "row",
|
|
440
|
-
alignItems: "flex-start",
|
|
441
|
-
justifyContent: "space-between",
|
|
442
|
-
gap: 12,
|
|
443
|
-
marginBottom: 12
|
|
444
|
-
},
|
|
445
|
-
createTitle: {
|
|
446
|
-
fontSize: 22,
|
|
447
|
-
fontWeight: "600",
|
|
448
|
-
color: "#0f172a"
|
|
449
|
-
},
|
|
450
|
-
createSub: {
|
|
451
|
-
marginTop: 2,
|
|
452
|
-
fontSize: 13,
|
|
453
|
-
color: "#64748b"
|
|
454
|
-
},
|
|
455
|
-
flexShrink: {
|
|
456
|
-
flexShrink: 1
|
|
457
|
-
},
|
|
458
|
-
group: {
|
|
459
|
-
marginBottom: 14
|
|
460
|
-
},
|
|
461
|
-
groupTitle: {
|
|
462
|
-
fontSize: 16,
|
|
463
|
-
fontWeight: "600",
|
|
464
|
-
paddingBottom: 6,
|
|
465
|
-
marginBottom: 8,
|
|
466
|
-
borderBottomWidth: 1
|
|
467
|
-
},
|
|
468
|
-
groupTiles: {
|
|
469
|
-
flexDirection: "row",
|
|
470
|
-
flexWrap: "wrap",
|
|
471
|
-
columnGap: GUTTER,
|
|
472
|
-
rowGap: 4
|
|
473
|
-
},
|
|
474
|
-
createTile: {
|
|
475
|
-
flexDirection: "row",
|
|
476
|
-
alignItems: "flex-start",
|
|
477
|
-
gap: 10,
|
|
478
|
-
minHeight: 48,
|
|
479
|
-
paddingVertical: 6
|
|
480
|
-
},
|
|
481
|
-
createIcon: {
|
|
482
|
-
width: 36,
|
|
483
|
-
height: 36,
|
|
484
|
-
borderRadius: 10,
|
|
661
|
+
marginTop: 4,
|
|
485
662
|
alignItems: "center",
|
|
486
663
|
justifyContent: "center"
|
|
487
664
|
},
|
|
488
|
-
|
|
489
|
-
fontSize:
|
|
665
|
+
blankPage: {
|
|
666
|
+
fontSize: 10,
|
|
490
667
|
fontWeight: "600",
|
|
491
|
-
color: "#
|
|
492
|
-
|
|
493
|
-
createHint: {
|
|
494
|
-
marginTop: 1,
|
|
495
|
-
fontSize: 11,
|
|
496
|
-
lineHeight: 14,
|
|
497
|
-
color: "#64748b"
|
|
498
|
-
},
|
|
499
|
-
composerBlock: {
|
|
500
|
-
marginBottom: 16,
|
|
501
|
-
gap: 8
|
|
502
|
-
},
|
|
503
|
-
lookChip: {
|
|
504
|
-
width: 112,
|
|
505
|
-
borderRadius: 12,
|
|
506
|
-
overflow: "hidden",
|
|
507
|
-
backgroundColor: "#ffffff",
|
|
508
|
-
borderWidth: 1,
|
|
509
|
-
borderColor: "rgba(15,23,42,0.08)"
|
|
510
|
-
},
|
|
511
|
-
lookCover: {
|
|
512
|
-
width: "100%",
|
|
513
|
-
height: 72,
|
|
514
|
-
backgroundColor: "#f1f5f9"
|
|
668
|
+
color: "#a1a1aa",
|
|
669
|
+
textAlign: "center"
|
|
515
670
|
},
|
|
516
|
-
|
|
671
|
+
empty: {
|
|
517
672
|
alignItems: "center",
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
workHead: {
|
|
528
|
-
gap: 8,
|
|
529
|
-
marginBottom: 12
|
|
530
|
-
},
|
|
531
|
-
workTitle: {
|
|
532
|
-
fontSize: 18,
|
|
533
|
-
fontWeight: "600",
|
|
534
|
-
color: "#0f172a"
|
|
535
|
-
},
|
|
536
|
-
filterChip: {
|
|
537
|
-
backgroundColor: "#ffffff",
|
|
538
|
-
borderWidth: 1,
|
|
539
|
-
borderColor: "rgba(15,23,42,0.1)",
|
|
540
|
-
borderRadius: 999,
|
|
541
|
-
paddingHorizontal: 14,
|
|
542
|
-
paddingVertical: 7
|
|
543
|
-
},
|
|
544
|
-
filterChipOn: {
|
|
545
|
-
backgroundColor: "#0f172a",
|
|
546
|
-
borderColor: "#0f172a"
|
|
547
|
-
},
|
|
548
|
-
filterLabel: {
|
|
549
|
-
fontSize: 13,
|
|
550
|
-
fontWeight: "600",
|
|
551
|
-
color: "#0f172a"
|
|
552
|
-
},
|
|
553
|
-
filterLabelOn: {
|
|
554
|
-
color: "#f8fafc"
|
|
555
|
-
},
|
|
556
|
-
studioLabel: {
|
|
557
|
-
fontSize: 11,
|
|
558
|
-
fontWeight: "600",
|
|
559
|
-
letterSpacing: 0.6,
|
|
560
|
-
textTransform: "uppercase",
|
|
561
|
-
color: "#64748b",
|
|
562
|
-
flexShrink: 1
|
|
563
|
-
},
|
|
564
|
-
askAgentBtn: {
|
|
565
|
-
flexDirection: "row",
|
|
673
|
+
paddingVertical: SPACE.xxl,
|
|
674
|
+
paddingHorizontal: SPACE.xl,
|
|
675
|
+
borderRadius: RADIUS.xl,
|
|
676
|
+
backgroundColor: theme.card
|
|
677
|
+
},
|
|
678
|
+
emptyIcon: {
|
|
679
|
+
width: 52,
|
|
680
|
+
height: 52,
|
|
681
|
+
borderRadius: 26,
|
|
566
682
|
alignItems: "center",
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
borderRadius: 8,
|
|
571
|
-
paddingHorizontal: 8,
|
|
572
|
-
paddingVertical: 6,
|
|
573
|
-
backgroundColor: "#ffffff",
|
|
574
|
-
flexShrink: 0
|
|
575
|
-
},
|
|
576
|
-
askAgentLabel: {
|
|
577
|
-
fontSize: 11,
|
|
578
|
-
fontWeight: "600",
|
|
579
|
-
color: "#64748b"
|
|
580
|
-
},
|
|
581
|
-
studioRow: {
|
|
582
|
-
flexDirection: "row",
|
|
583
|
-
gap: 8,
|
|
584
|
-
paddingBottom: 4
|
|
585
|
-
},
|
|
586
|
-
meta: {
|
|
587
|
-
borderTopWidth: StyleSheet.hairlineWidth,
|
|
588
|
-
borderTopColor: "rgba(15,23,42,0.08)",
|
|
589
|
-
paddingHorizontal: 12,
|
|
590
|
-
paddingVertical: 10
|
|
683
|
+
justifyContent: "center",
|
|
684
|
+
backgroundColor: theme.background,
|
|
685
|
+
marginBottom: SPACE.md
|
|
591
686
|
},
|
|
592
|
-
|
|
687
|
+
emptyTitle: __spreadProps(__spreadValues({}, TYPE.title), {
|
|
688
|
+
color: theme.foreground,
|
|
689
|
+
textAlign: "center"
|
|
690
|
+
}),
|
|
691
|
+
emptyDetail: __spreadProps(__spreadValues({}, TYPE.body), {
|
|
593
692
|
fontSize: 14,
|
|
594
|
-
|
|
595
|
-
color:
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
693
|
+
marginTop: SPACE.xs,
|
|
694
|
+
color: theme.mutedForeground,
|
|
695
|
+
textAlign: "center",
|
|
696
|
+
maxWidth: 300
|
|
697
|
+
}),
|
|
698
|
+
emptyCta: {
|
|
699
|
+
marginTop: SPACE.lg + 2,
|
|
700
|
+
flexDirection: "row",
|
|
701
|
+
alignItems: "center",
|
|
702
|
+
gap: SPACE.sm,
|
|
703
|
+
minHeight: 44,
|
|
704
|
+
paddingHorizontal: SPACE.xl - 4,
|
|
705
|
+
borderRadius: RADIUS.pill,
|
|
706
|
+
backgroundColor: theme.primary
|
|
707
|
+
},
|
|
708
|
+
emptyCtaLabel: __spreadProps(__spreadValues({}, TYPE.label), {
|
|
709
|
+
fontSize: 15,
|
|
710
|
+
color: theme.primaryForeground
|
|
711
|
+
})
|
|
712
|
+
}));export{CanvasBoardsGrid};//# sourceMappingURL=CanvasBoardsGrid.js.map
|