X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/1a0d01d9cdbffcf9667562502c3d2e36e5a9fa5b..94f422ac82d9af46410c63775e4aeea77395a730:/redakcja/static/xsl/wl2html_client.xsl?ds=sidebyside diff --git a/redakcja/static/xsl/wl2html_client.xsl b/redakcja/static/xsl/wl2html_client.xsl index 4414b0aa..4f642918 100644 --- a/redakcja/static/xsl/wl2html_client.xsl +++ b/redakcja/static/xsl/wl2html_client.xsl @@ -189,6 +189,16 @@ </div> </xsl:template> + <xsl:template match="nota_red"> + <xsl:param name="mixed" /> + <div> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="false()" /> + </xsl:apply-templates> + </div> + </xsl:template> + <!-- Tagi obejmujÄ ce tekst dedykacji (styl wieloakapitowy bÄ dź wielostrofowy): <dedykacja> tekst-dedykacji </dedykacja> @@ -634,12 +644,12 @@ --> <xsl:template match="sekcja_swiatlo"> <xsl:param name="mixed" /> - <br><xsl:call-template name="standard-attributes" /></br> + <hr><xsl:call-template name="standard-attributes" /></hr> </xsl:template> <xsl:template match="sekcja_asterysk"> <xsl:param name="mixed" /> - <hr><xsl:call-template name="standard-attributes" /></hr> + <p><xsl:call-template name="standard-attributes" /></p> </xsl:template> <xsl:template match="separator_linia"> @@ -649,7 +659,12 @@ <xsl:template match="zastepnik_wersu"> <xsl:param name="mixed" /> - <hr><xsl:call-template name="standard-attributes" /></hr> + <span> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </span> </xsl:template> <!-- @@ -728,7 +743,9 @@ <!-- <xsl:value-of select="." /> --> <xsl:param name="mixed" /> <xsl:choose> - <xsl:when test="normalize-space(.) = ''" /> + <xsl:when test="normalize-space(.) = ''"> + <xsl:value-of select="." /> + </xsl:when> <xsl:when test="not($mixed)"> <span x-node="out-of-flow-text" class="out-of-flow-text" x-editable="true"> <xsl:value-of select="." /> @@ -753,14 +770,16 @@ <!-- Earlier versions of html2wl introduced a BUG, that 'causes "out-of-flow-text" tag to appear. - Instead of marking it as "unknown", just pass thru it + Instead of marking it as "unknown", just pass thru it. + Keep a pass-thru span for out-of-flow box editing --> - <xsl:template match="out-of-flow-text"> - <xsl:param name="mixed" /> - <xsl:apply-templates select="child::node()"> - <xsl:with-param name="mixed" select="$mixed" /> - </xsl:apply-templates> - </xsl:template> + <xsl:template match="out-of-flow-text"> + <span data-pass-thru="true"> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="false()" /> + </xsl:apply-templates> + </span> + </xsl:template> <xsl:template match="*"> <span class="unknown-tag" x-node="{name()}"> @@ -806,5 +825,16 @@ </xsl:choose> </xsl:for-each> </xsl:template> - -</xsl:stylesheet> \ No newline at end of file + + <xsl:template match="alien"> + <span class="alien" x-pass-thru="true"> + <xsl:apply-templates select="node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </span> + </xsl:template> + + <xsl:template match="comment()"> + <xsl:comment><xsl:value-of select="."/></xsl:comment> + </xsl:template> +</xsl:stylesheet>