Sprite copies animation of another sprite

Its kind of a weird issue, I have animated sprite component which plays for animations based on key events, like I am passing which key will play which animation like for one compents its “AWSD” while for another it is “Arrow keys” so two sprites has same four animation but only wjll play on different key events also I am sending img as prop too so I can have different characters as sprite and it works fine in that case when imgs are different only issue is that when I pass the same img to both components they start reacting to the key events of another sprite. I am not sure if I am explaining it properly.

I made a sandbox if you see I have two animated sprite components in canvas both have different key codes for playing animation on different keys event and passing img as prop too. if you use same img for both components they play animation on other’s key event and if you pass another img it works properly (use another img “sss.png” from public)

I am using react three fiber