def_visibility + reactive map buttons

This commit is contained in:
Swrup 2025-04-15 06:41:50 +02:00
parent 930c49e8d6
commit 281b40d64a
7 changed files with 52 additions and 46 deletions

View file

@ -156,7 +156,7 @@ let mk_image_div t_s =
let (file_label, file), alt = mk_image_field_unwraped () in
let () =
let has_file = S.map (fun t -> Option.is_some t.post_form.file) t_s in
Util.def_on has_file alt;
Util.def_visibility `On has_file alt;
let on =
S.map (fun t -> t.post_form.alt) t_s
|> S.changes |> E.filter_map Fun.id |> E.map Jstr.v