Commit 6d7e6740 authored by Jerome Chauveau's avatar Jerome Chauveau
Browse files

modification du test de contexte texte afin d'afficher ou non les options de...

modification du test de contexte texte afin d'afficher ou non les options de lecture : vérification de l'existence d'un élement ayant l'identifiant 'text' dans le contenu.
parent e2e21485
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@ declare variable $max.cons:PLUGINS_BASE_DIR := "/plugins";
(: TOC path name (in URLs):)
declare variable $max.cons:TOC := "sommaire";

declare variable $max.cons:TEXT_ID := "text";

(: MENU file path. :)
declare variable $max.cons:MENU_FILE := "menu.xml";
@@ -62,7 +63,7 @@ declare variable $max.cons:ROUTE_ID_CONTEXT_KEY := "routeId";


(:Edition Route TOC function name:)
declare variable $max.cons:EDITION_ROUTE_TOC_FUNC := "getRouteTOC";
(:declare variable $max.cons:EDITION_ROUTE_TOC_FUNC := "getRouteTOC";:)

(:Edition's Footer path:)
declare variable $max.cons:EDITION_FOOTER_PATH := "fragments/footer.frag.html";
+1 −1
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@ declare function max.html:render(
            else ()
    let $doc := if ($fragmentId) then $pageId else tokenize($pageId,'doc/')[last()]
    let $navigationSelect := if($targetId) then max.html:getNavbarForDocument($projectId, $doc, $targetId) else()
    let $textOptions := if ($targetId) then max.html:buildTextOptionsMenu($projectId) else ()
    let $textOptions := if ($content//*[@id=$max.cons:TEXT_ID]) then max.html:buildTextOptionsMenu($projectId) else ()

    return
        try {