@gooddata/sdk-ui-dashboard 10.20.0-alpha.33 → 10.20.0-alpha.35

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.
Files changed (27) hide show
  1. package/esm/__version.d.ts +1 -1
  2. package/esm/__version.js +1 -1
  3. package/esm/presentation/widget/description/ExportModeInsightWidgetDescription.d.ts +9 -0
  4. package/esm/presentation/widget/description/ExportModeInsightWidgetDescription.d.ts.map +1 -0
  5. package/esm/presentation/widget/description/ExportModeInsightWidgetDescription.js +19 -0
  6. package/esm/presentation/widget/description/ExportModeInsightWidgetDescription.js.map +1 -0
  7. package/esm/presentation/widget/description/InsightWidgetDescriptionComponentProvider.d.ts +12 -0
  8. package/esm/presentation/widget/description/InsightWidgetDescriptionComponentProvider.d.ts.map +1 -0
  9. package/esm/presentation/widget/description/InsightWidgetDescriptionComponentProvider.js +15 -0
  10. package/esm/presentation/widget/description/InsightWidgetDescriptionComponentProvider.js.map +1 -0
  11. package/esm/presentation/widget/description/InsightWidgetDescriptionTrigger.d.ts.map +1 -1
  12. package/esm/presentation/widget/description/InsightWidgetDescriptionTrigger.js +8 -12
  13. package/esm/presentation/widget/description/InsightWidgetDescriptionTrigger.js.map +1 -1
  14. package/esm/presentation/widget/description/types.d.ts +2 -0
  15. package/esm/presentation/widget/description/types.d.ts.map +1 -1
  16. package/esm/presentation/widget/description/useInsightWidgetDescription.d.ts +7 -0
  17. package/esm/presentation/widget/description/useInsightWidgetDescription.d.ts.map +1 -0
  18. package/esm/presentation/widget/description/useInsightWidgetDescription.js +21 -0
  19. package/esm/presentation/widget/description/useInsightWidgetDescription.js.map +1 -0
  20. package/esm/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.d.ts.map +1 -1
  21. package/esm/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.js +3 -2
  22. package/esm/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.js.map +1 -1
  23. package/esm/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.d.ts +6 -0
  24. package/esm/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.d.ts.map +1 -1
  25. package/esm/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.js +10 -1
  26. package/esm/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.js.map +1 -1
  27. package/package.json +15 -15
@@ -1,2 +1,2 @@
1
- export declare const LIB_VERSION = "10.20.0-alpha.33";
1
+ export declare const LIB_VERSION = "10.20.0-alpha.35";
2
2
  //# sourceMappingURL=__version.d.ts.map
package/esm/__version.js CHANGED
@@ -1,4 +1,4 @@
1
1
  // (C) 2021 GoodData Corporation
2
2
  // DO NOT CHANGE THIS FILE, IT IS RE-GENERATED ON EVERY BUILD
3
- export const LIB_VERSION = "10.20.0-alpha.33";
3
+ export const LIB_VERSION = "10.20.0-alpha.35";
4
4
  //# sourceMappingURL=__version.js.map
