@prorobotech/openapi-k8s-toolkit 0.0.1-alpha.50 → 0.0.1-alpha.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.
Files changed (38) hide show
  1. package/dist/openapi-k8s-toolkit.es.js +45069 -20111
  2. package/dist/openapi-k8s-toolkit.es.js.map +1 -1
  3. package/dist/openapi-k8s-toolkit.umd.js +45619 -513
  4. package/dist/openapi-k8s-toolkit.umd.js.map +1 -1
  5. package/dist/types/components/molecules/EnrichedTable/index.d.ts +1 -3
  6. package/dist/types/components/molecules/EnrichedTable/{EnrichedTable.d.ts → organisms/EnrichedTable/EnrichedTable.d.ts} +1 -1
  7. package/dist/types/components/molecules/EnrichedTable/organisms/EnrichedTable/index.d.ts +3 -0
  8. package/dist/types/components/molecules/EnrichedTable/{utils.d.ts → organisms/EnrichedTable/utils.d.ts} +1 -1
  9. package/dist/types/components/molecules/{EnrichedTableProvider → EnrichedTable/organisms/EnrichedTableProvider}/EnrichedTableProvider.d.ts +6 -8
  10. package/dist/types/components/molecules/{EnrichedTableProvider → EnrichedTable/organisms/EnrichedTableProvider}/index.d.ts +0 -1
  11. package/dist/types/components/molecules/EnrichedTable/organisms/index.d.ts +2 -0
  12. package/dist/types/components/molecules/index.d.ts +0 -1
  13. package/dist/types/index.d.ts +1 -1
  14. package/dist/types/localTypes/bff/table.d.ts +33 -0
  15. package/dist/types/localTypes/richTable.d.ts +0 -14
  16. package/dist/types/utils/index.d.ts +0 -2
  17. package/package.json +1 -1
  18. package/dist/types/components/molecules/EnrichedTableProvider/utils.d.ts +0 -25
  19. package/dist/types/utils/parseColumnsOverrides/guards.d.ts +0 -21
  20. package/dist/types/utils/parseColumnsOverrides/index.d.ts +0 -2
  21. package/dist/types/utils/parseColumnsOverrides/parseColumnsOverrides.d.ts +0 -22
  22. package/dist/types/utils/prepareTableMappings/index.d.ts +0 -1
  23. package/dist/types/utils/prepareTableMappings/prepareTableMappings.d.ts +0 -20
  24. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/FilterDropdown/FilterDropdown.d.ts +0 -0
  25. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/FilterDropdown/index.d.ts +0 -0
  26. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/ShortenedTextWithTooltip/ShortenedTextWithTooltip.d.ts +0 -0
  27. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/ShortenedTextWithTooltip/index.d.ts +0 -0
  28. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/ShortenedTextWithTooltip/styled.d.ts +0 -0
  29. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TableComponents/TableComponents.d.ts +0 -0
  30. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TableComponents/index.d.ts +0 -0
  31. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TextAlignContainer/TextAlignContainer.d.ts +0 -0
  32. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TextAlignContainer/index.d.ts +0 -0
  33. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TinyButton/TinyButton.d.ts +0 -0
  34. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TinyButton/index.d.ts +0 -0
  35. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TrimmedTags/TrimmedTags.d.ts +0 -0
  36. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/TrimmedTags/index.d.ts +0 -0
  37. /package/dist/types/components/molecules/EnrichedTable/{atoms → organisms/EnrichedTable/atoms}/index.d.ts +0 -0
  38. /package/dist/types/components/molecules/EnrichedTable/{types.d.ts → organisms/EnrichedTable/types.d.ts} +0 -0
@@ -1,3 +1 @@
1
- export { EnrichedTable } from './EnrichedTable';
2
- export type { TEnrichedTableProps } from './EnrichedTable';
3
- export { getEnrichedColumns, getEnrichedColumnsWithControls } from './utils';
1
+ export * from './organisms';
@@ -1,6 +1,6 @@
1
1
  import React, { FC, ReactNode } from 'react';
2
2
  import { TableProps, TablePaginationConfig } from 'antd';
