diff --git a/modules/intermediate_format/ifweb.xql b/modules/intermediate_format/ifweb.xql index f7ea31ebc39c4a55b4c89f4035f702cffd7b8034..9c3d7bedeaefa50e2ef41305c98ba72ad1670021 100644 --- a/modules/intermediate_format/ifweb.xql +++ b/modules/intermediate_format/ifweb.xql @@ -22,7 +22,7 @@ declare function ifweb:main($resource as xs:string) as xs:string? { let $doc := doc($config:sade-data || $resource) let $filename := substring-before($resource, '.xml') || "-if.xml" - let $replace-whitespace := false() + let $replace-whitespace := true() let $preprocessed-data := pre:preprocessing($doc/tei:TEI, $replace-whitespace) let $intermediate-format := ident:walk($preprocessed-data, ()) diff --git a/modules/intermediate_format/preprocessing.xqm b/modules/intermediate_format/preprocessing.xqm index f2404f21229b062492ebd3e4bc4938be9ea42ef0..234194ebb9e68bab218c46baba05d82c60485acf 100644 --- a/modules/intermediate_format/preprocessing.xqm +++ b/modules/intermediate_format/preprocessing.xqm @@ -115,7 +115,8 @@ declare function pre:default-element and $following-sibling[self::ref or self::app or self::hi or self::bibl or self::foreign or self::choice or self::milestone or self::persName or self::choice or self::index or self::seg or self::ptr] - and not($node[self::index])) + and not($node[self::index]) + or ($node[self::milestone]) and $following-node[self::text()]) then attribute {"break-after"}{"yes"} else ()),