diff options
author | Sébastien Dailly <sebastien@dailly.me> | 2022-02-07 16:40:45 +0100 |
---|---|---|
committer | Sébastien Dailly <sebastien@dailly.me> | 2022-02-07 16:43:33 +0100 |
commit | 8d23a029c57be92a7aed0f18d9fcf1c931c1038e (patch) | |
tree | 5bce8907c420b171de9f49679045723aad03e247 /editor/state/state.mli | |
parent | 6f1b152a6927171b0c0bfed207307ed1bac1900d (diff) |
Reformat
Diffstat (limited to 'editor/state/state.mli')
-rwxr-xr-x | editor/state/state.mli | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/editor/state/state.mli b/editor/state/state.mli index 57b45fa..c98a8ab 100755 --- a/editor/state/state.mli +++ b/editor/state/state.mli @@ -4,30 +4,32 @@ module Storage = Storage type t = { editable : bool ; view : Prosemirror.View.editor_view Js.t - ; last_backup: float - ; page_id: Jstr.t option - + ; last_backup : float + ; page_id : Jstr.t option ; window : Brr.El.t list ; pm : Prosemirror.t } +val eq : t -> t -> bool -val eq: t -> t -> bool - +val set_title : Storage.content Js.t -> unit (** Update the title element according to the page. *) -val set_title - : Storage.content Js.t -> unit -val state_of_storage - : Prosemirror.t -> Storage.content Js.t -> Prosemirror.Model.schema Js.t -> Prosemirror.State.editor_state Js.t +val state_of_storage : + Prosemirror.t + -> Storage.content Js.t + -> Prosemirror.Model.schema Js.t + -> Prosemirror.State.editor_state Js.t -val load_page - : Jstr.t option -> t -> t +val load_page : Jstr.t option -> t -> t +val new_page : Jstr.t option -> title:Jstr.t -> t -> t (** Create a new empty page, and load it *) -val new_page - : Jstr.t option -> title:Jstr.t -> t -> t +val init : + Prosemirror.t + -> Prosemirror.View.editor_view Js.t + -> float + -> Jstr.t option + -> t (** Initialise a new state *) -val init - : Prosemirror.t -> Prosemirror.View.editor_view Js.t -> float -> Jstr.t option -> t |