From b47a9cd938e31dccb1e3f131ce8b925f4527f6da Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Thu, 15 Feb 2024 00:04:35 -0500 Subject: [PATCH] Nicer format for credits page --- slixfeed/assets/information.toml | 78 ++++++++++++++++---------------- slixfeed/xmpp/client.py | 17 ++----- 2 files changed, 44 insertions(+), 51 deletions(-) diff --git a/slixfeed/assets/information.toml b/slixfeed/assets/information.toml index 8b2e159..8f7ee21 100644 --- a/slixfeed/assets/information.toml +++ b/slixfeed/assets/information.toml @@ -119,45 +119,45 @@ MIT License for more details. https://gitgud.io/sjehuda/slixfeed """ -thanks = """ -Alixander Court (Utah); \ -Chriss Farrell (SalixOS, Oregon); \ -Christian Dersch (SalixOS); \ -Cyrille Pontvieux (SalixOS, France); \ -Denis Fomin (Gajim, Russia); \ -Dimitris Tzemos (SalixOS, Greece); \ -Emmanuel Gil Peyrot (Poezio, France); \ -Florent Le Coz (Poezio, France); \ -George Vlahavas (SalixOS, Greece); \ -Guus der Kinderen (Openfire, Netherlands); \ -habnabit_ from #python on irc.libera.chat; \ -Imar van Erven Dorens (SalixOS, Netherlands); \ -imattau (atomtopubsub); \ -Jaussoin Timothée (Movim, France); \ -Justin Karneges (Psi, California); \ -Kevin Smith (Swift IM, Wales); \ -Lars Windolf (Liferea, Germany); \ -Luis Henrique Mello (SalixOS, Brazil); \ -magicfelix; \ -Markus Muttilainen (SalixOS); \ -Martin (Debian, Germany); \ -Mathieu Pasquet (slixmpp, France); \ -Maxime Buquet (slixmpp, France); \ -mirux (Germany); \ -Phillip Watkins (SalixOS, United Kingdom); \ -Pierrick Le Brun (SalixOS, France); \ -Raphael Groner (Fedora, Germany); \ -Remko Tronçon (Psi , Belgium); \ -Simone "roughnecks" Canaletti (Italy); \ -Richard Lapointe (SalixOS, Connecticut); \ -Stephen Paul Weber ; \ -Strix from Loqi; \ -Thibaud Guerin (SalixOS); \ -Thorsten Fröhlich (France); \ -Thorsten Mühlfelder (SalixOS, Germany); \ -Tim Beech (SalixOS, Brazil); \ -Yann Leboulanger (Gajim, France). -""" +thanks = [ + "Alixander Court (Utah)", + "Chriss Farrell (SalixOS, Oregon)", + "Christian Dersch (SalixOS)", + "Cyrille Pontvieux (SalixOS, France)", + "Denis Fomin (Gajim, Russia)", + "Dimitris Tzemos (SalixOS, Greece)", + "Emmanuel Gil Peyrot (Poezio, France)", + "Florent Le Coz (Poezio, France)", + "George Vlahavas (SalixOS, Greece)", + "Guus der Kinderen (Openfire, Netherlands)", + "habnabit_ from #python on irc.libera.chat", + "Imar van Erven Dorens (SalixOS, Netherlands)", + "imattau (atomtopubsub)", + "Jaussoin Timothée (Movim, France)", + "Justin Karneges (Psi, California)", + "Kevin Smith (Swift IM, Wales)", + "Lars Windolf (Liferea, Germany)", + "Luis Henrique Mello (SalixOS, Brazil)", + "magicfelix", + "Markus Muttilainen (SalixOS)", + "Martin (Debian, Germany)", + "Mathieu Pasquet (slixmpp, France)", + "Maxime Buquet (slixmpp, France)", + "mirux (Germany)", + "Phillip Watkins (SalixOS, United Kingdom)", + "Pierrick Le Brun (SalixOS, France)", + "Raphael Groner (Fedora, Germany)", + "Remko Tronçon (Psi , Belgium)", + "Simone \"roughnecks\" Canaletti (Italy)", + "Richard Lapointe (SalixOS, Connecticut)", + "Stephen Paul Weber ", + "Strix from Loqi", + "Thibaud Guerin (SalixOS)", + "Thorsten Fröhlich (France)", + "Thorsten Mühlfelder (SalixOS, Germany)", + "Tim Beech (SalixOS, Brazil)", + "Yann Leboulanger (Gajim, France)" +] xmpp = """ XMPP is the Extensible Messaging and Presence Protocol, a set \ diff --git a/slixfeed/xmpp/client.py b/slixfeed/xmpp/client.py index 8ecda9c..640fd9f 100644 --- a/slixfeed/xmpp/client.py +++ b/slixfeed/xmpp/client.py @@ -980,18 +980,11 @@ class Slixfeed(slixmpp.ClientXMPP): async def _handle_credit(self, iq, session): - # form = self['xep_0004'].make_form('result', 'Thanks') - # form['instructions'] = action.manual('information.toml', 'thanks') - # session['payload'] = form - text = 'We are XMPP\n\n' - fren = action.manual('information.toml', 'thanks') - fren = "".join(fren) - fren = fren.split(';') - fren = "\n".join(fren) - text += fren - # text += '\n\nYOU!\n\n🫵️\n\n- Join us -\n\n🤝️' - text += '\n\nYOU!\n\n🫵️\n\n- Join us -' - session['notes'] = [['info', text]] + form = self['xep_0004'].make_form('result', 'Credits') + form['instructions'] = "We are XMPP" + form.add_field(ftype="text-multi", value=action.manual('information.toml', 'thanks')) + form['instructions'] = 'YOU!\n🫵️\n- Join us -' + session['payload'] = form return session