diff --git a/frontend/src/core/components/viewer/SignatureAPIBridge.tsx b/frontend/src/core/components/viewer/SignatureAPIBridge.tsx index b37542233..52c86e41f 100644 --- a/frontend/src/core/components/viewer/SignatureAPIBridge.tsx +++ b/frontend/src/core/components/viewer/SignatureAPIBridge.tsx @@ -236,6 +236,6 @@ export const SignatureAPIBridge = forwardRef(function SignatureAPI return null; // This is a bridge component with no UI }); -export type { SignatureAPI } from './viewerTypes'; +export type { SignatureAPI } from '@app/components/viewer/viewerTypes'; SignatureAPIBridge.displayName = 'SignatureAPIBridge'; diff --git a/frontend/src/core/hooks/tools/automate/useAutomateToolRegistry.ts b/frontend/src/core/hooks/tools/automate/useAutomateToolRegistry.ts index 8bc995114..6df1da00f 100644 --- a/frontend/src/core/hooks/tools/automate/useAutomateToolRegistry.ts +++ b/frontend/src/core/hooks/tools/automate/useAutomateToolRegistry.ts @@ -1,7 +1,7 @@ import { useMemo } from 'react'; -import { useToolRegistry } from '../../../contexts/ToolRegistryContext'; -import { AutomateToolRegistry, AutomateToolId, AUTOMATABLE_TOOL_IDS } from '../../../types/automation'; +import { useToolRegistry } from '@app/contexts/ToolRegistryContext'; +import { AutomateToolRegistry, AutomateToolId, AUTOMATABLE_TOOL_IDS } from '@app/types/automation'; export const useAutomateToolRegistry = (): AutomateToolRegistry => { const { regularTools } = useToolRegistry(); diff --git a/frontend/src/core/services/automationStorage.ts b/frontend/src/core/services/automationStorage.ts index 7a48f9cb9..d3e36f0fe 100644 --- a/frontend/src/core/services/automationStorage.ts +++ b/frontend/src/core/services/automationStorage.ts @@ -2,7 +2,7 @@ * Service for managing automation configurations in IndexedDB */ -import type { AutomationConfig as DomainAutomationConfig } from '../types/automation'; +import type { AutomationConfig as DomainAutomationConfig } from '@app/types/automation'; export type AutomationConfig = DomainAutomationConfig; @@ -29,7 +29,7 @@ class AutomationStorage { request.onupgradeneeded = (event) => { const db = (event.target as IDBOpenDBRequest).result; - + if (!db.objectStoreNames.contains(this.storeName)) { const store = db.createObjectStore(this.storeName, { keyPath: 'id' }); store.createIndex('name', 'name', { unique: false }); @@ -43,18 +43,18 @@ class AutomationStorage { if (!this.db) { await this.init(); } - + if (!this.db) { throw new Error('Database not initialized'); } - + return this.db; } async saveAutomation(automation: AutomationPayload): Promise { const db = await this.ensureDB(); const timestamp = new Date().toISOString(); - + const automationWithMeta: AutomationConfig = { id: `automation-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`, ...automation, @@ -79,7 +79,7 @@ class AutomationStorage { async updateAutomation(automation: AutomationConfig): Promise { const db = await this.ensureDB(); - + const updatedAutomation: AutomationConfig = { ...automation, updatedAt: new Date().toISOString() @@ -159,13 +159,13 @@ class AutomationStorage { async searchAutomations(query: string): Promise { const automations = await this.getAllAutomations(); - + if (!query.trim()) { return automations; } const lowerQuery = query.toLowerCase(); - return automations.filter(automation => + return automations.filter(automation => automation.name.toLowerCase().includes(lowerQuery) || (automation.description && automation.description.toLowerCase().includes(lowerQuery)) || automation.operations.some(op => op.operation.toLowerCase().includes(lowerQuery))