diff --git a/client/src/components/popup/preferences.tsx b/client/src/components/popup/preferences.tsx index ee24d6c..2b6d29b 100644 --- a/client/src/components/popup/preferences.tsx +++ b/client/src/components/popup/preferences.tsx @@ -2,16 +2,41 @@ import * as React from 'react' import { Input, Typography } from '@mui/material' import Markdown from '../markdown' import { Switch, Button, ButtonGroup } from '@mui/material'; +import Box from '@mui/material/Box'; +import Slider from '@mui/material/Slider'; import FormControlLabel from '@mui/material/FormControlLabel'; import { IPreferencesContext } from "../infoview/context" -interface PreferencesPopupProps extends IPreferencesContext{ +interface PreferencesPopupProps extends IPreferencesContext { handleClose: () => void } -export function PreferencesPopup({ layout, setLayout, isSavePreferences, setIsSavePreferences, handleClose }: PreferencesPopupProps) { +export function PreferencesPopup({ layout, setLayout, isSavePreferences, setIsSavePreferences, handleClose }: PreferencesPopupProps) { + + const marks = [ + { + value: 0, + label: 'Mobile', + key: "mobile" + }, + { + value: 1, + label: 'Auto', + key: "auto" + }, + { + value: 2, + label: 'Desktop', + key: "desktop" + }, + ]; + + const handlerChangeLayout = (_: Event, value: number) => { + setLayout(marks[value].key as IPreferencesContext["layout"]) + } + return