Automatic theme switching support in favorite colours (#567)

* Automatic theme switching support in favorite colours

* Ref to dark theme

Co-authored-by: Rob Wu <rob@robwu.nl>

---------

Co-authored-by: Rob Wu <rob@robwu.nl>
This commit is contained in:
rebloor
2024-09-09 16:26:27 +12:00
committed by GitHub
parent 141134499a
commit 1d8a18aa1e
2 changed files with 6 additions and 5 deletions

View File

@@ -1,15 +1,15 @@
# Favourite Colour # Favourite Colour
Shows and stores your favourite colour, in storage.sync in the about:addons page for the add-on. Shows and stores your favourite colour, in storage.sync in the extension's about:addons page.
Demonstrates: Demonstrates:
* storing data with storage.sync * storing data with storage.sync
* reading data from storage.managed
* creating an options page and opening it with `runtime.openOptionsPage()`
* best practice for supporting automatic theme switching (dark theme) in the options page
* reading data from storage.managed, To have Firefox read data from storage.managed, create a file with this content:
* creating an options page and opening it with `runtime.openOptionsPage()`.
To have Firefox read data from storage.managed, create a file with the following contents:
{ {
"name": "favourite-colour-examples@mozilla.org", "name": "favourite-colour-examples@mozilla.org",

View File

@@ -3,6 +3,7 @@
<html> <html>
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="color-scheme" content="dark light">
</head> </head>
<body> <body>