parsimonhi / animCJK

Draw animated Japanese characters (Kanji and Kana), Korean characters (Hanja) and Chinese characters (Hanzi) in correct stroke order using svg, free open-source code.
284 stars 72 forks source link

Stroke starts too early in Firefox #3

Closed Connum closed 6 years ago

Connum commented 6 years ago

Hi there,

nice work! I started something similiar some months ago (https://sino.constantinmedia.com/stroke-order/) but didn't get very far - SVG creation was just too tedious and I didn't have the time...

Just wanted to let you know that in Firefox, the strokes start too early, so for every stroke, there is a small red portion where the stroke begins, from the beginning of the animation. This doesn't happen in Chrome, however.

parsimonhi commented 6 years ago

Hello,

Thank you for your report.

I also noticed that bug recently. It seems it was not there using some previous versions of firefox on Windows, but i am not sure of that because i work on MacOS most of the time. The bug is not visible using firefox on MacOS.

For those who want to fix this firefox bug on Windows "as soon as possible, replace for instance in the css of the svg files

from {
    stroke:#c00;
    stroke-dashoffset:3334;
}

by

from {
    stroke:#ccc;
    stroke-dashoffset:3334;
}
5% {
    stroke:#c00;
    stroke-dashoffset:3334;
}
parsimonhi commented 6 years ago

Hello,

I updated all the svgs by replacing:

from { stroke:#c00; stroke-dashoffset:3334; }

by

from { stroke:#ccc; stroke-dashoffset:3334; } 1% { stroke:#c00; stroke-dashoffset:3334; }

Connum commented 6 years ago

That's great, thanks!