Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: add spinner component#16014

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
BrunoQuaresma merged 10 commits intomainfrombq/add-spinner-component
Jan 2, 2025
Merged
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Avoid animation on Chromatic
  • Loading branch information
@BrunoQuaresma
BrunoQuaresma committedJan 2, 2025
commit5353da2ab5d260859c7c0d4438ba016d419e9f46
5 changes: 4 additions & 1 deletionsite/src/components/Spinner/Spinner.tsx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -4,6 +4,7 @@
* https://v0.dev/ help.
*/

import isChromatic from "chromatic/*";
import { cva, type VariantProps } from "class-variance-authority";
import type { ReactNode } from "react";
import { cn } from "utils/cn";
Expand DownExpand Up@@ -61,7 +62,9 @@ export function Spinner({
height="4"
rx="0.5"
// 0.8 = leaves * 0.1
className="animate-[loading_0.8s_ease-in-out_infinite]"
className={
isChromatic() ? "" : "animate-[loading_0.8s_ease-in-out_infinite]"
}
style={{
transform: `rotate(${rotation}deg)`,
transformOrigin: "center",
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp