@griddo/ax 12.13.1 → 12.14.1

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.
@@ -1,19 +1,20 @@
1
1
  import React, { useCallback, useEffect, useRef, useState } from "react";
2
2
  import { connect } from "react-redux";
3
- import { format, subDays } from "date-fns";
4
3
 
5
- import type { ExportFormat, LogActivityExportRequest, LogActivityPaginationRequest } from "@griddo/api-types";
6
- import type { ILogItemsByDay, ILogItemsByUser, IQueryValue, IRootState, IStructuredData } from "@ax/types";
7
4
  import { EmptyState, ErrorToast, FilterTagsBar, MainWrapper, SearchTagsBar, Select, TableList } from "@ax/components";
8
5
  import { activityLogActions } from "@ax/containers/ActivityLog";
9
6
  import { structuredDataActions } from "@ax/containers/StructuredData";
10
7
  import { useModal } from "@ax/hooks";
8
+ import type { ILogItemsByDay, ILogItemsByUser, IQueryValue, IRootState, IStructuredData } from "@ax/types";
11
9
 
10
+ import type { ExportFormat, LogActivityExportRequest, LogActivityPaginationRequest } from "@griddo/api-types";
11
+ import { format, subDays } from "date-fns";
12
+
13
+ import DownloadModal from "./DownloadModal";
12
14
  import { useFilterQuery } from "./hooks";
13
- import TableHeader from "./TableHeader";
14
15
  import ItemLog from "./ItemLog";
15
16
  import ItemLogUser from "./ItemLogUser";
16
- import DownloadModal from "./DownloadModal";
17
+ import TableHeader from "./TableHeader";
17
18
 
18
19
  import * as S from "./style";
19
20
 
@@ -27,6 +27,7 @@ import { usersActions } from "@ax/containers/Users";
27
27
  import { RouteLeavingGuard } from "@ax/guards";
28
28
  import { dateToString, getDefaultTheme } from "@ax/helpers";
29
29
  import {
30
+ permissionsPageId,
30
31
  useBroadcastClipboard,
31
32
  useBroadcastContentUpdate,
32
33
  useEditingHeartbeat,
@@ -92,7 +93,7 @@ const GlobalEditor = (props: IProps) => {
92
93
 
93
94
  const isAllowedTo = usePermissionsForPage(
94
95
  "global",
95
- pageID,
96
+ permissionsPageId(editorContent, pageID),
96
97
  {
97
98
  publishPages: "global.globalData.publishUnpublishAllGlobalData",
98
99
  createPages: "global.globalData.createAllGlobalData",
@@ -25,6 +25,7 @@ import { dataPacksActions } from "@ax/containers/Settings/DataPacks";
25
25
  import { RouteLeavingGuard } from "@ax/guards";
26
26
  import { dateToString, getDeactivatedModules, isModuleDisabled } from "@ax/helpers";
27
27
  import {
28
+ permissionsPageId,
28
29
  useBroadcastClipboard,
29
30
  useBroadcastContentUpdate,
30
31
  useEditingHeartbeat,
@@ -95,7 +96,7 @@ const PageEditor = (props: IProps) => {
95
96
 
96
97
  const isAllowedTo = usePermissionsForPage(
97
98
  currentSiteInfo.id,
98
- pageID,
99
+ permissionsPageId(editorContent, pageID),
99
100
  {
100
101
  publishPages: "content.publishUnpublishPages",
101
102
  createPages: "content.createPages",