-
Notifications
You must be signed in to change notification settings - Fork 0
refactor: migrate styling from scss to vanilla-extract #68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
46f9857
b1d784f
c7c98d8
7ba4537
776ac60
a9fdf8f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,87 @@ | ||||||||||||||||||||||||||||||||||||||
| import { keyframes } from '@vanilla-extract/css'; | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const fadeIn = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { opacity: 'var(--fade-from, 0)' }, | ||||||||||||||||||||||||||||||||||||||
| to: { opacity: 'var(--fade-to, 1)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const fadeOut = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { opacity: 'var(--fade-from, 1)' }, | ||||||||||||||||||||||||||||||||||||||
| to: { opacity: 'var(--fade-to, 0)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const slideUp = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'translateY(var(--slide-distance, 0.4rem))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'translateY(0)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const slideDown = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'translateY(var(--slide-distance, -0.4rem))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'translateY(0)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const slideRight = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'translateX(var(--slide-distance, -0.4rem))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'translateX(0)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const slideLeft = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'translateX(var(--slide-distance, 0.4rem))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'translateX(0)' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const scaleIn = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'scale(var(--scale-from, 0.9))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'scale(var(--scale-to, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const scaleOut = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'scale(var(--scale-from, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'scale(var(--scale-to, 0.9))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const rotateClockwise = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'var(--rotate-from, rotate(0deg))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'var(--rotate-to, rotate(360deg))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const rotateCounterclockwise = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'var(--rotate-from, rotate(360deg))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'var(--rotate-to, rotate(0deg))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const bounceIn = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| '0%': { transform: 'scale(var(--bounce-from, 0.5))' }, | ||||||||||||||||||||||||||||||||||||||
| '50%': { transform: 'scale(var(--bounce-mid, 1.05))' }, | ||||||||||||||||||||||||||||||||||||||
| '100%': { transform: 'scale(var(--bounce-to, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const bounceOut = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| '0%': { transform: 'scale(var(--bounce-from, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| '50%': { transform: 'scale(var(--bounce-mid, 1.05))' }, | ||||||||||||||||||||||||||||||||||||||
| '100%': { transform: 'scale(var(--bounce-to, 0.5))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const elasticIn = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| '0%': { transform: 'scaleX(var(--elastic-from, 0))' }, | ||||||||||||||||||||||||||||||||||||||
| '60%': { transform: 'scaleX(var(--elastic-mid1, 1.2))' }, | ||||||||||||||||||||||||||||||||||||||
| '80%': { transform: 'scaleX(var(--elastic-mid2, 0.9))' }, | ||||||||||||||||||||||||||||||||||||||
| '100%': { transform: 'scaleX(var(--elastic-to, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const elasticOut = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| '0%': { transform: 'scaleX(var(--elastic-from, 1))' }, | ||||||||||||||||||||||||||||||||||||||
| '20%': { transform: 'scaleX(var(--elastic-mid1, 0.9))' }, | ||||||||||||||||||||||||||||||||||||||
| '40%': { transform: 'scaleX(var(--elastic-mid2, 1.2))' }, | ||||||||||||||||||||||||||||||||||||||
| '100%': { transform: 'scaleX(var(--elastic-to, 0))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const flipIn = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'perspective(40rem) rotateY(var(--flip-from, 90deg))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'perspective(40rem) rotateY(var(--flip-to, 0deg))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||
| export const flipOut = keyframes({ | ||||||||||||||||||||||||||||||||||||||
| from: { transform: 'perspective(40rem) rotateY(var(--flip-from, 0deg))' }, | ||||||||||||||||||||||||||||||||||||||
| to: { transform: 'perspective(40rem) rotateY(var(--flip-to, 90deg))' }, | ||||||||||||||||||||||||||||||||||||||
| }); | ||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+79
to
+87
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perspective value uses unusual unit and may be too large. The flip animations use
🎨 Proposed fix to use standard units and add customization export const flipIn = keyframes({
- from: { transform: 'perspective(40rem) rotateY(var(--flip-from, 90deg))' },
- to: { transform: 'perspective(40rem) rotateY(var(--flip-to, 0deg))' },
+ from: { transform: 'perspective(var(--flip-perspective, 400px)) rotateY(var(--flip-from, 90deg))' },
+ to: { transform: 'perspective(var(--flip-perspective, 400px)) rotateY(var(--flip-to, 0deg))' },
});
export const flipOut = keyframes({
- from: { transform: 'perspective(40rem) rotateY(var(--flip-from, 0deg))' },
- to: { transform: 'perspective(40rem) rotateY(var(--flip-to, 90deg))' },
+ from: { transform: 'perspective(var(--flip-perspective, 400px)) rotateY(var(--flip-from, 0deg))' },
+ to: { transform: 'perspective(var(--flip-perspective, 400px)) rotateY(var(--flip-to, 90deg))' },
});📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🌐 Web query:
@vanilla-extract/css latest stable version 2025 2026 npm💡 Result:
Latest stable @vanilla-extract/css on npm: 1.17.4. Install: npm i @vanilla-extract/css. [1]
Sources
[1] npm package page for @vanilla-extract/css.
🌐 Web query:
@vanilla-extract/jest-transform latest stable version 2025 2026 npm💡 Result:
Latest stable on the npm registry: @vanilla-extract/jest-transform v1.1.17 (published June 12, 2025). [1][2]
Sources:
🌐 Web query:
@vanilla-extract/rollup-plugin latest stable version 2025 2026 npm💡 Result:
As of Jan 9, 2026: the upstream releases page shows @vanilla-extract/rollup-plugin v1.4.2 (released Nov 14, 2025), while the npm registry page currently lists v1.4.1 as the published package. [1][2]
Sources:
🌐 Web query:
vanilla-extract security vulnerabilities CVE 2025 2026💡 Result:
Short answer: There are no CVEs specifically assigned to the vanilla-extract project (packages like @vanilla-extract/css, /vite-plugin, /webpack-plugin, /esbuild-plugin) in 2025–2026 that I can find. However, there was a related npm supply‑chain incident: the unrelated package docusaurus-plugin-vanilla-extract was reported as malicious following an npm account takeover (advisory dated November 24, 2025). Security scanners (Snyk / ReversingLabs) report no known security issues for the official vanilla-extract packages. [1][2][3]
Sources:
If you want, I can (a) search NVD/CVE databases for any newly published CVEs right now, or (b) list recommended mitigation steps (dependency scanning, lockfile pinning, rotate credentials) for supply‑chain incidents.
Update Vanilla Extract package versions—specified versions do not exist in npm registry.
The package.json references versions that have not been released:
These will cause
npm installto fail. Update to available versions: 1.17.4, 1.1.17, and 1.4.2 respectively. No security vulnerabilities were found in the official vanilla-extract packages.🤖 Prompt for AI Agents