@elevasis/ui 1.7.5 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/index.js +2 -3
- package/dist/auth/index.js +3 -4
- package/dist/charts/index.js +6 -8
- package/dist/{chunk-SFF5MJEI.js → chunk-2YBPRE6H.js} +1 -2
- package/dist/{chunk-U34YGJQB.js → chunk-3I2LOKQU.js} +1 -1
- package/dist/{chunk-PVVQTENF.js → chunk-3PURTICE.js} +1 -1
- package/dist/{chunk-2JBWPFHF.js → chunk-6TMW6VQ2.js} +1 -1
- package/dist/{chunk-6HZAMY6T.js → chunk-ARZM3OTI.js} +6 -2
- package/dist/{chunk-OK3XFSJJ.js → chunk-BWZMI4KP.js} +963 -10
- package/dist/{chunk-4KPI7YCY.js → chunk-EHXOR5LA.js} +2 -3
- package/dist/{chunk-Y7UY3HI4.js → chunk-ESOQEOOX.js} +2 -2
- package/dist/{chunk-L2CM2CUA.js → chunk-GZVH423C.js} +26 -3
- package/dist/{chunk-Y6DNK5ZD.js → chunk-JRJW2H57.js} +35 -9
- package/dist/{chunk-LBPALY25.js → chunk-JUPCUF77.js} +2 -2
- package/dist/chunk-QWYJHM3S.js +1068 -0
- package/dist/{chunk-NEK6JKPW.js → chunk-WUQWCUCB.js} +1 -1
- package/dist/chunk-Z4TPHMRD.js +231 -0
- package/dist/components/index.css +65 -0
- package/dist/components/index.d.ts +261 -2
- package/dist/components/index.js +1136 -80
- package/dist/hooks/index.css +452 -0
- package/dist/hooks/index.d.ts +1831 -13
- package/dist/hooks/index.js +15 -6
- package/dist/hooks/published.css +452 -0
- package/dist/hooks/published.d.ts +866 -6
- package/dist/hooks/published.js +15 -370
- package/dist/index.css +3 -0
- package/dist/index.d.ts +1665 -2
- package/dist/index.js +14 -17
- package/dist/initialization/index.js +3 -4
- package/dist/organization/index.js +3 -4
- package/dist/profile/index.js +1 -2
- package/dist/provider/index.css +3 -0
- package/dist/provider/index.js +7 -10
- package/dist/provider/published.js +6 -9
- package/dist/utils/index.d.ts +92 -1
- package/dist/utils/index.js +1 -2
- package/package.json +7 -3
- package/dist/chunk-4VGWQ5AN.js +0 -91
- package/dist/chunk-KA7LO7U5.js +0 -28
- package/dist/chunk-LFYO3MDC.js +0 -58
- package/dist/chunk-TIRMFDM4.js +0 -33
- package/dist/chunk-TYV5NJV2.js +0 -1
package/dist/index.js
CHANGED
|
@@ -1,29 +1,26 @@
|
|
|
1
1
|
import './chunk-ARQRKA6J.js';
|
|
2
|
-
export { createOrganizationsSlice, createUseOrgInitialization, createUseOrganizations } from './chunk-U34YGJQB.js';
|
|
3
2
|
import './chunk-XCYKC6OZ.js';
|
|
4
|
-
export { createUseAppInitialization } from './chunk-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export {
|
|
8
|
-
export { observabilityKeys, useErrorTrends } from './chunk-6HZAMY6T.js';
|
|
3
|
+
export { createUseAppInitialization } from './chunk-3PURTICE.js';
|
|
4
|
+
export { ApiKeyService, CredentialService, DeploymentService, OrganizationMembershipService, WebhookEndpointService, filterByDomainFilters, useActivateDeployment, useActivityFilters, useCommandViewDomainFilters, useCreateApiKey, useCreateCredential, useCreateWebhookEndpoint, useCredentials, useDeactivateDeployment, useDeactivateMembership, useDeleteApiKey, useDeleteCredential, useDeleteDeployment, useDeleteWebhookEndpoint, useExecutionLogsFilters, useListApiKeys, useListDeployments, useListWebhookEndpoints, useOrganizationMembers, useReactivateMembership, useResourceSearch, useResourcesDomainFilters, useStatusFilter, useTimeRangeDates, useUpdateApiKey, useUpdateCredential, useUpdateMemberConfig, useUpdateWebhookEndpoint, useUserMemberships, useVisibleResources } from './chunk-QWYJHM3S.js';
|
|
5
|
+
export { OperationsService, createUseFeatureAccess, executionsKeys, isSessionCapable, operationsKeys, scheduleKeys, sessionsKeys, sortData, useActivities, useActivityTrend, useArchiveSession, useBatchDelete, useBatchedResourcesHealth, useBulkDeleteExecutions, useBusinessImpact, useCancelExecution, useCancelSchedule, useCheckpointTasks, useCommandQueue, useCommandQueueTotals, useCommandViewData, useCommandViewLayout, useCommandViewStats, useCommandViewStore, useCostBreakdown, useCostByModel, useCostSummary, useCostTrends, useCreateSchedule, useCreateSession, useDashboardMetrics, useDeleteExecution, useDeleteSchedule, useDeleteSession, useDeleteTask, useDeploymentDocs, useErrorAnalysis, useErrorDetail, useErrorDetails, useErrorDistribution, useErrorNotification, useExecuteAsync, useExecution, useExecutionHealth, useExecutionLogSSE, useExecutionLogs, useExecutionPanelState, useExecutions, useGetExecutionHistory, useGetSchedule, useGraphStats, useListSchedules, useMarkAllAsRead, useMarkAsRead, useNotificationCount, useNotifications, usePaginationState, usePatchTask, usePauseSchedule, useRecentExecutionsByResource, useResolveAllErrors, useResolveError, useResolveErrorsByExecution, useResourceDefinition, useResourceErrors, useResourceExecutions, useResources, useResourcesHealth, useResumeSchedule, useRetryExecution, useSSEConnection, useScheduledTasks, useSession, useSessionExecution, useSessionExecutions, useSessionMessages, useSessionWebSocket, useSessions, useSortedData, useSubmitAction, useSuccessNotification, useTableSelection, useTableSort, useTestNotification, useTopFailingResources, useUnresolveError, useUnresolvedErrors, useUpdateAnchor, useUpdateSchedule, useWarningNotification } from './chunk-BWZMI4KP.js';
|
|
6
|
+
export { observabilityKeys, useErrorTrends } from './chunk-ARZM3OTI.js';
|
|
9
7
|
import './chunk-JGJSZ3UE.js';
|
|
10
8
|
export { TanStackRouterBridge } from './chunk-LHQTTUL2.js';
|
|
11
9
|
export { GRAPH_CONSTANTS, calculateGraphHeight, useConnectionHighlight, useDirectedChainHighlighting, useFitViewTrigger, useGraphHighlighting, useNodeSelection } from './chunk-F6RBK7NJ.js';
|
|
12
10
|
export { AGENT_CONSTANTS, CONTAINER_CONSTANTS, SHARED_VIZ_CONSTANTS, STATUS_COLORS, TIMELINE_CONSTANTS, WORKFLOW_CONSTANTS, calculateBarPosition, formatDuration, getEdgeColor, getEdgeOpacity, getResourceStatusColor, getStatusColors, getStatusIcon, shouldAnimateEdge, useAgentIterationData, useExecutionPath, useMergedExecution, useReactFlowAgent, useTimelineData, useUnifiedWorkflowLayout, useWorkflowStepsLayout } from './chunk-3Q5V2T6L.js';
|
|
13
11
|
import './chunk-YZ6GTZXL.js';
|
|
14
|
-
export {
|
|
12
|
+
export { createOrganizationsSlice, createUseOrgInitialization, createUseOrganizations } from './chunk-3I2LOKQU.js';
|
|
13
|
+
import './chunk-RNP5R5I3.js';
|
|
14
|
+
export { ElevasisProvider, ElevasisUIProvider, mantineNotificationAdapter } from './chunk-ESOQEOOX.js';
|
|
15
15
|
export { TOKEN_VAR_MAP, componentThemes, createCssVariablesResolver, generateShades, getPreset, mantineThemeOverride } from './chunk-KB5NKPTN.js';
|
|
16
|
-
export { ElevasisCoreProvider } from './chunk-
|
|
17
|
-
export { OrganizationProvider } from './chunk-
|
|
18
|
-
export { ApiClientProvider, useApiClient, useApiClientContext } from './chunk-
|
|
19
|
-
export {
|
|
20
|
-
export {
|
|
21
|
-
export { APIClientError, formatErrorMessage, getErrorInfo, getErrorTitle, isAPIClientError } from './chunk-4VGWQ5AN.js';
|
|
22
|
-
export { AdminGuard, ProtectedRoute, useSessionCheck as useRefocusSessionCheck, useSessionCheck } from './chunk-2JBWPFHF.js';
|
|
16
|
+
export { ElevasisCoreProvider, NotificationProvider, useNotificationAdapter } from './chunk-JRJW2H57.js';
|
|
17
|
+
export { OrganizationProvider } from './chunk-2YBPRE6H.js';
|
|
18
|
+
export { ApiClientProvider, useApiClient, useApiClientContext } from './chunk-JUPCUF77.js';
|
|
19
|
+
export { APIClientError, DEBOUNCE_FILTER, DEBOUNCE_SLIDER, GC_TIME_LONG, GC_TIME_MEDIUM, GC_TIME_SHORT, LIMIT_ACTIVITY_FEED, OAUTH_FLOW_TIMEOUT, OAUTH_POPUP_CHECK_INTERVAL, PAGE_SIZE_DEFAULT, REFETCH_INTERVAL_DASHBOARD, REFETCH_INTERVAL_REALTIME, REFETCH_INTERVAL_RUNNING, REFETCH_INTERVAL_RUNNING_FAST, SSE_CLOSE_GRACE_PERIOD, SSE_TOKEN_REFRESH_DELAY, STALE_TIME_ADMIN, STALE_TIME_DEFAULT, STALE_TIME_MONITORING, WS_MAX_RETRIES_BEFORE_ERROR, WS_RECONNECT_BASE_DELAY, WS_RECONNECT_MAX_DELAY, formatChartAxisDate, formatDate, formatDateTime, formatErrorMessage, getErrorInfo, getErrorTitle, getResourceColor, getResourceIcon, isAPIClientError, restoreConsole, suppressKnownWarnings, validateEmail } from './chunk-Z4TPHMRD.js';
|
|
20
|
+
export { AdminGuard, ProtectedRoute, useSessionCheck as useRefocusSessionCheck, useSessionCheck } from './chunk-6TMW6VQ2.js';
|
|
23
21
|
export { useStableAccessToken } from './chunk-FWZJH3TL.js';
|
|
24
|
-
export { InitializationContext, InitializationProvider, useInitialization } from './chunk-
|
|
25
|
-
export { ProfileProvider, UserProfileService, useProfile, useUserProfile } from './chunk-
|
|
26
|
-
export { ElevasisServiceProvider, useElevasisServices } from './chunk-KA7LO7U5.js';
|
|
22
|
+
export { InitializationContext, InitializationProvider, useInitialization } from './chunk-WUQWCUCB.js';
|
|
23
|
+
export { ElevasisServiceProvider, ProfileProvider, UserProfileService, useElevasisServices, useProfile, useUserProfile } from './chunk-GZVH423C.js';
|
|
27
24
|
export { useOrganization } from './chunk-DD3CCMCZ.js';
|
|
28
25
|
export { AuthProvider, useAuthContext } from './chunk-7PLEQFHO.js';
|
|
29
26
|
export { RouterProvider, useRouterContext } from './chunk-Q7DJKLEN.js';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
export { createUseAppInitialization } from '../chunk-
|
|
1
|
+
export { createUseAppInitialization } from '../chunk-3PURTICE.js';
|
|
2
2
|
import '../chunk-RNP5R5I3.js';
|
|
3
|
-
export { InitializationContext, InitializationProvider, useInitialization } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
5
|
-
import '../chunk-KA7LO7U5.js';
|
|
3
|
+
export { InitializationContext, InitializationProvider, useInitialization } from '../chunk-WUQWCUCB.js';
|
|
4
|
+
import '../chunk-GZVH423C.js';
|
|
6
5
|
import '../chunk-DD3CCMCZ.js';
|
|
7
6
|
import '../chunk-7PLEQFHO.js';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
export { createOrganizationsSlice, createUseOrgInitialization, createUseOrganizations } from '../chunk-
|
|
1
|
+
export { createOrganizationsSlice, createUseOrgInitialization, createUseOrganizations } from '../chunk-3I2LOKQU.js';
|
|
2
2
|
import '../chunk-RNP5R5I3.js';
|
|
3
|
-
export { OrganizationProvider } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
5
|
-
import '../chunk-KA7LO7U5.js';
|
|
3
|
+
export { OrganizationProvider } from '../chunk-2YBPRE6H.js';
|
|
4
|
+
import '../chunk-GZVH423C.js';
|
|
6
5
|
export { useOrganization } from '../chunk-DD3CCMCZ.js';
|
|
7
6
|
import '../chunk-7PLEQFHO.js';
|
package/dist/profile/index.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
import '../chunk-RNP5R5I3.js';
|
|
2
|
-
export { ProfileProvider, UserProfileService, useProfile, useUserProfile } from '../chunk-
|
|
3
|
-
import '../chunk-KA7LO7U5.js';
|
|
2
|
+
export { ProfileProvider, UserProfileService, useProfile, useUserProfile } from '../chunk-GZVH423C.js';
|
|
4
3
|
import '../chunk-7PLEQFHO.js';
|
package/dist/provider/index.css
CHANGED
|
@@ -8,6 +8,9 @@
|
|
|
8
8
|
.mantine-Select-option:hover {
|
|
9
9
|
background-color: var(--color-surface-hover) !important;
|
|
10
10
|
}
|
|
11
|
+
[data-mantine-color-scheme=dark] .mantine-Tabs-root {
|
|
12
|
+
--tab-border-color: var(--color-border);
|
|
13
|
+
}
|
|
11
14
|
.mantine-Tabs-tab:hover {
|
|
12
15
|
background-color: var(--color-surface-hover);
|
|
13
16
|
}
|
package/dist/provider/index.js
CHANGED
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
export { ElevasisProvider, ElevasisUIProvider, mantineNotificationAdapter } from '../chunk-
|
|
1
|
+
export { ElevasisProvider, ElevasisUIProvider, mantineNotificationAdapter } from '../chunk-ESOQEOOX.js';
|
|
2
2
|
import '../chunk-KB5NKPTN.js';
|
|
3
|
-
export { ElevasisCoreProvider } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
5
|
-
import '../chunk-
|
|
6
|
-
|
|
7
|
-
import '../chunk-
|
|
8
|
-
|
|
9
|
-
import '../chunk-NEK6JKPW.js';
|
|
10
|
-
import '../chunk-L2CM2CUA.js';
|
|
11
|
-
export { ElevasisServiceProvider, useElevasisServices } from '../chunk-KA7LO7U5.js';
|
|
3
|
+
export { ElevasisCoreProvider, NotificationProvider, useNotificationAdapter } from '../chunk-JRJW2H57.js';
|
|
4
|
+
import '../chunk-2YBPRE6H.js';
|
|
5
|
+
import '../chunk-JUPCUF77.js';
|
|
6
|
+
import '../chunk-Z4TPHMRD.js';
|
|
7
|
+
import '../chunk-WUQWCUCB.js';
|
|
8
|
+
export { ElevasisServiceProvider, useElevasisServices } from '../chunk-GZVH423C.js';
|
|
12
9
|
import '../chunk-DD3CCMCZ.js';
|
|
13
10
|
import '../chunk-7PLEQFHO.js';
|
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
export { ElevasisCoreProvider } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
import '../chunk-
|
|
4
|
-
|
|
5
|
-
import '../chunk-
|
|
6
|
-
|
|
7
|
-
import '../chunk-NEK6JKPW.js';
|
|
8
|
-
import '../chunk-L2CM2CUA.js';
|
|
9
|
-
export { ElevasisServiceProvider, useElevasisServices } from '../chunk-KA7LO7U5.js';
|
|
1
|
+
export { ElevasisCoreProvider, NotificationProvider, useNotificationAdapter } from '../chunk-JRJW2H57.js';
|
|
2
|
+
import '../chunk-2YBPRE6H.js';
|
|
3
|
+
import '../chunk-JUPCUF77.js';
|
|
4
|
+
import '../chunk-Z4TPHMRD.js';
|
|
5
|
+
import '../chunk-WUQWCUCB.js';
|
|
6
|
+
export { ElevasisServiceProvider, useElevasisServices } from '../chunk-GZVH423C.js';
|
|
10
7
|
import '../chunk-DD3CCMCZ.js';
|
|
11
8
|
import '../chunk-7PLEQFHO.js';
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -152,5 +152,96 @@ type TablerIcon = typeof IconBrain;
|
|
|
152
152
|
*/
|
|
153
153
|
declare function getResourceIcon(type: ResourceDefinitionType): TablerIcon;
|
|
154
154
|
|
|
155
|
-
|
|
155
|
+
/** Monitoring and analytics stale time (30s). */
|
|
156
|
+
declare const STALE_TIME_MONITORING = 30000;
|
|
157
|
+
/** Admin data stale time (1 min). */
|
|
158
|
+
declare const STALE_TIME_ADMIN = 60000;
|
|
159
|
+
/** Global default and static data stale time (5 min). Matches queryClient default. */
|
|
160
|
+
declare const STALE_TIME_DEFAULT = 300000;
|
|
161
|
+
/** Short-lived cache garbage collection for admin/resource hooks (5 min). */
|
|
162
|
+
declare const GC_TIME_SHORT = 300000;
|
|
163
|
+
/** Medium-lived cache garbage collection for resource detail hooks (10 min). */
|
|
164
|
+
declare const GC_TIME_MEDIUM = 600000;
|
|
165
|
+
/** Long-lived cache garbage collection for resource definitions (30 min). Matches queryClient default. */
|
|
166
|
+
declare const GC_TIME_LONG = 1800000;
|
|
167
|
+
|
|
168
|
+
/** Dashboard and monitoring data polling interval (60s). */
|
|
169
|
+
declare const REFETCH_INTERVAL_DASHBOARD = 60000;
|
|
170
|
+
/** Near-real-time data polling for logs and activities (30s). */
|
|
171
|
+
declare const REFETCH_INTERVAL_REALTIME = 30000;
|
|
172
|
+
/** Active execution detail polling when status is 'running' (2s). */
|
|
173
|
+
declare const REFETCH_INTERVAL_RUNNING = 2000;
|
|
174
|
+
/** Execution runner list polling when executions are active (1s). */
|
|
175
|
+
declare const REFETCH_INTERVAL_RUNNING_FAST = 1000;
|
|
176
|
+
|
|
177
|
+
/** SSE reconnect delay after token refresh (2s). */
|
|
178
|
+
declare const SSE_TOKEN_REFRESH_DELAY = 2000;
|
|
179
|
+
/** SSE unsubscribe grace period for tab switching (5s). */
|
|
180
|
+
declare const SSE_CLOSE_GRACE_PERIOD = 5000;
|
|
181
|
+
/** WebSocket exponential backoff base delay (1s). */
|
|
182
|
+
declare const WS_RECONNECT_BASE_DELAY = 1000;
|
|
183
|
+
/** WebSocket reconnect delay cap (30s). */
|
|
184
|
+
declare const WS_RECONNECT_MAX_DELAY = 30000;
|
|
185
|
+
/** WebSocket retries before showing error state. */
|
|
186
|
+
declare const WS_MAX_RETRIES_BEFORE_ERROR = 3;
|
|
187
|
+
|
|
188
|
+
/** Standard page size for lists (command queue, notifications). */
|
|
189
|
+
declare const PAGE_SIZE_DEFAULT = 20;
|
|
190
|
+
/** Activity feed page size and load-more increment. */
|
|
191
|
+
declare const LIMIT_ACTIVITY_FEED = 50;
|
|
192
|
+
/** Search/filter input debounce delay (150ms). */
|
|
193
|
+
declare const DEBOUNCE_FILTER = 150;
|
|
194
|
+
/** Slider input debounce delay (500ms). */
|
|
195
|
+
declare const DEBOUNCE_SLIDER = 500;
|
|
196
|
+
/** OAuth popup closed-check polling interval (500ms). */
|
|
197
|
+
declare const OAUTH_POPUP_CHECK_INTERVAL = 500;
|
|
198
|
+
/** OAuth flow maximum duration before timeout (5 min). */
|
|
199
|
+
declare const OAUTH_FLOW_TIMEOUT = 300000;
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
* Date formatting utilities for consistent date display across the application
|
|
203
|
+
*/
|
|
204
|
+
/**
|
|
205
|
+
* Format a date string for display with date and time
|
|
206
|
+
*
|
|
207
|
+
* @param dateString - ISO date string or null
|
|
208
|
+
* @returns Formatted date string (e.g., "Dec 9, 2025, 10:30 AM") or "Never" if null
|
|
209
|
+
*
|
|
210
|
+
* @example
|
|
211
|
+
* formatDateTime('2025-12-09T10:30:00Z') // "Dec 9, 2025, 10:30 AM"
|
|
212
|
+
* formatDateTime(null) // "Never"
|
|
213
|
+
*/
|
|
214
|
+
declare function formatDateTime(dateString: string | null): string;
|
|
215
|
+
/**
|
|
216
|
+
* Format a date string for chart axis labels (compact format)
|
|
217
|
+
*
|
|
218
|
+
* @param dateString - ISO date string or null
|
|
219
|
+
* @returns Compact formatted string (e.g., "12/8, 9PM") or empty string if null
|
|
220
|
+
*
|
|
221
|
+
* @example
|
|
222
|
+
* formatChartAxisDate('2025-12-08T21:00:00.000Z') // "12/8, 9PM"
|
|
223
|
+
* formatChartAxisDate('2025-12-09T13:00:00.000Z') // "12/9, 1PM"
|
|
224
|
+
*/
|
|
225
|
+
declare function formatChartAxisDate(dateString: string | null): string;
|
|
226
|
+
|
|
227
|
+
/**
|
|
228
|
+
* Suppresses known non-critical console warnings in development
|
|
229
|
+
*
|
|
230
|
+
* This utility filters out warnings that are:
|
|
231
|
+
* - Coming from third-party libraries (e.g., Mantine deprecation warnings)
|
|
232
|
+
* - Non-breaking and do not affect functionality
|
|
233
|
+
* - Expected to be fixed in future library updates
|
|
234
|
+
*/
|
|
235
|
+
/**
|
|
236
|
+
* Initializes warning suppression by intercepting console.error and console.warn
|
|
237
|
+
* Call this once at application startup
|
|
238
|
+
*/
|
|
239
|
+
declare function suppressKnownWarnings(): void;
|
|
240
|
+
/**
|
|
241
|
+
* Restores original console.error and console.warn behavior
|
|
242
|
+
* Useful for testing
|
|
243
|
+
*/
|
|
244
|
+
declare function restoreConsole(): void;
|
|
245
|
+
|
|
246
|
+
export { APIClientError, DEBOUNCE_FILTER, DEBOUNCE_SLIDER, GC_TIME_LONG, GC_TIME_MEDIUM, GC_TIME_SHORT, LIMIT_ACTIVITY_FEED, OAUTH_FLOW_TIMEOUT, OAUTH_POPUP_CHECK_INTERVAL, PAGE_SIZE_DEFAULT, REFETCH_INTERVAL_DASHBOARD, REFETCH_INTERVAL_REALTIME, REFETCH_INTERVAL_RUNNING, REFETCH_INTERVAL_RUNNING_FAST, SSE_CLOSE_GRACE_PERIOD, SSE_TOKEN_REFRESH_DELAY, STALE_TIME_ADMIN, STALE_TIME_DEFAULT, STALE_TIME_MONITORING, WS_MAX_RETRIES_BEFORE_ERROR, WS_RECONNECT_BASE_DELAY, WS_RECONNECT_MAX_DELAY, formatChartAxisDate, formatDate, formatDateTime, formatErrorMessage, getErrorInfo, getErrorTitle, getResourceColor, getResourceIcon, isAPIClientError, restoreConsole, suppressKnownWarnings, validateEmail };
|
|
156
247
|
export type { TablerIcon };
|
package/dist/utils/index.js
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
export { formatDate, getResourceColor, getResourceIcon, validateEmail } from '../chunk-
|
|
2
|
-
export { APIClientError, formatErrorMessage, getErrorInfo, getErrorTitle, isAPIClientError } from '../chunk-4VGWQ5AN.js';
|
|
1
|
+
export { APIClientError, DEBOUNCE_FILTER, DEBOUNCE_SLIDER, GC_TIME_LONG, GC_TIME_MEDIUM, GC_TIME_SHORT, LIMIT_ACTIVITY_FEED, OAUTH_FLOW_TIMEOUT, OAUTH_POPUP_CHECK_INTERVAL, PAGE_SIZE_DEFAULT, REFETCH_INTERVAL_DASHBOARD, REFETCH_INTERVAL_REALTIME, REFETCH_INTERVAL_RUNNING, REFETCH_INTERVAL_RUNNING_FAST, SSE_CLOSE_GRACE_PERIOD, SSE_TOKEN_REFRESH_DELAY, STALE_TIME_ADMIN, STALE_TIME_DEFAULT, STALE_TIME_MONITORING, WS_MAX_RETRIES_BEFORE_ERROR, WS_RECONNECT_BASE_DELAY, WS_RECONNECT_MAX_DELAY, formatChartAxisDate, formatDate, formatDateTime, formatErrorMessage, getErrorInfo, getErrorTitle, getResourceColor, getResourceIcon, isAPIClientError, restoreConsole, suppressKnownWarnings, validateEmail } from '../chunk-Z4TPHMRD.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elevasis/ui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.8.0",
|
|
4
4
|
"description": "UI components and platform-aware hooks for building custom frontends on the Elevasis platform",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -91,6 +91,10 @@
|
|
|
91
91
|
"types": "./dist/auth/context.d.ts",
|
|
92
92
|
"import": "./dist/auth/context.js"
|
|
93
93
|
},
|
|
94
|
+
"./components/navigation": {
|
|
95
|
+
"types": "./dist/components/navigation/index.d.ts",
|
|
96
|
+
"import": "./dist/components/navigation/index.js"
|
|
97
|
+
},
|
|
94
98
|
"./components/index.css": "./dist/components/index.css",
|
|
95
99
|
"./layout/index.css": "./dist/layout/index.css",
|
|
96
100
|
"./graph/index.css": "./dist/graph/index.css",
|
|
@@ -178,9 +182,9 @@
|
|
|
178
182
|
"tsup": "^8.0.0",
|
|
179
183
|
"typescript": "5.9.2",
|
|
180
184
|
"vite": "^7.0.0",
|
|
185
|
+
"@repo/core": "0.0.0",
|
|
181
186
|
"@repo/eslint-config": "0.0.0",
|
|
182
|
-
"@repo/typescript-config": "0.0.0"
|
|
183
|
-
"@repo/core": "0.0.0"
|
|
187
|
+
"@repo/typescript-config": "0.0.0"
|
|
184
188
|
},
|
|
185
189
|
"dependencies": {
|
|
186
190
|
"@dagrejs/dagre": "^1.1.4",
|
package/dist/chunk-4VGWQ5AN.js
DELETED
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
// src/utils/error-utils.ts
|
|
2
|
-
var APIClientError = class extends Error {
|
|
3
|
-
statusCode;
|
|
4
|
-
code;
|
|
5
|
-
requestId;
|
|
6
|
-
fields;
|
|
7
|
-
retryAfter;
|
|
8
|
-
constructor(message, code, statusCode, requestId, fields, retryAfter) {
|
|
9
|
-
super(message);
|
|
10
|
-
this.name = "APIClientError";
|
|
11
|
-
this.code = code;
|
|
12
|
-
this.statusCode = statusCode;
|
|
13
|
-
this.requestId = requestId;
|
|
14
|
-
this.fields = fields;
|
|
15
|
-
this.retryAfter = retryAfter;
|
|
16
|
-
}
|
|
17
|
-
};
|
|
18
|
-
function isAPIClientError(error) {
|
|
19
|
-
return error instanceof APIClientError;
|
|
20
|
-
}
|
|
21
|
-
function getErrorInfo(error) {
|
|
22
|
-
if (isAPIClientError(error)) {
|
|
23
|
-
return {
|
|
24
|
-
message: error.message,
|
|
25
|
-
code: error.code,
|
|
26
|
-
requestId: error.requestId,
|
|
27
|
-
statusCode: error.statusCode,
|
|
28
|
-
fields: error.fields,
|
|
29
|
-
retryAfter: error.retryAfter
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
if (error instanceof Error) {
|
|
33
|
-
return {
|
|
34
|
-
message: error.message
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
return {
|
|
38
|
-
message: String(error)
|
|
39
|
-
};
|
|
40
|
-
}
|
|
41
|
-
function getErrorTitle(code) {
|
|
42
|
-
if (!code) return "Error";
|
|
43
|
-
switch (code) {
|
|
44
|
-
case "VALIDATION_ERROR":
|
|
45
|
-
return "Validation Error";
|
|
46
|
-
case "AUTHENTICATION_FAILED":
|
|
47
|
-
return "Authentication Required";
|
|
48
|
-
case "FORBIDDEN":
|
|
49
|
-
return "Access Denied";
|
|
50
|
-
case "NOT_FOUND":
|
|
51
|
-
return "Not Found";
|
|
52
|
-
case "CONFLICT":
|
|
53
|
-
return "Conflict";
|
|
54
|
-
case "RATE_LIMIT_EXCEEDED":
|
|
55
|
-
return "Rate Limit Exceeded";
|
|
56
|
-
case "INTERNAL_SERVER_ERROR":
|
|
57
|
-
return "Server Error";
|
|
58
|
-
case "SERVICE_UNAVAILABLE":
|
|
59
|
-
return "Service Temporarily Unavailable";
|
|
60
|
-
default:
|
|
61
|
-
return "Error";
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
function formatErrorMessage(message, requestId, fields, retryAfter) {
|
|
65
|
-
let formatted = message;
|
|
66
|
-
if (fields && Object.keys(fields).length > 0) {
|
|
67
|
-
const fieldErrors = [];
|
|
68
|
-
for (const [field, errors] of Object.entries(fields)) {
|
|
69
|
-
const fieldName = field === "root" || field === "_root" ? "Request" : field;
|
|
70
|
-
errors.forEach((error) => {
|
|
71
|
-
fieldErrors.push(`\u2022 ${fieldName}: ${error}`);
|
|
72
|
-
});
|
|
73
|
-
}
|
|
74
|
-
if (fieldErrors.length > 0) {
|
|
75
|
-
formatted = fieldErrors.join("\n");
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
if (retryAfter) {
|
|
79
|
-
formatted += `
|
|
80
|
-
|
|
81
|
-
Please wait ${retryAfter} seconds before retrying.`;
|
|
82
|
-
}
|
|
83
|
-
if (requestId) {
|
|
84
|
-
formatted += `
|
|
85
|
-
|
|
86
|
-
Request ID: ${requestId}`;
|
|
87
|
-
}
|
|
88
|
-
return formatted;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
export { APIClientError, formatErrorMessage, getErrorInfo, getErrorTitle, isAPIClientError };
|
package/dist/chunk-KA7LO7U5.js
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { createContext, useContext, useMemo } from 'react';
|
|
2
|
-
import { jsx } from 'react/jsx-runtime';
|
|
3
|
-
|
|
4
|
-
// src/provider/ElevasisServiceContext.tsx
|
|
5
|
-
var ElevasisServiceContext = createContext(null);
|
|
6
|
-
function useElevasisServices() {
|
|
7
|
-
const ctx = useContext(ElevasisServiceContext);
|
|
8
|
-
if (!ctx) {
|
|
9
|
-
throw new Error(
|
|
10
|
-
"useElevasisServices must be used within an ElevasisServiceProvider or an ElevasisProvider with apiUrl configured."
|
|
11
|
-
);
|
|
12
|
-
}
|
|
13
|
-
return ctx;
|
|
14
|
-
}
|
|
15
|
-
function ElevasisServiceProvider({
|
|
16
|
-
apiRequest,
|
|
17
|
-
organizationId,
|
|
18
|
-
isReady,
|
|
19
|
-
children
|
|
20
|
-
}) {
|
|
21
|
-
const value = useMemo(
|
|
22
|
-
() => ({ apiRequest, organizationId, isReady }),
|
|
23
|
-
[apiRequest, organizationId, isReady]
|
|
24
|
-
);
|
|
25
|
-
return /* @__PURE__ */ jsx(ElevasisServiceContext.Provider, { value, children });
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export { ElevasisServiceProvider, useElevasisServices };
|
package/dist/chunk-LFYO3MDC.js
DELETED
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { IconUser, IconExternalLink, IconPlug, IconBolt, IconGitBranch, IconBrain } from '@tabler/icons-react';
|
|
2
|
-
|
|
3
|
-
// src/utils/formatDate.ts
|
|
4
|
-
var formatDate = (dateString) => {
|
|
5
|
-
const date = new Date(dateString);
|
|
6
|
-
return date.toLocaleDateString("en-US", {
|
|
7
|
-
year: "numeric",
|
|
8
|
-
month: "long",
|
|
9
|
-
day: "numeric",
|
|
10
|
-
hour: "2-digit",
|
|
11
|
-
minute: "2-digit"
|
|
12
|
-
});
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
// src/utils/validateEmail.ts
|
|
16
|
-
var validateEmail = (email) => {
|
|
17
|
-
return /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)+$/.test(email);
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
// ../core/src/platform/registry/resource-metadata.ts
|
|
21
|
-
var resourceTypeIconNames = {
|
|
22
|
-
agent: "IconBrain",
|
|
23
|
-
workflow: "IconGitBranch",
|
|
24
|
-
trigger: "IconBolt",
|
|
25
|
-
integration: "IconPlug",
|
|
26
|
-
external: "IconExternalLink",
|
|
27
|
-
human: "IconUser"
|
|
28
|
-
};
|
|
29
|
-
var resourceTypeColors = {
|
|
30
|
-
agent: "violet",
|
|
31
|
-
workflow: "blue",
|
|
32
|
-
trigger: "orange",
|
|
33
|
-
integration: "teal",
|
|
34
|
-
external: "gray",
|
|
35
|
-
human: "yellow"
|
|
36
|
-
};
|
|
37
|
-
function getResourceIconName(type) {
|
|
38
|
-
return resourceTypeIconNames[type];
|
|
39
|
-
}
|
|
40
|
-
function getResourceColor(type) {
|
|
41
|
-
return resourceTypeColors[type];
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
// src/utils/resource-icons.tsx
|
|
45
|
-
var iconNameToComponent = {
|
|
46
|
-
IconBrain,
|
|
47
|
-
IconGitBranch,
|
|
48
|
-
IconBolt,
|
|
49
|
-
IconPlug,
|
|
50
|
-
IconExternalLink,
|
|
51
|
-
IconUser
|
|
52
|
-
};
|
|
53
|
-
function getResourceIcon(type) {
|
|
54
|
-
const iconName = getResourceIconName(type);
|
|
55
|
-
return iconNameToComponent[iconName];
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export { formatDate, getResourceColor, getResourceIcon, validateEmail };
|
package/dist/chunk-TIRMFDM4.js
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { getErrorInfo, getErrorTitle, formatErrorMessage } from './chunk-4VGWQ5AN.js';
|
|
2
|
-
import { createContext, useContext } from 'react';
|
|
3
|
-
import { jsx } from 'react/jsx-runtime';
|
|
4
|
-
|
|
5
|
-
var consoleAdapter = {
|
|
6
|
-
success(title, message) {
|
|
7
|
-
console.log(`[Notification][Success] ${title}: ${message}`);
|
|
8
|
-
},
|
|
9
|
-
error(title, message) {
|
|
10
|
-
console.warn(`[Notification][Error] ${title}: ${message}`);
|
|
11
|
-
},
|
|
12
|
-
info(title, message) {
|
|
13
|
-
console.log(`[Notification][Info] ${title}: ${message}`);
|
|
14
|
-
},
|
|
15
|
-
warning(title, message) {
|
|
16
|
-
console.warn(`[Notification][Warning] ${title}: ${message}`);
|
|
17
|
-
},
|
|
18
|
-
apiError(error) {
|
|
19
|
-
const { message, code, requestId, fields, retryAfter } = getErrorInfo(error);
|
|
20
|
-
const title = getErrorTitle(code);
|
|
21
|
-
const formatted = formatErrorMessage(message, requestId, fields, retryAfter);
|
|
22
|
-
console.warn(`[Notification][API Error] ${title}: ${formatted}`);
|
|
23
|
-
}
|
|
24
|
-
};
|
|
25
|
-
var NotificationContext = createContext(consoleAdapter);
|
|
26
|
-
function NotificationProvider({ adapter, children }) {
|
|
27
|
-
return /* @__PURE__ */ jsx(NotificationContext.Provider, { value: adapter, children });
|
|
28
|
-
}
|
|
29
|
-
function useNotificationAdapter() {
|
|
30
|
-
return useContext(NotificationContext);
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export { NotificationProvider, useNotificationAdapter };
|
package/dist/chunk-TYV5NJV2.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
|