Source files of fsfe.org, pdfreaders.org, freeyourandroid.org, ilovefs.org, drm.info, and test.fsfe.org. Contribute: https://fsfe.org/contribute/web/ https://fsfe.org
Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

51 lines
1.9KB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
  3. xmlns:dt="http://xsltsl.org/date-time"
  4. exclude-result-prefixes="dt"
  5. xmlns:str="http://exslt.org/strings"
  6. extension-element-prefixes="str">
  7. <xsl:import href="build/xslt/gettext.xsl" />
  8. <xsl:import href="tools/xsltsl/static-elements.xsl" />
  9. <xsl:import href="tools/xsltsl/tagging.xsl" />
  10. <xsl:import href="build/xslt/fsfe_head.xsl" />
  11. <xsl:import href="build/xslt/fsfe_body.xsl" />
  12. <!-- For pages used on external web servers, load the CSS from absolute URL -->
  13. <xsl:variable name="urlprefix">
  14. <xsl:if test="/buildinfo/document/@external">https://fsfe.org</xsl:if>
  15. </xsl:variable>
  16. <xsl:include href="build/xslt/fsfe_document.xsl" />
  17. <xsl:include href="build/xslt/fsfe_headings.xsl" />
  18. <xsl:include href="build/xslt/fsfe_localmenu.xsl" />
  19. <!-- Do not copy non-HTML elements to output -->
  20. <xsl:include href="build/xslt/fsfe_nolocal.xsl" />
  21. <!-- HTML 5 compatibility doctype, since our XSLT parser doesn't support disabling output escaping -->
  22. <xsl:output method="html" encoding="utf-8" indent="yes" doctype-system="about:legacy-compat" />
  23. <!-- Ignore "latin" tags, used only for printable material -->
  24. <xsl:template match="latin">
  25. <xsl:apply-templates select="@*|node()"/>
  26. </xsl:template>
  27. <!--FIXME ↓-->
  28. <xsl:template match="fetch-news">
  29. <xsl:call-template name="fetch-news">
  30. <xsl:with-param name="tag" select="'/buildinfo/document/sidebar/@news'"/>
  31. <xsl:with-param name="nb-items" select="4"/>
  32. </xsl:call-template>
  33. </xsl:template>
  34. <!-- Static elements which can be included everywhere -->
  35. <xsl:template match="static-element">
  36. <xsl:variable name="id"><xsl:value-of select="@id"/></xsl:variable>
  37. <xsl:copy-of select="/buildinfo/document/set/element[@id=$id]" />
  38. </xsl:template>
  39. </xsl:stylesheet>