X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/4c48c47d0b84e516114c16ee191359166e93a51c..c63cb9e4a92378f9a630f95faa3d4d167e7aa8ec:/redakcja/static/xsl/wl2html_client.xsl diff --git a/redakcja/static/xsl/wl2html_client.xsl b/redakcja/static/xsl/wl2html_client.xsl index 4f642918..8be6e225 100644 --- a/redakcja/static/xsl/wl2html_client.xsl +++ b/redakcja/static/xsl/wl2html_client.xsl @@ -732,6 +732,119 @@ </span> </xsl:template> + <!-- + ************************** + MATERIAÅY EDUKACYJNE + ************************** + --> + + <!-- + Listy + --> + <xsl:template match="lista"> + <xsl:variable name="listtag"> + <xsl:choose> + <xsl:when test="@typ='num' or @typ='alfa'">ol</xsl:when> + <xsl:when test="@typ='punkt' or @typ='slowniczek' or @typ='czytelnia'">ul</xsl:when> + <xsl:otherwise>ul</xsl:otherwise> + </xsl:choose> + </xsl:variable> + <xsl:element name="{$listtag}"> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </xsl:element> + </xsl:template> + + + <xsl:template match="punkt[../@typ='slowniczek']"> + <dl x-node="punkt" class="punkt"> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </dl> + </xsl:template> + + <xsl:template match="punkt[../@typ!='slowniczek']"> + <li x-editable="true" x-node="punkt" class="punkt"> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </li> + </xsl:template> + + <!-- + SÅowniczek + --> + <xsl:template match="definiendum"> + <dt x-editable="true" x-node="definiendum" class="definiendum"> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </dt> + </xsl:template> + + <xsl:template match="definiens"> + <dd x-editable="true" x-node="definiendum" class="definiendum"> + <xsl:call-template name="standard-attributes" /> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </dd> + </xsl:template> + + <!-- + Tabela + --> + + <xsl:template match="wiersz"> + <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> + + + <xsl:template match="kol"> + <span> + <xsl:call-template name="standard-attributes" /> + <div x-editable="true" x-node="kol-inside" x-pass-thru="true"> + <xsl:apply-templates select="child::node()"> + <xsl:with-param name="mixed" select="true()" /> + </xsl:apply-templates> + </div> + </span> + </xsl:template> + + + <!-- + Obraz + --> + <xsl:template match="obraz"> + <img x-node="obraz" src="http://i.imgur.com/{@name}.jpg" class="obraz"> + <xsl:call-template name="standard-attributes" /> + </img> + </xsl:template> + + <!-- + Semantyczne pudeÅka + --> + <xsl:template match="pomoce|forma|czas|opis|kol-inside"> + <span x-editable="true"> + <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> + + <!-- **************** @@ -783,6 +896,7 @@ <xsl:template match="*"> <span class="unknown-tag" x-node="{name()}"> + <xsl:call-template name="standard-attributes" /> <xsl:apply-templates select="child::node()"> <xsl:with-param name="mixed" select="true()" /> </xsl:apply-templates>