unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#69815: [PATCH] Fix some CSS issues on elpa.gnu.org
@ 2024-03-15 17:37 john muhl
  2024-03-17 10:56 ` Philip Kaludercic
  0 siblings, 1 reply; 6+ messages in thread
From: john muhl @ 2024-03-15 17:37 UTC (permalink / raw)
  To: 69815

[-- Attachment #1: Type: text/plain, Size: 688 bytes --]

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.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Fix-some-CSS-issues.patch --]
[-- Type: text/x-patch, Size: 1439 bytes --]

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


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0001-Show-rank-instead-of-version-on-narrow-displays.patch --]
[-- Type: text/x-patch, Size: 842 bytes --]

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


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: 0001-elpa-admin.el-elpaa-html-header-Fix-DOCTYPE.patch --]
[-- Type: text/x-patch, Size: 718 bytes --]

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>
 <html lang=\"en\" xml:lang=\"en\">
     <head>
         <title>%s</title>
-- 
2.41.0


[-- Attachment #5: before.png --]
[-- Type: image/png, Size: 61094 bytes --]

[-- Attachment #6: narrow.png --]
[-- Type: image/png, Size: 82788 bytes --]

[-- Attachment #7: after.png --]
[-- Type: image/png, Size: 90217 bytes --]

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2024-03-22 15:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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
2024-03-22 12:55     ` john muhl
2024-03-22 14:56       ` Philip Kaludercic
2024-03-22 15:33         ` john muhl

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).