3
- import { TAdditionalPrinterColumnsColWidths, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsUndefinedValues } from '../../../localTypes/richTable';
3
+ import { TAdditionalPrinterColumnsColWidths, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsUndefinedValues } from '../../../../../localTypes/richTable';
4
4
  export type TEnrichedTableProps = {
5
5
  theme: 'light' | 'dark';
6
6
  baseprefix?: string;
@@ -0,0 +1,3 @@
1
+ export { EnrichedTable } from './EnrichedTable';
2
+ export type { TEnrichedTableProps } from './EnrichedTable';
3
+ export { getEnrichedColumns, getEnrichedColumnsWithControls } from './utils';
@@ -1,7 +1,7 @@
1
1
  import { ReactNode } from 'react';
2
2
  import { NavigateFunction } from 'react-router-dom';
3
3
  import { TableProps } from 'antd';
4
- import { TAdditionalPrinterColumnsColWidths, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsUndefinedValues } from '../../../localTypes/richTable';
4
+ import { TAdditionalPrinterColumnsColWidths, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsUndefinedValues } from '../../../../../localTypes/richTable';
5
5
  export declare const getEnrichedColumns: ({ columns, additionalPrinterColumnsUndefinedValues, additionalPrinterColumnsTrimLengths, additionalPrinterColumnsColWidths, }: {
6
6
  columns: TableProps['columns'];
7
7
  additionalPrinterColumnsUndefinedValues?: TAdditionalPrinterColumnsUndefinedValues | undefined;
@@ -1,8 +1,9 @@
1
1
  import React, { FC, ReactNode } from 'react';
2
2
  import { TablePaginationConfig } from 'antd';
3
- import { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsColWidths } from '../../../localTypes/richTable';
4
- import { TJSON } from '../../../localTypes/JSON';
3
+ import { TJSON } from '../../../../../localTypes/JSON';
4
+ import { TAdditionalPrinterColumns } from '../../../../../localTypes/richTable';
5
5
  export type TEnrichedTableProviderProps = {
6
+ cluster: string;
6
7
  theme: 'light' | 'dark';
7
8
  baseprefix?: string;
8
9
  dataItems: TJSON[];
@@ -21,12 +22,9 @@ export type TEnrichedTableProviderProps = {
21
22
  canDelete?: boolean;
22
23
  };
23
24
  };
24
- additionalPrinterColumns?: TAdditionalPrinterColumns;
25
- pathToNavigate?: string;
26
- recordKeysForNavigation?: string[];
27
- additionalPrinterColumnsUndefinedValues?: TAdditionalPrinterColumnsUndefinedValues;
28
- additionalPrinterColumnsTrimLengths?: TAdditionalPrinterColumnsTrimLengths;
29
- additionalPrinterColumnsColWidths?: TAdditionalPrinterColumnsColWidths;
25
+ customizationId?: string;
26
+ tableMappingsReplaceValues?: Record<string, string | undefined>;
27
+ forceDefaultAdditionalPrinterColumns?: TAdditionalPrinterColumns;
30
28
  selectData?: {
31
29
  onChange: (selectedRowKeys: React.Key[], selectedRowsData: {
32
30
  name: string;
@@ -1,3 +1,2 @@
1
1
  export { EnrichedTableProvider } from './EnrichedTableProvider';
2
2
  export type { TEnrichedTableProviderProps } from './EnrichedTableProvider';
3
- export { prepareDataForEnrichedColumns } from './utils';
@@ -0,0 +1,2 @@
1
+ export * from './EnrichedTable';
2
+ export * from './EnrichedTableProvider';
@@ -1,7 +1,6 @@
1
1
  export * from './ManageableBreadcrumbs';
2
2
  export * from './ManageableSidebar';
3
3
  export * from './EnrichedTable';
4
- export * from './EnrichedTableProvider';
5
4
  export * from './BlackholeForm';
6
5
  export * from './MarketPlace';
7
6
  export * from './ProjectInfoCard';
@@ -30,6 +30,6 @@ export type { TFormPrefill, TRangeInputCustomValue, TRangeInputCustomValuesBlock
30
30
  export type { TJSON } from './localTypes/JSON';
31
31
  export type { TApiGroupList, TApiGroupResourceTypeList, TBuiltinResourceTypeList, TSingleResource, TBuiltinResources, TApiResources, TCrdResources, TCRD, } from './localTypes/k8s';
32
32
  export type { TMarketPlacePanel, TMarketPlacePanelResource, TMarketPlacePanelResponse } from './localTypes/marketplace';
33
- export type { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsColWidths, TTableMappingData, TTableMappingResource, TTableMappingResponse, } from './localTypes/richTable';
33
+ export type { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsColWidths, } from './localTypes/richTable';
34
34
  export type { TFilterIfApiInstanceNamespaceScopedReq, TFilterIfApiInstanceNamespaceScopedRes, TFilterIfBuiltInInstanceNamespaceScopedReq, TFilterIfBuiltInInstanceNamespaceScopedRes, } from './localTypes/bff/scopes';
35
35
  export type { TGetDerefedSwaggerRes } from './localTypes/bff/swagger';
@@ -0,0 +1,33 @@
1
+ import { TableProps } from 'antd';
2
+ import { TJSON } from '../JSON';
3
+ import { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsColWidths } from '../richTable';
4
+ export type TPrepareTableReq = {
5
+ customizationId?: string;
6
+ tableMappingsReplaceValues?: Record<string, string | undefined>;
7
+ forceDefaultAdditionalPrinterColumns?: TAdditionalPrinterColumns;
8
+ dataItems: TJSON[];
9
+ resourceSchema?: TJSON;
10
+ dataForControls?: {
11
+ cluster: string;
12
+ syntheticProject?: string;
13
+ pathPrefix: string;
14
+ apiVersion: string;
15
+ typeName: string;
16
+ backlink: string;
17
+ deletePathPrefix: string;
18
+ onDeleteHandle: (name: string, endpoint: string) => void;
19
+ permissions: {
20
+ canUpdate?: boolean;
21
+ canDelete?: boolean;
22
+ };
23
+ };
24
+ };
25
+ export type TPrepareTableRes = {
26
+ dataSource: TableProps['dataSource'];
27
+ columns: TableProps['columns'];
28
+ additionalPrinterColumnsUndefinedValues?: TAdditionalPrinterColumnsUndefinedValues;
29
+ additionalPrinterColumnsTrimLengths?: TAdditionalPrinterColumnsTrimLengths;
30
+ additionalPrinterColumnsColWidths?: TAdditionalPrinterColumnsColWidths;
31
+ pathToNavigate?: string;
32
+ recordKeysForNavigation?: string[];
33
+ };
@@ -15,17 +15,3 @@ export type TAdditionalPrinterColumnsColWidths = {
15
15
  key: string;
16
16
  value: string;
17
17
  }[];
18
- export type TTableMappingData = {
19
- pathToMatch: string;
20
- pathToNavigate: string;
21
- keysToParse: string[];
22
- };
23
- export type TTableMappingResource = {
24
- apiVersion: string;
25
- kind: string;
26
- spec: TTableMappingData;
27
- } & unknown;
28
- export type TTableMappingResponse = {
29
- apiVersion: string;
30
- items: TTableMappingResource[];
31
- };
@@ -8,7 +8,5 @@ export * from './getAllPathsFromObj';
8
8
  export * from './getPrefixSubArrays';
9
9
  export * from './groupsToTreeData';
10
10
  export * from './getGroupsByCategory';
11
- export * from './prepareTableMappings';
12
- export * from './parseColumnsOverrides';
13
11
  export * from './createContextFactory';
14
12
  export * from './prepareUrlsToFetchForDynamicRenderer';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prorobotech/openapi-k8s-toolkit",
3
- "version": "0.0.1-alpha.50",
3
+ "version": "0.0.1-alpha.52",
4
4
  "description": "ProRobotech OpenAPI k8s tools",
5
5
  "main": "dist/openapi-k8s-toolkit.cjs.js",
6
6
  "module": "dist/openapi-k8s-toolkit.es.js",
@@ -1,25 +0,0 @@
1
- import { TableProps } from 'antd';
2
- import { TJSON } from '../../../localTypes/JSON';
3
- import { TAdditionalPrinterColumns } from '../../../localTypes/richTable';
4
- export declare const prepareDataForEnrichedColumns: ({ dataItems, resourceSchema, dataForControls, additionalPrinterColumns, }: {
5
- dataItems: TJSON[];
6
- resourceSchema?: TJSON | undefined;
7
- dataForControls?: {
8
- cluster: string;
9
- syntheticProject?: string | undefined;
10
- pathPrefix: string;
11
- apiVersion: string;
12
- typeName: string;
13
- backlink: string;
14
- deletePathPrefix: string;
15
- onDeleteHandle: (name: string, endpoint: string) => void;
16
- permissions: {
17
- canUpdate?: boolean;
18
- canDelete?: boolean;
19
- };
20
- } | undefined;
21
- additionalPrinterColumns?: TAdditionalPrinterColumns | undefined;
22
- }) => {
23
- dataSource: TableProps['dataSource'];
24
- columns: TableProps['columns'];
25
- };
@@ -1,21 +0,0 @@
1
- import { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsTrimLengths, TAdditionalPrinterColumnsColWidths } from '../../localTypes/richTable';
2
- export declare const isWithAdditionalPrinterColumns: (x: any) => x is {
3
- spec: {
4
- additionalPrinterColumns: TAdditionalPrinterColumns;
5
- };
6
- };
7
- export declare const isWithAdditionalPrinterColumnsUndefinedValues: (x: any) => x is {
8
- spec: {
9
- additionalPrinterColumnsUndefinedValues: TAdditionalPrinterColumnsUndefinedValues;
10
- };
11
- };
12
- export declare const isWithAdditionalPrinterColumnsTrimLengths: (x: any) => x is {
13
- spec: {
14
- additionalPrinterColumnsTrimLengths: TAdditionalPrinterColumnsTrimLengths;
15
- };
16
- };
17
- export declare const isWithAdditionalPrinterColumnsColWidths: (x: any) => x is {
18
- spec: {
19
- additionalPrinterColumnsColWidths: TAdditionalPrinterColumnsColWidths;
20
- };
21
- };
@@ -1,2 +0,0 @@
1
- export * from './parseColumnsOverrides';
2
- export * from './guards';
@@ -1,22 +0,0 @@
1
- import { TCrdResources } from '../../localTypes/k8s';
2
- import { TAdditionalPrinterColumns, TAdditionalPrinterColumnsUndefinedValues, TAdditionalPrinterColumnsColWidths, TAdditionalPrinterColumnsTrimLengths } from '../../localTypes/richTable';
3
- export declare const parseCustomOverrides: ({ columnsOverridesData, overrideType, }: {
4
- columnsOverridesData?: {
5
- kind: string;
6
- apiVersion: string;
7
- metadata: {
8
- managedFields?: any;
9
- };
10
- items: import("../..").TJSON[];
11
- status?: {
12
- allowed?: boolean | undefined;
13
- reason?: string | undefined;
14
- } | undefined;
15
- } | undefined;
16
- overrideType: string;
17
- }) => {
18
- ensuredCustomOverrides?: TAdditionalPrinterColumns | undefined;
19
- ensuredCustomOverridesUndefinedValues?: TAdditionalPrinterColumnsUndefinedValues | undefined;
20
- ensuredCustomOverridesTrimLengths?: TAdditionalPrinterColumnsTrimLengths | undefined;
21
- ensuredCustomOverridesColWidths?: TAdditionalPrinterColumnsColWidths | undefined;
22
- };
@@ -1 +0,0 @@
1
- export * from './prepareTableMappings';
@@ -1,20 +0,0 @@
1
- import { TTableMappingData } from '../../localTypes/richTable';
2
- export declare const prepareTableMappings: ({ data, clusterName, projectName, instanceName, namespace, syntheticProject, entryType, apiGroup, apiVersion, typeName, entryName, apiExtensionVersion, crdName, pathname, }: {
3
- data: Partial<TTableMappingData>[];
4
- clusterName?: string | undefined;
5
- projectName?: string | undefined;
6
- instanceName?: string | undefined;
7
- namespace?: string | undefined;
8
- syntheticProject?: string | undefined;
9
- entryType?: string | undefined;
10
- apiGroup?: string | undefined;
11
- apiVersion?: string | undefined;
12
- typeName?: string | undefined;
13
- entryName?: string | undefined;
14
- apiExtensionVersion?: string | undefined;
15
- crdName?: string | undefined;
16
- pathname: string;
17
- }) => {
18
- pathToNavigate?: string;
19
- keysToParse?: string[];
20
- } | undefined;