Launch threadListAvatars feature

This CL adds the docs for the feature and promotes the feature from an
experiment to an option.

Fixed: twpowertools:28, twpowertools:26
Change-Id: I69d6eccc5fe83c802718e255fa9967f804f3d9a6
diff --git a/docs/features.es.md b/docs/features.es.md
index 5dcd623..a8d8b07 100644
--- a/docs/features.es.md
+++ b/docs/features.es.md
@@ -138,6 +138,38 @@
 
 ![Imagen que muestra la función](resources/reposition_expand_thread.jpg)
 
+### Avatares/fotos de perfil en las listas de hilos
+> **Opción:** _Muestra fotos de perfil en las listas de hilos de la Consola de
+la Comunidad_.
+
+Cuando esta opción está activada, se mostrarán los avatares/fotos de perfil en
+las listas de hilos de la Consola de la Comunidad al lado de cada hilo, para
+mostrar quién ha participado en cada hilo.
+
+La extensión obtiene el mensaje principal y las primeras 15 respuestas, y
+muestra los avatares en orden (el primer avatar corresponde a la primera persona
+que se ha unido al hilo). Si un usuario no ha configurado un avatar, se salta,
+y solo se muestran un máximo de 3 avatares.
+
+#### Problemas conocidos
+- Los avatares no se muestran para hilos en foros privados, debido a razones
+técnicas.
+- Solo el mensaje principal y las primeras 15 respuestas son consideradas para
+cada hilo, así que si alguien se une al hilo después de este límite, su avatar
+no aparecerá.
+- Cuando se vuelve de un hilo a la lista de hilos haciendo clic en el botón
+"atrás", los avatares tardan unos segundos en aparecer.
+- Si más de 3 personas con avatar han publicado un mensaje, la extensión no lo
+indicará de ninguna manera, solo mostrará los primeros 3 avatares.
+- Aunque un EP no tenga insignia en un foro, su avatar se mostrará en la lista
+de hilos (esto es de hecho por diseño, no es un problema). Aun así, el avatar
+no se mostrará dentro del hilo.
+- Si un EP cambia su avatar, podrías continuar viendo el viejo en las listas de
+hilos, debido al hecho que los avatares se guardan en una caché, y solo se
+actualizan cuando se publica una nueva respuesta en el hilo.
+
+![Imagen que muestra la función de avatares en listas de hilos](resources/thread_list_avatars.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 b50a8a1..ead6a88 100644
--- a/docs/features.md
+++ b/docs/features.md
@@ -72,7 +72,7 @@
 threads are very similar. This option increases this contrast.
 
 ### Sticky drawer headers
-> **Option name_** _Make the headers in the Community Console sidebar stick at
+> **Option name:** _Make the headers in the Community Console sidebar stick at
 the top_.
 
 ![GIF showing the feature](resources/sticky_headers.gif)
@@ -131,6 +131,35 @@
 
 ![Picture showing the feature](resources/reposition_expand_thread.jpg)
 
+### Avatars in thread lists
+> **Option name:** _Show avatars in thread lists in the Community Console_.
+
+When this option is enabled, in thread lists in the Community Console avatars
+will be shown next to each thread to show the avatars of the people who have
+participated in the thread.
+
+The extension retrieves the main message and the first 15 replies, and shows
+the avatars in order (the first avatar corresponds to the first person who
+joined the thread). If a user hasn't set an avatar, it is skipped, and only up
+to 3 avatars are shown.
+
+#### Known issues
+- Avatars aren't shown for threads in private forums, due to technical reasons.
+- Only the main message and the first 15 replies are considered in each thread,
+so if someone joins the thread after this limit, their avatar won't appear.
+- When going back from a thread to the thread list by clicking the "back"
+button, avatars take some seconds to appear.
+- If more than 3 people with avatar have posted a message, the extension will
+not indicate this in any way, it will just show the first 3 avatars.
+- Even if a PE is not badged in a forum, their avatar will be shown in the
+thread list (this is actually a feature, not an issue). The avatar won't show
+however inside the thread.
+- If a PE changes their avatar, you might still see the old one in the thread
+list, due to the fact that avatars are stored in a cache, and are only updated
+when a new reply is posted in the thread.
+
+![Picture showing the thread list avatars feature](resources/thread_list_avatars.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/thread_list_avatars.jpg b/docs/resources/thread_list_avatars.jpg
new file mode 100644
index 0000000..85b4f1c
--- /dev/null
+++ b/docs/resources/thread_list_avatars.jpg
Binary files differ
diff --git a/src/common/optionsPrototype.json5 b/src/common/optionsPrototype.json5
index a5caa3e..80020ce 100644
--- a/src/common/optionsPrototype.json5
+++ b/src/common/optionsPrototype.json5
@@ -95,13 +95,13 @@
     context: 'options',
     killSwitchType: 'option',
   },
-
-  // Experiments:
   'threadlistavatars': {
     defaultValue: false,
-    context: 'experiments',
-    killSwitchType: 'experiment',
+    context: 'options',
+    killSwitchType: 'option',
   },
+
+  // Experiments:
   'autorefreshlist': {
     defaultValue: false,
     context: 'experiments',
diff --git a/src/options/optionsPage.json5 b/src/options/optionsPage.json5
index 694c7dc..9647dd6 100644
--- a/src/options/optionsPage.json5
+++ b/src/options/optionsPage.json5
@@ -26,6 +26,7 @@
         {codename: 'batchlock'},
         {codename: 'enhancedannouncementsdot'},
         {codename: 'repositionexpandthread', experimental: true},
+        {codename: 'threadlistavatars'},
       ],
     },
     {
diff --git a/src/static/options/experiments.html b/src/static/options/experiments.html
index 81c8a10..b835e17 100644
--- a/src/static/options/experiments.html
+++ b/src/static/options/experiments.html
@@ -12,7 +12,6 @@
       <h1 data-i18n="experiments_title"></h1>
       <p data-i18n="experiments_description"></p>
       <form>
-        <div class="option"><input type="checkbox" id="threadlistavatars"> <label for="threadlistavatars" data-i18n="threadlistavatars"></label></div>
         <div class="option"><input type="checkbox" id="autorefreshlist"> <label for="autorefreshlist" data-i18n="autorefreshlist"></label></div>
         <div class="actions"><button id="save" data-i18n="save"></button></div>
       </form>