@backstage/plugin-catalog-react 1.1.2-next.1 → 1.1.2-next.2
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 +49 -0
- package/alpha/package.json +1 -1
- package/dist/index.alpha.d.ts +29 -0
- package/dist/index.beta.d.ts +29 -0
- package/dist/index.d.ts +29 -0
- package/dist/index.esm.js +121 -40
- package/dist/index.esm.js.map +1 -1
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,54 @@
|
|
|
1
1
|
# @backstage/plugin-catalog-react
|
|
2
2
|
|
|
3
|
+
## 1.1.2-next.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- be26d95141: Added new `EntityProcessingStatusPicker` that will filter for entities with orphans and/or errors.
|
|
8
|
+
|
|
9
|
+
If you are using the default Catalog page this picker will be added automatically. For those who have customized their Catalog page you'll need to add this manually by doing something like this:
|
|
10
|
+
|
|
11
|
+
```diff
|
|
12
|
+
...
|
|
13
|
+
import {
|
|
14
|
+
CatalogFilterLayout,
|
|
15
|
+
EntityTypePicker,
|
|
16
|
+
UserListPicker,
|
|
17
|
+
EntityTagPicker
|
|
18
|
+
+ EntityProcessingStatusPicker,
|
|
19
|
+
} from '@backstage/plugin-catalog-react';
|
|
20
|
+
...
|
|
21
|
+
export const CustomCatalogPage = ({
|
|
22
|
+
columns,
|
|
23
|
+
actions,
|
|
24
|
+
initiallySelectedFilter = 'owned',
|
|
25
|
+
}: CatalogPageProps) => {
|
|
26
|
+
return (
|
|
27
|
+
...
|
|
28
|
+
<EntityListProvider>
|
|
29
|
+
<CatalogFilterLayout>
|
|
30
|
+
<CatalogFilterLayout.Filters>
|
|
31
|
+
<EntityKindPicker initialFilter="component" hidden />
|
|
32
|
+
<EntityTypePicker />
|
|
33
|
+
<UserListPicker initialFilter={initiallySelectedFilter} />
|
|
34
|
+
<EntityTagPicker />
|
|
35
|
+
+ <EntityProcessingStatusPicker />
|
|
36
|
+
<CatalogFilterLayout.Filters>
|
|
37
|
+
<CatalogFilterLayout.Content>
|
|
38
|
+
<CatalogTable columns={columns} actions={actions} />
|
|
39
|
+
</CatalogFilterLayout.Content>
|
|
40
|
+
</CatalogFilterLayout>
|
|
41
|
+
</EntityListProvider>
|
|
42
|
+
...
|
|
43
|
+
};
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
- Updated dependencies
|
|
47
|
+
- @backstage/core-components@0.10.0-next.2
|
|
48
|
+
- @backstage/catalog-model@1.1.0-next.2
|
|
49
|
+
- @backstage/theme@0.2.16-next.1
|
|
50
|
+
- @backstage/integration@1.2.2-next.2
|
|
51
|
+
|
|
3
52
|
## 1.1.2-next.1
|
|
4
53
|
|
|
5
54
|
### Patch Changes
|
package/alpha/package.json
CHANGED
package/dist/index.alpha.d.ts
CHANGED
|
@@ -83,6 +83,7 @@ export declare type CatalogReactComponentsNameToClassKey = {
|
|
|
83
83
|
CatalogReactEntitySearchBar: CatalogReactEntitySearchBarClassKey;
|
|
84
84
|
CatalogReactEntityTagPicker: CatalogReactEntityTagPickerClassKey;
|
|
85
85
|
CatalogReactEntityOwnerPicker: CatalogReactEntityOwnerPickerClassKey;
|
|
86
|
+
CatalogReactEntityProcessingStatusPicker: CatalogReactEntityProcessingStatusPickerClassKey;
|
|
86
87
|
};
|
|
87
88
|
|
|
88
89
|
/** @public */
|
|
@@ -91,6 +92,9 @@ export declare type CatalogReactEntityLifecyclePickerClassKey = 'input';
|
|
|
91
92
|
/** @public */
|
|
92
93
|
export declare type CatalogReactEntityOwnerPickerClassKey = 'input';
|
|
93
94
|
|
|
95
|
+
/** @public */
|
|
96
|
+
export declare type CatalogReactEntityProcessingStatusPickerClassKey = 'input';
|
|
97
|
+
|
|
94
98
|
/** @public */
|
|
95
99
|
export declare type CatalogReactEntitySearchBarClassKey = 'searchToolbar' | 'input';
|
|
96
100
|
|
|
@@ -130,8 +134,20 @@ export declare type DefaultEntityFilters = {
|
|
|
130
134
|
lifecycles?: EntityLifecycleFilter;
|
|
131
135
|
tags?: EntityTagFilter;
|
|
132
136
|
text?: EntityTextFilter;
|
|
137
|
+
orphan?: EntityOrphanFilter;
|
|
138
|
+
error?: EntityErrorFilter;
|
|
133
139
|
};
|
|
134
140
|
|
|
141
|
+
/**
|
|
142
|
+
* Filters entities based on if it has errors or not.
|
|
143
|
+
* @public
|
|
144
|
+
*/
|
|
145
|
+
export declare class EntityErrorFilter implements EntityFilter {
|
|
146
|
+
readonly value: boolean;
|
|
147
|
+
constructor(value: boolean);
|
|
148
|
+
filterEntity(entity: Entity): boolean;
|
|
149
|
+
}
|
|
150
|
+
|
|
135
151
|
/** @public */
|
|
136
152
|
export declare type EntityFilter = {
|
|
137
153
|
/**
|
|
@@ -241,6 +257,16 @@ export declare type EntityLoadingStatus<TEntity extends Entity = Entity> = {
|
|
|
241
257
|
refresh?: VoidFunction;
|
|
242
258
|
};
|
|
243
259
|
|
|
260
|
+
/**
|
|
261
|
+
* Filters entities based if it is an orphan or not.
|
|
262
|
+
* @public
|
|
263
|
+
*/
|
|
264
|
+
export declare class EntityOrphanFilter implements EntityFilter {
|
|
265
|
+
readonly value: boolean;
|
|
266
|
+
constructor(value: boolean);
|
|
267
|
+
filterEntity(entity: Entity): boolean;
|
|
268
|
+
}
|
|
269
|
+
|
|
244
270
|
/**
|
|
245
271
|
* Filter matching entities that are owned by group.
|
|
246
272
|
* @public
|
|
@@ -255,6 +281,9 @@ export declare class EntityOwnerFilter implements EntityFilter {
|
|
|
255
281
|
/** @public */
|
|
256
282
|
export declare const EntityOwnerPicker: () => JSX.Element | null;
|
|
257
283
|
|
|
284
|
+
/** @public */
|
|
285
|
+
export declare const EntityProcessingStatusPicker: () => JSX.Element;
|
|
286
|
+
|
|
258
287
|
/**
|
|
259
288
|
* Provides an entity to be picked up by the `useEntity` hook.
|
|
260
289
|
*
|
package/dist/index.beta.d.ts
CHANGED
|
@@ -83,6 +83,7 @@ export declare type CatalogReactComponentsNameToClassKey = {
|
|
|
83
83
|
CatalogReactEntitySearchBar: CatalogReactEntitySearchBarClassKey;
|
|
84
84
|
CatalogReactEntityTagPicker: CatalogReactEntityTagPickerClassKey;
|
|
85
85
|
CatalogReactEntityOwnerPicker: CatalogReactEntityOwnerPickerClassKey;
|
|
86
|
+
CatalogReactEntityProcessingStatusPicker: CatalogReactEntityProcessingStatusPickerClassKey;
|
|
86
87
|
};
|
|
87
88
|
|
|
88
89
|
/** @public */
|
|
@@ -91,6 +92,9 @@ export declare type CatalogReactEntityLifecyclePickerClassKey = 'input';
|
|
|
91
92
|
/** @public */
|
|
92
93
|
export declare type CatalogReactEntityOwnerPickerClassKey = 'input';
|
|
93
94
|
|
|
95
|
+
/** @public */
|
|
96
|
+
export declare type CatalogReactEntityProcessingStatusPickerClassKey = 'input';
|
|
97
|
+
|
|
94
98
|
/** @public */
|
|
95
99
|
export declare type CatalogReactEntitySearchBarClassKey = 'searchToolbar' | 'input';
|
|
96
100
|
|
|
@@ -130,8 +134,20 @@ export declare type DefaultEntityFilters = {
|
|
|
130
134
|
lifecycles?: EntityLifecycleFilter;
|
|
131
135
|
tags?: EntityTagFilter;
|
|
132
136
|
text?: EntityTextFilter;
|
|
137
|
+
orphan?: EntityOrphanFilter;
|
|
138
|
+
error?: EntityErrorFilter;
|
|
133
139
|
};
|
|
134
140
|
|
|
141
|
+
/**
|
|
142
|
+
* Filters entities based on if it has errors or not.
|
|
143
|
+
* @public
|
|
144
|
+
*/
|
|
145
|
+
export declare class EntityErrorFilter implements EntityFilter {
|
|
146
|
+
readonly value: boolean;
|
|
147
|
+
constructor(value: boolean);
|
|
148
|
+
filterEntity(entity: Entity): boolean;
|
|
149
|
+
}
|
|
150
|
+
|
|
135
151
|
/** @public */
|
|
136
152
|
export declare type EntityFilter = {
|
|
137
153
|
/**
|
|
@@ -241,6 +257,16 @@ export declare type EntityLoadingStatus<TEntity extends Entity = Entity> = {
|
|
|
241
257
|
refresh?: VoidFunction;
|
|
242
258
|
};
|
|
243
259
|
|
|
260
|
+
/**
|
|
261
|
+
* Filters entities based if it is an orphan or not.
|
|
262
|
+
* @public
|
|
263
|
+
*/
|
|
264
|
+
export declare class EntityOrphanFilter implements EntityFilter {
|
|
265
|
+
readonly value: boolean;
|
|
266
|
+
constructor(value: boolean);
|
|
267
|
+
filterEntity(entity: Entity): boolean;
|
|
268
|
+
}
|
|
269
|
+
|
|
244
270
|
/**
|
|
245
271
|
* Filter matching entities that are owned by group.
|
|
246
272
|
* @public
|
|
@@ -255,6 +281,9 @@ export declare class EntityOwnerFilter implements EntityFilter {
|
|
|
255
281
|
/** @public */
|
|
256
282
|
export declare const EntityOwnerPicker: () => JSX.Element | null;
|
|
257
283
|
|
|
284
|
+
/** @public */
|
|
285
|
+
export declare const EntityProcessingStatusPicker: () => JSX.Element;
|
|
286
|
+
|
|
258
287
|
/**
|
|
259
288
|
* Provides an entity to be picked up by the `useEntity` hook.
|
|
260
289
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -83,6 +83,7 @@ export declare type CatalogReactComponentsNameToClassKey = {
|
|
|
83
83
|
CatalogReactEntitySearchBar: CatalogReactEntitySearchBarClassKey;
|
|
84
84
|
CatalogReactEntityTagPicker: CatalogReactEntityTagPickerClassKey;
|
|
85
85
|
CatalogReactEntityOwnerPicker: CatalogReactEntityOwnerPickerClassKey;
|
|
86
|
+
CatalogReactEntityProcessingStatusPicker: CatalogReactEntityProcessingStatusPickerClassKey;
|
|
86
87
|
};
|
|
87
88
|
|
|
88
89
|
/** @public */
|
|
@@ -91,6 +92,9 @@ export declare type CatalogReactEntityLifecyclePickerClassKey = 'input';
|
|
|
91
92
|
/** @public */
|
|
92
93
|
export declare type CatalogReactEntityOwnerPickerClassKey = 'input';
|
|
93
94
|
|
|
95
|
+
/** @public */
|
|
96
|
+
export declare type CatalogReactEntityProcessingStatusPickerClassKey = 'input';
|
|
97
|
+
|
|
94
98
|
/** @public */
|
|
95
99
|
export declare type CatalogReactEntitySearchBarClassKey = 'searchToolbar' | 'input';
|
|
96
100
|
|
|
@@ -130,8 +134,20 @@ export declare type DefaultEntityFilters = {
|
|
|
130
134
|
lifecycles?: EntityLifecycleFilter;
|
|
131
135
|
tags?: EntityTagFilter;
|
|
132
136
|
text?: EntityTextFilter;
|
|
137
|
+
orphan?: EntityOrphanFilter;
|
|
138
|
+
error?: EntityErrorFilter;
|
|
133
139
|
};
|
|
134
140
|
|
|
141
|
+
/**
|
|
142
|
+
* Filters entities based on if it has errors or not.
|
|
143
|
+
* @public
|
|
144
|
+
*/
|
|
145
|
+
export declare class EntityErrorFilter implements EntityFilter {
|
|
146
|
+
readonly value: boolean;
|
|
147
|
+
constructor(value: boolean);
|
|
148
|
+
filterEntity(entity: Entity): boolean;
|
|
149
|
+
}
|
|
150
|
+
|
|
135
151
|
/** @public */
|
|
136
152
|
export declare type EntityFilter = {
|
|
137
153
|
/**
|
|
@@ -241,6 +257,16 @@ export declare type EntityLoadingStatus<TEntity extends Entity = Entity> = {
|
|
|
241
257
|
refresh?: VoidFunction;
|
|
242
258
|
};
|
|
243
259
|
|
|
260
|
+
/**
|
|
261
|
+
* Filters entities based if it is an orphan or not.
|
|
262
|
+
* @public
|
|
263
|
+
*/
|
|
264
|
+
export declare class EntityOrphanFilter implements EntityFilter {
|
|
265
|
+
readonly value: boolean;
|
|
266
|
+
constructor(value: boolean);
|
|
267
|
+
filterEntity(entity: Entity): boolean;
|
|
268
|
+
}
|
|
269
|
+
|
|
244
270
|
/**
|
|
245
271
|
* Filter matching entities that are owned by group.
|
|
246
272
|
* @public
|
|
@@ -255,6 +281,9 @@ export declare class EntityOwnerFilter implements EntityFilter {
|
|
|
255
281
|
/** @public */
|
|
256
282
|
export declare const EntityOwnerPicker: () => JSX.Element | null;
|
|
257
283
|
|
|
284
|
+
/** @public */
|
|
285
|
+
export declare const EntityProcessingStatusPicker: () => JSX.Element;
|
|
286
|
+
|
|
258
287
|
/**
|
|
259
288
|
* Provides an entity to be picked up by the `useEntity` hook.
|
|
260
289
|
*
|
package/dist/index.esm.js
CHANGED
|
@@ -473,6 +473,26 @@ class UserListFilter {
|
|
|
473
473
|
return this.value;
|
|
474
474
|
}
|
|
475
475
|
}
|
|
476
|
+
class EntityOrphanFilter {
|
|
477
|
+
constructor(value) {
|
|
478
|
+
this.value = value;
|
|
479
|
+
}
|
|
480
|
+
filterEntity(entity) {
|
|
481
|
+
var _a;
|
|
482
|
+
const orphan = (_a = entity.metadata.annotations) == null ? void 0 : _a["backstage.io/orphan"];
|
|
483
|
+
return orphan !== void 0 && this.value.toString() === orphan;
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
class EntityErrorFilter {
|
|
487
|
+
constructor(value) {
|
|
488
|
+
this.value = value;
|
|
489
|
+
}
|
|
490
|
+
filterEntity(entity) {
|
|
491
|
+
var _a, _b;
|
|
492
|
+
const error = ((_b = (_a = entity == null ? void 0 : entity.status) == null ? void 0 : _a.items) == null ? void 0 : _b.length) > 0;
|
|
493
|
+
return error !== void 0 && this.value === error;
|
|
494
|
+
}
|
|
495
|
+
}
|
|
476
496
|
|
|
477
497
|
function useEntityTypeFilter() {
|
|
478
498
|
var _a;
|
|
@@ -684,20 +704,20 @@ const EntityKindPicker = (props) => {
|
|
|
684
704
|
}, "Kind filter not yet available");
|
|
685
705
|
};
|
|
686
706
|
|
|
687
|
-
const useStyles$
|
|
707
|
+
const useStyles$c = makeStyles({
|
|
688
708
|
input: {}
|
|
689
709
|
}, {
|
|
690
710
|
name: "CatalogReactEntityLifecyclePicker"
|
|
691
711
|
});
|
|
692
|
-
const icon$
|
|
712
|
+
const icon$3 = /* @__PURE__ */ React.createElement(CheckBoxOutlineBlankIcon, {
|
|
693
713
|
fontSize: "small"
|
|
694
714
|
});
|
|
695
|
-
const checkedIcon$
|
|
715
|
+
const checkedIcon$3 = /* @__PURE__ */ React.createElement(CheckBoxIcon, {
|
|
696
716
|
fontSize: "small"
|
|
697
717
|
});
|
|
698
718
|
const EntityLifecyclePicker = () => {
|
|
699
719
|
var _a, _b;
|
|
700
|
-
const classes = useStyles$
|
|
720
|
+
const classes = useStyles$c();
|
|
701
721
|
const {
|
|
702
722
|
updateFilters,
|
|
703
723
|
backendEntities,
|
|
@@ -737,8 +757,8 @@ const EntityLifecyclePicker = () => {
|
|
|
737
757
|
onChange: (_, value) => setSelectedLifecycles(value),
|
|
738
758
|
renderOption: (option, { selected }) => /* @__PURE__ */ React.createElement(FormControlLabel, {
|
|
739
759
|
control: /* @__PURE__ */ React.createElement(Checkbox, {
|
|
740
|
-
icon: icon$
|
|
741
|
-
checkedIcon: checkedIcon$
|
|
760
|
+
icon: icon$3,
|
|
761
|
+
checkedIcon: checkedIcon$3,
|
|
742
762
|
checked: selected
|
|
743
763
|
}),
|
|
744
764
|
label: option
|
|
@@ -755,20 +775,20 @@ const EntityLifecyclePicker = () => {
|
|
|
755
775
|
})));
|
|
756
776
|
};
|
|
757
777
|
|
|
758
|
-
const useStyles$
|
|
778
|
+
const useStyles$b = makeStyles({
|
|
759
779
|
input: {}
|
|
760
780
|
}, {
|
|
761
781
|
name: "CatalogReactEntityOwnerPicker"
|
|
762
782
|
});
|
|
763
|
-
const icon$
|
|
783
|
+
const icon$2 = /* @__PURE__ */ React.createElement(CheckBoxOutlineBlankIcon, {
|
|
764
784
|
fontSize: "small"
|
|
765
785
|
});
|
|
766
|
-
const checkedIcon$
|
|
786
|
+
const checkedIcon$2 = /* @__PURE__ */ React.createElement(CheckBoxIcon, {
|
|
767
787
|
fontSize: "small"
|
|
768
788
|
});
|
|
769
789
|
const EntityOwnerPicker = () => {
|
|
770
790
|
var _a, _b;
|
|
771
|
-
const classes = useStyles$
|
|
791
|
+
const classes = useStyles$b();
|
|
772
792
|
const {
|
|
773
793
|
updateFilters,
|
|
774
794
|
backendEntities,
|
|
@@ -805,8 +825,8 @@ const EntityOwnerPicker = () => {
|
|
|
805
825
|
onChange: (_, value) => setSelectedOwners(value),
|
|
806
826
|
renderOption: (option, { selected }) => /* @__PURE__ */ React.createElement(FormControlLabel, {
|
|
807
827
|
control: /* @__PURE__ */ React.createElement(Checkbox, {
|
|
808
|
-
icon: icon$
|
|
809
|
-
checkedIcon: checkedIcon$
|
|
828
|
+
icon: icon$2,
|
|
829
|
+
checkedIcon: checkedIcon$2,
|
|
810
830
|
checked: selected
|
|
811
831
|
}),
|
|
812
832
|
label: option
|
|
@@ -823,7 +843,7 @@ const EntityOwnerPicker = () => {
|
|
|
823
843
|
})));
|
|
824
844
|
};
|
|
825
845
|
|
|
826
|
-
const useStyles$
|
|
846
|
+
const useStyles$a = makeStyles((_theme) => ({
|
|
827
847
|
searchToolbar: {
|
|
828
848
|
paddingLeft: 0,
|
|
829
849
|
paddingRight: 0
|
|
@@ -834,7 +854,7 @@ const useStyles$9 = makeStyles((_theme) => ({
|
|
|
834
854
|
});
|
|
835
855
|
const EntitySearchBar = () => {
|
|
836
856
|
var _a, _b;
|
|
837
|
-
const classes = useStyles$
|
|
857
|
+
const classes = useStyles$a();
|
|
838
858
|
const { filters, updateFilters } = useEntityList();
|
|
839
859
|
const [search, setSearch] = useState((_b = (_a = filters.text) == null ? void 0 : _a.value) != null ? _b : "");
|
|
840
860
|
useDebounce(() => {
|
|
@@ -990,7 +1010,7 @@ const componentEntityColumns = [
|
|
|
990
1010
|
columnFactories.createMetadataDescriptionColumn()
|
|
991
1011
|
];
|
|
992
1012
|
|
|
993
|
-
const useStyles$
|
|
1013
|
+
const useStyles$9 = makeStyles((theme) => ({
|
|
994
1014
|
empty: {
|
|
995
1015
|
padding: theme.spacing(2),
|
|
996
1016
|
display: "flex",
|
|
@@ -1005,7 +1025,7 @@ const EntityTable = (props) => {
|
|
|
1005
1025
|
variant = "gridItem",
|
|
1006
1026
|
columns
|
|
1007
1027
|
} = props;
|
|
1008
|
-
const classes = useStyles$
|
|
1028
|
+
const classes = useStyles$9();
|
|
1009
1029
|
const tableStyle = {
|
|
1010
1030
|
minWidth: "0",
|
|
1011
1031
|
width: "100%"
|
|
@@ -1034,20 +1054,20 @@ EntityTable.columns = columnFactories;
|
|
|
1034
1054
|
EntityTable.systemEntityColumns = systemEntityColumns;
|
|
1035
1055
|
EntityTable.componentEntityColumns = componentEntityColumns;
|
|
1036
1056
|
|
|
1037
|
-
const useStyles$
|
|
1057
|
+
const useStyles$8 = makeStyles({
|
|
1038
1058
|
input: {}
|
|
1039
1059
|
}, {
|
|
1040
1060
|
name: "CatalogReactEntityTagPicker"
|
|
1041
1061
|
});
|
|
1042
|
-
const icon = /* @__PURE__ */ React.createElement(CheckBoxOutlineBlankIcon, {
|
|
1062
|
+
const icon$1 = /* @__PURE__ */ React.createElement(CheckBoxOutlineBlankIcon, {
|
|
1043
1063
|
fontSize: "small"
|
|
1044
1064
|
});
|
|
1045
|
-
const checkedIcon = /* @__PURE__ */ React.createElement(CheckBoxIcon, {
|
|
1065
|
+
const checkedIcon$1 = /* @__PURE__ */ React.createElement(CheckBoxIcon, {
|
|
1046
1066
|
fontSize: "small"
|
|
1047
1067
|
});
|
|
1048
1068
|
const EntityTagPicker = () => {
|
|
1049
1069
|
var _a, _b;
|
|
1050
|
-
const classes = useStyles$
|
|
1070
|
+
const classes = useStyles$8();
|
|
1051
1071
|
const {
|
|
1052
1072
|
updateFilters,
|
|
1053
1073
|
filters,
|
|
@@ -1090,8 +1110,8 @@ const EntityTagPicker = () => {
|
|
|
1090
1110
|
onChange: (_, value) => setSelectedTags(value),
|
|
1091
1111
|
renderOption: (option, { selected }) => /* @__PURE__ */ React.createElement(FormControlLabel, {
|
|
1092
1112
|
control: /* @__PURE__ */ React.createElement(Checkbox, {
|
|
1093
|
-
icon,
|
|
1094
|
-
checkedIcon,
|
|
1113
|
+
icon: icon$1,
|
|
1114
|
+
checkedIcon: checkedIcon$1,
|
|
1095
1115
|
checked: selected
|
|
1096
1116
|
}),
|
|
1097
1117
|
label: option
|
|
@@ -1192,7 +1212,7 @@ function EntityKindIcon(props) {
|
|
|
1192
1212
|
});
|
|
1193
1213
|
}
|
|
1194
1214
|
|
|
1195
|
-
const useStyles$
|
|
1215
|
+
const useStyles$7 = makeStyles((theme) => ({
|
|
1196
1216
|
node: {
|
|
1197
1217
|
fill: theme.palette.grey[300],
|
|
1198
1218
|
stroke: theme.palette.grey[300],
|
|
@@ -1246,7 +1266,7 @@ function useAncestry(root) {
|
|
|
1246
1266
|
};
|
|
1247
1267
|
}
|
|
1248
1268
|
function CustomNode({ node }) {
|
|
1249
|
-
const classes = useStyles$
|
|
1269
|
+
const classes = useStyles$7();
|
|
1250
1270
|
const navigate = useNavigate();
|
|
1251
1271
|
const entityRoute = useRouteRef(entityRouteRef);
|
|
1252
1272
|
const [width, setWidth] = useState(0);
|
|
@@ -1330,7 +1350,7 @@ function AncestryPage(props) {
|
|
|
1330
1350
|
})));
|
|
1331
1351
|
}
|
|
1332
1352
|
|
|
1333
|
-
const useStyles$
|
|
1353
|
+
const useStyles$6 = makeStyles((theme) => ({
|
|
1334
1354
|
root: {
|
|
1335
1355
|
display: "flex",
|
|
1336
1356
|
flexDirection: "column"
|
|
@@ -1347,7 +1367,7 @@ const useStyles$5 = makeStyles((theme) => ({
|
|
|
1347
1367
|
}
|
|
1348
1368
|
}));
|
|
1349
1369
|
function ListItemText(props) {
|
|
1350
|
-
const classes = useStyles$
|
|
1370
|
+
const classes = useStyles$6();
|
|
1351
1371
|
return /* @__PURE__ */ React.createElement(ListItemText$1, {
|
|
1352
1372
|
...props,
|
|
1353
1373
|
primaryTypographyProps: { className: classes.monospace },
|
|
@@ -1355,7 +1375,7 @@ function ListItemText(props) {
|
|
|
1355
1375
|
});
|
|
1356
1376
|
}
|
|
1357
1377
|
function ListSubheader(props) {
|
|
1358
|
-
const classes = useStyles$
|
|
1378
|
+
const classes = useStyles$6();
|
|
1359
1379
|
return /* @__PURE__ */ React.createElement(ListSubheader$1, {
|
|
1360
1380
|
className: classes.monospace
|
|
1361
1381
|
}, props.children);
|
|
@@ -1392,7 +1412,7 @@ function KeyValueListItem(props) {
|
|
|
1392
1412
|
}));
|
|
1393
1413
|
}
|
|
1394
1414
|
function HelpIcon(props) {
|
|
1395
|
-
const classes = useStyles$
|
|
1415
|
+
const classes = useStyles$6();
|
|
1396
1416
|
return /* @__PURE__ */ React.createElement(Link, {
|
|
1397
1417
|
to: props.to,
|
|
1398
1418
|
className: classes.helpIcon
|
|
@@ -1401,7 +1421,7 @@ function HelpIcon(props) {
|
|
|
1401
1421
|
}));
|
|
1402
1422
|
}
|
|
1403
1423
|
|
|
1404
|
-
const useStyles$
|
|
1424
|
+
const useStyles$5 = makeStyles({
|
|
1405
1425
|
root: {
|
|
1406
1426
|
display: "flex",
|
|
1407
1427
|
flexDirection: "column"
|
|
@@ -1490,7 +1510,7 @@ function Contents$1(props) {
|
|
|
1490
1510
|
}));
|
|
1491
1511
|
}
|
|
1492
1512
|
function ColocatedPage(props) {
|
|
1493
|
-
const classes = useStyles$
|
|
1513
|
+
const classes = useStyles$5();
|
|
1494
1514
|
return /* @__PURE__ */ React.createElement(React.Fragment, null, /* @__PURE__ */ React.createElement(DialogContentText, {
|
|
1495
1515
|
variant: "h2"
|
|
1496
1516
|
}, "Colocated"), /* @__PURE__ */ React.createElement(DialogContentText, null, "These are the entities that are colocated with this entity - as in, they originated from the same data source (e.g. came from the same YAML file), or from the same origin (e.g. the originally registered URL)."), /* @__PURE__ */ React.createElement("div", {
|
|
@@ -1517,7 +1537,7 @@ function JsonPage(props) {
|
|
|
1517
1537
|
}))));
|
|
1518
1538
|
}
|
|
1519
1539
|
|
|
1520
|
-
const useStyles$
|
|
1540
|
+
const useStyles$4 = makeStyles({
|
|
1521
1541
|
root: {
|
|
1522
1542
|
display: "flex",
|
|
1523
1543
|
flexDirection: "column"
|
|
@@ -1525,7 +1545,7 @@ const useStyles$3 = makeStyles({
|
|
|
1525
1545
|
});
|
|
1526
1546
|
function OverviewPage(props) {
|
|
1527
1547
|
var _a, _b;
|
|
1528
|
-
const classes = useStyles$
|
|
1548
|
+
const classes = useStyles$4();
|
|
1529
1549
|
const {
|
|
1530
1550
|
apiVersion,
|
|
1531
1551
|
kind,
|
|
@@ -1622,7 +1642,7 @@ function YamlPage(props) {
|
|
|
1622
1642
|
}))));
|
|
1623
1643
|
}
|
|
1624
1644
|
|
|
1625
|
-
const useStyles$
|
|
1645
|
+
const useStyles$3 = makeStyles((theme) => ({
|
|
1626
1646
|
fullHeightDialog: {
|
|
1627
1647
|
height: "calc(100% - 64px)"
|
|
1628
1648
|
},
|
|
@@ -1643,7 +1663,7 @@ const useStyles$2 = makeStyles((theme) => ({
|
|
|
1643
1663
|
}));
|
|
1644
1664
|
function TabPanel(props) {
|
|
1645
1665
|
const { children, value, index, ...other } = props;
|
|
1646
|
-
const classes = useStyles$
|
|
1666
|
+
const classes = useStyles$3();
|
|
1647
1667
|
return /* @__PURE__ */ React.createElement("div", {
|
|
1648
1668
|
role: "tabpanel",
|
|
1649
1669
|
hidden: value !== index,
|
|
@@ -1663,7 +1683,7 @@ function a11yProps(index) {
|
|
|
1663
1683
|
};
|
|
1664
1684
|
}
|
|
1665
1685
|
function InspectEntityDialog(props) {
|
|
1666
|
-
const classes = useStyles$
|
|
1686
|
+
const classes = useStyles$3();
|
|
1667
1687
|
const [activeTab, setActiveTab] = React.useState(0);
|
|
1668
1688
|
useEffect(() => {
|
|
1669
1689
|
setActiveTab(0);
|
|
@@ -1794,7 +1814,7 @@ function useUnregisterEntityDialogState(entity) {
|
|
|
1794
1814
|
};
|
|
1795
1815
|
}
|
|
1796
1816
|
|
|
1797
|
-
const useStyles$
|
|
1817
|
+
const useStyles$2 = makeStyles({
|
|
1798
1818
|
advancedButton: {
|
|
1799
1819
|
fontSize: "0.7em"
|
|
1800
1820
|
}
|
|
@@ -1806,7 +1826,7 @@ const Contents = ({
|
|
|
1806
1826
|
var _a;
|
|
1807
1827
|
const alertApi = useApi(alertApiRef);
|
|
1808
1828
|
const configApi = useApi(configApiRef);
|
|
1809
|
-
const classes = useStyles$
|
|
1829
|
+
const classes = useStyles$2();
|
|
1810
1830
|
const state = useUnregisterEntityDialogState(entity);
|
|
1811
1831
|
const [showDelete, setShowDelete] = useState(false);
|
|
1812
1832
|
const [busy, setBusy] = useState(false);
|
|
@@ -1928,7 +1948,7 @@ const UnregisterEntityDialog = (props) => {
|
|
|
1928
1948
|
}, "Cancel")));
|
|
1929
1949
|
};
|
|
1930
1950
|
|
|
1931
|
-
const useStyles = makeStyles((theme) => ({
|
|
1951
|
+
const useStyles$1 = makeStyles((theme) => ({
|
|
1932
1952
|
root: {
|
|
1933
1953
|
backgroundColor: "rgba(0, 0, 0, .11)",
|
|
1934
1954
|
boxShadow: "none",
|
|
@@ -1984,7 +2004,7 @@ function getFilterGroups(orgName) {
|
|
|
1984
2004
|
const UserListPicker = (props) => {
|
|
1985
2005
|
var _a;
|
|
1986
2006
|
const { initialFilter, availableFilters } = props;
|
|
1987
|
-
const classes = useStyles();
|
|
2007
|
+
const classes = useStyles$1();
|
|
1988
2008
|
const configApi = useApi(configApiRef);
|
|
1989
2009
|
const orgName = (_a = configApi.getOptionalString("organization.name")) != null ? _a : "Company";
|
|
1990
2010
|
const {
|
|
@@ -2066,6 +2086,67 @@ const UserListPicker = (props) => {
|
|
|
2066
2086
|
}))))));
|
|
2067
2087
|
};
|
|
2068
2088
|
|
|
2089
|
+
const useStyles = makeStyles({
|
|
2090
|
+
input: {}
|
|
2091
|
+
}, {
|
|
2092
|
+
name: "CatalogReactEntityProcessingStatusPickerPicker"
|
|
2093
|
+
});
|
|
2094
|
+
const icon = /* @__PURE__ */ React.createElement(CheckBoxOutlineBlankIcon, {
|
|
2095
|
+
fontSize: "small"
|
|
2096
|
+
});
|
|
2097
|
+
const checkedIcon = /* @__PURE__ */ React.createElement(CheckBoxIcon, {
|
|
2098
|
+
fontSize: "small"
|
|
2099
|
+
});
|
|
2100
|
+
const EntityProcessingStatusPicker = () => {
|
|
2101
|
+
const classes = useStyles();
|
|
2102
|
+
const { updateFilters } = useEntityList();
|
|
2103
|
+
const [selectedAdvancedItems, setSelectedAdvancedItems] = useState([]);
|
|
2104
|
+
function orphanChange(value) {
|
|
2105
|
+
updateFilters({
|
|
2106
|
+
orphan: value ? new EntityOrphanFilter(value) : void 0
|
|
2107
|
+
});
|
|
2108
|
+
}
|
|
2109
|
+
function errorChange(value) {
|
|
2110
|
+
updateFilters({
|
|
2111
|
+
error: value ? new EntityErrorFilter(value) : void 0
|
|
2112
|
+
});
|
|
2113
|
+
}
|
|
2114
|
+
const availableAdvancedItems = ["Is Orphan", "Has Error"];
|
|
2115
|
+
return /* @__PURE__ */ React.createElement(Box, {
|
|
2116
|
+
pb: 1,
|
|
2117
|
+
pt: 1
|
|
2118
|
+
}, /* @__PURE__ */ React.createElement(Typography, {
|
|
2119
|
+
variant: "button",
|
|
2120
|
+
component: "label"
|
|
2121
|
+
}, "Processing Status", /* @__PURE__ */ React.createElement(Autocomplete, {
|
|
2122
|
+
multiple: true,
|
|
2123
|
+
options: availableAdvancedItems,
|
|
2124
|
+
value: selectedAdvancedItems,
|
|
2125
|
+
onChange: (_, value) => {
|
|
2126
|
+
setSelectedAdvancedItems(value);
|
|
2127
|
+
orphanChange(value.includes("Is Orphan"));
|
|
2128
|
+
errorChange(value.includes("Has Error"));
|
|
2129
|
+
},
|
|
2130
|
+
renderOption: (option, { selected }) => /* @__PURE__ */ React.createElement(FormControlLabel, {
|
|
2131
|
+
control: /* @__PURE__ */ React.createElement(Checkbox, {
|
|
2132
|
+
icon,
|
|
2133
|
+
checkedIcon,
|
|
2134
|
+
checked: selected
|
|
2135
|
+
}),
|
|
2136
|
+
label: option
|
|
2137
|
+
}),
|
|
2138
|
+
size: "small",
|
|
2139
|
+
popupIcon: /* @__PURE__ */ React.createElement(ExpandMoreIcon, {
|
|
2140
|
+
"data-testid": "processing-status-picker-expand"
|
|
2141
|
+
}),
|
|
2142
|
+
renderInput: (params) => /* @__PURE__ */ React.createElement(TextField, {
|
|
2143
|
+
...params,
|
|
2144
|
+
className: classes.input,
|
|
2145
|
+
variant: "outlined"
|
|
2146
|
+
})
|
|
2147
|
+
})));
|
|
2148
|
+
};
|
|
2149
|
+
|
|
2069
2150
|
const MockEntityListContextProvider = ({
|
|
2070
2151
|
children,
|
|
2071
2152
|
value
|
|
@@ -2100,5 +2181,5 @@ const MockEntityListContextProvider = ({
|
|
|
2100
2181
|
}, children);
|
|
2101
2182
|
};
|
|
2102
2183
|
|
|
2103
|
-
export { AsyncEntityProvider, CatalogFilterLayout, EntityKindFilter, EntityKindPicker, EntityLifecycleFilter, EntityLifecyclePicker, EntityListContext, EntityListProvider, EntityOwnerFilter, EntityOwnerPicker, EntityProvider, EntityRefLink, EntityRefLinks, EntitySearchBar, EntityTable, EntityTagFilter, EntityTagPicker, EntityTextFilter, EntityTypeFilter, EntityTypePicker, FavoriteEntity, InspectEntityDialog, MockEntityListContextProvider, MockStarredEntitiesApi, UnregisterEntityDialog, UserListFilter, UserListPicker, catalogApiRef, columnFactories, entityRouteParams, entityRouteRef, getEntityRelations, getEntitySourceLocation, humanizeEntityRef, isOwnerOf, starredEntitiesApiRef, useAsyncEntity, useEntity, useEntityList, useEntityOwnership, useEntityPermission, useEntityTypeFilter, useRelatedEntities, useStarredEntities, useStarredEntity };
|
|
2184
|
+
export { AsyncEntityProvider, CatalogFilterLayout, EntityErrorFilter, EntityKindFilter, EntityKindPicker, EntityLifecycleFilter, EntityLifecyclePicker, EntityListContext, EntityListProvider, EntityOrphanFilter, EntityOwnerFilter, EntityOwnerPicker, EntityProcessingStatusPicker, EntityProvider, EntityRefLink, EntityRefLinks, EntitySearchBar, EntityTable, EntityTagFilter, EntityTagPicker, EntityTextFilter, EntityTypeFilter, EntityTypePicker, FavoriteEntity, InspectEntityDialog, MockEntityListContextProvider, MockStarredEntitiesApi, UnregisterEntityDialog, UserListFilter, UserListPicker, catalogApiRef, columnFactories, entityRouteParams, entityRouteRef, getEntityRelations, getEntitySourceLocation, humanizeEntityRef, isOwnerOf, starredEntitiesApiRef, useAsyncEntity, useEntity, useEntityList, useEntityOwnership, useEntityPermission, useEntityTypeFilter, useRelatedEntities, useStarredEntities, useStarredEntity };
|
|
2104
2185
|
//# sourceMappingURL=index.esm.js.map
|