From 7e0ff872dfeddf3ac4a610e0b44a780b6d7c61c1 Mon Sep 17 00:00:00 2001 From: Bruno Charest Date: Mon, 16 Feb 2026 15:56:13 -0500 Subject: [PATCH] =?UTF-8?q?feat:=20ajouter=20une=20modale=20pour=20affiche?= =?UTF-8?q?r=20les=20notes=20en=20plein=20=C3=A9cran=20avec=20header,=20co?= =?UTF-8?q?ntenu=20scrollable,=20tags,=20actions=20(=C3=A9pingler,=20palet?= =?UTF-8?q?te=20de=20couleurs,=20=C3=A9diter,=20supprimer)=20et=20support?= =?UTF-8?q?=20th=C3=A8me=20clair/sombre?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- shaarli-pro/css/custom_views.css | 199 +++++++++++++++++++++++++++++++ 1 file changed, 199 insertions(+) diff --git a/shaarli-pro/css/custom_views.css b/shaarli-pro/css/custom_views.css index 6fac56a..ccdf911 100644 --- a/shaarli-pro/css/custom_views.css +++ b/shaarli-pro/css/custom_views.css @@ -368,6 +368,205 @@ body.view-notes .content-container { width: 100%; } +.note-modal-overlay { + position: fixed; + inset: 0; + display: none; + align-items: center; + justify-content: center; + padding: 24px; + background: rgba(0, 0, 0, 0.55); + z-index: 1000; +} + +.note-modal-overlay.open { + display: flex; +} + +.note-modal { + width: min(720px, 92vw); + max-height: 86vh; + overflow: hidden; + border-radius: 12px; + background: var(--background-secondary, #ffffff); + border: 1px solid rgba(0, 0, 0, 0.12); + color: inherit; + display: flex; + flex-direction: column; +} + +[data-theme="dark"] .note-modal { + background: #202124; + border-color: rgba(255, 255, 255, 0.12); +} + +.note-modal-header { + display: flex; + align-items: flex-start; + justify-content: space-between; + gap: 12px; + padding: 18px 20px 10px; + flex-shrink: 0; +} + +.note-modal .note-title { + font-size: 1.6rem; + line-height: 1.35; + margin: 0; + color: inherit; + font-weight: 500; +} + +.note-modal-content { + flex: 1; + overflow-y: auto; + padding: 0 20px 18px; +} + +.note-modal .note-body { + font-size: 1rem; + line-height: 1.75; + display: block; + -webkit-line-clamp: initial; + line-clamp: initial; + -webkit-box-orient: initial; + max-height: none; + overflow: visible; + color: inherit; +} + +.note-modal .note-body * { + color: inherit; +} + +.note-modal-tags { + display: flex; + flex-wrap: wrap; + gap: 8px; + padding: 10px 20px 12px; + border-top: 1px solid rgba(0, 0, 0, 0.12); + flex-shrink: 0; +} + +[data-theme="dark"] .note-modal-tags { + border-top-color: rgba(255, 255, 255, 0.12); +} + +.note-modal-tags.is-empty { + display: none; +} + +.note-modal-tags .note-tag { + background: rgba(0, 0, 0, 0.06); + border: 1px solid rgba(0, 0, 0, 0.14); + color: inherit; + border-radius: 999px; + padding: 4px 10px; + font-size: 0.72rem; + letter-spacing: 0.02em; +} + +[data-theme="dark"] .note-modal-tags .note-tag { + background: rgba(255, 255, 255, 0.12); + border-color: rgba(255, 255, 255, 0.22); +} + +.note-modal-actions { + display: flex; + align-items: center; + justify-content: space-between; + gap: 10px; + padding: 8px 12px; + border-top: 1px solid rgba(0, 0, 0, 0.12); + background: rgba(0, 0, 0, 0.03); + flex-shrink: 0; +} + +[data-theme="dark"] .note-modal-actions { + border-top-color: rgba(255, 255, 255, 0.12); + background: rgba(255, 255, 255, 0.06); +} + +.note-modal-actions-left { + display: flex; + align-items: center; + gap: 2px; + flex-wrap: wrap; +} + +.note-modal-actions-left > button, +.note-modal-actions-left > a, +.note-modal-actions-left > .note-modal-color-picker > button { + background: transparent; + border: none; + color: inherit; + opacity: 0.9; + width: 32px; + height: 32px; + border-radius: 50%; + display: inline-flex; + align-items: center; + justify-content: center; + cursor: pointer; + text-decoration: none; +} + +.note-modal-actions-left > button:hover, +.note-modal-actions-left > a:hover, +.note-modal-actions-left > .note-modal-color-picker > button:hover { + opacity: 1; + background: rgba(0, 0, 0, 0.08); +} + +[data-theme="dark"] .note-modal-actions-left > button:hover, +[data-theme="dark"] .note-modal-actions-left > a:hover, +[data-theme="dark"] .note-modal-actions-left > .note-modal-color-picker > button:hover { + background: rgba(255, 255, 255, 0.14); +} + +.note-modal-close-btn { + background: transparent; + border: none; + color: inherit; + font-weight: 600; + border-radius: 8px; + padding: 6px 10px; + cursor: pointer; +} + +.note-modal-close-btn:hover { + background: rgba(0, 0, 0, 0.08); +} + +[data-theme="dark"] .note-modal-close-btn:hover { + background: rgba(255, 255, 255, 0.14); +} + +.note-modal-pin-toggle { + background: transparent; + border: none; + color: inherit; + opacity: 0.85; + width: 34px; + height: 34px; + border-radius: 50%; + display: inline-flex; + align-items: center; + justify-content: center; + cursor: pointer; + flex-shrink: 0; +} + +.note-modal-pin-toggle:hover, +.note-modal-pin-toggle.active { + opacity: 1; + background-color: rgba(0, 0, 0, 0.08); +} + +[data-theme="dark"] .note-modal-pin-toggle:hover, +[data-theme="dark"] .note-modal-pin-toggle.active { + background-color: rgba(255, 255, 255, 0.14); +} /* --- CARD STYLING --- */ .note-card {