Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/widget/nav/NavIcon.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<i :class="icon" class="text-neutral text-sm" />
<i :class="icon" class="text-neutral text-sm shrink-0" />
</template>

<script setup lang="ts">
Expand Down
10 changes: 6 additions & 4 deletions src/components/widget/nav/NavItem.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div
class="flex cursor-pointer items-center gap-2 rounded-md px-4 py-3 text-sm transition-colors text-base-foreground"
class="flex cursor-pointer items-start gap-2 rounded-md px-4 py-3 text-sm transition-colors text-base-foreground"
:class="
active
? 'bg-interface-menu-component-surface-selected'
Expand All @@ -9,9 +9,11 @@
role="button"
@click="onClick"
>
<NavIcon v-if="icon" :icon="icon" />
<i v-else class="text-neutral icon-[lucide--folder] text-xs" />
<span class="flex items-center">
<div v-if="icon" class="py-0.5">
<NavIcon :icon="icon" />
</div>
<i v-else class="text-neutral icon-[lucide--folder] text-xs shrink-0" />
<span class="flex items-center break-all">
Copy link
Contributor

Choose a reason for hiding this comment

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

🧹 Nitpick | 🔵 Trivial

Consider break-words for more natural text wrapping.

The break-all utility breaks text at any character, even mid-word, which can reduce readability. Consider using break-words instead, which only breaks when necessary and attempts to preserve whole words.

🔎 Proposed alternative using break-words
-    <span class="flex items-center break-all">
+    <span class="flex items-center break-words">
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<span class="flex items-center break-all">
<span class="flex items-center break-words">
🤖 Prompt for AI Agents
In @src/components/widget/nav/NavItem.vue at line 14, Replace the Tailwind
text-wrapping utility on the span in NavItem.vue: locate the <span class="flex
items-center break-all"> (in the NavItem component) and change the class from
break-all to break-words so text will wrap at word boundaries instead of
breaking mid-word; ensure no other code depends on the aggressive break behavior
and run the component visually to confirm layout remains acceptable.

<slot></slot>
</span>
</div>
Expand Down
Loading