@odigos/ui-kit 0.0.231 → 0.0.233
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 +29 -0
- package/lib/chunks/index-BaKzgedB.js +77 -0
- package/lib/chunks/{index-tFZXUKvO.js → index-D65aqUr3.js} +1 -1
- package/lib/chunks/index-Di5tcvgi.js +145 -0
- package/lib/chunks/ui-components-DD1EWBzE.js +2696 -0
- package/lib/components/_v2/cards/section-card/index.d.ts +11 -0
- package/lib/components/_v2/drop-down/index.d.ts +1 -1
- package/lib/components/_v2/modal/index.d.ts +6 -0
- package/lib/components/_v2/search/index.d.ts +2 -0
- package/lib/components/_v2/segment/index.d.ts +1 -0
- package/lib/components/_v2/typography/index.d.ts +20 -1
- package/lib/components/_v2/warning-modal/index.d.ts +5 -5
- package/lib/components/v2.js +1 -1
- package/lib/components.js +1 -1
- package/lib/constants/sampling/index.d.ts +74 -0
- package/lib/constants/strings/index.d.ts +6 -0
- package/lib/constants.js +1 -1
- package/lib/containers/_v2/_forms/data-stream-form/index.d.ts +6 -0
- package/lib/containers/_v2/_forms/data-stream-form/merge-warning.d.ts +11 -0
- package/lib/containers/_v2/_forms/index.d.ts +1 -0
- package/lib/containers/_v2/_modals/add-data-stream-modal/index.d.ts +15 -0
- package/lib/containers/_v2/_modals/edit-data-stream-modal/index.d.ts +15 -0
- package/lib/containers/_v2/_modals/index.d.ts +3 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/chrome.d.ts +8 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/footer.d.ts +13 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/header.d.ts +6 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/index.d.ts +8 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/info-card.d.ts +7 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/lists.d.ts +11 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/primary-banner.d.ts +4 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/section.d.ts +3 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/common/sub-title.d.ts +4 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/index.d.ts +4 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/preset-row.d.ts +19 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-advanced.d.ts +7 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-drop-list.d.ts +9 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-keep-list.d.ts +19 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-noisy.d.ts +8 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-strategy.d.ts +10 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-success.d.ts +5 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/steps/step-welcome.d.ts +6 -0
- package/lib/containers/_v2/_modals/sampling-onboarding-modal/types.d.ts +29 -0
- package/lib/containers/_v2/index.d.ts +2 -0
- package/lib/containers/_v2/overview/columns/column/empty-add.d.ts +7 -0
- package/lib/containers/_v2/overview/columns/column/head.d.ts +14 -0
- package/lib/containers/_v2/overview/columns/column/index.d.ts +12 -0
- package/lib/containers/_v2/overview/columns/column/list-item.d.ts +17 -0
- package/lib/containers/_v2/overview/columns/column/namespace-divider.d.ts +7 -0
- package/lib/containers/_v2/overview/columns/column/source-visual-state.d.ts +9 -0
- package/lib/containers/_v2/overview/columns/index.d.ts +11 -0
- package/lib/containers/_v2/overview/data-stream-select/index.d.ts +12 -0
- package/lib/containers/_v2/overview/drawers/index.d.ts +31 -0
- package/lib/containers/_v2/overview/filters/index.d.ts +2 -0
- package/lib/containers/_v2/overview/index.d.ts +14 -0
- package/lib/containers/_v2/overview/multi-source-control/index.d.ts +7 -0
- package/lib/containers/_v2/overview/search/builder.d.ts +25 -0
- package/lib/containers/_v2/overview/search/index.d.ts +7 -0
- package/lib/containers/_v2/sampling-rules/types.d.ts +8 -8
- package/lib/containers/source-drawer/index.d.ts +2 -2
- package/lib/containers/v2.js +492 -33
- package/lib/containers.js +122 -198
- package/lib/contexts/data-stream-form-context.d.ts +60 -0
- package/lib/contexts/index.d.ts +1 -0
- package/lib/contexts.js +1 -1
- package/lib/functions.js +1 -1
- package/lib/hooks/useOnClickOutside.d.ts +1 -0
- package/lib/hooks.js +1 -1
- package/lib/icons/common/index.d.ts +1 -0
- package/lib/icons/common/star-icon/index.d.ts +2 -0
- package/lib/icons.js +1 -1
- package/lib/mock-data/index.d.ts +1 -0
- package/lib/mock-data/sources/index.d.ts +1 -0
- package/lib/snippets/_v2/cancel-modal/index.d.ts +4 -1
- package/lib/snippets/_v2/delete-modal/index.d.ts +3 -1
- package/lib/snippets/_v2/rich-title/index.d.ts +1 -0
- package/lib/snippets/v2.js +1 -1
- package/lib/snippets.js +1 -1
- package/lib/store.js +1 -1
- package/lib/theme/palettes/index.d.ts +10 -0
- package/lib/theme.js +1 -1
- package/lib/types/actions/index.d.ts +2 -0
- package/lib/types/config/index.d.ts +2 -0
- package/lib/types/destinations/index.d.ts +1 -0
- package/lib/types/instrumentation-rules/index.d.ts +2 -0
- package/lib/types/sources/index.d.ts +44 -0
- package/lib/types.js +1 -1
- package/lib/visuals/index.d.ts +1 -0
- package/lib/visuals/visual-purple-rings/index.d.ts +7 -0
- package/lib/visuals.js +1 -1
- package/package.json +11 -11
- package/lib/chunks/index-DAOWyONO.js +0 -145
- package/lib/chunks/ui-components-CvK0mvVN.js +0 -2659
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type Action, type Destination, EntityTypes, type InstrumentationRule, type Source, StatusType, type SVG, type WorkloadId } from '@/types';
|
|
3
|
+
export interface ListItemProps {
|
|
4
|
+
entityId: string | WorkloadId;
|
|
5
|
+
entityType: EntityTypes;
|
|
6
|
+
title: string;
|
|
7
|
+
status?: StatusType;
|
|
8
|
+
faded?: boolean;
|
|
9
|
+
tooltip?: string;
|
|
10
|
+
throughput?: string;
|
|
11
|
+
icon?: SVG;
|
|
12
|
+
icons?: SVG[];
|
|
13
|
+
iconSrc?: string;
|
|
14
|
+
isActive?: boolean;
|
|
15
|
+
raw: Source | Destination | Action | InstrumentationRule;
|
|
16
|
+
}
|
|
17
|
+
export declare const ListItem: FC<ListItemProps>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type Source, StatusType } from '@/types';
|
|
2
|
+
interface SourceVisualState {
|
|
3
|
+
status?: StatusType;
|
|
4
|
+
faded: boolean;
|
|
5
|
+
tooltip?: string;
|
|
6
|
+
displaySource: Source;
|
|
7
|
+
}
|
|
8
|
+
export declare function getSourceVisualState(source: Source): SourceVisualState;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type CSSProperties, type FC } from 'react';
|
|
2
|
+
import { type Metrics } from '@/types';
|
|
3
|
+
export interface ColumnsProps {
|
|
4
|
+
height?: CSSProperties['height'];
|
|
5
|
+
metrics: Metrics;
|
|
6
|
+
refetchSources: () => void;
|
|
7
|
+
refetchDestinations: () => void;
|
|
8
|
+
refetchActions: () => void;
|
|
9
|
+
refetchInstrumentationRules: () => void;
|
|
10
|
+
}
|
|
11
|
+
export declare const Columns: FC<ColumnsProps>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type DataStream } from '@/types';
|
|
3
|
+
export interface DataStreamSelectProps {
|
|
4
|
+
updateDataStream: (dataStreamName: string, dataStream: DataStream) => void | Promise<void>;
|
|
5
|
+
deleteDataStream: (dataStreamName: string) => void | Promise<void>;
|
|
6
|
+
/**
|
|
7
|
+
* Optional. When omitted, "create" just appends to the local data-streams store
|
|
8
|
+
* and selects the new stream. Provide this when there's a remote create mutation.
|
|
9
|
+
*/
|
|
10
|
+
createDataStream?: (dataStream: DataStream) => void | Promise<void>;
|
|
11
|
+
}
|
|
12
|
+
export declare const DataStreamSelect: FC<DataStreamSelectProps>;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type CreateActionFunc, type CreateDestinationFunc, type CreateInstrumentationRuleFunc, type DeleteActionFunc, type DeleteDestinationFunc, type DeleteInstrumentationRuleFunc, type EffectiveConfig, type EnableProfilingFunc, type FetchNamespacesWithWorkloads, type FetchPeerSourcesFunc, type FetchProfilingSlotsFunc, type FetchSourceByIdFunc, type FetchSourceDescribeFunc, type FetchSourceLibrariesFunc, type FetchSourceProfilingFunc, type GetDestinationCategoriesFunc, type GetPotentialDestinationsFunc, type PersistSourcesFunc, type RecoverFromRollbackFunc, type RestartPodFunc, type RestartWorkloadsFunc, type TestConnectionFunc, type UpdateActionFunc, type UpdateDestinationFunc, type UpdateInstrumentationRuleFunc, type UpdateSourceFunc } from '@/types';
|
|
3
|
+
export interface DrawersProps {
|
|
4
|
+
effectiveConfig: EffectiveConfig;
|
|
5
|
+
fetchNamespacesWithWorkloads: FetchNamespacesWithWorkloads;
|
|
6
|
+
persistSources: PersistSourcesFunc;
|
|
7
|
+
restartWorkloads: RestartWorkloadsFunc;
|
|
8
|
+
restartPod: RestartPodFunc;
|
|
9
|
+
recoverFromRollback: RecoverFromRollbackFunc;
|
|
10
|
+
updateSource: UpdateSourceFunc;
|
|
11
|
+
fetchSourceById: FetchSourceByIdFunc;
|
|
12
|
+
fetchSourceDescribe: FetchSourceDescribeFunc;
|
|
13
|
+
fetchSourceLibraries: FetchSourceLibrariesFunc;
|
|
14
|
+
fetchPeerSources: FetchPeerSourcesFunc;
|
|
15
|
+
enableProfiling: EnableProfilingFunc;
|
|
16
|
+
fetchProfilingSlots: FetchProfilingSlotsFunc;
|
|
17
|
+
fetchSourceProfiling: FetchSourceProfilingFunc;
|
|
18
|
+
getDestinationCategories: GetDestinationCategoriesFunc;
|
|
19
|
+
getPotentialDestinations: GetPotentialDestinationsFunc;
|
|
20
|
+
testConnection: TestConnectionFunc;
|
|
21
|
+
createDestination: CreateDestinationFunc;
|
|
22
|
+
updateDestination: UpdateDestinationFunc;
|
|
23
|
+
deleteDestination: DeleteDestinationFunc;
|
|
24
|
+
createInstrumentationRule: CreateInstrumentationRuleFunc;
|
|
25
|
+
updateInstrumentationRule: UpdateInstrumentationRuleFunc;
|
|
26
|
+
deleteInstrumentationRule: DeleteInstrumentationRuleFunc;
|
|
27
|
+
createAction: CreateActionFunc;
|
|
28
|
+
updateAction: UpdateActionFunc;
|
|
29
|
+
deleteAction: DeleteActionFunc;
|
|
30
|
+
}
|
|
31
|
+
export declare const Drawers: FC<DrawersProps>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type ColumnsProps } from './columns';
|
|
3
|
+
import { type DrawersProps } from './drawers';
|
|
4
|
+
import { CSSProperties } from 'styled-components';
|
|
5
|
+
import { type DataStreamSelectProps } from './data-stream-select';
|
|
6
|
+
export interface OverviewProps extends DrawersProps, DataStreamSelectProps {
|
|
7
|
+
columnsMaxHeight: CSSProperties['maxHeight'];
|
|
8
|
+
metrics: ColumnsProps['metrics'];
|
|
9
|
+
refetchSources: ColumnsProps['refetchSources'];
|
|
10
|
+
refetchDestinations: ColumnsProps['refetchDestinations'];
|
|
11
|
+
refetchActions: ColumnsProps['refetchActions'];
|
|
12
|
+
refetchInstrumentationRules: ColumnsProps['refetchInstrumentationRules'];
|
|
13
|
+
}
|
|
14
|
+
export declare const Overview: FC<OverviewProps>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type PersistSourcesFunc, type RestartWorkloadsFunc } from '@/types';
|
|
3
|
+
export interface MultiSourceControlProps {
|
|
4
|
+
restartWorkloads: RestartWorkloadsFunc;
|
|
5
|
+
persistSources: PersistSourcesFunc;
|
|
6
|
+
}
|
|
7
|
+
export declare const MultiSourceControl: FC<MultiSourceControlProps>;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { type Action, type Destination, EntityTypes, type InstrumentationRule, type Source } from '@/types';
|
|
2
|
+
export type Category = 'all' | EntityTypes;
|
|
3
|
+
interface Params {
|
|
4
|
+
searchText: string;
|
|
5
|
+
selectedCategory: Category;
|
|
6
|
+
sources: Source[];
|
|
7
|
+
destinations: Destination[];
|
|
8
|
+
actions: Action[];
|
|
9
|
+
instrumentationRules: InstrumentationRule[];
|
|
10
|
+
}
|
|
11
|
+
export declare const buildSearchResults: ({ instrumentationRules, sources, actions, destinations, searchText, selectedCategory }: Params) => {
|
|
12
|
+
categories: {
|
|
13
|
+
category: Category;
|
|
14
|
+
label: string;
|
|
15
|
+
count: number;
|
|
16
|
+
entities: InstrumentationRule[] | Source[] | Action[] | Destination[];
|
|
17
|
+
}[];
|
|
18
|
+
searchResults: {
|
|
19
|
+
entities: Action[] | Destination[] | Source[] | InstrumentationRule[];
|
|
20
|
+
category: Category;
|
|
21
|
+
label: string;
|
|
22
|
+
count: number;
|
|
23
|
+
}[];
|
|
24
|
+
};
|
|
25
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
export interface OverviewSearchProps {
|
|
3
|
+
width?: string;
|
|
4
|
+
/** When true, the results popup is suppressed (e.g. when the parent already renders results inline). */
|
|
5
|
+
preventPopup?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare const OverviewSearch: FC<OverviewSearchProps>;
|
|
@@ -19,13 +19,13 @@ export interface SamplingRulesProps {
|
|
|
19
19
|
loading: boolean;
|
|
20
20
|
tableRowsMaxHeight: CSSProperties['maxHeight'];
|
|
21
21
|
fetchSamplingRules: () => void;
|
|
22
|
-
createNoisyOperationRule: (samplingId: string, rule: NoisyOperationRuleInput) => void;
|
|
23
|
-
updateNoisyOperationRule: (samplingId: string, ruleId: string, rule: NoisyOperationRuleInput) => void;
|
|
24
|
-
createHighlyRelevantOperationRule: (samplingId: string, rule: HighlyRelevantOperationRuleInput) => void;
|
|
25
|
-
updateHighlyRelevantOperationRule: (samplingId: string, ruleId: string, rule: HighlyRelevantOperationRuleInput) => void;
|
|
26
|
-
createCostReductionRule: (samplingId: string, rule: CostReductionRuleInput) => void;
|
|
27
|
-
updateCostReductionRule: (samplingId: string, ruleId: string, rule: CostReductionRuleInput) => void;
|
|
28
|
-
deleteSamplingRule: (samplingId: string, ruleId: string, category: SamplingRuleCategory) => void;
|
|
29
|
-
updateK8sHealthProbesConfig: (enabled: boolean, keepPercentage: number) => void;
|
|
22
|
+
createNoisyOperationRule: (samplingId: string, rule: NoisyOperationRuleInput) => Promise<void> | void;
|
|
23
|
+
updateNoisyOperationRule: (samplingId: string, ruleId: string, rule: NoisyOperationRuleInput) => Promise<void> | void;
|
|
24
|
+
createHighlyRelevantOperationRule: (samplingId: string, rule: HighlyRelevantOperationRuleInput) => Promise<void> | void;
|
|
25
|
+
updateHighlyRelevantOperationRule: (samplingId: string, ruleId: string, rule: HighlyRelevantOperationRuleInput) => Promise<void> | void;
|
|
26
|
+
createCostReductionRule: (samplingId: string, rule: CostReductionRuleInput) => Promise<void> | void;
|
|
27
|
+
updateCostReductionRule: (samplingId: string, ruleId: string, rule: CostReductionRuleInput) => Promise<void> | void;
|
|
28
|
+
deleteSamplingRule: (samplingId: string, ruleId: string, category: SamplingRuleCategory) => Promise<void> | void;
|
|
29
|
+
updateK8sHealthProbesConfig: (enabled: boolean, keepPercentage: number) => Promise<void> | void;
|
|
30
30
|
docsUrl?: string;
|
|
31
31
|
}
|
|
@@ -3,9 +3,9 @@ import { type ProfilingProps } from './profiling';
|
|
|
3
3
|
import { type DescribeProps } from './describe';
|
|
4
4
|
import { type LibrariesProps } from './libraries';
|
|
5
5
|
import { type PeerSourcesProps } from './peers';
|
|
6
|
-
import { type
|
|
6
|
+
import { type PersistSourcesFunc, type SourceFormData, type WorkloadId, type Source } from '@/types';
|
|
7
7
|
interface SourceDrawerProps {
|
|
8
|
-
persistSources:
|
|
8
|
+
persistSources: PersistSourcesFunc;
|
|
9
9
|
updateSource: (sourceId: WorkloadId, payload: SourceFormData) => Promise<void>;
|
|
10
10
|
restartWorkloads: (sourceIds: WorkloadId[]) => Promise<void>;
|
|
11
11
|
restartPod: (namespace: string, name: string) => Promise<void>;
|