Skip to content

fix(dashboard): show full command description#7815

Open
bugkeep wants to merge 2 commits intoAstrBotDevs:masterfrom
bugkeep:bugfix/7583-command-desc-tooltip
Open

fix(dashboard): show full command description#7815
bugkeep wants to merge 2 commits intoAstrBotDevs:masterfrom
bugkeep:bugfix/7583-command-desc-tooltip

Conversation

@bugkeep
Copy link
Copy Markdown
Contributor

@bugkeep bugkeep commented Apr 26, 2026

Fixes #7583.

  • Keep the ellipsis layout in the command list.
  • Add a native tooltip (title attribute) so truncated descriptions can be read on hover.

Summary by Sourcery

Bug Fixes:

  • Allow users to view full command descriptions via a tooltip when the text is truncated in the command list.

@auto-assign auto-assign Bot requested review from advent259141 and anka-afk April 26, 2026 07:18
@dosubot dosubot Bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Apr 26, 2026
Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey - I've left some high level feedback:

  • Consider omitting the title attribute when item.description is falsy (instead of showing '-' in the tooltip) so users don’t get a confusing tooltip that doesn’t add information beyond the placeholder text.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Consider omitting the `title` attribute when `item.description` is falsy (instead of showing `'-'` in the tooltip) so users don’t get a confusing tooltip that doesn’t add information beyond the placeholder text.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@dosubot dosubot Bot added the area:webui The bug / feature is about webui(dashboard) of astrbot. label Apr 26, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request adds a hover title to the description column in the CommandTable component to display the full text when it is truncated. The review feedback suggests replacing the native title attribute with Vuetify's v-tooltip for consistency with the rest of the application and recommends only showing the tooltip when a description is present to avoid displaying a redundant dash on hover.

Comment on lines +144 to 150
<div
class="text-body-2 text-medium-emphasis"
:title="item.description || '-'"
style="max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;"
>
{{ item.description || '-' }}
</div>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Using a native title attribute is inconsistent with the rest of the application, which utilizes Vuetify's v-tooltip component (e.g., in the actions column). v-tooltip provides a more polished user experience and consistent styling. Additionally, the tooltip should only be displayed when a description is present to avoid showing a redundant dash (-) on hover.

        <div
          class="text-body-2 text-medium-emphasis"
          style="max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;"
        >
          {{ item.description || '-' }}
          <v-tooltip
            v-if="item.description"
            activator="parent"
            location="top"
          >
            {{ item.description }}
          </v-tooltip>
        </div>

@dosubot dosubot Bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels Apr 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:webui The bug / feature is about webui(dashboard) of astrbot. size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Webui中超出显示长度的指令描述无法以任何方式看到

1 participant