From c6265278f05aa4d3af60e420f2d4d13e4bce8ad7 Mon Sep 17 00:00:00 2001 From: Sébastien Dailly Date: Fri, 3 Dec 2021 04:19:53 +0100 Subject: Removed the application mecanism from the state module --- editor/actions/add_page.ml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'editor/actions/add_page.ml') diff --git a/editor/actions/add_page.ml b/editor/actions/add_page.ml index fcad87f..5e52d43 100755 --- a/editor/actions/add_page.ml +++ b/editor/actions/add_page.ml @@ -1,4 +1,5 @@ module Js = Js_of_ocaml.Js +module App = Editor_app module M = struct @@ -16,9 +17,10 @@ module M = struct State.new_page ~title (Some page_id) state end + (** Create a new element *) let create - : unit -> State.event Note.event + : unit -> App.event Note.event = fun () -> let title = Jstr.v "Nouvelle page" in let form = Forms.Add_page.create () in @@ -34,9 +36,9 @@ let create () in Note.E.map - (fun v -> State.E + (fun v -> App.E (v - , (module M : State.Event with type t = M.t ))) + , (module M : App.Event with type t = M.t ))) (* Option.on_some trigger the event only when the pop up is validated. Closing the popup doesn't do anything. *) -- cgit v1.2.3