@redocly/theme 0.62.0-next.1 → 0.62.0-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/lib/core/types/hooks.d.ts +13 -1
- package/package.json +1 -1
- package/src/core/types/hooks.ts +20 -1
|
@@ -138,7 +138,19 @@ export type ThemeHooks = {
|
|
|
138
138
|
items: BffCatalogEntityRevision[];
|
|
139
139
|
};
|
|
140
140
|
useCatalogClassic: (config: CatalogConfig) => FilteredCatalog;
|
|
141
|
-
useTelemetry: () => Omit<AsyncApiRealmUI.Telemetry, 'init' | 'updateCloudEventData' | 'forceFlush' | 'startSpan' | 'constructCloudEvent' | 'sendToOtelService'
|
|
141
|
+
useTelemetry: () => Omit<AsyncApiRealmUI.Telemetry, 'init' | 'updateCloudEventData' | 'forceFlush' | 'startSpan' | 'constructCloudEvent' | 'sendToOtelService'> & {
|
|
142
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(event: TEventType, data?: AsyncApiRealmUI.EventPayload<TEventType>): void;
|
|
143
|
+
/**
|
|
144
|
+
* @deprecated This method is deprecated. Use send(event, data) instead.
|
|
145
|
+
*/
|
|
146
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(params: AsyncApiRealmUI.SendEventParams<TEventType>): void;
|
|
147
|
+
};
|
|
148
|
+
/**
|
|
149
|
+
* @deprecated This hook is deprecated. Use `useTelemetry` instead.
|
|
150
|
+
*/
|
|
151
|
+
useOtelTelemetry: () => {
|
|
152
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(params: AsyncApiRealmUI.SendEventParams<TEventType>): void;
|
|
153
|
+
};
|
|
142
154
|
useUserTeams: () => string[];
|
|
143
155
|
usePageData: () => PageData | null;
|
|
144
156
|
usePageSharedData: <T = unknown>(dataId: string) => T;
|
package/package.json
CHANGED
package/src/core/types/hooks.ts
CHANGED
|
@@ -177,7 +177,26 @@ export type ThemeHooks = {
|
|
|
177
177
|
| 'startSpan'
|
|
178
178
|
| 'constructCloudEvent'
|
|
179
179
|
| 'sendToOtelService'
|
|
180
|
-
|
|
180
|
+
> & {
|
|
181
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(
|
|
182
|
+
event: TEventType,
|
|
183
|
+
data?: AsyncApiRealmUI.EventPayload<TEventType>,
|
|
184
|
+
): void;
|
|
185
|
+
/**
|
|
186
|
+
* @deprecated This method is deprecated. Use send(event, data) instead.
|
|
187
|
+
*/
|
|
188
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(
|
|
189
|
+
params: AsyncApiRealmUI.SendEventParams<TEventType>,
|
|
190
|
+
): void;
|
|
191
|
+
};
|
|
192
|
+
/**
|
|
193
|
+
* @deprecated This hook is deprecated. Use `useTelemetry` instead.
|
|
194
|
+
*/
|
|
195
|
+
useOtelTelemetry: () => {
|
|
196
|
+
send<TEventType extends AsyncApiRealmUI.EventType>(
|
|
197
|
+
params: AsyncApiRealmUI.SendEventParams<TEventType>,
|
|
198
|
+
): void;
|
|
199
|
+
};
|
|
181
200
|
useUserTeams: () => string[];
|
|
182
201
|
usePageData: () => PageData | null;
|
|
183
202
|
usePageSharedData: <T = unknown>(dataId: string) => T;
|