@gooddata/sdk-ui-dashboard 11.43.0-alpha.4 → 11.43.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.
Files changed (103) hide show
  1. package/NOTICE +641 -841
  2. package/esm/__version.d.ts +1 -1
  3. package/esm/__version.d.ts.map +1 -1
  4. package/esm/__version.js +1 -1
  5. package/esm/index.d.ts +2 -2
  6. package/esm/index.d.ts.map +1 -1
  7. package/esm/index.js +2 -2
  8. package/esm/presentation/automations/{_staging/alerting → alerting}/AlertingManagementDialog.d.ts +1 -1
  9. package/esm/presentation/automations/alerting/AlertingManagementDialog.d.ts.map +1 -0
  10. package/esm/presentation/automations/{_staging/alerting → alerting}/AlertingManagementDialog.js +1 -1
  11. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentBasic.d.ts.map +1 -0
  12. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentBasic.js +8 -9
  13. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentEnhanced.d.ts.map +1 -0
  14. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentEnhanced.js +17 -29
  15. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogNew.d.ts +1 -1
  16. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogNew.d.ts.map +1 -0
  17. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogNew.js +9 -28
  18. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/Alert.d.ts.map +1 -0
  19. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/Alert.js +15 -18
  20. package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/AlertDropdown.d.ts +1 -1
  21. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/AlertDropdown.d.ts.map +1 -0
  22. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/AlertsList.d.ts.map +1 -0
  23. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.d.ts.map +1 -1
  24. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.js +2 -2
  25. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.d.ts.map +1 -0
  26. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.js +31 -0
  27. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.test.d.ts +2 -0
  28. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.test.d.ts.map +1 -0
  29. package/esm/presentation/automations/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.test.js +39 -0
  30. package/esm/presentation/automations/alerting/hooks/useAlertingDialogAccessibility.d.ts.map +1 -0
  31. package/esm/presentation/automations/alerting/hooks/useAlertingDialogAccessibility.js +11 -0
  32. package/esm/presentation/automations/connectors/AlertingConnector.d.ts +6 -3
  33. package/esm/presentation/automations/connectors/AlertingConnector.d.ts.map +1 -1
  34. package/esm/presentation/automations/connectors/AlertingConnector.js +75 -12
  35. package/esm/presentation/automations/connectors/AlertingConnector.test.d.ts +2 -0
  36. package/esm/presentation/automations/connectors/AlertingConnector.test.d.ts.map +1 -0
  37. package/esm/presentation/automations/connectors/AlertingConnector.test.js +152 -0
  38. package/esm/presentation/automations/connectors/DefaultAlertingManagementDialogConnected.d.ts +11 -0
  39. package/esm/presentation/automations/connectors/DefaultAlertingManagementDialogConnected.d.ts.map +1 -0
  40. package/esm/presentation/automations/connectors/DefaultAlertingManagementDialogConnected.js +20 -0
  41. package/esm/presentation/automations/connectors/hooks/useBuildAlertingManagementDialogContext.d.ts +3 -0
  42. package/esm/presentation/automations/connectors/hooks/useBuildAlertingManagementDialogContext.d.ts.map +1 -0
  43. package/esm/presentation/automations/connectors/hooks/useBuildAlertingManagementDialogContext.js +131 -0
  44. package/esm/presentation/automations/connectors/hooks/useBuildAutomationsContext.d.ts.map +1 -1
  45. package/esm/presentation/automations/connectors/hooks/useBuildAutomationsContext.js +4 -1
  46. package/esm/presentation/automations/connectors/hooks/useBuildAutomationsContext.test.js +2 -0
  47. package/esm/presentation/automations/contexts/AlertingManagementDialogContext.d.ts +27 -0
  48. package/esm/presentation/automations/contexts/AlertingManagementDialogContext.d.ts.map +1 -0
  49. package/esm/presentation/automations/contexts/AlertingManagementDialogContext.js +11 -0
  50. package/esm/presentation/automations/contexts/AutomationsContext.d.ts +1 -0
  51. package/esm/presentation/automations/contexts/AutomationsContext.d.ts.map +1 -1
  52. package/esm/presentation/automations/shared/automationFilters/components/AutomationDateFilter.test.js +1 -0
  53. package/esm/presentation/dashboard/DashboardHeader/AlertingDialogProvider.d.ts.map +1 -1
  54. package/esm/presentation/dashboard/DashboardHeader/AlertingDialogProvider.js +3 -17
  55. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeChrome.d.ts +5 -4
  56. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeChrome.d.ts.map +1 -1
  57. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeChrome.js +30 -48
  58. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeContext.d.ts +37 -0
  59. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeContext.d.ts.map +1 -0
  60. package/esm/presentation/dashboard/DashboardSidebar/SidebarResizeContext.js +90 -0
  61. package/esm/presentation/dashboard/components/DashboardInner.d.ts.map +1 -1
  62. package/esm/presentation/dashboard/components/DashboardInner.js +24 -14
  63. package/esm/presentation/dashboard/components/DashboardRenderer.js +1 -1
  64. package/esm/presentation/localization/bundles/zh-Hant.localization-bundle.js +1 -1
  65. package/esm/presentation/widget/insight/configuration/InsightAlertConfig/AlertsList.js +1 -1
  66. package/esm/presentation/widget/insight/configuration/InsightAlerts.d.ts.map +1 -1
  67. package/esm/presentation/widget/insight/configuration/InsightAlerts.js +8 -1
  68. package/esm/presentation/widget/insight/configuration/InsightAlertsNew.d.ts.map +1 -1
  69. package/esm/presentation/widget/insight/configuration/InsightAlertsNew.test.d.ts +2 -0
  70. package/esm/presentation/widget/insight/configuration/InsightAlertsNew.test.d.ts.map +1 -0
  71. package/esm/presentation/widget/insight/configuration/InsightAlertsNew.test.js +124 -0
  72. package/esm/sdk-ui-dashboard.d.ts +6 -1
  73. package/package.json +20 -20
  74. package/styles/css/configurationPanel.css +2 -3
  75. package/styles/css/configurationPanel.css.map +1 -1
  76. package/styles/css/main.css +8767 -11368
  77. package/styles/css/main.css.map +1 -1
  78. package/styles/scss/configurationPanel.scss +2 -3
  79. package/esm/presentation/automations/_staging/alerting/AlertingManagementDialog.d.ts.map +0 -1
  80. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentBasic.d.ts.map +0 -1
  81. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentEnhanced.d.ts.map +0 -1
  82. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogNew.d.ts.map +0 -1
  83. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/Alert.d.ts.map +0 -1
  84. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/AlertDropdown.d.ts.map +0 -1
  85. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/AlertsList.d.ts.map +0 -1
  86. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.d.ts +0 -11
  87. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.d.ts.map +0 -1
  88. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.js +0 -38
  89. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.d.ts.map +0 -1
  90. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.js +0 -50
  91. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/hooks/useAlertValidation.d.ts +0 -7
  92. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/hooks/useAlertValidation.d.ts.map +0 -1
  93. package/esm/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/hooks/useAlertValidation.js +0 -30
  94. package/esm/presentation/automations/_staging/alerting/hooks/useAlertingDialogAccessibility.d.ts.map +0 -1
  95. package/esm/presentation/automations/_staging/alerting/hooks/useAlertingDialogAccessibility.js +0 -12
  96. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentBasic.d.ts +0 -0
  97. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentEnhanced.d.ts +0 -0
  98. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/Alert.d.ts +0 -0
  99. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/AlertDropdown.js +0 -0
  100. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/AlertsList.d.ts +0 -0
  101. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/AlertsList.js +0 -0
  102. /package/esm/presentation/automations/{_staging/alerting → alerting}/DefaultAlertingManagementDialog/components/PauseAlertRunner.d.ts +0 -0
  103. /package/esm/presentation/automations/{_staging/alerting → alerting}/hooks/useAlertingDialogAccessibility.d.ts +0 -0
