import styles from "./Panes.module.scss"; import { Text } from "preact-i18n"; import { dispatch } from "../../../redux"; import { connectState } from "../../../redux/connector"; import { AVAILABLE_EXPERIMENTS, ExperimentOptions, EXPERIMENTS, } from "../../../redux/reducers/experiments"; import Checkbox from "../../../components/ui/Checkbox"; interface Props { options?: ExperimentOptions; } export function Component(props: Props) { return (

{AVAILABLE_EXPERIMENTS.map((key) => ( -1} onChange={(enabled) => dispatch({ type: enabled ? "EXPERIMENTS_ENABLE" : "EXPERIMENTS_DISABLE", key, }) }> { EXPERIMENTS[key].title }

{ EXPERIMENTS[key].description }

))} {AVAILABLE_EXPERIMENTS.length === 0 && (
)}
); } export const ExperimentsPage = connectState(Component, (state) => { return { options: state.experiments, }; });