Skip to content

Commit

Permalink
fix(storage) improve volume form after design review
Browse files Browse the repository at this point in the history
  • Loading branch information
edlerd committed Sep 28, 2023
1 parent c7625ba commit d1a8da4
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/pages/storage/forms/StorageVolumeForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { useParams } from "react-router-dom";
import { updateMaxHeight } from "util/updateMaxHeight";
import useEventListener from "@use-it/event-listener";
import StorageVolumeFormMenu, {
BLOCK,
FILESYSTEM,
MAIN_CONFIGURATION,
SNAPSHOTS,
ZFS,
Expand Down Expand Up @@ -140,7 +140,7 @@ const StorageVolumeForm: FC<Props> = ({ formik }) => {
{section === SNAPSHOTS && (
<StorageVolumeFormSnapshots formik={formik} />
)}
{section === BLOCK && <StorageVolumeFormBlock formik={formik} />}
{section === FILESYSTEM && <StorageVolumeFormBlock formik={formik} />}
{section === ZFS && <StorageVolumeFormZFS formik={formik} />}
</Col>
</Row>
Expand Down
18 changes: 17 additions & 1 deletion src/pages/storage/forms/StorageVolumeFormBlock.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,23 @@ const StorageVolumeFormBlock: FC<Props> = ({ formik }) => {
name: "block_mount_options",
defaultValue: "",
help: "Mount options for block devices",
children: <Input type="text" />,
children: (
<Input
type="text"
help={
<>
For a list of available options visit{" "}
<a
target="_blank"
rel="noreferrer"
href="https://manpages.ubuntu.com/manpages/jammy/en/man8/mount.8.html#filesystem-independent%20mount%20options"
>
mount manpages
</a>
</>
}
/>
),
}),
]}
/>
Expand Down
4 changes: 2 additions & 2 deletions src/pages/storage/forms/StorageVolumeFormMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { StorageVolumeFormValues } from "pages/storage/forms/StorageVolumeForm";

export const MAIN_CONFIGURATION = "Main configuration";
export const SNAPSHOTS = "Snapshots";
export const BLOCK = "Block";
export const FILESYSTEM = "Filesystem";
export const ZFS = "ZFS";

interface Props {
Expand Down Expand Up @@ -73,7 +73,7 @@ const StorageVolumeFormMenu: FC<Props> = ({
{contentType === "filesystem" &&
["zfs", "lvm", "ceph"].includes(poolDriver) && (
<MenuItem
label={BLOCK}
label={FILESYSTEM}
{...menuItemProps}
disableReason={disableReason}
/>
Expand Down

0 comments on commit d1a8da4

Please sign in to comment.