feat(ai): admin disabled-teaser for AI actions when LLM unconfigured (LC-506) #473
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/LC-506-llm-admin-teaser"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
When the optional LLM endpoint (
LETS_CHAT_LLM_URL) is unconfigured, the AI actions used to be hidden from everyone, so nobody discovered the feature existed. Now site admins see the AI controls as a disabled teaser with a "set it up" hint, while regular members still see nothing. No behavior change when the LLM is configured.Scope
{% else if llm_teaser %}branch renders a disabled, no-hx button with adata-lc-tiptooltip pointing atLETS_CHAT_LLM_URL. Recomputed on the notify-prefs header swap so it survives the inline update.ai-needs-setup(en + es)..lc-action-disabledCSS: dimmed, default cursor, no hover affordance.llm_teaser = !state.llm_available() && user.role == "admin". The teaser carries nohx-*attributes and usesaria-disabled(not thedisabledattribute) so the hover tooltip still renders while the control does nothing.Not included
The per-message "Translate" item is CSS-gated with no per-message view flag, so showing an admin teaser there would mean threading a flag through all 17
MessageViewconstructors. Left hidden for now.Checks
just check,just test,just test-saas,just build-cssall pass.