webplugin settings defaults
This commit is contained in:
@@ -71,7 +71,7 @@ Open these URLs:
|
|||||||
- Health check: <http://localhost:8000/health>
|
- Health check: <http://localhost:8000/health>
|
||||||
- OpenAPI documentation: <http://localhost:8000/docs>
|
- OpenAPI documentation: <http://localhost:8000/docs>
|
||||||
|
|
||||||
The browser extension defaults to `http://localhost:8000`.
|
The browser extension requires a backend URL to be entered during setup; it does not assume a default server.
|
||||||
|
|
||||||
The supplied `Logo.svg` is bundled as `frontend/static/logo.svg` for web pages and `webextension/logo.svg` for the Firefox popup and settings page.
|
The supplied `Logo.svg` is bundled as `frontend/static/logo.svg` for web pages and `webextension/logo.svg` for the Firefox popup and settings page.
|
||||||
The visible LinkLog brand text uses the Google Foundry `Asset` font when available, with local fallbacks in the Firefox extension.
|
The visible LinkLog brand text uses the Google Foundry `Asset` font when available, with local fallbacks in the Firefox extension.
|
||||||
@@ -140,7 +140,7 @@ The manifest includes stable Firefox extension metadata and references the packa
|
|||||||
3. Select **Load Temporary Add-on**.
|
3. Select **Load Temporary Add-on**.
|
||||||
4. Choose `webextension/manifest.json`.
|
4. Choose `webextension/manifest.json`.
|
||||||
5. Open the LinkLog extension options and enter:
|
5. Open the LinkLog extension options and enter:
|
||||||
- Backend URL: `http://localhost:8000`
|
- Backend URL: the URL of your LinkLog server, such as `http://localhost:8000`
|
||||||
- Username: `alice`
|
- Username: `alice`
|
||||||
- Password: `secret123`
|
- Password: `secret123`
|
||||||
6. Save the settings and login.
|
6. Save the settings and login.
|
||||||
|
|||||||
@@ -818,3 +818,15 @@ When the user is not logged in, the plugin should display no form fields and war
|
|||||||
|
|
||||||
### Assistant outcome
|
### Assistant outcome
|
||||||
The Firefox popup now hides capture fields by default for signed-out users, shows a localized sign-in warning, and provides an Open settings action. The form appears only after backend credentials and a valid session are available; expired sessions return to the warning state.
|
The Firefox popup now hides capture fields by default for signed-out users, shows a localized sign-in warning, and provides an Open settings action. The form appears only after backend credentials and a valid session are available; expired sessions return to the warning state.
|
||||||
|
|
||||||
|
### User
|
||||||
|
Remove `DEFAULT_BACKEND` setting in the plugin.
|
||||||
|
|
||||||
|
### Assistant outcome
|
||||||
|
Removed the hard-coded backend URL fallback from the Firefox extension. The backend URL is now empty until the user enters it, and the README setup instructions reflect that no default server is assumed.
|
||||||
|
|
||||||
|
### User
|
||||||
|
Change the title of the field “One-time password” to “One-time password (when configured)”.
|
||||||
|
|
||||||
|
### Assistant outcome
|
||||||
|
Updated the OTP field label in the English, Spanish, German, French, and Dutch extension locale catalogs to clarify that the code is needed only when OTP is configured.
|
||||||
|
|||||||
@@ -145,6 +145,8 @@
|
|||||||
136. When a log entry is deleted then all mastodon posts are deleted too.
|
136. When a log entry is deleted then all mastodon posts are deleted too.
|
||||||
137. Don't forget to update the plugin to work with OTP.
|
137. Don't forget to update the plugin to work with OTP.
|
||||||
138. When the user is not logged in then the plugin should just display no form fields but warn the user that they have to log in with a link to settings.
|
138. When the user is not logged in then the plugin should just display no form fields but warn the user that they have to log in with a link to settings.
|
||||||
|
139. Remove DEFAULT_BACKEND setting in the plugin.
|
||||||
|
140. Change the title of the field "One-time password" to "One-time password (when configured)".
|
||||||
|
|
||||||
## Future entries
|
## Future entries
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
@@ -18,7 +18,7 @@
|
|||||||
"usernameLabel": {"message": "Benutzername"},
|
"usernameLabel": {"message": "Benutzername"},
|
||||||
"usernamePlaceholder": {"message": "alice"},
|
"usernamePlaceholder": {"message": "alice"},
|
||||||
"passwordLabel": {"message": "Passwort"},
|
"passwordLabel": {"message": "Passwort"},
|
||||||
"otpLabel": {"message": "Einmalpasswort"},
|
"otpLabel": {"message": "Einmalpasswort (falls konfiguriert)"},
|
||||||
"otpPlaceholder": {"message": "123456"},
|
"otpPlaceholder": {"message": "123456"},
|
||||||
"saveAndLogIn": {"message": "Speichern und anmelden"},
|
"saveAndLogIn": {"message": "Speichern und anmelden"},
|
||||||
"thisPlugin": {"message": "Dieses Add-on"},
|
"thisPlugin": {"message": "Dieses Add-on"},
|
||||||
|
|||||||
@@ -57,7 +57,7 @@
|
|||||||
"message": "Password"
|
"message": "Password"
|
||||||
},
|
},
|
||||||
"otpLabel": {
|
"otpLabel": {
|
||||||
"message": "One-time password"
|
"message": "One-time password (when configured)"
|
||||||
},
|
},
|
||||||
"otpPlaceholder": {
|
"otpPlaceholder": {
|
||||||
"message": "123456"
|
"message": "123456"
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
"usernameLabel": {"message": "Nombre de usuario"},
|
"usernameLabel": {"message": "Nombre de usuario"},
|
||||||
"usernamePlaceholder": {"message": "alice"},
|
"usernamePlaceholder": {"message": "alice"},
|
||||||
"passwordLabel": {"message": "Contraseña"},
|
"passwordLabel": {"message": "Contraseña"},
|
||||||
"otpLabel": {"message": "Contraseña de un solo uso"},
|
"otpLabel": {"message": "Contraseña de un solo uso (cuando está configurada)"},
|
||||||
"otpPlaceholder": {"message": "123456"},
|
"otpPlaceholder": {"message": "123456"},
|
||||||
"saveAndLogIn": {"message": "Guardar e iniciar sesión"},
|
"saveAndLogIn": {"message": "Guardar e iniciar sesión"},
|
||||||
"thisPlugin": {"message": "Este complemento"},
|
"thisPlugin": {"message": "Este complemento"},
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
"usernameLabel": {"message": "Nom d’utilisateur"},
|
"usernameLabel": {"message": "Nom d’utilisateur"},
|
||||||
"usernamePlaceholder": {"message": "alice"},
|
"usernamePlaceholder": {"message": "alice"},
|
||||||
"passwordLabel": {"message": "Mot de passe"},
|
"passwordLabel": {"message": "Mot de passe"},
|
||||||
"otpLabel": {"message": "Mot de passe à usage unique"},
|
"otpLabel": {"message": "Mot de passe à usage unique (si configuré)"},
|
||||||
"otpPlaceholder": {"message": "123456"},
|
"otpPlaceholder": {"message": "123456"},
|
||||||
"saveAndLogIn": {"message": "Enregistrer et se connecter"},
|
"saveAndLogIn": {"message": "Enregistrer et se connecter"},
|
||||||
"thisPlugin": {"message": "Cette extension"},
|
"thisPlugin": {"message": "Cette extension"},
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
"usernameLabel": {"message": "Gebruikersnaam"},
|
"usernameLabel": {"message": "Gebruikersnaam"},
|
||||||
"usernamePlaceholder": {"message": "alice"},
|
"usernamePlaceholder": {"message": "alice"},
|
||||||
"passwordLabel": {"message": "Wachtwoord"},
|
"passwordLabel": {"message": "Wachtwoord"},
|
||||||
"otpLabel": {"message": "Eenmalig wachtwoord"},
|
"otpLabel": {"message": "Eenmalig wachtwoord (indien geconfigureerd)"},
|
||||||
"otpPlaceholder": {"message": "123456"},
|
"otpPlaceholder": {"message": "123456"},
|
||||||
"saveAndLogIn": {"message": "Opslaan en inloggen"},
|
"saveAndLogIn": {"message": "Opslaan en inloggen"},
|
||||||
"thisPlugin": {"message": "Deze plug-in"},
|
"thisPlugin": {"message": "Deze plug-in"},
|
||||||
|
|||||||
@@ -1,8 +1,6 @@
|
|||||||
// Copyright © 2026 Olaf Kolkman
|
// Copyright © 2026 Olaf Kolkman
|
||||||
// SPDX-License-Identifier: GPL-3.0-or-later
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
||||||
|
|
||||||
const DEFAULT_BACKEND = 'https://linklog.example.com';
|
|
||||||
|
|
||||||
const statusEl = document.getElementById('status');
|
const statusEl = document.getElementById('status');
|
||||||
const form = document.getElementById('settings-form');
|
const form = document.getElementById('settings-form');
|
||||||
const backendUrlInput = document.getElementById('backend-url');
|
const backendUrlInput = document.getElementById('backend-url');
|
||||||
@@ -24,7 +22,7 @@ function setStatus(message, isError = false) {
|
|||||||
|
|
||||||
async function loadSettings() {
|
async function loadSettings() {
|
||||||
const settings = await browser.storage.local.get(['backendUrl', 'username', 'accessToken']);
|
const settings = await browser.storage.local.get(['backendUrl', 'username', 'accessToken']);
|
||||||
backendUrlInput.value = settings.backendUrl || DEFAULT_BACKEND;
|
backendUrlInput.value = settings.backendUrl || '';
|
||||||
usernameInput.value = settings.username || '';
|
usernameInput.value = settings.username || '';
|
||||||
|
|
||||||
if (settings.accessToken && settings.backendUrl) {
|
if (settings.accessToken && settings.backendUrl) {
|
||||||
|
|||||||
Reference in New Issue
Block a user