Asjust size and spacing of external link SVG icon

This commit is contained in:
Helen Chong 2024-07-16 20:55:22 +08:00
parent 10ad4bf6c8
commit 4ce2b1d988
3 changed files with 6 additions and 6 deletions

View File

@ -87,7 +87,7 @@
outline-offset: -0.25em; outline-offset: -0.25em;
} }
a.link-btn[href^="http"]:not([href*="leilukin.com"]) { padding-right: calc(var(--btn-right-padding) + var(--sz-link-padding)); } a.link-btn[href^="http"]:not([href*="leilukin.com"]) { padding-right: calc(var(--btn-right-padding) + var(--sz-external-link)); }
/* Content Accordion */ /* Content Accordion */
* + .content-accordion { margin-top: var(--sz-paragraph-margin); } * + .content-accordion { margin-top: var(--sz-paragraph-margin); }

View File

@ -52,7 +52,7 @@ a:not([class]):focus { outline: 0.15rem solid var(--clr-link); }
a:hover img, a:focus img { outline: 0.2em solid var(--clr-body-txt); } a:hover img, a:focus img { outline: 0.2em solid var(--clr-body-txt); }
a[href^="http"]:not([href*="leilukin.com"]):not(:has(img, svg, picture)), a[href^="http"]:not([href*="leilukin.com"]):not(:has(img, svg, picture)),
.external-link { padding-right: var(--sz-link-padding); } .external-link { padding-right: var(--sz-external-link); }
a[href^="http"]:not([href*="leilukin.com"]):not(:has(img, svg, picture))::after, a[href^="http"]:not([href*="leilukin.com"]):not(:has(img, svg, picture))::after,
.external-link::after { .external-link::after {
@ -61,12 +61,12 @@ a[href^="http"]:not([href*="leilukin.com"]):not(:has(img, svg, picture))::after,
display: inline-block; display: inline-block;
width: 1em; width: 1em;
height: 1em; height: 1em;
margin-left: 0.3em; margin: 0 0.3em;
background-color: currentColor; background-color: currentColor;
mask-size: 100%;
mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'%3E%3C!--!Font Awesome Free 6.5.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2024 Fonticons, Inc.--%3E%3Cpath d='M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32h82.7L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3V192c0 17.7 14.3 32 32 32s32-14.3 32-32V32c0-17.7-14.3-32-32-32H320zM80 32C35.8 32 0 67.8 0 112V432c0 44.2 35.8 80 80 80H400c44.2 0 80-35.8 80-80V320c0-17.7-14.3-32-32-32s-32 14.3-32 32V432c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16V112c0-8.8 7.2-16 16-16H192c17.7 0 32-14.3 32-32s-14.3-32-32-32H80z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'%3E%3C!--!Font Awesome Free 6.5.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2024 Fonticons, Inc.--%3E%3Cpath d='M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32h82.7L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3V192c0 17.7 14.3 32 32 32s32-14.3 32-32V32c0-17.7-14.3-32-32-32H320zM80 32C35.8 32 0 67.8 0 112V432c0 44.2 35.8 80 80 80H400c44.2 0 80-35.8 80-80V320c0-17.7-14.3-32-32-32s-32 14.3-32 32V432c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16V112c0-8.8 7.2-16 16-16H192c17.7 0 32-14.3 32-32s-14.3-32-32-32H80z'/%3E%3C/svg%3E");
mask-repeat: no-repeat; mask-repeat: no-repeat;
transform: translateY(0.25em); mask-size: 90%;
transform: translateY(0.35em);
} }
:not(.c-blockquote) > blockquote, :not(.c-blockquote) > blockquote,

View File

@ -47,7 +47,7 @@
--sz-paragraph-margin: 1.15em; --sz-paragraph-margin: 1.15em;
--sz-main-padding: clamp(1rem, 5%, 4rem); --sz-main-padding: clamp(1rem, 5%, 4rem);
--sz-navbar-ht: 4rem; --sz-navbar-ht: 4rem;
--sz-link-padding: 1.5em; --sz-external-link: 1.4em;
} }
/* ------------------- */ /* ------------------- */