Composant thème de neige d'hiver ❄

This theme component adds some animated snow to your forum.

:christmas_tree: Warning: the animations will increase browser CPU usage :santa:

:eye: Demo

:link: Repository

Javascript mode (shared by @cjk77 here):

CSS Mode (adapted from here)

37 « J'aime »

Thanks - now with snow :smiley:

Installation:

Go to: /admin/customize/themes
Choose Compontes - add Install.
Paste in the link: https://github.com/davidtaylorhq/discourse-snow-theme.git
Go back to admin/customize/themes and find your theme.
Click it and you can customize your theme.
Scroll down
Add the new component to your theme.

And your have :snowflake:

10 « J'aime »

I’ve got a couple of users using Firefox and Opera where this isn’t working (configured with js-mode), but the codepen example of the code does work. Works fine in Chrome. Any ideas?

ETA: Both users have confirmed that css mode works for them

1 « J'aime »

It seems to be a Chrome-only component. On Firefox, with JS-mode, there’s nothing, and with CSS mode there’s a wall of jerky snow flakes that covers the screen, so it’s not really usable.

3 « J'aime »

It is now updated so that js-mode works for Firefox. I haven’t tested Opera, but I suspect the same fix will help there as well.

14 « J'aime »

Can confirm it’s now working for both of my users, Firefox and Opera. Thanks for the fix.

5 « J'aime »

I use Opera,

looked great but as David noted

image

image
the CPU is too much,

1% without up to 39% with,

Sadly had to go :pensive:

6 « J'aime »

is there a way to make this have random fireworks instead of snow?

and my CPU never increased with the snow, used it on desktops and phones, my entire forum loved it, and not one complaint about CPU usage

10 « J'aime »

Hi! I love this, it’s adorable and really brings things to life. I’m wondering, however, if it’s possible to make it appear only to the right and left/in the unused space beside the board (or go behind it)? That way it doesn’t snow all over the text and make reading difficult.

4 « J'aime »

Seems to work fine with the latest discourse release…

2 « J'aime »

J’aime beaucoup ce composant de thème, mais y a-t-il un moyen de changer le « point » (ou devrais-je dire « point » ?) en une vraie icône de flocon de neige ?

1 « J'aime »

Y a-t-il un moyen de ralentir la neige pour qu’elle soit moins distrayante ? Une sorte de neige paresseuse ? Ou un moyen pour les utilisateurs de désactiver la neige eux-mêmes afin que certains puissent en profiter pendant que d’autres, pour qui elle cause des problèmes, puissent la désactiver ?

1 « J'aime »

Utilisez-vous la version CSS ou JS ?

passé de JS à CSS ! Mais nous pouvons essayer l’un ou l’autre, celui qui est le plus facile. @famousamos.1 pour information

3 « J'aime »

@dennisjbr s’en occupe pour moi - j’aurais dû le lui demander d’abord, mais ma liste de choses à faire est immense. Il nous aide avec notre site.

3 « J'aime »

La version CSS est plus facile à modifier, mais ce n’est pas le même effet. :thinking:

Si la version CSS vous convient et que vous souhaitez ralentir la chute, ajoutez ce CSS à votre thème ou à un nouveau composant de thème et ajustez la valeur selon vos besoins. Plus la valeur est élevée, plus la chute est lente.

#snow {
    animation: snow 60s linear infinite;
}
6 « J'aime »

Merci beaucoup

3 « J'aime »