fix: address CodeRabbit review - Vue 3.5 props destructuring and a11y

- Fix inverted pluralization: use single i18n key with {count} param
- Fix text-bold → font-bold (valid Tailwind class) and class ordering
- Replace hardcoded 'Search...' default with i18n t('g.search')
- Remove unused itemSelected i18n key (merged into itemsSelected)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
dante01yoon
2026-03-11 17:31:50 +09:00
parent 202f7a0d16
commit e62ad9a238
2 changed files with 5 additions and 10 deletions

View File

@@ -89,7 +89,7 @@
/>
<ComboboxInput
v-model="searchQuery"
:placeholder="searchPlaceholder"
:placeholder="searchPlaceholder ?? t('g.search')"
class="w-full border-none bg-transparent text-sm outline-none"
/>
</div>
@@ -101,11 +101,7 @@
v-if="showSelectedCount"
class="px-1 text-sm text-base-foreground"
>
{{
selectedCount > 0
? $t('g.itemsSelected', { selectedCount })
: $t('g.itemSelected', { selectedCount })
}}
{{ $t('g.itemsSelected', { count: selectedCount }) }}
</span>
<Button
v-if="showClearButton"
@@ -147,7 +143,7 @@
>
<ComboboxItemIndicator>
<i
class="text-bold icon-[lucide--check] text-xs text-base-foreground"
class="icon-[lucide--check] text-xs font-bold text-base-foreground"
/>
</ComboboxItemIndicator>
</div>
@@ -198,7 +194,7 @@ const {
showSearchBox = false,
showSelectedCount = false,
showClearButton = false,
searchPlaceholder = 'Search...',
searchPlaceholder,
listMaxHeight = '28rem',
popoverMinWidth,
popoverMaxWidth

View File

@@ -256,8 +256,7 @@
"clearAll": "Clear all",
"copyURL": "Copy URL",
"releaseTitle": "{package} {version} Release",
"itemSelected": "{selectedCount} item selected",
"itemsSelected": "{selectedCount} items selected",
"itemsSelected": "{count} items selected",
"multiSelectDropdown": "Multi-select dropdown",
"singleSelectDropdown": "Single-select dropdown",
"progressCountOf": "of",