@redhat-cloud-services/types 3.2.0 → 3.2.1
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/index.d.ts +18 -15
- package/index.js +6 -0
- package/index.js.map +1 -1
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -108,10 +108,6 @@ export type EnableTopicsArgs = [{
|
|
|
108
108
|
names: string[];
|
|
109
109
|
append?: boolean;
|
|
110
110
|
}] | string[];
|
|
111
|
-
type SearchNavItemPermission<T extends keyof VisibilityFunctions = 'isOrgAdmin'> = {
|
|
112
|
-
method: T;
|
|
113
|
-
args: Parameters<VisibilityFunctions[T]>;
|
|
114
|
-
};
|
|
115
111
|
export type ChromeWsEventTypes = 'com.redhat.console.notifications.drawer';
|
|
116
112
|
export type ChromeWsPayload<T> = {
|
|
117
113
|
data: T;
|
|
@@ -124,25 +120,32 @@ export type ChromeWsPayload<T> = {
|
|
|
124
120
|
export type ChromeWsEventListener<T> = (event: ChromeWsPayload<T>) => void;
|
|
125
121
|
export type UnSubscribeFromChromeWsEvent = () => void;
|
|
126
122
|
export type AddChromeWsEventListener = <T>(type: ChromeWsEventTypes, listener: ChromeWsEventListener<T>) => UnSubscribeFromChromeWsEvent;
|
|
127
|
-
export type SearchDataType = '
|
|
128
|
-
export
|
|
129
|
-
id: string;
|
|
123
|
+
export type SearchDataType = 'services' | 'quickstarts';
|
|
124
|
+
export type SearchEntry = {
|
|
130
125
|
title: string;
|
|
131
|
-
description: string;
|
|
132
126
|
uri: string;
|
|
133
127
|
pathname: string;
|
|
128
|
+
description: string;
|
|
129
|
+
icon?: string;
|
|
130
|
+
id: string;
|
|
134
131
|
bundleTitle: string;
|
|
135
132
|
altTitle?: string[];
|
|
136
|
-
icon?: string;
|
|
137
133
|
type: SearchDataType;
|
|
138
|
-
|
|
134
|
+
};
|
|
135
|
+
export declare enum ReleaseEnv {
|
|
136
|
+
STABLE = "STABLE",
|
|
137
|
+
PREVIEW = "PREVIEW"
|
|
139
138
|
}
|
|
139
|
+
export type ResultItem = {
|
|
140
|
+
title: string;
|
|
141
|
+
description: string;
|
|
142
|
+
bundleTitle: string;
|
|
143
|
+
pathname: string;
|
|
144
|
+
id: string;
|
|
145
|
+
};
|
|
140
146
|
export interface ChromeSearchAPI {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
getAvailableTypes: () => SearchDataType[];
|
|
144
|
-
clearType: (type: SearchDataType) => Promise<void>;
|
|
145
|
-
getCachedData: (type: SearchDataType) => SearchEntry[] | undefined;
|
|
147
|
+
query: (term: string, type: SearchDataType, env?: ReleaseEnv) => Promise<ResultItem[]>;
|
|
148
|
+
insert: (data: SearchEntry) => Promise<void>;
|
|
146
149
|
}
|
|
147
150
|
export type DrawerPanelActions = {
|
|
148
151
|
setDrawerPanelContent: (data: {
|
package/index.js
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ReleaseEnv = void 0;
|
|
4
|
+
var ReleaseEnv;
|
|
5
|
+
(function (ReleaseEnv) {
|
|
6
|
+
ReleaseEnv["STABLE"] = "STABLE";
|
|
7
|
+
ReleaseEnv["PREVIEW"] = "PREVIEW";
|
|
8
|
+
})(ReleaseEnv || (exports.ReleaseEnv = ReleaseEnv = {}));
|
|
3
9
|
//# sourceMappingURL=index.js.map
|
package/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../packages/types/index.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../packages/types/index.ts"],"names":[],"mappings":";;;AA4JA,IAAY,UAGX;AAHD,WAAY,UAAU;IACpB,+BAAiB,CAAA;IACjB,iCAAmB,CAAA;AACrB,CAAC,EAHW,UAAU,0BAAV,UAAU,QAGrB"}
|
package/package.json
CHANGED