diff --git a/docs/features.es.md b/docs/features.es.md index f1c3bb0..bb73e3d 100644 --- a/docs/features.es.md +++ b/docs/features.es.md @@ -137,6 +137,12 @@ se hace más grande y animado para que lo veas mejor. ![GIF que muestra el punto de notificación mejorado](resources/announcement_dot.gif) +### Reposiciona el botón para expandir hilos +> **Option name:** _Pon el botón "expandir hilo" a la izquierda del todo en las +listas de hilos de la Consola de la Comunidad._. + +![Imagen que muestra la función](resources/reposition_expand_thread.jpg) + ### Punto indicador > **Opciones:** _Muestra si el autor del hilo ha participado en otros hilos_, _Muestra el número de preguntas y respuestas escritas por el autor del hilo diff --git a/docs/features.md b/docs/features.md index 50ae1fc..a462046 100644 --- a/docs/features.md +++ b/docs/features.md @@ -125,11 +125,17 @@ the Community Console_. When this option is enabled, the "Alpha" banner in the upper-left corner of the Community Console is removed, and the notification dot which appears in the -hamburguer menu when there's a new announcement is enlarged and animated so you +hamburger menu when there's a new announcement is enlarged and animated so you don't miss it. ![GIF showing the improved notification dot](resources/announcement_dot.gif) +### Reposition the expand thread button +> **Option name:** _Place the "expand thread" button all the way to the left in +the Community Console thread lists_. + +![Picture showing the feature](resources/reposition_expand_thread.jpg) + ### Indicator dot > **Option names:** _Show whether the OP has participated in other threads_, _Show the number of questions and replies written by the OP within the last `n` diff --git a/docs/resources/reposition_expand_thread.jpg b/docs/resources/reposition_expand_thread.jpg new file mode 100644 index 0000000..cb24016 Binary files /dev/null and b/docs/resources/reposition_expand_thread.jpg differ diff --git a/src/_locales/ca/messages.json b/src/_locales/ca/messages.json index 746ac61..c4c74cc 100644 --- a/src/_locales/ca/messages.json +++ b/src/_locales/ca/messages.json @@ -95,6 +95,10 @@ "message": "Mostra el punt que notifica que hi ha anuncis sense llegir d'una manera més prominent a la Consola de la Comunitat.", "description": "Feature checkbox in the options page" }, + "options_repositionexpandthread": { + "message": "Posa el botó \"expandir fil\" a l'esquerra del tot en les llistes de fils de la Consola de la Comunitat.", + "description": "Feature checkbox in the options page" + }, "options_profileindicator_header": { "message": "Punt indicador", "description": "Heading for the profile indicator feature options" diff --git a/src/_locales/en/messages.json b/src/_locales/en/messages.json index 407ba5c..f3b71d3 100644 --- a/src/_locales/en/messages.json +++ b/src/_locales/en/messages.json @@ -99,6 +99,10 @@ "message": "Show the announcements notification dot more prominently in the Community Console.", "description": "Feature checkbox in the options page" }, + "options_repositionexpandthread": { + "message": "Place the \"expand thread\" button all the way to the left in the Community Console thread lists.", + "description": "Feature checkbox in the options page" + }, "options_profileindicator_header": { "message": "Indicator dot", "description": "Heading for the profile indicator feature options" diff --git a/src/_locales/es/messages.json b/src/_locales/es/messages.json index 96b6fd9..1ac1f11 100644 --- a/src/_locales/es/messages.json +++ b/src/_locales/es/messages.json @@ -95,6 +95,10 @@ "message": "Muestra el punto que notifica que hay anuncios sin leer de manera más prominente en la Consola de la Comunidad.", "description": "Feature checkbox in the options page" }, + "options_repositionexpandthread": { + "message": "Pon el botón \"expandir hilo\" a la izquierda del todo en las listas de hilos de la Consola de la Comunidad.", + "description": "Feature checkbox in the options page" + }, "options_profileindicator_header": { "message": "Punto indicador", "description": "Heading for the profile indicator feature options" diff --git a/src/common/common.js b/src/common/common.js index 663ca28..e4af064 100644 --- a/src/common/common.js +++ b/src/common/common.js @@ -22,6 +22,7 @@ const defaultOptions = { 'batchlock': false, 'smei_sortdirection': false, 'enhancedannouncementsdot': false, + 'repositionexpandthread': false, }; const specialOptions = [ diff --git a/src/content_scripts/console_inject.js b/src/content_scripts/console_inject.js index 67bd409..c042f92 100644 --- a/src/content_scripts/console_inject.js +++ b/src/content_scripts/console_inject.js @@ -402,6 +402,11 @@ chrome.storage.sync.get(null, function(items) { chrome.runtime.getURL('injections/enhanced_announcements_dot.css')); } + if (options.repositionexpandthread) { + injectStylesheet( + chrome.runtime.getURL('injections/reposition_expand_thread.css')); + } + if (options.ccforcehidedrawer) { var drawer = document.querySelector('material-drawer'); if (drawer !== null && drawer.classList.contains('mat-drawer-expanded')) { diff --git a/src/injections/reposition_expand_thread.css b/src/injections/reposition_expand_thread.css new file mode 100644 index 0000000..8df9d2f --- /dev/null +++ b/src/injections/reposition_expand_thread.css @@ -0,0 +1,20 @@ +ec-thread-summary .panel .main-header { + flex-direction: row-reverse; +} + +ec-thread-summary .panel .main-header .expand-container { + padding: 0 0 0 8px; +} + +ec-thread-summary .panel .main-header .header { + padding-left: 0px!important; + padding-right: 16px!important; +} + +ec-thread-list ec-bulk-actions .selection { + padding-left: 29px; +} + +ec-thread-summary .panel .main .content-wrapper > .content > .content { + padding: 0 8px 0 121px; +} diff --git a/src/options/options.html b/src/options/options.html index 62fce67..69cddd8 100644 --- a/src/options/options.html +++ b/src/options/options.html @@ -34,6 +34,7 @@

+

diff --git a/templates/manifest.gjson b/templates/manifest.gjson index 72126b9..5a91bdf 100644 --- a/templates/manifest.gjson +++ b/templates/manifest.gjson @@ -71,7 +71,8 @@ "injections/profileindicator_inject.css", "injections/ccdarktheme.css", "injections/batchlock_inject.js", - "injections/enhanced_announcements_dot.css" + "injections/enhanced_announcements_dot.css", + "injections/reposition_expand_thread.css" #if defined(CHROMIUM_MV3) ], "matches": [