diff options
| author | nsfisis <nsfisis@gmail.com> | 2025-11-30 03:10:01 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2025-11-30 03:10:01 +0900 |
| commit | 277ff78fa74be86de86fdfa66af7f4ae2fb17980 (patch) | |
| tree | bc4a24da8eb24149460f950ef73eefa9653d704a /services/nuldoc/static | |
| parent | 1730a81a6560c2baa75791d6edba2e2a1d997d4e (diff) | |
| download | nsfisis.dev-277ff78fa74be86de86fdfa66af7f4ae2fb17980.tar.gz nsfisis.dev-277ff78fa74be86de86fdfa66af7f4ae2fb17980.tar.zst nsfisis.dev-277ff78fa74be86de86fdfa66af7f4ae2fb17980.zip | |
feat(slides): Update style of slide controller buttons
Diffstat (limited to 'services/nuldoc/static')
| -rw-r--r-- | services/nuldoc/static/_all/style.css | 30 | ||||
| -rw-r--r-- | services/nuldoc/static/slides/slide.js | 8 |
2 files changed, 35 insertions, 3 deletions
diff --git a/services/nuldoc/static/_all/style.css b/services/nuldoc/static/_all/style.css index 8c848bc..32dd4f5 100644 --- a/services/nuldoc/static/_all/style.css +++ b/services/nuldoc/static/_all/style.css @@ -418,3 +418,33 @@ img { color: #000; border-bottom-color: #000; } + +.controllers { + display: flex; + flex-direction: column; + align-items: end; + margin: 1rem 0; +} + +.controllers-buttons { + display: flex; + align-items: center; + gap: 1rem; +} + +.controllers button { + width: 3.5rem; + height: 3rem; + border-radius: 0.5rem; + background: #000; + display: flex; + align-items: center; + justify-content: center; + color: #fff; + border: none; + cursor: pointer; +} + +.controllers button:hover { + background: #555; +} diff --git a/services/nuldoc/static/slides/slide.js b/services/nuldoc/static/slides/slide.js index 4c7a0de..75a8d35 100644 --- a/services/nuldoc/static/slides/slide.js +++ b/services/nuldoc/static/slides/slide.js @@ -1,6 +1,6 @@ -import { GlobalWorkerOptions, getDocument } from "/pdf.min.mjs"; +import { getDocument, GlobalWorkerOptions } from "./pdf.min.mjs"; -document.addEventListener("DOMContentLoaded", async () => { +async function init() { GlobalWorkerOptions.workerSrc = "/pdf.worker.min.mjs"; const canvas = document.getElementById("slide"); @@ -57,4 +57,6 @@ document.addEventListener("DOMContentLoaded", async () => { // TODO: error handling doc = await getDocument(url).promise; queueRenderPage(pageNum); -}); +} + +document.addEventListener("DOMContentLoaded", init); |
