feat: UX 2-Reihen-Button-Pattern — max 3 Buttons/Reihe, Nummern im Text+Button, Sonderschaltflächen separat

This commit is contained in:
Bernd (Hermes)
2026-07-21 07:47:12 +02:00
parent eb10954e7c
commit 57bebeb029
3 changed files with 653 additions and 170 deletions
+74 -26
View File
@@ -4638,16 +4638,29 @@ class RocketChatAdapter(BasePlatformAdapter):
f"Möchtest du den Butler-Mode ändern oder beibehalten?\n\n"
f"👉 Klicke auf einen Button:"
)
butler_buttons = _build(
["✏️ Ändern", "⏭️ Skip"],
# Reihe 1: Ändern-Button
butler_buttons_row1 = _build(
["✏️ Ändern"],
prefix="REVIEW_BUTLER",
style="primary",
)
butler_attachments = [{
"color": "#1d74f5",
"title": "Butler-Mode Review",
"actions": butler_buttons,
}]
# Reihe 2: Beibehalten (Sonderschaltfläche)
butler_buttons_row2 = _build(
["⏭️ Beibehalten"],
prefix="REVIEW_BUTLER",
style="default",
)
butler_attachments = [
{
"color": "#1d74f5",
"title": "Butler-Mode Review",
"actions": butler_buttons_row1,
},
{
"color": "#1d74f5",
"actions": butler_buttons_row2,
},
]
await self._post_message_with_retry(
operator_room_id, butler_text, attachments=butler_attachments
)
@@ -4695,16 +4708,29 @@ class RocketChatAdapter(BasePlatformAdapter):
f"Möchtest du den FAKT-Speicherort ändern oder beibehalten?\n\n"
f"👉 Klicke auf einen Button:"
)
fakt_buttons = _build(
["✏️ Ändern", "⏭️ Skip"],
# Reihe 1: Ändern-Button
fakt_buttons_row1 = _build(
["✏️ Ändern"],
prefix="REVIEW_FAKT",
style="primary",
)
fakt_attachments = [{
"color": "#1d74f5",
"title": "FAKT-Speicherort Review",
"actions": fakt_buttons,
}]
# Reihe 2: Beibehalten (Sonderschaltfläche)
fakt_buttons_row2 = _build(
["⏭️ Beibehalten"],
prefix="REVIEW_FAKT",
style="default",
)
fakt_attachments = [
{
"color": "#1d74f5",
"title": "FAKT-Speicherort Review",
"actions": fakt_buttons_row1,
},
{
"color": "#1d74f5",
"actions": fakt_buttons_row2,
},
]
await self._post_message_with_retry(
operator_room_id, fakt_text, attachments=fakt_attachments
)
@@ -4729,11 +4755,22 @@ class RocketChatAdapter(BasePlatformAdapter):
prefix="BUTLER",
style="primary",
)
butler_attachments = [{
"color": "#1d74f5",
"title": "Butler-Modus wählen",
"actions": butler_buttons,
}]
butler_back = _build(
["↩️ Zurück"],
prefix="REVIEW_BUTLER",
style="default",
)
butler_attachments = [
{
"color": "#1d74f5",
"title": "Butler-Modus wählen",
"actions": butler_buttons,
},
{
"color": "#1d74f5",
"actions": butler_back,
},
]
# Wechsle in butler_mode Phase (existierende Logik)
self._onboarding_state = {
"phase": "butler_mode",
@@ -4783,16 +4820,27 @@ class RocketChatAdapter(BasePlatformAdapter):
"4️⃣ **Keine Sammlung** — FAKT-Nachrichten werden nicht persistiert\n\n"
"👉 Klicke auf einen Button oder antworte mit 1–4:"
)
fakt_buttons = _build(
["1️⃣ Standard", "2️⃣ Neu", "3️⃣ Vorhanden", "4️⃣ Keine"],
fakt_buttons_row1 = _build(
["1️⃣ Standard", "2️⃣ Neu", "3️⃣ Vorhanden"],
prefix="FAKT",
style="primary",
)
fakt_attachments = [{
"color": "#1d74f5",
"title": "FAKT-Speicherort wählen",
"actions": fakt_buttons,
}]
fakt_buttons_row2 = _build(
["4️⃣ Keine", "⏭️ Skip"],
prefix="FAKT",
style="primary",
)
fakt_attachments = [
{
"color": "#1d74f5",
"title": "FAKT-Speicherort wählen",
"actions": fakt_buttons_row1,
},
{
"color": "#1d74f5",
"actions": fakt_buttons_row2,
},
]
# Wechsle in fakt_store Phase (existierende Logik)
self._onboarding_state = {
"phase": "fakt_store",