@semiont/react-ui 0.2.30-build.50 → 0.2.30-build.52

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.
@@ -101,17 +101,13 @@ var globImport_translations_json = __glob({
101
101
  var TranslationContext = createContext4(null);
102
102
  var translationCache = /* @__PURE__ */ new Map();
103
103
  function processPluralFormat(text, params) {
104
- console.log("[processPluralFormat] Called with text:", text, "params:", params);
105
104
  const pluralMatch = text.match(/\{(\w+),\s*plural,\s*/);
106
105
  if (!pluralMatch) {
107
- console.log("[processPluralFormat] No plural match found");
108
106
  return text;
109
107
  }
110
108
  const paramName = pluralMatch[1];
111
109
  const count = params[paramName];
112
- console.log("[processPluralFormat] paramName:", paramName, "count:", count);
113
110
  if (count === void 0) {
114
- console.log("[processPluralFormat] Count undefined, returning original");
115
111
  return text;
116
112
  }
117
113
  let startPos = pluralMatch[0].length;
@@ -235,14 +231,11 @@ var defaultTranslationManager = {
235
231
  return `${namespace}.${key}`;
236
232
  }
237
233
  if (params && typeof translation === "string") {
238
- console.log("[Translation] Processing:", namespace, key, "with params:", params, "translation:", translation);
239
234
  let result = translation;
240
235
  result = processPluralFormat(result, params);
241
- console.log("[Translation] After processPluralFormat:", result);
242
236
  Object.entries(params).forEach(([paramKey, paramValue]) => {
243
237
  result = result.replace(new RegExp(`\\{${paramKey}\\}`, "g"), String(paramValue));
244
238
  });
245
- console.log("[Translation] Final result:", result);
246
239
  return result;
247
240
  }
248
241
  return translation;
@@ -433,4 +426,4 @@ export {
433
426
  ToastProvider,
434
427
  useToast
435
428
  };
436
- //# sourceMappingURL=chunk-LU3HSAZJ.mjs.map
429
+ //# sourceMappingURL=chunk-S3WK5JL3.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/contexts/ApiClientContext.tsx","../src/contexts/SessionContext.tsx","../src/contexts/OpenResourcesContext.tsx","../src/contexts/TranslationContext.tsx","../src/components/Toast.tsx"],"sourcesContent":["'use client';\n\nimport React, { createContext, useContext, ReactNode } from 'react';\nimport type { ApiClientManager } from '../types/ApiClientManager';\n\nconst ApiClientContext = createContext<ApiClientManager | null>(null);\n\nexport interface ApiClientProviderProps {\n apiClientManager: ApiClientManager;\n children: ReactNode;\n}\n\n/**\n * Provider for API client management\n * Apps must provide an ApiClientManager implementation\n */\nexport function ApiClientProvider({\n apiClientManager,\n children,\n}: ApiClientProviderProps) {\n return (\n <ApiClientContext.Provider value={apiClientManager}>\n {children}\n </ApiClientContext.Provider>\n );\n}\n\n/**\n * Hook to access the API client\n * Must be used within an ApiClientProvider\n * @returns API client instance (null if not authenticated)\n */\nexport function useApiClient() {\n const context = useContext(ApiClientContext);\n\n if (!context) {\n throw new Error('useApiClient must be used within an ApiClientProvider');\n }\n\n return context.client;\n}\n","'use client';\n\nimport { createContext, useContext, ReactNode } from 'react';\nimport type { SessionManager } from '../types/SessionManager';\n\nconst SessionContext = createContext<SessionManager | null>(null);\n\n/**\n * Provider Pattern: Accepts SessionManager implementation as prop\n * and makes it available to child components via Context.\n *\n * Apps provide their own implementation (next-auth, custom auth, etc.)\n * and pass it to this provider at the root level.\n *\n * @example\n * ```tsx\n * // In app root\n * const sessionManager = useSessionManager(); // App's implementation\n *\n * <SessionProvider sessionManager={sessionManager}>\n * <App />\n * </SessionProvider>\n * ```\n */\nexport function SessionProvider({\n sessionManager,\n children\n}: {\n sessionManager: SessionManager;\n children: ReactNode;\n}) {\n return (\n <SessionContext.Provider value={sessionManager}>\n {children}\n </SessionContext.Provider>\n );\n}\n\n/**\n * Hook to access SessionManager from Context\n * Components use this hook to access session state and expiry information\n */\nexport function useSessionContext() {\n const context = useContext(SessionContext);\n if (!context) {\n throw new Error('useSessionContext must be used within SessionProvider');\n }\n return context;\n}","'use client';\n\nimport React, { createContext, useContext } from 'react';\nimport type { OpenResourcesManager } from '../types/OpenResourcesManager';\n\nconst OpenResourcesContext = createContext<OpenResourcesManager | undefined>(undefined);\n\n/**\n * Provider Pattern: Accepts OpenResourcesManager implementation as prop\n * and makes it available to child components via Context.\n *\n * Apps provide their own implementation (localStorage, sessionStorage, database, etc.)\n * and pass it to this provider at the root level.\n *\n * @example\n * ```tsx\n * // In app root\n * const openResourcesManager = useOpenResourcesManager(); // App's implementation\n *\n * <OpenResourcesProvider openResourcesManager={openResourcesManager}>\n * <App />\n * </OpenResourcesProvider>\n * ```\n */\nexport function OpenResourcesProvider({\n openResourcesManager,\n children\n}: {\n openResourcesManager: OpenResourcesManager;\n children: React.ReactNode;\n}) {\n return (\n <OpenResourcesContext.Provider value={openResourcesManager}>\n {children}\n </OpenResourcesContext.Provider>\n );\n}\n\n/**\n * Hook to access OpenResourcesManager from Context\n * Components use this hook to access open resources functionality\n */\nexport function useOpenResources(): OpenResourcesManager {\n const context = useContext(OpenResourcesContext);\n if (context === undefined) {\n throw new Error('useOpenResources must be used within an OpenResourcesProvider');\n }\n return context;\n}","'use client';\n\nimport React, { createContext, useContext, ReactNode, useState, useEffect, useMemo } from 'react';\nimport type { TranslationManager } from '../types/TranslationManager';\n\n// Static import for default English only - always needed as fallback\nimport enTranslations from '../../translations/en.json';\n\nconst TranslationContext = createContext<TranslationManager | null>(null);\n\n// Cache for dynamically loaded translations\nconst translationCache = new Map<string, any>();\n\n/**\n * Process ICU MessageFormat plural syntax\n * Supports: {count, plural, =0 {text} =1 {text} other {text}}\n */\nfunction processPluralFormat(text: string, params: Record<string, any>): string {\n // Match {paramName, plural, ...} with proper brace counting\n const pluralMatch = text.match(/\\{(\\w+),\\s*plural,\\s*/);\n if (!pluralMatch) {\n return text;\n }\n\n const paramName = pluralMatch[1];\n const count = params[paramName];\n if (count === undefined) {\n return text;\n }\n\n // Find the matching closing brace by counting\n let startPos = pluralMatch[0].length;\n let braceCount = 1; // We're inside the first {\n let endPos = startPos;\n\n for (let i = startPos; i < text.length; i++) {\n if (text[i] === '{') braceCount++;\n else if (text[i] === '}') {\n braceCount--;\n if (braceCount === 0) {\n endPos = i;\n break;\n }\n }\n }\n\n const pluralCases = text.substring(startPos, endPos);\n\n // Parse plural cases: =0 {text} =1 {text} other {text}\n const cases: Record<string, string> = {};\n const caseRegex = /(?:=(\\d+)|(\\w+))\\s*\\{([^}]+)\\}/g;\n let caseMatch;\n\n while ((caseMatch = caseRegex.exec(pluralCases)) !== null) {\n const [, exactNumber, keyword, textContent] = caseMatch;\n const key = exactNumber !== undefined ? `=${exactNumber}` : keyword;\n cases[key] = textContent;\n }\n\n // Select appropriate case\n const exactMatch = cases[`=${count}`];\n if (exactMatch !== undefined) {\n const result = exactMatch.replace(/#/g, String(count));\n return text.substring(0, pluralMatch.index!) + result + text.substring(endPos + 1);\n }\n\n const otherCase = cases['other'];\n if (otherCase !== undefined) {\n const result = otherCase.replace(/#/g, String(count));\n return text.substring(0, pluralMatch.index!) + result + text.substring(endPos + 1);\n }\n\n return text;\n}\n\n// List of available locales (can be extended without importing all files)\nexport const AVAILABLE_LOCALES = [\n 'ar', // Arabic\n 'bn', // Bengali\n 'cs', // Czech\n 'da', // Danish\n 'de', // German\n 'el', // Greek\n 'en', // English\n 'es', // Spanish\n 'fa', // Persian/Farsi\n 'fi', // Finnish\n 'fr', // French\n 'he', // Hebrew\n 'hi', // Hindi\n 'id', // Indonesian\n 'it', // Italian\n 'ja', // Japanese\n 'ko', // Korean\n 'ms', // Malay\n 'nl', // Dutch\n 'no', // Norwegian\n 'pl', // Polish\n 'pt', // Portuguese\n 'ro', // Romanian\n 'sv', // Swedish\n 'th', // Thai\n 'tr', // Turkish\n 'uk', // Ukrainian\n 'vi', // Vietnamese\n 'zh', // Chinese\n] as const;\nexport type AvailableLocale = typeof AVAILABLE_LOCALES[number];\n\n// Lazy load translations for a specific locale\nasync function loadTranslations(locale: string): Promise<any> {\n // Check cache first\n if (translationCache.has(locale)) {\n return translationCache.get(locale);\n }\n\n // English is already loaded statically\n if (locale === 'en') {\n translationCache.set('en', enTranslations);\n return enTranslations;\n }\n\n try {\n // Dynamic import for all other locales\n const translations = await import(`../../translations/${locale}.json`);\n const translationData = translations.default || translations;\n translationCache.set(locale, translationData);\n return translationData;\n } catch (error) {\n console.error(`Failed to load translations for locale: ${locale}`, error);\n // Fall back to English\n return enTranslations;\n }\n}\n\n// Default English translation manager (using static import)\nconst defaultTranslationManager: TranslationManager = {\n t: (namespace: string, key: string, params?: Record<string, any>) => {\n const translations = enTranslations as Record<string, Record<string, string>>;\n const translation = translations[namespace]?.[key];\n\n if (!translation) {\n console.warn(`Translation not found for ${namespace}.${key}`);\n return `${namespace}.${key}`;\n }\n\n // Handle parameter interpolation and plural format\n if (params && typeof translation === 'string') {\n let result = translation;\n // First process plural format\n result = processPluralFormat(result, params);\n // Then handle simple parameter interpolation\n Object.entries(params).forEach(([paramKey, paramValue]) => {\n result = result.replace(new RegExp(`\\\\{${paramKey}\\\\}`, 'g'), String(paramValue));\n });\n return result;\n }\n\n return translation;\n },\n};\n\nexport interface TranslationProviderProps {\n /**\n * Option 1: Provide a complete TranslationManager implementation\n */\n translationManager?: TranslationManager;\n\n /**\n * Option 2: Use built-in translations by specifying a locale\n * When adding new locales, just add the JSON file and update AVAILABLE_LOCALES\n */\n locale?: string;\n\n /**\n * Loading component to show while translations are being loaded\n * Only relevant when using dynamic locale loading\n */\n loadingComponent?: ReactNode;\n\n children: ReactNode;\n}\n\n/**\n * Provider for translation management with dynamic loading\n *\n * Three modes of operation:\n * 1. No provider: Components use default English strings\n * 2. With locale prop: Dynamically loads translations for that locale\n * 3. With translationManager: Use custom translation implementation\n */\nexport function TranslationProvider({\n translationManager,\n locale,\n loadingComponent = null,\n children,\n}: TranslationProviderProps) {\n const [loadedTranslations, setLoadedTranslations] = useState<any>(null);\n const [isLoading, setIsLoading] = useState(false);\n\n // Load translations when locale changes\n useEffect(() => {\n if (locale && !translationManager) {\n setIsLoading(true);\n loadTranslations(locale)\n .then(translations => {\n setLoadedTranslations(translations);\n setIsLoading(false);\n })\n .catch(error => {\n console.error('Failed to load translations:', error);\n setLoadedTranslations(enTranslations); // Fall back to English\n setIsLoading(false);\n });\n }\n }, [locale, translationManager]);\n\n // Create translation manager from loaded translations\n const localeManager = useMemo<TranslationManager | null>(() => {\n if (!loadedTranslations) return null;\n\n return {\n t: (namespace: string, key: string, params?: Record<string, any>) => {\n const translation = loadedTranslations[namespace]?.[key];\n\n if (!translation) {\n console.warn(`Translation not found for ${namespace}.${key} in locale ${locale}`);\n return `${namespace}.${key}`;\n }\n\n // Handle parameter interpolation and plural format\n if (params && typeof translation === 'string') {\n let result = translation;\n // First process plural format\n result = processPluralFormat(result, params);\n // Then handle simple parameter interpolation\n Object.entries(params).forEach(([paramKey, paramValue]) => {\n result = result.replace(new RegExp(`\\\\{${paramKey}\\\\}`, 'g'), String(paramValue));\n });\n return result;\n }\n\n return translation;\n },\n };\n }, [loadedTranslations, locale]);\n\n // If custom translation manager provided, use it\n if (translationManager) {\n return (\n <TranslationContext.Provider value={translationManager}>\n {children}\n </TranslationContext.Provider>\n );\n }\n\n // If locale provided and still loading, show loading component\n if (locale && isLoading) {\n return <>{loadingComponent}</>;\n }\n\n // If locale provided and translations loaded, use them\n if (locale && localeManager) {\n return (\n <TranslationContext.Provider value={localeManager}>\n {children}\n </TranslationContext.Provider>\n );\n }\n\n // Default: use English translations\n return (\n <TranslationContext.Provider value={defaultTranslationManager}>\n {children}\n </TranslationContext.Provider>\n );\n}\n\n/**\n * Hook to access translations within a namespace\n *\n * Works in three modes:\n * 1. Without provider: Returns default English translations\n * 2. With provider using locale: Returns dynamically loaded translations for that locale\n * 3. With custom provider: Uses the custom translation manager\n *\n * @param namespace - Translation namespace (e.g., 'Toolbar', 'ResourceViewer')\n * @returns Function to translate keys within the namespace\n */\nexport function useTranslations(namespace: string) {\n const context = useContext(TranslationContext);\n\n // If no context (no provider), use default English translations\n if (!context) {\n return (key: string, params?: Record<string, any>) => {\n const translations = enTranslations as Record<string, Record<string, string>>;\n const translation = translations[namespace]?.[key];\n\n if (!translation) {\n console.warn(`Translation not found for ${namespace}.${key}`);\n return `${namespace}.${key}`;\n }\n\n // Handle parameter interpolation and plural format\n if (params && typeof translation === 'string') {\n let result = translation;\n // First process plural format\n result = processPluralFormat(result, params);\n // Then handle simple parameter interpolation\n Object.entries(params).forEach(([paramKey, paramValue]) => {\n result = result.replace(new RegExp(`\\\\{${paramKey}\\\\}`, 'g'), String(paramValue));\n });\n return result;\n }\n\n return translation;\n };\n }\n\n // Return a function that translates keys within this namespace\n return (key: string, params?: Record<string, any>) => context.t(namespace, key, params);\n}\n\n/**\n * Hook to preload translations for a locale\n * Useful for preloading translations before navigation\n */\nexport function usePreloadTranslations() {\n return {\n preload: async (locale: string) => {\n try {\n await loadTranslations(locale);\n return true;\n } catch (error) {\n console.error(`Failed to preload translations for ${locale}:`, error);\n return false;\n }\n },\n isLoaded: (locale: string) => translationCache.has(locale),\n };\n}","'use client';\n\nimport React, { useEffect, useState } from 'react';\nimport { createPortal } from 'react-dom';\n\nexport type ToastType = 'success' | 'error' | 'info' | 'warning';\n\nexport interface ToastMessage {\n id: string;\n message: string;\n type: ToastType;\n duration?: number;\n}\n\ninterface ToastProps {\n toast: ToastMessage;\n onClose: (id: string) => void;\n}\n\nconst icons = {\n success: (\n <svg className=\"semiont-toast-icon\" fill=\"none\" stroke=\"currentColor\" viewBox=\"0 0 24 24\">\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M5 13l4 4L19 7\" />\n </svg>\n ),\n error: (\n <svg className=\"semiont-toast-icon\" fill=\"none\" stroke=\"currentColor\" viewBox=\"0 0 24 24\">\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M6 18L18 6M6 6l12 12\" />\n </svg>\n ),\n warning: (\n <svg className=\"semiont-toast-icon\" fill=\"none\" stroke=\"currentColor\" viewBox=\"0 0 24 24\">\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z\" />\n </svg>\n ),\n info: (\n <svg className=\"semiont-toast-icon\" fill=\"none\" stroke=\"currentColor\" viewBox=\"0 0 24 24\">\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n ),\n};\n\nfunction Toast({ toast, onClose }: ToastProps) {\n useEffect(() => {\n const timer = setTimeout(() => {\n onClose(toast.id);\n }, toast.duration || 3000);\n\n return () => clearTimeout(timer);\n }, [toast, onClose]);\n\n return (\n <div\n className=\"semiont-toast\"\n data-variant={toast.type}\n role=\"alert\"\n >\n <div className=\"semiont-toast-icon-wrapper\">{icons[toast.type]}</div>\n <p className=\"semiont-toast-message\">{toast.message}</p>\n <button\n onClick={() => onClose(toast.id)}\n className=\"semiont-toast-close\"\n aria-label=\"Close\"\n >\n <svg className=\"semiont-toast-close-icon\" fill=\"none\" stroke=\"currentColor\" viewBox=\"0 0 24 24\">\n <path strokeLinecap=\"round\" strokeLinejoin=\"round\" strokeWidth={2} d=\"M6 18L18 6M6 6l12 12\" />\n </svg>\n </button>\n </div>\n );\n}\n\ninterface ToastContainerProps {\n toasts: ToastMessage[];\n onClose: (id: string) => void;\n}\n\nexport function ToastContainer({ toasts, onClose }: ToastContainerProps) {\n const [mounted, setMounted] = useState(false);\n\n useEffect(() => {\n setMounted(true);\n return () => setMounted(false);\n }, []);\n\n if (!mounted) return null;\n\n return createPortal(\n <div className=\"semiont-toast-container\">\n {toasts.map((toast) => (\n <Toast key={toast.id} toast={toast} onClose={onClose} />\n ))}\n </div>,\n document.body\n );\n}\n\n// Toast context and hook for global toast management\ninterface ToastContextType {\n showToast: (message: string, type?: ToastType, duration?: number) => void;\n showSuccess: (message: string, duration?: number) => void;\n showError: (message: string, duration?: number) => void;\n showWarning: (message: string, duration?: number) => void;\n showInfo: (message: string, duration?: number) => void;\n}\n\nconst ToastContext = React.createContext<ToastContextType | undefined>(undefined);\n\nexport function ToastProvider({ children }: { children: React.ReactNode }) {\n const [toasts, setToasts] = useState<ToastMessage[]>([]);\n\n const showToast = (message: string, type: ToastType = 'info', duration?: number) => {\n const id = Date.now().toString();\n const newToast: ToastMessage = duration !== undefined \n ? { id, message, type, duration }\n : { id, message, type };\n setToasts((prev) => [...prev, newToast]);\n };\n\n const showSuccess = (message: string, duration?: number) => showToast(message, 'success', duration);\n const showError = (message: string, duration?: number) => showToast(message, 'error', duration);\n const showWarning = (message: string, duration?: number) => showToast(message, 'warning', duration);\n const showInfo = (message: string, duration?: number) => showToast(message, 'info', duration);\n\n const handleClose = (id: string) => {\n setToasts((prev) => prev.filter((toast) => toast.id !== id));\n };\n\n return (\n <ToastContext.Provider value={{ showToast, showSuccess, showError, showWarning, showInfo }}>\n {children}\n <ToastContainer toasts={toasts} onClose={handleClose} />\n </ToastContext.Provider>\n );\n}\n\nexport function useToast() {\n const context = React.useContext(ToastContext);\n if (context === undefined) {\n throw new Error('useToast must be used within a ToastProvider');\n }\n return context;\n}"],"mappings":";;;;;;;;;AAEA,SAAgB,eAAe,kBAA6B;AAmBxD;AAhBJ,IAAM,mBAAmB,cAAuC,IAAI;AAW7D,SAAS,kBAAkB;AAAA,EAChC;AAAA,EACA;AACF,GAA2B;AACzB,SACE,oBAAC,iBAAiB,UAAjB,EAA0B,OAAO,kBAC/B,UACH;AAEJ;AAOO,SAAS,eAAe;AAC7B,QAAM,UAAU,WAAW,gBAAgB;AAE3C,MAAI,CAAC,SAAS;AACZ,UAAM,IAAI,MAAM,uDAAuD;AAAA,EACzE;AAEA,SAAO,QAAQ;AACjB;;;ACtCA,SAAS,iBAAAA,gBAAe,cAAAC,mBAA6B;AA8BjD,gBAAAC,YAAA;AA3BJ,IAAM,iBAAiBF,eAAqC,IAAI;AAmBzD,SAAS,gBAAgB;AAAA,EAC9B;AAAA,EACA;AACF,GAGG;AACD,SACE,gBAAAE,KAAC,eAAe,UAAf,EA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AAClG,QAAM,WAAW,CAAC,SAAiB,aAAsB,UAAU,SAAS,QAAQ,QAAQ;AAE5F,QAAM,cAAc,CAAC,OAAe;AAClC,cAAU,CAAC,SAAS,KAAK,OAAO,CAAC,UAAU,MAAM,OAAO,EAAE,CAAC;AAAA,EAC7D;AAEA,SACE,qBAAC,aAAa,UAAb,EAAsB,OAAO,EAAE,WAAW,aAAa,WAAW,aAAa,SAAS,GACtF;AAAA;AAAA,IACD,gBAAAC,KAAC,kBAAe,QAAgB,SAAS,aAAa;AAAA,KACxD;AAEJ;AAEO,SAAS,WAAW;AACzB,QAAM,UAAUH,OAAM,WAAW,YAAY;AAC7C,MAAI,YAAY,QAAW;AACzB,UAAM,IAAI,MAAM,8CAA8C;AAAA,EAChE;AACA,SAAO;AACT;","names":["createContext","useContext","jsx","createContext","useContext","jsx","createContext","useContext","jsx","createContext","jsx","useContext","React","useEffect","useState","jsx"]}
package/dist/index.d.mts CHANGED
@@ -261,21 +261,6 @@ interface NavigationProps {
261
261
  /** Optional section title */
262
262
  title?: string;
263
263
  }
264
- /**
265
- * Props for the SidebarNavigation component
266
- */
267
- interface SidebarNavigationProps extends NavigationProps {
268
- /** Whether to show descriptions as tooltips */
269
- showDescriptions?: boolean;
270
- /** Custom active item class */
271
- activeClassName?: string;
272
- /** Custom inactive item class */
273
- inactiveClassName?: string;
274
- /** Whether the navigation is in collapsed state (icons only) */
275
- isCollapsed?: boolean;
276
- /** Whether to show text labels (when not collapsed) */
277
- showText?: boolean;
278
- }
279
264
 
280
265
  /**
281
266
  * Type definitions for resource viewer feature
@@ -283,7 +268,7 @@ interface SidebarNavigationProps extends NavigationProps {
283
268
 
284
269
  type SemiontResource$3 = components['schemas']['ResourceDescriptor'];
285
270
  type Annotation$n = components['schemas']['Annotation'];
286
- type Motivation$3 = components['schemas']['Motivation'];
271
+ type Motivation$4 = components['schemas']['Motivation'];
287
272
  /**
288
273
  * Selection for creating annotations
289
274
  */
@@ -311,7 +296,7 @@ interface TextSelection {
311
296
  */
312
297
 
313
298
  type Annotation$m = components['schemas']['Annotation'];
314
- type Motivation$2 = components['schemas']['Motivation'];
299
+ type Motivation$3 = components['schemas']['Motivation'];
315
300
  /**
316
301
  * Detection configuration for SSE-based annotation detection
317
302
  */
@@ -332,7 +317,7 @@ interface DetectionConfig {
332
317
  * Metadata is static (defined in registry), handlers are injected at runtime (from page.tsx)
333
318
  */
334
319
  interface Annotator {
335
- motivation: Motivation$2;
320
+ motivation: Motivation$3;
336
321
  internalType: string;
337
322
  displayName: string;
338
323
  description: string;
@@ -393,7 +378,7 @@ declare function withHandlers(handlers: Record<string, Annotator['handlers']>):
393
378
  declare function createDetectionHandler(annotator: Annotator, context: {
394
379
  client: any;
395
380
  rUri: any;
396
- setDetectingMotivation: (motivation: Motivation$2 | null) => void;
381
+ setDetectingMotivation: (motivation: Motivation$3 | null) => void;
397
382
  setMotivationDetectionProgress: (progress: any) => void;
398
383
  detectionStreamRef: MutableRefObject<any>;
399
384
  cacheManager: CacheManager;
@@ -406,7 +391,7 @@ declare function createDetectionHandler(annotator: Annotator, context: {
406
391
  */
407
392
  declare function createCancelDetectionHandler(context: {
408
393
  detectionStreamRef: MutableRefObject<any>;
409
- setDetectingMotivation: (motivation: Motivation$2 | null) => void;
394
+ setDetectingMotivation: (motivation: Motivation$3 | null) => void;
410
395
  setMotivationDetectionProgress: (progress: any) => void;
411
396
  }): () => void;
412
397
 
@@ -1647,11 +1632,13 @@ interface Props$b {
1647
1632
  }
1648
1633
  declare function CodeMirrorRenderer({ content, segments, onAnnotationClick, onAnnotationHover, onTextSelect, onChange, editable, newAnnotationIds, hoveredAnnotationId, hoveredCommentId, scrollToAnnotationId, sourceView, showLineNumbers, enableWidgets, onEntityTypeClick, onReferenceNavigate, onUnresolvedReferenceClick, getTargetDocumentName, generatingReferenceId, onDeleteAnnotation }: Props$b): react_jsx_runtime.JSX.Element;
1649
1634
 
1635
+ type Motivation$2 = components['schemas']['Motivation'];
1650
1636
  interface DetectionProgressWidgetProps {
1651
1637
  progress: DetectionProgress | null;
1652
1638
  onCancel?: () => void;
1639
+ annotationType?: Motivation$2 | 'reference';
1653
1640
  }
1654
- declare function DetectionProgressWidget({ progress, onCancel }: DetectionProgressWidgetProps): react_jsx_runtime.JSX.Element | null;
1641
+ declare function DetectionProgressWidget({ progress, onCancel, annotationType }: DetectionProgressWidgetProps): react_jsx_runtime.JSX.Element | null;
1655
1642
 
1656
1643
  interface Props$a {
1657
1644
  children: ReactNode;
@@ -2136,8 +2123,9 @@ interface ReferenceEntryProps {
2136
2123
  onSearchDocuments?: (referenceId: string, searchTerm: string) => void;
2137
2124
  onUpdateReference?: (referenceId: string, updates: Partial<Annotation$6>) => void;
2138
2125
  annotateMode?: boolean;
2126
+ isGenerating?: boolean;
2139
2127
  }
2140
- declare function ReferenceEntry({ reference, isFocused, onClick, routes, onReferenceRef, onReferenceHover, onGenerateDocument, onSearchDocuments, onUpdateReference, annotateMode, }: ReferenceEntryProps): react_jsx_runtime.JSX.Element;
2128
+ declare function ReferenceEntry({ reference, isFocused, onClick, routes, onReferenceRef, onReferenceHover, onGenerateDocument, onSearchDocuments, onUpdateReference, annotateMode, isGenerating, }: ReferenceEntryProps): react_jsx_runtime.JSX.Element;
2141
2129
 
2142
2130
  type Annotation$5 = components['schemas']['Annotation'];
2143
2131
  type ResponseContent<T> = T extends {
@@ -2171,6 +2159,7 @@ interface Props$1 {
2171
2159
  title: string;
2172
2160
  prompt?: string;
2173
2161
  }) => void;
2162
+ generatingReferenceId?: string | null;
2174
2163
  mediaType?: string | undefined;
2175
2164
  referencedBy?: ReferencedBy[];
2176
2165
  referencedByLoading?: boolean;
@@ -2183,7 +2172,7 @@ interface Props$1 {
2183
2172
  svgSelector?: string;
2184
2173
  } | null;
2185
2174
  }
2186
- declare function ReferencesPanel({ annotations, onAnnotationClick, focusedAnnotationId, hoveredAnnotationId, onAnnotationHover, onDetect, onCreate, isDetecting, detectionProgress, annotateMode, Link, routes, allEntityTypes, onCancelDetection, onSearchDocuments, onUpdate, onGenerateDocument, mediaType, referencedBy, referencedByLoading, pendingSelection, }: Props$1): react_jsx_runtime.JSX.Element;
2175
+ declare function ReferencesPanel({ annotations, onAnnotationClick, focusedAnnotationId, hoveredAnnotationId, onAnnotationHover, onDetect, onCreate, isDetecting, detectionProgress, annotateMode, Link, routes, allEntityTypes, onCancelDetection, onSearchDocuments, onUpdate, onGenerateDocument, generatingReferenceId, mediaType, referencedBy, referencedByLoading, pendingSelection, }: Props$1): react_jsx_runtime.JSX.Element;
2187
2176
 
2188
2177
  interface Props {
2189
2178
  documentEntityTypes: string[];
@@ -2353,12 +2342,38 @@ interface NavigationMenuProps {
2353
2342
  }
2354
2343
  declare function NavigationMenu({ Link, routes, t, isAdmin, isModerator, brandingLink, onItemClick, className, currentPath }: NavigationMenuProps): react_jsx_runtime.JSX.Element;
2355
2344
 
2345
+ interface SimpleNavigationItem$1 {
2346
+ name: string;
2347
+ href: string;
2348
+ icon: React__default.ComponentType<{
2349
+ className?: string;
2350
+ }>;
2351
+ description?: string;
2352
+ }
2353
+ interface SimpleNavigationProps$1 {
2354
+ title: string;
2355
+ items: SimpleNavigationItem$1[];
2356
+ currentPath: string;
2357
+ LinkComponent: React__default.ComponentType<any>;
2358
+ dropdownContent?: (onClose: () => void) => React__default.ReactNode;
2359
+ isCollapsed: boolean;
2360
+ onToggleCollapse: () => void;
2361
+ icons: {
2362
+ chevronLeft: React__default.ComponentType<{
2363
+ className?: string;
2364
+ }>;
2365
+ bars: React__default.ComponentType<{
2366
+ className?: string;
2367
+ }>;
2368
+ };
2369
+ collapseSidebarLabel: string;
2370
+ expandSidebarLabel: string;
2371
+ }
2356
2372
  /**
2357
- * Framework-agnostic sidebar navigation component.
2358
- * Accepts a Link component for routing and handles active state highlighting.
2359
- * Supports collapsed state where only icons are shown.
2373
+ * Simple navigation component for Admin and Moderation modes.
2374
+ * Renders a section header with optional dropdown and static navigation tabs.
2360
2375
  */
2361
- declare function SidebarNavigation({ items, title, currentPath, LinkComponent, className, showDescriptions, activeClassName, inactiveClassName, isCollapsed, showText }: SidebarNavigationProps): react_jsx_runtime.JSX.Element;
2376
+ declare function SimpleNavigation({ title, items, currentPath, LinkComponent, dropdownContent, isCollapsed, onToggleCollapse, icons, collapseSidebarLabel, expandSidebarLabel }: SimpleNavigationProps$1): react_jsx_runtime.JSX.Element;
2362
2377
 
2363
2378
  /**
2364
2379
  * Represents an open resource/document in the navigation
@@ -2430,6 +2445,7 @@ interface CollapsibleResourceNavigationProps {
2430
2445
  bars: ComponentType<any>;
2431
2446
  close: ComponentType<any>;
2432
2447
  };
2448
+ navigationMenu?: ((onClose: () => void) => ReactNode) | undefined;
2433
2449
  }
2434
2450
 
2435
2451
  /**
@@ -2437,7 +2453,7 @@ interface CollapsibleResourceNavigationProps {
2437
2453
  * Supports drag and drop for resource reordering when expanded.
2438
2454
  * Platform-agnostic design for use across different React environments.
2439
2455
  */
2440
- declare function CollapsibleResourceNavigation({ fixedItems, resources, isCollapsed, onToggleCollapse, onResourceClose, onResourceReorder, onResourceSelect, currentPath, LinkComponent, onNavigate, getResourceHref, className, activeClassName, inactiveClassName, translations, icons }: CollapsibleResourceNavigationProps): react_jsx_runtime.JSX.Element;
2456
+ declare function CollapsibleResourceNavigation({ fixedItems, resources, isCollapsed, onToggleCollapse, onResourceClose, onResourceReorder, currentPath, LinkComponent, onNavigate, getResourceHref, className, translations, icons, navigationMenu }: CollapsibleResourceNavigationProps): react_jsx_runtime.JSX.Element;
2441
2457
 
2442
2458
  /**
2443
2459
  * A sortable tab for an open resource in the navigation sidebar.
@@ -2445,6 +2461,20 @@ declare function CollapsibleResourceNavigation({ fixedItems, resources, isCollap
2445
2461
  */
2446
2462
  declare function SortableResourceTab({ resource, isCollapsed, isActive, href, onClose, onReorder, index, totalCount, LinkComponent, translations, dragHandleProps, isDragging }: SortableResourceTabProps): react_jsx_runtime.JSX.Element;
2447
2463
 
2464
+ interface SimpleNavigationItem {
2465
+ name: string;
2466
+ href: string;
2467
+ icon: React.ComponentType<any>;
2468
+ description?: string;
2469
+ }
2470
+ interface SimpleNavigationProps {
2471
+ title: string;
2472
+ items: SimpleNavigationItem[];
2473
+ currentPath: string;
2474
+ LinkComponent: React.ComponentType<any>;
2475
+ dropdownContent?: ((onClose: () => void) => ReactNode) | undefined;
2476
+ }
2477
+
2448
2478
  interface SearchModalProps$1 {
2449
2479
  isOpen: boolean;
2450
2480
  onClose: () => void;
@@ -2591,12 +2621,15 @@ interface UnifiedHeaderProps {
2591
2621
  }
2592
2622
  declare function UnifiedHeader({ Link, routes, t, tHome, showBranding, showAuthLinks, brandingLink, variant, isAuthenticated, isAdmin, isModerator, currentPath }: UnifiedHeaderProps): react_jsx_runtime.JSX.Element;
2593
2623
 
2624
+ interface NavigationMenuHelper {
2625
+ (onClose: () => void): React__default.ReactNode;
2626
+ }
2594
2627
  interface LeftSidebarProps {
2595
2628
  Link: React__default.ComponentType<LinkComponentProps>;
2596
2629
  routes: RouteBuilder;
2597
2630
  t: TranslateFn;
2598
2631
  tHome: TranslateFn;
2599
- children: React__default.ReactNode | ((isCollapsed: boolean, toggleCollapsed: () => void) => React__default.ReactNode);
2632
+ children: React__default.ReactNode | ((isCollapsed: boolean, toggleCollapsed: () => void, navigationMenu: NavigationMenuHelper) => React__default.ReactNode);
2600
2633
  brandingLink?: string;
2601
2634
  collapsible?: boolean;
2602
2635
  storageKey?: string;
@@ -3539,4 +3572,4 @@ interface ResourceViewerPageProps {
3539
3572
  }
3540
3573
  declare function ResourceViewerPage({ resource, rUri, content, contentLoading, annotations, referencedBy, referencedByLoading, allEntityTypes, locale, theme, onThemeChange, showLineNumbers, onLineNumbersToggle, activePanel, onPanelToggle, setActivePanel, onUpdateDocumentTags, onArchive, onUnarchive, onClone, onUpdateAnnotationBody, onRefetchAnnotations, onCreateAnnotation, onDeleteAnnotation, onTriggerSparkleAnimation, onClearNewAnnotationId, showSuccess, showError, onAnnotationAdded, onAnnotationRemoved, onAnnotationBodyUpdated, onDocumentArchived, onDocumentUnarchived, onEntityTagAdded, onEntityTagRemoved, onEventError, cacheManager, client, Link, routes, ToolbarPanels, SearchResourcesModal, GenerationConfigModal, }: ResourceViewerPageProps): react_jsx_runtime.JSX.Element;
3541
3574
 
3542
- export { ANNOTATORS, AUTH_EVENTS, AVAILABLE_LOCALES, AdminDevOpsPage, type AdminDevOpsPageProps, AdminSecurityPage, type AdminSecurityPageProps, type AdminUser, type AdminUserStats, AdminUsersPage, type AdminUsersPageProps, AnnotateToolbar, AnnotateView, type Annotation$n as Annotation, type AnnotationConfig, type AnnotationCreationHandler, type AnnotationHandlers, AnnotationHistory, type AnnotationManager, AnnotationOverlay, AnnotationProvider, type AnnotationProviderProps, AnnotationUIProvider, type AnnotationUIProviderProps, type AnnotationUIState, type AnnotationsCollection, type Annotator, ApiClientManager, ApiClientProvider, type ApiClientProviderProps, AssessmentEntry, AssessmentPanel, AsyncErrorBoundary, AuthErrorDisplay, type AuthErrorDisplayProps, type AuthEventDetail, type AuthEventType, type AvailableLocale, type BorderRadiusToken, BrowseView, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, type CacheManager, CacheProvider, type CacheProviderProps, type ClickAction, CodeMirrorRenderer, CollaborationPanel, CollapsibleResourceNavigation, type CollapsibleResourceNavigationProps, type ColorToken, CommentEntry, CommentsPanel, ComposeLoadingState, type ComposeLoadingStateProps, type CreateAnnotationParams, type DeleteAnnotationParams, DetectSection, type DetectionConfig, type DetectionProgress, DetectionProgressWidget, type DevOpsFeature, type DrawingMode, EntityTagsPage, type EntityTagsPageProps, EntityTypeBadges, ErrorBoundary, Footer, type GenerationOptions, type GenerationProgress, HighlightEntry, HighlightPanel, HistoryEvent, ImageURLSchema, ImageViewer, JsonLdPanel, JsonLdView, type KeyboardShortcut, KeyboardShortcutsHelpModal, LeftSidebar, type LinkComponentProps, LiveRegionProvider, type Motivation$3 as Motivation, type NavigationItem, NavigationMenu, type NavigationProps, type OAuthProvider, type OAuthUser, OAuthUserSchema, type OpenResource, OpenResourcesManager, OpenResourcesProvider, PageLayout, PanelHeader, PopupContainer, PopupHeader, type PreparedAnnotation, ProposeEntitiesModal, QUERY_KEYS, RecentDocumentsPage, type RecentDocumentsPageProps, ReferenceEntry, ReferenceResolutionWidget, ReferencesPanel, type ResolvedTheme, ResourceAnnotationsProvider, ResourceCard, type ResourceCardProps, ResourceComposePage, type ResourceComposePageProps, ResourceDiscoveryPage, type ResourceDiscoveryPageProps, ResourceErrorState, type ResourceErrorStateProps, type ResourceEvent, ResourceInfoPanel, ResourceLoadingState, ResourceSearchModal, type ResourceSearchModalProps, ResourceTagsInline, ResourceViewer, ResourceViewerPage, type ResourceViewerPageProps, type RouteBuilder, type SaveResourceParams, SearchModal, type SearchModalProps, SelectedTextDisplay, type SelectionData, type SelectionMotivation, SemiontBranding, SemiontFavicon, type SemiontResource$3 as SemiontResource, SessionExpiryBanner, SessionManager, SessionProvider, SessionTimer, SettingsPanel, type ShadowToken, type ShapeType, SidebarNavigation, type SidebarNavigationProps, SignInForm, type SignInFormProps, SignUpForm, type SignUpFormProps, SkipLinks, SortableResourceTab, type SortableResourceTabProps, type SpacingToken, StatisticsPanel, StatusDisplay, type StreamStatus, SvgDrawingCanvas, TagEntry, TagSchemasPage, type TagSchemasPageProps, TaggingPanel, type TextSegment, type TextSelection, type Theme, ToastContainer, type ToastMessage, ToastProvider, type ToastType, Toolbar, type ToolbarPanelType, type TransitionToken, TranslationManager, TranslationProvider, type TranslationProviderProps, type TypographyToken, type UICreateAnnotationParams, UnifiedAnnotationsPanel, UnifiedHeader, UserMenuSkeleton, WelcomePage, type WelcomePageProps, buttonStyles, createCancelDetectionHandler, createDetectionHandler, cssVariables, dispatch401Error, dispatch403Error, dispatchAuthEvent, faviconPaths, generateCSSVariables, getAnnotationClassName, getAnnotationInternalType, getAnnotator, getResourceIcon, getShortcutDisplay, groupAnnotationsByType, jsonLightHighlightStyle, jsonLightTheme, onAuthEvent, rehypeRenderAnnotations, remarkAnnotations, sanitizeImageURL, supportsDetection, tokens, useAdmin, useAnnotationManager, useAnnotationPanel, useAnnotationUI, useAnnotations, useApiClient, useAuthApi, useCacheManager, useDebounce, useDebouncedCallback, useDetectionProgress, useDocumentAnnouncements, useDoubleKeyPress, useDropdown, useEntityTypes, useFormAnnouncements, useFormValidation, useFormattedTime, useGenerationProgress, useHealth, useIsTyping, useKeyboardShortcuts, useLanguageChangeAnnouncements, useLineNumbers, useLiveRegion, useLoadingState, useLocalStorage, useOpenResources, usePreloadTranslations, useResourceAnnotations, useResourceEvents, useResourceLoadingAnnouncements, useResources, useRovingTabIndex, useSearchAnnouncements, useSessionContext, useSessionExpiry, useTheme, useToast, useToolbar, useTranslations, validationRules, withHandlers };
3575
+ export { ANNOTATORS, AUTH_EVENTS, AVAILABLE_LOCALES, AdminDevOpsPage, type AdminDevOpsPageProps, AdminSecurityPage, type AdminSecurityPageProps, type AdminUser, type AdminUserStats, AdminUsersPage, type AdminUsersPageProps, AnnotateToolbar, AnnotateView, type Annotation$n as Annotation, type AnnotationConfig, type AnnotationCreationHandler, type AnnotationHandlers, AnnotationHistory, type AnnotationManager, AnnotationOverlay, AnnotationProvider, type AnnotationProviderProps, AnnotationUIProvider, type AnnotationUIProviderProps, type AnnotationUIState, type AnnotationsCollection, type Annotator, ApiClientManager, ApiClientProvider, type ApiClientProviderProps, AssessmentEntry, AssessmentPanel, AsyncErrorBoundary, AuthErrorDisplay, type AuthErrorDisplayProps, type AuthEventDetail, type AuthEventType, type AvailableLocale, type BorderRadiusToken, BrowseView, Button, ButtonGroup, type ButtonGroupProps, type ButtonProps, type CacheManager, CacheProvider, type CacheProviderProps, type ClickAction, CodeMirrorRenderer, CollaborationPanel, CollapsibleResourceNavigation, type CollapsibleResourceNavigationProps, type ColorToken, CommentEntry, CommentsPanel, ComposeLoadingState, type ComposeLoadingStateProps, type CreateAnnotationParams, type DeleteAnnotationParams, DetectSection, type DetectionConfig, type DetectionProgress, DetectionProgressWidget, type DevOpsFeature, type DrawingMode, EntityTagsPage, type EntityTagsPageProps, EntityTypeBadges, ErrorBoundary, Footer, type GenerationOptions, type GenerationProgress, HighlightEntry, HighlightPanel, HistoryEvent, ImageURLSchema, ImageViewer, JsonLdPanel, JsonLdView, type KeyboardShortcut, KeyboardShortcutsHelpModal, LeftSidebar, type LinkComponentProps, LiveRegionProvider, type Motivation$4 as Motivation, type NavigationItem, NavigationMenu, type NavigationMenuHelper, type NavigationProps, type OAuthProvider, type OAuthUser, OAuthUserSchema, type OpenResource, OpenResourcesManager, OpenResourcesProvider, PageLayout, PanelHeader, PopupContainer, PopupHeader, type PreparedAnnotation, ProposeEntitiesModal, QUERY_KEYS, RecentDocumentsPage, type RecentDocumentsPageProps, ReferenceEntry, ReferenceResolutionWidget, ReferencesPanel, type ResolvedTheme, ResourceAnnotationsProvider, ResourceCard, type ResourceCardProps, ResourceComposePage, type ResourceComposePageProps, ResourceDiscoveryPage, type ResourceDiscoveryPageProps, ResourceErrorState, type ResourceErrorStateProps, type ResourceEvent, ResourceInfoPanel, ResourceLoadingState, ResourceSearchModal, type ResourceSearchModalProps, ResourceTagsInline, ResourceViewer, ResourceViewerPage, type ResourceViewerPageProps, type RouteBuilder, type SaveResourceParams, SearchModal, type SearchModalProps, SelectedTextDisplay, type SelectionData, type SelectionMotivation, SemiontBranding, SemiontFavicon, type SemiontResource$3 as SemiontResource, SessionExpiryBanner, SessionManager, SessionProvider, SessionTimer, SettingsPanel, type ShadowToken, type ShapeType, SignInForm, type SignInFormProps, SignUpForm, type SignUpFormProps, SimpleNavigation, type SimpleNavigationItem, type SimpleNavigationProps, SkipLinks, SortableResourceTab, type SortableResourceTabProps, type SpacingToken, StatisticsPanel, StatusDisplay, type StreamStatus, SvgDrawingCanvas, TagEntry, TagSchemasPage, type TagSchemasPageProps, TaggingPanel, type TextSegment, type TextSelection, type Theme, ToastContainer, type ToastMessage, ToastProvider, type ToastType, Toolbar, type ToolbarPanelType, type TransitionToken, TranslationManager, TranslationProvider, type TranslationProviderProps, type TypographyToken, type UICreateAnnotationParams, UnifiedAnnotationsPanel, UnifiedHeader, UserMenuSkeleton, WelcomePage, type WelcomePageProps, buttonStyles, createCancelDetectionHandler, createDetectionHandler, cssVariables, dispatch401Error, dispatch403Error, dispatchAuthEvent, faviconPaths, generateCSSVariables, getAnnotationClassName, getAnnotationInternalType, getAnnotator, getResourceIcon, getShortcutDisplay, groupAnnotationsByType, jsonLightHighlightStyle, jsonLightTheme, onAuthEvent, rehypeRenderAnnotations, remarkAnnotations, sanitizeImageURL, supportsDetection, tokens, useAdmin, useAnnotationManager, useAnnotationPanel, useAnnotationUI, useAnnotations, useApiClient, useAuthApi, useCacheManager, useDebounce, useDebouncedCallback, useDetectionProgress, useDocumentAnnouncements, useDoubleKeyPress, useDropdown, useEntityTypes, useFormAnnouncements, useFormValidation, useFormattedTime, useGenerationProgress, useHealth, useIsTyping, useKeyboardShortcuts, useLanguageChangeAnnouncements, useLineNumbers, useLiveRegion, useLoadingState, useLocalStorage, useOpenResources, usePreloadTranslations, useResourceAnnotations, useResourceEvents, useResourceLoadingAnnouncements, useResources, useRovingTabIndex, useSearchAnnouncements, useSessionContext, useSessionExpiry, useTheme, useToast, useToolbar, useTranslations, validationRules, withHandlers };