您可以自定义 userChrome.css 中的警告框吗?
Can you customize the alert box in userChrome.css?
我最近发现了 FireFox 的 userChrome.css
,您可以在其中使用 CSS 对所有内容进行裁剪。我尝试使用谷歌搜索如何自定义警报框(当我使用“alert()
”时),但我找不到任何东西。这可能吗?
欢迎来到 Whosebug,正常!根据this answer, Javascript alert boxes are system objects and not modifiable by CSS. However, you should rarely encounter one while using Firefox, and if you're in the process of writing a webextension, it's much better to write your own notification or popup.
我最近发现了 FireFox 的 userChrome.css
,您可以在其中使用 CSS 对所有内容进行裁剪。我尝试使用谷歌搜索如何自定义警报框(当我使用“alert()
”时),但我找不到任何东西。这可能吗?
欢迎来到 Whosebug,正常!根据this answer, Javascript alert boxes are system objects and not modifiable by CSS. However, you should rarely encounter one while using Firefox, and if you're in the process of writing a webextension, it's much better to write your own notification or popup.