@gooddata/sdk-ui-pluggable-application 11.41.0-alpha.5 → 11.41.0

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/esm/events.d.ts CHANGED
@@ -18,9 +18,9 @@ export interface IPluggableAppEventsContextValue {
18
18
  * Sets the page-title segment of the browser tab title on the host.
19
19
  *
20
20
  * @remarks
21
- * The host owns `document.title` and composes it as `"{pageTitle} - {brand}"`. Pass
22
- * `undefined` to fall back to the application's manifest title. No-ops when the application
23
- * runs standalone (outside the host).
21
+ * Emits a standard document-title-changed event on the host event channel. The host owns
22
+ * `document.title` and composes it as `"{pageTitle} - {brand}"`. Pass `undefined` to fall back to
23
+ * the application's manifest title. No-ops when the application runs standalone (outside the host).
24
24
  */
25
25
  setDocumentTitle: (pageTitle: string | undefined) => void;
26
26
  }
@@ -34,17 +34,13 @@ export interface IPluggableAppEventsProviderProps extends PropsWithChildren {
34
34
  * Host callback passed through pluggable mount options.
35
35
  */
36
36
  onEvent?: (event: IPluggableAppEvent) => void;
37
- /**
38
- * Host callback (from pluggable mount options) to set the page-title segment of the tab title.
39
- */
40
- onDocumentTitleChange?: (pageTitle: string | undefined) => void;
41
37
  }
42
38
  /**
43
39
  * React provider exposing pluggable-to-host event helpers.
44
40
  *
45
41
  * @alpha
46
42
  */
47
- export declare function PluggableAppEventsProvider({ onEvent, onDocumentTitleChange, children }: IPluggableAppEventsProviderProps): import("react/jsx-runtime").JSX.Element;
43
+ export declare function PluggableAppEventsProvider({ onEvent, children }: IPluggableAppEventsProviderProps): import("react/jsx-runtime").JSX.Element;
48
44
  /**
49
45
  * Returns event helpers for communication with host.
50
46
  *
@@ -1 +1 @@
1
- {"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../src/events.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,iBAAiB,EAAmD,MAAM,OAAO,CAAC;AAEhG,OAAO,EACH,KAAK,kBAAkB,EAE1B,MAAM,2CAA2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AC,KAAK,EAAE,kBAAkB,KAAK,IAAI,CAAC;CACjD;AAWD;;;;GAIG;AACH,wBAAgB,0BAA0B,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,gCAAgC,2CA6BjG;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,IAAI,+BAA+B,CAEvE"}
package/esm/events.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  // (C) 2026 GoodData Corporation
3
3
  import { createContext, useCallback, useContext, useMemo } from "react";
4
- import { reloadPlatformContextRequested, } from "@gooddata/sdk-pluggable-application-model";
4
+ import { documentTitleChanged, reloadPlatformContextRequested, } from "@gooddata/sdk-pluggable-application-model";
5
5
  const noop = () => undefined;
6
6
  const PluggableAppEventsContext = createContext({
7
7
  emit: noop,
@@ -14,7 +14,7 @@ PluggableAppEventsContext.displayName = "PluggableAppEventsContext";
14
14
  *
15
15
  * @alpha
16
16
  */
17
- export function PluggableAppEventsProvider({ onEvent, onDocumentTitleChange, children, }) {
17
+ export function PluggableAppEventsProvider({ onEvent, children }) {
18
18
  const emit = useCallback((event) => {
19
19
  onEvent?.(event);
20
20
  }, [onEvent]);
@@ -22,8 +22,8 @@ export function PluggableAppEventsProvider({ onEvent, onDocumentTitleChange, chi
22
22
  emit(reloadPlatformContextRequested());
23
23
  }, [emit]);
24
24
  const setDocumentTitle = useCallback((pageTitle) => {
25
- onDocumentTitleChange?.(pageTitle);
26
- }, [onDocumentTitleChange]);
25
+ emit(documentTitleChanged(pageTitle));
26
+ }, [emit]);
27
27
  return (_jsx(PluggableAppEventsContext.Provider, { value: useMemo(() => ({ emit, emitPlatformContextReload, setDocumentTitle }), [emit, emitPlatformContextReload, setDocumentTitle]), children: children }));
28
28
  }
29
29
  /**
@@ -167,9 +167,9 @@ export declare interface IPluggableAppEventsContextValue {
167
167
  * Sets the page-title segment of the browser tab title on the host.
168
168
  *
169
169
  * @remarks
170
- * The host owns `document.title` and composes it as `"{pageTitle} - {brand}"`. Pass
171
- * `undefined` to fall back to the application's manifest title. No-ops when the application
172
- * runs standalone (outside the host).
170
+ * Emits a standard document-title-changed event on the host event channel. The host owns
171
+ * `document.title` and composes it as `"{pageTitle} - {brand}"`. Pass `undefined` to fall back to
172
+ * the application's manifest title. No-ops when the application runs standalone (outside the host).
173
173
  */
174
174
  setDocumentTitle: (pageTitle: string | undefined) => void;
175
175
  }
@@ -184,10 +184,6 @@ export declare interface IPluggableAppEventsProviderProps extends PropsWithChild
184
184
  * Host callback passed through pluggable mount options.
185
185
  */
186
186
  onEvent?: (event: IPluggableAppEvent) => void;
187
- /**
188
- * Host callback (from pluggable mount options) to set the page-title segment of the tab title.
189
- */
190
- onDocumentTitleChange?: (pageTitle: string | undefined) => void;
191
187
  }
192
188
 
193
189
  /**
@@ -202,7 +198,7 @@ export declare function PlatformContextProvider({ value, children }: IPlatformCo
202
198
  *
203
199
  * @alpha
204
200
  */
205
- export declare function PluggableAppEventsProvider({ onEvent, onDocumentTitleChange, children }: IPluggableAppEventsProviderProps): JSX.Element;
201
+ export declare function PluggableAppEventsProvider({ onEvent, children }: IPluggableAppEventsProviderProps): JSX.Element;
206
202
 
207
203
  /**
208
204
  * Returns client platform context snapshot (or undefined if not available yet).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gooddata/sdk-ui-pluggable-application",
3
- "version": "11.41.0-alpha.5",
3
+ "version": "11.41.0",
4
4
  "description": "GoodData SDK React helpers for pluggable applications",
5
5
  "license": "MIT",
6
6
  "author": "GoodData Corporation",
@@ -24,12 +24,12 @@
24
24
  "react-intl": "7.1.11",
25
25
  "ts-invariant": "0.10.3",
26
26
  "tslib": "2.8.1",
27
- "@gooddata/sdk-backend-base": "11.41.0-alpha.5",
28
- "@gooddata/sdk-backend-tiger": "11.41.0-alpha.5",
29
- "@gooddata/sdk-model": "11.41.0-alpha.5",
30
- "@gooddata/sdk-pluggable-application-model": "11.41.0-alpha.5",
31
- "@gooddata/sdk-backend-spi": "11.41.0-alpha.5",
32
- "@gooddata/sdk-ui": "11.41.0-alpha.5"
27
+ "@gooddata/sdk-backend-base": "11.41.0",
28
+ "@gooddata/sdk-backend-tiger": "11.41.0",
29
+ "@gooddata/sdk-model": "11.41.0",
30
+ "@gooddata/sdk-pluggable-application-model": "11.41.0",
31
+ "@gooddata/sdk-backend-spi": "11.41.0",
32
+ "@gooddata/sdk-ui": "11.41.0"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@microsoft/api-documenter": "^7.17.0",
@@ -61,8 +61,8 @@
61
61
  "react-dom": "19.1.1",
62
62
  "typescript": "5.9.3",
63
63
  "vitest": "4.1.8",
64
- "@gooddata/eslint-config": "11.41.0-alpha.5",
65
- "@gooddata/oxlint-config": "11.41.0-alpha.5"
64
+ "@gooddata/eslint-config": "11.41.0",
65
+ "@gooddata/oxlint-config": "11.41.0"
66
66
  },
67
67
  "peerDependencies": {
68
68
  "react": "^18.0.0 || ^19.0.0",