diff --git a/CLAUDE.md b/CLAUDE.md index 9d37244fd..fa0566525 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -99,6 +99,12 @@ pnpm run typecheck pnpm run test ``` +You must first use `typecheck` to check if the code types are correct, and after making modifications, you need to use `typecheck` again until it passes. + +After the `typecheck` passes, you can use `lint:fix` to check the code quality. + +This project is a monorepo, and you can use the typecheck and `lint:fix` of sub-packages as needed, but please note that you must follow the above steps in order. + ## Architecture Guidelines ### Multi-Platform Architecture diff --git a/apps/desktop/layer/renderer/src/modules/ai-task/components/ai-task-modal.tsx b/apps/desktop/layer/renderer/src/modules/ai-task/components/ai-task-modal.tsx index 50ba26985..da4004767 100644 --- a/apps/desktop/layer/renderer/src/modules/ai-task/components/ai-task-modal.tsx +++ b/apps/desktop/layer/renderer/src/modules/ai-task/components/ai-task-modal.tsx @@ -148,38 +148,46 @@ export const AITaskModal = ({ task, prompt, onSubmit }: AITaskModalProps) => { } const handleSubmit = async (data: TaskFormData) => { - try { - // Process the form data to ensure proper datetime format - const processedData = { - ...data, - schedule: data.schedule, - } + // Process the form data to ensure proper datetime format + const processedData = { + ...data, + schedule: data.schedule, + } - if (isEditing) { - // Update existing task - await updateAITaskMutation.mutateAsync({ + // The optimistic mutations handle success/error toasts and error cases automatically + if (isEditing) { + // Update existing task + updateAITaskMutation.mutate( + { id: task.id, name: processedData.title, prompt: processedData.prompt, schedule: processedData.schedule, - }) - toast.success(t("tasks.toast.updated")) - } else { - // Create new task - await createAITaskMutation.mutateAsync({ + }, + { + onSuccess: () => { + toast.success(t("tasks.toast.updated")) + onSubmit?.(processedData) + dismiss() + }, + }, + ) + } else { + // Create new task + createAITaskMutation.mutate( + { name: processedData.title, prompt: processedData.prompt, schedule: processedData.schedule, - }) - toast.success(t("tasks.toast.created")) - } - - // Call the optional onSubmit callback - onSubmit?.(processedData) - dismiss() - } catch (error) { - console.error(`Failed to update/create AI task:`, error) - toast.error(isEditing ? t("tasks.toast.update_error") : t("tasks.toast.create_error")) + }, + { + onSuccess: () => { + toast.success(t("tasks.toast.created")) + onSubmit?.(processedData) + dismiss() + }, + }, + ) } } @@ -279,19 +287,13 @@ export const AITaskModal = ({ task, prompt, onSubmit }: AITaskModalProps) => { {t("words.cancel", { ns: "common" })} diff --git a/apps/desktop/layer/renderer/src/modules/ai-task/components/task-item.tsx b/apps/desktop/layer/renderer/src/modules/ai-task/components/task-item.tsx index 3e32f73a6..7d72f5efc 100644 --- a/apps/desktop/layer/renderer/src/modules/ai-task/components/task-item.tsx +++ b/apps/desktop/layer/renderer/src/modules/ai-task/components/task-item.tsx @@ -62,16 +62,16 @@ const getTaskStatus = (task: AITask) => { const getStatusColor = (status: string) => { switch (status) { case "completed": { - return "text-green-600 bg-green-50 border-green-200" + return "text-green bg-green-50 dark:bg-green-950" } case "scheduled": { - return "text-blue-600 bg-blue-50 border-blue-200" + return "text-blue bg-blue-50 dark:bg-blue-950" } case "paused": { - return "text-gray-600 bg-gray-50 border-gray-200" + return "text-gray bg-gray-50 dark:bg-gray-950" } default: { - return "text-gray-600 bg-gray-50 border-gray-200" + return "text-gray bg-gray-50 dark:bg-gray-950" } } } @@ -112,7 +112,7 @@ export const TaskItem = memo(({ task, isDeleting, onDelete, onTog

{task.name}

diff --git a/apps/desktop/layer/renderer/src/modules/ai-task/query.ts b/apps/desktop/layer/renderer/src/modules/ai-task/query.ts index a8259967a..5ae9cd737 100644 --- a/apps/desktop/layer/renderer/src/modules/ai-task/query.ts +++ b/apps/desktop/layer/renderer/src/modules/ai-task/query.ts @@ -1,32 +1,35 @@ +import type { WithOptimistic } from "@follow/hooks" +import { createOptimisticConfig, useOptimisticMutation } from "@follow/hooks" import type { + AITask, CreateTaskRequest, TaskCreateResponse, - TaskDeleteResponse, - TaskUpdateResponse, UpdateTaskRequest, } from "@follow-app/client-sdk" -import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query" +import { useQuery } from "@tanstack/react-query" import { followApi } from "~/lib/api-client" const MAX_AI_TASKS = 10 +// Use the generic optimistic wrapper type +type OptimisticAITask = WithOptimistic + +const aiTaskKey = "ai-task" export const aiTaskKeys = { - all: ["ai-task"] as const, - lists: () => [...aiTaskKeys.all, "list"] as const, - list: () => [...aiTaskKeys.lists()] as const, - details: () => [...aiTaskKeys.all, "detail"] as const, - detail: (id: string) => [...aiTaskKeys.details(), id] as const, + list: [aiTaskKey, "list"] as const, + details: [aiTaskKey, "detail"] as const, + detail: (id: string) => [...aiTaskKeys.details, id] as const, } // Queries export const useAITaskListQuery = () => { const { data } = useQuery({ - queryKey: aiTaskKeys.list(), - queryFn: () => followApi.aiTask.list(), + queryKey: aiTaskKeys.list, + queryFn: () => followApi.aiTask.list().then((res) => res.data), }) - return data?.data + return data } export const useCanCreateNewAITask = () => { @@ -37,7 +40,7 @@ export const useCanCreateNewAITask = () => { export const useAITaskQuery = (id: string | undefined, opts?: { enabled?: boolean }) => { const enabled = !!id && (opts?.enabled ?? true) const { data } = useQuery({ - queryKey: id ? aiTaskKeys.detail(id) : aiTaskKeys.details(), + queryKey: id ? aiTaskKeys.detail(id) : aiTaskKeys.details, queryFn: () => followApi.aiTask.get({ id: id as string }), enabled, }) @@ -47,38 +50,52 @@ export const useAITaskQuery = (id: string | undefined, opts?: { enabled?: boolea // Mutations export const useCreateAITaskMutation = () => { - const qc = useQueryClient() - return useMutation({ - mutationFn: (input) => followApi.aiTask.create(input), - onSuccess: async () => { - await qc.invalidateQueries({ queryKey: aiTaskKeys.lists() }) - }, - }) + return useOptimisticMutation( + createOptimisticConfig.forCreate({ + mutationFn: (input) => followApi.aiTask.create(input), + queryKey: aiTaskKeys.list, + generateOptimistic: (variables) => ({ + name: variables.name, + prompt: variables.prompt, + isEnabled: variables.isEnabled ?? true, + schedule: variables.schedule, + userId: "temp-user", + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), + lastRunAt: null, + nextRunAt: null, + runCount: 0, + lastResult: null, + lastError: null, + }), + + errorMessage: "Failed to create AI task", + retryable: false, + }), + ) } export const useUpdateAITaskMutation = () => { - const qc = useQueryClient() - return useMutation({ - mutationFn: (input) => followApi.aiTask.update(input), - onSuccess: async (res) => { - const id = res?.data?.id ?? undefined - await Promise.all([ - qc.invalidateQueries({ queryKey: aiTaskKeys.lists() }), - id ? qc.invalidateQueries({ queryKey: aiTaskKeys.detail(id) }) : Promise.resolve(), - ]) - }, - }) + return useOptimisticMutation( + createOptimisticConfig.forUpdate({ + mutationFn: (input) => followApi.aiTask.update(input), + queryKey: aiTaskKeys.list, + getId: (variables) => variables.id, + errorMessage: "Failed to update AI task", + retryable: false, + }), + ) } export const useDeleteAITaskMutation = () => { - const qc = useQueryClient() - return useMutation({ - mutationFn: ({ id }) => followApi.aiTask.delete({ id }), - onSuccess: async (_res, vars) => { - await Promise.all([ - qc.invalidateQueries({ queryKey: aiTaskKeys.lists() }), - qc.invalidateQueries({ queryKey: aiTaskKeys.detail(vars.id) }), - ]) - }, - }) + return useOptimisticMutation( + createOptimisticConfig.forDelete({ + mutationFn: ({ id }) => followApi.aiTask.delete({ id }), + queryKey: aiTaskKeys.list, + getId: (variables) => variables.id, + + errorMessage: "Failed to delete AI task", + retryable: false, + }), + ) } diff --git a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetCard.tsx b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetCard.tsx new file mode 100644 index 000000000..94275fc9a --- /dev/null +++ b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetCard.tsx @@ -0,0 +1,54 @@ +import { Button } from "@follow/components/ui/button/index.js" + +import type { MCPPreset } from "./types" + +interface MCPPresetCardProps { + preset: MCPPreset + onSelect: (preset: MCPPreset) => void +} + +export const MCPPresetCard = ({ preset, onSelect }: MCPPresetCardProps) => { + return ( +
+
+ {/* Icon */} +
+ +
+ + {/* Service Name */} +

{preset.displayName}

+ + {/* Description */} +

{preset.description}

+ + {/* Features */} +
+ {preset.features.map((feature) => ( +
+ • + {feature} +
+ ))} +
+ + {/* Action Button */} + + + {/* Auth Required Indicator */} + {preset.authRequired && ( +
+ + Authentication required +
+ )} +
+
+ ) +} diff --git a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetSelectionModal.tsx b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetSelectionModal.tsx new file mode 100644 index 000000000..ad41d7990 --- /dev/null +++ b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPPresetSelectionModal.tsx @@ -0,0 +1,79 @@ +import { Button } from "@follow/components/ui/button/index.js" + +import { MCPPresetCard } from "./MCPPresetCard" +import type { MCPPreset } from "./types" +import { MCP_PRESETS } from "./types" + +interface MCPPresetSelectionModalProps { + onPresetSelected: (preset: MCPPreset) => void + onManualConfig: () => void +} + +export const MCPPresetSelectionModal = ({ + onPresetSelected, + onManualConfig, +}: MCPPresetSelectionModalProps) => { + return ( +
+
+
+ {MCP_PRESETS.map((preset) => ( + + ))} + + {/* Custom/Manual Configuration Card */} +
+
+
+ +
+ +

Custom

+ +

+ Manual configuration for other MCP services +

+ +
+
+ • + Custom URL & settings +
+
+ • + Advanced configuration +
+
+ • + Full control +
+
+ + +
+
+
+
+ + {/* Future Services Hint */} +
+
+ +
+

More services coming soon

+

+ You can use the custom configuration option for any MCP-compatible service. +

+
+
+
+
+ ) +} diff --git a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServiceModalContent.tsx b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServiceModalContent.tsx index f778066d6..dfc969d62 100644 --- a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServiceModalContent.tsx +++ b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServiceModalContent.tsx @@ -16,6 +16,11 @@ import { toast } from "sonner" interface MCPServiceModalContentProps { service?: MCPService | null + initialValues?: { + name: string + transportType: "streamable-http" | "sse" + url: string + } onSave: (service: { name: string transportType: "streamable-http" | "sse" @@ -23,20 +28,19 @@ interface MCPServiceModalContentProps { headers?: Record }) => void onCancel: () => void - isLoading?: boolean } export const MCPServiceModalContent = ({ service, + initialValues, onSave, onCancel, - isLoading = false, }: MCPServiceModalContentProps) => { const { t } = useTranslation("ai") - const [name, setName] = useState(service?.name || "") - const [url, setUrl] = useState(service?.url || "") + const [name, setName] = useState(service?.name || initialValues?.name || "") + const [url, setUrl] = useState(service?.url || initialValues?.url || "") const [transportType, setTransportType] = useState<"streamable-http" | "sse">( - service?.transportType || "streamable-http", + service?.transportType || initialValues?.transportType || "streamable-http", ) const [headers, setHeaders] = useState>(service?.headers || {}) @@ -122,18 +126,11 @@ export const MCPServiceModalContent = ({
- -
diff --git a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServicesSection.tsx b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServicesSection.tsx index 93bcf328c..5d2bd6e16 100644 --- a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServicesSection.tsx +++ b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/MCPServicesSection.tsx @@ -1,11 +1,14 @@ import { Button } from "@follow/components/ui/button/index.js" import { Label } from "@follow/components/ui/label/index.jsx" import { Switch } from "@follow/components/ui/switch/index.jsx" +import type { WithOptimistic } from "@follow/hooks" +import { createOptimisticConfig, useOptimisticMutation } from "@follow/hooks" import type { MCPService } from "@follow/shared/settings/interface" import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query" import * as React from "react" import { useTranslation } from "react-i18next" import { toast } from "sonner" +import { useEventListener } from "usehooks-ts" import { setMCPEnabled, useMCPEnabled } from "~/atoms/settings/ai" import { useDialog, useModalStack } from "~/components/ui/modal/stacked/hooks" @@ -18,17 +21,23 @@ import { updateMCPConnection, } from "~/queries/mcp" +import { MCPPresetSelectionModal } from "./MCPPresetSelectionModal" import { MCPServiceItem } from "./MCPServiceItem" import { MCPServiceModalContent } from "./MCPServiceModalContent" +// Use the generic optimistic wrapper type +type OptimisticMCPService = WithOptimistic + export const MCPServicesSection = () => { const { t } = useTranslation("ai") const mcpEnabled = useMCPEnabled() const queryClient = useQueryClient() const dialog = useDialog() + const shouldWindowFocusRefetchRef = React.useRef(false) + // Reusable OAuth authorization handler using dialog - const handleOAuthAuthorization = async (authorizationUrl: string, connectionId?: string) => { + const handleOAuthAuthorization = async (authorizationUrl: string, _connectionId?: string) => { const confirmed = await dialog.ask({ title: t("integration.mcp.service.auth_required"), message: t("integration.mcp.service.auth_message"), @@ -41,22 +50,24 @@ export const MCPServicesSection = () => { const popup = window.open( authorizationUrl, "_blank", - "width=600,height=700,scrollbars=yes,resizable=yes", + "width=600,height=700,scrollbars=yes,resizable=yes,popup=yes", ) if (!popup) { toast.error(t("integration.mcp.service.popup_blocked")) } else { - popup.onclose = () => { - // FIXME - setTimeout(() => { - refreshToolsMutation.mutate(connectionId ? [connectionId] : undefined) - }, 3000) - } + shouldWindowFocusRefetchRef.current = true } } } + useEventListener("focus", () => { + if (shouldWindowFocusRefetchRef.current) { + shouldWindowFocusRefetchRef.current = false + refetch() + } + }) + // Query for MCP connections const { data: mcpServices = [], @@ -68,86 +79,160 @@ export const MCPServicesSection = () => { queryFn: fetchMCPConnections, enabled: mcpEnabled, refetchInterval: 30_000, - refetchOnWindowFocus: true, retry: 2, }) - // Mutation for creating MCP connection - const createConnectionMutation = useMutation({ - mutationFn: createMCPConnection, - onSuccess: async (result) => { - queryClient.invalidateQueries({ queryKey: mcpQueryKeys.connections() }) + // Optimistic mutation for creating MCP connection + const createConnectionMutation = useOptimisticMutation( + createOptimisticConfig.custom[0]>({ + mutationFn: createMCPConnection, + queryKey: mcpQueryKeys.connections(), + optimisticUpdater: (variables, previousData) => { + const tempId = `temp-${Date.now()}-${Math.random().toString(36).slice(2, 11)}` + const optimisticService: OptimisticMCPService = { + id: tempId, + name: variables.name || "New Service", + transportType: variables.transportType, + url: variables.url, + headers: variables.headers, + isConnected: false, + enabled: true, + status: "pending" as const, + toolCount: 0, + resourceCount: 0, + promptCount: 0, + createdAt: new Date().toISOString(), + lastUsed: null, + isOptimistic: true, + } - // Handle OAuth authorization if needed - if (result.authorizationUrl) { - await handleOAuthAuthorization(result.authorizationUrl, result.connectionId) - } else { - toast.success(t("integration.mcp.service.added")) - refreshToolsMutation.mutate([result.connectionId]) + return { + newData: [optimisticService, ...previousData], + rollbackData: previousData, + tempId, + } + }, + successUpdater: (result: any, _variables, previousData, context: any) => { + // Handle the API response structure + return previousData.map((service) => { + if (service.id === context?.tempId) { + // Merge the response data with optimistic data + return { + ...service, + id: result.connectionId || result.id || service.id, + isConnected: true, + status: "connected" as const, + isOptimistic: false, + } + } + return service + }) + }, + onSuccess: async (result: any) => { + if (result.authorizationUrl) { + await handleOAuthAuthorization(result.authorizationUrl, result.connectionId) + } else { + toast.success(t("integration.mcp.service.added")) + refreshToolsMutation.mutate([result.connectionId]) + } + }, + errorConfig: { + showToast: true, + customMessage: t("integration.mcp.service.discovery_failed"), + retryable: false, + }, + }), + ) + + // Optimistic mutation for updating MCP connection + const updateConnectionMutation = useOptimisticMutation( + createOptimisticConfig.custom< + OptimisticMCPService, + { + connectionId: string + updateData: Parameters[1] } - }, - onError: (error) => { - toast.error(t("integration.mcp.service.discovery_failed")) - console.error("Failed to create MCP connection:", error) - }, - }) - - // Mutation for updating MCP connection - const updateConnectionMutation = useMutation({ - mutationFn: ({ - connectionId, - updateData, - }: { - connectionId: string - updateData: Parameters[1] - }) => updateMCPConnection(connectionId, updateData), - onSuccess: async (result) => { - queryClient.invalidateQueries({ queryKey: mcpQueryKeys.connections() }) - - // Handle OAuth authorization if needed - if (result.authorizationUrl) { - await handleOAuthAuthorization(result.authorizationUrl, result.connectionId) - } else { - toast.success(t("integration.mcp.service.updated")) - refreshToolsMutation.mutate([result.connectionId]) - } - }, - onError: (error) => { - toast.error("Failed to update MCP connection") - console.error("Failed to update MCP connection:", error) - }, - }) - - const toggleConnectionMutation = useMutation({ - mutationFn: ({ connectionId, enabled }: { connectionId: string; enabled: boolean }) => - updateMCPConnection(connectionId, { enabled }), - - onError: () => { - toast.error("Failed to update MCP connection") - }, - onMutate(variables) { - queryClient.setQueryData(mcpQueryKeys.connections(), (old: MCPService[]) => { - return old.map((service) => + >({ + mutationFn: (({ connectionId, updateData }) => + updateMCPConnection(connectionId, updateData)) as any, + queryKey: mcpQueryKeys.connections(), + optimisticUpdater: (variables, previousData) => { + const newData = previousData.map((service) => service.id === variables.connectionId - ? { ...service, enabled: variables.enabled } + ? { + ...service, + ...variables.updateData, + status: "updating" as const, + isOptimistic: true, + updatedAt: new Date().toISOString(), + } : service, ) - }) - }, - }) - // Mutation for deleting MCP connection - const deleteConnectionMutation = useMutation({ - mutationFn: deleteMCPConnection, - onSuccess: () => { - queryClient.invalidateQueries({ queryKey: mcpQueryKeys.connections() }) - toast.success(t("integration.mcp.service.deleted")) - }, - onError: (error) => { - toast.error("Failed to delete MCP connection") - console.error("Failed to delete MCP connection:", error) - }, - }) + return { + newData, + rollbackData: previousData, + targetId: variables.connectionId, + } + }, + successUpdater: (result: any, variables, previousData) => { + return previousData.map((service) => + service.id === variables.connectionId + ? { + ...service, + ...result, + id: variables.connectionId, // Keep the original ID + status: "connected" as const, + isOptimistic: false, + } + : service, + ) + }, + onSuccess: async (result: any) => { + if (result.authorizationUrl) { + await handleOAuthAuthorization(result.authorizationUrl, result.connectionId) + } else { + toast.success(t("integration.mcp.service.updated")) + refreshToolsMutation.mutate([result.connectionId]) + } + }, + errorConfig: { + showToast: true, + customMessage: "Failed to update MCP connection", + retryable: false, + }, + }), + ) + + // Optimistic mutation for toggling connection enabled status + const toggleConnectionMutation = useOptimisticMutation( + createOptimisticConfig.forToggle< + OptimisticMCPService, + { connectionId: string; enabled: boolean }, + any // API response type + >({ + mutationFn: ({ connectionId, enabled }) => updateMCPConnection(connectionId, { enabled }), + queryKey: mcpQueryKeys.connections(), + getId: (variables) => variables.connectionId, + getToggleData: (variables) => ({ enabled: variables.enabled }), + errorMessage: "Failed to toggle MCP connection", + retryable: true, + }), + ) + + // Optimistic mutation for deleting MCP connection + const deleteConnectionMutation = useOptimisticMutation( + createOptimisticConfig.forDelete({ + mutationFn: deleteMCPConnection, + queryKey: mcpQueryKeys.connections(), + getId: (connectionId) => connectionId, + onSuccess: () => { + toast.success(t("integration.mcp.service.deleted")) + }, + errorMessage: "Failed to delete MCP connection", + retryable: false, + }), + ) // Mutation for refreshing MCP tools const refreshToolsMutation = useMutation({ @@ -169,14 +254,47 @@ export const MCPServicesSection = () => { present({ title: "Add MCP Service", content: ({ dismiss }: { dismiss: () => void }) => ( - { - createConnectionMutation.mutate(service) + { + if (!preset.quickSetup) { + // Show form with preset values pre-filled + present({ + title: `Setup ${preset.displayName}`, + content: ({ dismiss: dismissForm }) => ( + { + createConnectionMutation.mutate(service) + dismissForm() + }} + onCancel={dismissForm} + /> + ), + }) + } else { + // Direct submission for services + createConnectionMutation.mutate(preset.configTemplate) + } + dismiss() + }} + onManualConfig={() => { + // Show manual configuration form + present({ + title: "Add MCP Service", + content: ({ dismiss: dismissForm }) => ( + { + createConnectionMutation.mutate(service) + dismissForm() + }} + onCancel={dismissForm} + /> + ), + }) dismiss() }} - onCancel={dismiss} - isLoading={createConnectionMutation.isPending} /> ), }) @@ -196,7 +314,6 @@ export const MCPServicesSection = () => { dismiss() }} onCancel={dismiss} - isLoading={updateConnectionMutation.isPending} /> ), }) diff --git a/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/types.ts b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/types.ts new file mode 100644 index 000000000..3b8969730 --- /dev/null +++ b/apps/desktop/layer/renderer/src/modules/settings/tabs/ai/mcp/types.ts @@ -0,0 +1,68 @@ +export interface MCPPreset { + id: string + name: string + displayName: string + icon: string // simple-icons class name + description: string + features: string[] + + quickSetup: boolean + authRequired: boolean + configTemplate: { + name: string + transportType: "streamable-http" | "sse" + url: string + } +} + +export const MCP_PRESETS: MCPPreset[] = [ + { + id: "notion", + name: "notion", + displayName: "Notion", + icon: "i-simple-icons-notion", + description: "Connect your Notion workspace", + features: ["Read & search pages", "Create new content", "Update existing pages"], + + quickSetup: true, + authRequired: true, + configTemplate: { + name: "Notion", + transportType: "streamable-http", + url: "https://mcp.notion.com/mcp", + }, + }, + { + id: "linear", + name: "linear", + displayName: "Linear", + icon: "i-simple-icons-linear", + description: "Connect your Linear workspace", + features: ["Read & search issues", "Create new issues", "Update existing issues"], + + quickSetup: true, + authRequired: true, + configTemplate: { + name: "Linear", + transportType: "streamable-http", + url: "https://mcp.linear.app/mcp", + }, + }, + + { + id: "github", + name: "github", + displayName: "GitHub", + icon: "i-simple-icons-github", + description: "Connect your GitHub repository", + features: ["Read & search issues", "Create new issues", "Update existing issues"], + + quickSetup: false, + authRequired: true, + configTemplate: { + name: "GitHub", + transportType: "streamable-http", + url: "https://api.githubcopilot.com/mcp", + }, + }, +] diff --git a/packages/internal/hooks/src/index.ts b/packages/internal/hooks/src/index.ts index be6b18ab1..4b6200bb9 100644 --- a/packages/internal/hooks/src/index.ts +++ b/packages/internal/hooks/src/index.ts @@ -1,4 +1,5 @@ export type { HTMLMediaState } from "./factory/createHTMLMediaHook" +export * from "./optimistic" export * from "./useAnyPointDown" export * from "./useControlled" export * from "./useCountDown" diff --git a/packages/internal/hooks/src/optimistic/config.ts b/packages/internal/hooks/src/optimistic/config.ts new file mode 100644 index 000000000..d891cd19e --- /dev/null +++ b/packages/internal/hooks/src/optimistic/config.ts @@ -0,0 +1,134 @@ +import type { MutationFunction, QueryKey } from "@tanstack/react-query" + +import { optimisticStrategies } from "./strategies" +import type { OptimisticItem, OptimisticKey, OptimisticMutationConfig } from "./types" + +/** + * Configuration builders for common optimistic update patterns + * These provide type-safe, pre-configured optimistic mutation setups + */ +export const createOptimisticConfig = { + /** + * Configuration for create operations + * Adds new items to the beginning of the list + */ + forCreate: (config: { + mutationFn: MutationFunction + queryKey: QueryKey + generateOptimistic: (variables: TVariables) => Omit + onSuccess?: (result: TResponse, variables: TVariables) => void | Promise + errorMessage?: string + retryable?: boolean + maxRetries?: number + }): OptimisticMutationConfig => ({ + mutationFn: config.mutationFn, + queryKey: config.queryKey, + onSuccess: config.onSuccess, + ...optimisticStrategies.create( + (variables: TVariables) => + ({ + ...config.generateOptimistic(variables), + createdAt: new Date().toISOString(), + }) as Omit, + ), + errorConfig: { + showToast: true, + customMessage: config.errorMessage || "Failed to create item", + retryable: config.retryable ?? false, + maxRetries: config.maxRetries ?? 0, + }, + }), + + /** + * Configuration for update operations + * Updates existing items in place + */ + forUpdate: < + TData extends OptimisticItem, + TVariables extends Record, + TResponse = any, + >(config: { + mutationFn: MutationFunction + queryKey: QueryKey + getId: (variables: TVariables) => string + onSuccess?: (result: TResponse, variables: TVariables) => void | Promise + errorMessage?: string + retryable?: boolean + maxRetries?: number + }): OptimisticMutationConfig => ({ + mutationFn: config.mutationFn, + queryKey: config.queryKey, + onSuccess: config.onSuccess, + ...optimisticStrategies.update(config.getId), + errorConfig: { + showToast: true, + customMessage: config.errorMessage || "Failed to update item", + retryable: config.retryable ?? false, + maxRetries: config.maxRetries ?? 0, + }, + }), + + /** + * Configuration for delete operations + * Removes items from the list + */ + forDelete: (config: { + mutationFn: MutationFunction + queryKey: QueryKey + getId: (variables: TVariables) => string + onSuccess?: (result: TResponse, variables: TVariables) => void | Promise + errorMessage?: string + retryable?: boolean + }): OptimisticMutationConfig => ({ + mutationFn: config.mutationFn, + queryKey: config.queryKey, + onSuccess: config.onSuccess, + ...optimisticStrategies.delete(config.getId), + errorConfig: { + showToast: true, + customMessage: config.errorMessage || "Failed to delete item", + retryable: config.retryable ?? false, + maxRetries: 0, // Usually don't retry deletes + }, + }), + + /** + * Configuration for toggle operations + * Updates specific properties while preserving others + */ + forToggle: (config: { + mutationFn: MutationFunction + queryKey: QueryKey + getId: (variables: TVariables) => string + getToggleData: (variables: TVariables) => Partial + onSuccess?: (result: TResponse, variables: TVariables) => void | Promise + errorMessage?: string + retryable?: boolean + }): OptimisticMutationConfig => ({ + mutationFn: config.mutationFn, + queryKey: config.queryKey, + onSuccess: config.onSuccess, + ...optimisticStrategies.toggle(config.getId, config.getToggleData), + errorConfig: { + showToast: true, + customMessage: config.errorMessage || "Failed to toggle item", + retryable: config.retryable ?? true, + maxRetries: 0, + }, + }), + + /** + * Configuration for custom operations + * Provides full control over optimistic update behavior + */ + custom: ( + config: OptimisticMutationConfig, + ): OptimisticMutationConfig => ({ + errorConfig: { + showToast: true, + retryable: false, + maxRetries: 0, + }, + ...config, + }), +} diff --git a/packages/internal/hooks/src/optimistic/index.ts b/packages/internal/hooks/src/optimistic/index.ts new file mode 100644 index 000000000..6b98c4189 --- /dev/null +++ b/packages/internal/hooks/src/optimistic/index.ts @@ -0,0 +1,10 @@ +export { createOptimisticConfig } from "./config" +export { optimisticStrategies } from "./strategies" +export type { + OptimisticContext, + OptimisticItem, + OptimisticMutationConfig, + StrategyConfig, + WithOptimistic, +} from "./types" +export { useOptimisticMutation } from "./useOptimisticMutation" diff --git a/packages/internal/hooks/src/optimistic/strategies.ts b/packages/internal/hooks/src/optimistic/strategies.ts new file mode 100644 index 000000000..fff8aa1cd --- /dev/null +++ b/packages/internal/hooks/src/optimistic/strategies.ts @@ -0,0 +1,136 @@ +import type { OptimisticItem, OptimisticKey, StrategyConfig } from "./types" +import { optimisticKey, optimisticStatusKey } from "./types" + +/** + * Predefined optimistic update strategies for common operations + */ +export const optimisticStrategies = { + /** + * Strategy for creating new items + * Adds the new item to the beginning of the list with a temporary ID + */ + create: ( + generateOptimisticItem: (variables: any) => Omit, + ): StrategyConfig => ({ + optimisticUpdater: (variables: any, previousData: T[]) => { + const tempId = `temp-${Date.now()}-${Math.random().toString(36).slice(2, 11)}` + const optimisticItem = { + ...generateOptimisticItem(variables), + id: tempId, + [optimisticKey]: true, + [optimisticStatusKey]: "pending", + updatedAt: new Date().toISOString(), + } as T + + return { + newData: [optimisticItem, ...previousData], + rollbackData: previousData, + tempId, + } + }, + + successUpdater: (result: TResponse, variables: any, previousData: T[], context: any) => { + return previousData.map((item) => + item.id === context?.tempId + ? { ...item, ...(result as any), [optimisticKey]: false } + : item, + ) + }, + }), + + /** + * Strategy for updating existing items + * Updates the item in place and marks it as optimistic + */ + update: ( + getTargetId: string | ((variables: any) => string), + ): StrategyConfig => ({ + optimisticUpdater: (variables: any, previousData: T[]) => { + const targetId = typeof getTargetId === "function" ? getTargetId(variables) : getTargetId + + const newData = previousData.map((item) => + item.id === targetId + ? { + ...item, + ...variables, + [optimisticKey]: true, + [optimisticStatusKey]: "updating", + updatedAt: new Date().toISOString(), + } + : item, + ) + + return { + newData, + rollbackData: previousData, + targetId, + } + }, + + successUpdater: (result: TResponse, variables: any, previousData: T[]) => { + const targetId = typeof getTargetId === "function" ? getTargetId(variables) : getTargetId + return previousData.map((item) => + item.id === targetId ? { ...item, ...(result as any), [optimisticKey]: false } : item, + ) + }, + }), + + /** + * Strategy for deleting items + * Removes the item from the list immediately + */ + delete: ( + getId: (variables: any) => string, + ): StrategyConfig => ({ + optimisticUpdater: (variables: any, previousData: T[]) => { + const targetId = getId(variables) + const newData = previousData.filter((item) => item.id !== targetId) + + return { + newData, + rollbackData: previousData, + targetId, + } + }, + }), + + /** + * Strategy for toggling item properties + * Updates specific properties while keeping the rest unchanged + */ + toggle: ( + getId: (variables: any) => string, + getToggleData: (variables: any) => Partial, + ): StrategyConfig => ({ + optimisticUpdater: (variables: any, previousData: T[]) => { + const targetId = getId(variables) + const toggleData = getToggleData(variables) + + const newData = previousData.map((item) => + item.id === targetId + ? { + ...item, + ...toggleData, + [optimisticKey]: true, + [optimisticStatusKey]: "updating", + + updatedAt: new Date().toISOString(), + } + : item, + ) + + return { + newData, + rollbackData: previousData, + targetId, + } + }, + + successUpdater: (result: TResponse, variables: any, previousData: T[]) => { + const targetId = getId(variables) + return previousData.map((item) => + item.id === targetId ? { ...item, ...(result as any), [optimisticKey]: false } : item, + ) + }, + }), +} diff --git a/packages/internal/hooks/src/optimistic/types.ts b/packages/internal/hooks/src/optimistic/types.ts new file mode 100644 index 000000000..f3039e0db --- /dev/null +++ b/packages/internal/hooks/src/optimistic/types.ts @@ -0,0 +1,76 @@ +import type { MutationFunction, QueryKey } from "@tanstack/react-query" + +export const optimisticKey = Symbol("optimistic") +export const optimisticStatusKey = Symbol("optimisticStatus") + +export type OptimisticKey = typeof optimisticKey +export type OptimisticStatusKey = typeof optimisticStatusKey +// Base interface for items that support optimistic updates +export interface OptimisticItem { + id: string + // Use prefixed properties to minimize conflicts + [optimisticKey]?: boolean + [optimisticStatusKey]?: "pending" | "updating" | "error" | "connected" + updatedAt?: string +} + +// Generic optimistic wrapper type +export type WithOptimistic = T & { + [optimisticKey]?: boolean + [optimisticStatusKey]?: "pending" | "updating" | "error" | "connected" +} + +// Core optimistic update configuration +export interface OptimisticMutationConfig< + TData extends OptimisticItem, + TVariables, + TResponse = any, + TContext = unknown, +> { + // Basic configuration - mutationFn can return any response type + mutationFn: MutationFunction + queryKey: QueryKey + + // Optimistic update strategy + optimisticUpdater: ( + variables: TVariables, + previousData: TData[], + ) => { + newData: TData[] + rollbackData: TData[] + tempId?: string + } + + // Success data mapping - handles any response type + successUpdater?: ( + result: TResponse, + variables: TVariables, + previousData: TData[], + context?: TContext, + ) => TData[] + + // Error handling configuration + errorConfig?: { + showToast?: boolean + customMessage?: string + retryable?: boolean + maxRetries?: number + } + + // Success callback - receives the actual API response + onSuccess?: (result: TResponse, variables: TVariables) => void | Promise +} + +// Optimistic update context returned from onMutate +export interface OptimisticContext { + rollbackData: any[] + tempId?: string + previousData: any[] + targetId?: string +} + +// Strategy configuration for different operation types +export interface StrategyConfig { + optimisticUpdater: OptimisticMutationConfig["optimisticUpdater"] + successUpdater?: OptimisticMutationConfig["successUpdater"] +} diff --git a/packages/internal/hooks/src/optimistic/useOptimisticMutation.ts b/packages/internal/hooks/src/optimistic/useOptimisticMutation.ts new file mode 100644 index 000000000..90c818bcc --- /dev/null +++ b/packages/internal/hooks/src/optimistic/useOptimisticMutation.ts @@ -0,0 +1,80 @@ +import { useMutation, useQueryClient } from "@tanstack/react-query" +import { toast } from "sonner" + +import type { OptimisticContext, OptimisticItem, OptimisticMutationConfig } from "./types" + +/** + * Generic optimistic update mutation hook + * Provides automatic optimistic updates with error rollback for any mutation + */ +export function useOptimisticMutation< + TData extends OptimisticItem, + TVariables, + TResponse = any, + TContext = OptimisticContext, +>(config: OptimisticMutationConfig) { + const queryClient = useQueryClient() + + return useMutation({ + mutationFn: config.mutationFn, + + onMutate: async (variables: TVariables) => { + // Cancel any outgoing queries to prevent race conditions + await queryClient.cancelQueries({ queryKey: config.queryKey }) + + // Get previous data for rollback + const previousData = queryClient.getQueryData(config.queryKey) || [] + + // Execute optimistic update + const { newData, rollbackData, tempId } = config.optimisticUpdater(variables, previousData) + + // Update query cache with optimistic data + queryClient.setQueryData(config.queryKey, newData) + + return { + rollbackData, + tempId, + previousData, + variables, + } as TContext + }, + + onSuccess: async (result, variables, context) => { + // Apply success updater if provided, otherwise invalidate queries + if (config.successUpdater) { + const currentData = queryClient.getQueryData(config.queryKey) || [] + const updatedData = config.successUpdater(result, variables, currentData, context) + queryClient.setQueryData(config.queryKey, updatedData) + } + + // Execute custom success callback + await config.onSuccess?.(result, variables) + }, + + onError: (error, _variables, context: TContext | undefined) => { + // Rollback to previous state + const rollbackData = (context as any)?.rollbackData + if (rollbackData) { + queryClient.setQueryData(config.queryKey, rollbackData) + } + + // Show error toast if configured + if (config.errorConfig?.showToast !== false) { + const message = config.errorConfig?.customMessage || "Operation failed" + toast.error(message) + } + + console.error("Optimistic mutation failed:", error) + }, + + onSettled: () => { + // Ensure eventual consistency by invalidating queries + queryClient.invalidateQueries({ queryKey: config.queryKey }) + }, + + // Configure retry behavior + retry: config.errorConfig?.retryable ? (config.errorConfig.maxRetries ?? 2) : false, + + retryDelay: (attemptIndex) => Math.min(1000 * Math.pow(2, attemptIndex), 5000), + }) +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 02c27100a..2f612cb49 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -7,8 +7,8 @@ settings: catalogs: default: '@follow-app/client-sdk': - specifier: 0.3.48 - version: 0.3.48 + specifier: 0.3.50 + version: 0.3.50 tailwindcss-uikit-colors: specifier: 1.0.0 version: 1.0.0 @@ -465,7 +465,7 @@ importers: version: 3.0.2(electron@37.2.0) '@follow-app/client-sdk': specifier: 'catalog:' - version: 0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + version: 0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) '@follow/database': specifier: workspace:* version: link:../../../../packages/internal/database @@ -1673,7 +1673,7 @@ importers: dependencies: '@follow-app/client-sdk': specifier: 'catalog:' - version: 0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + version: 0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) '@follow/configs': specifier: workspace:* version: link:../../configs @@ -1685,7 +1685,7 @@ importers: dependencies: '@follow-app/client-sdk': specifier: 'catalog:' - version: 0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + version: 0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) '@follow/constants': specifier: workspace:* version: link:../constants @@ -1757,7 +1757,7 @@ importers: dependencies: '@follow-app/client-sdk': specifier: 'catalog:' - version: 0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + version: 0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) '@follow/constants': specifier: workspace:* version: link:../constants @@ -1821,7 +1821,7 @@ importers: dependencies: '@follow-app/client-sdk': specifier: 'catalog:' - version: 0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + version: 0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) '@follow/configs': specifier: workspace:* version: link:../../configs @@ -4051,26 +4051,26 @@ packages: '@floating-ui/utils@0.2.10': resolution: {integrity: sha512-aGTxbpbg8/b5JfU1HXSrbH3wXZuLPJcNEcZQFMxLs3oSzgtVu6nFPkbbGGUvBcUjKV2YyB9Wxxabo+HEH9tcRQ==} - '@follow-app/client-sdk@0.3.48': - resolution: {integrity: sha512-nPRnKQwzTTvPaIMOfZierMi9+TUlxc2his1FrGmkXOUbyMe6VtnChMtxHWU03Kdb2mnCJrVmOzJa0CwW6NAvmQ==} + '@follow-app/client-sdk@0.3.50': + resolution: {integrity: sha512-qc8gI5li/v62h1oR8p0bkLh+tlNaEP8jogppoP92v10XktERtd0rrx5grvSQ1pw0mM3Fws4CknEJZeGH9leDaw==} '@folo-services/ai-tools@0.2.31': resolution: {integrity: sha512-oqTVMBc6UCLOt/3M9GX4I+DJ8WT2U8Hlok1MN/Sruw8sQu0ZvtoDvkuiJEtssOQAGDifzHm7z8AVmOgNoGrKUg==} - '@folo-services/constants@0.1.27': - resolution: {integrity: sha512-ZCTgPvLiNfKiOU3E7m0x6Y6w/8PIkEHVl7C5pH+Tt36DrM81vHZjy+zPnZISgjOd3DYTJFHTOCI2ReFRx8Ir3g==} - - '@folo-services/drizzle@0.1.21': - resolution: {integrity: sha512-yJAPJz05h2uio5wPOHYbzaeFhJNn5UU9S4HPLQa3L8DNE9IG9DMsNAJqFTEpXQPwEQOf2n3k8FCF8GP/SygA7w==} + '@folo-services/constants@0.1.29': + resolution: {integrity: sha512-7YH5UQyUoT0STsoAKXTJgdAlvW88RKe5L/yqq4nbovSf2UJm1yEfl+opOYMeYEKBzX3OnixIipPL/1oKQPeh0w==} '@folo-services/drizzle@0.1.22': resolution: {integrity: sha512-n4L0bBA5AxqJn5K3k+BTzmtuZh90LAO7G6zALCo3H+BOsnMsQ1OCsQH/xFg7m6ICQ80LJVbHdUN6b4ZKUoQJ/g==} + '@folo-services/drizzle@0.1.23': + resolution: {integrity: sha512-Y4oGzfcYtsh9jdaDZvMh0CMO2tD1c2VSt1gtaZbq9uF17sv45empMI72OdGfWEJBJse7h/P+YGydX7iK63aoIQ==} + '@folo-services/exceptions@0.1.16': resolution: {integrity: sha512-ThmLLe1Dv2CFsDIgcuY6kJhYJnjiQ7UEsewaqc25MkuImDabhzWnnad+3zRnJGLpveaMeEZ69uqUsTbKC+fR7g==} - '@folo-services/shared@0.0.16': - resolution: {integrity: sha512-WWD9NEnzeJlRJ+6/d515ICITSPHRJjvbdqRwdQZM7J+KVyijZybl04VEf6TTJd62VAIEyRnF0PzFPeYQVCV+gQ==} + '@folo-services/shared@0.0.18': + resolution: {integrity: sha512-1uyoStgw1nE6pJqyrw3KaRQwLHGmz7AcbeYPFV3U7JRCLNz+TZTpYSBzSJ3ElRzc0EWnGs5ZztSH9b1N1uhSQA==} '@fontsource/sn-pro@5.2.5': resolution: {integrity: sha512-rBdBv/0ygj6bkO7xDMMFpwobLdSrcQ2Jncb6DIwdeYGoAgeWkQRwVYhGDKasfLjEYCNYxrqr6wsXsM9+aU39RA==} @@ -18952,12 +18952,12 @@ snapshots: '@floating-ui/utils@0.2.10': {} - '@follow-app/client-sdk@0.3.48(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3)': + '@follow-app/client-sdk@0.3.50(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3)': dependencies: - '@folo-services/constants': 0.1.27 - '@folo-services/drizzle': 0.1.21(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2) + '@folo-services/constants': 0.1.29 + '@folo-services/drizzle': 0.1.23(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2) '@folo-services/exceptions': 0.1.16 - '@folo-services/shared': 0.0.16(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + '@folo-services/shared': 0.0.18(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) zod: 3.25.76 transitivePeerDependencies: - '@aws-sdk/client-rds-data' @@ -19030,49 +19030,10 @@ snapshots: - sql.js - sqlite3 - '@folo-services/constants@0.1.27': + '@folo-services/constants@0.1.29': dependencies: zod: 3.25.76 - '@folo-services/drizzle@0.1.21(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)': - dependencies: - '@folo-services/exceptions': 0.1.16 - drizzle-orm: 0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) - drizzle-zod: 0.7.1(drizzle-orm@0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3))(zod@3.25.76) - nanoid: 5.1.5 - pg: 8.16.3 - zod: 3.25.76 - transitivePeerDependencies: - - '@aws-sdk/client-rds-data' - - '@cloudflare/workers-types' - - '@electric-sql/pglite' - - '@libsql/client' - - '@libsql/client-wasm' - - '@neondatabase/serverless' - - '@op-engineering/op-sqlite' - - '@opentelemetry/api' - - '@planetscale/database' - - '@prisma/client' - - '@tidbcloud/serverless' - - '@types/better-sqlite3' - - '@types/pg' - - '@types/sql.js' - - '@upstash/redis' - - '@vercel/postgres' - - '@xata.io/client' - - better-sqlite3 - - bun-types - - expo-sqlite - - gel - - knex - - kysely - - mysql2 - - pg-native - - postgres - - prisma - - sql.js - - sqlite3 - '@folo-services/drizzle@0.1.22(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)': dependencies: '@folo-services/exceptions': 0.1.16 @@ -19112,11 +19073,50 @@ snapshots: - sql.js - sqlite3 + '@folo-services/drizzle@0.1.23(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)': + dependencies: + '@folo-services/exceptions': 0.1.16 + drizzle-orm: 0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) + drizzle-zod: 0.7.1(drizzle-orm@0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3))(zod@3.25.76) + nanoid: 5.1.5 + pg: 8.16.3 + zod: 3.25.76 + transitivePeerDependencies: + - '@aws-sdk/client-rds-data' + - '@cloudflare/workers-types' + - '@electric-sql/pglite' + - '@libsql/client' + - '@libsql/client-wasm' + - '@neondatabase/serverless' + - '@op-engineering/op-sqlite' + - '@opentelemetry/api' + - '@planetscale/database' + - '@prisma/client' + - '@tidbcloud/serverless' + - '@types/better-sqlite3' + - '@types/pg' + - '@types/sql.js' + - '@upstash/redis' + - '@vercel/postgres' + - '@xata.io/client' + - better-sqlite3 + - bun-types + - expo-sqlite + - gel + - knex + - kysely + - mysql2 + - pg-native + - postgres + - prisma + - sql.js + - sqlite3 + '@folo-services/exceptions@0.1.16': {} - '@folo-services/shared@0.0.16(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3)': + '@folo-services/shared@0.0.18(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3)': dependencies: - '@folo-services/drizzle': 0.1.21(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2) + '@folo-services/drizzle': 0.1.23(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2) drizzle-orm: 0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3) drizzle-zod: 0.7.1(drizzle-orm@0.44.3(@opentelemetry/api@1.9.0)(@types/pg@8.6.1)(expo-sqlite@15.2.12(expo@53.0.12(@babel/core@7.28.0)(@expo/metro-runtime@5.0.4(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0)))(bufferutil@4.0.9)(graphql@16.8.1)(react-native-webview@13.15.0(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(react-native@0.79.1(@babel/core@7.28.0)(@types/react@19.1.8)(bufferutil@4.0.9)(react@19.0.0))(react@19.0.0))(kysely@0.28.2)(pg@8.16.3))(zod@3.25.76) zod: 3.25.76 diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index 40e46c8a4..0e92b0898 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -9,7 +9,7 @@ packages: catalog: typescript: 5.8.3 - "@follow-app/client-sdk": 0.3.48 + "@follow-app/client-sdk": 0.3.50 tailwindcss-uikit-colors: 1.0.0 onlyBuiltDependencies: