I use Tampermonkey to write a JS script in a website.
It should be on the right of the website’s page like this.
And it’s correct in one path of the website. But when I use the same script on another path of the website. It has a wrong style like this.
The elements added by my script is
I’ve tried to put it in Shadow DOM. But it doesn’t work.
My tampermonkey script just contain createElement
and some style
, so I may not show it.
Can anyone help me with this problem please?
Expecting the problem could be solved.