microsoft/qdk
Publicmirrored from https://github.com/microsoft/qdkAvailable
source/playground/public/katas.html
102lines · modecode
| 1 | <!doctype html> |
| 2 | <html lang="en"> |
| 3 | <head> |
| 4 | <meta charset="UTF-8" /> |
| 5 | <meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
| 6 | <title>Katas MathJax review</title> |
| 7 | <link |
| 8 | rel="stylesheet" |
| 9 | href="https://cdn.jsdelivr.net/npm/github-markdown-css@5.5.1/github-markdown-light.css" |
| 10 | /> |
| 11 | <link |
| 12 | rel="stylesheet" |
| 13 | href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/default.min.css" |
| 14 | /> |
| 15 | <style> |
| 16 | /* Override highlight.js if in dark mode */ |
| 17 | @import url("https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/styles/dark.min.css") |
| 18 | screen and (prefers-color-scheme: dark); |
| 19 | |
| 20 | /* Default colors, or theme set explicitly to light */ |
| 21 | :root, |
| 22 | [data-theme="light"] { |
| 23 | --kata-primay-color: #222; |
| 24 | --kata-background-color: #eee; |
| 25 | --kata-background-selected: #ccc; |
| 26 | --kata-row-highlight: #ddd; |
| 27 | } |
| 28 | /* User has set OS preference for dark (explicit theme will override) */ |
| 29 | @media (prefers-color-scheme: dark) { |
| 30 | :root { |
| 31 | --kata-primay-color: #eee; |
| 32 | --kata-background-color: #222; |
| 33 | --kata-background-selected: #444; |
| 34 | --kata-row-highlight: #333; |
| 35 | } |
| 36 | } |
| 37 | /* Explicit dark theme set (should match above dark preference values) */ |
| 38 | [data-theme="dark"] { |
| 39 | --kata-primay-color: #eee; |
| 40 | --kata-background-color: #222; |
| 41 | --kata-background-selected: #444; |
| 42 | --kata-row-highlight: #333; |
| 43 | } |
| 44 | |
| 45 | body { |
| 46 | font-family: system-ui, "Segoe UI", sans-serif; |
| 47 | color: var(--kata-primay-color); |
| 48 | background-color: var(--kata-background-color); |
| 49 | margin: 0; |
| 50 | } |
| 51 | table { |
| 52 | border-spacing: 0; |
| 53 | border-collapse: collapse; |
| 54 | vertical-align: middle; |
| 55 | } |
| 56 | table tr:nth-child(2n) { |
| 57 | background-color: var(--kata-row-highlight); |
| 58 | } |
| 59 | th, |
| 60 | td { |
| 61 | border: 0.5px solid gray; |
| 62 | padding: 8px; |
| 63 | } |
| 64 | .nav { |
| 65 | /* background: lightblue; */ |
| 66 | width: 320px; |
| 67 | height: 100vh; |
| 68 | padding-top: 16px; |
| 69 | position: fixed; |
| 70 | overflow-y: auto; |
| 71 | background-color: var(--kata-background-color); |
| 72 | } |
| 73 | .content { |
| 74 | margin-left: 330px; |
| 75 | padding: 16px; |
| 76 | width: calc(100% - 362px); |
| 77 | /* height: 100vh; */ |
| 78 | overflow-y: auto; |
| 79 | /* background: lightcyan; */ |
| 80 | } |
| 81 | .nav-item { |
| 82 | font-size: 1.1em; |
| 83 | padding: 8px; |
| 84 | color: var(--kata-primay-color); |
| 85 | } |
| 86 | .nav-item:hover { |
| 87 | background-color: var(--kata-row-highlight); |
| 88 | } |
| 89 | .nav-selected { |
| 90 | font-weight: bold; |
| 91 | background-color: var(--kata-background-selected); |
| 92 | } |
| 93 | </style> |
| 94 | </head> |
| 95 | <body> |
| 96 | <div id="app"></div> |
| 97 | <script src="libs/kataViewer.js"></script> |
| 98 | <script src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@11.9.0/build/highlight.min.js"></script> |
| 99 | <script src="https://cdn.jsdelivr.net/npm/highlightjs-qsharp@1.0.2/dist/qsharp.min.js"></script> |
| 100 | <script src="https://cdn.jsdelivr.net/npm/mathjax@3.2.2/es5/tex-mml-chtml.js"></script> |
| 101 | </body> |
| 102 | </html> |
| 103 | |