@@ -25,7 +25,7 @@ const HomePage = lazy(() => import("./pages/HomePage"));
|
|||||||
const NotFoundPage = lazy(() => import("./pages/NotFoundPage"));
|
const NotFoundPage = lazy(() => import("./pages/NotFoundPage"));
|
||||||
const PeopleListPage = lazy(() => import("./pages/PeopleListPage"));
|
const PeopleListPage = lazy(() => import("./pages/PeopleListPage"));
|
||||||
const VendorListPage = lazy(() => import("./pages/VendorListPage"));
|
const VendorListPage = lazy(() => import("./pages/VendorListPage"));
|
||||||
const FrameworksPage = lazy(() => import("./pages/FrameworksPage"));
|
const FrameworkListPage = lazy(() => import("./pages/FrameworkListPage"));
|
||||||
const FrameworkOverviewPage = lazy(() => import("./pages/FrameworkOverviewPage"));
|
const FrameworkOverviewPage = lazy(() => import("./pages/FrameworkOverviewPage"));
|
||||||
const VendorOverviewPage = lazy(() => import("./pages/VendorOverviewPage"));
|
const VendorOverviewPage = lazy(() => import("./pages/VendorOverviewPage"));
|
||||||
|
|
||||||
@@ -83,6 +83,7 @@ function App() {
|
|||||||
<ErrorBoundary>
|
<ErrorBoundary>
|
||||||
<FrameworksPage />
|
<FrameworksPage />
|
||||||
</ErrorBoundary>
|
</ErrorBoundary>
|
||||||
|
<FrameworkListPage />
|
||||||
</Suspense>
|
</Suspense>
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -9,10 +9,10 @@ import { Globe2, CheckCircle } from "lucide-react";
|
|||||||
import { Card, CardContent } from "@/components/ui/card";
|
import { Card, CardContent } from "@/components/ui/card";
|
||||||
import { Badge } from "@/components/ui/badge";
|
import { Badge } from "@/components/ui/badge";
|
||||||
import { Link } from "react-router";
|
import { Link } from "react-router";
|
||||||
import type { FrameworksPageQuery as FrameworksPageQueryType } from "./__generated__/FrameworksPageQuery.graphql";
|
import type { FrameworkListPageQuery as FrameworkListPageQueryType } from "./__generated__/FrameworkListPageQuery.graphql";
|
||||||
|
|
||||||
const FrameworksPageQuery = graphql`
|
const FrameworkListPageQuery = graphql`
|
||||||
query FrameworksPageQuery {
|
query FrameworkListPageQuery {
|
||||||
node(id: "AZSfP_xAcAC5IAAAAAAltA") {
|
node(id: "AZSfP_xAcAC5IAAAAAAltA") {
|
||||||
id
|
id
|
||||||
... on Organization {
|
... on Organization {
|
||||||
@@ -40,12 +40,12 @@ const FrameworksPageQuery = graphql`
|
|||||||
}
|
}
|
||||||
`;
|
`;
|
||||||
|
|
||||||
function FrameworksPageContent({
|
function FrameworkListPageContent({
|
||||||
queryRef,
|
queryRef,
|
||||||
}: {
|
}: {
|
||||||
queryRef: PreloadedQuery<FrameworksPageQueryType>;
|
queryRef: PreloadedQuery<FrameworkListPageQueryType>;
|
||||||
}) {
|
}) {
|
||||||
const data = usePreloadedQuery(FrameworksPageQuery, queryRef);
|
const data = usePreloadedQuery(FrameworkListPageQuery, queryRef);
|
||||||
const frameworks = data.node.frameworks?.edges.map(edge => edge?.node) ?? [];
|
const frameworks = data.node.frameworks?.edges.map(edge => edge?.node) ?? [];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -92,7 +92,7 @@ function FrameworksPageContent({
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
function FrameworksPageFallback() {
|
function FrameworkListPageFallback() {
|
||||||
return (
|
return (
|
||||||
<div className="min-h-screen bg-background p-6">
|
<div className="min-h-screen bg-background p-6">
|
||||||
<div className="mb-8">
|
<div className="mb-8">
|
||||||
@@ -117,16 +117,16 @@ function FrameworksPageFallback() {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export default function FrameworksPage() {
|
export default function FrameworkListPage() {
|
||||||
const [queryRef, loadQuery] = useQueryLoader<FrameworksPageQueryType>(FrameworksPageQuery);
|
const [queryRef, loadQuery] = useQueryLoader<FrameworkListPageQueryType>(FrameworkListPageQuery);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
loadQuery({});
|
loadQuery({});
|
||||||
}, [loadQuery]);
|
}, [loadQuery]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Suspense fallback={<FrameworksPageFallback />}>
|
<Suspense fallback={<FrameworkListPageFallback />}>
|
||||||
{queryRef && <FrameworksPageContent queryRef={queryRef} />}
|
{queryRef && <FrameworkListPageContent queryRef={queryRef} />}
|
||||||
</Suspense>
|
</Suspense>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
/**
|
/**
|
||||||
* @generated SignedSource<<3bb5a1a7f62542ace96a9f256dada04e>>
|
* @generated SignedSource<<87f0a667163355b6f7d273a71aa65a93>>
|
||||||
* @lightSyntaxTransform
|
* @lightSyntaxTransform
|
||||||
* @nogrep
|
* @nogrep
|
||||||
*/
|
*/
|
||||||
@@ -10,8 +10,8 @@
|
|||||||
|
|
||||||
import { ConcreteRequest } from 'relay-runtime';
|
import { ConcreteRequest } from 'relay-runtime';
|
||||||
export type ControlState = "IMPLEMENTED" | "IN_PROGRESS" | "NOT_APPLICABLE" | "NOT_STARTED";
|
export type ControlState = "IMPLEMENTED" | "IN_PROGRESS" | "NOT_APPLICABLE" | "NOT_STARTED";
|
||||||
export type FrameworksPageQuery$variables = Record<PropertyKey, never>;
|
export type FrameworkListPageQuery$variables = Record<PropertyKey, never>;
|
||||||
export type FrameworksPageQuery$data = {
|
export type FrameworkListPageQuery$data = {
|
||||||
readonly node: {
|
readonly node: {
|
||||||
readonly frameworks?: {
|
readonly frameworks?: {
|
||||||
readonly edges: ReadonlyArray<{
|
readonly edges: ReadonlyArray<{
|
||||||
@@ -35,9 +35,9 @@ export type FrameworksPageQuery$data = {
|
|||||||
readonly id: string;
|
readonly id: string;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
export type FrameworksPageQuery = {
|
export type FrameworkListPageQuery = {
|
||||||
response: FrameworksPageQuery$data;
|
response: FrameworkListPageQuery$data;
|
||||||
variables: FrameworksPageQuery$variables;
|
variables: FrameworkListPageQuery$variables;
|
||||||
};
|
};
|
||||||
|
|
||||||
const node: ConcreteRequest = (function(){
|
const node: ConcreteRequest = (function(){
|
||||||
@@ -170,7 +170,7 @@ return {
|
|||||||
"argumentDefinitions": [],
|
"argumentDefinitions": [],
|
||||||
"kind": "Fragment",
|
"kind": "Fragment",
|
||||||
"metadata": null,
|
"metadata": null,
|
||||||
"name": "FrameworksPageQuery",
|
"name": "FrameworkListPageQuery",
|
||||||
"selections": [
|
"selections": [
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
@@ -193,7 +193,7 @@ return {
|
|||||||
"operation": {
|
"operation": {
|
||||||
"argumentDefinitions": [],
|
"argumentDefinitions": [],
|
||||||
"kind": "Operation",
|
"kind": "Operation",
|
||||||
"name": "FrameworksPageQuery",
|
"name": "FrameworkListPageQuery",
|
||||||
"selections": [
|
"selections": [
|
||||||
{
|
{
|
||||||
"alias": null,
|
"alias": null,
|
||||||
@@ -218,16 +218,16 @@ return {
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"params": {
|
"params": {
|
||||||
"cacheID": "1c8d130ae8ef94afc7a59fae8ac71e39",
|
"cacheID": "b9f11bd39a99da4a1693b67c60a85845",
|
||||||
"id": null,
|
"id": null,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"name": "FrameworksPageQuery",
|
"name": "FrameworkListPageQuery",
|
||||||
"operationKind": "query",
|
"operationKind": "query",
|
||||||
"text": "query FrameworksPageQuery {\n node(id: \"AZSfP_xAcAC5IAAAAAAltA\") {\n __typename\n id\n ... on Organization {\n frameworks {\n edges {\n node {\n id\n name\n description\n controls {\n edges {\n node {\n id\n state\n }\n }\n }\n createdAt\n updatedAt\n }\n }\n }\n }\n }\n}\n"
|
"text": "query FrameworkListPageQuery {\n node(id: \"AZSfP_xAcAC5IAAAAAAltA\") {\n __typename\n id\n ... on Organization {\n frameworks {\n edges {\n node {\n id\n name\n description\n controls {\n edges {\n node {\n id\n state\n }\n }\n }\n createdAt\n updatedAt\n }\n }\n }\n }\n }\n}\n"
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
|
|
||||||
(node as any).hash = "fda9662b311a83b144af3c11c573d634";
|
(node as any).hash = "cc761cbab629daf0587a9befff255256";
|
||||||
|
|
||||||
export default node;
|
export default node;
|
||||||
Reference in New Issue
Block a user