diff --git a/apps/console/src/__generated__/core/CompliancePageAuditListFragment.graphql.ts b/apps/console/src/__generated__/core/CompliancePageAuditListFragment.graphql.ts index d9957241a..843767367 100644 --- a/apps/console/src/__generated__/core/CompliancePageAuditListFragment.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageAuditListFragment.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<<0bf1290a489f4685a6057509b9eaed9c>> + * @generated SignedSource<> * @lightSyntaxTransform * @nogrep */ @@ -61,7 +61,7 @@ const node: ReaderFragment = { { "kind": "Literal", "name": "first", - "value": 1000 + "value": 100 } ], "concreteType": "AuditConnection", @@ -104,13 +104,13 @@ const node: ReaderFragment = { "storageKey": null } ], - "storageKey": "audits(first:1000)" + "storageKey": "audits(first:100)" } ], "type": "Organization", "abstractKey": null }; -(node as any).hash = "d307c5c23d18357bc09c1115989dd734"; +(node as any).hash = "b66fddcbd57e4fd5af9f2a91663cb65b"; export default node; diff --git a/apps/console/src/__generated__/core/CompliancePageAuditsPageQuery.graphql.ts b/apps/console/src/__generated__/core/CompliancePageAuditsPageQuery.graphql.ts index 3038455c5..167bca0f3 100644 --- a/apps/console/src/__generated__/core/CompliancePageAuditsPageQuery.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageAuditsPageQuery.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<<9b92fdee29c65d57e35647e37f427be9>> + * @generated SignedSource<<109bdc23095ddd764ac63f68d9185ab1>> * @lightSyntaxTransform * @nogrep */ @@ -134,7 +134,7 @@ return { { "kind": "Literal", "name": "first", - "value": 1000 + "value": 100 } ], "concreteType": "AuditConnection", @@ -201,7 +201,7 @@ return { "storageKey": null } ], - "storageKey": "audits(first:1000)" + "storageKey": "audits(first:100)" } ], "type": "Organization", @@ -214,12 +214,12 @@ return { ] }, "params": { - "cacheID": "4efa36568b452a0075ed29fe7f5ed279", + "cacheID": "ebb26dedba5dbbae4d46bcd3a41b201d", "id": null, "metadata": {}, "name": "CompliancePageAuditsPageQuery", "operationKind": "query", - "text": "query CompliancePageAuditsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ...CompliancePageAuditListFragment\n id\n }\n}\n\nfragment CompliancePageAuditListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageAuditListItem_compliancePageFragment\n id\n }\n audits(first: 1000) {\n edges {\n node {\n id\n ...CompliancePageAuditListItem_auditFragment\n }\n }\n }\n}\n\nfragment CompliancePageAuditListItem_auditFragment on Audit {\n id\n name\n framework {\n name\n id\n }\n validUntil\n state\n trustCenterVisibility\n}\n\nfragment CompliancePageAuditListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n" + "text": "query CompliancePageAuditsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ...CompliancePageAuditListFragment\n id\n }\n}\n\nfragment CompliancePageAuditListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageAuditListItem_compliancePageFragment\n id\n }\n audits(first: 100) {\n edges {\n node {\n id\n ...CompliancePageAuditListItem_auditFragment\n }\n }\n }\n}\n\nfragment CompliancePageAuditListItem_auditFragment on Audit {\n id\n name\n framework {\n name\n id\n }\n validUntil\n state\n trustCenterVisibility\n}\n\nfragment CompliancePageAuditListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n" } }; })(); diff --git a/apps/console/src/__generated__/core/CompliancePageDocumentListFragment.graphql.ts b/apps/console/src/__generated__/core/CompliancePageDocumentListFragment.graphql.ts index 14c2b9b14..485ce6a54 100644 --- a/apps/console/src/__generated__/core/CompliancePageDocumentListFragment.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageDocumentListFragment.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<<520e633d06f7c68a9270600108ec81da>> + * @generated SignedSource<> * @lightSyntaxTransform * @nogrep */ @@ -61,7 +61,7 @@ const node: ReaderFragment = { { "kind": "Literal", "name": "first", - "value": 1000 + "value": 100 } ], "concreteType": "DocumentConnection", @@ -104,13 +104,13 @@ const node: ReaderFragment = { "storageKey": null } ], - "storageKey": "documents(first:1000)" + "storageKey": "documents(first:100)" } ], "type": "Organization", "abstractKey": null }; -(node as any).hash = "10da8f0838c700d4a2535ec5193844a8"; +(node as any).hash = "a8d512034c171dc461a42e6ae6e76f12"; export default node; diff --git a/apps/console/src/__generated__/core/CompliancePageDocumentsPageQuery.graphql.ts b/apps/console/src/__generated__/core/CompliancePageDocumentsPageQuery.graphql.ts index 0c8015343..522c44825 100644 --- a/apps/console/src/__generated__/core/CompliancePageDocumentsPageQuery.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageDocumentsPageQuery.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<> + * @generated SignedSource<> * @lightSyntaxTransform * @nogrep */ @@ -127,7 +127,7 @@ return { { "kind": "Literal", "name": "first", - "value": 1000 + "value": 100 } ], "concreteType": "DocumentConnection", @@ -235,7 +235,7 @@ return { "storageKey": null } ], - "storageKey": "documents(first:1000)" + "storageKey": "documents(first:100)" } ], "type": "Organization", @@ -248,12 +248,12 @@ return { ] }, "params": { - "cacheID": "675dc82aa65110e99b4ddc51992999c3", + "cacheID": "a094d511faa776c9e8d68f53933b3937", "id": null, "metadata": {}, "name": "CompliancePageDocumentsPageQuery", "operationKind": "query", - "text": "query CompliancePageDocumentsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ...CompliancePageDocumentListFragment\n id\n }\n}\n\nfragment CompliancePageDocumentListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageDocumentListItem_compliancePageFragment\n id\n }\n documents(first: 1000) {\n edges {\n node {\n id\n ...CompliancePageDocumentListItem_documentFragment\n }\n }\n }\n}\n\nfragment CompliancePageDocumentListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n\nfragment CompliancePageDocumentListItem_documentFragment on Document {\n id\n documentType\n title\n trustCenterVisibility\n lastVersion: versions(first: 1, orderBy: {field: CREATED_AT, direction: DESC}) {\n edges {\n node {\n id\n status\n }\n }\n }\n}\n" + "text": "query CompliancePageDocumentsPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ...CompliancePageDocumentListFragment\n id\n }\n}\n\nfragment CompliancePageDocumentListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageDocumentListItem_compliancePageFragment\n id\n }\n documents(first: 100) {\n edges {\n node {\n id\n ...CompliancePageDocumentListItem_documentFragment\n }\n }\n }\n}\n\nfragment CompliancePageDocumentListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n\nfragment CompliancePageDocumentListItem_documentFragment on Document {\n id\n documentType\n title\n trustCenterVisibility\n lastVersion: versions(first: 1, orderBy: {field: CREATED_AT, direction: DESC}) {\n edges {\n node {\n id\n status\n }\n }\n }\n}\n" } }; })(); diff --git a/apps/console/src/__generated__/core/CompliancePageFileListFragment.graphql.ts b/apps/console/src/__generated__/core/CompliancePageFileListFragment.graphql.ts index fda663837..75c331c45 100644 --- a/apps/console/src/__generated__/core/CompliancePageFileListFragment.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageFileListFragment.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<<6d08eaab8a421f1908e103b1343e72ac>> + * @generated SignedSource<<6805840d2d78dff0dc2281278cf21757>> * @lightSyntaxTransform * @nogrep */ @@ -168,6 +168,6 @@ const node: ReaderFragment = { "abstractKey": null }; -(node as any).hash = "ebbed925b4bbca03e906f63a2d18ab7b"; +(node as any).hash = "2d91d06498ed17aca44a1eea3d3605ea"; export default node; diff --git a/apps/console/src/__generated__/core/CompliancePageFilesPageQuery.graphql.ts b/apps/console/src/__generated__/core/CompliancePageFilesPageQuery.graphql.ts index d0ea24d27..bba827353 100644 --- a/apps/console/src/__generated__/core/CompliancePageFilesPageQuery.graphql.ts +++ b/apps/console/src/__generated__/core/CompliancePageFilesPageQuery.graphql.ts @@ -1,5 +1,5 @@ /** - * @generated SignedSource<<43d75c2e4c035f883790d1d854b60bfc>> + * @generated SignedSource<<94259096753f254d67dba23309f3c17b>> * @lightSyntaxTransform * @nogrep */ @@ -70,7 +70,7 @@ v5 = [ { "kind": "Literal", "name": "first", - "value": 1000 + "value": 100 } ]; return { @@ -290,7 +290,7 @@ return { ] } ], - "storageKey": "trustCenterFiles(first:1000)" + "storageKey": "trustCenterFiles(first:100)" }, { "alias": null, @@ -312,12 +312,12 @@ return { ] }, "params": { - "cacheID": "115af8c7555ab3ab0277f16c8ec7ea6d", + "cacheID": "dfdca184d1fbe4ccaeddda2c71e86958", "id": null, "metadata": {}, "name": "CompliancePageFilesPageQuery", "operationKind": "query", - "text": "query CompliancePageFilesPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ... on Organization {\n canCreateTrustCenterFile: permission(action: \"core:trust-center-file:create\")\n }\n ...CompliancePageFileListFragment\n id\n }\n}\n\nfragment CompliancePageFileListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageFileListItem_compliancePageFragment\n id\n }\n trustCenterFiles(first: 1000) {\n edges {\n node {\n id\n ...CompliancePageFileListItem_fileFragment\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n}\n\nfragment CompliancePageFileListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n\nfragment CompliancePageFileListItem_fileFragment on TrustCenterFile {\n id\n name\n category\n fileUrl\n trustCenterVisibility\n createdAt\n canUpdate: permission(action: \"core:trust-center-file:update\")\n canDelete: permission(action: \"core:trust-center-file:delete\")\n}\n" + "text": "query CompliancePageFilesPageQuery(\n $organizationId: ID!\n) {\n organization: node(id: $organizationId) {\n __typename\n ... on Organization {\n canCreateTrustCenterFile: permission(action: \"core:trust-center-file:create\")\n }\n ...CompliancePageFileListFragment\n id\n }\n}\n\nfragment CompliancePageFileListFragment on Organization {\n compliancePage: trustCenter {\n ...CompliancePageFileListItem_compliancePageFragment\n id\n }\n trustCenterFiles(first: 100) {\n edges {\n node {\n id\n ...CompliancePageFileListItem_fileFragment\n __typename\n }\n cursor\n }\n pageInfo {\n endCursor\n hasNextPage\n }\n }\n}\n\nfragment CompliancePageFileListItem_compliancePageFragment on TrustCenter {\n canUpdate: permission(action: \"core:trust-center:update\")\n}\n\nfragment CompliancePageFileListItem_fileFragment on TrustCenterFile {\n id\n name\n category\n fileUrl\n trustCenterVisibility\n createdAt\n canUpdate: permission(action: \"core:trust-center-file:update\")\n canDelete: permission(action: \"core:trust-center-file:delete\")\n}\n" } }; })(); diff --git a/apps/console/src/pages/organizations/compliance-page/audits/_components/CompliancePageAuditList.tsx b/apps/console/src/pages/organizations/compliance-page/audits/_components/CompliancePageAuditList.tsx index 093cc4fd4..a65875765 100644 --- a/apps/console/src/pages/organizations/compliance-page/audits/_components/CompliancePageAuditList.tsx +++ b/apps/console/src/pages/organizations/compliance-page/audits/_components/CompliancePageAuditList.tsx @@ -1,7 +1,5 @@ -import { sprintf } from "@probo/helpers"; import { useTranslate } from "@probo/i18n"; -import { Button, IconChevronDown, Table, Tbody, Td, Th, Thead, Tr } from "@probo/ui"; -import { useState } from "react"; +import { Table, Tbody, Td, Th, Thead, Tr } from "@probo/ui"; import { useFragment } from "react-relay"; import { graphql } from "relay-runtime"; @@ -14,7 +12,7 @@ const fragment = graphql` compliancePage: trustCenter @required(action: THROW) { ...CompliancePageAuditListItem_compliancePageFragment } - audits(first: 1000) { + audits(first: 100) { edges { node { id @@ -29,12 +27,9 @@ export function CompliancePageAuditList(props: { fragmentRef: CompliancePageAudi const { fragmentRef } = props; const { __ } = useTranslate(); - const [limit, setLimit] = useState(100); const { audits, compliancePage } = useFragment(fragment, fragmentRef); - const showMoreButton = limit !== null && audits.edges.length > limit; - return (
@@ -64,16 +59,6 @@ export function CompliancePageAuditList(props: { fragmentRef: CompliancePageAudi ))}
- {showMoreButton && ( - - )}
); } diff --git a/apps/console/src/pages/organizations/compliance-page/documents/_components/CompliancePageDocumentList.tsx b/apps/console/src/pages/organizations/compliance-page/documents/_components/CompliancePageDocumentList.tsx index 228e840ef..d2a83a98b 100644 --- a/apps/console/src/pages/organizations/compliance-page/documents/_components/CompliancePageDocumentList.tsx +++ b/apps/console/src/pages/organizations/compliance-page/documents/_components/CompliancePageDocumentList.tsx @@ -1,7 +1,5 @@ -import { sprintf } from "@probo/helpers"; import { useTranslate } from "@probo/i18n"; -import { Button, IconChevronDown, Table, Tbody, Td, Th, Thead, Tr } from "@probo/ui"; -import { useState } from "react"; +import { Table, Tbody, Td, Th, Thead, Tr } from "@probo/ui"; import { useFragment } from "react-relay"; import { graphql } from "relay-runtime"; @@ -14,7 +12,7 @@ const fragment = graphql` compliancePage: trustCenter @required(action: THROW) { ...CompliancePageDocumentListItem_compliancePageFragment } - documents(first: 1000) { + documents(first: 100) { edges { node { id @@ -32,9 +30,6 @@ export function CompliancePageDocumentList(props: { fragmentRef: CompliancePageD const { compliancePage, documents } = useFragment(fragment, fragmentRef); - const [limit, setLimit] = useState(100); - const showMoreButton = limit !== null && documents.edges.length > limit; - return (
@@ -63,16 +58,6 @@ export function CompliancePageDocumentList(props: { fragmentRef: CompliancePageD ))}
- {showMoreButton && ( - - )}
); }; diff --git a/apps/console/src/pages/organizations/compliance-page/files/_components/CompliancePageFileList.tsx b/apps/console/src/pages/organizations/compliance-page/files/_components/CompliancePageFileList.tsx index 39da85db2..9b7077445 100644 --- a/apps/console/src/pages/organizations/compliance-page/files/_components/CompliancePageFileList.tsx +++ b/apps/console/src/pages/organizations/compliance-page/files/_components/CompliancePageFileList.tsx @@ -1,6 +1,5 @@ -import { sprintf } from "@probo/helpers"; import { useTranslate } from "@probo/i18n"; -import { Button, IconChevronDown, Table, Tbody, Td, Th, Thead, Tr, useDialogRef } from "@probo/ui"; +import { Table, Tbody, Td, Th, Thead, Tr, useDialogRef } from "@probo/ui"; import { useCallback, useState } from "react"; import { useFragment } from "react-relay"; import { graphql } from "relay-runtime"; @@ -17,7 +16,7 @@ const fragment = graphql` compliancePage: trustCenter @required(action: THROW) { ...CompliancePageFileListItem_compliancePageFragment } - trustCenterFiles(first: 1000) + trustCenterFiles(first: 100) @connection(key: "CompliancePageFileList_trustCenterFiles") { __id edges { @@ -41,9 +40,6 @@ export function CompliancePageFileList(props: { fragmentRef: CompliancePageFileL trustCenterFiles: files, } = useFragment(fragment, fragmentRef); - const [limit, setLimit] = useState(100); - const showMoreButton = limit !== null && files.edges.length > limit; - const [editingFile, setEditingFile] = useState< CompliancePageFileListItem_fileFragment$data | null>(null); const [deletingFileId, setDeletingFileId] = useState(null); @@ -87,16 +83,6 @@ export function CompliancePageFileList(props: { fragmentRef: CompliancePageFileL ))} - {showMoreButton && ( - - )} {editingFile && (