From 109d081a3f6dbf21c8dc15ea3648eff3008c9e0d Mon Sep 17 00:00:00 2001 From: yumoqing Date: Mon, 6 Jul 2026 15:08:51 +0800 Subject: [PATCH] fix: wrap description+pricing in VScrollPanel so long descriptions don't push pricing off-screen - show_llms_cards.ui: card-body-scroll VScrollPanel wraps Text(desc) + Filler(pricing) - show_llms_cards_by_provider.ui: same fix --- wwwroot/show_llms_cards.ui | 44 +++++++++++++++----------- wwwroot/show_llms_cards_by_provider.ui | 44 +++++++++++++++----------- 2 files changed, 52 insertions(+), 36 deletions(-) diff --git a/wwwroot/show_llms_cards.ui b/wwwroot/show_llms_cards.ui index 04051ef..170555b 100644 --- a/wwwroot/show_llms_cards.ui +++ b/wwwroot/show_llms_cards.ui @@ -51,34 +51,42 @@ ] }, { - "widgettype":"Text", + "widgettype":"VScrollPanel", "options":{ - "text":{{json.dumps(llm.description, ensure_ascii=False)}}, - "wrap":true, - "halign":"left" - } - }, - { - "widgettype":"Filler", - "options":{ - "css":"pricing-box" + "css":"card-body-scroll" }, "subwidgets":[ -{% for pricing_text in llm.pricing_display %} { "widgettype":"Text", "options":{ - "text":{{json.dumps(pricing_text, ensure_ascii=False)}}, + "text":{{json.dumps(llm.description, ensure_ascii=False)}}, "wrap":true, - "halign":"left", - "css":"pricing-text" + "halign":"left" } - }{% if not loop.last %},{% endif %} -{% endfor %} + }, + { + "widgettype":"Filler", + "options":{ + "css":"pricing-box" + }, + "subwidgets":[ + {% for pricing_text in llm.pricing_display %} + { + "widgettype":"Text", + "options":{ + "text":{{json.dumps(pricing_text, ensure_ascii=False)}}, + "wrap":true, + "halign":"left", + "css":"pricing-text" + } + }{% if not loop.last %},{% endif %} + {% endfor %} + ] + } ] } - ], - "binds":[ + ], + "binds":[ { "wid":"self", "event":"click", diff --git a/wwwroot/show_llms_cards_by_provider.ui b/wwwroot/show_llms_cards_by_provider.ui index 813c467..1ff3c63 100644 --- a/wwwroot/show_llms_cards_by_provider.ui +++ b/wwwroot/show_llms_cards_by_provider.ui @@ -50,34 +50,42 @@ ] }, { - "widgettype":"Text", + "widgettype":"VScrollPanel", "options":{ - "text":{{json.dumps(llm.description or '', ensure_ascii=False)}}, - "wrap":true, - "halign":"left" - } - }, - { - "widgettype":"Filler", - "options":{ - "css":"pricing-box" + "css":"card-body-scroll" }, "subwidgets":[ -{% for pricing_text in llm.pricing_display %} { "widgettype":"Text", "options":{ - "text":{{json.dumps(pricing_text, ensure_ascii=False)}}, + "text":{{json.dumps(llm.description or '', ensure_ascii=False)}}, "wrap":true, - "halign":"left", - "css":"pricing-text" + "halign":"left" } - }{% if not loop.last %},{% endif %} -{% endfor %} + }, + { + "widgettype":"Filler", + "options":{ + "css":"pricing-box" + }, + "subwidgets":[ + {% for pricing_text in llm.pricing_display %} + { + "widgettype":"Text", + "options":{ + "text":{{json.dumps(pricing_text, ensure_ascii=False)}}, + "wrap":true, + "halign":"left", + "css":"pricing-text" + } + }{% if not loop.last %},{% endif %} + {% endfor %} + ] + } ] } - ], - "binds":[ + ], + "binds":[ { "wid":"self", "event":"click",