unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: john muhl <jm@pub.pink>
To: Philip Kaludercic <philipk@posteo.net>
Cc: 69815@debbugs.gnu.org
Subject: bug#69815: [PATCH] Fix some CSS issues on elpa.gnu.org
Date: Sun, 17 Mar 2024 21:01:44 -0500	[thread overview]
Message-ID: <875xxkmfrg.fsf@pub.pink> (raw)
In-Reply-To: <87jzm19le0.fsf@posteo.net>

Philip Kaludercic <philipk@posteo.net> writes:

> john muhl <jm@pub.pink> writes:
>
>> Here are a few patches fixing some minor issues. The first one
>> makes the packages table always full-width and expands the footer
>> background so it contains all the footer text (see before.png).
>>
>> I noticed that with a very narrow view the CSS drops the rank
>> column to help fit but it doesn’t help quite enough to prevent
>> horizontal overflow (narrow.png). It seems to me that the version
>> column is the least important so the second patch changes the
>> narrow view to drop it instead of the rank (after.png).
>>
>> The last patch fixes the doctype for sub-pages. <!DOCTYPE HTML
>> PUBLIC> is not a valid doctype and so triggers quirks mode. Not a
>> big deal but probably better avoided.
>>
>>>From f13cc711f0bf368f9acb1ae579ab9e078aefce1e Mon Sep 17 00:00:00 2001
>> From: john muhl <jm@pub.pink>
>> Date: Thu, 14 Mar 2024 13:22:52 -0500
>> Subject: [PATCH] Fix some CSS issues
>>
>> * html/layout.css (footer): Remove fixed height so the background
>> expands to encompass all footer content.
>> (table): Make packages table always use full page width.
>> ---
>>  html/layout.css | 12 ++++++------
>>  1 file changed, 6 insertions(+), 6 deletions(-)
>>
>> diff --git a/html/layout.css b/html/layout.css
>> index 7d3be41..9d04958 100644
>> --- a/html/layout.css
>> +++ b/html/layout.css
>> @@ -1,4 +1,4 @@
>> -l/* Copyright (C) 2010-2022, 2024 Free Software Foundation, Inc.
>> +/* Copyright (C) 2010-2022, 2024 Free Software Foundation, Inc.
>>  
>>  This file is free software: you can redistribute it and/or modify
>>  it under the terms of the GNU General Public License as published by
>> @@ -74,7 +74,7 @@ html, body {
>>    height: 100%;
>>    margin: 0 auto -50px; /* the bottom margin is the negative value of the footer's height */
>>  }
>> -footer, .push, .footer {
>> +.push {
>>    height: 90px; /* .push must be the same height as .footer */
>>  }
>>  
>> @@ -302,6 +302,10 @@ footer p, .footer p {
>>    line-height: 1.4em;
>>  }
>>  
>> +table {
>> +  width: 100%;
>> +}
>> +
>>  @media screen and (max-width: 999px) {
>>    .container {
>>      width: 600px;
>> @@ -313,10 +317,6 @@ footer p, .footer p {
>>      font-size: 1em;
>>    }
>>  
>> -  table {
>> -    width: 100%;
>> -  }
>> -  
>>    .container {
>>      width: 90%;
>>      padding: 40px 5%;
>> -- 
>> 2.41.0
>
> Looks good.
>
>>
>>>From 5dafd0d3483336ff50b5039942bc35c41d30644f Mon Sep 17 00:00:00 2001
>> From: john muhl <jm@pub.pink>
>> Date: Thu, 14 Mar 2024 13:46:54 -0500
>> Subject: [PATCH] Show rank instead of version on narrow displays
>>
>> * html/layout.css (td):
>> (th): Hide version and right align rank column.
>> ---
>>  html/layout.css | 7 ++++++-
>>  1 file changed, 6 insertions(+), 1 deletion(-)
>>
>> diff --git a/html/layout.css b/html/layout.css
>> index 9d04958..02dfb87 100644
>> --- a/html/layout.css
>> +++ b/html/layout.css
>> @@ -283,6 +283,11 @@ td {
>>    border-bottom: 1px solid #ddd;
>>  }
>>  
>> +td:last-child,
>> +th:last-child {
>> +  text-align: right;
>> +}
>> +
>>  footer, .footer {
>>    border-top: 1px solid #999;
>>    text-align:center;
>> @@ -330,7 +335,7 @@ table {
>>      width: 300px;
>>    }
>>  
>> -  td:last-child, th:last-child {
>> +  td:nth-child(2), th:nth-child(2) {
>>      display: none;
>>    }
>>  
>> -- 
>> 2.41.0
>
>
> Why not show both, and allow scrolling horizontally (x-overflow: auto)
> if there is not enough space?
>
>>
>>
>>>From 16547922cc9339e4f920ae62a1bee09c38625cbf Mon Sep 17 00:00:00 2001
>> From: john muhl <jm@pub.pink>
>> Date: Thu, 14 Mar 2024 16:54:45 -0500
>> Subject: [PATCH] * elpa-admin.el (elpaa--html-header): Fix DOCTYPE.
>>
>> ---
>>  elpa-admin.el | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/elpa-admin.el b/elpa-admin.el
>> index d4a9dcf..9475336 100644
>> --- a/elpa-admin.el
>> +++ b/elpa-admin.el
>> @@ -1544,7 +1544,7 @@ readme file has an unconventional name"
>>  ;;; Make the HTML pages for online browsing.
>>  
>>  (defun elpaa--html-header (title &optional header head-extra)
>> -  (format "<!DOCTYPE HTML PUBLIC>
>> +  (format "<!DOCTYPE HTML>
>
> What difference does this make?  Or rather how is this related to the
> other patches?  That should be explained in the commit message.

It’s unrelated. I just included it since it looked like a mistake.
If those pages require quirks mode then a better fix would be get
rid of that requirement. Checking now I see that they serve
non-conforming HTML so perhaps we should fix that first.





  reply	other threads:[~2024-03-18  2:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-15 17:37 bug#69815: [PATCH] Fix some CSS issues on elpa.gnu.org john muhl
2024-03-17 10:56 ` Philip Kaludercic
2024-03-18  2:01   ` john muhl [this message]
2024-03-22 12:55     ` john muhl
2024-03-22 14:56       ` Philip Kaludercic
2024-03-22 15:33         ` john muhl

Reply instructions:

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

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

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875xxkmfrg.fsf@pub.pink \
    --to=jm@pub.pink \
    --cc=69815@debbugs.gnu.org \
    --cc=philipk@posteo.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).