@gooddata/sdk-ui 10.44.0-alpha.2 → 10.44.0-alpha.4
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/base/localization/IntlWrapper.d.ts +3 -3
- package/esm/base/localization/IntlWrapper.d.ts.map +1 -1
- package/esm/base/localization/IntlWrapper.js +3 -2
- package/esm/base/localization/IntlWrapper.js.map +1 -1
- package/esm/base/localization/TranslationsCustomizationProvider/Context.d.ts +4 -4
- package/esm/base/localization/TranslationsCustomizationProvider/Context.d.ts.map +1 -1
- package/esm/base/localization/TranslationsCustomizationProvider/Context.js +7 -7
- package/esm/base/localization/TranslationsCustomizationProvider/Context.js.map +1 -1
- package/esm/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.d.ts +2 -2
- package/esm/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.d.ts.map +1 -1
- package/esm/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.js +3 -2
- package/esm/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.js.map +1 -1
- package/esm/base/localization/intlUtils.d.ts +4 -4
- package/esm/base/localization/intlUtils.d.ts.map +1 -1
- package/esm/base/localization/intlUtils.js +5 -8
- package/esm/base/localization/intlUtils.js.map +1 -1
- package/esm/base/react/BackendContext.d.ts +4 -4
- package/esm/base/react/BackendContext.d.ts.map +1 -1
- package/esm/base/react/BackendContext.js +7 -6
- package/esm/base/react/BackendContext.js.map +1 -1
- package/esm/base/react/ClientWorkspaceContext/ClientWorkspaceContext.d.ts +4 -4
- package/esm/base/react/ClientWorkspaceContext/ClientWorkspaceContext.d.ts.map +1 -1
- package/esm/base/react/ClientWorkspaceContext/ClientWorkspaceContext.js +9 -10
- package/esm/base/react/ClientWorkspaceContext/ClientWorkspaceContext.js.map +1 -1
- package/esm/base/react/ClientWorkspaceContext/interfaces.d.ts +2 -1
- package/esm/base/react/ClientWorkspaceContext/interfaces.d.ts.map +1 -1
- package/esm/base/react/ClientWorkspaceContext/interfaces.js +1 -1
- package/esm/base/react/CorrelationContext.d.ts +5 -5
- package/esm/base/react/CorrelationContext.d.ts.map +1 -1
- package/esm/base/react/CorrelationContext.js +7 -6
- package/esm/base/react/CorrelationContext.js.map +1 -1
- package/esm/base/react/ErrorComponent.d.ts +1 -2
- package/esm/base/react/ErrorComponent.d.ts.map +1 -1
- package/esm/base/react/ErrorComponent.js +14 -19
- package/esm/base/react/ErrorComponent.js.map +1 -1
- package/esm/base/react/LoadingComponent.d.ts +1 -2
- package/esm/base/react/LoadingComponent.d.ts.map +1 -1
- package/esm/base/react/LoadingComponent.js +3 -12
- package/esm/base/react/LoadingComponent.js.map +1 -1
- package/esm/base/react/OrganizationContext.d.ts +4 -4
- package/esm/base/react/OrganizationContext.d.ts.map +1 -1
- package/esm/base/react/OrganizationContext.js +4 -3
- package/esm/base/react/OrganizationContext.js.map +1 -1
- package/esm/base/react/WorkspaceContext.d.ts +4 -4
- package/esm/base/react/WorkspaceContext.d.ts.map +1 -1
- package/esm/base/react/WorkspaceContext.js +7 -6
- package/esm/base/react/WorkspaceContext.js.map +1 -1
- package/esm/base/react/contextStore.d.ts +3 -3
- package/esm/base/react/contextStore.d.ts.map +1 -1
- package/esm/base/react/contextStore.js +11 -10
- package/esm/base/react/contextStore.js.map +1 -1
- package/esm/base/react/debounce.js +4 -4
- package/esm/base/react/debounce.js.map +1 -1
- package/esm/base/react/forwardRefWithGenerics.d.ts +2 -2
- package/esm/base/react/forwardRefWithGenerics.d.ts.map +1 -1
- package/esm/base/react/forwardRefWithGenerics.js +2 -2
- package/esm/base/react/forwardRefWithGenerics.js.map +1 -1
- package/esm/base/react/legacy/withEntireDataView.d.ts +2 -2
- package/esm/base/react/legacy/withEntireDataView.d.ts.map +1 -1
- package/esm/base/react/legacy/withEntireDataView.js +6 -6
- package/esm/base/react/legacy/withEntireDataView.js.map +1 -1
- package/esm/base/react/placeholders/context.d.ts +2 -2
- package/esm/base/react/placeholders/context.d.ts.map +1 -1
- package/esm/base/react/placeholders/context.js +4 -3
- package/esm/base/react/placeholders/context.js.map +1 -1
- package/esm/base/react/useAutoupdateRef.d.ts +1 -2
- package/esm/base/react/useAutoupdateRef.d.ts.map +1 -1
- package/esm/base/react/useAutoupdateRef.js +3 -3
- package/esm/base/react/useAutoupdateRef.js.map +1 -1
- package/esm/base/react/useCombineRefs.d.ts +2 -2
- package/esm/base/react/useCombineRefs.d.ts.map +1 -1
- package/esm/base/react/useCombineRefs.js +2 -2
- package/esm/base/react/useCombineRefs.js.map +1 -1
- package/esm/base/react/useInitialProp.js +2 -2
- package/esm/base/react/useInitialProp.js.map +1 -1
- package/esm/base/react/useLocalStorage.d.ts.map +1 -1
- package/esm/base/react/useLocalStorage.js +4 -4
- package/esm/base/react/useLocalStorage.js.map +1 -1
- package/esm/base/react/useObjectDiff.js +3 -3
- package/esm/base/react/useObjectDiff.js.map +1 -1
- package/esm/base/react/usePagedResource.d.ts +2 -1
- package/esm/base/react/usePagedResource.d.ts.map +1 -1
- package/esm/base/react/usePagedResource.js.map +1 -1
- package/esm/base/react/usePromiseCache.d.ts +2 -1
- package/esm/base/react/usePromiseCache.d.ts.map +1 -1
- package/esm/base/react/usePromiseCache.js.map +1 -1
- package/esm/base/react/usePropState.d.ts +1 -2
- package/esm/base/react/usePropState.d.ts.map +1 -1
- package/esm/base/react/usePropState.js +3 -3
- package/esm/base/react/usePropState.js.map +1 -1
- package/esm/base/react/validation/ValidationContextStore.d.ts.map +1 -1
- package/esm/base/react/validation/ValidationContextStore.js +7 -7
- package/esm/base/react/validation/ValidationContextStore.js.map +1 -1
- package/esm/base/react/withContexts.d.ts +2 -1
- package/esm/base/react/withContexts.d.ts.map +1 -1
- package/esm/base/react/withContexts.js.map +1 -1
- package/esm/base/react/wrapDisplayName.d.ts +2 -1
- package/esm/base/react/wrapDisplayName.d.ts.map +1 -1
- package/esm/base/react/wrapDisplayName.js +1 -1
- package/esm/base/react/wrapDisplayName.js.map +1 -1
- package/esm/base/vis/VisualizationProps.d.ts +3 -3
- package/esm/base/vis/VisualizationProps.d.ts.map +1 -1
- package/esm/execution/Execute.d.ts +3 -3
- package/esm/execution/Execute.d.ts.map +1 -1
- package/esm/execution/Execute.js +4 -5
- package/esm/execution/Execute.js.map +1 -1
- package/esm/execution/ExecuteInsight.d.ts +3 -3
- package/esm/execution/ExecuteInsight.d.ts.map +1 -1
- package/esm/execution/ExecuteInsight.js +3 -4
- package/esm/execution/ExecuteInsight.js.map +1 -1
- package/esm/execution/RawExecute.d.ts +3 -3
- package/esm/execution/RawExecute.d.ts.map +1 -1
- package/esm/execution/RawExecute.js +3 -4
- package/esm/execution/RawExecute.js.map +1 -1
- package/esm/execution/useExecutionDataView.d.ts +2 -1
- package/esm/execution/useExecutionDataView.d.ts.map +1 -1
- package/esm/execution/useExecutionDataView.js.map +1 -1
- package/esm/execution/useInsight.d.ts +2 -1
- package/esm/execution/useInsight.d.ts.map +1 -1
- package/esm/execution/useInsight.js +1 -0
- package/esm/execution/useInsight.js.map +1 -1
- package/esm/execution/useInsightDataView.d.ts +2 -1
- package/esm/execution/useInsightDataView.d.ts.map +1 -1
- package/esm/execution/useInsightDataView.js +1 -0
- package/esm/execution/useInsightDataView.js.map +1 -1
- package/esm/execution/withExecution.d.ts +2 -1
- package/esm/execution/withExecution.d.ts.map +1 -1
- package/esm/execution/withExecution.js.map +1 -1
- package/esm/execution/withExecutionLoading.d.ts +2 -2
- package/esm/execution/withExecutionLoading.d.ts.map +1 -1
- package/esm/execution/withExecutionLoading.js +7 -6
- package/esm/execution/withExecutionLoading.js.map +1 -1
- package/esm/kpi/FormattedNumber.d.ts +1 -2
- package/esm/kpi/FormattedNumber.d.ts.map +1 -1
- package/esm/kpi/FormattedNumber.js +2 -2
- package/esm/kpi/FormattedNumber.js.map +1 -1
- package/esm/kpi/Kpi.d.ts +4 -4
- package/esm/kpi/Kpi.d.ts.map +1 -1
- package/esm/kpi/Kpi.js +14 -16
- package/esm/kpi/Kpi.js.map +1 -1
- package/esm/kpi/KpiError.d.ts +1 -2
- package/esm/kpi/KpiError.d.ts.map +1 -1
- package/esm/kpi/KpiError.js +3 -4
- package/esm/kpi/KpiError.js.map +1 -1
- package/esm/sdk-ui.d.ts +62 -54
- package/package.json +14 -14
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
2
|
/**
|
|
3
3
|
* @internal
|
|
4
4
|
*/
|
|
5
5
|
export interface IIntlWrapperProps {
|
|
6
6
|
locale?: string;
|
|
7
|
-
children?:
|
|
7
|
+
children?: ReactNode;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* @internal
|
|
11
11
|
*/
|
|
12
|
-
export declare function IntlWrapper({ locale, children }: IIntlWrapperProps):
|
|
12
|
+
export declare function IntlWrapper({ locale, children }: IIntlWrapperProps): import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
//# sourceMappingURL=IntlWrapper.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IntlWrapper.d.ts","sourceRoot":"","sources":["../../../src/base/localization/IntlWrapper.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"IntlWrapper.d.ts","sourceRoot":"","sources":["../../../src/base/localization/IntlWrapper.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAW,MAAM,OAAO,CAAC;AAW3C;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAC9B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,EAAE,MAAsB,EAAE,QAAQ,EAAE,EAAE,iBAAiB,2CAkBlF"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// (C) 2007-2025 GoodData Corporation
|
|
2
|
-
import
|
|
3
|
+
import { useMemo } from "react";
|
|
3
4
|
import { IntlProvider } from "react-intl";
|
|
4
5
|
import { resolveLocaleDefaultMessages } from "./intlUtils.js";
|
|
5
6
|
import { DefaultLocale } from "./Locale.js";
|
|
@@ -16,6 +17,6 @@ export function IntlWrapper({ locale = DefaultLocale, children }) {
|
|
|
16
17
|
*/
|
|
17
18
|
const settings = window.gdSettings;
|
|
18
19
|
const messages = useMemo(() => pickCorrectWording(resolveLocaleDefaultMessages(locale, messagesMap), settings), [locale, settings]);
|
|
19
|
-
return (
|
|
20
|
+
return (_jsx(IntlProvider, { locale: locale, messages: messages, children: children }));
|
|
20
21
|
}
|
|
21
22
|
//# sourceMappingURL=IntlWrapper.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IntlWrapper.js","sourceRoot":"","sources":["../../../src/base/localization/IntlWrapper.tsx"],"names":[],"mappings":"AAAA,qCAAqC;
|
|
1
|
+
{"version":3,"file":"IntlWrapper.js","sourceRoot":"","sources":["../../../src/base/localization/IntlWrapper.tsx"],"names":[],"mappings":";AAAA,qCAAqC;AAErC,OAAO,EAAa,OAAO,EAAE,MAAM,OAAO,CAAC;AAE3C,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAI1C,OAAO,EAAE,4BAA4B,EAAE,MAAM,gBAAgB,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,8CAA8C,CAAC;AAUlF;;GAEG;AACH,MAAM,UAAU,WAAW,CAAC,EAAE,MAAM,GAAG,aAAa,EAAE,QAAQ,EAAqB;IAC/E;;;;OAIG;IACH,MAAM,QAAQ,GAAG,MAAM,CAAC,UAAgC,CAAC;IAEzD,MAAM,QAAQ,GAAG,OAAO,CACpB,GAAG,EAAE,CAAC,kBAAkB,CAAC,4BAA4B,CAAC,MAAM,EAAE,WAAW,CAAC,EAAE,QAAQ,CAAC,EACrF,CAAC,MAAM,EAAE,QAAQ,CAAC,CACrB,CAAC;IAEF,OAAO,CACH,KAAC,YAAY,IAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,QAAQ,YAC3C,QAAQ,GACE,CAClB,CAAC;AACN,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ComponentType, ReactNode } from "react";
|
|
2
2
|
/**
|
|
3
3
|
* @beta
|
|
4
4
|
*/
|
|
@@ -14,14 +14,14 @@ export interface ITranslationsCustomizationContextProviderProps {
|
|
|
14
14
|
/**
|
|
15
15
|
* React children
|
|
16
16
|
*/
|
|
17
|
-
children?:
|
|
17
|
+
children?: ReactNode;
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
20
|
* @beta
|
|
21
21
|
*/
|
|
22
|
-
export declare function TranslationsCustomizationContextProvider({ children, translationsCustomizationIsLoading, translations, }: ITranslationsCustomizationContextProviderProps):
|
|
22
|
+
export declare function TranslationsCustomizationContextProvider({ children, translationsCustomizationIsLoading, translations, }: ITranslationsCustomizationContextProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
23
23
|
/**
|
|
24
24
|
* @beta
|
|
25
25
|
*/
|
|
26
|
-
export declare function withTranslationsCustomization<T>(Component:
|
|
26
|
+
export declare function withTranslationsCustomization<T>(Component: ComponentType<T>): ComponentType<Omit<T, "translationsCustomizationIsLoading" | "translations">>;
|
|
27
27
|
//# sourceMappingURL=Context.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/Context.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Context.d.ts","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/Context.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,EAAE,SAAS,EAAiB,MAAM,OAAO,CAAC;AAYhE;;GAEG;AACH,MAAM,WAAW,8CAA8C;IAC3D;;OAEG;IACH,kCAAkC,EAAE,OAAO,CAAC;IAE5C;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAErC;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;GAEG;AACH,wBAAgB,wCAAwC,CAAC,EACrD,QAAQ,EACR,kCAAkC,EAClC,YAAY,GACf,EAAE,8CAA8C,2CAQhD;AAyCD;;GAEG;AACH,wBAAgB,6BAA6B,CAAC,CAAC,EAC3C,SAAS,EAAE,aAAa,CAAC,CAAC,CAAC,GAC5B,aAAa,CAAC,IAAI,CAAC,CAAC,EAAE,oCAAoC,GAAG,cAAc,CAAC,CAAC,CAM/E"}
|
|
@@ -1,27 +1,27 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// (C) 2021-2025 GoodData Corporation
|
|
2
|
-
import
|
|
3
|
+
import { createContext } from "react";
|
|
3
4
|
import compose from "lodash/flowRight.js";
|
|
4
5
|
import { wrapDisplayName } from "../../react/wrapDisplayName.js";
|
|
5
|
-
const TranslationsCustomizationContext =
|
|
6
|
+
const TranslationsCustomizationContext = createContext(undefined);
|
|
6
7
|
TranslationsCustomizationContext.displayName = "TranslationsCustomizationContext";
|
|
7
|
-
const TranslationsCustomizationIsLoadingContext =
|
|
8
|
+
const TranslationsCustomizationIsLoadingContext = createContext(undefined);
|
|
8
9
|
TranslationsCustomizationIsLoadingContext.displayName = "TranslationsCustomizationIsLoadingContext";
|
|
9
10
|
/**
|
|
10
11
|
* @beta
|
|
11
12
|
*/
|
|
12
13
|
export function TranslationsCustomizationContextProvider({ children, translationsCustomizationIsLoading, translations, }) {
|
|
13
|
-
return (
|
|
14
|
-
React.createElement(TranslationsCustomizationIsLoadingContext.Provider, { value: translationsCustomizationIsLoading }, children)));
|
|
14
|
+
return (_jsx(TranslationsCustomizationContext.Provider, { value: translations, children: _jsx(TranslationsCustomizationIsLoadingContext.Provider, { value: translationsCustomizationIsLoading, children: children }) }));
|
|
15
15
|
}
|
|
16
16
|
function withTranslationsCustomizationValue(Component) {
|
|
17
17
|
function ComponentWithInjectedTranslationsCustomizationValue(props) {
|
|
18
|
-
return (
|
|
18
|
+
return (_jsx(TranslationsCustomizationContext.Consumer, { children: (translations) => _jsx(Component, { translations: translations, ...props }) }));
|
|
19
19
|
}
|
|
20
20
|
return wrapDisplayName("withTranslationsCustomizationValue", TranslationsCustomizationContextProvider)(ComponentWithInjectedTranslationsCustomizationValue);
|
|
21
21
|
}
|
|
22
22
|
function withTranslationsCustomizationIsLoading(Component) {
|
|
23
23
|
function ComponentWithInjectedTranslationsCustomizationIsLoading(props) {
|
|
24
|
-
return (
|
|
24
|
+
return (_jsx(TranslationsCustomizationIsLoadingContext.Consumer, { children: (translationsCustomizationIsLoading) => (_jsx(Component, { translationsCustomizationIsLoading: translationsCustomizationIsLoading, ...props })) }));
|
|
25
25
|
}
|
|
26
26
|
return wrapDisplayName("withTranslationsCustomizationIsLoading", TranslationsCustomizationContextProvider)(ComponentWithInjectedTranslationsCustomizationIsLoading);
|
|
27
27
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Context.js","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/Context.tsx"],"names":[],"mappings":"AAAA,qCAAqC;
|
|
1
|
+
{"version":3,"file":"Context.js","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/Context.tsx"],"names":[],"mappings":";AAAA,qCAAqC;AAErC,OAAO,EAA4B,aAAa,EAAE,MAAM,OAAO,CAAC;AAEhE,OAAO,OAAO,MAAM,qBAAqB,CAAC;AAE1C,OAAO,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AAEjE,MAAM,gCAAgC,GAAG,aAAa,CAAqC,SAAS,CAAC,CAAC;AACtG,gCAAgC,CAAC,WAAW,GAAG,kCAAkC,CAAC;AAElF,M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@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactElement } from "react";
|
|
2
2
|
import { IAnalyticalBackend, IWorkspaceSettings } from "@gooddata/sdk-backend-spi";
|
|
3
3
|
declare global {
|
|
4
4
|
interface Window {
|
|
@@ -50,5 +50,5 @@ export interface ITranslationsCustomizationProviderProps {
|
|
|
50
50
|
*
|
|
51
51
|
* @beta
|
|
52
52
|
*/
|
|
53
|
-
export declare function TranslationsCustomizationProvider({ render, customize, translations: translationsParam, backend: backendParam, workspace: workspaceParam, }: ITranslationsCustomizationProviderProps):
|
|
53
|
+
export declare function TranslationsCustomizationProvider({ render, customize, translations: translationsParam, backend: backendParam, workspace: workspaceParam, }: ITranslationsCustomizationProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
54
54
|
//# sourceMappingURL=TranslationsCustomizationProvider.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TranslationsCustomizationProvider.d.ts","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"TranslationsCustomizationProvider.d.ts","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAuB,MAAM,OAAO,CAAC;AAE1D,OAAO,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAOnF,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,MAAM;QACZ,UAAU,EAAE,kBAAkB,GAAG,SAAS,CAAC;KAC9C;CACJ;AAED;;GAEG;AACH,MAAM,WAAW,uCAAuC;IACpD;;OAEG;IACH,MAAM,CAAC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,YAAY,CAAC;IAE3D;;OAEG;IACH,SAAS,CAAC,CAAC,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,QAAQ,CAAC,EAAE,kBAAkB,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAExG;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAErC;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,kBAAkB,CAAC;IAE7B;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACtB;AAID;;;;;;;;;;;GAWG;AACH,wBAAgB,iCAAiC,CAAC,EAC9C,MAAM,EACN,SAA8B,EAC9B,YAAY,EAAE,iBAA4C,EAC1D,OAAO,EAAE,YAAY,EACrB,SAAS,EAAE,cAAc,GAC5B,EAAE,uCAAuC,2CAoCzC"}
|
package/esm/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// (C) 2021-2025 GoodData Corporation
|
|
2
|
-
import
|
|
3
|
+
import { useEffect, useState } from "react";
|
|
3
4
|
import { TranslationsCustomizationContextProvider } from "./Context.js";
|
|
4
5
|
import { pickCorrectWording } from "./utils.js";
|
|
5
6
|
import { useBackend } from "../../react/BackendContext.js";
|
|
@@ -40,6 +41,6 @@ export function TranslationsCustomizationProvider({ render, customize = pickCorr
|
|
|
40
41
|
};
|
|
41
42
|
fetchSettings();
|
|
42
43
|
}, [backend, workspace, translationsParam]);
|
|
43
|
-
return (
|
|
44
|
+
return (_jsx(TranslationsCustomizationContextProvider, { translationsCustomizationIsLoading: isLoading, translations: translations, children: render(translations) }));
|
|
44
45
|
}
|
|
45
46
|
//# sourceMappingURL=TranslationsCustomizationProvider.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TranslationsCustomizationProvider.js","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.tsx"],"names":[],"mappings":"AAAA,qCAAqC;
|
|
1
|
+
{"version":3,"file":"TranslationsCustomizationProvider.js","sourceRoot":"","sources":["../../../../src/base/localization/TranslationsCustomizationProvider/TranslationsCustomizationProvider.tsx"],"names":[],"mappings":";AAAA,qCAAqC;AAErC,OAAO,EAAgB,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAI1D,OAAO,EAAE,wCAAwC,EAAE,MAAM,cAAc,CAAC;AACxE,OAAO,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,EAAE,UAAU,EAAE,MAAM,+BAA+B,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AA8C/D,MAAM,wBAAwB,GAA4D,EAAE,CAAC;AAE7F;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,iCAAiC,CAAC,EAC9C,MAAM,EACN,SAAS,GAAG,kBAAkB,EAC9B,YAAY,EAAE,iBAAiB,GAAG,wBAAwB,EAC1D,OAAO,EAAE,YAAY,EACrB,SAAS,EAAE,cAAc,GACa;IACtC,MAAM,OAAO,GAAG,UAAU,CAAC,YAAY,CAAC,CAAC;IACzC,MAAM,SAAS,GAAG,YAAY,CAAC,cAAc,CAAC,CAAC;IAC/C,MAAM,CAAC,YAAY,EAAE,eAAe,CAAC,GAAG,QAAQ,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,iBAAiB,CAAC,CAAC,CAAC;IACrF,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAElD,SAAS,CAAC,GAAG,EAAE;QACX,MAAM,aAAa,GAAG,KAAK,IAAI,EAAE;YAC7B,IAAI,CAAC,OAAO,IAAI,CAAC,SAAS,EAAE,CAAC;gBACzB,OAAO;YACX,CAAC;YACD,YAAY,CAAC,IAAI,CAAC,CAAC;YAEnB,MAAM,QAAQ,GAAG,MAAM,OAAO,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,QAAQ,EAAE,CAAC,yBAAyB,EAAE,CAAC;YAE3F;;;;eAIG;YACH,MAAM,CAAC,UAAU,GAAG,QAAQ,CAAC;YAC7B,eAAe,CAAC,SAAS,CAAC,iBAAiB,EAAE,QAAQ,CAAC,CAAC,CAAC;YACxD,YAAY,CAAC,KAAK,CAAC,CAAC;QACxB,CAAC,CAAC;QAEF,aAAa,EAAE,CAAC;IACpB,CAAC,EAAE,CAAC,OAAO,EAAE,SAAS,EAAE,iBAAiB,CAAC,CAAC,CAAC;IAE5C,OAAO,CACH,KAAC,wCAAwC,IACrC,kCAAkC,EAAE,SAAS,EAC7C,YAAY,EAAE,YAAY,YAEzB,MAAM,CAAC,YAAY,CAAC,GACkB,CAC9C,CAAC;AACN,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ComponentClass, ComponentType, FC, ReactNode } from "react";
|
|
2
2
|
import { IntlShape } from "react-intl";
|
|
3
3
|
import { ILocale } from "./Locale.js";
|
|
4
4
|
import { ITranslations } from "./messagesMap.js";
|
|
@@ -9,11 +9,11 @@ export declare function createIntlMock(customMessages?: {}, locale?: string): In
|
|
|
9
9
|
/**
|
|
10
10
|
* @internal
|
|
11
11
|
*/
|
|
12
|
-
export declare function withIntlForTest<P>(WrappedComponent:
|
|
12
|
+
export declare function withIntlForTest<P>(WrappedComponent: FC<P> | ComponentClass<P>, customLocale?: ILocale, customMessages?: ITranslations): ComponentType<P>;
|
|
13
13
|
/**
|
|
14
14
|
* @internal
|
|
15
15
|
*/
|
|
16
|
-
export declare function withIntl<P>(WrappedComponent:
|
|
16
|
+
export declare function withIntl<P>(WrappedComponent: FC<P> | ComponentClass<P>, customLocale?: ILocale, customMessages?: ITranslations): ComponentType<P>;
|
|
17
17
|
/**
|
|
18
18
|
* @internal
|
|
19
19
|
*/
|
|
@@ -22,7 +22,7 @@ export declare function Intl({ children, customLocale, customMessages, forTest,
|
|
|
22
22
|
customLocale?: ILocale;
|
|
23
23
|
customMessages?: ITranslations;
|
|
24
24
|
forTest?: boolean;
|
|
25
|
-
}):
|
|
25
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
26
26
|
/**
|
|
27
27
|
* Resolves parameter into {@link ILocale} or {@link DefaultLocale}.
|
|
28
28
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intlUtils.d.ts","sourceRoot":"","sources":["../../../src/base/localization/intlUtils.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"intlUtils.d.ts","sourceRoot":"","sources":["../../../src/base/localization/intlUtils.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,EAAE,EAAO,SAAS,EAAE,MAAM,OAAO,CAAC;AAE1E,OAAO,EAAgB,SAAS,EAAc,MAAM,YAAY,CAAC;AAGjE,OAAO,EAAiB,OAAO,EAAY,MAAM,aAAa,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAe,MAAM,kBAAkB,CAAC;AAG9D;;GAEG;AACH,wBAAgB,cAAc,CAAC,cAAc,KAAK,EAAE,MAAM,SAAU,GAAG,SAAS,CAe/E;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,CAAC,EAC7B,gBAAgB,EAAE,EAAE,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,EAC3C,YAAY,CAAC,EAAE,OAAO,EACtB,cAAc,CAAC,EAAE,aAAa,GAC/B,aAAa,CAAC,CAAC,CAAC,CAsBlB;AAED;;GAEG;AACH,wBAAgB,QAAQ,CAAC,CAAC,EACtB,gBAAgB,EAAE,EAAE,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,EAC3C,YAAY,CAAC,EAAE,OAAO,EACtB,cAAc,CAAC,EAAE,aAAa,GAC/B,aAAa,CAAC,CAAC,CAAC,CAalB;AAED;;GAEG;AACH,wBAAgB,IAAI,CAAC,EACjB,QAAQ,EACR,YAAY,EACZ,cAAc,EACd,OAAe,GAClB,EAAE;IACC,QAAQ,EAAE,SAAS,CAAC;IACpB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,cAAc,CAAC,EAAE,aAAa,CAAC;IAC/B,OAAO,CAAC,EAAE,OAAO,CAAC;CACrB,2CAkBA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,aAAa,GAAI,QAAQ,OAAO,KAAG,OAE/C,CAAC;AAEF;;;;;;;;GAQG;AACH,eAAO,MAAM,4BAA4B,GACrC,QAAQ,MAAM,EACd,aAAa;IAAE,CAAC,MAAM,EAAE,MAAM,GAAG,aAAa,CAAA;CAAE,kBASnD,CAAC;AAEF;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAEhE;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAEhE;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,SAAS,GAAG,MAAM,CAE5D"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import React from "react";
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
2
|
import { IntlProvider, createIntl } from "react-intl";
|
|
4
3
|
import { DefaultLocale, isLocale } from "./Locale.js";
|
|
5
4
|
import { messagesMap } from "./messagesMap.js";
|
|
@@ -30,13 +29,12 @@ export function withIntlForTest(WrappedComponent, customLocale, customMessages)
|
|
|
30
29
|
function WithIntl(props) {
|
|
31
30
|
const locale = customLocale || DefaultLocale;
|
|
32
31
|
const messages = customMessages || resolveLocaleDefaultMessages(locale, messagesMap);
|
|
33
|
-
return (
|
|
32
|
+
return (_jsx(IntlProvider, { locale: locale, messages: messages, onError: (error) => {
|
|
34
33
|
// Suppress MISSING_TRANSLATION errors to improve test performance
|
|
35
34
|
if (!error.message?.includes("MISSING_TRANSLATION")) {
|
|
36
35
|
console.warn("IntlProviderForTest error:", error);
|
|
37
36
|
}
|
|
38
|
-
} }
|
|
39
|
-
React.createElement(WrappedComponent, { ...props })));
|
|
37
|
+
}, children: _jsx(WrappedComponent, { ...props }) }));
|
|
40
38
|
}
|
|
41
39
|
return wrapDisplayName("withIntl", WrappedComponent)(WithIntl);
|
|
42
40
|
}
|
|
@@ -47,8 +45,7 @@ export function withIntl(WrappedComponent, customLocale, customMessages) {
|
|
|
47
45
|
function WithIntl(props) {
|
|
48
46
|
const locale = customLocale || DefaultLocale;
|
|
49
47
|
const messages = customMessages || resolveLocaleDefaultMessages(locale, messagesMap);
|
|
50
|
-
return (
|
|
51
|
-
React.createElement(WrappedComponent, { ...props })));
|
|
48
|
+
return (_jsx(IntlProvider, { locale: locale, messages: messages, children: _jsx(WrappedComponent, { ...props }) }));
|
|
52
49
|
}
|
|
53
50
|
return wrapDisplayName("withIntl", WrappedComponent)(WithIntl);
|
|
54
51
|
}
|
|
@@ -68,7 +65,7 @@ export function Intl({ children, customLocale, customMessages, forTest = false,
|
|
|
68
65
|
}
|
|
69
66
|
};
|
|
70
67
|
}
|
|
71
|
-
return
|
|
68
|
+
return _jsx(IntlProvider, { ...props, children: children });
|
|
72
69
|
}
|
|
73
70
|
/**
|
|
74
71
|
* Resolves parameter into {@link ILocale} or {@link DefaultLocale}.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intlUtils.js","sourceRoot":"","sources":["../../../src/base/localization/intlUtils.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"intlUtils.js","sourceRoot":"","sources":["../../../src/base/localization/intlUtils.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAE,YAAY,EAAa,UAAU,EAAE,MAAM,YAAY,CAAC;AAGjE,OAAO,EAAE,aAAa,EAAW,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC/D,OAAO,EAAiB,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAE9D;;GAEG;AACH,MAAM,UAAU,cAAc,CAAC,c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C,MAAM,4BAA4B,GAAG,CACxC,MAAc,EACd,WAAgD,EAClD,EAAE;IACA,MAAM,OAAO,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC;IACpC,IAAI,CAAC,OAAO,EAAE,CAAC;QACX,OAAO,CAAC,IAAI,CAAC,8BAA8B,MAAM,WAAW,aAAa,EAAE,CAAC,CAAC;QAC7E,OAAO,WAAW,CAAC,aAAa,CAAC,CAAC;IACtC,CAAC;IAED,OAAO,OAAO,CAAC;AACnB,CAAC,CAAC;AAEF;;;;GAIG;AACH,MAAM,UAAU,wBAAwB,CAAC,IAAe;IACpD,OAAO,IAAI,IAAI,CAAC,aAAa,CAAC,EAAE,EAAE,EAAE,0BAA0B,EAAE,CAAC,GAAG,CAAC;AACzE,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,wBAAwB,CAAC,IAAe;IACpD,OAAO,IAAI,CAAC,aAAa,CAAC,EAAE,EAAE,EAAE,+BAA+B,EAAE,CAAC,CAAC;AACvE,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,oBAAoB,CAAC,IAAe;IAChD,OAAO,IAAI,CAAC,aAAa,CAAC,EAAE,EAAE,EAAE,uBAAuB,EAAE,CAAC,CAAC;AAC/D,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ComponentType, ReactNode } from "react";
|
|
2
2
|
import { IAnalyticalBackend } from "@gooddata/sdk-backend-spi";
|
|
3
3
|
/**
|
|
4
4
|
* Props of the {@link BackendProvider} component.
|
|
@@ -12,14 +12,14 @@ export interface IBackendProviderProps {
|
|
|
12
12
|
/**
|
|
13
13
|
* React children
|
|
14
14
|
*/
|
|
15
|
-
children?:
|
|
15
|
+
children?: ReactNode;
|
|
16
16
|
}
|
|
17
17
|
/**
|
|
18
18
|
* BackendProvider can be used to inject analytical backend instance to all ui-sdk components in your app.
|
|
19
19
|
*
|
|
20
20
|
* @public
|
|
21
21
|
*/
|
|
22
|
-
export declare function BackendProvider({ children, backend }: IBackendProviderProps):
|
|
22
|
+
export declare function BackendProvider({ children, backend }: IBackendProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
23
23
|
/**
|
|
24
24
|
* Hook to get analytical backend instance provided to {@link BackendProvider}.
|
|
25
25
|
*
|
|
@@ -74,5 +74,5 @@ export declare const useBackendStrict: (backend?: IAnalyticalBackend, context?:
|
|
|
74
74
|
*/
|
|
75
75
|
export declare function withBackend<T extends {
|
|
76
76
|
backend?: IAnalyticalBackend;
|
|
77
|
-
}>(Component:
|
|
77
|
+
}>(Component: ComponentType<T>): ComponentType<T>;
|
|
78
78
|
//# sourceMappingURL=BackendContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BackendContext.d.ts","sourceRoot":"","sources":["../../../src/base/react/BackendContext.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BackendContext.d.ts","sourceRoot":"","sources":["../../../src/base/react/BackendContext.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,EAAE,SAAS,EAA6B,MAAM,OAAO,CAAC;AAI5E,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAO/D;;;GAGG;AACH,MAAM,WAAW,qBAAqB;IAClC;;OAEG;IACH,OAAO,EAAE,kBAAkB,CAAC;IAE5B;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,EAAE,qBAAqB,2CAE3E;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,eAAO,MAAM,UAAU,GAAI,UAAU,kBAAkB,KAAG,kBAAkB,GAAG,SAG9E,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,gBAAgB,GACzB,UAAU,kBAAkB,EAC5B,gBAA4B,KAC7B,kBAQF,CAAC;AAEF;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,CAAC,SAAS;IAAE,OAAO,CAAC,EAAE,kBAAkB,CAAA;CAAE,EAClE,SAAS,EAAE,aAAa,CAAC,CAAC,CAAC,GAC5B,aAAa,CAAC,CAAC,CAAC,CAUlB"}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// (C) 2019-2025 GoodData Corporation
|
|
2
|
-
import
|
|
3
|
+
import { createContext, useContext } from "react";
|
|
3
4
|
import { invariant } from "ts-invariant";
|
|
4
5
|
import { wrapDisplayName } from "./wrapDisplayName.js";
|
|
5
|
-
const BackendContext =
|
|
6
|
+
const BackendContext = createContext(undefined);
|
|
6
7
|
BackendContext.displayName = "BackendContext";
|
|
7
8
|
/**
|
|
8
9
|
* BackendProvider can be used to inject analytical backend instance to all ui-sdk components in your app.
|
|
@@ -10,7 +11,7 @@ BackendContext.displayName = "BackendContext";
|
|
|
10
11
|
* @public
|
|
11
12
|
*/
|
|
12
13
|
export function BackendProvider({ children, backend }) {
|
|
13
|
-
return
|
|
14
|
+
return _jsx(BackendContext.Provider, { value: backend, children: children });
|
|
14
15
|
}
|
|
15
16
|
/**
|
|
16
17
|
* Hook to get analytical backend instance provided to {@link BackendProvider}.
|
|
@@ -34,7 +35,7 @@ export function BackendProvider({ children, backend }) {
|
|
|
34
35
|
* @public
|
|
35
36
|
*/
|
|
36
37
|
export const useBackend = (backend) => {
|
|
37
|
-
const backendFromContext =
|
|
38
|
+
const backendFromContext = useContext(BackendContext);
|
|
38
39
|
return backend ?? backendFromContext;
|
|
39
40
|
};
|
|
40
41
|
/**
|
|
@@ -61,7 +62,7 @@ export const useBackend = (backend) => {
|
|
|
61
62
|
* @public
|
|
62
63
|
*/
|
|
63
64
|
export const useBackendStrict = (backend, context = "useBackendStrict") => {
|
|
64
|
-
const backendFromContext =
|
|
65
|
+
const backendFromContext = useContext(BackendContext);
|
|
65
66
|
const effectiveBackend = backend ?? backendFromContext;
|
|
66
67
|
invariant(effectiveBackend, `${context}: IAnalyticalBackend must be defined. Either pass it as a parameter or make sure there is a BackendProvider up the component tree.`);
|
|
67
68
|
return effectiveBackend;
|
|
@@ -74,7 +75,7 @@ export const useBackendStrict = (backend, context = "useBackendStrict") => {
|
|
|
74
75
|
*/
|
|
75
76
|
export function withBackend(Component) {
|
|
76
77
|
function ComponentWithInjectedBackend(props) {
|
|
77
|
-
return (
|
|
78
|
+
return (_jsx(BackendContext.Consumer, { children: (backend) => _jsx(Component, { ...props, backend: props.backend ?? backend }) }));
|
|
78
79
|
}
|
|
79
80
|
return wrapDisplayName("withBackend", Component)(ComponentWithInjectedBackend);
|
|
80
81
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BackendContext.js","sourceRoot":"","sources":["../../../src/base/react/BackendContext.tsx"],"names":[],"mappings":"AAAA,qCAAqC;
|
|
1
|
+
{"version":3,"file":"BackendContext.js","sourceRoot":"","sources":["../../../src/base/react/BackendContext.tsx"],"names":[],"mappings":";AAAA,qCAAqC;AAErC,OAAO,EAA4B,aAAa,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAE5E,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAIzC,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAEvD,MAAM,cAAc,GAAG,aAAa,CAAiC,SAAS,CAAC,CAAC;AAChF,cAAc,CAAC,WAAW,GAAG,gBAAgB,CAAC;AAkB9C;;;;GAIG;AACH,MAAM,UAAU,eAAe,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAyB;IACxE,OAAO,KAAC,cAAc,CAAC,QAAQ,IAAC,KAAK,EAAE,OAAO,YAAG,QAAQ,GAA2B,CAAC;AACzF,CAAC;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,OAA4B,EAAkC,EAAE;IACvF,MAAM,kBAAkB,GAAG,UAAU,CAAC,cAAc,CAAC,CAAC;IACtD,OAAO,OAAO,IAAI,kBAAkB,CAAC;AACzC,CAAC,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC5B,OAA4B,EAC5B,OAAO,GAAG,kBAAkB,EACV,EAAE;IACpB,MAAM,kBAAkB,GAAG,UAAU,CAAC,cAAc,CAAC,CAAC;IACtD,MAAM,gBAAgB,GAAG,OAAO,IAAI,kBAAkB,CAAC;IACvD,SAAS,CACL,gBAAgB,EAChB,GAAG,OAAO,oIAAoI,CACjJ,CAAC;IACF,OAAO,gBAAgB,CAAC;AAC5B,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,UAAU,WAAW,CACvB,SAA2B;IAE3B,SAAS,4BAA4B,CAAC,KAAQ;QAC1C,OAAO,CACH,KAAC,cAAc,CAAC,QAAQ,cACnB,CAAC,OAAO,EAAE,EAAE,CAAC,KAAC,SAAS,OAAK,KAAK,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,IAAI,OAAO,GAAI,GACnD,CAC7B,CAAC;IACN,CAAC;IAED,OAAO,eAAe,CAAC,aAAa,EAAE,SAAS,CAAC,CAAC,4BAA4B,CAAC,CAAC;AACnF,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
2
|
import { IAnalyticalBackend } from "@gooddata/sdk-backend-spi";
|
|
3
3
|
import { IClientWorkspaceIdentifiers, IClientWorkspaceStatus } from "./interfaces.js";
|
|
4
4
|
import { GoodDataSdkError } from "../../errors/GoodDataSdkError.js";
|
|
@@ -23,7 +23,7 @@ export interface IClientWorkspaceProviderCoreProps {
|
|
|
23
23
|
/**
|
|
24
24
|
* Wrapped React components that will have access to the LCMWorkspace context.
|
|
25
25
|
*/
|
|
26
|
-
children:
|
|
26
|
+
children: ReactNode;
|
|
27
27
|
}
|
|
28
28
|
/**
|
|
29
29
|
* @alpha
|
|
@@ -77,7 +77,7 @@ export type IClientWorkspaceProviderProps = IClientWorkspaceProviderWithWorkspac
|
|
|
77
77
|
*
|
|
78
78
|
* @alpha
|
|
79
79
|
*/
|
|
80
|
-
export declare function ClientWorkspaceProvider(props: IClientWorkspaceProviderProps):
|
|
80
|
+
export declare function ClientWorkspaceProvider(props: IClientWorkspaceProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
81
81
|
/**
|
|
82
82
|
* ResolvedClientWorkspaceProvider can be used as a replacement of the {@link WorkspaceProvider}, if you are accessing
|
|
83
83
|
* workspace in LCM context.
|
|
@@ -91,7 +91,7 @@ export declare function ClientWorkspaceProvider(props: IClientWorkspaceProviderP
|
|
|
91
91
|
*
|
|
92
92
|
* @alpha
|
|
93
93
|
*/
|
|
94
|
-
export declare function ResolvedClientWorkspaceProvider(props: IClientWorkspaceIdentifiers):
|
|
94
|
+
export declare function ResolvedClientWorkspaceProvider(props: IClientWorkspaceIdentifiers): import("react/jsx-runtime").JSX.Element;
|
|
95
95
|
/**
|
|
96
96
|
* Hook to obtain loading status of the {@link ClientWorkspaceProvider} - "success", "error", "loading" or "pending".
|
|
97
97
|
* @alpha
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClientWorkspaceContext.d.ts","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/ClientWorkspaceContext.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ClientWorkspaceContext.d.ts","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/ClientWorkspaceContext.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAA6B,MAAM,OAAO,CAAC;AAK7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAE/D,OAAO,EAAE,2BAA2B,EAAE,sBAAsB,EAAE,MAAM,iBAAiB,CAAC;AAEtF,OAAO,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEpE,OAAO,EACH,yBAAyB,EACzB,0BAA0B,EAE7B,MAAM,4BAA4B,CAAC;AAGpC;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,yBAAyB,CAC3D,2BAA2B,EAC3B,gBAAgB,CACnB,GACG,sBAAsB,CAAC;AAU3B;;;;GAIG;AACH,MAAM,WAAW,iCAAiC;IAC9C;;;;;OAKG;IACH,OAAO,CAAC,EAAE,kBAAkB,CAAC;IAE7B;;OAEG;IACH,QAAQ,EAAE,SAAS,CAAC;CACvB;AAED;;GAEG;AACH,MAAM,WAAW,0CAA2C,SAAQ,iCAAiC;IACjG;;;;;OAKG;IACH,SAAS,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,qDACb,SAAQ,iCAAiC;IACzC;;;;;OAKG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;;;OAIG;IACH,MAAM,EAAE,MAAM,CAAC;CAClB;AAED;;;GAGG;AACH,MAAM,MAAM,6BAA6B,GACnC,0CAA0C,GAC1C,qDAAqD,CAAC;AAE5D;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,6BAA6B,2CAoB3E;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,2BAA2B,2CAiBjF;AAED;;;GAGG;AACH,eAAO,MAAM,wBAAwB,QAAO,0BAG3C,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,uBAAuB,QAAO,gBAAgB,GAAG,SAG7D,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,6BAA6B,QAAO,2BAGhD,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,6BAA6B,QAAO,OAGhD,CAAC"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// (C) 2019-2025 GoodData Corporation
|
|
2
|
-
import
|
|
3
|
+
import { createContext, useContext } from "react";
|
|
3
4
|
import isEmpty from "lodash/isEmpty.js";
|
|
4
5
|
import { invariant } from "ts-invariant";
|
|
5
6
|
import { resolveLCMWorkspaceIdentifiers } from "./resolveLCMWorkspaceIdentifiers.js";
|
|
6
7
|
import { useBackendStrict } from "../BackendContext.js";
|
|
7
8
|
import { useCancelablePromise, } from "../useCancelablePromise.js";
|
|
8
9
|
import { WorkspaceProvider, useWorkspace } from "../WorkspaceContext.js";
|
|
9
|
-
const ClientWorkspaceContext =
|
|
10
|
+
const ClientWorkspaceContext = createContext({
|
|
10
11
|
status: "pending",
|
|
11
12
|
error: undefined,
|
|
12
13
|
result: undefined,
|
|
@@ -39,8 +40,7 @@ export function ClientWorkspaceProvider(props) {
|
|
|
39
40
|
promise: () => resolveLCMWorkspaceIdentifiers(backend, { client, dataProduct, workspace }),
|
|
40
41
|
}, [client, dataProduct, workspace, backend]);
|
|
41
42
|
const ws = lcmIdentifiers.result?.workspace;
|
|
42
|
-
return (
|
|
43
|
-
React.createElement(WorkspaceProvider, { workspace: ws }, children)));
|
|
43
|
+
return (_jsx(ClientWorkspaceContext.Provider, { value: { ...lcmIdentifiers, isInitialized: true }, children: _jsx(WorkspaceProvider, { workspace: ws, children: children }) }));
|
|
44
44
|
}
|
|
45
45
|
/**
|
|
46
46
|
* ResolvedClientWorkspaceProvider can be used as a replacement of the {@link WorkspaceProvider}, if you are accessing
|
|
@@ -65,15 +65,14 @@ export function ResolvedClientWorkspaceProvider(props) {
|
|
|
65
65
|
error: undefined,
|
|
66
66
|
isInitialized: true,
|
|
67
67
|
};
|
|
68
|
-
return (
|
|
69
|
-
React.createElement(WorkspaceProvider, { workspace: props.workspace }, props.children)));
|
|
68
|
+
return (_jsx(ClientWorkspaceContext.Provider, { value: context, children: _jsx(WorkspaceProvider, { workspace: props.workspace, children: props.children }) }));
|
|
70
69
|
}
|
|
71
70
|
/**
|
|
72
71
|
* Hook to obtain loading status of the {@link ClientWorkspaceProvider} - "success", "error", "loading" or "pending".
|
|
73
72
|
* @alpha
|
|
74
73
|
*/
|
|
75
74
|
export const useClientWorkspaceStatus = () => {
|
|
76
|
-
const context =
|
|
75
|
+
const context = useContext(ClientWorkspaceContext);
|
|
77
76
|
return context.status;
|
|
78
77
|
};
|
|
79
78
|
/**
|
|
@@ -81,7 +80,7 @@ export const useClientWorkspaceStatus = () => {
|
|
|
81
80
|
* @alpha
|
|
82
81
|
*/
|
|
83
82
|
export const useClientWorkspaceError = () => {
|
|
84
|
-
const context =
|
|
83
|
+
const context = useContext(ClientWorkspaceContext);
|
|
85
84
|
return context.error;
|
|
86
85
|
};
|
|
87
86
|
/**
|
|
@@ -89,7 +88,7 @@ export const useClientWorkspaceError = () => {
|
|
|
89
88
|
* @alpha
|
|
90
89
|
*/
|
|
91
90
|
export const useClientWorkspaceIdentifiers = () => {
|
|
92
|
-
const context =
|
|
91
|
+
const context = useContext(ClientWorkspaceContext);
|
|
93
92
|
return context.result ?? {};
|
|
94
93
|
};
|
|
95
94
|
/**
|
|
@@ -98,7 +97,7 @@ export const useClientWorkspaceIdentifiers = () => {
|
|
|
98
97
|
* @alpha
|
|
99
98
|
*/
|
|
100
99
|
export const useClientWorkspaceInitialized = () => {
|
|
101
|
-
const context =
|
|
100
|
+
const context = useContext(ClientWorkspaceContext);
|
|
102
101
|
return context.isInitialized;
|
|
103
102
|
};
|
|
104
103
|
//
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ClientWorkspaceContext.js","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/ClientWorkspaceContext.tsx"],"names":[],"mappings":"AAAA,qCAAqC;
|
|
1
|
+
{"version":3,"file":"ClientWorkspaceContext.js","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/ClientWorkspaceContext.tsx"],"names":[],"mappings":";AAAA,qCAAqC;AAErC,OAAO,EAAa,aAAa,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAE7D,OAAO,OAAO,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAA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U,CAAC,sBAAsB,CAAC,CAAC;IACnD,OAAO,OAAO,CAAC,aAAa,CAAC;AACjC,CAAC,CAAC;AAEF,EAAE;AACF,EAAE;AACF,EAAE;AAEF,SAAS,gBAAgB,CAAI,GAAM;IAC/B,OAAO,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAE,GAA2B,CAAC,WAAW,CAAC,CAAC;AACxE,CAAC;AAED,SAAS,+BAA+B,CAAC,KAAoC;IACzE,IAAI,gBAAgB,CAAC,KAAK,CAAC,EAAE,CAAC;QAC1B,OAAO;YACH,SAAS,EAAE,KAAK,CAAC,SAAS;SAC7B,CAAC;IACN,CAAC;IAED,SAAS,CACL,KAAK,CAAC,MAAM,IAAI,KAAK,CAAC,WAAW,EACjC,wHAAwH,CAC3H,CAAC;IACF,OAAO;QACH,MAAM,EAAE,KAAK,CAAC,MAAM;QACpB,WAAW,EAAE,KAAK,CAAC,WAAW;KACjC,CAAC;AACN,CAAC"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
1
2
|
/**
|
|
2
3
|
* Resolved LCM identifiers of the workspace.
|
|
3
4
|
*
|
|
@@ -23,7 +24,7 @@ export interface IClientWorkspaceIdentifiers {
|
|
|
23
24
|
/**
|
|
24
25
|
* React children
|
|
25
26
|
*/
|
|
26
|
-
children?:
|
|
27
|
+
children?: ReactNode;
|
|
27
28
|
}
|
|
28
29
|
/**
|
|
29
30
|
* @internal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/interfaces.ts"],"names":[],"mappings":"AAEA;;;;GAIG;AACH,MAAM,WAAW,2BAA2B;IACxC;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,QAAQ,CAAC,EAAE,
|
|
1
|
+
{"version":3,"file":"interfaces.d.ts","sourceRoot":"","sources":["../../../../src/base/react/ClientWorkspaceContext/interfaces.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC;;;;GAIG;AACH,MAAM,WAAW,2BAA2B;IACxC;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACnC,aAAa,EAAE,OAAO,CAAC;CAC1B"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
2
|
import { IAnalyticalBackend, IRequestCorrelationMetadata } from "@gooddata/sdk-backend-spi";
|
|
3
3
|
/**
|
|
4
4
|
* Props of the {@link CorrelationProvider} component.
|
|
@@ -12,7 +12,7 @@ export interface ICorrelationProviderProps {
|
|
|
12
12
|
/**
|
|
13
13
|
* React children
|
|
14
14
|
*/
|
|
15
|
-
children?:
|
|
15
|
+
children?: ReactNode;
|
|
16
16
|
}
|
|
17
17
|
/**
|
|
18
18
|
* CorrelationProvider provides request correlation metadata to components.
|
|
@@ -20,7 +20,7 @@ export interface ICorrelationProviderProps {
|
|
|
20
20
|
*
|
|
21
21
|
* @public
|
|
22
22
|
*/
|
|
23
|
-
export declare function CorrelationProvider({ children, correlationData }: ICorrelationProviderProps):
|
|
23
|
+
export declare function CorrelationProvider({ children, correlationData }: ICorrelationProviderProps): import("react/jsx-runtime").JSX.Element;
|
|
24
24
|
/**
|
|
25
25
|
* Hook to get correlation metadata from the nearest correlation provider.
|
|
26
26
|
*
|
|
@@ -57,7 +57,7 @@ export interface IBackendProviderWithCorrelationProps {
|
|
|
57
57
|
/**
|
|
58
58
|
* React children
|
|
59
59
|
*/
|
|
60
|
-
children?:
|
|
60
|
+
children?: ReactNode;
|
|
61
61
|
}
|
|
62
62
|
/**
|
|
63
63
|
* Combined provider for both backend and correlation metadata.
|
|
@@ -66,5 +66,5 @@ export interface IBackendProviderWithCorrelationProps {
|
|
|
66
66
|
*
|
|
67
67
|
* @public
|
|
68
68
|
*/
|
|
69
|
-
export declare function BackendProviderWithCorrelation({ backend: externalBackend, correlationData, children, }: IBackendProviderWithCorrelationProps):
|
|
69
|
+
export declare function BackendProviderWithCorrelation({ backend: externalBackend, correlationData, children, }: IBackendProviderWithCorrelationProps): import("react/jsx-runtime").JSX.Element;
|
|
70
70
|
//# sourceMappingURL=CorrelationContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CorrelationContext.d.ts","sourceRoot":"","sources":["../../../src/base/react/CorrelationContext.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"CorrelationContext.d.ts","sourceRoot":"","sources":["../../../src/base/react/CorrelationContext.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAsC,MAAM,OAAO,CAAC;AAEtE,OAAO,EAAE,kBAAkB,EAAE,2BAA2B,EAAE,MAAM,2BAA2B,CAAC;AAU5F;;;GAGG;AACH,MAAM,WAAW,yBAAyB;IACtC;;OAEG;IACH,eAAe,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAExC;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,EAAE,QAAQ,EAAE,eAAe,EAAE,EAAE,yBAAyB,2CAe3F;AAED;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,QAAO,MAAM,CAAC,MAAM,EAAE,MAAM,CAE1D,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,yBAAyB,GAClC,UAAU,kBAAkB,EAC5B,sBAAsB,2BAA2B,KAClD,kBAAkB,GAAG,SAqBvB,CAAC;AAEF;;;;GAIG;AACH,MAAM,WAAW,oCAAoC;IACjD;;OAEG;IACH,OAAO,CAAC,EAAE,kBAAkB,CAAC;IAE7B;;OAEG;IACH,eAAe,EAAE,2BAA2B,CAAC;IAE7C;;OAEG;IACH,QAAQ,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;;;;GAMG;AACH,wBAAgB,8BAA8B,CAAC,EAC3C,OAAO,EAAE,eAAe,EACxB,eAAe,EACf,QAAQ,GACX,EAAE,oCAAoC,2CAoCtC"}
|