pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jonathan S. Katz <jkatz@postgresql.org>
To: Peter Geoghegan <pg@bowt.ie>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Pg Docs <pgsql-docs@lists.postgresql.org>
Subject: Re: Duplicating website's formatting in local doc builds
Date: Fri, 14 Feb 2020 21:01:44 -0500
Message-ID: <942a40ca-6ad8-4e79-3d7e-fa511a3f7513@postgresql.org> (raw)
In-Reply-To: <CAH2-Wzmmftu7eXcWKfZKCQ3C_qcKiKwsGSyvmXCNCCPVDW7zrw@mail.gmail.com>
References: <1375.1581446233@sss.pgh.pa.us>
	<d381c45a-880f-7b0d-773d-be117685a6ad@postgresql.org>
	<3873.1581449531@sss.pgh.pa.us>
	<4b44c4ec-a678-6586-fbb0-efc3299af203@postgresql.org>
	<CAH2-Wzka_NfJGfL9UvQ1Jau1gqerat2zR9O0iAm3DgQEAYebJQ@mail.gmail.com>
	<dc3089b0-9c40-fc3b-bce1-7fcc16891dd1@postgresql.org>
	<86f03290-e60c-855e-786a-d1b75c254811@postgresql.org>
	<716a39ec-6f56-0280-8d4b-b246176c6a3d@postgresql.org>
	<bd7e5ec0-caa4-56d0-562e-21880e205e02@postgresql.org>
	<11007.1581721578@sss.pgh.pa.us>
	<8d663c68-3df0-bf3f-8c2e-e6897a55394a@postgresql.org>
	<17445.1581731499@sss.pgh.pa.us>
	<CAH2-Wzmmftu7eXcWKfZKCQ3C_qcKiKwsGSyvmXCNCCPVDW7zrw@mail.gmail.com>

On 2/14/20 8:56 PM, Peter Geoghegan wrote:
> On Fri, Feb 14, 2020 at 5:51 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Hm, I wouldn't go into that much detail; it'd likely soon be out of
>> date anyway.  I had in mind something more like "If the STYLE=website
>> option is used, the generated HTML files will include references to
>> stylesheets hosted at www.postgresql.org, so that viewing them will
>> require network access."
> 
> But everything else looks good, right?
> 
> I would like to commit this patch shortly.

Language updates attached...mostly kept Tom's suggestions.

Thanks,

Jonathan

Attachments:

website-formatted-docs-v6.patch (text/plain, 2.1K) download diff --git a/doc/src/sgml/docguide.sgml b/doc/src/sgml/docguide.sgml index c99198f5e5..64ebdb3257 100644 --- a/doc/src/sgml/docguide.sgml +++ b/doc/src/sgml/docguide.sgml @@ -276,6 +276,13 @@ checking for fop... fop <prompt>doc/src/sgml$ </prompt><userinput>make STYLE=website html</userinput> </screen> </para> + + <para> + If the <literal>STYLE=website</literal> optoin is used, the generated HTML + files include references to stylesheets hosted on <ulink + url="https://www.postgresql.org/docs/current/">postgresql.org</ulink> and + require network access to view. + </para> </sect2> <sect2> diff --git a/doc/src/sgml/stylesheet-html-common.xsl b/doc/src/sgml/stylesheet-html-common.xsl index 9edce52a10..d9961089c6 100644 --- a/doc/src/sgml/stylesheet-html-common.xsl +++ b/doc/src/sgml/stylesheet-html-common.xsl @@ -18,6 +18,14 @@ <xsl:param name="link.mailto.url">pgsql-docs@lists.postgresql.org</xsl:param> <xsl:param name="toc.max.depth">2</xsl:param> +<!-- + The below allows the stylesheets provided by the website to be applied fully + to the generated HTML. + --> +<xsl:template name="body.attributes"> + <xsl:attribute name="id">docContent</xsl:attribute> + <xsl:attribute name="class">container-fluid col-10</xsl:attribute> +</xsl:template> <!-- Change display of some elements --> diff --git a/doc/src/sgml/stylesheet.xsl b/doc/src/sgml/stylesheet.xsl index 4ff6e8ed24..bc5a904e0b 100644 --- a/doc/src/sgml/stylesheet.xsl +++ b/doc/src/sgml/stylesheet.xsl @@ -23,11 +23,15 @@ <xsl:param name="html.stylesheet"> <xsl:choose> <xsl:when test="$website.stylesheet = 0">stylesheet.css</xsl:when> - <xsl:otherwise>https://www.postgresql.org/media/css/docs.css</xsl:otherwise> + <xsl:otherwise> + https://www.postgresql.org/media/css/fontawesome.css + https://www.postgresql.org/media/css/bootstrap.min.css + https://www.postgresql.org/media/css/main.css + https://www.postgresql.org/media/css/normalize.css + </xsl:otherwise> </xsl:choose> </xsl:param> - <!-- strip directory name from image filerefs --> <xsl:template match="imagedata/@fileref"> <xsl:value-of select="substring-after(., '/')"/>
signature.asc (application/pgp-signature, 832B) download

view thread (18+ messages)  latest in thread

Message-ID: <942a40ca-6ad8-4e79-3d7e-fa511a3f7513@postgresql.org>
Permalink:  ../942a40ca-6ad8-4e79-3d7e-fa511a3f7513@postgresql.org/
Also on:    postgresql.org/message-id/942a40ca-6ad8-4e79-3d7e-fa511a3f7513@postgresql.org

 ·  · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-docs@postgresql.org
  Cc: jkatz@postgresql.org, pg@bowt.ie, tgl@sss.pgh.pa.us, pgsql-docs@lists.postgresql.org
  Subject: Re: Duplicating website's formatting in local doc builds
  In-Reply-To: <942a40ca-6ad8-4e79-3d7e-fa511a3f7513@postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox