;; Declarative wodoc config for the TyXML documentation.
;;   wodoc build --config doc/wodoc --out <dir>/<label> --label <v> \
;;               --menu https://ocsigen.org/doc/menu.html [--local]
;; (wodoc build runs `dune build @doc --profile release` itself when --src is omitted.)
;; TyXML has no client/server split, so plain `dune build @doc` is enough (no
;; odoc-driver). The auxiliary packages (tyxml-ppx/syntax/jsx) live on ocaml.org;
;; the manual's ppx/jsx pages document their use. odoc puts the manual pages and
;; the API together under the tyxml/ package dir.
(project tyxml)
(title TyXML)
(url-prefix /tyxml)
(css /css/style.css /css/ocsigen-odoc.css)  ; shared Ocsigen theme (wodoc css default changed)
(profile release)                   ; dev profile treats warning 67 as an error
(landing tyxml/index.html)          ; the package home page (docs/index.mld)
(nav
  (section "TyXML - Manual"
    (link "Introduction"          tyxml/index.html    index)
    (link "Functorial interface"  tyxml/functors.html functors)
    (link "Ppx syntax extension"  tyxml/ppx.html      ppx)
    (link "JSX syntax"            tyxml/jsx.html      jsx))
  (section "TyXML - API"
    (link "API reference" tyxml/api.html api)))

;; Sibling Ocsigen projects, so wodoc rewrites their ocaml.org cross-references
;; to relative links into their deployed docs on ocsigen.org. The full family is
;; listed (not only the ones this doc currently links to) so that adding a link
;; later never silently breaks. (pkg deploy-dir layout wrapper-module)
(hosted
  (eliom             eliom           true  Eliom)
  (ocsigen-toolkit   ocsigen-toolkit true  Ot)
  (ocsigen-start     ocsigen-start   true  Os)
  (ocsigenserver     ocsigenserver   false Ocsigen)
  (js_of_ocaml       js_of_ocaml     subdir)
  (js_of_ocaml-tyxml js_of_ocaml     subdir)  ; Tyxml_js, referenced by the manual
  (tyxml             tyxml           subdir)
  (lwt               lwt             subdir)
  (reactiveData      reactiveData    root))
