Skip to content

Commit ba768c3

Browse files
viva-jinyiclaude
andauthored
fix: Prevent text selection in MediaAssetCard (#6708)
## Summary - Prevent text selection when clicking or dragging MediaAssetCard - Add `select-none` Tailwind class to prevent unwanted text highlighting ## Changes - Changed class from `gap-1` to `gap-1 select-none` in MediaAssetCard container ## Problem When users click or drag on a MediaAssetCard, the text content (tags, titles, descriptions, buttons) gets selected and highlighted, which creates a poor user experience. ## Solution Added the `select-none` Tailwind CSS class which applies `user-select: none` to prevent text selection within the card during mouse interactions. ## Test plan - [x] Click on MediaAssetCard and verify text is not selected - [x] Drag across MediaAssetCard and verify text is not highlighted - [x] Verify card selection still works properly - [x] Verify buttons and interactive elements still work 🤖 Generated with [Claude Code](https://claude.com/claude-code) ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-6708-fix-Prevent-text-selection-in-MediaAssetCard-2ac6d73d365081f6bec2ffebad7cb7ed) by [Unito](https://www.unito.io) Co-authored-by: Claude <noreply@anthropic.com>
1 parent e3f19ab commit ba768c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/platform/assets/components/MediaAssetCard.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ provide(MediaAssetKey, {
248248
249249
const containerClasses = computed(() =>
250250
cn(
251-
'gap-1',
251+
'gap-1 select-none',
252252
selected
253253
? 'border-3 border-zinc-900 dark-theme:border-white bg-zinc-200 dark-theme:bg-zinc-700'
254254
: 'hover:bg-zinc-100 dark-theme:hover:bg-zinc-800'

0 commit comments

Comments
 (0)