@@ -444,14 +444,13 @@
444
444
  margin-right: 15px;
445
445
  }
446
446
 
447
- .fixedDataTableRowLayout_rowWrapper:hover {
447
+ .gd-infinite-list-item:hover {
448
448
  // overwrite
449
449
  // stylelint-disable-next-line declaration-no-important
450
450
  z-index: 1 !important;
451
451
  }
452
452
 
453
- .public_fixedDataTableRow_main,
454
- .public_fixedDataTableCell_main {
453
+ .gd-infinite-list-item {
455
454
  background: none;
456
455
  }
457
456
 
@@ -1 +0,0 @@
1
- {"version":3,"file":"AlertingManagementDialog.d.ts","sourceRoot":"","sources":["../../../../../src/presentation/automations/_staging/alerting/AlertingManagementDialog.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AAG1C,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,yBAAyB,CAAC;AAE9E;;GAEG;AACH,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,8BAA8B,GAAG,YAAY,CAI5F"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"DefaultAlertingManagementDialogContentBasic.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentBasic.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAuBrE,UAAU,iDAAiD;IACvD,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,QAAQ,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;IACrD,MAAM,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;IACnD,OAAO,EAAE,CAAC,KAAK,EAAE,yBAAyB,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IACpE,qBAAqB,EAAE,OAAO,CAAC;IAC/B,WAAW,EAAE,yBAAyB,EAAE,CAAC;CAC5C;AAED;;GAEG;AACH,wBAAgB,2CAA2C,CAAC,EACxD,OAAO,EACP,QAAQ,EACR,MAAM,EACN,OAAO,EACP,qBAAqB,EACrB,WAAW,EACd,EAAE,iDAAiD,2CAmEnD"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"DefaultAlertingManagementDialogContentEnhanced.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogContentEnhanced.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AA4CrE,UAAU,oDAAoD;IAC1D,KAAK,CAAC,EAAE,MAAM,IAAI,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;CACtD;AAED;;GAEG;AACH,wBAAgB,8CAA8C,CAAC,EAC3D,KAAK,EACL,OAAO,EACP,MAAM,EACT,EAAE,oDAAoD,2CA6ItD"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"DefaultAlertingManagementDialogNew.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/DefaultAlertingManagementDialogNew.tsx"],"names":[],"mappings":"AAiBA,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,4BAA4B,CAAC;AAOjF;;GAEG;AACH,wBAAgB,kCAAkC,CAAC,EAC/C,cAAc,EACd,YAAY,EACZ,MAAM,EACN,KAAK,EACL,eAAe,EACf,aAAa,EACb,OAAO,EACP,qBAAqB,EACrB,WAAW,EACd,EAAE,8BAA8B,2CAmGhC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"Alert.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/Alert.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,KAAK,yBAAyB,EAAmB,MAAM,qBAAqB,CAAC;AACtF,OAAO,EAQH,kBAAkB,EAKrB,MAAM,sBAAsB,CAAC;AAY9B,UAAU,WAAW;IACjB,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,KAAK,EAAE,yBAAyB,CAAC;IACjC,aAAa,CAAC,EAAE,UAAU,GAAG,MAAM,GAAG,OAAO,kBAAkB,CAAC;IAChE,cAAc,EAAE,OAAO,CAAC;IACxB,gBAAgB,EAAE,CAAC,CAAC,QAAQ,CAAC,EAAE,OAAO,KAAK,IAAI,CAAC,GAAG,CAAC,MAAM,IAAI,CAAC,CAAC;IAChE,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC/B;AAkBD,wBAAgB,KAAK,CAAC,EAClB,KAAK,EACL,QAAQ,EACR,MAAM,EACN,aAAa,EACb,aAAa,EACb,cAAc,EACd,gBAAgB,EAChB,MAAM,EACN,iBAAiB,EACpB,EAAE,WAAW,2CA6Jb"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"AlertDropdown.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/AlertDropdown.tsx"],"names":[],"mappings":"AASA,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AAyBzE,wBAAgB,aAAa,CAAC,EAC1B,UAAU,EACV,MAAM,EACN,OAAO,EACP,OAAO,EACP,MAAM,EACN,OAAO,EACP,QAAQ,EACR,QAAQ,EACX,EAAE,mBAAmB,2CA4DrB"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"AlertsList.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/AlertsList.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAMrE,UAAU,YAAY;IAClB,QAAQ,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;IACrD,MAAM,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;IACnD,OAAO,EAAE,CAAC,KAAK,EAAE,yBAAyB,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;IACpE,SAAS,EAAE,OAAO,CAAC;IACnB,MAAM,EAAE,yBAAyB,EAAE,CAAC;IACpC,iBAAiB,EAAE,MAAM,CAAC;CAC7B;AAMD,wBAAgB,MAAM,CAAC,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,EAAE,EAAE,YAAY,2CAkFvG"}
@@ -1,11 +0,0 @@
1
- import { type IAutomationMetadataObject } from "@gooddata/sdk-model";
2
- import { type GoodDataSdkError } from "@gooddata/sdk-ui";
3
- interface IDeleteAlertConfirmDialogProps {
4
- alert: IAutomationMetadataObject;
5
- onCancel: () => void;
6
- onSuccess?: (alert: IAutomationMetadataObject) => void;
7
- onError?: (error: GoodDataSdkError) => void;
8
- }
9
- export declare function DeleteAlertConfirmDialog({ alert, onCancel, onSuccess, onError }: IDeleteAlertConfirmDialogProps): import("react/jsx-runtime").JSX.Element;
10
- export {};
11
- //# sourceMappingURL=DeleteAlertConfirmDialog.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"DeleteAlertConfirmDialog.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/DeleteAlertConfirmDialog.tsx"],"names":[],"mappings":"AAMA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AACrE,OAAO,EAAE,KAAK,gBAAgB,EAAsD,MAAM,kBAAkB,CAAC;AAO7G,UAAU,8BAA8B;IACpC,KAAK,EAAE,yBAAyB,CAAC;IACjC,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,yBAAyB,KAAK,IAAI,CAAC;IACvD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,gBAAgB,KAAK,IAAI,CAAC;CAC/C;AAED,wBAAgB,wBAAwB,CAAC,EACrC,KAAK,EACL,QAAQ,EACR,SAAS,EACT,OAAO,EACV,EAAE,8BAA8B,2CAyDhC"}
@@ -1,38 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { FormattedMessage, useIntl } from "react-intl";
3
- import { convertError, useBackendStrict, useWorkspaceStrict } from "@gooddata/sdk-ui";
4
- import { ConfirmDialog } from "@gooddata/sdk-ui-kit";
5
- import { useDashboardSelector } from "../../../../../../model/react/DashboardStoreProvider.js";
6
- import { selectCanManageWorkspace } from "../../../../../../model/store/permissions/permissionsSelectors.js";
7
- import { selectCurrentUser } from "../../../../../../model/store/user/userSelectors.js";
8
- export function DeleteAlertConfirmDialog({ alert, onCancel, onSuccess, onError, }) {
9
- const effectiveBackend = useBackendStrict();
10
- const effectiveWorkspace = useWorkspaceStrict();
11
- const intl = useIntl();
12
- const currentUser = useDashboardSelector(selectCurrentUser);
13
- const canManageAutomations = useDashboardSelector(selectCanManageWorkspace);
14
- const handleDeleteAlert = async () => {
15
- try {
16
- const alertCreatorId = alert.createdBy?.login;
17
- const currentUserId = currentUser?.login;
18
- const isAlertCreatedByCurrentUser = !!alertCreatorId && !!currentUserId && alertCreatorId === currentUserId;
19
- const automationService = effectiveBackend.workspace(effectiveWorkspace).automations();
20
- // If alert is created by current user, or user has permissions to manage automations, delete it, otherwise unsubscribe
21
- const deleteMethod = canManageAutomations || isAlertCreatedByCurrentUser
22
- ? automationService.deleteAutomation.bind(automationService)
23
- : automationService.unsubscribeAutomation.bind(automationService);
24
- await deleteMethod(alert.id);
25
- onSuccess?.(alert);
26
- }
27
- catch (err) {
28
- onError?.(convertError(err));
29
- }
30
- };
31
- return (_jsx(ConfirmDialog, { displayCloseButton: true, isPositive: false, headline: intl.formatMessage({ id: "dialogs.alerting.management.delete.dialog" }), cancelButtonText: intl.formatMessage({ id: "cancel" }), submitButtonText: intl.formatMessage({ id: "delete" }), onSubmit: () => {
32
- void handleDeleteAlert();
33
- }, onClose: onCancel, onCancel: onCancel, className: "gd-notifications-channel-delete-dialog s-alert-delete-dialog", containerClassName: "gd-notifications-channel-delete-dialog-overlay", children: _jsx("span", { className: "s-alert-delete-dialog-content", children: _jsx(FormattedMessage, { id: "dialogs.alerting.management.delete.dialog.confirm", values: {
34
- b: (chunks) => (_jsxs("span", { className: "gd-notifications-channel-delete-dialog-text", children: [chunks, " ",
35
- _jsx("strong", { children: alert.title })
36
- ] })),
37
- } }) }) }));
38
- }
@@ -1 +0,0 @@
1
- {"version":3,"file":"PauseAlertRunner.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/components/PauseAlertRunner.tsx"],"names":[],"mappings":"AAIA,OAAO,EACH,KAAK,yBAAyB,EAC9B,KAAK,mCAAmC,EAC3C,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,gBAAgB,EAAgB,MAAM,kBAAkB,CAAC;AAIvE,UAAU,sBAAsB;IAC5B,KAAK,EAAE,yBAAyB,GAAG,IAAI,CAAC;IACxC,KAAK,EAAE,OAAO,CAAC;IACf,SAAS,CAAC,EAAE,CACR,KAAK,EAAE,yBAAyB,GAAG,mCAAmC,EACtE,KAAK,EAAE,OAAO,KACb,IAAI,CAAC;IACV,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,gBAAgB,EAAE,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;CAC/D;AAED,wBAAgB,gBAAgB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,OAAO,EAAE,EAAE,sBAAsB,QAgD5F"}
@@ -1,50 +0,0 @@
1
- // (C) 2022-2026 GoodData Corporation
2
- import { useCallback, useEffect } from "react";
3
- import { convertError } from "@gooddata/sdk-ui";
4
- import { useSaveAlertToBackend } from "../../../../../widget/insight/configuration/InsightAlertConfig/hooks/useSaveAlertToBackend.js";
5
- export function PauseAlertRunner({ alert, pause, onSuccess, onError }) {
6
- const { handlePauseAlert, handleResumeAlert } = useSaveAlertToBackend({
7
- onPauseSuccess: () => {
8
- if (alert) {
9
- onSuccess?.(alert, true);
10
- }
11
- },
12
- onPauseError: (error) => {
13
- onError?.(convertError(error), true);
14
- },
15
- onResumeSuccess: () => {
16
- if (alert) {
17
- onSuccess?.(alert, false);
18
- }
19
- },
20
- onResumeError: () => {
21
- if (alert) {
22
- onSuccess?.(alert, false);
23
- }
24
- },
25
- });
26
- const handlerPauseAlert = useCallback(() => {
27
- if (!alert) {
28
- return;
29
- }
30
- if (pause) {
31
- const alertToPause = {
32
- ...alert,
33
- alert: { ...alert.alert, trigger: { ...alert.alert?.trigger, state: "PAUSED" } },
34
- };
35
- handlePauseAlert(alertToPause);
36
- }
37
- else {
38
- const alertToResume = {
39
- ...alert,
40
- alert: { ...alert.alert, trigger: { ...alert.alert?.trigger, state: "ACTIVE" } },
41
- };
42
- handleResumeAlert(alertToResume);
43
- }
44
- }, [alert, handlePauseAlert, handleResumeAlert, pause]);
45
- useEffect(() => {
46
- handlerPauseAlert();
47
- // eslint-disable-next-line react-hooks/exhaustive-deps
48
- }, [alert]);
49
- return null;
50
- }
@@ -1,7 +0,0 @@
1
- import { type IAutomationMetadataObject } from "@gooddata/sdk-model";
2
- export type AlertInvalidityReason = "missingMetric" | "missingWidget";
3
- export declare const useAlertValidation: (alert: IAutomationMetadataObject | undefined, isNewAlert?: boolean | undefined) => {
4
- isValid: boolean;
5
- invalidityReason: AlertInvalidityReason | undefined;
6
- };
7
- //# sourceMappingURL=useAlertValidation.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"useAlertValidation.d.ts","sourceRoot":"","sources":["../../../../../../../src/presentation/automations/_staging/alerting/DefaultAlertingManagementDialog/hooks/useAlertValidation.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAUrE,MAAM,MAAM,qBAAqB,GAAG,eAAe,GAAG,eAAe,CAAC;AAEtE,eAAO,MAAM,kBAAkB;;;CAgC9B,CAAC"}
@@ -1,30 +0,0 @@
1
- // (C) 2024-2026 GoodData Corporation
2
- import { useDashboardSelector } from "../../../../../../model/react/DashboardStoreProvider.js";
3
- import { selectCatalogDateDatasets } from "../../../../../../model/store/catalog/catalogSelectors.js";
4
- import { selectEnableComparisonInAlerting } from "../../../../../../model/store/config/configSelectors.js";
5
- import { selectInsightByWidgetRef } from "../../../../../../model/store/insights/insightsSelectors.js";
6
- import { selectWidgetByRef } from "../../../../../../model/store/tabs/layout/layoutSelectors.js";
7
- import { getAlertMeasure } from "../../../../alerting/DefaultAlertingDialog/utils/getters.js";
8
- import { getSupportedInsightMeasuresByInsight } from "../../../../alerting/DefaultAlertingDialog/utils/items.js";
9
- export const useAlertValidation = (alert, isNewAlert) => {
10
- const widgetLocalId = alert?.metadata?.widget;
11
- const widgetRef = widgetLocalId ? { identifier: widgetLocalId } : undefined;
12
- const canManageComparison = useDashboardSelector(selectEnableComparisonInAlerting);
13
- const widget = useDashboardSelector(selectWidgetByRef(widgetRef));
14
- const insight = useDashboardSelector(selectInsightByWidgetRef(widget?.ref));
15
- const dateDatasets = useDashboardSelector(selectCatalogDateDatasets);
16
- const supportedMeasures = getSupportedInsightMeasuresByInsight(insight, dateDatasets, canManageComparison, alert);
17
- const selectedMeasureExists = alert ? getAlertMeasure(supportedMeasures, alert.alert) : undefined;
18
- const isValid = isNewAlert || Boolean(!!widget && selectedMeasureExists);
19
- let invalidityReason = undefined;
20
- if (!widget) {
21
- invalidityReason = "missingWidget";
22
- }
23
- else if (!selectedMeasureExists) {
24
- invalidityReason = "missingMetric";
25
- }
26
- return {
27
- isValid,
28
- invalidityReason,
29
- };
30
- };
@@ -1 +0,0 @@
1
- {"version":3,"file":"useAlertingDialogAccessibility.d.ts","sourceRoot":"","sources":["../../../../../../src/presentation/automations/_staging/alerting/hooks/useAlertingDialogAccessibility.ts"],"names":[],"mappings":"AAQA,eAAO,MAAM,8BAA8B;;CAW1C,CAAC"}
@@ -1,12 +0,0 @@
1
- // (C) 2025-2026 GoodData Corporation
2
- import { useMemo } from "react";
3
- import { DEFAULT_MENU_BUTTON_ID } from "../../../../../_staging/accessibility/elementId.js";
4
- import { useDashboardSelector } from "../../../../../model/react/DashboardStoreProvider.js";
5
- import { selectAlertingDialogReturnFocusTo } from "../../../../../model/store/ui/uiSelectors.js";
6
- export const useAlertingDialogAccessibility = () => {
7
- const alertingDialogReturnFocusTo = useDashboardSelector(selectAlertingDialogReturnFocusTo);
8
- const returnFocusTo = useMemo(() => alertingDialogReturnFocusTo || DEFAULT_MENU_BUTTON_ID, [alertingDialogReturnFocusTo]);
9
- return {
10
- returnFocusTo,
11
- };
12
- };