mirror of
https://github.com/tiennm99/iammiti99.git
synced 2026-10-11 12:18:59 +00:00
fix(css): size brand icons to 20x20 (Simple Icons SVGs lack width/height)
Simple Icons ships SVGs with viewBox only — no explicit width/height —
so inline SVG rendered at 0x0 inside the link button flex container.
Add `.link__icon svg { width:20px; height:20px; fill:currentColor }` to
size all icons consistently. Lucide stroke-only icons opt out of the
fill via attribute selector.
This commit is contained in:
1 parent
a67bdc5790
commit
37ed198b2a
4 files changed
+58
No files matched your search
Binary file not shown.
|
After Width: | Height: | Size: 47 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 38 KiB |
Executable
+45
@@ -0,0 +1,45 @@
|
||||
#!/usr/bin/env bash
|
||||
# Capture submission assets (images/screenshot.png + images/tn.png) from
|
||||
# the live demo. Run from repo root. Re-runnable; overwrites existing files.
|
||||
#
|
||||
# Requires: npx (installs Playwright on first run, ~170 MB chromium cache)
|
||||
# Optional: oxipng (lossless PNG compression — recommended)
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
URL="${BONSAI_DEMO_URL:-https://tiennm99.github.io/bonsai/}"
|
||||
SCREENSHOT="images/screenshot.png"
|
||||
THUMBNAIL="images/tn.png"
|
||||
|
||||
cd "$(dirname "$0")/.."
|
||||
|
||||
mkdir -p images
|
||||
|
||||
echo "==> Installing Playwright Chromium (cached after first run)"
|
||||
npx --yes playwright@1.50.0 install chromium
|
||||
|
||||
echo "==> Capturing screenshot.png (1500x1000)"
|
||||
npx --yes playwright@1.50.0 screenshot \
|
||||
--viewport-size=1500,1000 \
|
||||
--browser=chromium \
|
||||
--color-scheme=light \
|
||||
--wait-for-timeout=800 \
|
||||
"$URL" "$SCREENSHOT"
|
||||
|
||||
echo "==> Capturing tn.png (900x600)"
|
||||
npx --yes playwright@1.50.0 screenshot \
|
||||
--viewport-size=900,600 \
|
||||
--browser=chromium \
|
||||
--color-scheme=light \
|
||||
--wait-for-timeout=800 \
|
||||
"$URL" "$THUMBNAIL"
|
||||
|
||||
if command -v oxipng >/dev/null 2>&1; then
|
||||
echo "==> Compressing with oxipng"
|
||||
oxipng -o4 --strip safe "$SCREENSHOT" "$THUMBNAIL"
|
||||
else
|
||||
echo "==> oxipng not installed; skipping compression (install for smaller files)"
|
||||
fi
|
||||
|
||||
echo "==> Done"
|
||||
file "$SCREENSHOT" "$THUMBNAIL"
|
||||
@@ -148,6 +148,19 @@ body {
|
||||
color: var(--bonsai-accent);
|
||||
}
|
||||
|
||||
.link__icon svg {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
display: block;
|
||||
fill: currentColor;
|
||||
}
|
||||
|
||||
/* Lucide UI icons use stroke, not fill */
|
||||
.link__icon svg[stroke="currentColor"],
|
||||
.link__icon svg.lucide {
|
||||
fill: none;
|
||||
}
|
||||
|
||||
.link__title { line-height: 1; }
|
||||
|
||||
.bonsai-footer {
|
||||
|
||||
Reference in new issue
Block a user