Explorar o código

Add option to hide sidebar by default (#8515) (#8528)

* Add option to hide sidebar by default (#8515)

Closes https://github.com/FreshRSS/FreshRSS/issues/8515

Changes proposed in this pull request:

- Add `sidebar_hidden_by_default` user preference (default: `false`)
- Add a checkbox in the Display settings page to toggle this preference
- Hide the sidebar on page load in `normal` and `reader` views when the preference is enabled and no session state exists
- Add English translation key; mark all other languages as `TODO` for translators

How to test the feature manually:

1. Go to Settings → Display, tick "Hide sidebar by default", save
2. Go back to the main view (normal or reader): the sidebar should be hidden on load
3. Toggle the sidebar manually — it should open/stay open for the rest of the session
4. Open a new tab: the sidebar should be hidden again
5. Go to Settings → Display, untick the option, save: the sidebar should now be visible on load as usual
6. Check that the sidebar is always visible on Settings pages regardless of the preference

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* fix: PR comment

* Update app/i18n/pl/conf.php

* i18n: fr

* make fix-all

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: Inverle <inverle@proton.me>
Co-authored-by: Alexandre Alapetite <alexandre@alapetite.fr>
rid3r45 hai 1 mes
pai
achega
3e4d5bb041

+ 1 - 0
CREDITS.md

@@ -250,6 +250,7 @@ People are sorted by name so please keep this order.
 * [rdmitr](https://github.com/rdmitr): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:rdmitr)
 * [rdmitr](https://github.com/rdmitr): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:rdmitr)
 * [Rebecca Scott](https://github.com/becdetat): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:becdetat), [Web](https://becdetat.com)
 * [Rebecca Scott](https://github.com/becdetat): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:becdetat), [Web](https://becdetat.com)
 * [Rezad](https://github.com/rezad1393): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:rezad1393)
 * [Rezad](https://github.com/rezad1393): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:rezad1393)
+* [rid3r45](https://github.com/rid3r45): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:rid3r45)
 * [Rob Loach](https://github.com/RobLoach): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:RobLoach), [Web](https://robloach.net/)
 * [Rob Loach](https://github.com/RobLoach): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:RobLoach), [Web](https://robloach.net/)
 * [Robert Kaussow](https://github.com/xoxys): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:xoxys), [Web](https://geeklabor.de/)
 * [Robert Kaussow](https://github.com/xoxys): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:xoxys), [Web](https://geeklabor.de/)
 * [robertdahlem](https://github.com/robertdahlem): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:robertdahlem)
 * [robertdahlem](https://github.com/robertdahlem): [contributions](https://github.com/FreshRSS/FreshRSS/pulls?q=is:pr+author:robertdahlem)

+ 2 - 2
README.fr.md

@@ -234,11 +234,11 @@ Voir le [dépôt dédié à ces extensions](https://github.com/FreshRSS/Extensio
 | English (United States) (en-US) | ■■■■■■■■■■ 100% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fen-US+%2F%28TODO%7CDIRTY%29%24%2F) |
 | English (United States) (en-US) | ■■■■■■■■■■ 100% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fen-US+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Español (es) | ■■■■■■■■■・ 98% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fes+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Español (es) | ■■■■■■■■■・ 98% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fes+%2F%28TODO%7CDIRTY%29%24%2F) |
 | فارسی (fa) | ■■■■■■■■■・ 91% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffa+%2F%28TODO%7CDIRTY%29%24%2F) |
 | فارسی (fa) | ■■■■■■■■■・ 91% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffa+%2F%28TODO%7CDIRTY%29%24%2F) |
-| Suomi (fi) | ■■■■■■■■■・ 94% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffi+%2F%28TODO%7CDIRTY%29%24%2F) |
+| Suomi (fi) | ■■■■■■■■■・ 93% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffi+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Français (fr) | ■■■■■■■■■■ 100% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffr+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Français (fr) | ■■■■■■■■■■ 100% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffr+%2F%28TODO%7CDIRTY%29%24%2F) |
 | עברית (he) | ■■■■・・・・・・ 41% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhe+%2F%28TODO%7CDIRTY%29%24%2F) |
 | עברית (he) | ■■■■・・・・・・ 41% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhe+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Magyar (hu) | ■■■■■■■■■・ 97% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhu+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Magyar (hu) | ■■■■■■■■■・ 97% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhu+%2F%28TODO%7CDIRTY%29%24%2F) |
-| Bahasa Indonesia (id) | ■■■■■■■■■・ 91% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fid+%2F%28TODO%7CDIRTY%29%24%2F) |
+| Bahasa Indonesia (id) | ■■■■■■■■■・ 90% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fid+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Italiano (it) | ■■■■■■■■■・ 98% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fit+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Italiano (it) | ■■■■■■■■■・ 98% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fit+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 日本語 (ja) | ■■■■■■■■・・ 89% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fja+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 日本語 (ja) | ■■■■■■■■・・ 89% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fja+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 한국어 (ko) | ■■■■■■■■・・ 82% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fko+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 한국어 (ko) | ■■■■■■■■・・ 82% | [contribuer](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fko+%2F%28TODO%7CDIRTY%29%24%2F) |

+ 2 - 2
README.md

@@ -130,11 +130,11 @@ See the [repository dedicated to those extensions](https://github.com/FreshRSS/E
 | English (United States) (en-US) | ■■■■■■■■■■ 100% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fen-US+%2F%28TODO%7CDIRTY%29%24%2F) |
 | English (United States) (en-US) | ■■■■■■■■■■ 100% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fen-US+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Español (es) | ■■■■■■■■■・ 98% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fes+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Español (es) | ■■■■■■■■■・ 98% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fes+%2F%28TODO%7CDIRTY%29%24%2F) |
 | فارسی (fa) | ■■■■■■■■■・ 91% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffa+%2F%28TODO%7CDIRTY%29%24%2F) |
 | فارسی (fa) | ■■■■■■■■■・ 91% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffa+%2F%28TODO%7CDIRTY%29%24%2F) |
-| Suomi (fi) | ■■■■■■■■■・ 94% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffi+%2F%28TODO%7CDIRTY%29%24%2F) |
+| Suomi (fi) | ■■■■■■■■■・ 93% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffi+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Français (fr) | ■■■■■■■■■■ 100% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffr+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Français (fr) | ■■■■■■■■■■ 100% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Ffr+%2F%28TODO%7CDIRTY%29%24%2F) |
 | עברית (he) | ■■■■・・・・・・ 41% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhe+%2F%28TODO%7CDIRTY%29%24%2F) |
 | עברית (he) | ■■■■・・・・・・ 41% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhe+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Magyar (hu) | ■■■■■■■■■・ 97% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhu+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Magyar (hu) | ■■■■■■■■■・ 97% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fhu+%2F%28TODO%7CDIRTY%29%24%2F) |
