diff options
| author | Hsieh Chin Fan <pham@topo.tw> | 2024-09-22 19:12:28 +0800 |
|---|---|---|
| committer | Hsieh Chin Fan <pham@topo.tw> | 2024-09-22 19:12:28 +0800 |
| commit | 99f80919d6a5546425c8b7418c4e874f8c99e69a (patch) | |
| tree | 483d9389e8b3090130a3663f8cd84a07e22e9689 /src | |
| parent | 74bef2d5615db7a5d2ee8f95515bd4fc40249915 (diff) | |
feat: add padding for plus/minus button
Diffstat (limited to 'src')
| -rw-r--r-- | src/Layout.mjs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Layout.mjs b/src/Layout.mjs index 8a9f316..789027b 100644 --- a/src/Layout.mjs +++ b/src/Layout.mjs | |||
| @@ -161,11 +161,11 @@ export class Overlay extends Layout { | |||
| 161 | // Plus/Minus font-size of content | 161 | // Plus/Minus font-size of content |
| 162 | wrapper.querySelector('#plus-font-size').onclick = () => { | 162 | wrapper.querySelector('#plus-font-size').onclick = () => { |
| 163 | const fontSize = parseFloat(getComputedStyle(block).fontSize) / 16 | 163 | const fontSize = parseFloat(getComputedStyle(block).fontSize) / 16 |
| 164 | block.style.fontSize = `${fontSize + 0.1}rem` | 164 | block.style.fontSize = `${fontSize + 0.2}rem` |
| 165 | } | 165 | } |
| 166 | wrapper.querySelector('#minus-font-size').onclick = () => { | 166 | wrapper.querySelector('#minus-font-size').onclick = () => { |
| 167 | const fontSize = parseFloat(getComputedStyle(block).fontSize) / 16 | 167 | const fontSize = parseFloat(getComputedStyle(block).fontSize) / 16 |
| 168 | block.style.fontSize = `${fontSize - 0.1}rem` | 168 | block.style.fontSize = `${fontSize - 0.2}rem` |
| 169 | } | 169 | } |
| 170 | }) | 170 | }) |
| 171 | } | 171 | } |