feat: refactorer le système de couleurs des notes avec palette unifiée pour thème clair/sombre, ajout de support pour images de fond, amélioration du popup de palette avec grille responsive et accessibilité, et correction du z-index et overflow pour permettre l'affichage correct des popups
This commit is contained in:
@@ -380,8 +380,9 @@ body.view-notes .content-container {
|
||||
/* Prevent split */
|
||||
position: relative;
|
||||
transition: box-shadow 0.2s, transform 0.2s, background-color 0.2s;
|
||||
overflow: hidden;
|
||||
/* for cover image */
|
||||
overflow: visible;
|
||||
/* allow palette popup to escape card bounds */
|
||||
color: var(--note-card-fg, #202124);
|
||||
}
|
||||
|
||||
/* Dark Mode Card */
|
||||
@@ -408,6 +409,11 @@ body.view-notes .content-container {
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.note-cover {
|
||||
overflow: hidden;
|
||||
border-radius: 8px 8px 0 0;
|
||||
}
|
||||
|
||||
/* Inner Content */
|
||||
.note-inner {
|
||||
padding: 12px 16px;
|
||||
@@ -483,6 +489,7 @@ body.view-notes .content-container {
|
||||
transition: opacity 0.2s;
|
||||
position: relative;
|
||||
/* For palette popup */
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
/* Show actions on hover */
|
||||
@@ -497,8 +504,9 @@ body.view-notes .content-container {
|
||||
}
|
||||
}
|
||||
|
||||
.note-hover-actions button,
|
||||
.note-hover-actions a {
|
||||
.note-hover-actions > button,
|
||||
.note-hover-actions > a,
|
||||
.note-hover-actions > div > button {
|
||||
background: none;
|
||||
border: none;
|
||||
width: 34px;
|
||||
@@ -515,19 +523,22 @@ body.view-notes .content-container {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-hover-actions button,
|
||||
[data-theme="dark"] .note-hover-actions a {
|
||||
[data-theme="dark"] .note-hover-actions > button,
|
||||
[data-theme="dark"] .note-hover-actions > a,
|
||||
[data-theme="dark"] .note-hover-actions > div > button {
|
||||
color: #9aa0a6;
|
||||
}
|
||||
|
||||
.note-hover-actions button:hover,
|
||||
.note-hover-actions a:hover {
|
||||
.note-hover-actions > button:hover,
|
||||
.note-hover-actions > a:hover,
|
||||
.note-hover-actions > div > button:hover {
|
||||
background-color: rgba(136, 136, 136, 0.2);
|
||||
color: var(--text-color);
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-hover-actions button:hover,
|
||||
[data-theme="dark"] .note-hover-actions a:hover {
|
||||
[data-theme="dark"] .note-hover-actions > button:hover,
|
||||
[data-theme="dark"] .note-hover-actions > a:hover,
|
||||
[data-theme="dark"] .note-hover-actions > div > button:hover {
|
||||
color: #e8eaed;
|
||||
}
|
||||
|
||||
@@ -549,181 +560,497 @@ body.view-notes .content-container {
|
||||
/* Reference: Keep Colors */
|
||||
/* Default */
|
||||
.note-card.note-color-default {
|
||||
background-color: var(--background-secondary, #ffffff);
|
||||
background-color: #20293a;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #dbe7ff;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-default {
|
||||
background-color: #202124;
|
||||
border-color: #5f6368;
|
||||
background-color: #20293a;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #dbe7ff;
|
||||
}
|
||||
|
||||
/* Red */
|
||||
.note-card.note-color-red {
|
||||
background-color: #f28b82;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1714;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-red {
|
||||
background-color: #5c2b29;
|
||||
border-color: #5c2b29;
|
||||
background-color: #f28b82;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1714;
|
||||
}
|
||||
|
||||
/* Orange */
|
||||
.note-card.note-color-orange {
|
||||
background-color: #fbbc04;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3d2a00;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-orange {
|
||||
background-color: #614a19;
|
||||
border-color: #614a19;
|
||||
background-color: #fbbc04;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3d2a00;
|
||||
}
|
||||
|
||||
/* Yellow */
|
||||
.note-card.note-color-yellow {
|
||||
background-color: #fff475;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #383100;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-yellow {
|
||||
background-color: #635d19;
|
||||
border-color: #635d19;
|
||||
background-color: #fff475;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #383100;
|
||||
}
|
||||
|
||||
/* Green */
|
||||
.note-card.note-color-green {
|
||||
background-color: #ccff90;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #203400;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-green {
|
||||
background-color: #345920;
|
||||
border-color: #345920;
|
||||
background-color: #ccff90;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #203400;
|
||||
}
|
||||
|
||||
/* Teal */
|
||||
.note-card.note-color-teal {
|
||||
background-color: #a7ffeb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #08342d;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-teal {
|
||||
background-color: #16504b;
|
||||
border-color: #16504b;
|
||||
background-color: #a7ffeb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #08342d;
|
||||
}
|
||||
|
||||
/* Blue */
|
||||
.note-card.note-color-blue {
|
||||
background-color: #cbf0f8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #113541;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-blue {
|
||||
background-color: #2d555e;
|
||||
border-color: #2d555e;
|
||||
background-color: #cbf0f8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #113541;
|
||||
}
|
||||
|
||||
/* Dark Blue */
|
||||
.note-card.note-color-darkblue {
|
||||
background-color: #aecbfa;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #102645;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-darkblue {
|
||||
background-color: #1e3a5f;
|
||||
border-color: #1e3a5f;
|
||||
background-color: #aecbfa;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #102645;
|
||||
}
|
||||
|
||||
/* Purple */
|
||||
.note-card.note-color-purple {
|
||||
background-color: #d7aefb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1845;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-purple {
|
||||
background-color: #42275e;
|
||||
border-color: #42275e;
|
||||
background-color: #d7aefb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1845;
|
||||
}
|
||||
|
||||
/* Pink */
|
||||
.note-card.note-color-pink {
|
||||
background-color: #fdcfe8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #4a1d34;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-pink {
|
||||
background-color: #5b2245;
|
||||
border-color: #5b2245;
|
||||
background-color: #fdcfe8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #4a1d34;
|
||||
}
|
||||
|
||||
/* Brown */
|
||||
.note-card.note-color-brown {
|
||||
background-color: #e6c9a8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3c2714;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-brown {
|
||||
background-color: #442f19;
|
||||
border-color: #442f19;
|
||||
background-color: #e6c9a8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3c2714;
|
||||
}
|
||||
|
||||
/* Grey */
|
||||
.note-card.note-color-grey {
|
||||
background-color: #e8eaed;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2a2d31;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-card.note-color-grey {
|
||||
background-color: #3c3f43;
|
||||
border-color: #3c3f43;
|
||||
background-color: #e8eaed;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2a2d31;
|
||||
}
|
||||
|
||||
.note-card.note-has-bg,
|
||||
.note-modal.note-has-bg,
|
||||
.link-outer.note-has-bg {
|
||||
background-image: linear-gradient(rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.16)), var(--note-bg-image);
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
}
|
||||
|
||||
.note-card .note-title,
|
||||
.note-card .note-body,
|
||||
.note-card .note-tag,
|
||||
.note-card .note-hover-actions button,
|
||||
.note-card .note-hover-actions a {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.note-card[class*="note-color-"] {
|
||||
color: var(--note-card-fg, #202124);
|
||||
}
|
||||
|
||||
.link-outer[class*="note-color-"] {
|
||||
color: var(--note-card-fg, #202124);
|
||||
}
|
||||
|
||||
.link-outer.note-color-default {
|
||||
background-color: #20293a;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #dbe7ff;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-default {
|
||||
background-color: #20293a;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #dbe7ff;
|
||||
}
|
||||
|
||||
.link-outer.note-color-red {
|
||||
background-color: #f28b82;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1714;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-red {
|
||||
background-color: #f28b82;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1714;
|
||||
}
|
||||
|
||||
.link-outer.note-color-orange {
|
||||
background-color: #fbbc04;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3d2a00;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-orange {
|
||||
background-color: #fbbc04;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3d2a00;
|
||||
}
|
||||
|
||||
.link-outer.note-color-yellow {
|
||||
background-color: #fff475;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #383100;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-yellow {
|
||||
background-color: #fff475;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #383100;
|
||||
}
|
||||
|
||||
.link-outer.note-color-green {
|
||||
background-color: #ccff90;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #203400;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-green {
|
||||
background-color: #ccff90;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #203400;
|
||||
}
|
||||
|
||||
.link-outer.note-color-teal {
|
||||
background-color: #a7ffeb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #08342d;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-teal {
|
||||
background-color: #a7ffeb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #08342d;
|
||||
}
|
||||
|
||||
.link-outer.note-color-blue {
|
||||
background-color: #cbf0f8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #113541;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-blue {
|
||||
background-color: #cbf0f8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #113541;
|
||||
}
|
||||
|
||||
.link-outer.note-color-darkblue {
|
||||
background-color: #aecbfa;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #102645;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-darkblue {
|
||||
background-color: #aecbfa;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #102645;
|
||||
}
|
||||
|
||||
.link-outer.note-color-purple {
|
||||
background-color: #d7aefb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1845;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-purple {
|
||||
background-color: #d7aefb;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2f1845;
|
||||
}
|
||||
|
||||
.link-outer.note-color-pink {
|
||||
background-color: #fdcfe8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #4a1d34;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-pink {
|
||||
background-color: #fdcfe8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #4a1d34;
|
||||
}
|
||||
|
||||
.link-outer.note-color-brown {
|
||||
background-color: #e6c9a8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3c2714;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-brown {
|
||||
background-color: #e6c9a8;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #3c2714;
|
||||
}
|
||||
|
||||
.link-outer.note-color-grey {
|
||||
background-color: #e8eaed;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2a2d31;
|
||||
}
|
||||
|
||||
[data-theme="dark"] .link-outer.note-color-grey {
|
||||
background-color: #e8eaed;
|
||||
border-color: transparent;
|
||||
--note-card-fg: #2a2d31;
|
||||
}
|
||||
|
||||
.link-outer[class*="note-color-"] .link-title,
|
||||
.link-outer[class*="note-color-"] .link-url,
|
||||
.link-outer[class*="note-color-"] .link-meta,
|
||||
.link-outer[class*="note-color-"] .link-description,
|
||||
.link-outer[class*="note-color-"] .link-tag a,
|
||||
.link-outer[class*="note-color-"] .link-actions a,
|
||||
.link-outer[class*="note-color-"] .link-actions button,
|
||||
.link-outer[class*="note-color-"] .bookmark-palette > button {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.link-actions .bookmark-palette {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.link-actions .bookmark-palette > button {
|
||||
background: none;
|
||||
border: none;
|
||||
width: 36px;
|
||||
height: 36px;
|
||||
border-radius: 0.5rem;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 0;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.link-actions .bookmark-palette > button i {
|
||||
font-size: 1.15rem;
|
||||
}
|
||||
|
||||
.link-actions .bookmark-palette > button:hover {
|
||||
background: rgba(255, 255, 255, 0.08);
|
||||
}
|
||||
|
||||
.link-actions .bookmark-palette .palette-popup {
|
||||
left: 0;
|
||||
right: auto;
|
||||
}
|
||||
|
||||
/* --- PALETTE POPUP --- */
|
||||
.palette-popup {
|
||||
position: absolute;
|
||||
bottom: 100%;
|
||||
left: 0;
|
||||
width: 320px;
|
||||
background: white;
|
||||
width: min(500px, 92vw);
|
||||
background: #1f232b;
|
||||
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
|
||||
border-radius: 4px;
|
||||
padding: 8px;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 4px;
|
||||
z-index: 100;
|
||||
border-radius: 12px;
|
||||
padding: 0;
|
||||
z-index: 5000;
|
||||
display: none;
|
||||
/* JS toggles this */
|
||||
}
|
||||
|
||||
[data-theme="dark"] .palette-popup {
|
||||
background: #202124;
|
||||
background: #1f232b;
|
||||
box-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
|
||||
border: 1px solid #5f6368;
|
||||
}
|
||||
|
||||
.palette-popup.open {
|
||||
display: flex;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.palette-popup.open-down {
|
||||
top: calc(100% + 8px);
|
||||
bottom: auto;
|
||||
}
|
||||
|
||||
.palette-btn {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
min-width: 32px;
|
||||
min-height: 32px;
|
||||
padding: 0;
|
||||
border-radius: 50%;
|
||||
border: 1px solid rgba(0, 0, 0, 0.1);
|
||||
border: 1px solid rgba(255, 255, 255, 0.18);
|
||||
cursor: pointer;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
flex: 0 0 auto;
|
||||
background-position: center;
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
.palette-btn:hover {
|
||||
border-color: #999;
|
||||
border-color: rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
|
||||
[data-theme="dark"] .palette-btn {
|
||||
border-color: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.palette-btn.is-active {
|
||||
outline: 2px solid #a855f7;
|
||||
outline-offset: 1px;
|
||||
}
|
||||
|
||||
.palette-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
padding: 10px 12px;
|
||||
overflow-x: auto;
|
||||
flex-wrap: nowrap;
|
||||
scrollbar-width: thin;
|
||||
}
|
||||
|
||||
.palette-row::-webkit-scrollbar {
|
||||
height: 6px;
|
||||
}
|
||||
|
||||
.palette-row::-webkit-scrollbar-thumb {
|
||||
background: rgba(255, 255, 255, 0.24);
|
||||
border-radius: 999px;
|
||||
}
|
||||
|
||||
.palette-row+.palette-row {
|
||||
border-top: 1px solid rgba(255, 255, 255, 0.14);
|
||||
}
|
||||
|
||||
.palette-btn-default,
|
||||
.palette-btn-bg-none {
|
||||
background: #2b313c;
|
||||
color: #d7dce5;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.palette-btn-default i,
|
||||
.palette-btn-bg-none i {
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
/* Prevent link action generic button rules from deforming swatches in bookmark palette */
|
||||
.link-actions .palette-popup .palette-btn {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
min-width: 32px;
|
||||
min-height: 32px;
|
||||
border-radius: 50%;
|
||||
padding: 0;
|
||||
background: transparent;
|
||||
border: 1px solid rgba(255, 255, 255, 0.18);
|
||||
background-position: center;
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
.link-actions .palette-popup .palette-btn:hover {
|
||||
background: transparent;
|
||||
border-color: rgba(255, 255, 255, 0.8);
|
||||
}
|
||||
|
||||
.link-outer.palette-open,
|
||||
.view-list .link-outer.palette-open,
|
||||
.view-compact .link-outer.palette-open {
|
||||
overflow: visible;
|
||||
z-index: 4000;
|
||||
content-visibility: visible;
|
||||
contain: none;
|
||||
contain-intrinsic-size: auto;
|
||||
}
|
||||
|
||||
/* --- MODAL FOR NOTE VIEW --- */
|
||||
.note-modal-overlay {
|
||||
position: fixed;
|
||||
@@ -748,40 +1075,301 @@ body.view-notes .content-container {
|
||||
}
|
||||
|
||||
.note-modal {
|
||||
background: var(--background-secondary, #fff);
|
||||
width: 600px;
|
||||
max-width: 90%;
|
||||
max-height: 90vh;
|
||||
border-radius: 8px;
|
||||
overflow-y: auto;
|
||||
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
|
||||
padding: 24px;
|
||||
background: var(--modal-note-bg, #7a4b00);
|
||||
color: var(--modal-note-fg, #fff2d9);
|
||||
width: min(720px, 92vw);
|
||||
max-height: 88vh;
|
||||
border-radius: 10px;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 12px 32px rgba(0, 0, 0, 0.42);
|
||||
position: relative;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
--note-scrollbar-thumb: rgba(255, 229, 170, 0.75);
|
||||
--note-separator: rgba(255, 230, 182, 0.22);
|
||||
--note-footer-bg: rgba(0, 0, 0, 0.14);
|
||||
}
|
||||
|
||||
.note-modal.note-color-default {
|
||||
--modal-note-bg: #20293a;
|
||||
--modal-note-fg: #dbe7ff;
|
||||
--note-scrollbar-thumb: rgba(219, 231, 255, 0.45);
|
||||
--note-separator: rgba(219, 231, 255, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.08);
|
||||
}
|
||||
|
||||
.note-modal.note-color-red {
|
||||
--modal-note-bg: #f28b82;
|
||||
--modal-note-fg: #2f1714;
|
||||
--note-scrollbar-thumb: rgba(47, 23, 20, 0.45);
|
||||
--note-separator: rgba(47, 23, 20, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.18);
|
||||
}
|
||||
|
||||
.note-modal.note-color-orange {
|
||||
--modal-note-bg: #fbbc04;
|
||||
--modal-note-fg: #3d2a00;
|
||||
--note-scrollbar-thumb: rgba(61, 42, 0, 0.45);
|
||||
--note-separator: rgba(61, 42, 0, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.note-modal.note-color-yellow {
|
||||
--modal-note-bg: #fff475;
|
||||
--modal-note-fg: #383100;
|
||||
--note-scrollbar-thumb: rgba(56, 49, 0, 0.45);
|
||||
--note-separator: rgba(56, 49, 0, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.24);
|
||||
}
|
||||
|
||||
.note-modal.note-color-green {
|
||||
--modal-note-bg: #ccff90;
|
||||
--modal-note-fg: #203400;
|
||||
--note-scrollbar-thumb: rgba(32, 52, 0, 0.45);
|
||||
--note-separator: rgba(32, 52, 0, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.22);
|
||||
}
|
||||
|
||||
.note-modal.note-color-teal {
|
||||
--modal-note-bg: #a7ffeb;
|
||||
--modal-note-fg: #08342d;
|
||||
--note-scrollbar-thumb: rgba(8, 52, 45, 0.45);
|
||||
--note-separator: rgba(8, 52, 45, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.22);
|
||||
}
|
||||
|
||||
.note-modal.note-color-blue {
|
||||
--modal-note-bg: #cbf0f8;
|
||||
--modal-note-fg: #113541;
|
||||
--note-scrollbar-thumb: rgba(17, 53, 65, 0.45);
|
||||
--note-separator: rgba(17, 53, 65, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.22);
|
||||
}
|
||||
|
||||
.note-modal.note-color-darkblue {
|
||||
--modal-note-bg: #aecbfa;
|
||||
--modal-note-fg: #102645;
|
||||
--note-scrollbar-thumb: rgba(16, 38, 69, 0.45);
|
||||
--note-separator: rgba(16, 38, 69, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.note-modal.note-color-purple {
|
||||
--modal-note-bg: #d7aefb;
|
||||
--modal-note-fg: #2f1845;
|
||||
--note-scrollbar-thumb: rgba(47, 24, 69, 0.45);
|
||||
--note-separator: rgba(47, 24, 69, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.note-modal.note-color-pink {
|
||||
--modal-note-bg: #fdcfe8;
|
||||
--modal-note-fg: #4a1d34;
|
||||
--note-scrollbar-thumb: rgba(74, 29, 52, 0.45);
|
||||
--note-separator: rgba(74, 29, 52, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.note-modal.note-color-brown {
|
||||
--modal-note-bg: #e6c9a8;
|
||||
--modal-note-fg: #3c2714;
|
||||
--note-scrollbar-thumb: rgba(60, 39, 20, 0.45);
|
||||
--note-separator: rgba(60, 39, 20, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
.note-modal.note-color-grey {
|
||||
--modal-note-bg: #e8eaed;
|
||||
--modal-note-fg: #2a2d31;
|
||||
--note-scrollbar-thumb: rgba(42, 45, 49, 0.45);
|
||||
--note-separator: rgba(42, 45, 49, 0.2);
|
||||
--note-footer-bg: rgba(255, 255, 255, 0.2);
|
||||
}
|
||||
|
||||
[data-theme="dark"] .note-modal {
|
||||
background: var(--bg-card);
|
||||
border: 1px solid var(--border);
|
||||
border: 1px solid 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.3rem;
|
||||
line-height: 1.5;
|
||||
margin-bottom: 16px;
|
||||
font-size: 1.6rem;
|
||||
line-height: 1.35;
|
||||
margin: 0;
|
||||
color: inherit;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.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;
|
||||
transition: background-color 0.2s, opacity 0.2s;
|
||||
}
|
||||
|
||||
.note-modal-pin-toggle i {
|
||||
font-size: 1.2rem;
|
||||
}
|
||||
|
||||
.note-modal-pin-toggle:hover,
|
||||
.note-modal-pin-toggle.active {
|
||||
opacity: 1;
|
||||
background-color: rgba(255, 255, 255, 0.14);
|
||||
}
|
||||
|
||||
.note-modal-content {
|
||||
flex: 1;
|
||||
overflow-y: auto;
|
||||
padding: 0 20px 18px;
|
||||
scrollbar-width: thin;
|
||||
scrollbar-color: var(--note-scrollbar-thumb) transparent;
|
||||
}
|
||||
|
||||
.note-modal-content::-webkit-scrollbar {
|
||||
width: 10px;
|
||||
}
|
||||
|
||||
.note-modal-content::-webkit-scrollbar-track {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.note-modal-content::-webkit-scrollbar-thumb {
|
||||
background: var(--note-scrollbar-thumb);
|
||||
border-radius: 10px;
|
||||
border: 2px solid transparent;
|
||||
background-clip: content-box;
|
||||
}
|
||||
|
||||
.note-modal .note-body {
|
||||
font-size: 1rem;
|
||||
line-height: 1.5;
|
||||
-webkit-line-clamp: unset;
|
||||
line-clamp: unset;
|
||||
line-height: 1.75;
|
||||
display: block;
|
||||
-webkit-line-clamp: initial;
|
||||
line-clamp: initial;
|
||||
-webkit-box-orient: initial;
|
||||
max-height: none;
|
||||
overflow: visible;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
/* Modal actions at bottom? */
|
||||
.note-modal-actions {
|
||||
margin-top: 24px;
|
||||
.note-modal .note-body * {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.note-modal-tags {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
flex-wrap: wrap;
|
||||
gap: 8px;
|
||||
padding: 10px 20px 12px;
|
||||
border-top: 1px solid var(--note-separator);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.note-modal-tags.is-empty {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.note-modal-tags .note-tag {
|
||||
background: rgba(255, 255, 255, 0.12);
|
||||
border: 1px solid rgba(255, 255, 255, 0.22);
|
||||
color: inherit;
|
||||
border-radius: 999px;
|
||||
padding: 4px 10px;
|
||||
font-size: 0.72rem;
|
||||
letter-spacing: 0.02em;
|
||||
}
|
||||
|
||||
.note-modal-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: 10px;
|
||||
padding: 8px 12px;
|
||||
border-top: 1px solid var(--note-separator);
|
||||
background: var(--note-footer-bg);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.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;
|
||||
transition: background-color 0.2s, opacity 0.2s;
|
||||
}
|
||||
|
||||
.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(255, 255, 255, 0.14);
|
||||
}
|
||||
|
||||
.note-modal-color-picker {
|
||||
position: relative;
|
||||
display: inline-flex;
|
||||
}
|
||||
|
||||
.note-modal-palette {
|
||||
left: -8px;
|
||||
bottom: calc(100% + 8px);
|
||||
width: min(500px, 92vw);
|
||||
}
|
||||
|
||||
.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(255, 255, 255, 0.14);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
.note-modal {
|
||||
width: 96vw;
|
||||
max-height: 92vh;
|
||||
}
|
||||
|
||||
.note-modal .note-title {
|
||||
font-size: 1.25rem;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user