-| Bahasa Indonesia (id) | ■■■■■■■■■・ 91% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fid+%2F%28TODO%7CDIRTY%29%24%2F) |
+| Bahasa Indonesia (id) | ■■■■■■■■■・ 90% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fid+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Italiano (it) | ■■■■■■■■■・ 98% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fit+%2F%28TODO%7CDIRTY%29%24%2F) |
 | Italiano (it) | ■■■■■■■■■・ 98% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fit+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 日本語 (ja) | ■■■■■■■■・・ 89% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fja+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 日本語 (ja) | ■■■■■■■■・・ 89% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fja+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 한국어 (ko) | ■■■■■■■■・・ 82% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fko+%2F%28TODO%7CDIRTY%29%24%2F) |
 | 한국어 (ko) | ■■■■■■■■・・ 82% | [contribute](https://github.com/search?q=repo%3AFreshRSS%2FFreshRSS+path%3Aapp%2Fi18n%2Fko+%2F%28TODO%7CDIRTY%29%24%2F) |

+ 1 - 0
app/Controllers/configureController.php

@@ -74,6 +74,7 @@ class FreshRSS_configure_Controller extends FreshRSS_ActionController {
 			FreshRSS_Context::userConf()->bottomline_date = Minz_Request::paramBoolean('bottomline_date');
 			FreshRSS_Context::userConf()->bottomline_date = Minz_Request::paramBoolean('bottomline_date');
 			FreshRSS_Context::userConf()->bottomline_link = Minz_Request::paramBoolean('bottomline_link');
 			FreshRSS_Context::userConf()->bottomline_link = Minz_Request::paramBoolean('bottomline_link');
 			FreshRSS_Context::userConf()->show_nav_buttons = Minz_Request::paramBoolean('show_nav_buttons');
 			FreshRSS_Context::userConf()->show_nav_buttons = Minz_Request::paramBoolean('show_nav_buttons');
+			FreshRSS_Context::userConf()->sidebar_hidden_by_default = Minz_Request::paramBoolean('sidebar_hidden_by_default');
 			FreshRSS_Context::userConf()->html5_notif_timeout = max(0, Minz_Request::paramInt('html5_notif_timeout'));
 			FreshRSS_Context::userConf()->html5_notif_timeout = max(0, Minz_Request::paramInt('html5_notif_timeout'));
 			FreshRSS_Context::userConf()->html5_enable_notif = Minz_Request::paramBoolean('html5_enable_notif');
 			FreshRSS_Context::userConf()->html5_enable_notif = Minz_Request::paramBoolean('html5_enable_notif');
 			FreshRSS_Context::userConf()->good_notification_timeout = max(0, Minz_Request::paramInt('good_notification_timeout'));
 			FreshRSS_Context::userConf()->good_notification_timeout = max(0, Minz_Request::paramInt('good_notification_timeout'));

+ 1 - 0
app/Models/UserConfiguration.php

@@ -54,6 +54,7 @@ declare(strict_types=1);
  * @property bool $icons_as_emojis
  * @property bool $icons_as_emojis
  * @property int $simplify_over_n_feeds
  * @property int $simplify_over_n_feeds
  * @property bool $show_nav_buttons
  * @property bool $show_nav_buttons
+ * @property bool $sidebar_hidden_by_default
  * @property 'big'|'small'|'none' $mark_read_button
  * @property 'big'|'small'|'none' $mark_read_button
  * @property 'ASC'|'DESC' $sort_order
  * @property 'ASC'|'DESC' $sort_order
  * @property 'id'|'c.name'|'date'|'f.name'|'length'|'link'|'rand'|'title' $sort
  * @property 'id'|'c.name'|'date'|'f.name'|'length'|'link'|'rand'|'title' $sort

+ 1 - 0
app/i18n/cs/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Časový limit HTML5 oznámení',
 			'timeout' => 'Časový limit HTML5 oznámení',
 		),
 		),
 		'show_nav_buttons' => 'Zobrazit navigační tlačítka',
 		'show_nav_buttons' => 'Zobrazit navigační tlačítka',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Motiv',
 			'_' => 'Motiv',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/de/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Zeitüberschreitung für HTML5-Benachrichtigung',
 			'timeout' => 'Zeitüberschreitung für HTML5-Benachrichtigung',
 		),
 		),
 		'show_nav_buttons' => 'Zeige Navigations-Buttons',
 		'show_nav_buttons' => 'Zeige Navigations-Buttons',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Layout',
 			'_' => 'Layout',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/el/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 notification timeout',	// TODO
 			'timeout' => 'HTML5 notification timeout',	// TODO
 		),
 		),
 		'show_nav_buttons' => 'Show the navigation buttons',	// TODO
 		'show_nav_buttons' => 'Show the navigation buttons',	// TODO
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Theme',	// TODO
 			'_' => 'Theme',	// TODO
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/en-US/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 notification timeout',	// IGNORE
 			'timeout' => 'HTML5 notification timeout',	// IGNORE
 		),
 		),
 		'show_nav_buttons' => 'Show the navigation buttons',	// IGNORE
 		'show_nav_buttons' => 'Show the navigation buttons',	// IGNORE
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// IGNORE
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Theme',	// IGNORE
 			'_' => 'Theme',	// IGNORE
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/en/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 notification timeout',
 			'timeout' => 'HTML5 notification timeout',
 		),
 		),
 		'show_nav_buttons' => 'Show the navigation buttons',
 		'show_nav_buttons' => 'Show the navigation buttons',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Theme',
 			'_' => 'Theme',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/es/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Notificación de fin de espera HTML5',
 			'timeout' => 'Notificación de fin de espera HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Mostrar los botones de navegación',
 		'show_nav_buttons' => 'Mostrar los botones de navegación',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/fa/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => ' وقفه اعلان HTML5',
 			'timeout' => ' وقفه اعلان HTML5',
 		),
 		),
 		'show_nav_buttons' => ' دکمه های ناوبری را نشان دهید',
 		'show_nav_buttons' => ' دکمه های ناوبری را نشان دهید',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => ' موضوع',
 			'_' => ' موضوع',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/fi/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Tauko HTML5-ilmoitusten välissä',
 			'timeout' => 'Tauko HTML5-ilmoitusten välissä',
 		),
 		),
 		'show_nav_buttons' => 'Näytä siirtymispainikkeet',
 		'show_nav_buttons' => 'Näytä siirtymispainikkeet',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Teema',
 			'_' => 'Teema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/fr/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Temps d’affichage de la notification HTML5',
 			'timeout' => 'Temps d’affichage de la notification HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Afficher les boutons de navigation',
 		'show_nav_buttons' => 'Afficher les boutons de navigation',
