@odigos/ui-kit 0.0.161 → 0.0.163
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/CHANGELOG.md +22 -0
- package/lib/chunks/index-53f81cb1.js +3 -0
- package/lib/chunks/{ui-components-b00f42a0.js → ui-components-fabd01fd.js} +125 -123
- package/lib/components/_v2/search/index.d.ts +3 -1
- package/lib/components/_v2/segment/index.d.ts +6 -1
- package/lib/components/_v2/warning-modal/index.d.ts +2 -1
- package/lib/components/input-table/map-columns-to-fields/index.d.ts +1 -1
- package/lib/components/input-table/types.d.ts +1 -1
- package/lib/components/v2.js +1 -1
- package/lib/components.js +1 -1
- package/lib/constants.js +1 -1
- package/lib/containers/_v2/central-connections/source-drawer/index.d.ts +15 -0
- package/lib/containers/data-flow/column/base.d.ts +1 -0
- package/lib/containers/dropdowns/index.d.ts +1 -0
- package/lib/containers/dropdowns/pods-agent-injection-status-dropdown/index.d.ts +16 -0
- package/lib/containers/v2.js +59 -9
- package/lib/containers.js +115 -115
- package/lib/contexts.js +1 -1
- package/lib/functions/get-status-type-from-odigos-health/index.d.ts +2 -2
- package/lib/functions.js +1 -1
- package/lib/hooks.js +1 -1
- package/lib/mock-data/index.d.ts +2 -0
- package/lib/mock-data/snapshot/index.d.ts +5 -0
- package/lib/mock-data/workload/index.d.ts +2 -0
- package/lib/snippets/_v2/cancel-modal/index.d.ts +1 -1
- package/lib/snippets/_v2/delete-modal/index.d.ts +1 -1
- package/lib/snippets.js +1 -1
- package/lib/store/useFilterStore.d.ts +3 -0
- package/lib/store.js +1 -1
- package/lib/theme.js +1 -1
- package/lib/types/actions/index.d.ts +4 -1
- package/lib/types/destinations/index.d.ts +1 -0
- package/lib/types/enum/index.d.ts +21 -0
- package/lib/types/index.d.ts +3 -0
- package/lib/types/instrumentation-rules/index.d.ts +1 -1
- package/lib/types/metrics/index.d.ts +1 -1
- package/lib/types/snapshot/index.d.ts +27 -0
- package/lib/types/sources/index.d.ts +3 -29
- package/lib/types/workload/index.d.ts +23 -0
- package/lib/types.js +1 -1
- package/package.json +1 -1
- package/lib/chunks/index-ddeae825.js +0 -3
package/lib/contexts.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{cX as OdigosProvider,z as useOdigos}from"./chunks/ui-components-
|
|
1
|
+
export{cX as OdigosProvider,z as useOdigos}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const getStatusTypeFromOdigosHealth: (status:
|
|
1
|
+
import { DesiredStateProgress, OtherStatus, StatusType } from '@/types';
|
|
2
|
+
export declare const getStatusTypeFromOdigosHealth: (status: DesiredStateProgress) => StatusType | OtherStatus;
|
package/lib/functions.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{
|
|
1
|
+
export{bz as capitalizeFirstLetter,cB as cleanObjectEmptyStringsValues,bu as compareCondition,bB as deepClone,aD as filterActions,b7 as filterDestinations,b8 as filterDestinationsByStream,b5 as filterSources,b6 as filterSourcesByStream,cC as flattenObjectKeys,aX as formatBytes,ce as formatDuration,k as generateId,ak as getActionIcon,aw as getConditionsBooleans,a$ as getContainersIcons,c8 as getContainersInstrumentedCount,a_ as getDestinationIcon,aK as getEntityIcon,ai as getEntityId,aF as getEntityLabel,cD as getIdFromSseTarget,aZ as getInstrumentationRuleIcon,cE as getMainContainerLanguage,bE as getMetricForEntity,cF as getMonitorIcon,cG as getPlatformIcon,cH as getPlatformLabel,bN as getProgrammingLanguageIcon,cg as getRecursiveValues,cI as getSseTargetFromId,cJ as getStatusColor,q as getStatusFromPodStatus,aB as getStatusIcon,bW as getStatusTypeFromOdigosHealth,cK as getValueForRange,bQ as getWorkloadId,by as getYamlFieldsForDestination,bX as hasUnhealthyInstances,X as isEmpty,cL as isLegalK8sLabel,c9 as isOverTime,c0 as isStringABoolean,cM as isTimeElapsed,cN as isValidVersion,ay as mapConditions,bt as mapDestinationFieldsForDisplay,aW as mapExportedSignals,cO as numbersOnly,c1 as parseBooleanFromString,cP as parseJsonStringToPrettyString,cQ as removeEmptyValuesFromObject,bv as safeJsonParse,cR as safeJsonStringify,aQ as sleep,bf as splitCamelString,cS as stringifyNonStringValues,cT as trimVersion}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
package/lib/hooks.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{ah as useActionFormData,cY as useBodyScroll,
|
|
1
|
+
export{ah as useActionFormData,cY as useBodyScroll,b9 as useClickNode,bR as useClickNotification,b2 as useConnection,b4 as useContainerSize,ca as useCopy,bl as useDataStreamFormData,bx as useDestinationFormData,u as useGenericForm,cZ as useInfiniteScroll,bO as useInstrumentationRuleFormData,aa as useKeyDown,be as useOnClickOutside,ba as usePopup,bk as useSessionStorage,c2 as useSourceFormData,c6 as useSourceSelectionFormData,i as useTimeAgo}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
package/lib/mock-data/index.d.ts
CHANGED
|
@@ -7,6 +7,8 @@ export * from './instrumentation-rules';
|
|
|
7
7
|
export * from './namespaces';
|
|
8
8
|
export * from './pipeline-collectors';
|
|
9
9
|
export * from './service-map';
|
|
10
|
+
export * from './snapshot';
|
|
10
11
|
export * from './sources';
|
|
11
12
|
export * from './tokens';
|
|
12
13
|
export * from './traces';
|
|
14
|
+
export * from './workload';
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type AllClusterSnapshots, type ClusterSnapshot, type NamespaceSnapshot, type WorkloadSnapshot } from '@/types';
|
|
2
|
+
export declare const MOCK_WORKLOAD_SNAPSHOT: WorkloadSnapshot;
|
|
3
|
+
export declare const MOCK_NAMESPACE_SNAPSHOT: NamespaceSnapshot;
|
|
4
|
+
export declare const MOCK_CLUSTER_SNAPSHOT: ClusterSnapshot;
|
|
5
|
+
export declare const MOCK_ALL_CLUSTER_SNAPSHOTS: AllClusterSnapshots;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { type FC } from 'react';
|
|
2
2
|
import { type WarningModalProps } from '@/components/_v2';
|
|
3
|
-
export type CancelModalProps = Pick<WarningModalProps, 'onDeny' | 'onApprove'>;
|
|
3
|
+
export type CancelModalProps = Pick<WarningModalProps, 'isOpen' | 'onClose' | 'onDeny' | 'onApprove'>;
|
|
4
4
|
export declare const CancelModal: FC<CancelModalProps>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type FC } from 'react';
|
|
2
2
|
import { type WarningModalProps } from '@/components/_v2';
|
|
3
|
-
export interface DeleteModalProps extends Pick<WarningModalProps, 'onDeny' | 'onApprove'> {
|
|
3
|
+
export interface DeleteModalProps extends Pick<WarningModalProps, 'isOpen' | 'onClose' | 'onDeny' | 'onApprove'> {
|
|
4
4
|
action?: string;
|
|
5
5
|
target?: string;
|
|
6
6
|
}
|
package/lib/snippets.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{
|
|
1
|
+
export{bq as AddButton,bY as CopyText,bU as EditButton,bT as Flow,c_ as MapItemNode,c$ as NoDataNode,br as NoteBackToSummary,b_ as PodContainer,c3 as SourceContainer}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
|
@@ -8,6 +8,7 @@ export interface FiltersState {
|
|
|
8
8
|
monitors?: DropdownProps['options'];
|
|
9
9
|
languages?: DropdownProps['options'];
|
|
10
10
|
conditions?: DropdownProps['options'];
|
|
11
|
+
podsAgentInjectionStatus?: DropdownProps['options'];
|
|
11
12
|
errors?: DropdownProps['options'];
|
|
12
13
|
onlyErrors?: boolean;
|
|
13
14
|
}
|
|
@@ -28,6 +29,8 @@ interface StoreState {
|
|
|
28
29
|
setLanguages: (metrics: FiltersState['languages']) => void;
|
|
29
30
|
conditions: FiltersState['conditions'];
|
|
30
31
|
setConditions: (conditions: FiltersState['conditions']) => void;
|
|
32
|
+
podsAgentInjectionStatus: FiltersState['podsAgentInjectionStatus'];
|
|
33
|
+
setPodsAgentInjectionStatus: (podsAgentInjectionStatus: FiltersState['podsAgentInjectionStatus']) => void;
|
|
31
34
|
errors: FiltersState['errors'];
|
|
32
35
|
setErrors: (metrics: FiltersState['errors']) => void;
|
|
33
36
|
onlyErrors: FiltersState['onlyErrors'];
|
package/lib/store.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{cW as useActiveNodeStore,
|
|
1
|
+
export{cW as useActiveNodeStore,cd as useDarkMode,b3 as useDataStreamStore,a9 as useDrawerStore,ag as useEntityStore,aC as useFilterStore,aU as useInstrumentStore,ao as useModalStore,a8 as useNotificationStore,a7 as usePendingStore,aT as useSelectedStore,bm as useSetupStore}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
package/lib/theme.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{p as default}from"./chunks/ui-components-
|
|
1
|
+
export{p as default}from"./chunks/ui-components-fabd01fd.js";import"styled-components";import"./icons.js";import"react";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
|
@@ -77,17 +77,20 @@ export interface ActionFields {
|
|
|
77
77
|
export type ActionFormData = Omit<Action, 'id' | 'conditions'>;
|
|
78
78
|
export declare enum K8sAttributesFrom {
|
|
79
79
|
Pod = "pod",
|
|
80
|
-
Namespace = "namespace"
|
|
80
|
+
Namespace = "namespace",
|
|
81
|
+
Node = "node"
|
|
81
82
|
}
|
|
82
83
|
export interface LabelsAttributes {
|
|
83
84
|
labelKey: string;
|
|
84
85
|
attributeKey: string;
|
|
85
86
|
from?: K8sAttributesFrom;
|
|
87
|
+
fromSources?: K8sAttributesFrom[];
|
|
86
88
|
}
|
|
87
89
|
export interface AnnotationsAttributes {
|
|
88
90
|
annotationKey: string;
|
|
89
91
|
attributeKey: string;
|
|
90
92
|
from?: K8sAttributesFrom;
|
|
93
|
+
fromSources?: K8sAttributesFrom[];
|
|
91
94
|
}
|
|
92
95
|
export interface ClusterAttributes {
|
|
93
96
|
attributeName: string;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare enum K8sResourceKind {
|
|
2
|
+
Deployment = "Deployment",
|
|
3
|
+
DaemonSet = "DaemonSet",
|
|
4
|
+
StatefulSet = "StatefulSet",
|
|
5
|
+
CronJob = "CronJob",
|
|
6
|
+
ConfigMap = "ConfigMap",
|
|
7
|
+
Pod = "Pod",
|
|
8
|
+
DeploymentConfig = "DeploymentConfig"
|
|
9
|
+
}
|
|
10
|
+
export declare enum DesiredStateProgress {
|
|
11
|
+
Error = "Error",
|
|
12
|
+
Failure = "Failure",
|
|
13
|
+
Notice = "Notice",
|
|
14
|
+
Pending = "Pending",
|
|
15
|
+
Waiting = "Waiting",
|
|
16
|
+
Unsupported = "Unsupported",
|
|
17
|
+
Disabled = "Disabled",
|
|
18
|
+
Success = "Success",
|
|
19
|
+
Irrelevant = "Irrelevant",
|
|
20
|
+
Unknown = "Unknown"
|
|
21
|
+
}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export * from './data-flow';
|
|
|
4
4
|
export * from './data-streams';
|
|
5
5
|
export * from './describe';
|
|
6
6
|
export * from './destinations';
|
|
7
|
+
export * from './enum';
|
|
7
8
|
export * from './instrumentation-instances';
|
|
8
9
|
export * from './instrumentation-rules';
|
|
9
10
|
export * from './metrics';
|
|
@@ -11,6 +12,8 @@ export * from './namespaces';
|
|
|
11
12
|
export * from './pipeline-collectors';
|
|
12
13
|
export * from './service-map';
|
|
13
14
|
export * from './signals';
|
|
15
|
+
export * from './snapshot';
|
|
14
16
|
export * from './sources';
|
|
15
17
|
export * from './tokens';
|
|
16
18
|
export * from './traces';
|
|
19
|
+
export * from './workload';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export interface WorkloadSnapshot {
|
|
2
|
+
namespace: string;
|
|
3
|
+
name: string;
|
|
4
|
+
kind: string;
|
|
5
|
+
selected: boolean;
|
|
6
|
+
otelServiceName?: string | null;
|
|
7
|
+
healthStatus?: string | null;
|
|
8
|
+
}
|
|
9
|
+
export interface NamespaceSnapshot {
|
|
10
|
+
name: string;
|
|
11
|
+
selected?: boolean | null;
|
|
12
|
+
workloads: WorkloadSnapshot[];
|
|
13
|
+
}
|
|
14
|
+
export interface ClusterSnapshot {
|
|
15
|
+
clusterId: string;
|
|
16
|
+
clusterName: string;
|
|
17
|
+
timestamp: number;
|
|
18
|
+
namespaces: NamespaceSnapshot[];
|
|
19
|
+
}
|
|
20
|
+
export interface AllClusterSnapshots {
|
|
21
|
+
clusters: ClusterSnapshot[];
|
|
22
|
+
totalWorkloads: number;
|
|
23
|
+
totalNamespaces: number;
|
|
24
|
+
lastUpdated: number;
|
|
25
|
+
}
|
|
26
|
+
export type GetClusterSnapshot = (clusterId: string) => Promise<ClusterSnapshot | null>;
|
|
27
|
+
export type GetAllClusterSnapshots = () => Promise<AllClusterSnapshots | null>;
|
|
@@ -1,29 +1,6 @@
|
|
|
1
1
|
import { type Condition, ProgrammingLanguages } from '../common';
|
|
2
|
+
import type { DesiredConditionStatus, WorkloadId } from '../workload';
|
|
2
3
|
import type { NamespaceSelectionFormData, SourceSelectionFormData } from '@/store';
|
|
3
|
-
export declare enum K8sResourceKind {
|
|
4
|
-
Deployment = "Deployment",
|
|
5
|
-
DaemonSet = "DaemonSet",
|
|
6
|
-
StatefulSet = "StatefulSet",
|
|
7
|
-
CronJob = "CronJob",
|
|
8
|
-
DeploymentConfig = "DeploymentConfig"
|
|
9
|
-
}
|
|
10
|
-
export declare enum OdigosHealthStatus {
|
|
11
|
-
Error = "Error",
|
|
12
|
-
Failure = "Failure",
|
|
13
|
-
Notice = "Notice",
|
|
14
|
-
Pending = "Pending",
|
|
15
|
-
Waiting = "Waiting",
|
|
16
|
-
Unsupported = "Unsupported",
|
|
17
|
-
Disabled = "Disabled",
|
|
18
|
-
Success = "Success",
|
|
19
|
-
Irrelevant = "Irrelevant",
|
|
20
|
-
Unknown = "Unknown"
|
|
21
|
-
}
|
|
22
|
-
export interface WorkloadId {
|
|
23
|
-
namespace: string;
|
|
24
|
-
name: string;
|
|
25
|
-
kind: K8sResourceKind | '';
|
|
26
|
-
}
|
|
27
4
|
export interface SourceContainer {
|
|
28
5
|
containerName: string;
|
|
29
6
|
language: ProgrammingLanguages;
|
|
@@ -40,11 +17,8 @@ export interface Source extends WorkloadId {
|
|
|
40
17
|
dataStreamNames: string[];
|
|
41
18
|
containers: SourceContainer[] | null;
|
|
42
19
|
conditions: Condition[] | null;
|
|
43
|
-
workloadOdigosHealthStatus?:
|
|
44
|
-
|
|
45
|
-
reasonEnum: string;
|
|
46
|
-
message: string;
|
|
47
|
-
} | null;
|
|
20
|
+
workloadOdigosHealthStatus?: DesiredConditionStatus | null;
|
|
21
|
+
podsAgentInjectionStatus?: DesiredConditionStatus | null;
|
|
48
22
|
manifestYAML?: string | null;
|
|
49
23
|
}
|
|
50
24
|
export interface SourceFormData {
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { K8sResourceKind, DesiredStateProgress } from '../enum';
|
|
2
|
+
export interface WorkloadId {
|
|
3
|
+
namespace: string;
|
|
4
|
+
name: string;
|
|
5
|
+
kind: K8sResourceKind | '';
|
|
6
|
+
}
|
|
7
|
+
interface WorkloadFilter extends Partial<WorkloadId> {
|
|
8
|
+
markedForInstrumentation?: boolean;
|
|
9
|
+
}
|
|
10
|
+
export interface DesiredConditionStatus {
|
|
11
|
+
name?: string;
|
|
12
|
+
status: DesiredStateProgress;
|
|
13
|
+
reasonEnum?: string | null;
|
|
14
|
+
message: string;
|
|
15
|
+
}
|
|
16
|
+
export interface Workload {
|
|
17
|
+
id: WorkloadId;
|
|
18
|
+
podsAgentInjectionStatus: DesiredConditionStatus;
|
|
19
|
+
}
|
|
20
|
+
export type GetWorkloads = (filter: WorkloadFilter) => Promise<{
|
|
21
|
+
workloads: Workload[];
|
|
22
|
+
}>;
|
|
23
|
+
export {};
|
package/lib/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{
|
|
1
|
+
export{cj as ActionCategory,Q as ActionKeyTypes,G as ActionType,cw as AddNodeTypes,cm as BooleanOperation,bJ as CodeAttributesKeyTypes,an as Crud,bH as CustomInstrumentationsKeyTypes,b0 as DesiredStateProgress,cx as DestinationTypes,cv as EdgeTypes,af as EntityTypes,a0 as FieldTypes,bI as GolangCustomProbe,bF as HeadersCollectionKeyTypes,V as InputTypes,cs as InstallationMethod,bL as InstrumentationRuleType,ct as IntrumentationStatus,bG as JavaCustomProbe,cn as JsonOperation,K as K8sAttributesFrom,c4 as K8sResourceKind,co as ListDirection,bS as NodeTypes,cl as NumberOperation,bs as OtherEntityTypes,aA as OtherStatus,O as OtherStatusType,bK as PayloadCollectionKeyTypes,cr as PlatformType,cA as PodContainerLifecycleStatus,cz as PodContainerStatus,cy as PodPhase,cu as Profile,c5 as ProgrammingLanguages,bw as SignalType,cp as SortDirection,f as StatusType,ck as StringOperation,cq as Tier,y as WorkloadRolloutStatus}from"./chunks/ui-components-fabd01fd.js";import"./icons.js";import"react";import"styled-components";import"zustand";import"javascript-time-ago";import"./chunks/vendor-55cc654c.js";import"react-dom";import"@xyflow/react";import"prism-react-renderer";import"react-error-boundary";import"lottie-react";
|
package/package.json
CHANGED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import o,{useMemo as s}from"react";import t from"styled-components";import{c9 as a,k as e,l as i,m as n,h as r,j as l,ch as c,r as m,aN as p}from"./ui-components-b00f42a0.js";import{VIcon as d,CopyIcon as u,YamlIcon as f}from"../icons.js";const h=t.div`
|
|
2
|
-
padding: 0 12px;
|
|
3
|
-
`,y=({yaml:t})=>{const{clickCopy:y,isCopied:b}=a(),k=s(()=>[{id:e(),type:i.Button,buttonProps:{leftIcon:b?d:u,onClick:()=>y(t||""),disabled:b,size:n.S,variant:r.Secondary}}],[t,b]);return o.createElement(l,{icon:f,title:"YAML",actions:k},o.createElement(h,null,t?o.createElement(c,{code:t,language:"yaml",theme:"duotoneDark"}):o.createElement(m,null,o.createElement(p,{title:"No YAML found",subTitle:"The YAML for this resource is not available"}))))};export{y as Y};
|