From 925ad7b3e0e9365e4850b7dadbe3c805a6b71899 Mon Sep 17 00:00:00 2001 From: Will Miao <13051207myq@gmail.com> Date: Thu, 15 May 2025 05:36:56 +0800 Subject: [PATCH] Add user-select: none to prevent text selection on cards and control elements --- static/css/components/card.css | 19 +++++++++++++++++++ static/css/layout.css | 20 ++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/static/css/components/card.css b/static/css/components/card.css index 7555fc21..a3977703 100644 --- a/static/css/components/card.css +++ b/static/css/components/card.css @@ -359,6 +359,25 @@ font-size: 0.85em; } +/* Prevent text selection on cards and interactive elements */ +.lora-card, +.lora-card *, +.card-actions, +.card-actions i, +.toggle-blur-btn, +.show-content-btn, +.card-preview img, +.card-preview video, +.card-footer, +.card-header, +.model-name, +.base-model-label { + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + /* Recipe specific elements - migrated from recipe-card.css */ .recipe-indicator { position: absolute; diff --git a/static/css/layout.css b/static/css/layout.css index 195ff113..73b9cc3f 100644 --- a/static/css/layout.css +++ b/static/css/layout.css @@ -306,6 +306,26 @@ box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15); } +/* Prevent text selection in control and header areas */ +.tag, +.control-group button, +.control-group select, +.toggle-folders-btn, +.bulk-operations-panel, +.app-header, +.header-branding, +.app-title, +.main-nav, +.nav-item, +.header-actions button, +.header-controls, +.toggle-folders-container button { + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + @media (max-width: 768px) { .actions { flex-wrap: wrap;