+		'sidebar_hidden_by_default' => 'Masquer la barre latérale par défaut',
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Thème',
 			'_' => 'Thème',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/he/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 התראה פג תוקף',
 			'timeout' => 'HTML5 התראה פג תוקף',
 		),
 		),
 		'show_nav_buttons' => 'Show the navigation buttons',	// TODO
 		'show_nav_buttons' => 'Show the navigation buttons',	// TODO
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'ערכת נושא',
 			'_' => 'ערכת נושא',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/hu/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 értesítés hossza',
 			'timeout' => 'HTML5 értesítés hossza',
 		),
 		),
 		'show_nav_buttons' => 'Navigációs gombok megjelenítése',
 		'show_nav_buttons' => 'Navigációs gombok megjelenítése',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Téma',
 			'_' => 'Téma',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/id/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Batas waktu pemberitahuan HTML5',
 			'timeout' => 'Batas waktu pemberitahuan HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Tampilkan tombol navigasi',
 		'show_nav_buttons' => 'Tampilkan tombol navigasi',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/it/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Notifica timeout HTML5',
 			'timeout' => 'Notifica timeout HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Mostra i pulsanti di navigazione',
 		'show_nav_buttons' => 'Mostra i pulsanti di navigazione',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/ja/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 の通知タイムアウト時間',
 			'timeout' => 'HTML5 の通知タイムアウト時間',
 		),
 		),
 		'show_nav_buttons' => 'ナビゲーションボタンを表示する',
 		'show_nav_buttons' => 'ナビゲーションボタンを表示する',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'テーマ',
 			'_' => 'テーマ',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/ko/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 알림 타임아웃',
 			'timeout' => 'HTML5 알림 타임아웃',
 		),
 		),
 		'show_nav_buttons' => '내비게이션 버튼 보이기',
 		'show_nav_buttons' => '내비게이션 버튼 보이기',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => '테마',
 			'_' => '테마',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/lv/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 paziņojuma laika ierobežojums',
 			'timeout' => 'HTML5 paziņojuma laika ierobežojums',
 		),
 		),
 		'show_nav_buttons' => 'Rādīt navigācijas pogas',
 		'show_nav_buttons' => 'Rādīt navigācijas pogas',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tēma',
 			'_' => 'Tēma',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/nl/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 notificatie stop',
 			'timeout' => 'HTML5 notificatie stop',
 		),
 		),
 		'show_nav_buttons' => 'Toon navigatieknoppen',
 		'show_nav_buttons' => 'Toon navigatieknoppen',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Thema',
 			'_' => 'Thema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/oc/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Temps d’afichatge de las notificacions HTML5',
 			'timeout' => 'Temps d’afichatge de las notificacions HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Mostrar los botons de navigacion',
 		'show_nav_buttons' => 'Mostrar los botons de navigacion',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tèma',
 			'_' => 'Tèma',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/pl/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Czas wyświetlania powiadomienia HTML5',
 			'timeout' => 'Czas wyświetlania powiadomienia HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Pokaż przyciski nawigacyjne',
 		'show_nav_buttons' => 'Pokaż przyciski nawigacyjne',