@@ -0,0 +1,9 @@
1
+ import React from "react";
2
+ import { IInsightWidgetDescriptionTriggerProps } from "./types.js";
3
+ /**
4
+ * Simplified version of the InsightWidgetDescriptionTrigger component that is used in export mode.
5
+ *
6
+ * It is hidden, but holds the export data and content for exporter.
7
+ */
8
+ export declare const ExportModeInsightWidgetDescription: React.FC<IInsightWidgetDescriptionTriggerProps>;
9
+ //# sourceMappingURL=ExportModeInsightWidgetDescription.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExportModeInsightWidgetDescription.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/ExportModeInsightWidgetDescription.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,qCAAqC,EAAE,MAAM,YAAY,CAAC;AAGnE;;;;GAIG;AACH,eAAO,MAAM,kCAAkC,EAAE,KAAK,CAAC,EAAE,CAAC,qCAAqC,CAe9F,CAAC"}
@@ -0,0 +1,19 @@
1
+ // (C) 2025 GoodData Corporation
2
+ import React from "react";
3
+ import { DescriptionPanelContent } from "@gooddata/sdk-ui-kit";
4
+ import { useInsightWidgetDescription } from "./useInsightWidgetDescription.js";
5
+ /**
6
+ * Simplified version of the InsightWidgetDescriptionTrigger component that is used in export mode.
7
+ *
8
+ * It is hidden, but holds the export data and content for exporter.
9
+ */
10
+ export const ExportModeInsightWidgetDescription = (props) => {
11
+ const { exportData } = props;
12
+ const { isVisible, description, useRichText } = useInsightWidgetDescription(props);
13
+ if (!isVisible) {
14
+ return null;
15
+ }
16
+ return (React.createElement("div", { style: { display: "none" }, ...exportData },
17
+ React.createElement(DescriptionPanelContent, { description: description, useRichText: useRichText })));
18
+ };
19
+ //# sourceMappingURL=ExportModeInsightWidgetDescription.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExportModeInsightWidgetDescription.js","sourceRoot":"","sources":["../../../../src/presentation/widget/description/ExportModeInsightWidgetDescription.tsx"],"names":[],"mappings":"AAAA,gCAAgC;AAEhC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAE/E;;;;GAIG;AACH,MAAM,CAAC,MAAM,kCAAkC,GAAoD,CAC/F,KAAK,EACP,EAAE;IACA,MAAM,EAAE,UAAU,EAAE,GAAG,KAAK,CAAC;IAC7B,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,2BAA2B,CAAC,KAAK,CAAC,CAAC;IAEnF,IAAI,CAAC,SAAS,EAAE,CAAC;QACb,OAAO,IAAI,CAAC;IAChB,CAAC;IAED,OAAO,CACH,6BAAK,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,KAAM,UAAU;QAC3C,oBAAC,uBAAuB,IAAC,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,GAAI,CAC7E,CACT,CAAC;AACN,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import React, { ReactNode } from "react";
2
+ import { IInsightWidgetDescriptionTriggerProps } from "./types.js";
3
+ interface InsightWidgetDescriptionComponentContextType {
4
+ InsightWidgetDescriptionComponent: React.FC<IInsightWidgetDescriptionTriggerProps>;
5
+ }
6
+ export declare const InsightWidgetDescriptionComponentProvider: React.FC<{
7
+ InsightWidgetDescriptionComponent: React.FC<IInsightWidgetDescriptionTriggerProps>;
8
+ children: ReactNode;
9
+ }>;
10
+ export declare const useInsightWidgetDescriptionComponent: () => InsightWidgetDescriptionComponentContextType;
11
+ export {};
12
+ //# sourceMappingURL=InsightWidgetDescriptionComponentProvider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InsightWidgetDescriptionComponentProvider.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionComponentProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAA6B,SAAS,EAAE,MAAM,OAAO,CAAC;AACpE,OAAO,EAAE,qCAAqC,EAAE,MAAM,YAAY,CAAC;AAGnE,UAAU,4CAA4C;IAClD,iCAAiC,EAAE,KAAK,CAAC,EAAE,CAAC,qCAAqC,CAAC,CAAC;CACtF;AAMD,eAAO,MAAM,yCAAyC,EAAE,KAAK,CAAC,EAAE,CAAC;IAC7D,iCAAiC,EAAE,KAAK,CAAC,EAAE,CAAC,qCAAqC,CAAC,CAAC;IACnF,QAAQ,EAAE,SAAS,CAAC;CACvB,CAMA,CAAC;AAEF,eAAO,MAAM,oCAAoC,QAAO,4CAMvD,CAAC"}
@@ -0,0 +1,15 @@
1
+ // (C) 2025 GoodData Corporation
2
+ import React, { createContext, useContext } from "react";
3
+ import { InsightWidgetDescriptionTrigger } from "./InsightWidgetDescriptionTrigger.js";
4
+ const InsightWidgetDescriptionComponentContext = createContext(undefined);
5
+ export const InsightWidgetDescriptionComponentProvider = ({ InsightWidgetDescriptionComponent, children }) => {
6
+ return (React.createElement(InsightWidgetDescriptionComponentContext.Provider, { value: { InsightWidgetDescriptionComponent } }, children));
7
+ };
8
+ export const useInsightWidgetDescriptionComponent = () => {
9
+ const context = useContext(InsightWidgetDescriptionComponentContext);
10
+ if (!context) {
11
+ return { InsightWidgetDescriptionComponent: InsightWidgetDescriptionTrigger };
12
+ }
13
+ return context;
14
+ };
15
+ //# sourceMappingURL=InsightWidgetDescriptionComponentProvider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"InsightWidgetDescriptionComponentProvider.js","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionComponentProvider.tsx"],"names":[],"mappings":"AAAA,gCAAgC;AAEhC,OAAO,KAAK,EAAE,EAAE,aAAa,EAAE,UAAU,EAAa,MAAM,OAAO,CAAC;AAEpE,OAAO,EAAE,+BAA+B,EAAE,MAAM,sCAAsC,CAAC;AAMvF,MAAM,wCAAwC,GAAG,aAAa,CAE5D,SAAS,CAAC,CAAC;AAEb,MAAM,CAAC,MAAM,yCAAyC,GAGjD,CAAC,EAAE,iCAAiC,EAAE,QAAQ,EAAE,EAAE,EAAE;IACrD,OAAO,CACH,oBAAC,wCAAwC,CAAC,QAAQ,IAAC,KAAK,EAAE,EAAE,iCAAiC,EAAE,IAC1F,QAAQ,CACuC,CACvD,CAAC;AACN,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,oCAAoC,GAAG,GAAiD,EAAE;IACnG,MAAM,OAAO,GAAG,UAAU,CAAC,wCAAwC,CAAC,CAAC;IACrE,IAAI,CAAC,OAAO,EAAE,CAAC;QACX,OAAO,EAAE,iCAAiC,EAAE,+BAA+B,EAAE,CAAC;IAClF,CAAC;IACD,OAAO,OAAO,CAAC;AACnB,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"InsightWidgetDescriptionTrigger.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionTrigger.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,EAAE,qCAAqC,EAAE,MAAM,YAAY,CAAC;AAQnE,eAAO,MAAM,+BAA+B,EAAE,KAAK,CAAC,EAAE,CAAC,qCAAqC,CA+B3F,CAAC"}
1
+ {"version":3,"file":"InsightWidgetDescriptionTrigger.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionTrigger.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,EAAE,qCAAqC,EAAE,MAAM,YAAY,CAAC;AAInE,eAAO,MAAM,+BAA+B,EAAE,KAAK,CAAC,EAAE,CAAC,qCAAqC,CAwB3F,CAAC"}
@@ -1,26 +1,22 @@
1
- // (C) 2022-2024 GoodData Corporation
1
+ // (C) 2022-2025 GoodData Corporation
2
2
  import React from "react";
