]> git.ipfire.org Git - thirdparty/fastapi/fastapi.git/commitdiff
🔨 Update docs Termynal scripts to not include line nums for local dev (#11854)
authorSebastián Ramírez <tiangolo@gmail.com>
Wed, 17 Jul 2024 02:12:29 +0000 (21:12 -0500)
committerGitHub <noreply@github.com>
Wed, 17 Jul 2024 02:12:29 +0000 (21:12 -0500)
docs/en/docs/css/custom.css
docs/en/docs/js/custom.js

index 386aa9d7e7fd3289febe408f07a1929718b2a802..b192f6123a27399e3b44e379427434ca52d5d34b 100644 (file)
   white-space: pre-wrap;
 }
 
+.termy .linenos {
+  display: none;
+}
+
 a.external-link {
   /* For right to left languages */
   direction: ltr;
index 8e3be4c130704a12174ac56f7a325706bc4d7a80..0008db49e3b98cd374035be8dc609f165fcf429d 100644 (file)
@@ -35,7 +35,7 @@ function setupTermynal() {
 
     function createTermynals() {
         document
-            .querySelectorAll(`.${termynalActivateClass} .highlight`)
+            .querySelectorAll(`.${termynalActivateClass} .highlight code`)
             .forEach(node => {
                 const text = node.textContent;
                 const lines = text.split("\n");