From 482753e96a31a33c6409de6180e944eddc41c902 Mon Sep 17 00:00:00 2001 From: Tanner Collin Date: Tue, 2 Dec 2025 23:19:12 +0000 Subject: [PATCH] Add a copy button to the article title --- webclient/src/Article.js | 7 ++----- webclient/src/Feed.js | 2 +- webclient/src/Style-light.css | 4 +--- webclient/src/fonts/Fonts.css | 5 +++++ webclient/src/fonts/icomoon2.ttf | Bin 0 -> 1608 bytes 5 files changed, 9 insertions(+), 9 deletions(-) create mode 100644 webclient/src/fonts/icomoon2.ttf diff --git a/webclient/src/Article.js b/webclient/src/Article.js index eec67e5..f66fba2 100644 --- a/webclient/src/Article.js +++ b/webclient/src/Article.js @@ -44,7 +44,7 @@ function Article({ cache }) { }, [id]); const copyLink = () => { - navigator.clipboard.writeText(`${story.title} ${window.location.href}`).then(() => { + navigator.clipboard.writeText(`${story.title}:\n${window.location.href}`).then(() => { setCopyButtonText('\uea10'); setTimeout(() => setCopyButtonText('\ue92c'), 2000); }, () => { @@ -82,10 +82,7 @@ function Article({ cache }) { -
-

{story.title}

- -
+

{story.title}

Source: {sourceLink(story)} diff --git a/webclient/src/Feed.js b/webclient/src/Feed.js index edab84a..d418419 100644 --- a/webclient/src/Feed.js +++ b/webclient/src/Feed.js @@ -101,7 +101,7 @@ function Feed({ updateCache }) { QotNews - {loadingStatus &&

Fetching stories {loadingStatus.current} / {loadingStatus.total}...

} + {loadingStatus &&

Preloading stories {loadingStatus.current} / {loadingStatus.total}...

} {error &&
Connection error? Click to expand. diff --git a/webclient/src/Style-light.css b/webclient/src/Style-light.css index c948504..272bb61 100644 --- a/webclient/src/Style-light.css +++ b/webclient/src/Style-light.css @@ -130,7 +130,6 @@ span.source { .article h1 { font-size: 1.6rem; - margin: 0; } .article h2 { @@ -270,10 +269,9 @@ span.source { } .copy-button { - font: 2rem/1 'icomoon'; + font: 1.5rem/1 'icomoon2'; background: transparent; border: none; cursor: pointer; - padding: 0 0.5rem; vertical-align: middle; } diff --git a/webclient/src/fonts/Fonts.css b/webclient/src/fonts/Fonts.css index 91982fd..95ba5db 100644 --- a/webclient/src/fonts/Fonts.css +++ b/webclient/src/fonts/Fonts.css @@ -26,3 +26,8 @@ font-family: 'Icomoon'; src: url('icomoon.ttf') format('truetype'); } + +@font-face { + font-family: 'Icomoon2'; + src: url('icomoon2.ttf') format('truetype'); +} diff --git a/webclient/src/fonts/icomoon2.ttf b/webclient/src/fonts/icomoon2.ttf new file mode 100644 index 0000000000000000000000000000000000000000..efe7749a266d39cff7e3b27d1cbde2803fcb610c GIT binary patch literal 1608 zcmb7EL2MgE6#ai@y=$j9j^nOdnGn`7b&#NL5;rlGpe&b4m8dFOsDwajw$9>2ioKTO zO34N7DN;`$KnReKdO_lZ;Lc&h%@X3offH0JJtXCddLe7xtk>XHiUhNonfKrSfBxH@ znI$Ho6BLr9rK{J^t>k9SpTT^OzTRwm-NV-p?h)}E>~~w|M<1*7n|e`(OV0 z2kekYY;5}8#@WH0--zVz@ULxxuzrvOB17jtx7qIR76D+p7@X~(=?TI6u-9SFw!Pgh zP16n7eeLgfZGZ4t--7)KYJAiUcKXnXW&$&541oru!UxqglpLb7aIBPf?l#Fq3m|_Hbr+G#tix&cTa^ zx!B_2{o*h7BVpHrq<7NwmEIV54Se|s(g`Czqz~R&_)de-oSY=wYkd;qhMf3* z;DGCfQLi-F(j(7^(rMbB?6GHxPSQNRNnhi$u7J_2q+vrf+PGS5B*Qd)lhk5Fj_V4t zXe;3*_zMX(fZtDW3OC_&f=%#mBzTHS^eGNE8yPS&@Qkp)AE%pO3I4SN8^HSsPT^)% z5^REhJHb=92j6ZrgLV*fR-mj&0kzQs>d?v!zqhj$be!ed5`Jku^=Jnn+U3wP)oAIs z#N+sDe(UzO*Q0A#tVOqJn>^|r7knw`^qrR9@q1q1-*9g2IhUKk73i$drC3BCGFn)v h6HD``k9h;!E!x9)IewQb$-C6B1Mz=%a*H0ve*;Fd5e5JN literal 0 HcmV?d00001