From ae154212fe8864741b12eed949bb086dff5888af Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Tue, 9 Dec 2025 19:34:03 +0200 Subject: [PATCH] feat(client/server): basic support for experimental features --- .../src/services/experimental_features.ts | 13 ++++++++ .../widgets/type_widgets/options/advanced.tsx | 33 +++++++++++++++---- apps/server/src/routes/api/options.ts | 1 + apps/server/src/services/options_init.ts | 3 +- packages/commons/src/lib/options_interface.ts | 1 + 5 files changed, 44 insertions(+), 7 deletions(-) create mode 100644 apps/client/src/services/experimental_features.ts diff --git a/apps/client/src/services/experimental_features.ts b/apps/client/src/services/experimental_features.ts new file mode 100644 index 000000000..4f6566163 --- /dev/null +++ b/apps/client/src/services/experimental_features.ts @@ -0,0 +1,13 @@ +interface ExperimentalFeature { + id: string; + name: string; + description: string; +} + +export const experimentalFeatures: ExperimentalFeature[] = [ + { + id: "newLayout", + name: "New Layout", + description: "Try out the new layout for a more modern look and improved usability.", + } +]; diff --git a/apps/client/src/widgets/type_widgets/options/advanced.tsx b/apps/client/src/widgets/type_widgets/options/advanced.tsx index b16dca89d..091ba4d2f 100644 --- a/apps/client/src/widgets/type_widgets/options/advanced.tsx +++ b/apps/client/src/widgets/type_widgets/options/advanced.tsx @@ -7,6 +7,9 @@ import FormText from "../../react/FormText"; import OptionsSection from "./components/OptionsSection" import Column from "../../react/Column"; import { useEffect, useState } from "preact/hooks"; +import CheckboxList from "./components/CheckboxList"; +import { experimentalFeatures } from "../../../services/experimental_features"; +import { useTriliumOptionJson } from "../../react/hooks"; export default function AdvancedSettings() { return <> @@ -14,6 +17,7 @@ export default function AdvancedSettings() { + ; } @@ -44,14 +48,14 @@ function DatabaseIntegrityOptions() { return ( {t("database_integrity_check.description")} - +