Skip to content

Commit be0749b

Browse files
Ciphroxxkeshav
authored andcommitted
skipped typing animation for braille playground
1 parent b139bc6 commit be0749b

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

src/pages/alphabets/[alphabet]/playground.astro

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,17 @@ const currentCategory = alphabetData[alphabet as keyof AlphabetsData];
6868

6969
document.documentElement.style.setProperty("--steps", info.text.length * 2);
7070

71-
// Animation handling to spelling
72-
spellDiv.classList.remove("animation");
73-
void spellDiv.offsetWidth;
74-
spellDiv.classList.add("animation");
71+
// Animation handling for spelling
72+
if (category !== "braille") {
73+
spellDiv.classList.remove("animation");
74+
void spellDiv.offsetWidth;
75+
spellDiv.classList.add("animation");
76+
spellDiv.style.borderRight = "3px solid";
77+
} else {
78+
// Skip animation for braille
79+
spellDiv.classList.remove("animation");
80+
spellDiv.style.borderRight = "none";
81+
}
7582

7683
if (info.description && info.description.trim() !== "") {
7784
descriptionDiv.innerHTML = info.description;
@@ -80,7 +87,7 @@ const currentCategory = alphabetData[alphabet as keyof AlphabetsData];
8087

8188
// Animation handling for description
8289
descriptionDiv.classList.remove("animation");
83-
void descriptionDiv.offsetWidth;
90+
void descriptionDiv.offsetWidth;
8491
descriptionDiv.classList.add("animation");
8592
} else {
8693
descriptionDiv.classList.remove("animation");

0 commit comments

Comments
 (0)