Userstyles allows you to inject CSS on the Scratch website - useful to make the buttons you add with userscripts colorful, or to customize native Scratch element.
Wie füge ich ein Userstyle hinzu?
Make sure to refresh Scratch Addons from chrome://extensions
after doing any changes to your addon.
Go to the manifest of your addon (addon.json) and add a property called "userstyles"
.
This property must be an array.
Each item of the array must have the following properties: "url"
and "matches"
.
"url"
must be a relative URL to a CSS file.
"matches"
must be an array of URLs where you want the userstyle to be injected. You can use asterisks.
Example manifest:
{
"name": "Scratch Messaging",
"description": "Provides easy reading and replying to your Scratch messages.",
"userstyles": [
{
"url": "userstyle.css",
"matches": ["https://scratch.mit.edu/*"]
},
{
"url": "second_userstyle.css",
"matches": ["https://scratch.mit.edu/projects/*", "https://scratch.mit.edu/users/*"]
}
],
"tags": ["community"],
"enabledByDefault": false
}
Fehlerbehebung in Userstyles
Du musst beim Ändern deines Addons Scratch Addons in chrome://extensions
neu laden.
Falls dein Userscript nicht funktioniert, stelle sicher, dass dein Addon aktiviert ist.
Wenn du weiterhin Probleme hast, öffne ein neues Issue in diesem Repo.
Kommentare
Befolge die Verhaltensregeln. Du kannst diesen Kommentarabschnitt auf GitHub Discussions anzeigen, sowie deinen Kommentar bearbeiten oder löschen.