diff --git a/src/pages/version/ParametersModal/ParametersModal.stories.tsx b/src/pages/version/ParametersModal/ParametersModal.stories.tsx new file mode 100644 index 0000000000..753cad8639 --- /dev/null +++ b/src/pages/version/ParametersModal/ParametersModal.stories.tsx @@ -0,0 +1,20 @@ +import { CustomStoryObj, CustomMeta } from "test_utils/types"; +import { ParametersModal } from "."; + +export default { + component: ParametersModal, +} satisfies CustomMeta; + +export const Default: CustomStoryObj = { + render: (args) => ( + + ), +}; diff --git a/src/pages/version/ParametersModal.test.tsx b/src/pages/version/ParametersModal/ParametersModal.test.tsx similarity index 95% rename from src/pages/version/ParametersModal.test.tsx rename to src/pages/version/ParametersModal/ParametersModal.test.tsx index 992e8a3573..d366b199c1 100644 --- a/src/pages/version/ParametersModal.test.tsx +++ b/src/pages/version/ParametersModal/ParametersModal.test.tsx @@ -1,5 +1,5 @@ import { render, screen, userEvent } from "test_utils"; -import { ParametersModal } from "./ParametersModal"; +import { ParametersModal } from "."; const parameters = [ { key: "Key 1", value: "Value 1" }, diff --git a/src/pages/version/ParametersModal.tsx b/src/pages/version/ParametersModal/index.tsx similarity index 87% rename from src/pages/version/ParametersModal.tsx rename to src/pages/version/ParametersModal/index.tsx index 38879412ca..f0c5ab1a04 100644 --- a/src/pages/version/ParametersModal.tsx +++ b/src/pages/version/ParametersModal/index.tsx @@ -1,4 +1,5 @@ import { useRef, useState } from "react"; +import styled from "@emotion/styled"; import { useLeafyGreenTable, LGColumnDef } from "@leafygreen-ui/table/new"; import { DisplayModal } from "components/DisplayModal"; import { MetadataItem } from "components/MetadataCard"; @@ -40,12 +41,19 @@ export const ParametersModal: React.FC = ({ parameters }) => { size="large" title="Patch Parameters" > - + + + ); }; +const OverflowContainer = styled.div` + max-height: 600px; + overflow-y: scroll; +`; + const columns: LGColumnDef[] = [ { accessorKey: "key",