Add social links to download page
This commit is contained in:
@@ -17,20 +17,16 @@ onMount(() => {
|
||||
return
|
||||
}
|
||||
|
||||
// 10% pixeldrain socials
|
||||
// 90% patreon
|
||||
|
||||
// 30% pixeldrain socials
|
||||
// 20% reviews
|
||||
// 50% patreon
|
||||
|
||||
let rand = Math.random()
|
||||
if (rand < 0.1) {
|
||||
set_ad_type("twitter")
|
||||
} else if (rand < 0.2) {
|
||||
set_ad_type("mastodon")
|
||||
} else if (rand < 0.3) {
|
||||
set_ad_type("reddit")
|
||||
} else if (rand < 0.4) {
|
||||
set_ad_type("reviews")
|
||||
if (rand < 0.3) {
|
||||
set_ad_type("socials")
|
||||
} else if (rand < 0.5) {
|
||||
set_ad_type("lemmy")
|
||||
set_ad_type("reviews")
|
||||
} else {
|
||||
set_ad_type("patreon_support")
|
||||
}
|
||||
@@ -202,6 +198,39 @@ head.valueimpression_loaded.subscribe(v => {
|
||||
</a>
|
||||
</div>
|
||||
|
||||
{:else if ad_type === "socials"}
|
||||
<div class="banner center">
|
||||
<div class="socials">
|
||||
Pixeldrain is on the fediverse!<br/>
|
||||
|
||||
<a href="https://mastodon.social/@fornax" rel="noreferrer" class="button" target="_blank" style="background-color: #595aff; color: #ffffff;">
|
||||
<i class="icon small">people</i>
|
||||
Mastodon
|
||||
</a>
|
||||
<a href="https://lemmy.fornaxian.tech/c/pixeldrain"
|
||||
rel="noreferrer" class="button" target="_blank" style="background-color: #14854f; color: #ffffff;"
|
||||
>
|
||||
<i class="icon small">people</i>
|
||||
Lemmy
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="socials">
|
||||
And on legacy media too<br/>
|
||||
|
||||
<a href="https://twitter.com/Fornax96" rel="noreferrer" class="button" target="_blank" style="background-color: #1a8cd8; color: #ffffff;">
|
||||
<i class="icon small">people</i>
|
||||
Twitter
|
||||
</a>
|
||||
<a href="https://www.reddit.com/r/PixelDrain"
|
||||
rel="noreferrer" class="button" target="_blank" style="background-color: #ff4500; color: #ffffff;"
|
||||
>
|
||||
<i class="icon small">people</i>
|
||||
Reddit
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{:else if ad_type === "reviews"}
|
||||
|
||||
<div class="banner support_banner">
|
||||
@@ -230,25 +259,32 @@ head.valueimpression_loaded.subscribe(v => {
|
||||
display: block;
|
||||
margin: auto;
|
||||
transform-origin: 0 0;
|
||||
font-size: 1.2em;
|
||||
}
|
||||
.center {
|
||||
text-align: center;
|
||||
}
|
||||
.support_banner {
|
||||
font-size: 1.2em;
|
||||
text-align: center;
|
||||
padding: 2px;
|
||||
}
|
||||
.social_button {
|
||||
font-size: 1.4em;
|
||||
text-align: center;
|
||||
padding: 4px;
|
||||
}
|
||||
.socials {
|
||||
display: inline-block;
|
||||
text-align: center;
|
||||
margin: 0 5px;
|
||||
}
|
||||
|
||||
/* Vertical estate is sparse on some devices*/
|
||||
@media(max-height: 600px) {
|
||||
.support_banner {
|
||||
/* Try to avoid text wrapping */
|
||||
@media(max-width: 600px) {
|
||||
.banner {
|
||||
font-size: 1em;
|
||||
}
|
||||
.social_button {
|
||||
font-size: 1.2em;
|
||||
.socials {
|
||||
font-size: 0.8em;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
79
svelte/src/icons/Lemmy.svelte
Normal file
79
svelte/src/icons/Lemmy.svelte
Normal file
@@ -0,0 +1,79 @@
|
||||
<script>export let style;</script>
|
||||
|
||||
<svg
|
||||
style={style}
|
||||
width="24"
|
||||
height="24"
|
||||
viewBox="0 0 1024 1024"
|
||||
version="1.1"
|
||||
id="svg8"
|
||||
enable-background="new"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/">
|
||||
<g
|
||||
inkscape:label="Layer 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(0,-26.066658)"
|
||||
style="display:inline">
|
||||
<path
|
||||
fill="currentColor"
|
||||
stroke="currentColor"
|
||||
id="path1087"
|
||||
style="display:inline;opacity:1;fill:none;fill-opacity:1;stroke-width:28;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 716.85595,362.96478 c 15.29075,-21.36763 35.36198,-41.10921 56.50979,-53.31749 66.66377,-38.48393 137.02617,-33.22172 170.08018,22.43043 33.09493,55.72093 14.98656,117.48866 -47.64399,159.85496 -31.95554,19.26819 -62.93318,30.92309 -97.22892,35.54473 M 307.14407,362.96478 C 291.85332,341.59715 271.78209,321.85557 250.63429,309.64729 183.97051,271.16336 113.60811,276.42557 80.554051,332.07772 47.459131,387.79865 65.56752,449.56638 128.19809,491.93268 c 31.95554,19.26819 62.93319,30.92309 97.22893,35.54473"
|
||||
inkscape:connector-curvature="0"
|
||||
inkscape:label="ears"
|
||||
sodipodi:insensitive="true" />
|
||||
<path
|
||||
fill="currentColor"
|
||||
stroke="currentColor"
|
||||
style="display:inline;opacity:1;fill:none;fill-opacity:1;stroke-width:28;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="M 801.23205,576.8699 C 812.73478,427.06971 720.58431,321.98291 511.99999,325.38859 303.41568,328.79426 213.71393,428.0311 222.76794,576.8699 c 8.64289,142.08048 176.80223,246.40388 288.12038,246.40388 111.31815,0 279.45076,-104.5447 290.34373,-246.40388 z"
|
||||
id="path969"
|
||||
inkscape:connector-curvature="0"
|
||||
sodipodi:nodetypes="szszs"
|
||||
inkscape:label="head"
|
||||
sodipodi:insensitive="true" />
|
||||
<path
|
||||
fill="currentColor"
|
||||
id="path1084"
|
||||
style="display:inline;opacity:1;fill-opacity:1;stroke-width:0;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 610.4991,644.28932 c 0,23.11198 18.70595,41.84795 41.78091,41.84795 23.07495,0 41.7809,-18.73597 41.7809,-41.84795 0,-23.112 -18.70594,-41.84796 -41.7809,-41.84796 -23.07496,0 -41.78091,18.73596 -41.78091,41.84796 z m -280.56002,0 c 0,23.32492 18.87829,42.23352 42.16586,42.23352 23.28755,0 42.16585,-18.9086 42.16585,-42.23352 0,-23.32494 -18.87829,-42.23353 -42.16585,-42.23353 -23.28757,0 -42.16586,18.90859 -42.16586,42.23353 z"
|
||||
inkscape:connector-curvature="0"
|
||||
inkscape:label="eyes"
|
||||
sodipodi:nodetypes="ssssssssss"
|
||||
sodipodi:insensitive="true" />
|
||||
<path
|
||||
fill="currentColor"
|
||||
id="path1008"
|
||||
style="display:inline;opacity:1;fill:none;stroke-width:32;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
||||
d="m 339.72919,769.2467 -54.54422,72.22481 m 399.08582,-72.22481 54.54423,72.22481 M 263.68341,697.82002 175.92752,733.64353 m 579.85765,-35.82351 87.7559,35.82351"
|
||||
inkscape:connector-curvature="0"
|
||||
inkscape:label="whiskers"
|
||||
sodipodi:nodetypes="cccccccc"
|
||||
sodipodi:insensitive="true" />
|
||||
<path
|
||||
fill="currentColor"
|
||||
style="display:inline;opacity:1;fill-opacity:1;stroke-width:28;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;fill-rule:nonzero"
|
||||
d="m 512.00082,713.08977 c -45.86417,0 -75.13006,31.84485 -74.14159,71.10084 1.07048,42.51275 32.46865,71.10323 74.14159,71.10323 41.67296,0 74.05118,-32.99608 74.14161,-71.10323 0.0932,-39.26839 -28.27742,-71.10084 -74.14161,-71.10084 z"
|
||||
id="path1115"
|
||||
inkscape:connector-curvature="0"
|
||||
inkscape:label="nose"
|
||||
sodipodi:nodetypes="zszsz"
|
||||
sodipodi:insensitive="true" />
|
||||
</g>
|
||||
</svg>
|
||||
|
||||
<style>
|
||||
svg, path {
|
||||
fill: currentColor;
|
||||
border: currentColor;
|
||||
stroke: currentColor;
|
||||
}
|
||||
</style>
|
Reference in New Issue
Block a user