@adminide-stack/yantra-mobile 12.0.163-alpha.1 → 12.0.164-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.
- package/lib/components/CustomDrawer.js +8 -1
- package/lib/components/CustomDrawer.js.map +1 -1
- package/lib/components/NavigationHeader/HeaderSheet.js +23 -8
- package/lib/components/NavigationHeader/HeaderSheet.js.map +1 -1
- package/lib/components/NavigationHeader/HeaderSkillsButton.js +6 -3
- package/lib/components/NavigationHeader/HeaderSkillsButton.js.map +1 -1
- package/lib/components/NavigationHeader/HeaderSystemButtons.js +7 -0
- package/lib/components/NavigationHeader/HeaderSystemButtons.js.map +1 -0
- package/lib/components/NavigationHeader/HeaderTasksButton.js +144 -93
- package/lib/components/NavigationHeader/HeaderTasksButton.js.map +1 -1
- package/lib/components/NavigationHeader/NavigationHeader.js +2 -2
- package/lib/components/NavigationHeader/NavigationHeader.js.map +1 -1
- package/lib/features/agent-chat/NativeAgentChat.js +3 -3
- package/lib/features/agent-chat/NativeAgentChat.js.map +1 -1
- package/lib/features/audio-input/AudioRecorderPanel.js +1 -1
- package/lib/features/audio-input/NativeDictationBar.js +1 -1
- package/lib/features/canvas/CanvasExperience.js +1 -1
- package/lib/features/channels/ConnectAppsSheet.js +1 -1
- package/lib/features/channels/HomeImessage.js +1 -1
- package/lib/features/channels/useChannelsApi.js +1 -1
- package/lib/features/chat/OneTimeCodePrompt.js +1 -1
- package/lib/features/chat/QueuedFollowUps.js +4 -3
- package/lib/features/chat/QueuedFollowUps.js.map +1 -1
- package/lib/features/chat/TemporaryChatView.js +238 -0
- package/lib/features/chat/TemporaryChatView.js.map +1 -0
- package/lib/features/chat/connectorConnect.js +1 -1
- package/lib/features/chat/temporaryChatStore.js +59 -7
- package/lib/features/chat/temporaryChatStore.js.map +1 -1
- package/lib/features/chat/withTemporaryChat.js +24 -0
- package/lib/features/chat/withTemporaryChat.js.map +1 -0
- package/lib/features/dictate/recorderStatus.js +22 -0
- package/lib/features/dictate/recorderStatus.js.map +1 -0
- package/lib/features/dictate/useDictationRecorder.js +4 -4
- package/lib/features/dictate/useDictationRecorder.js.map +1 -1
- package/lib/features/home/sky/HomeSky.js +1 -1
- package/lib/features/skills/SkillTemplatePicker.js +107 -143
- package/lib/features/skills/SkillTemplatePicker.js.map +1 -1
- package/lib/features/webbuilder/WebBuilderExperience.js +402 -33
- package/lib/features/webbuilder/WebBuilderExperience.js.map +1 -1
- package/lib/features/webbuilder/components/CloudSheet.js +35 -15
- package/lib/features/webbuilder/components/CloudSheet.js.map +1 -1
- package/lib/features/webbuilder/components/Credits.js +149 -0
- package/lib/features/webbuilder/components/Credits.js.map +1 -0
- package/lib/features/webbuilder/components/PreviewFrame.js +15 -4
- package/lib/features/webbuilder/components/PreviewFrame.js.map +1 -1
- package/lib/features/webbuilder/components/PreviewScreen.js +5 -2
- package/lib/features/webbuilder/components/PreviewScreen.js.map +1 -1
- package/lib/features/webbuilder/components/ProjectChat.js +58 -8
- package/lib/features/webbuilder/components/ProjectChat.js.map +1 -1
- package/lib/features/webbuilder/components/ProjectSheets.js +29 -6
- package/lib/features/webbuilder/components/ProjectSheets.js.map +1 -1
- package/lib/features/webbuilder/components/ProjectsScreen.js +16 -7
- package/lib/features/webbuilder/components/ProjectsScreen.js.map +1 -1
- package/lib/features/webbuilder/components/PublishSheet.js +133 -2
- package/lib/features/webbuilder/components/PublishSheet.js.map +1 -1
- package/lib/features/webbuilder/components/RetentionBanner.js +130 -0
- package/lib/features/webbuilder/components/RetentionBanner.js.map +1 -0
- package/lib/features/webbuilder/components/ShareSheet.js +265 -0
- package/lib/features/webbuilder/components/ShareSheet.js.map +1 -0
- package/lib/features/webbuilder/components/SiteStatusSheet.js +533 -0
- package/lib/features/webbuilder/components/SiteStatusSheet.js.map +1 -0
- package/lib/features/webbuilder/components/StudioHome.js +8 -1
- package/lib/features/webbuilder/components/StudioHome.js.map +1 -1
- package/lib/features/webbuilder/components/TemplateSuggestions.js +98 -0
- package/lib/features/webbuilder/components/TemplateSuggestions.js.map +1 -0
- package/lib/features/webbuilder/connectorTemplates.js +3 -3
- package/lib/features/webbuilder/connectorTemplates.js.map +1 -1
- package/lib/features/webbuilder/creditsLinks.js +5 -0
- package/lib/features/webbuilder/creditsLinks.js.map +1 -0
- package/lib/features/webbuilder/previewAccess.js +207 -0
- package/lib/features/webbuilder/previewAccess.js.map +1 -0
- package/lib/features/webbuilder/previewProbe.js +49 -1
- package/lib/features/webbuilder/previewProbe.js.map +1 -1
- package/lib/features/webbuilder/readiness.js +14 -0
- package/lib/features/webbuilder/readiness.js.map +1 -0
- package/lib/features/webbuilder/shareLink.js +26 -0
- package/lib/features/webbuilder/shareLink.js.map +1 -0
- package/lib/features/webbuilder/templateCover.js +11 -0
- package/lib/features/webbuilder/templateCover.js.map +1 -0
- package/lib/features/webbuilder/templateSuggestions.js +112 -0
- package/lib/features/webbuilder/templateSuggestions.js.map +1 -0
- package/lib/features/webbuilder/useGithubAutoSync.js +83 -0
- package/lib/features/webbuilder/useGithubAutoSync.js.map +1 -0
- package/lib/features/webbuilder/usePreviewAccess.js +61 -0
- package/lib/features/webbuilder/usePreviewAccess.js.map +1 -0
- package/lib/features/webbuilder/useWebBuilderCredits.js +99 -0
- package/lib/features/webbuilder/useWebBuilderCredits.js.map +1 -0
- package/lib/features/webbuilder/web/credits/credits.js +203 -0
- package/lib/features/webbuilder/web/credits/credits.js.map +1 -0
- package/lib/features/webbuilder/web/credits/creditsReader.js +65 -0
- package/lib/features/webbuilder/web/credits/creditsReader.js.map +1 -0
- package/lib/features/webbuilder/web/data/cloud.js +3 -3
- package/lib/features/webbuilder/web/data/cloud.js.map +1 -1
- package/lib/features/webbuilder/web/data/database.js +4 -1
- package/lib/features/webbuilder/web/data/database.js.map +1 -1
- package/lib/features/webbuilder/web/github/autoSync.js +231 -0
- package/lib/features/webbuilder/web/github/autoSync.js.map +1 -0
- package/lib/features/webbuilder/web/github/autoSyncEngine.js +367 -0
- package/lib/features/webbuilder/web/github/autoSyncEngine.js.map +1 -0
- package/lib/features/webbuilder/web/github/githubSync.js +54 -0
- package/lib/features/webbuilder/web/github/githubSync.js.map +1 -0
- package/lib/features/webbuilder/web/history/versions.js +83 -0
- package/lib/features/webbuilder/web/history/versions.js.map +1 -0
- package/lib/features/webbuilder/web/project/retention.js +217 -0
- package/lib/features/webbuilder/web/project/retention.js.map +1 -0
- package/lib/features/webbuilder/web/publish/actionErrors.js +81 -0
- package/lib/features/webbuilder/web/publish/actionErrors.js.map +1 -0
- package/lib/features/webbuilder/web/publish/publishSteps.js +86 -0
- package/lib/features/webbuilder/web/publish/publishSteps.js.map +1 -0
- package/lib/features/webbuilder/web/publish/siteAddress.js +79 -0
- package/lib/features/webbuilder/web/publish/siteAddress.js.map +1 -0
- package/lib/features/webbuilder/web/publish/siteHealth.js +497 -0
- package/lib/features/webbuilder/web/publish/siteHealth.js.map +1 -0
- package/lib/features/webbuilder/web/publish/siteInsights.js +145 -0
- package/lib/features/webbuilder/web/publish/siteInsights.js.map +1 -0
- package/lib/features/webbuilder/web/sharing/roles.js +108 -2
- package/lib/features/webbuilder/web/sharing/roles.js.map +1 -1
- package/lib/features/webbuilder/web/sharing/share.js +52 -0
- package/lib/features/webbuilder/web/sharing/share.js.map +1 -0
- package/lib/features/webbuilder/web/sharing/sharingApi.js +199 -0
- package/lib/features/webbuilder/web/sharing/sharingApi.js.map +1 -0
- package/lib/features/webbuilder/web/webServices.js +13 -2
- package/lib/features/webbuilder/web/webServices.js.map +1 -1
- package/lib/features/webbuilder/webbuilderPrompts.js +4 -1
- package/lib/features/webbuilder/webbuilderPrompts.js.map +1 -1
- package/lib/features/webbuilder/workflow.js +2 -2
- package/lib/features/webbuilder/workflow.js.map +1 -1
- package/lib/hooks/useSurfaceJobs.js +113 -28
- package/lib/hooks/useSurfaceJobs.js.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/screens/Chat/index.js +3 -2
- package/lib/screens/Chat/index.js.map +1 -1
- package/lib/screens/Home/HomeScreen.js +1 -1
- package/lib/screens/Home/components/BuildTemplatesSection.js +1 -1
- package/lib/screens/Home/components/ChooseTemplateModal.js +1 -1
- package/lib/screens/Home/components/HomeHero.js +1 -1
- package/lib/screens/Home/components/HomeSuggestions.js +1 -1
- package/lib/screens/Home/components/TemplateBrowserModal.js +1 -1
- package/lib/screens/Home/index.js +1 -1
- package/lib/screens/Home/index.js.map +1 -1
- package/lib/screens/WebBuilderNative/index.js +1 -1
- package/lib/screens/WebBuilderNative/index.js.map +1 -1
- package/lib/screens/WebBuilderNative/sandboxProxyApi.js +33 -3
- package/lib/screens/WebBuilderNative/sandboxProxyApi.js.map +1 -1
- package/lib/screens/WebBuilderNative/useWebBuilderHost.js +33 -13
- package/lib/screens/WebBuilderNative/useWebBuilderHost.js.map +1 -1
- package/lib/screens/WebBuilderNative/useWebBuilderJobs.js +11 -4
- package/lib/screens/WebBuilderNative/useWebBuilderJobs.js.map +1 -1
- package/lib/screens/WebBuilderNative/webbuilderTransport.js +1 -1
- package/lib/screens/WebBuilderNative/webbuilderTransport.js.map +1 -1
- package/lib/services/brainQuickReply.js +47 -14
- package/lib/services/brainQuickReply.js.map +1 -1
- package/package.json +2 -2
- package/lib/components/NavigationHeader/HeaderMoreMenu.js +0 -78
- package/lib/components/NavigationHeader/HeaderMoreMenu.js.map +0 -1
- package/lib/components/NavigationHeader/HeaderSettingsMenu.js +0 -132
- package/lib/components/NavigationHeader/HeaderSettingsMenu.js.map +0 -1
|
@@ -1,52 +1,137 @@
|
|
|
1
|
-
import {useState,useMemo,useCallback}from'react';import {useGetSurfaceJobsQuery,useRemoveSurfaceJobMutation}from'common/graphql';import {
|
|
1
|
+
import {useState,useMemo,useCallback}from'react';import {useGetSurfaceJobsQuery,useGetTasksQuery,useRemoveSurfaceJobMutation,useRemoveTaskMutation}from'common/graphql';import {visibleJobs,centralJobsFrom,isJobRunning,isSurfaceJobsUnsupported}from'common';import {usePrerequisiteIds}from'./usePrerequisiteIds.js';const POLL_OPEN_MS = 15e3;
|
|
2
2
|
const POLL_CLOSED_MS = 6e4;
|
|
3
|
-
const JOBS_LIMIT =
|
|
3
|
+
const JOBS_LIMIT = 100;
|
|
4
|
+
const TASKS_LIMIT = 200;
|
|
5
|
+
const dismissedJobs = /* @__PURE__ */ new Set();
|
|
4
6
|
function useSurfaceJobs(open) {
|
|
5
7
|
const {
|
|
6
8
|
orgName
|
|
7
9
|
} = usePrerequisiteIds();
|
|
10
|
+
const pollInterval = open ? POLL_OPEN_MS : POLL_CLOSED_MS;
|
|
8
11
|
const [unsupported, setUnsupported] = useState(false);
|
|
9
|
-
const {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
12
|
+
const onSurfaceError = (error) => {
|
|
13
|
+
if (isSurfaceJobsUnsupported(error.message)) setUnsupported(true);
|
|
14
|
+
};
|
|
15
|
+
const workspace = useGetSurfaceJobsQuery({
|
|
16
|
+
variables: {
|
|
17
|
+
limit: JOBS_LIMIT,
|
|
18
|
+
orgName: orgName || void 0
|
|
19
|
+
},
|
|
20
|
+
skip: !orgName || unsupported,
|
|
21
|
+
fetchPolicy: "cache-and-network",
|
|
22
|
+
pollInterval,
|
|
23
|
+
onError: onSurfaceError
|
|
24
|
+
});
|
|
25
|
+
const own = useGetSurfaceJobsQuery({
|
|
17
26
|
variables: {
|
|
18
27
|
limit: JOBS_LIMIT
|
|
19
28
|
},
|
|
20
29
|
skip: !orgName || unsupported,
|
|
21
30
|
fetchPolicy: "cache-and-network",
|
|
22
|
-
pollInterval
|
|
23
|
-
onError:
|
|
24
|
-
|
|
25
|
-
|
|
31
|
+
pollInterval,
|
|
32
|
+
onError: onSurfaceError
|
|
33
|
+
});
|
|
34
|
+
const tasks = useGetTasksQuery({
|
|
35
|
+
variables: {
|
|
36
|
+
orgName: orgName || void 0,
|
|
37
|
+
offset: 0,
|
|
38
|
+
limit: TASKS_LIMIT
|
|
39
|
+
},
|
|
40
|
+
skip: !orgName,
|
|
41
|
+
fetchPolicy: "cache-and-network",
|
|
42
|
+
nextFetchPolicy: "cache-first",
|
|
43
|
+
pollInterval
|
|
26
44
|
});
|
|
27
45
|
const [removeJob] = useRemoveSurfaceJobMutation();
|
|
28
|
-
const [
|
|
46
|
+
const [removeTask] = useRemoveTaskMutation();
|
|
47
|
+
const [dismissed, setDismissed] = useState(() => new Set(dismissedJobs));
|
|
29
48
|
const jobs = useMemo(() => {
|
|
30
|
-
var _a;
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
|
|
49
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
50
|
+
const surfaceRows = unsupported ? null : [...(_b = (_a = workspace.data) == null ? void 0 : _a.getSurfaceJobs) != null ? _b : [], ...(_d = (_c = own.data) == null ? void 0 : _c.getSurfaceJobs) != null ? _d : []];
|
|
51
|
+
const taskRows = (_g = (_f = (_e = tasks.data) == null ? void 0 : _e.getTasks) == null ? void 0 : _f.data) != null ? _g : [];
|
|
52
|
+
return visibleJobs(centralJobsFrom(surfaceRows, taskRows).filter((job) => !dismissed.has(job.id)));
|
|
53
|
+
}, [workspace.data, own.data, tasks.data, unsupported, dismissed]);
|
|
34
54
|
const runningCount = useMemo(() => jobs.filter(isJobRunning).length, [jobs]);
|
|
55
|
+
const {
|
|
56
|
+
refetch: refetchWorkspace
|
|
57
|
+
} = workspace;
|
|
58
|
+
const {
|
|
59
|
+
refetch: refetchOwn
|
|
60
|
+
} = own;
|
|
61
|
+
const {
|
|
62
|
+
refetch: refetchTasks
|
|
63
|
+
} = tasks;
|
|
35
64
|
const refresh = useCallback(() => {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
65
|
+
refetchTasks().catch(() => void 0);
|
|
66
|
+
if (unsupported) return;
|
|
67
|
+
refetchWorkspace().catch(() => void 0);
|
|
68
|
+
refetchOwn().catch(() => void 0);
|
|
69
|
+
}, [refetchWorkspace, refetchOwn, refetchTasks, unsupported]);
|
|
70
|
+
const removeMany = useCallback((ids) => {
|
|
71
|
+
if (!ids.length) return;
|
|
72
|
+
ids.forEach((id) => dismissedJobs.add(id));
|
|
73
|
+
setDismissed(new Set(dismissedJobs));
|
|
74
|
+
const workspaceContext = orgName ? {
|
|
75
|
+
headers: {
|
|
76
|
+
orgname: orgName
|
|
77
|
+
}
|
|
78
|
+
} : void 0;
|
|
79
|
+
const removeOne = async (id) => {
|
|
80
|
+
const attempts = [["removeSurfaceJob(workspace)", () => removeJob({
|
|
81
|
+
variables: {
|
|
82
|
+
id
|
|
83
|
+
},
|
|
84
|
+
context: workspaceContext
|
|
85
|
+
}).then((r) => {
|
|
86
|
+
var _a;
|
|
87
|
+
return (_a = r.data) == null ? void 0 : _a.removeSurfaceJob;
|
|
88
|
+
})], ["removeSurfaceJob", () => removeJob({
|
|
89
|
+
variables: {
|
|
90
|
+
id
|
|
91
|
+
}
|
|
92
|
+
}).then((r) => {
|
|
93
|
+
var _a;
|
|
94
|
+
return (_a = r.data) == null ? void 0 : _a.removeSurfaceJob;
|
|
95
|
+
})], ["removeTask(workspace)", () => removeTask({
|
|
96
|
+
variables: {
|
|
97
|
+
id
|
|
98
|
+
},
|
|
99
|
+
context: workspaceContext
|
|
100
|
+
}).then((r) => {
|
|
101
|
+
var _a;
|
|
102
|
+
return (_a = r.data) == null ? void 0 : _a.removeTask;
|
|
103
|
+
})]];
|
|
104
|
+
const tried = [];
|
|
105
|
+
for (const [via, attempt] of attempts) {
|
|
106
|
+
try {
|
|
107
|
+
if (await attempt()) return true;
|
|
108
|
+
tried.push(`${via}: false`);
|
|
109
|
+
} catch (err) {
|
|
110
|
+
tried.push(`${via}: ${err instanceof Error ? err.message : String(err)}`);
|
|
111
|
+
}
|
|
43
112
|
}
|
|
44
|
-
|
|
45
|
-
|
|
113
|
+
console.warn(`[Tasks] could not remove job ${id} (org ${orgName != null ? orgName : "-"}):`, tried.join(" | "));
|
|
114
|
+
return false;
|
|
115
|
+
};
|
|
116
|
+
Promise.all(ids.map((id) => removeOne(id).then((removed) => ({
|
|
117
|
+
id,
|
|
118
|
+
removed
|
|
119
|
+
})))).then((results) => {
|
|
120
|
+
const kept = results.filter((r) => !r.removed).map((r) => r.id);
|
|
121
|
+
if (!kept.length) return;
|
|
122
|
+
kept.forEach((id) => dismissedJobs.delete(id));
|
|
123
|
+
setDismissed(new Set(dismissedJobs));
|
|
124
|
+
}).finally(refresh);
|
|
125
|
+
}, [orgName, removeJob, removeTask, refresh]);
|
|
126
|
+
const dismiss = useCallback((id) => removeMany([id]), [removeMany]);
|
|
127
|
+
const clearFinished = useCallback(() => removeMany(jobs.filter((job) => !isJobRunning(job)).map((job) => job.id)), [jobs, removeMany]);
|
|
128
|
+
const loading = tasks.loading && !tasks.data || !unsupported && workspace.loading && own.loading && !workspace.data && !own.data;
|
|
46
129
|
return {
|
|
47
130
|
jobs,
|
|
48
131
|
runningCount,
|
|
132
|
+
loading,
|
|
49
133
|
dismiss,
|
|
134
|
+
clearFinished,
|
|
50
135
|
refresh
|
|
51
136
|
};
|
|
52
137
|
}export{useSurfaceJobs};//# sourceMappingURL=useSurfaceJobs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSurfaceJobs.js","sources":["../../src/hooks/useSurfaceJobs.ts"],"sourcesContent":["/**\n * The person's long-running jobs (a Web Builder build, a canvas video, ...) for the\n * Tasks sheet and its badge: the server-owned surface jobs the web chat's Tasks panel\n * reads too (common CENTRAL_TASKS_MODEL), so a job shows wherever it was started and\n * after the app that started it is gone. Polls like the web: often while the sheet is\n * open, rarely while it is closed.\n */\nimport { useCallback, useMemo, useState } from 'react';\nimport { useGetSurfaceJobsQuery, useRemoveSurfaceJobMutation } from 'common/graphql';\nimport {\n centralJobsFrom,\n isJobRunning,\n isSurfaceJobsUnsupported,\n visibleJobs,\n type CentralJob,\n type RawJobTask,\n} from 'common';\nimport { usePrerequisiteIds } from './usePrerequisiteIds';\n\nconst POLL_OPEN_MS = 15_000;\nconst POLL_CLOSED_MS = 60_000;\nconst JOBS_LIMIT = 50;\n\nexport function useSurfaceJobs(open: boolean): {\n jobs: CentralJob[];\n runningCount: number;\n dismiss: (id: string) => void;\n refresh: () => void;\n} {\n const { orgName } = usePrerequisiteIds();\n // Once the backend says it has no getSurfaceJobs, stop asking for this session.\n const [unsupported, setUnsupported] = useState(false);\n const { data, refetch } = useGetSurfaceJobsQuery({\n // No `orgName`: a job is recorded in the request's organization (recordSurfaceJob), and the\n // phone's request organization is not always the workspace it shows - naming that one\n // listed nothing (dev 10/20: three recorded builds, an empty sheet). The name only says the\n // workspace is known, i.e. the person is signed in.\n variables: { limit: JOBS_LIMIT },\n skip: !orgName || unsupported,\n fetchPolicy: 'cache-and-network',\n pollInterval: open ? POLL_OPEN_MS : POLL_CLOSED_MS,\n onError: (error) => {\n if (isSurfaceJobsUnsupported(error.message)) setUnsupported(true);\n },\n });\n const [removeJob] = useRemoveSurfaceJobMutation();\n // Dismissed ids stay hidden until the refetch confirms they are gone.\n const [dismissed, setDismissed] = useState<Set<string>>(() => new Set());\n\n const jobs = useMemo(() => {\n const rows = (data?.getSurfaceJobs ?? []) as RawJobTask[];\n return visibleJobs(centralJobsFrom(rows, []).filter((job) => !dismissed.has(job.id)));\n }, [data, dismissed]);\n const runningCount = useMemo(() => jobs.filter(isJobRunning).length, [jobs]);\n\n const refresh = useCallback(() => {\n if (!unsupported) refetch().catch(() => undefined);\n }, [refetch, unsupported]);\n\n const dismiss = useCallback(\n (id: string) => {\n setDismissed((prev) => new Set(prev).add(id));\n removeJob({ variables: { id } })\n .catch((err: unknown) => console.warn('[Tasks] dismiss failed:', err))\n .finally(refresh);\n },\n [removeJob, refresh],\n );\n\n return { jobs, runningCount, dismiss, refresh };\n}\n"],"names":[],"mappings":"iRAWA,MAAM,YAAe,GAAA,IAAA;AACrB,MAAM,cAAiB,GAAA,GAAA;AACvB,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,MAAA,CAAO,YAAY,CAAE,CAAA,MAAA,EAAQ,CAAC,IAAI,CAAC,CAAA;AAC3E,EAAM,MAAA,OAAA,GAAU,YAAY,MAAM;AAChC,IAAA,IAAI,CAAC,WAAa,EAAA,OAAA,EAAU,CAAA,KAAA,CAAM,MAAM,MAAS,CAAA;AAAA,GAChD,EAAA,CAAC,OAAS,EAAA,WAAW,CAAC,CAAA;AACzB,EAAM,MAAA,OAAA,GAAU,WAAY,CAAA,CAAC,EAAe,KAAA;AAC1C,IAAA,YAAA,CAAa,UAAQ,IAAI,GAAA,CAAI,IAAI,CAAE,CAAA,GAAA,CAAI,EAAE,CAAC,CAAA;AAC1C,IAAU,SAAA,CAAA;AAAA,MACR,SAAW,EAAA;AAAA,QACT;AAAA;AACF,KACD,CAAA,CAAE,KAAM,CAAA,CAAC,GAAiB,KAAA,OAAA,CAAQ,IAAK,CAAA,yBAAA,EAA2B,GAAG,CAAC,CAAE,CAAA,OAAA,CAAQ,OAAO,CAAA;AAAA,GACvF,EAAA,CAAC,SAAW,EAAA,OAAO,CAAC,CAAA;AACvB,EAAO,OAAA;AAAA,IACL,IAAA;AAAA,IACA,YAAA;AAAA,IACA,OAAA;AAAA,IACA;AAAA,GACF;AACF"}
|
|
1
|
+
{"version":3,"file":"useSurfaceJobs.js","sources":["../../src/hooks/useSurfaceJobs.ts"],"sourcesContent":["/**\n * The person's long-running jobs (a Web Builder build, a canvas video, ...) for the\n * Tasks sheet and its badge: the server-owned surface jobs the web chat's Tasks panel\n * reads too (common CENTRAL_TASKS_MODEL), so a job shows wherever it was started and\n * after the app that started it is gone. Polls like the web: often while the sheet is\n * open, rarely while it is closed.\n */\nimport { useCallback, useMemo, useState } from 'react';\nimport {\n useGetSurfaceJobsQuery,\n useGetTasksQuery,\n useRemoveSurfaceJobMutation,\n useRemoveTaskMutation,\n} from 'common/graphql';\nimport {\n centralJobsFrom,\n isJobRunning,\n isSurfaceJobsUnsupported,\n visibleJobs,\n type CentralJob,\n type RawJobTask,\n} from 'common';\nimport { usePrerequisiteIds } from './usePrerequisiteIds';\n\nconst POLL_OPEN_MS = 15_000;\nconst POLL_CLOSED_MS = 60_000;\nconst JOBS_LIMIT = 100;\nconst TASKS_LIMIT = 200;\n\n/** Shared by every screen's header, so a job removed in one is gone from all. */\nconst dismissedJobs = new Set<string>();\n\n/**\n * Reads what the web's useCentralTasks reads - the workspace's surface jobs by name and\n * its tasks (cdecli runs) - plus the request organization's surface jobs. A job is recorded\n * in the request's organization (recordSurfaceJob). Web Builder now names the workspace in\n * the `orgname` header (useWebBuilderJobs), but builds recorded before that went to a request\n * organization that is not always the workspace (dev 10/20: three recorded builds, an empty\n * sheet); the last read keeps those listed until they age out.\n */\nexport function useSurfaceJobs(open: boolean): {\n jobs: CentralJob[];\n runningCount: number;\n loading: boolean;\n dismiss: (id: string) => void;\n clearFinished: () => void;\n refresh: () => void;\n} {\n const { orgName } = usePrerequisiteIds();\n const pollInterval = open ? POLL_OPEN_MS : POLL_CLOSED_MS;\n // Once the backend says it has no getSurfaceJobs, stop asking for this session.\n const [unsupported, setUnsupported] = useState(false);\n const onSurfaceError = (error: { message: string }) => {\n if (isSurfaceJobsUnsupported(error.message)) setUnsupported(true);\n };\n const workspace = useGetSurfaceJobsQuery({\n variables: { limit: JOBS_LIMIT, orgName: orgName || undefined },\n skip: !orgName || unsupported,\n fetchPolicy: 'cache-and-network',\n pollInterval,\n onError: onSurfaceError,\n });\n const own = useGetSurfaceJobsQuery({\n variables: { limit: JOBS_LIMIT },\n skip: !orgName || unsupported,\n fetchPolicy: 'cache-and-network',\n pollInterval,\n onError: onSurfaceError,\n });\n const tasks = useGetTasksQuery({\n variables: { orgName: orgName || undefined, offset: 0, limit: TASKS_LIMIT },\n skip: !orgName,\n fetchPolicy: 'cache-and-network',\n nextFetchPolicy: 'cache-first',\n pollInterval,\n });\n const [removeJob] = useRemoveSurfaceJobMutation();\n const [removeTask] = useRemoveTaskMutation();\n // Dismissed ids stay hidden until the refetch confirms they are gone, in every header.\n const [dismissed, setDismissed] = useState<Set<string>>(() => new Set(dismissedJobs));\n\n const jobs = useMemo(() => {\n const surfaceRows = unsupported\n ? null\n : ([...(workspace.data?.getSurfaceJobs ?? []), ...(own.data?.getSurfaceJobs ?? [])] as RawJobTask[]);\n const taskRows = (tasks.data?.getTasks?.data ?? []) as RawJobTask[];\n return visibleJobs(centralJobsFrom(surfaceRows, taskRows).filter((job) => !dismissed.has(job.id)));\n }, [workspace.data, own.data, tasks.data, unsupported, dismissed]);\n const runningCount = useMemo(() => jobs.filter(isJobRunning).length, [jobs]);\n\n const { refetch: refetchWorkspace } = workspace;\n const { refetch: refetchOwn } = own;\n const { refetch: refetchTasks } = tasks;\n const refresh = useCallback(() => {\n refetchTasks().catch(() => undefined);\n if (unsupported) return;\n refetchWorkspace().catch(() => undefined);\n refetchOwn().catch(() => undefined);\n }, [refetchWorkspace, refetchOwn, refetchTasks, unsupported]);\n\n const removeMany = useCallback(\n (ids: string[]) => {\n if (!ids.length) return;\n ids.forEach((id) => dismissedJobs.add(id));\n setDismissed(new Set(dismissedJobs));\n // A job is removed in the request's organization: the workspace's (named) for what the\n // workspace read lists, the phone's default for its older builds. A cdecli run is a\n // plain task. The first that takes it wins.\n const workspaceContext = orgName ? { headers: { orgname: orgName } } : undefined;\n const removeOne = async (id: string): Promise<boolean> => {\n const attempts: Array<[string, () => Promise<boolean | null | undefined>]> = [\n [\n 'removeSurfaceJob(workspace)',\n () =>\n removeJob({ variables: { id }, context: workspaceContext }).then(\n (r) => r.data?.removeSurfaceJob,\n ),\n ],\n ['removeSurfaceJob', () => removeJob({ variables: { id } }).then((r) => r.data?.removeSurfaceJob)],\n [\n 'removeTask(workspace)',\n () =>\n removeTask({ variables: { id }, context: workspaceContext }).then(\n (r) => r.data?.removeTask,\n ),\n ],\n ];\n const tried: string[] = [];\n for (const [via, attempt] of attempts) {\n try {\n if (await attempt()) return true;\n tried.push(`${via}: false`);\n } catch (err) {\n tried.push(`${via}: ${err instanceof Error ? err.message : String(err)}`);\n }\n }\n console.warn(`[Tasks] could not remove job ${id} (org ${orgName ?? '-'}):`, tried.join(' | '));\n return false;\n };\n Promise.all(ids.map((id) => removeOne(id).then((removed) => ({ id, removed }))))\n .then((results) => {\n const kept = results.filter((r) => !r.removed).map((r) => r.id);\n if (!kept.length) return;\n // Nothing took it: show it again rather than hide a job that is still there.\n kept.forEach((id) => dismissedJobs.delete(id));\n setDismissed(new Set(dismissedJobs));\n })\n .finally(refresh);\n },\n [orgName, removeJob, removeTask, refresh],\n );\n\n const dismiss = useCallback((id: string) => removeMany([id]), [removeMany]);\n const clearFinished = useCallback(\n () => removeMany(jobs.filter((job) => !isJobRunning(job)).map((job) => job.id)),\n [jobs, removeMany],\n );\n\n const loading =\n (tasks.loading && !tasks.data) ||\n (!unsupported && workspace.loading && own.loading && !workspace.data && !own.data);\n\n return { jobs, runningCount, loading, dismiss, clearFinished, refresh };\n}\n"],"names":[],"mappings":"wTAWA,MAAM,YAAe,GAAA,IAAA;AACrB,MAAM,cAAiB,GAAA,GAAA;AACvB,MAAM,UAAa,GAAA,GAAA;AACnB,MAAM,WAAc,GAAA,GAAA;AAGpB,MAAM,aAAA,uBAAoB,GAAY,EAAA;AAU/B,SAAS,eAAe,IAO7B,EAAA;AACA,EAAM,MAAA;AAAA,IACJ;AAAA,MACE,kBAAmB,EAAA;AACvB,EAAM,MAAA,YAAA,GAAe,OAAO,YAAe,GAAA,cAAA;AAE3C,EAAA,MAAM,CAAC,WAAA,EAAa,cAAc,CAAA,GAAI,SAAS,KAAK,CAAA;AACpD,EAAM,MAAA,cAAA,GAAiB,CAAC,KAElB,KAAA;AACJ,IAAA,IAAI,wBAAyB,CAAA,KAAA,CAAM,OAAO,CAAA,iBAAkB,IAAI,CAAA;AAAA,GAClE;AACA,EAAA,MAAM,YAAY,sBAAuB,CAAA;AAAA,IACvC,SAAW,EAAA;AAAA,MACT,KAAO,EAAA,UAAA;AAAA,MACP,SAAS,OAAW,IAAA;AAAA,K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CAAK,OAAQ,CAAA,CAAA,EAAA,KAAM,aAAc,CAAA,MAAA,CAAO,EAAE,CAAC,CAAA;AAC3C,MAAa,YAAA,CAAA,IAAI,GAAI,CAAA,aAAa,CAAC,CAAA;AAAA,KACpC,CAAE,CAAA,OAAA,CAAQ,OAAO,CAAA;AAAA,KACjB,CAAC,OAAA,EAAS,SAAW,EAAA,UAAA,EAAY,OAAO,CAAC,CAAA;AAC5C,EAAM,MAAA,OAAA,GAAU,WAAY,CAAA,CAAC,EAAe,KAAA,UAAA,CAAW,CAAC,EAAE,CAAC,CAAA,EAAG,CAAC,UAAU,CAAC,CAAA;AAC1E,EAAM,MAAA,aAAA,GAAgB,YAAY,MAAM,UAAA,CAAW,KAAK,MAAO,CAAA,CAAA,GAAA,KAAO,CAAC,YAAa,CAAA,GAAG,CAAC,CAAE,CAAA,GAAA,CAAI,SAAO,GAAI,CAAA,EAAE,CAAC,CAAG,EAAA,CAAC,IAAM,EAAA,UAAU,CAAC,CAAA;AACjI,EAAA,MAAM,UAAU,KAAM,CAAA,OAAA,IAAW,CAAC,KAAA,CAAM,QAAQ,CAAC,WAAA,IAAe,SAAU,CAAA,OAAA,IAAW,IAAI,OAAW,IAAA,CAAC,SAAU,CAAA,IAAA,IAAQ,CAAC,GAAI,CAAA,IAAA;AAC5H,EAAO,OAAA;AAAA,IACL,IAAA;AAAA,IACA,YAAA;AAAA,IACA,OAAA;AAAA,IACA,OAAA;AAAA,IACA,aAAA;AAAA,IACA;AAAA,GACF;AACF"}
|
package/lib/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import {Feature}from'@common-stack/client-react';import YantraMobileModule from'./module.js';export{default as Home}from'./screens/Home/
|
|
1
|
+
import {Feature}from'@common-stack/client-react';import YantraMobileModule from'./module.js';export{default as Home}from'./screens/Home/index.js';export{default as NewChat}from'./screens/NewChat/index.js';export{default as Account}from'./screens/Account/index.js';export{default as ChatHistory}from'./screens/ChatHistory/index.js';export{default as Apps}from'./screens/Apps/index.js';export{default as WebBuilder}from'./screens/WebBuilder/index.js';export{GatewayContextProvider,useGatewayContext}from'./contexts/GatewayContext.js';export{CdecliConnectionProvider}from'./contexts/CdecliConnectionContext.js';export{ChatLiveStreamEngine}from'./contexts/ChatLiveStreamContext.js';export{MemoryPressureResponder}from'./features/memory/MemoryPressureResponder.js';export{BUILTIN_MOBILE_GATEWAYS,MAX_CONCURRENT_TASKS,STORAGE_KEYS}from'./config/constants.js';export{config}from'./config/env-config.js';export{useCdecliAutoConnect}from'./hooks/useCdecliAutoConnect.js';export{useObtainSystemToken}from'./hooks/useObtainSystemToken.js';export{mintSurfaceSystemToken,resolveSurfaceCatalogBackend}from'./hooks/mintSurfaceSystemToken.js';export{buildCdecliTokenInjection,buildSurfaceGateRecoveryScript}from'./hooks/surfaceHandoffScript.js';export{isInstanceNotFoundError,useGatewayConnection}from'./hooks/useGatewayConnection.js';export{usePrerequisiteIds}from'./hooks/usePrerequisiteIds.js';export{useWorkspaceProvisioner}from'./hooks/useWorkspaceProvisioner.js';export{useGatewayRegistry}from'./hooks/useGatewayRegistry.js';export{agentSessionManager}from'./services/agentSessionManager.js';export{ensureGatewayApiKeys,resetGatewayApiKeyBridge}from'./services/gatewayApiKeyBridge.js';export{GatewayClient}from'./services/gatewayClient.js';export{BRIDGE_PROTOCOL_VERSION,BRIDGE_READY_ACTION,DEFAULT_BRIDGE_TIMEOUT_MS,DEFAULT_CHUNK_SIZE,MessageType}from'./bridge/types.js';export{WebViewManager}from'./bridge/WebViewManager.js';export{NativeWebViewBridge}from'./bridge/NativeWebViewBridge.js';export{TypedBridge}from'./bridge/TypedBridge.js';export{CancellableRequest}from'./bridge/CancellableRequest.js';export{ChunkedMessageHandler}from'./bridge/ChunkedMessageHandler.js';export{BridgeDebugger}from'./bridge/BridgeDebugger.js';export{WEB_BRIDGE_BOOTSTRAP}from'./bridge/webBridgeBootstrap.js';export{AuthenticatedFetch}from'./bridge/AuthenticatedFetch.js';export{AuthBridgeHandler}from'./bridge/handlers/AuthBridgeHandler.js';export{NavigationBridgeHandler}from'./bridge/handlers/NavigationBridgeHandler.js';export{AnalyticsBridgeHandler}from'./bridge/handlers/AnalyticsBridgeHandler.js';export{SURFACE_HOST_ACTIONS,SurfaceHostBridgeHandler}from'./bridge/handlers/SurfaceHostBridgeHandler.js';export{classifySurfaceNavigation}from'./bridge/surfaceLinkRouting.js';export{getPackagerHost,resolveMobileWebUrl}from'./bridge/resolveMobileWebUrl.js';export{YANTRA_LOADER_SIZE_COMPACT,YANTRA_LOADER_SIZE_DEFAULT,YantraBrandLoader}from'./components/YantraBrandLoader.js';export{default as CustomDrawer}from'./components/CustomDrawer.js';export{AppThemeProvider,useAppTheme}from'./theme/AppThemeProvider.js';export{InviteDeepLink}from'./features/invite/InviteDeepLink.js';export{ChatInviteDeepLink}from'./features/messaging/ChatInviteDeepLink.js';export{HealthSyncRunner}from'./features/health/HealthSyncRunner.js';export{startHealthBackgroundSync}from'./features/health/backgroundSync.js';export{FitnessWidgetRunner}from'./features/fitness-widgets/FitnessWidgetRunner.js';export{FitnessDeepLink}from'./features/fitness-widgets/FitnessDeepLink.js';export{inviteTokenFromUrl,isInviteUrl}from'./features/invite/inviteLink.js';export{isKeyboardControllerAvailable}from'./utils/keyboardController.js';export{getNativeCanvasExperience,getNativeCanvasViewer,preloadNativeCanvasExperience,registerCanvasExperiencePreload,registerNativeCanvasExperience,registerNativeCanvasViewer}from'./features/canvas/nativeViewerRegistry.js';export{getNativeCharactersExperience,registerNativeCharactersExperience}from'./features/characters/nativeCharactersRegistry.js';export{getNativeChatExperience,registerNativeChatExperience}from'./features/messaging/nativeChatRegistry.js';export{forgetChatPushToken,rememberChatPushToken}from'./features/messaging/chatPushToken.js';export{CHAT_NOTIFICATION_CONFIG_KEY,CHAT_NOTIFICATION_KEYS,chatPrefsFromSettings}from'./features/messaging/chatNotificationPrefs.js';export{settingsUriForAccount}from'./utils/cdecodeUri.js';export{getNativeShoppingExperience,preloadNativeShoppingExperience,registerNativeShoppingExperience,registerShoppingExperiencePreload}from'./features/shopping/nativeShoppingRegistry.js';export{getNativeTravelExperience,preloadNativeTravelExperience,registerNativeTravelExperience,registerTravelExperiencePreload}from'./features/travel/nativeTravelRegistry.js';export{getNativeJobSearchExperience,preloadNativeJobSearchExperience,registerJobSearchExperiencePreload,registerNativeJobSearchExperience}from'./features/job-search/nativeJobSearchRegistry.js';export{getNativeResumeExperience,preloadNativeResumeExperience,registerNativeResumeExperience,registerResumeExperiencePreload}from'./features/resume/nativeResumeRegistry.js';export{getNativeInboxExperience,preloadNativeInboxExperience,registerInboxExperiencePreload,registerNativeInboxExperience}from'./features/inbox/nativeInboxRegistry.js';export{getNativeStudyExperience,preloadNativeStudyExperience,registerNativeStudyExperience,registerStudyExperiencePreload}from'./features/study/nativeStudyRegistry.js';export{getNativeLocalServicesExperience,preloadNativeLocalServicesExperience,registerLocalServicesExperiencePreload,registerNativeLocalServicesExperience}from'./features/local-services/nativeLocalServicesRegistry.js';export{getNativeMoviesExperience,preloadNativeMoviesExperience,registerMoviesExperiencePreload,registerNativeMoviesExperience}from'./features/movies/nativeMoviesRegistry.js';export{getNativeExpensesExperience,preloadNativeExpensesExperience,registerExpensesExperiencePreload,registerNativeExpensesExperience}from'./features/expenses/nativeExpensesRegistry.js';export{getNativeWebBuilderExperience,preloadNativeWebBuilderExperience,registerNativeWebBuilderExperience,registerWebBuilderExperiencePreload}from'./features/webbuilder/nativeWebBuilderRegistry.js';export{NativeAgentChat}from'./features/agent-chat/NativeAgentChat.js';export{ChatLinkOpenerProvider}from'./features/links/ChatLinkOpenerProvider.js';export{useCdecliConnection}from'./contexts/cdecliConnection.js';export{resolveSurfaceAuthGraphqlUrl}from'./hooks/resolveSurfaceAuthGraphqlUrl.js';var index = new Feature(YantraMobileModule);export{index as default};//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["import { Feature } from '@common-stack/client-react';\nimport YantraMobileModule from './module';\n\nexport default new Feature(YantraMobileModule);\nexport * from './screens';\nexport { GatewayContextProvider, useGatewayContext } from './contexts/GatewayContext';\nexport { CdecliConnectionProvider, useCdecliConnection } from './contexts/CdecliConnectionContext';\nexport { ChatLiveStreamEngine } from './contexts/ChatLiveStreamContext';\nexport { MemoryPressureResponder } from './features/memory/MemoryPressureResponder';\nexport * from './config/constants';\nexport { config } from './config/env-config';\nexport { useCdecliAutoConnect } from './hooks/useCdecliAutoConnect';\nexport { useObtainSystemToken } from './hooks/useObtainSystemToken';\nexport {\n mintSurfaceSystemToken,\n resolveSurfaceCatalogBackend,\n resolveSurfaceAuthGraphqlUrl,\n} from './hooks/mintSurfaceSystemToken';\nexport { buildCdecliTokenInjection, buildSurfaceGateRecoveryScript } from './hooks/surfaceHandoffScript';\nexport { useGatewayConnection, isInstanceNotFoundError } from './hooks/useGatewayConnection';\nexport { usePrerequisiteIds } from './hooks/usePrerequisiteIds';\nexport { useWorkspaceProvisioner } from './hooks/useWorkspaceProvisioner';\nexport { useGatewayRegistry } from './hooks/useGatewayRegistry';\nexport * from './services';\nexport * from './bridge';\nexport {\n YantraBrandLoader,\n YANTRA_LOADER_SIZE_DEFAULT,\n YANTRA_LOADER_SIZE_COMPACT,\n} from './components/YantraBrandLoader';\nexport { default as CustomDrawer } from './components/CustomDrawer';\nexport { AppThemeProvider, useAppTheme } from './theme/AppThemeProvider';\n// Invite deep links. Mounted by the app at the root (see portable-devices/mobile\n// App.tsx) rather than routed to: the invitee has neither an org nor a session,\n// and every mobile route requires both.\nexport { InviteDeepLink } from './features/invite/InviteDeepLink';\nexport { ChatInviteDeepLink } from './features/messaging/ChatInviteDeepLink';\n// Apple Health / Health Connect sync. Mounted at the app root like the invite\n// handlers: it syncs on every return to the foreground, whatever screen is open.\nexport { HealthSyncRunner } from './features/health/HealthSyncRunner';\n// Apple Health while the app is closed: started once at launch, before anything renders.\nexport { startHealthBackgroundSync } from './features/health/backgroundSync';\n// Fitness widgets (iOS): keeps the home / lock screen snapshot fresh, and opens the\n// Fitness surface when a widget or the workout Live Activity is tapped. Both at the root.\nexport { FitnessWidgetRunner } from './features/fitness-widgets/FitnessWidgetRunner';\nexport { FitnessDeepLink } from './features/fitness-widgets/FitnessDeepLink';\nexport { inviteTokenFromUrl, isInviteUrl } from './features/invite/inviteLink';\nexport { isKeyboardControllerAvailable } from './utils/keyboardController';\n// The canvas viewer seam. Exported from the index on purpose: the app (the MF\n// host) registers the federated viewer here and the CanvasBoard screen reads\n// it. Reachability from this entry is what makes rollup emit the registry as a\n// real shared module - as an internal-only file, `registerNativeCanvasViewer`\n// is never called inside the package, so rollup tree-shakes it and constant-\n// folds the screen down to its fallback branch.\nexport {\n registerNativeCanvasViewer,\n getNativeCanvasViewer,\n registerNativeCanvasExperience,\n getNativeCanvasExperience,\n registerCanvasExperiencePreload,\n preloadNativeCanvasExperience,\n} from './features/canvas/nativeViewerRegistry';\n// Characters seam - same reachability contract as the canvas registry above.\nexport {\n registerNativeCharactersExperience,\n getNativeCharactersExperience,\n} from './features/characters/nativeCharactersRegistry';\n// Chat seam - same reachability contract as the two registries above.\nexport { registerNativeChatExperience, getNativeChatExperience } from './features/messaging/nativeChatRegistry';\n// Chat push + notification preferences: the app (which owns expo-notifications and the\n// settings session) registers the token and serves the preferences through these.\nexport { rememberChatPushToken, forgetChatPushToken } from './features/messaging/chatPushToken';\nexport {\n CHAT_NOTIFICATION_CONFIG_KEY,\n CHAT_NOTIFICATION_KEYS,\n chatPrefsFromSettings,\n} from './features/messaging/chatNotificationPrefs';\nexport { settingsUriForAccount } from './utils/cdecodeUri';\nexport {\n registerNativeShoppingExperience,\n getNativeShoppingExperience,\n registerShoppingExperiencePreload,\n preloadNativeShoppingExperience,\n} from './features/shopping/nativeShoppingRegistry';\nexport type { ShoppingExperienceProps } from './features/shopping/ShoppingExperience';\nexport type { ShoppingHostChat } from './features/shopping/hostChat';\nexport {\n registerNativeTravelExperience,\n getNativeTravelExperience,\n registerTravelExperiencePreload,\n preloadNativeTravelExperience,\n} from './features/travel/nativeTravelRegistry';\nexport type { TravelExperienceProps } from './features/travel/TravelExperience';\nexport type { TravelHostChat } from './features/travel/hostChat';\nexport {\n registerNativeJobSearchExperience,\n getNativeJobSearchExperience,\n registerJobSearchExperiencePreload,\n preloadNativeJobSearchExperience,\n} from './features/job-search/nativeJobSearchRegistry';\nexport type { JobSearchExperienceProps } from './features/job-search/JobSearchExperience';\nexport type { JobSearchHostChat } from './features/job-search/hostChat';\nexport {\n registerNativeResumeExperience,\n getNativeResumeExperience,\n registerResumeExperiencePreload,\n preloadNativeResumeExperience,\n} from './features/resume/nativeResumeRegistry';\nexport type { ResumeExperienceProps } from './features/resume/ResumeExperience';\nexport type { ResumeHostChat } from './features/resume/hostChat';\nexport {\n registerNativeInboxExperience,\n getNativeInboxExperience,\n registerInboxExperiencePreload,\n preloadNativeInboxExperience,\n} from './features/inbox/nativeInboxRegistry';\nexport type { InboxExperienceProps } from './features/inbox/InboxExperience';\nexport type { InboxHostChat } from './features/inbox/hostChat';\nexport {\n registerNativeStudyExperience,\n getNativeStudyExperience,\n registerStudyExperiencePreload,\n preloadNativeStudyExperience,\n} from './features/study/nativeStudyRegistry';\nexport type { StudyExperienceProps } from './features/study/StudyExperience';\nexport type { StudyHostChat } from './features/study/hostChat';\nexport {\n registerNativeLocalServicesExperience,\n getNativeLocalServicesExperience,\n registerLocalServicesExperiencePreload,\n preloadNativeLocalServicesExperience,\n} from './features/local-services/nativeLocalServicesRegistry';\nexport type { LocalServicesExperienceProps } from './features/local-services/LocalServicesExperience';\nexport type { LocalServicesHostChat } from './features/local-services/hostChat';\nexport {\n registerNativeMoviesExperience,\n getNativeMoviesExperience,\n registerMoviesExperiencePreload,\n preloadNativeMoviesExperience,\n} from './features/movies/nativeMoviesRegistry';\nexport type { MoviesExperienceProps } from './features/movies/MoviesExperience';\nexport type { MoviesHostChat } from './features/movies/hostChat';\nexport {\n registerNativeExpensesExperience,\n getNativeExpensesExperience,\n registerExpensesExperiencePreload,\n preloadNativeExpensesExperience,\n} from './features/expenses/nativeExpensesRegistry';\nexport type { ExpensesExperienceProps } from './features/expenses/ExpensesExperience';\nexport type { ExpensesHostChat } from './features/expenses/hostChat';\nexport {\n registerNativeWebBuilderExperience,\n getNativeWebBuilderExperience,\n registerWebBuilderExperiencePreload,\n preloadNativeWebBuilderExperience,\n} from './features/webbuilder/nativeWebBuilderRegistry';\nexport type { WebBuilderExperienceProps } from './features/webbuilder/WebBuilderExperience';\nexport type { WebBuilderHostChat } from './features/webbuilder/hostChat';\nexport { NativeAgentChat } from './features/agent-chat';\nexport { ChatLinkOpenerProvider } from './features/links/ChatLinkOpenerProvider';\nexport type { AgentChatMessage, AgentChatSuggestion, NativeAgentChatProps } from './features/agent-chat';\nexport type {\n ChatHostServices,\n ChatViewer,\n FederatedChatProps,\n NativeChatExperienceProps,\n} from './features/messaging/chatHost';\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["import { Feature } from '@common-stack/client-react';\nimport YantraMobileModule from './module';\n\nexport default new Feature(YantraMobileModule);\nexport * from './screens';\nexport { GatewayContextProvider, useGatewayContext } from './contexts/GatewayContext';\nexport { CdecliConnectionProvider, useCdecliConnection } from './contexts/CdecliConnectionContext';\nexport { ChatLiveStreamEngine } from './contexts/ChatLiveStreamContext';\nexport { MemoryPressureResponder } from './features/memory/MemoryPressureResponder';\nexport * from './config/constants';\nexport { config } from './config/env-config';\nexport { useCdecliAutoConnect } from './hooks/useCdecliAutoConnect';\nexport { useObtainSystemToken } from './hooks/useObtainSystemToken';\nexport {\n mintSurfaceSystemToken,\n resolveSurfaceCatalogBackend,\n resolveSurfaceAuthGraphqlUrl,\n} from './hooks/mintSurfaceSystemToken';\nexport { buildCdecliTokenInjection, buildSurfaceGateRecoveryScript } from './hooks/surfaceHandoffScript';\nexport { useGatewayConnection, isInstanceNotFoundError } from './hooks/useGatewayConnection';\nexport { usePrerequisiteIds } from './hooks/usePrerequisiteIds';\nexport { useWorkspaceProvisioner } from './hooks/useWorkspaceProvisioner';\nexport { useGatewayRegistry } from './hooks/useGatewayRegistry';\nexport * from './services';\nexport * from './bridge';\nexport {\n YantraBrandLoader,\n YANTRA_LOADER_SIZE_DEFAULT,\n YANTRA_LOADER_SIZE_COMPACT,\n} from './components/YantraBrandLoader';\nexport { default as CustomDrawer } from './components/CustomDrawer';\nexport { AppThemeProvider, useAppTheme } from './theme/AppThemeProvider';\n// Invite deep links. Mounted by the app at the root (see portable-devices/mobile\n// App.tsx) rather than routed to: the invitee has neither an org nor a session,\n// and every mobile route requires both.\nexport { InviteDeepLink } from './features/invite/InviteDeepLink';\nexport { ChatInviteDeepLink } from './features/messaging/ChatInviteDeepLink';\n// Apple Health / Health Connect sync. Mounted at the app root like the invite\n// handlers: it syncs on every return to the foreground, whatever screen is open.\nexport { HealthSyncRunner } from './features/health/HealthSyncRunner';\n// Apple Health while the app is closed: started once at launch, before anything renders.\nexport { startHealthBackgroundSync } from './features/health/backgroundSync';\n// Fitness widgets (iOS): keeps the home / lock screen snapshot fresh, and opens the\n// Fitness surface when a widget or the workout Live Activity is tapped. Both at the root.\nexport { FitnessWidgetRunner } from './features/fitness-widgets/FitnessWidgetRunner';\nexport { FitnessDeepLink } from './features/fitness-widgets/FitnessDeepLink';\nexport { inviteTokenFromUrl, isInviteUrl } from './features/invite/inviteLink';\nexport { isKeyboardControllerAvailable } from './utils/keyboardController';\n// The canvas viewer seam. Exported from the index on purpose: the app (the MF\n// host) registers the federated viewer here and the CanvasBoard screen reads\n// it. Reachability from this entry is what makes rollup emit the registry as a\n// real shared module - as an internal-only file, `registerNativeCanvasViewer`\n// is never called inside the package, so rollup tree-shakes it and constant-\n// folds the screen down to its fallback branch.\nexport {\n registerNativeCanvasViewer,\n getNativeCanvasViewer,\n registerNativeCanvasExperience,\n getNativeCanvasExperience,\n registerCanvasExperiencePreload,\n preloadNativeCanvasExperience,\n} from './features/canvas/nativeViewerRegistry';\n// Characters seam - same reachability contract as the canvas registry above.\nexport {\n registerNativeCharactersExperience,\n getNativeCharactersExperience,\n} from './features/characters/nativeCharactersRegistry';\n// Chat seam - same reachability contract as the two registries above.\nexport { registerNativeChatExperience, getNativeChatExperience } from './features/messaging/nativeChatRegistry';\n// Chat push + notification preferences: the app (which owns expo-notifications and the\n// settings session) registers the token and serves the preferences through these.\nexport { rememberChatPushToken, forgetChatPushToken } from './features/messaging/chatPushToken';\nexport {\n CHAT_NOTIFICATION_CONFIG_KEY,\n CHAT_NOTIFICATION_KEYS,\n chatPrefsFromSettings,\n} from './features/messaging/chatNotificationPrefs';\nexport { settingsUriForAccount } from './utils/cdecodeUri';\nexport {\n registerNativeShoppingExperience,\n getNativeShoppingExperience,\n registerShoppingExperiencePreload,\n preloadNativeShoppingExperience,\n} from './features/shopping/nativeShoppingRegistry';\nexport type { ShoppingExperienceProps } from './features/shopping/ShoppingExperience';\nexport type { ShoppingHostChat } from './features/shopping/hostChat';\nexport {\n registerNativeTravelExperience,\n getNativeTravelExperience,\n registerTravelExperiencePreload,\n preloadNativeTravelExperience,\n} from './features/travel/nativeTravelRegistry';\nexport type { TravelExperienceProps } from './features/travel/TravelExperience';\nexport type { TravelHostChat } from './features/travel/hostChat';\nexport {\n registerNativeJobSearchExperience,\n getNativeJobSearchExperience,\n registerJobSearchExperiencePreload,\n preloadNativeJobSearchExperience,\n} from './features/job-search/nativeJobSearchRegistry';\nexport type { JobSearchExperienceProps } from './features/job-search/JobSearchExperience';\nexport type { JobSearchHostChat } from './features/job-search/hostChat';\nexport {\n registerNativeResumeExperience,\n getNativeResumeExperience,\n registerResumeExperiencePreload,\n preloadNativeResumeExperience,\n} from './features/resume/nativeResumeRegistry';\nexport type { ResumeExperienceProps } from './features/resume/ResumeExperience';\nexport type { ResumeHostChat } from './features/resume/hostChat';\nexport {\n registerNativeInboxExperience,\n getNativeInboxExperience,\n registerInboxExperiencePreload,\n preloadNativeInboxExperience,\n} from './features/inbox/nativeInboxRegistry';\nexport type { InboxExperienceProps } from './features/inbox/InboxExperience';\nexport type { InboxHostChat } from './features/inbox/hostChat';\nexport {\n registerNativeStudyExperience,\n getNativeStudyExperience,\n registerStudyExperiencePreload,\n preloadNativeStudyExperience,\n} from './features/study/nativeStudyRegistry';\nexport type { StudyExperienceProps } from './features/study/StudyExperience';\nexport type { StudyHostChat } from './features/study/hostChat';\nexport {\n registerNativeLocalServicesExperience,\n getNativeLocalServicesExperience,\n registerLocalServicesExperiencePreload,\n preloadNativeLocalServicesExperience,\n} from './features/local-services/nativeLocalServicesRegistry';\nexport type { LocalServicesExperienceProps } from './features/local-services/LocalServicesExperience';\nexport type { LocalServicesHostChat } from './features/local-services/hostChat';\nexport {\n registerNativeMoviesExperience,\n getNativeMoviesExperience,\n registerMoviesExperiencePreload,\n preloadNativeMoviesExperience,\n} from './features/movies/nativeMoviesRegistry';\nexport type { MoviesExperienceProps } from './features/movies/MoviesExperience';\nexport type { MoviesHostChat } from './features/movies/hostChat';\nexport {\n registerNativeExpensesExperience,\n getNativeExpensesExperience,\n registerExpensesExperiencePreload,\n preloadNativeExpensesExperience,\n} from './features/expenses/nativeExpensesRegistry';\nexport type { ExpensesExperienceProps } from './features/expenses/ExpensesExperience';\nexport type { ExpensesHostChat } from './features/expenses/hostChat';\nexport {\n registerNativeWebBuilderExperience,\n getNativeWebBuilderExperience,\n registerWebBuilderExperiencePreload,\n preloadNativeWebBuilderExperience,\n} from './features/webbuilder/nativeWebBuilderRegistry';\nexport type { WebBuilderExperienceProps } from './features/webbuilder/WebBuilderExperience';\nexport type { WebBuilderHostChat } from './features/webbuilder/hostChat';\nexport { NativeAgentChat } from './features/agent-chat';\nexport { ChatLinkOpenerProvider } from './features/links/ChatLinkOpenerProvider';\nexport type { AgentChatMessage, AgentChatSuggestion, NativeAgentChatProps } from './features/agent-chat';\nexport type {\n ChatHostServices,\n ChatViewer,\n FederatedChatProps,\n NativeChatExperienceProps,\n} from './features/messaging/chatHost';\n"],"names":[],"mappings":"05MAEA,YAAe,IAAI,QAAQ,kBAAkB,CAAA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {useMemo,useLayoutEffect,useState,useCallback,useRef,useEffect}from'react';import {useWindowDimensions,Keyboard,StyleSheet,View,Pressable}from'react-native';import {getDefaultLeftItems,Box,Text,InputToolBar}from'@admin-layout/gluestack-ui-mobile';import {useSafeAreaInsets,SafeAreaView}from'react-native-safe-area-context';import {useNavigation,useRoute,CommonActions}from'@react-navigation/native';import {MessageActionBar}from'../../features/chat/MessageActionBar.js';import {ChatTranscript}from'../../features/chat/ChatTranscript.js';import {ChatLinkOpenerProvider}from'../../features/links/ChatLinkOpenerProvider.js';import {AskUserCard}from'../../features/chat/AskUserCard.js';import {pendingAskUser}from'../../features/chat/askUser.js';import {PendingConnectorConnectCard}from'../../features/chat/ConnectorConnectPrompt.js';import {QueuedFollowUps}from'../../features/chat/QueuedFollowUps.js';import {queuedFollowUpRows}from'../../features/chat/queuedFollowUpRows.js';import {displayConnectorConnectMessages,displayConnectorConnectText}from'common';import {splitPreResponse}from'../../features/chat/preResponse.js';import {FreeCreditsCard}from'../../features/credits/FreeCreditsCard.js';import {lockedTurnToResend}from'../../features/credits/freeCredits.js';import {useFreeCredits}from'../../features/credits/useFreeCredits.js';import'common/graphql';import'../../config/env-config.js';import'../../hooks/usePrerequisiteIds.js';import'@react-native-async-storage/async-storage';import'expo-secure-store';import'../../features/messaging/yantraChatOrg.js';import {useCdecliConnection}from'../../contexts/cdecliConnection.js';import'../../contexts/GatewayContext.js';import {useChatLiveStream}from'../../contexts/ChatLiveStreamContext.js';import {KeyboardAwareScreen,KeyboardComposerDock}from'../../components/KeyboardComposerDock.js';import {YantraBrandLoader,YANTRA_LOADER_SIZE_COMPACT}from'../../components/YantraBrandLoader.js';import ThinkingIndicator from'../../components/ThinkingIndicator.js';import {mobileTokens}from'../../theme/mobileTokens.js';import {useAppTheme}from'../../theme/AppThemeProvider.js';import DeepSearchModal from'../Home/components/DeepSearchModal.js';import {normalizeSummaryText,extractDeepSearchSources}from'../Home/deepSearchUtils.js';import {AudioRecorderPanel}from'../../features/audio-input/AudioRecorderPanel.js';import {NativeDictationBar}from'../../features/audio-input/NativeDictationBar.js';import {isNativeDictationAvailable}from'../../features/audio-input/nativeDictation.js';import {useImageAttachments}from'../../features/attachments/useImageAttachments.js';import {ComposerAttachmentBar}from'../../features/attachments/ComposerAttachmentBar.js';import {useComposerAttachMenu}from'../../features/attachments/ComposerAttachMenu.js';import {peekComposerAttachments,hasComposerAttachments,takeComposerAttachments}from'../../features/attachments/composerAttachmentHandoff.js';import {MicErrorBoundary}from'../../features/audio-input/MicErrorBoundary.js';import {requestMicPermission}from'../../features/audio-input/useAudioPermission.js';import {shouldRedirectToShop}from'../../features/shopping/chat/homeShoppingIntent.js';import {replaceWithShopNative,shopHandoffParams,pushShopNative}from'../../features/shopping/chat/openShopNative.js';import {resolveNativeHandoff,nativeRouteForConnectors}from'../../features/apps/nativeAppHandoff.js';import {parseToolActivity}from'../../features/chat/toolActivity.js';import {replaceWithNativeApp,nativeHandoffParams,pushNativeApp}from'../../features/apps/nativeAppNavigation.js';var __defProp = Object.defineProperty;
|
|
1
|
+
import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {useMemo,useLayoutEffect,useState,useCallback,useRef,useEffect}from'react';import {useWindowDimensions,Keyboard,StyleSheet,View,Pressable}from'react-native';import {getDefaultLeftItems,Box,Text,InputToolBar}from'@admin-layout/gluestack-ui-mobile';import {useSafeAreaInsets,SafeAreaView}from'react-native-safe-area-context';import {useNavigation,useRoute,CommonActions}from'@react-navigation/native';import {MessageActionBar}from'../../features/chat/MessageActionBar.js';import {withTemporaryChat}from'../../features/chat/withTemporaryChat.js';import {ChatTranscript}from'../../features/chat/ChatTranscript.js';import {ChatLinkOpenerProvider}from'../../features/links/ChatLinkOpenerProvider.js';import {AskUserCard}from'../../features/chat/AskUserCard.js';import {pendingAskUser}from'../../features/chat/askUser.js';import {PendingConnectorConnectCard}from'../../features/chat/ConnectorConnectPrompt.js';import {QueuedFollowUps}from'../../features/chat/QueuedFollowUps.js';import {queuedFollowUpRows}from'../../features/chat/queuedFollowUpRows.js';import {displayConnectorConnectMessages,displayConnectorConnectText}from'common';import {splitPreResponse}from'../../features/chat/preResponse.js';import {FreeCreditsCard}from'../../features/credits/FreeCreditsCard.js';import {lockedTurnToResend}from'../../features/credits/freeCredits.js';import {useFreeCredits}from'../../features/credits/useFreeCredits.js';import'common/graphql';import'../../config/env-config.js';import'../../hooks/usePrerequisiteIds.js';import'@react-native-async-storage/async-storage';import'expo-secure-store';import'../../features/messaging/yantraChatOrg.js';import {useCdecliConnection}from'../../contexts/cdecliConnection.js';import'../../contexts/GatewayContext.js';import {useChatLiveStream}from'../../contexts/ChatLiveStreamContext.js';import {KeyboardAwareScreen,KeyboardComposerDock}from'../../components/KeyboardComposerDock.js';import {YantraBrandLoader,YANTRA_LOADER_SIZE_COMPACT}from'../../components/YantraBrandLoader.js';import ThinkingIndicator from'../../components/ThinkingIndicator.js';import {mobileTokens}from'../../theme/mobileTokens.js';import {useAppTheme}from'../../theme/AppThemeProvider.js';import DeepSearchModal from'../Home/components/DeepSearchModal.js';import {normalizeSummaryText,extractDeepSearchSources}from'../Home/deepSearchUtils.js';import {AudioRecorderPanel}from'../../features/audio-input/AudioRecorderPanel.js';import {NativeDictationBar}from'../../features/audio-input/NativeDictationBar.js';import {isNativeDictationAvailable}from'../../features/audio-input/nativeDictation.js';import {useImageAttachments}from'../../features/attachments/useImageAttachments.js';import {ComposerAttachmentBar}from'../../features/attachments/ComposerAttachmentBar.js';import {useComposerAttachMenu}from'../../features/attachments/ComposerAttachMenu.js';import {peekComposerAttachments,hasComposerAttachments,takeComposerAttachments}from'../../features/attachments/composerAttachmentHandoff.js';import {MicErrorBoundary}from'../../features/audio-input/MicErrorBoundary.js';import {requestMicPermission}from'../../features/audio-input/useAudioPermission.js';import {shouldRedirectToShop}from'../../features/shopping/chat/homeShoppingIntent.js';import {replaceWithShopNative,shopHandoffParams,pushShopNative}from'../../features/shopping/chat/openShopNative.js';import {resolveNativeHandoff,nativeRouteForConnectors}from'../../features/apps/nativeAppHandoff.js';import {parseToolActivity}from'../../features/chat/toolActivity.js';import {replaceWithNativeApp,nativeHandoffParams,pushNativeApp}from'../../features/apps/nativeAppNavigation.js';var __defProp = Object.defineProperty;
|
|
2
2
|
var __defProps = Object.defineProperties;
|
|
3
3
|
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
4
|
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
@@ -710,4 +710,5 @@ const styles = StyleSheet.create({
|
|
|
710
710
|
paddingTop: 10,
|
|
711
711
|
paddingBottom: 4
|
|
712
712
|
}
|
|
713
|
-
});
|
|
713
|
+
});
|
|
714
|
+
var index = withTemporaryChat(ChatScreen);export{index as default};//# sourceMappingURL=index.js.map
|