SF.net SVN: docutils:[9902 ] trunk/docutils/docutils/w riters/html5_polyglot/minimal .css

milde--- via Docutils-checkins <[email protected]>
Newsgroups gmane.text.docutils.cvs
Message-ID <[email protected]>
Revision: 9902
          http://sourceforge.net/p/docutils/code/9902
Author:   milde
Date:     2024-08-15 07:30:31 +0000 (Thu, 15 Aug 2024)
Log Message:
-----------
Fix CSS for HTML5: right align code line numbers.

It's a compromise: only numbers up to 99 are right aligned
to keep the reserved space small.

Modified Paths:
--------------
    trunk/docutils/docutils/writers/html5_polyglot/minimal.css

Modified: trunk/docutils/docutils/writers/html5_polyglot/minimal.css
===================================================================
--- trunk/docutils/docutils/writers/html5_polyglot/minimal.css	2024-08-15 07:30:22 UTC (rev 9901)
+++ trunk/docutils/docutils/writers/html5_polyglot/minimal.css	2024-08-15 07:30:31 UTC (rev 9902)
@@ -235,10 +235,14 @@
 div.line-block { display: block; }
 div.line-block div.line-block, pre { margin-left: 2em; }
 
-/* Code line numbers: dropped when copying text from the page */
+/* Code line numbers: align-right, don't copy with drag-and-drop */
 pre.code .ln { display: none; }
 pre.code code:before {
-  content: attr(data-lineno); /* …, none) fallback not supported by any browser */
+  content: attr(data-lineno);
+  display: inline-block;
+  min-width: 1.8em;
+  text-align: right;
+  font-size: small;
   color: gray;
 }
 

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



_______________________________________________
Docutils-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/docutils-checkins
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.