first commit
This commit is contained in:
17
ui/app/workspace/pii-redactor/layout.tsx
Normal file
17
ui/app/workspace/pii-redactor/layout.tsx
Normal file
@@ -0,0 +1,17 @@
|
||||
import { createFileRoute, Outlet, useChildMatches } from "@tanstack/react-router";
|
||||
import { NoPermissionView } from "@/components/noPermissionView";
|
||||
import { RbacOperation, RbacResource, useRbac } from "@enterprise/lib";
|
||||
import PiiRedactorPage from "./page";
|
||||
|
||||
function RouteComponent() {
|
||||
const hasPiiRedactorAccess = useRbac(RbacResource.PIIRedactor, RbacOperation.View);
|
||||
const childMatches = useChildMatches();
|
||||
if (!hasPiiRedactorAccess) {
|
||||
return <NoPermissionView entity="PII redactor" />;
|
||||
}
|
||||
return childMatches.length === 0 ? <PiiRedactorPage /> : <Outlet />;
|
||||
}
|
||||
|
||||
export const Route = createFileRoute("/workspace/pii-redactor")({
|
||||
component: RouteComponent,
|
||||
});
|
||||
9
ui/app/workspace/pii-redactor/page.tsx
Normal file
9
ui/app/workspace/pii-redactor/page.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import PiiRedactorRulesView from "@enterprise/components/pii-redactor/piiRedactorRulesView";
|
||||
|
||||
export default function PiiRedactorPage() {
|
||||
return (
|
||||
<div className="mx-auto w-full max-w-7xl">
|
||||
<PiiRedactorRulesView />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
6
ui/app/workspace/pii-redactor/providers/layout.tsx
Normal file
6
ui/app/workspace/pii-redactor/providers/layout.tsx
Normal file
@@ -0,0 +1,6 @@
|
||||
import { createFileRoute } from "@tanstack/react-router";
|
||||
import PiiRedactorProvidersPage from "./page";
|
||||
|
||||
export const Route = createFileRoute("/workspace/pii-redactor/providers")({
|
||||
component: PiiRedactorProvidersPage,
|
||||
});
|
||||
9
ui/app/workspace/pii-redactor/providers/page.tsx
Normal file
9
ui/app/workspace/pii-redactor/providers/page.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import PiiRedactorProviderView from "@enterprise/components/pii-redactor/piiRedactorProviderView";
|
||||
|
||||
export default function PiiRedactorProvidersPage() {
|
||||
return (
|
||||
<div className="mx-auto w-full max-w-7xl">
|
||||
<PiiRedactorProviderView />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
6
ui/app/workspace/pii-redactor/rules/layout.tsx
Normal file
6
ui/app/workspace/pii-redactor/rules/layout.tsx
Normal file
@@ -0,0 +1,6 @@
|
||||
import { createFileRoute } from "@tanstack/react-router";
|
||||
import PiiRedactorRulesPage from "./page";
|
||||
|
||||
export const Route = createFileRoute("/workspace/pii-redactor/rules")({
|
||||
component: PiiRedactorRulesPage,
|
||||
});
|
||||
9
ui/app/workspace/pii-redactor/rules/page.tsx
Normal file
9
ui/app/workspace/pii-redactor/rules/page.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import PiiRedactorRulesView from "@enterprise/components/pii-redactor/piiRedactorRulesView";
|
||||
|
||||
export default function PiiRedactorRulesPage() {
|
||||
return (
|
||||
<div className="mx-auto w-full max-w-7xl">
|
||||
<PiiRedactorRulesView />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user