Skip to content

Commit

Permalink
Tweak confetti animation
Browse files Browse the repository at this point in the history
dhelonious committed Jan 4, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent 9b3b1c3 commit b3c32a2
Showing 4 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion RELEASE.md
Original file line number Diff line number Diff line change
@@ -14,7 +14,8 @@ This release also includes:

## Changelog for 4.3.2snap6:

* Improve confetti animation
* Hotfix for `media.dir` setting being empty on install
* Add spinning to confetti animation
* Hotfix for `mastodon-server.get-certificate` `acme.server` check [4.3.2snap4]
* It's your Fediday: The day you joined the Fediverse will be celebrated by your instance with a confetti rain! 🎊 [4.3.2snap4]
* Support [BuyPass](https://buypass.com) SSL CA [4.3.2snap4]
2 changes: 1 addition & 1 deletion src/mastodon/addons/effects.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Based on snow addon by Roni Laukkarinen
// https://github.com/ronilaukkarinen/mastodon/commit/9bf1563
export function topEffect(animate, height='70px', fadeLength='30px', maxParticlesSmall=25, maxParticlesLarge=50) {
export function topEffect(animate, height='80px', fadeLength='30px', maxParticlesSmall=25, maxParticlesLarge=50) {
const wrapper = document.createElement('div');
wrapper.classList.add('particles');
wrapper.style.position = 'fixed';
2 changes: 1 addition & 1 deletion src/mastodon/addons/fediday.js
Original file line number Diff line number Diff line change
@@ -66,6 +66,6 @@ document.addEventListener('DOMContentLoaded', () => {
// Set property for other addons to check
window.fediday = true;

topEffect(animateConfetti);
topEffect(animateConfetti, maxParticlesSmall=35, maxParticlesLarge=70);
}
});
2 changes: 1 addition & 1 deletion src/mastodon/addons/snow.js
Original file line number Diff line number Diff line change
@@ -57,6 +57,6 @@ document.addEventListener('DOMContentLoaded', () => {
}

if (new Date().getMonth() === 11 && new Date().getDate() >= 23 && new Date().getDate() <= 31) {
topEffect(animateSnow, height='80px', fadeLength=`40px`);
topEffect(animateSnow, fadeLength=`40px`);
}
});

0 comments on commit b3c32a2

Please sign in to comment.