|
| 1 | +/* Custom styles for HED Python Tools Documentation - Furo Theme */ |
| 2 | + |
| 3 | +/* Quick Links sidebar styling - darker gray box with proper padding */ |
| 4 | +.sidebar-quicklinks { |
| 5 | + margin: 1rem 0.75rem 1rem 0.75rem; |
| 6 | + padding: 0.75rem 1rem; |
| 7 | + background-color: #e8e8e8; |
| 8 | + border-radius: 0.25rem; |
| 9 | + border: 1px solid #d0d0d0; |
| 10 | +} |
| 11 | + |
| 12 | +/* Dark mode styling for quick links - much darker background */ |
| 13 | +body[data-theme="dark"] .sidebar-quicklinks { |
| 14 | + background-color: #0d0d0d; |
| 15 | + border-color: #1a1a1a; |
| 16 | +} |
| 17 | + |
| 18 | +.sidebar-quicklinks h3 { |
| 19 | + margin-top: 0; |
| 20 | + margin-bottom: 0.5rem; |
| 21 | + color: var(--color-sidebar-link-text); |
| 22 | + font-size: var(--sidebar-item-font-size); |
| 23 | + font-weight: 600; |
| 24 | +} |
| 25 | + |
| 26 | +.sidebar-quicklinks ul { |
| 27 | + list-style: none; |
| 28 | + padding-left: 0; |
| 29 | + margin-bottom: 0; |
| 30 | +} |
| 31 | + |
| 32 | +.sidebar-quicklinks li { |
| 33 | + margin-bottom: 0.25rem; |
| 34 | +} |
| 35 | + |
| 36 | +.sidebar-quicklinks a { |
| 37 | + color: var(--color-link) !important; |
| 38 | + text-decoration: none; |
| 39 | + font-size: var(--sidebar-item-font-size); |
| 40 | + display: block; |
| 41 | + padding: 0.25rem 0; |
| 42 | + transition: color 0.2s ease; |
| 43 | +} |
| 44 | + |
| 45 | +.sidebar-quicklinks a:hover { |
| 46 | + color: var(--color-link-hover) !important; |
| 47 | + text-decoration: underline; |
| 48 | +} |
| 49 | + |
| 50 | +/* External link icon for quick links */ |
| 51 | +.sidebar-quicklinks a[target="_blank"]::after { |
| 52 | + content: " ↗"; |
| 53 | + font-size: 0.7em; |
| 54 | + opacity: 0.6; |
| 55 | +} |
| 56 | + |
| 57 | +/* Make search field more visible with same background as quick links */ |
| 58 | +.sidebar-search-container { |
| 59 | + margin: 0 0.75rem; |
| 60 | +} |
| 61 | + |
| 62 | +.sidebar-search-container input { |
| 63 | + background-color: #e8e8e8 !important; |
| 64 | + border: 1px solid #d0d0d0 !important; |
| 65 | + color: var(--color-foreground-primary) !important; |
| 66 | + background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23666666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") !important; |
| 67 | + background-repeat: no-repeat !important; |
| 68 | + background-position: right 0.5rem center !important; |
| 69 | + background-size: 1.2em !important; |
| 70 | + padding-right: 2.5rem !important; |
| 71 | +} |
| 72 | + |
| 73 | +body[data-theme="dark"] .sidebar-search-container input { |
| 74 | + background-color: #0d0d0d !important; |
| 75 | + border: 1px solid #1a1a1a !important; |
| 76 | + color: #e8e8e8 !important; |
| 77 | + background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23cccccc' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") !important; |
| 78 | +} |
| 79 | + |
| 80 | +/* Make search icon visible */ |
| 81 | +.sidebar-search-container input::placeholder { |
| 82 | + color: var(--color-foreground-muted) !important; |
| 83 | + opacity: 1 !important; |
| 84 | +} |
| 85 | + |
| 86 | +body[data-theme="dark"] .sidebar-search-container input::placeholder { |
| 87 | + color: #999999 !important; |
| 88 | +} |
| 89 | + |
| 90 | +/* Style search icon/button visibility */ |
| 91 | +.sidebar-search .icon { |
| 92 | + color: var(--color-foreground-muted) !important; |
| 93 | +} |
| 94 | + |
| 95 | +body[data-theme="dark"] .sidebar-search .icon { |
| 96 | + color: #999999 !important; |
| 97 | +} |
| 98 | + |
| 99 | +/* Hide view source and edit buttons in top-right header */ |
| 100 | +a.muted-link[href*="_sources"], |
| 101 | +a.muted-link[title*="Edit this page"], |
| 102 | +a.muted-link[title*="View page source"], |
| 103 | +.content-icon-container a[href*="_sources"] { |
| 104 | + display: none !important; |
| 105 | +} |
| 106 | + |
| 107 | +/* Ensure GitHub repository button shows as icon in top-right header */ |
| 108 | + |
| 109 | +/* Target the hijacked link using the class added by JS, OR the href attribute as fallback */ |
| 110 | +.content-icon-container a.github-repo-link, |
| 111 | +.content-icon-container a[href*="github.com"]:not([href*="/edit/"]) { |
| 112 | + display: inline-flex !important; |
| 113 | + align-items: center !important; |
| 114 | + justify-content: center !important; |
| 115 | + width: 2rem !important; |
| 116 | + height: 2rem !important; |
| 117 | + |
| 118 | + /* GitHub Icon */ |
| 119 | + background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12' fill='%23666666'/%3E%3C/svg%3E") !important; |
| 120 | + background-repeat: no-repeat !important; |
| 121 | + background-position: center !important; |
| 122 | + background-size: 1.2rem !important; |
| 123 | + |
| 124 | + color: transparent !important; /* Hide any text */ |
| 125 | + overflow: hidden !important; |
| 126 | +} |
| 127 | + |
| 128 | +/* Hide the original SVG icon inside the link */ |
| 129 | +.content-icon-container a.github-repo-link svg, |
| 130 | +.content-icon-container a[href*="github.com"] svg { |
| 131 | + display: none !important; |
| 132 | +} |
| 133 | + |
| 134 | +/* Dark mode icon color */ |
| 135 | +body[data-theme="dark"] .content-icon-container a.github-repo-link, |
| 136 | +body[data-theme="dark"] .content-icon-container a[href*="github.com"]:not([href*="/edit/"]) { |
| 137 | + background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12' fill='%23cccccc'/%3E%3C/svg%3E") !important; |
| 138 | +} |
| 139 | + |
| 140 | +/* Explicitly hide the edit link via CSS as well */ |
| 141 | +.content-icon-container a[href*="/edit/"] { |
| 142 | + display: none !important; |
| 143 | +} |
| 144 | + |
| 145 | +/* Logo styling - ensure visibility in both light and dark modes */ |
| 146 | +.sidebar-brand-text { |
| 147 | + font-weight: 600; |
| 148 | +} |
| 149 | + |
| 150 | +/* Adjust logo size if needed */ |
| 151 | +.sidebar-logo { |
| 152 | + margin-bottom: 0.5rem; |
| 153 | +} |
| 154 | + |
| 155 | +.sidebar-logo img { |
| 156 | + max-width: 100%; |
| 157 | + height: auto; |
| 158 | +} |
0 commit comments