diff options
author | bptato <nincsnevem662@gmail.com> | 2024-08-23 16:13:06 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2024-08-23 16:13:06 +0200 |
commit | b7c2c15a9c2503c01bb63e9e9c4c04378192a1dd (patch) | |
tree | fb9a671bb387bd15a6c8cb0efbea20b1a4a526f8 | |
parent | 9708f48d837c132332ff64257a6bc8e38d540147 (diff) | |
download | chawan-b7c2c15a9c2503c01bb63e9e9c4c04378192a1dd.tar.gz |
cssvalues: fix broken vmin, vmax
-rw-r--r-- | src/css/cssvalues.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/css/cssvalues.nim b/src/css/cssvalues.nim index 03118a42..8caa823a 100644 --- a/src/css/cssvalues.nim +++ b/src/css/cssvalues.nim @@ -585,9 +585,9 @@ func px*(l: CSSLength; window: WindowAttributes; p: LayoutUnit): LayoutUnit = of cuVw: toLayoutUnit(float64(window.width_px) * l.num / 100) of cuVh: toLayoutUnit(float64(window.height_px) * l.num / 100) of cuVmin: - toLayoutUnit(min(window.width_px, window.width_px) / 100 * l.num) + toLayoutUnit(min(window.width_px, window.height_px) / 100 * l.num) of cuVmax: - toLayoutUnit(max(window.width_px, window.width_px) / 100 * l.num) + toLayoutUnit(max(window.width_px, window.height_px) / 100 * l.num) func blockify*(display: CSSDisplay): CSSDisplay = case display |