import React from "react"; import { Link } from "react-router-dom"; import { useTranslation } from "react-i18next"; import { Table, TableBody, TableHeader, TableVariant, } from "@patternfly/react-table"; import { ClientScopeRepresentation } from "./models/client-scope"; type ClientScopeListProps = { clientScopes: ClientScopeRepresentation[]; }; export const ClientScopeList = ({ clientScopes }: ClientScopeListProps) => { const { t } = useTranslation("client-scopes"); const columns: (keyof ClientScopeRepresentation)[] = [ "name", "description", "protocol", ]; const data = clientScopes.map((c) => { return { cells: columns.map((col) => { if (col === "name") { return ( <> {c[col]} ); } return c[col]; }), }; }); return ( <> {}, }, { title: t("common:delete"), onClick: () => {}, }, ]} aria-label={t("clientScopeList")} >
); };