3
3
  import { objRefToString, widgetRef } from "@gooddata/sdk-model";
4
4
  import { stringUtils } from "@gooddata/util";
5
5
  import { DescriptionClickTrigger } from "./DescriptionClickTrigger.js";
6
- import { useDashboardSelector, useDashboardUserInteraction, selectEnableRichTextDescriptions, } from "../../../model/index.js";
6
+ import { useDashboardUserInteraction } from "../../../model/index.js";
7
+ import { useInsightWidgetDescription } from "./useInsightWidgetDescription.js";
7
8
  export const InsightWidgetDescriptionTrigger = (props) => {
8
- const { widget, insight } = props;
9
- const visible = widget.configuration?.description?.visible ?? true;
10
- const description = widget.configuration?.description?.source === "widget" || !insight
11
- ? widget.description
12
- : insight.insight.summary;
13
- const trimmedDescription = description?.trim();
9
+ const { widget } = props;
10
+ const { isVisible, description, useRichText } = useInsightWidgetDescription(props);
14
11
  const widgetRefAsString = objRefToString(widgetRef(widget));
15
12
  const userInteraction = useDashboardUserInteraction();
16
13
  const eventPayload = {
17
14
  from: "widget",
18
15
  type: widget.configuration?.description?.source === "widget" ? "custom" : "inherit",
19
- description: trimmedDescription,
16
+ description,
20
17
  };
21
- const useRichText = useDashboardSelector(selectEnableRichTextDescriptions);
22
- if (visible && trimmedDescription && trimmedDescription !== "") {
23
- return (React.createElement(DescriptionClickTrigger, { className: `widget-description-${stringUtils.simplifyText(widgetRefAsString)}`, description: trimmedDescription, onOpen: () => userInteraction.descriptionTooltipOpened(eventPayload), useRichText: useRichText }));
18
+ if (isVisible) {
19
+ return (React.createElement(DescriptionClickTrigger, { className: `widget-description-${stringUtils.simplifyText(widgetRefAsString)}`, description: description, onOpen: () => userInteraction.descriptionTooltipOpened(eventPayload), useRichText: useRichText }));
24
20
  }
25
21
  return null;
26
22
  };
@@ -1 +1 @@
1
- {"version":3,"file":"InsightWidgetDescriptionTrigger.js","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionTrigger.tsx"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAGvE,OAAO,EACH,oBAAoB,EACpB,2BAA2B,EAE3B,gCAAgC,GACnC,MAAM,yBAAyB,CAAC;AAEjC,MAAM,CAAC,MAAM,+BAA+B,GAAoD,CAAC,KAAK,EAAE,EAAE;IACtG,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,KAAK,CAAC;IAClC,MAAM,OAAO,GAAG,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,OAAO,IAAI,IAAI,CAAC;IACnE,MAAM,WAAW,GACb,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,MAAM,KAAK,QAAQ,IAAI,CAAC,OAAO;QAC9D,CAAC,CAAC,MAAM,CAAC,WAAW;QACpB,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;IAElC,MAAM,kBAAkB,GAAG,WAAW,EAAE,IAAI,EAAE,CAAC;IAC/C,MAAM,iBAAiB,GAAG,cAAc,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;IAE5D,MAAM,eAAe,GAAG,2BAA2B,EAAE,CAAC;IAEtD,MAAM,YAAY,GAAiC;QAC/C,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS;QACnF,WAAW,EAAE,kBAAkB;KAClC,CAAC;IACF,MAAM,WAAW,GAAG,oBAAoB,CAAC,gCAAgC,CAAC,CAAC;IAE3E,IAAI,OAAO,IAAI,kBAAkB,IAAI,kBAAkB,KAAK,EAAE,EAAE,CAAC;QAC7D,OAAO,CACH,oBAAC,uBAAuB,IACpB,SAAS,EAAE,sBAAsB,WAAW,CAAC,YAAY,CAAC,iBAAiB,CAAC,EAAE,EAC9E,WAAW,EAAE,kBAAkB,EAC/B,MAAM,EAAE,GAAG,EAAE,CAAC,eAAe,CAAC,wBAAwB,CAAC,YAAY,CAAC,EACpE,WAAW,EAAE,WAAW,GAC1B,CACL,CAAC;IACN,CAAC;IACD,OAAO,IAAI,CAAC;AAChB,CAAC,CAAC"}
1
+ {"version":3,"file":"InsightWidgetDescriptionTrigger.js","sourceRoot":"","sources":["../../../../src/presentation/widget/description/InsightWidgetDescriptionTrigger.tsx"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,OAAO,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AAGvE,OAAO,EAAE,2BAA2B,EAAgC,MAAM,yBAAyB,CAAC;AACpG,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAkC,CAAC;AAE/E,MAAM,CAAC,MAAM,+BAA+B,GAAoD,CAAC,KAAK,EAAE,EAAE;IACtG,MAAM,EAAE,MAAM,EAAE,GAAG,KAAK,CAAC;IACzB,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,GAAG,2BAA2B,CAAC,KAAK,CAAC,CAAC;IACnF,MAAM,iBAAiB,GAAG,cAAc,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;IAE5D,MAAM,eAAe,GAAG,2BAA2B,EAAE,CAAC;IAEtD,MAAM,YAAY,GAAiC;QAC/C,IAAI,EAAE,QAAQ;QACd,IAAI,EAAE,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,MAAM,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS;QACnF,WAAW;KACd,CAAC;IAEF,IAAI,SAAS,EAAE,CAAC;QACZ,OAAO,CACH,oBAAC,uBAAuB,IACpB,SAAS,EAAE,sBAAsB,WAAW,CAAC,YAAY,CAAC,iBAAiB,CAAC,EAAE,EAC9E,WAAW,EAAE,WAAW,EACxB,MAAM,EAAE,GAAG,EAAE,CAAC,eAAe,CAAC,wBAAwB,CAAC,YAAY,CAAC,EACpE,WAAW,EAAE,WAAW,GAC1B,CACL,CAAC;IACN,CAAC;IACD,OAAO,IAAI,CAAC;AAChB,CAAC,CAAC"}
@@ -1,8 +1,10 @@
1
1
  import { IInsight, IInsightWidget, ScreenSize } from "@gooddata/sdk-model";
2
+ import { CommonExportDataAttributes } from "src/presentation/export/types.js";
2
3
  export interface IInsightWidgetDescriptionTriggerProps {
3
4
  widget: IInsightWidget;
4
5
  insight?: IInsight;
5
6
  screen: ScreenSize;
7
+ exportData?: CommonExportDataAttributes;
6
8
  }
7
9
  export interface IDescriptionClickTriggerProps {
8
10
  className: string;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAE3E,MAAM,WAAW,qCAAqC;IAClD,MAAM,EAAE,cAAc,CAAC;IACvB,OAAO,CAAC,EAAE,QAAQ,CAAC;IACnB,MAAM,EAAE,UAAU,CAAC;CACtB;AAED,MAAM,WAAW,6BAA6B;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACzB"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC3E,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAC;AAE9E,MAAM,WAAW,qCAAqC;IAClD,MAAM,EAAE,cAAc,CAAC;IACvB,OAAO,CAAC,EAAE,QAAQ,CAAC;IACnB,MAAM,EAAE,UAAU,CAAC;IACnB,UAAU,CAAC,EAAE,0BAA0B,CAAC;CAC3C;AAED,MAAM,WAAW,6BAA6B;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACzB"}
@@ -0,0 +1,7 @@
1
+ import { IInsightWidgetDescriptionTriggerProps } from "./types.js";
2
+ export declare const useInsightWidgetDescription: (props: IInsightWidgetDescriptionTriggerProps) => {
3
+ isVisible: boolean | "" | undefined;
4
+ description: string | undefined;
5
+ useRichText: boolean;
6
+ };
7
+ //# sourceMappingURL=useInsightWidgetDescription.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useInsightWidgetDescription.d.ts","sourceRoot":"","sources":["../../../../src/presentation/widget/description/useInsightWidgetDescription.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,qCAAqC,EAAE,MAAM,YAAY,CAAC;AAGnE,eAAO,MAAM,2BAA2B,UAAW,qCAAqC;;;;CAuBvF,CAAC"}
@@ -0,0 +1,21 @@
1
+ // (C) 2025 GoodData Corporation
2
+ import { useMemo } from "react";
3
+ import { selectEnableRichTextDescriptions, useDashboardSelector } from "../../../model/index.js";
4
+ export const useInsightWidgetDescription = (props) => {
5
+ const { widget, insight } = props;
6
+ const useRichText = useDashboardSelector(selectEnableRichTextDescriptions);
7
+ const description = useMemo(() => {
8
+ return widget.configuration?.description?.source === "widget" || !insight
9
+ ? widget.description
10
+ : insight.insight.summary;
11
+ }, [widget, insight]);
12
+ const trimmedDescription = useMemo(() => description?.trim(), [description]);
13
+ const visible = widget.configuration?.description?.visible ?? true;
14
+ const isVisible = useMemo(() => visible && trimmedDescription && trimmedDescription !== "", [visible, trimmedDescription]);
15
+ return {
16
+ isVisible,
17
+ description,
18
+ useRichText,
19
+ };
20
+ };
21
+ //# sourceMappingURL=useInsightWidgetDescription.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"useInsightWidgetDescription.js","sourceRoot":"","sources":["../../../../src/presentation/widget/description/useInsightWidgetDescription.ts"],"names":[],"mappings":"AAAA,gCAAgC;AAEhC,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAEhC,OAAO,EAAE,gCAAgC,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAEjG,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAAC,KAA4C,EAAE,EAAE;IACxF,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,GAAG,KAAK,CAAC;IAElC,MAAM,WAAW,GAAG,oBAAoB,CAAC,gCAAgC,CAAC,CAAC;IAE3E,MAAM,WAAW,GAAG,OAAO,CAAC,GAAG,EAAE;QAC7B,OAAO,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,MAAM,KAAK,QAAQ,IAAI,CAAC,OAAO;YACrE,CAAC,CAAC,MAAM,CAAC,WAAW;YACpB,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC;IAClC,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC;IACtB,MAAM,kBAAkB,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,IAAI,EAAE,EAAE,CAAC,WAAW,CAAC,CAAC,CAAC;IAE7E,MAAM,OAAO,GAAG,MAAM,CAAC,aAAa,EAAE,WAAW,EAAE,OAAO,IAAI,IAAI,CAAC;IACnE,MAAM,SAAS,GAAG,OAAO,CACrB,GAAG,EAAE,CAAC,OAAO,IAAI,kBAAkB,IAAI,kBAAkB,KAAK,EAAE,EAChE,CAAC,OAAO,EAAE,kBAAkB,CAAC,CAChC,CAAC;IAEF,OAAO;QACH,SAAS;QACT,WAAW;QACX,WAAW;KACd,CAAC;AACN,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"DefaultDashboardInsightWidget.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.tsx"],"names":[],"mappings":"AACA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAwBpD,OAAO,EAAE,mCAAmC,EAAE,MAAM,YAAY,CAAC;AAIjE,eAAO,MAAM,6BAA6B,EAAE,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,mCAAmC,EAAE,SAAS,CAAC,CAIxG,CAAC"}
1
+ {"version":3,"file":"DefaultDashboardInsightWidget.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.tsx"],"names":[],"mappings":"AACA,OAAO,KAA+B,MAAM,OAAO,CAAC;AAuBpD,OAAO,EAAE,mCAAmC,EAAE,MAAM,YAAY,CAAC;AAKjE,eAAO,MAAM,6BAA6B,EAAE,KAAK,CAAC,EAAE,CAAC,IAAI,CAAC,mCAAmC,EAAE,SAAS,CAAC,CAIxG,CAAC"}
@@ -8,11 +8,11 @@ import { DashboardItem, DashboardItemHeadline, DashboardItemVisualization, getVi
8
8
  import { DashboardInsight } from "../../insight/index.js";
9
9
  import { useInsightExport } from "../../common/index.js";
10
10
  import { useDashboardComponentsContext } from "../../../dashboardContexts/index.js";
11
- import { InsightWidgetDescriptionTrigger } from "../../description/InsightWidgetDescriptionTrigger.js";
12
11
  import { useInsightMenu } from "./useInsightMenu.js";
13
12
  import { DashboardWidgetInsightGuard } from "./DashboardWidgetInsightGuard.js";
14
13
  import { useAlertingAndScheduling } from "./useAlertingAndScheduling.js";
15
14
  import { useWidgetHighlighting } from "../../common/useWidgetHighlighting.js";
15
+ import { useInsightWidgetDescriptionComponent } from "../../description/InsightWidgetDescriptionComponentProvider.js";
16
16
  export const DefaultDashboardInsightWidget = (props) => {
17
17
  return React.createElement(DashboardWidgetInsightGuard, { ...props, Component: DefaultDashboardInsightWidgetCore });
18
18
  };
@@ -71,6 +71,7 @@ const DefaultDashboardInsightWidgetCore = ({ widget, insight, screen, onError, o
71
71
  const InsightMenuButtonComponent = useMemo(() => InsightMenuButtonComponentProvider(insight, widget), [InsightMenuButtonComponentProvider, insight, widget]);
72
72
  const InsightMenuComponent = useMemo(() => InsightMenuComponentProvider(insight, widget), [InsightMenuComponentProvider, insight, widget]);
73
73
  const { elementRef, highlighted } = useWidgetHighlighting(widget);
74
+ const { InsightWidgetDescriptionComponent } = useInsightWidgetDescriptionComponent();
74
75
  const accessibilityWidgetDescription = settings.enableDescriptions
75
76
  ? widget.configuration?.description?.source === "widget" || !insight
76
77
  ? widget.description
@@ -78,7 +79,7 @@ const DefaultDashboardInsightWidgetCore = ({ widget, insight, screen, onError, o
78
79
  : "";
79
80
  return (React.createElement(DashboardItem, { className: cx(dashboardItemClasses, "type-visualization", "gd-dashboard-view-widget", getVisTypeCssClass(widget.type, visType), { "gd-highlighted": highlighted }), screen: screen, ref: elementRef, description: accessibilityWidgetDescription },
80
81
  React.createElement(DashboardItemVisualization, { renderHeadline: (clientHeight) => !widget.configuration?.hideTitle && (React.createElement(DashboardItemHeadline, { title: widget.title, clientHeight: clientHeight, exportData: exportData?.title })), renderBeforeVisualization: () => (React.createElement("div", { className: "gd-absolute-row" },
81
- settings?.enableDescriptions ? (React.createElement(InsightWidgetDescriptionTrigger, { insight: insight, widget: widget, screen: screen })) : null,
82
+ settings?.enableDescriptions ? (React.createElement(InsightWidgetDescriptionComponent, { insight: insight, widget: widget, screen: screen, exportData: exportData?.description })) : null,
82
83
  React.createElement(InsightMenuButtonComponent, { insight: insight, widget: widget, isOpen: isMenuOpen, onClick: toggleMenu, items: menuItems }))), renderAfterContent: () => {
83
84
  if (!isMenuOpen) {
84
85
  return null;
@@ -1 +1 @@
1
- {"version":3,"file":"DefaultDashboardInsightWidget.js","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.tsx"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpD,OAAO,EAAE,MAAM,YAAY,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AACrC,OAAO,EAAY,WAAW,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAGtF,OAAO,EACH,oBAAoB,EACpB,cAAc,EACd,2BAA2B,GAC9B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACH,aAAa,EACb,qBAAqB,EACrB,0BAA0B,EAC1B,kBAAkB,GACrB,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,OAAO,EAAE,6BAA6B,EAAE,MAAM,qCAAqC,CAAC;AACpF,OAAO,EAAE,+BAA+B,EAAE,MAAM,sDAAsD,CAAC;AAEvG,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,2BAA2B,EAAE,MAAM,kCAAk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d,MAAM,EAAE,UAAU,EAClB,OAAO,EAAE,UAAU,EACnB,KAAK,EAAE,SAAS,GAClB,CACA,CACT,EACD,kBAAkB,EAAE,GAAG,EAAE;gBACrB,IAAI,CAAC,UAAU,EAAE,CAAC;oBACd,OAAO,IAAI,CAAC;gBAChB,CAAC;gBAED,OAAO,CACH,oBAAC,oBAAoB,IACjB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,UAAU,EAClB,OAAO,EAAE,SAAS,EAClB,KAAK,EAAE,SAAS,GAClB,CACL,CAAC;YACN,CAAC,IAEA,CAAC,EAAE,YAAY,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,CAChC,oBAAC,gBAAgB,IACb,YAAY,EAAE,YAAY,EAC1B,WAAW,EAAE,WAAW,EACxB,OAAO,EAAE,OAAO,EAChB,MAAM,EAAE,MAAM,EACd,aAAa,EAAE,aAAa,EAC5B,gBAAgB,EAAE,gBAAgB,EAClC,OAAO,EAAE,OAAO,EAChB,cAAc,EAAE,cAAc,EAC9B,gBAAgB,EAAE,gBAAgB,EAClC,UAAU,EAAE,UAAU,EAAE,MAAM,GAChC,CACL,CACwB,CACjB,CACnB,CAAC;AACN,CAAC,CAAC"}
1
+ {"version":3,"file":"DefaultDashboardInsightWidget.js","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/DefaultDashboardInsightWidget.tsx"],"names":[],"mappings":"AAAA,qCAAqC;AACrC,OAAO,KAAK,EAAE,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpD,OAAO,EAAE,MAAM,YAAY,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AACrC,OAAO,EAAY,WAAW,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAGtF,OAAO,EACH,oBAAoB,EACpB,cAAc,EACd,2BAA2B,GAC9B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACH,aAAa,EACb,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AC"}
@@ -1,4 +1,10 @@
1
1
  import React from "react";
2
2
  import { IDefaultDashboardInsightWidgetProps } from "./types.js";
3
+ /**
4
+ * Insight widget that can be exported.
5
+ *
6
+ * This component wraps the DefaultDashboardInsightWidget with the ExportModeInsightWidgetDescription
7
+ * to provide the description component that is not publicly customizable for exporter.
8
+ */
3
9
  export declare const ExportableDashboardInsightWidget: React.FC<IDefaultDashboardInsightWidgetProps>;
4
10
  //# sourceMappingURL=ExportableDashboardInsightWidget.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExportableDashboardInsightWidget.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,mCAAmC,EAAE,MAAM,YAAY,CAAC;AAGjE,eAAO,MAAM,gCAAgC,EAAE,KAAK,CAAC,EAAE,CAAC,mCAAmC,CAE1F,CAAC"}
1
+ {"version":3,"file":"ExportableDashboardInsightWidget.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,mCAAmC,EAAE,MAAM,YAAY,CAAC;AAKjE;;;;;GAKG;AACH,eAAO,MAAM,gCAAgC,EAAE,KAAK,CAAC,EAAE,CAAC,mCAAmC,CAQ1F,CAAC"}
@@ -1,7 +1,16 @@
1
1
  // (C) 2025 GoodData Corporation
2
2
  import React from "react";
3
3
  import { DefaultDashboardInsightWidget } from "./DefaultDashboardInsightWidget.js";
4
+ import { InsightWidgetDescriptionComponentProvider } from "../../description/InsightWidgetDescriptionComponentProvider.js";
5
+ import { ExportModeInsightWidgetDescription } from "../../description/ExportModeInsightWidgetDescription.js";
6
+ /**
7
+ * Insight widget that can be exported.
8
+ *
9
+ * This component wraps the DefaultDashboardInsightWidget with the ExportModeInsightWidgetDescription
10
+ * to provide the description component that is not publicly customizable for exporter.
11
+ */
4
12
  export const ExportableDashboardInsightWidget = (props) => {
5
- return React.createElement(DefaultDashboardInsightWidget, { ...props });
13
+ return (React.createElement(InsightWidgetDescriptionComponentProvider, { InsightWidgetDescriptionComponent: ExportModeInsightWidgetDescription },
14
+ React.createElement(DefaultDashboardInsightWidget, { ...props })));
6
15
  };
7
16
  //# sourceMappingURL=ExportableDashboardInsightWidget.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ExportableDashboardInsightWidget.js","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.tsx"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AAEnF,MAAM,CAAC,MAAM,gCAAgC,GAAkD,CAAC,KAAK,EAAE,EAAE;IACrG,OAAO,oBAAC,6BAA6B,OAAK,KAAK,GAAI,CAAC;AACxD,CAAC,CAAC"}
1
+ {"version":3,"file":"ExportableDashboardInsightWidget.js","sourceRoot":"","sources":["../../../../../src/presentation/widget/widget/InsightWidget/ExportableDashboardInsightWidget.tsx"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,6BAA6B,EAAE,MAAM,oCAAoC,CAAC;AACnF,OAAO,EAAE,yCAAyC,EAAE,MAAM,gEAAgE,CAAC;AAC3H,OAAO,EAAE,kCAAkC,EAAE,MAAM,yDAAyD,CAAC;AAE7G;;;;;GAKG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAkD,CAAC,KAAK,EAAE,EAAE;IACrG,OAAO,CACH,oBAAC,yCAAyC,IACtC,iCAAiC,EAAE,kCAAkC;QAErE,oBAAC,6BAA6B,OAAK,KAAK,GAAI,CACJ,CAC/C,CAAC;AACN,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gooddata/sdk-ui-dashboard",
3
- "version": "10.20.0-alpha.33",
3
+ "version": "10.20.0-alpha.35",
4
4
  "description": "GoodData SDK - Dashboard Component",
5
5
  "repository": {
6
6
  "type": "git",
@@ -57,17 +57,17 @@
57
57
  "ts-invariant": "^0.7.5",
58
58
  "tslib": "^2.5.0",
59
59
  "uuid": "^8.3.2",
60
- "@gooddata/sdk-backend-base": "10.20.0-alpha.33",
61
- "@gooddata/sdk-backend-spi": "10.20.0-alpha.33",
62
- "@gooddata/sdk-model": "10.20.0-alpha.33",
63
- "@gooddata/sdk-ui": "10.20.0-alpha.33",
64
- "@gooddata/sdk-ui-ext": "10.20.0-alpha.33",
65
- "@gooddata/sdk-ui-filters": "10.20.0-alpha.33",
66
- "@gooddata/sdk-ui-geo": "10.20.0-alpha.33",
67
- "@gooddata/sdk-ui-kit": "10.20.0-alpha.33",
68
- "@gooddata/sdk-ui-theme-provider": "10.20.0-alpha.33",
69
- "@gooddata/sdk-ui-vis-commons": "10.20.0-alpha.33",
70
- "@gooddata/util": "10.20.0-alpha.33"
60
+ "@gooddata/sdk-backend-spi": "10.20.0-alpha.35",
61
+ "@gooddata/sdk-backend-base": "10.20.0-alpha.35",
62
+ "@gooddata/sdk-ui": "10.20.0-alpha.35",
63
+ "@gooddata/sdk-ui-ext": "10.20.0-alpha.35",
64
+ "@gooddata/sdk-model": "10.20.0-alpha.35",
65
+ "@gooddata/sdk-ui-filters": "10.20.0-alpha.35",
66
+ "@gooddata/sdk-ui-geo": "10.20.0-alpha.35",
67
+ "@gooddata/sdk-ui-kit": "10.20.0-alpha.35",
68
+ "@gooddata/sdk-ui-theme-provider": "10.20.0-alpha.35",
69
+ "@gooddata/sdk-ui-vis-commons": "10.20.0-alpha.35",
70
+ "@gooddata/util": "10.20.0-alpha.35"
71
71
  },
72
72
  "peerDependencies": {
73
73
  "react": "^16.10.0 || ^17.0.0 || ^18.0.0",
@@ -120,9 +120,9 @@
120
120
  "typescript": "5.3.3",
121
121
  "vitest": "1.0.4",
122
122
  "vitest-dom": "0.1.1",
123
- "@gooddata/i18n-toolkit": "10.20.0-alpha.33",
124
- "@gooddata/reference-workspace": "10.20.0-alpha.33",
125
- "@gooddata/sdk-backend-mockingbird": "10.20.0-alpha.33"
123
+ "@gooddata/i18n-toolkit": "10.20.0-alpha.35",
124
+ "@gooddata/reference-workspace": "10.20.0-alpha.35",
125
+ "@gooddata/sdk-backend-mockingbird": "10.20.0-alpha.35"
126
126
  },
127
127
  "scripts": {
128
128
  "clean": "rm -rf ci dist esm coverage *.log styles/css tsconfig.tsbuildinfo",