From c67c3a68615e5ef5a3325cfbbc1aa74abb41ea54 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Thu, 14 Aug 2025 22:27:07 +0300 Subject: [PATCH] feat(react/settings): port images --- apps/client/src/stylesheets/style.css | 5 + apps/client/src/widgets/react/FormGroup.tsx | 5 +- .../widgets/type_widgets/content_widget.tsx | 6 +- .../widgets/type_widgets/options/images.tsx | 51 ++++++++++ .../type_widgets/options/images/images.ts | 98 ------------------- 5 files changed, 61 insertions(+), 104 deletions(-) create mode 100644 apps/client/src/widgets/type_widgets/options/images.tsx delete mode 100644 apps/client/src/widgets/type_widgets/options/images/images.ts diff --git a/apps/client/src/stylesheets/style.css b/apps/client/src/stylesheets/style.css index fa55b04a6..8e1a787e0 100644 --- a/apps/client/src/stylesheets/style.css +++ b/apps/client/src/stylesheets/style.css @@ -139,6 +139,11 @@ textarea, color: var(--muted-text-color); } +.form-group.disabled { + opacity: 0.5; + pointer-events: none; +} + /* Add a gap between consecutive radios / check boxes */ label.tn-radio + label.tn-radio, label.tn-checkbox + label.tn-checkbox { diff --git a/apps/client/src/widgets/react/FormGroup.tsx b/apps/client/src/widgets/react/FormGroup.tsx index ff972d49c..513594dfa 100644 --- a/apps/client/src/widgets/react/FormGroup.tsx +++ b/apps/client/src/widgets/react/FormGroup.tsx @@ -7,11 +7,12 @@ interface FormGroupProps { className?: string; children: ComponentChildren; description?: string | ComponentChildren; + disabled?: boolean; } -export default function FormGroup({ label, title, className, children, description, labelRef }: FormGroupProps) { +export default function FormGroup({ label, title, className, children, description, labelRef, disabled }: FormGroupProps) { return ( -