Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "fx-autoconfig"]
path = fx-autoconfig
url = https://github.com/MrOtherGuy/fx-autoconfig.git
90 changes: 89 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
**English** | [中文(简体)](docs/README.zh-CN.md) | [日本語](docs/README.ja.md) | [한국어](docs/README.ko.md) | [Deutsch](docs/README.de.md) | [Français](docs/README.fr.md) | [Español](docs/README.es.md) | [Português (Brasil)](docs/README.pt-BR.md) | [Русский](docs/README.ru.md)

A Firefox userChrome.js script that brings a second sidebar with web panels like in Vivaldi/Edge/Floorp but better.

<img width="2200" height="2131" alt="promo-rounded" src="https://github.com/user-attachments/assets/020ee8cf-1f3d-4184-98fe-889be89d6145" />
Expand All @@ -18,7 +20,7 @@ https://github.com/user-attachments/assets/cd79d644-ca2c-4a30-ae8e-c265f41768b6
- Customize via [Customize Toolbar...](https://support.mozilla.org/en-US/kb/customize-firefox-controls-buttons-and-toolbars)
- Settings:
- General: `Position (Left / Right)` • `Width`
- Visibility: `Auto-hide sidebar` • `Auto-hide behaiour (Inline / Overlay)` • `Hide web panel when sidebar is hidden` • `Set shortcut to hide/show sidebar`
- Visibility: `Auto-hide sidebar` • `Auto-hide behaviour (Inline / Overlay)` • `Hide web panel when sidebar is hidden` • `Set shortcut to hide/show sidebar`
- Web panel: `Default floating panel offset` • `New panel position (Before plus button / After plus button)` • `Show geometry hint`
- Web panel button: `Container indicator (Off / Left / Right / Top / Bottom / Around)` • `Tooltip (Off / Title / URL / Title and URL)` • `Show full URL in tooltip`
- Web panel toolbar: `Auto-hide forward button` • `Auto-hide back button`
Expand All @@ -45,8 +47,94 @@ https://github.com/user-attachments/assets/cd79d644-ca2c-4a30-ae8e-c265f41768b6

## Installation

### One-click install (Windows, recommended)

Open PowerShell as **Administrator** and run:

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/install.ps1 | iex
```

The script will automatically:

1. Download fx-autoconfig and Second Sidebar from GitHub
2. Detect Firefox install directory and profile folder
3. Install fx-autoconfig program files and profile files
4. Install Second Sidebar script
5. Verify the installation

> **Admin privileges**: fx-autoconfig's `config.js` must be copied to `C:\Program Files\Mozilla Firefox\`, which requires admin privileges. If not running as admin, the script will prompt for manual copy.

**Uninstall:**

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/uninstall.ps1 | iex
```

The uninstall script lets you interactively choose which components to remove (Second Sidebar script, fx-autoconfig profile files, fx-autoconfig program files).

### Manual install

1. Install [fx-autoconfig](https://github.com/MrOtherGuy/fx-autoconfig).
2. Copy the contents of the `src/` directory (`second_sidebar/` and `second_sidebar.uc.mjs`) into `chrome/JS/`.
3. Enable `toolkit.legacyUserProfileCustomizations.stylesheets` and `dom.allow_scripts_to_close_windows` in `about:config`.
4. [Clear](https://github.com/MrOtherGuy/fx-autoconfig?tab=readme-ov-file#deleting-startup-cache) startup-cache.
5. Have fun!

## Localization

The script supports multiple languages and automatically displays the UI in the user's Firefox language.

### Supported languages

| Language | Code | Status |
| ------------------ | ------- | ------- |
| English | `en-US` | ✅ Full |
| 中文(简体) | `zh-CN` | ✅ Full |
| 日本語 | `ja` | ✅ Full |
| 한국어 | `ko` | ✅ Full |
| Deutsch | `de` | ✅ Full |
| Français | `fr` | ✅ Full |
| Español | `es` | ✅ Full |
| Português (Brasil) | `pt-BR` | ✅ Full |
| Русский | `ru` | ✅ Full |

### Language file structure

```
src/second_sidebar/i18n/
├── index.mjs # Language detection and loading entry
├── en-US.mjs # English
├── zh-CN.mjs # Simplified Chinese
├── ja.mjs # Japanese
├── ko.mjs # Korean
├── de.mjs # German
├── fr.mjs # French
├── es.mjs # Spanish
├── pt-BR.mjs # Brazilian Portuguese
└── ru.mjs # Russian
```

### How it works

All UI strings are extracted from source code into language files under `src/second_sidebar/i18n/`. Each source file imports `L` from the i18n module:

```js
import { L } from "../i18n/index.mjs";
```

At startup, `index.mjs` detects the browser language via `Services.locale.requestedLocale` and exports the matching language object. If no exact match is found, it falls back by language prefix (e.g., `de-AT` → `de`), and ultimately to `en-US`.

### Adding a new language

1. Copy `en-US.mjs` to a new file (e.g., `it.mjs`)
2. Replace the English values with translations, keeping the keys unchanged
3. Import and register the new language in `index.mjs`

### Switching language

The script automatically detects the Firefox browser language. To switch:

1. Open Firefox Settings → General → Language
2. Change the Firefox interface language
3. Restart the browser
93 changes: 93 additions & 0 deletions docs/README.de.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
[English](../README.md) | **Deutsch**

Ein Firefox userChrome.js-Skript, das eine zweite Seitenleiste mit Web-Panels wie in Vivaldi/Edge/Floorp bringt – nur besser.

<img width="2200" height="2131" alt="promo-rounded" src="https://github.com/user-attachments/assets/020ee8cf-1f3d-4184-98fe-889be89d6145" />

## Motivation

Ich habe verschiedene Browser ausprobiert, wie Vivaldi, Edge, Floorp und Zen, und sie alle haben eines gemeinsam, ohne das ich mir ein Browser nicht vorstellen kann — die Seitenleiste. Leider hat Firefox, der meinen Bedürfnissen am ehesten entspricht, eine eher unbefriedigende Seitenleiste. Also beschloss ich, selbst eine zu erstellen, mit Blackjack und Hostessen!

## Demo

https://github.com/user-attachments/assets/cd79d644-ca2c-4a30-ae8e-c265f41768b6

## Funktionen

### Seitenleiste

- Aktionen: `Anzeigen` • `Ausblenden`
- Anpassen über [Symbolleiste anpassen...](https://support.mozilla.org/de/kb/customize-firefox-controls-buttons-and-toolbars)
- Einstellungen:
- Allgemein: `Position (Links / Rechts)` • `Breite`
- Sichtbarkeit: `Seitenleiste automatisch ausblenden` • `Verhalten beim automatischen Ausblenden (Inline / Überlagerung)` • `Web-Panel ausblenden, wenn Seitenleiste ausgeblendet ist` • `Tastenkombination zum Aus-/Einblenden der Seitenleiste`
- Web-Panel: `Standard-Versatz für schwebende Panels` • `Position neuer Panels (Vor dem Plus-Button / Nach dem Plus-Button)` • `Geometriehinweis anzeigen`
- Web-Panel-Schaltfläche: `Container-Anzeige (Aus / Links / Rechts / Oben / Unten / Ringsum)` • `Quickinfo (Aus / Titel / URL / Titel und URL)` • `Vollständige URL in Quickinfo anzeigen`
- Web-Panel-Symbolleiste: `Vorwärts-Button automatisch ausblenden` • `Zurück-Button automatisch ausblenden`
- Animationen: `Seitenleiste animieren` • `Web-Panel-Symbolleiste animieren`

### Web-Panels

- Aktionen: `Erstellen` • `Löschen` • `Bearbeiten` • `Position und Größe ändern` • `Position und Größe zurücksetzen` • `Entladen` • `Stumm schalten` • `Ton einschalten` • `Anheften` • `Lösen` • `Zoom ändern` • `Zurück` • `Vorwärts` • `Neu laden` • `Startseite`
- Erweiterungsunterstützung
- Popup-Benachrichtigungsunterstützung (Berechtigungen für Mikrofon/Kamera/Standort usw.)
- Einstellungen:
- Allgemein: `URL` • `Multi-Account-Container` • `Temporär` • `Mobile Ansicht` • `Zoom`
- Titel: `Dynamisch` • `Statischen Titel festlegen`
- Favicon: `Dynamisch` • `Statisches Favicon festlegen`
- Position und Größe: `Modus (Schwebend / Angeheftet)` • `Immer im Vordergrund` • `Positionsanker` • `Horizontaler Versatz` • `Vertikaler Versatz` • `Breite` • `Höhe`
- Laden: `Beim Start in den Speicher laden` • `Zuletzt geöffnete Seite wiederherstellen` • `Nach dem Schließen aus dem Speicher entladen` • `Periodisches Neuladen`
- Tastenkombination: `Tastenkombination zum Aus-/Einblenden des Web-Panels`
- CSS-Selektor: `Aktivieren` • `CSS-Selektor festlegen`
- Elemente ausblenden: `Symbolleiste ausblenden` • `Ton-Symbol ausblenden` • `Benachrichtigungsbadge ausblenden`

### Widgets

- `Zweite Seitenleiste` zum Anzeigen / Ausblenden der Seitenleiste

## Installation

### Ein-Klick-Installation (Windows, empfohlen)

PowerShell als **Administrator** öffnen und ausführen:

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/install.ps1 | iex
```

Das Skript führt automatisch Folgendes aus:

1. fx-autoconfig und Second Sidebar von GitHub herunterladen
2. Firefox-Installationsverzeichnis und Profilordner erkennen
3. fx-autoconfig-Programmdateien und Profildateien installieren
4. Second Sidebar-Skript installieren
5. Installation überprüfen

> **Administratorrechte**: fx-autoconfigs `config.js` muss nach `C:\Program Files\Mozilla Firefox\` kopiert werden, was Administratorrechte erfordert. Wenn nicht als Administrator ausgeführt, wird zur manuellen Kopie aufgefordert.

**Deinstallation:**

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/uninstall.ps1 | iex
```

Das Deinstallationsskript ermöglicht die interaktive Auswahl der zu entfernenden Komponenten.

### Manuelle Installation

1. [fx-autoconfig](https://github.com/MrOtherGuy/fx-autoconfig) installieren.
2. Den Inhalt des `src/`-Verzeichnisses (`second_sidebar/` und `second_sidebar.uc.mjs`) in `chrome/JS/` kopieren.
3. `toolkit.legacyUserProfileCustomizations.stylesheets` und `dom.allow_scripts_to_close_windows` in `about:config` aktivieren.
4. [Start-Cache löschen](https://github.com/MrOtherGuy/fx-autoconfig?tab=readme-ov-file#deleting-startup-cache).
5. Viel Spaß!

## Lokalisierung

Das Skript unterstützt mehrere Sprachen und zeigt die Benutzeroberfläche automatisch in der Firefox-Sprache an.

### Neue Sprache hinzufügen

1. `en-US.mjs` in eine neue Datei kopieren (z.B. `it.mjs`)
2. Englische Werte durch Übersetzungen ersetzen (Schlüssel nicht ändern)
3. Neue Sprache in `index.mjs` importieren und registrieren
4. PR einreichen
91 changes: 91 additions & 0 deletions docs/README.es.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
[English](../README.md) | **Español**

Un script userChrome.js de Firefox que aporta una segunda barra lateral con paneles web como en Vivaldi/Edge/Floorp pero mejor.

<img width="2200" height="2131" alt="promo-rounded" src="https://github.com/user-attachments/assets/020ee8cf-1f3d-4184-98fe-889be89d6145" />

## Motivación

He probado varios navegadores, como Vivaldi, Edge, Floorp y Zen, y todos tienen algo en común sin lo cual no puedo imaginar usar un navegador — la barra lateral. Lamentablemente, Firefox, que más se ajusta a mis necesidades, tiene una barra lateral bastante insatisfactoria. ¡Así que decidí crear otra yo mismo, con blackjack y acompañantes!

## Demo

https://github.com/user-attachments/assets/cd79d644-ca2c-4a30-ae8e-c265f41768b6

## Características

### Barra lateral

- Acciones: `Mostrar` • `Ocultar`
- Personalizar vía [Personalizar barra de herramientas...](https://support.mozilla.org/es/kb/customize-firefox-controls-buttons-and-toolbars)
- Configuración:
- General: `Posición (Izquierda / Derecha)` • `Ancho`
- Visibilidad: `Ocultar automáticamente la barra lateral` • `Comportamiento de ocultación automática (En línea / Superposición)` • `Ocultar panel web cuando la barra lateral está oculta` • `Atajo para ocultar/mostrar la barra lateral`
- Panel web: `Desplazamiento predeterminado del panel flotante` • `Posición del nuevo panel (Antes del botón más / Después del botón más)` • `Mostrar indicador de geometría`
- Botón del panel web: `Indicador de contenedor (Desactivado / Izquierda / Derecha / Arriba / Abajo / Alrededor)` • `Información sobre herramienta (Desactivado / Título / URL / Título y URL)` • `Mostrar URL completa en la información`
- Barra de herramientas del panel web: `Ocultar automáticamente el botón adelante` • `Ocultar automáticamente el botón atrás`
- Animaciones: `Animar barra lateral` • `Animar barra de herramientas del panel web`

### Paneles web

- Acciones: `Crear` • `Eliminar` • `Editar` • `Cambiar posición y tamaño` • `Restablecer posición y tamaño` • `Descargar` • `Silenciar` • `Activar sonido` • `Fijar` • `Desfijar` • `Cambiar zoom` • `Atrás` • `Adelante` • `Recargar` • `Inicio`
- Soporte de extensiones
- Soporte de notificaciones emergentes (permisos de micrófono/cámara/ubicación, etc.)
- Configuración:
- General: `URL` • `Contenedor multi-cuenta` • `Temporal` • `Vista móvil` • `Zoom`
- Título: `Dinámico` • `Establecer título estático`
- Favicon: `Dinámico` • `Establecer favicon estático`
- Posición y tamaño: `Modo (Flotante / Fijado)` • `Siempre encima` • `Ancla de posición` • `Desplazamiento horizontal` • `Desplazamiento vertical` • `Ancho` • `Alto`
- Carga: `Cargar en memoria al inicio` • `Restaurar la última página abierta` • `Descargar de la memoria al cerrar` • `Recarga periódica`
- Atajo de teclado: `Atajo para ocultar/mostrar el panel web`
- Selector CSS: `Activar` • `Establecer selector CSS`
- Ocultar elementos: `Ocultar barra de herramientas` • `Ocultar icono de sonido` • `Ocultar insignia de notificación`

### Widgets

- `Segunda barra lateral` para mostrar / ocultar la barra lateral

## Instalación

### Instalación con un clic (Windows, recomendado)

Abrir PowerShell como **administrador** y ejecutar:

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/install.ps1 | iex
```

El script realizará automáticamente:

1. Descargar fx-autoconfig y Second Sidebar desde GitHub
2. Detectar el directorio de instalación de Firefox y la carpeta de perfil
3. Instalar los archivos de programa y perfil de fx-autoconfig
4. Instalar el script Second Sidebar
5. Verificar la instalación

> **Privilegios de administrador**: El `config.js` de fx-autoconfig debe copiarse a `C:\Program Files\Mozilla Firefox\`, lo que requiere privilegios de administrador.

**Desinstalación:**

```powershell
irm https://raw.githubusercontent.com/aminought/firefox-second-sidebar/master/uninstall.ps1 | iex
```

### Instalación manual

1. Instalar [fx-autoconfig](https://github.com/MrOtherGuy/fx-autoconfig).
2. Copiar el contenido del directorio `src/` (`second_sidebar/` y `second_sidebar.uc.mjs`) en `chrome/JS/`.
3. Habilitar `toolkit.legacyUserProfileCustomizations.stylesheets` y `dom.allow_scripts_to_close_windows` en `about:config`.
4. [Limpiar](https://github.com/MrOtherGuy/fx-autoconfig?tab=readme-ov-file#deleting-startup-cache) la caché de inicio.
5. ¡Disfrutar!

## Localización

El script soporta múltiples idiomas y muestra automáticamente la interfaz en el idioma de Firefox.

### Añadir un nuevo idioma

1. Copiar `en-US.mjs` a un nuevo archivo (ej: `it.mjs`)
2. Reemplazar los valores en inglés con traducciones (no cambiar las claves)
3. Importar y registrar el nuevo idioma en `index.mjs`
4. Enviar un PR
Loading