import { observer } from "mobx-react-lite"; import styles from "./Panes.module.scss"; import { Text } from "preact-i18n"; import { useApplicationState } from "../../../mobx/State"; import { SyncKeys } from "../../../mobx/stores/Sync"; import Checkbox from "../../../components/ui/Checkbox"; export const Sync = observer(() => { const sync = useApplicationState().sync; return (
{/*

Sync items automatically
*/}

{( [ ["appearance", "appearance.title"], ["theme", "appearance.theme"], ["locale", "language.title"], // notifications sync is always-on ] as [SyncKeys, string][] ).map(([key, title]) => ( } onChange={() => sync.toggle(key)}> ))} {/*
Last sync at 12:00
*/}
); });