+		'sidebar_hidden_by_default' => 'Ukryj pasek boczny domyślnie',
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Motyw',
 			'_' => 'Motyw',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/pt-BR/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Notificação em HTML5 de timeout',
 			'timeout' => 'Notificação em HTML5 de timeout',
 		),
 		),
 		'show_nav_buttons' => 'Mostrar botões de navegação',
 		'show_nav_buttons' => 'Mostrar botões de navegação',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/pt-PT/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Notificação em HTML5 de timeout',
 			'timeout' => 'Notificação em HTML5 de timeout',
 		),
 		),
 		'show_nav_buttons' => 'Mostrar botões de navegação',
 		'show_nav_buttons' => 'Mostrar botões de navegação',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/ru/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Таймаут уведомлений HTML5',
 			'timeout' => 'Таймаут уведомлений HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Показать кнопки навигации',
 		'show_nav_buttons' => 'Показать кнопки навигации',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Тема',
 			'_' => 'Тема',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/sk/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Limit HTML5 oznámenia',
 			'timeout' => 'Limit HTML5 oznámenia',
 		),
 		),
 		'show_nav_buttons' => 'Zobraziť tlačidlá oznámenia',
 		'show_nav_buttons' => 'Zobraziť tlačidlá oznámenia',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Vzhľad',
 			'_' => 'Vzhľad',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/tr/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 bildirim zaman aşımı',
 			'timeout' => 'HTML5 bildirim zaman aşımı',
 		),
 		),
 		'show_nav_buttons' => 'Gezinme düğmelerini göster',
 		'show_nav_buttons' => 'Gezinme düğmelerini göster',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Tema',
 			'_' => 'Tema',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/uk/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'Тайм-аут сповіщення HTML5',
 			'timeout' => 'Тайм-аут сповіщення HTML5',
 		),
 		),
 		'show_nav_buttons' => 'Показати кнопки навігації',
 		'show_nav_buttons' => 'Показати кнопки навігації',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => 'Тема',
 			'_' => 'Тема',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/zh-CN/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 通知超时时间',
 			'timeout' => 'HTML5 通知超时时间',
 		),
 		),
 		'show_nav_buttons' => '显示导航按钮',
 		'show_nav_buttons' => '显示导航按钮',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => '主题',
 			'_' => '主题',
 			'deprecated' => array(
 			'deprecated' => array(

+ 1 - 0
app/i18n/zh-TW/conf.php

@@ -54,6 +54,7 @@ return array(
 			'timeout' => 'HTML5 通知超時時間',
 			'timeout' => 'HTML5 通知超時時間',
 		),
 		),
 		'show_nav_buttons' => '顯示導航按鈕',
 		'show_nav_buttons' => '顯示導航按鈕',
+		'sidebar_hidden_by_default' => 'Hide sidebar by default',	// TODO
 		'theme' => array(
 		'theme' => array(
 			'_' => '主題',
 			'_' => '主題',
 			'deprecated' => array(
 			'deprecated' => array(

+ 10 - 0
app/views/configure/display.phtml

@@ -275,6 +275,16 @@
 			</div>
 			</div>
 		</div>
 		</div>
 
 
+		<div class="form-group">
+			<div class="group-controls">
+				<label class="checkbox" for="sidebar_hidden_by_default">
+					<input type="checkbox" name="sidebar_hidden_by_default" id="sidebar_hidden_by_default" value="1"<?=
+						FreshRSS_Context::userConf()->sidebar_hidden_by_default ? ' checked="checked"' : '' ?> />
+					<?= _t('conf.display.sidebar_hidden_by_default') ?>
+				</label>
+			</div>
+		</div>
+
 		<div class="form-group form-actions">
 		<div class="form-group form-actions">
 			<div class="group-controls">
 			<div class="group-controls">
 				<button type="submit" class="btn btn-important"><?= _t('gen.action.submit') ?></button>
 				<button type="submit" class="btn btn-important"><?= _t('gen.action.submit') ?></button>

+ 1 - 0
app/views/helpers/javascript_vars.phtml

@@ -23,6 +23,7 @@ echo json_encode([
 		'nb_parallel_refresh' => max(1, FreshRSS_Context::systemConf()->nb_parallel_refresh),
 		'nb_parallel_refresh' => max(1, FreshRSS_Context::systemConf()->nb_parallel_refresh),
 		'does_lazyload' => !!FreshRSS_Context::userConf()->lazyload ,
 		'does_lazyload' => !!FreshRSS_Context::userConf()->lazyload ,
 		'sides_close_article' => !!FreshRSS_Context::userConf()->sides_close_article,
 		'sides_close_article' => !!FreshRSS_Context::userConf()->sides_close_article,
+		'sidebar_hidden_by_default' => !!FreshRSS_Context::userConf()->sidebar_hidden_by_default,
 		'sticky_post' => !!FreshRSS_Context::isStickyPostEnabled(),
 		'sticky_post' => !!FreshRSS_Context::isStickyPostEnabled(),
 		'html5_enable_notif' => FreshRSS_Context::userConf()->html5_enable_notif,
 		'html5_enable_notif' => FreshRSS_Context::userConf()->html5_enable_notif,
 		'html5_notif_timeout' => FreshRSS_Context::userConf()->html5_notif_timeout,
 		'html5_notif_timeout' => FreshRSS_Context::userConf()->html5_notif_timeout,

+ 1 - 0
config-user.default.php

@@ -135,6 +135,7 @@ return array (
 	'good_notification_timeout' => 3,
 	'good_notification_timeout' => 3,
 	'bad_notification_timeout' => 8,
 	'bad_notification_timeout' => 8,
 	'show_nav_buttons' => true,
 	'show_nav_buttons' => true,
+	'sidebar_hidden_by_default' => false,
 	# List of enabled FreshRSS extensions.
 	# List of enabled FreshRSS extensions.
 	'extensions_enabled' => [],
 	'extensions_enabled' => [],
 	'retrieve_extension_list' => true,
 	'retrieve_extension_list' => true,

+ 6 - 0
docs/en/users/05_Configuration.md

@@ -105,6 +105,12 @@ By default, FreshRSS displays buttons to ease the article navigation when browsi
 
 
 If you don’t use those buttons because you never browse on mobile or because you browse with gestures, you can disable them from the interface.
 If you don’t use those buttons because you never browse on mobile or because you browse with gestures, you can disable them from the interface.
 
 
+### Hide sidebar by default
+
+By default, the sidebar is visible when opening FreshRSS. If you prefer to have more reading space on load, you can hide it by default.
+
+When this option is enabled, the sidebar will be hidden at the start of each new session in the normal and reader views. You can still toggle it at any time using the sidebar button in the navigation bar.
+
 ## Reading
 ## Reading
 
 
 ### Number of articles per page
 ### Number of articles per page

+ 4 - 0
p/scripts/main.js

@@ -971,6 +971,10 @@ function init_nav_menu() {
 		if (context.current_view === 'normal') aside.classList.add('visible');
 		if (context.current_view === 'normal') aside.classList.add('visible');
 		sync(media);
 		sync(media);
 	}
 	}
+	if (state === null && context.sidebar_hidden_by_default && ['normal', 'reader'].includes(context.current_view)) {
+		const active = toggle_aside.classList.contains('active');
+		if (active) toggle_aside_click(false);
+	}
 	const close_aside = [
 	const close_aside = [
 		document.querySelector('.aside a.toggle_aside'),
 		document.querySelector('.aside a.toggle_aside'),
 		document.querySelector('a.close-aside'), // background of aside (#close)
 		document.querySelector('a.close-aside'), // background of aside (#close)