add multi-page notepad and memos toolbox tool
All checks were successful
Deploy Sokko G / deploy (push) Successful in 16s
All checks were successful
Deploy Sokko G / deploy (push) Successful in 16s
This commit is contained in:
parent
fcabbe8029
commit
6125336338
33 changed files with 3787 additions and 138 deletions
|
|
@ -55,6 +55,10 @@
|
|||
padding: var(--space-4);
|
||||
}
|
||||
|
||||
.library-tool-example[data-module-type="notepad"] .module-content {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.library-tool-example .image-annotation-stage,
|
||||
.library-tool-example .images-grid img {
|
||||
max-height: 260px;
|
||||
|
|
|
|||
|
|
@ -9,6 +9,16 @@
|
|||
-webkit-mask-image: url("/static/icons/notepad.svg");
|
||||
}
|
||||
|
||||
.ui-icon-memos {
|
||||
mask-image: url("/static/icons/memos.svg");
|
||||
-webkit-mask-image: url("/static/icons/memos.svg");
|
||||
}
|
||||
|
||||
.ui-icon-pages {
|
||||
mask-image: url("/static/icons/pages.svg");
|
||||
-webkit-mask-image: url("/static/icons/pages.svg");
|
||||
}
|
||||
|
||||
.ui-icon-checklist {
|
||||
mask-image: url("/static/icons/checklist.svg");
|
||||
-webkit-mask-image: url("/static/icons/checklist.svg");
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
@use "layout";
|
||||
@use "module-shell";
|
||||
@use "notepad";
|
||||
@use "memos";
|
||||
@use "drawing";
|
||||
@use "text-exchange";
|
||||
@use "checklist";
|
||||
|
|
|
|||
186
website/src/styles/toolboxes/_memos.scss
Normal file
186
website/src/styles/toolboxes/_memos.scss
Normal file
|
|
@ -0,0 +1,186 @@
|
|||
// Rôle : stylise l'outil Memos, ses post-it et sa bande déroulante.
|
||||
.memos-module {
|
||||
display: grid;
|
||||
gap: var(--space-3);
|
||||
padding: var(--space-4);
|
||||
}
|
||||
|
||||
.memos-toolbar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-3);
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.memos-add-button {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.memos-ticker-toggle {
|
||||
width: 40px;
|
||||
min-width: 40px;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.memos-ticker-toggle.active,
|
||||
.memo-card.is-drop-target {
|
||||
border-color: rgba(246, 196, 83, 0.48);
|
||||
background: rgba(246, 196, 83, 0.1);
|
||||
color: var(--color-accent-gold);
|
||||
}
|
||||
|
||||
.memos-ticker {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
border: 1px solid rgba(246, 196, 83, 0.22);
|
||||
border-radius: var(--radius-md);
|
||||
background: rgba(5, 7, 17, 0.56);
|
||||
}
|
||||
|
||||
.memos-ticker-track {
|
||||
display: flex;
|
||||
width: max-content;
|
||||
min-width: 100%;
|
||||
gap: calc(var(--space-6) * 3);
|
||||
padding: 8px 10px;
|
||||
animation: memos-ticker-scroll 24s linear infinite;
|
||||
}
|
||||
|
||||
.memos-ticker-item {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
color: var(--color-text-secondary);
|
||||
font-size: var(--font-size-sm);
|
||||
font-weight: 800;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.memos-ticker-item::before {
|
||||
content: "";
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-radius: 50%;
|
||||
background: var(--memo-color);
|
||||
box-shadow: 0 0 10px color-mix(in srgb, var(--memo-color) 42%, transparent);
|
||||
}
|
||||
|
||||
.memos-list {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
|
||||
gap: var(--space-3);
|
||||
}
|
||||
|
||||
.memo-card {
|
||||
position: relative;
|
||||
display: grid;
|
||||
gap: var(--space-2);
|
||||
min-height: 132px;
|
||||
padding: var(--space-3) var(--space-3) var(--space-3) 52px;
|
||||
border: 1px solid color-mix(in srgb, var(--memo-color) 42%, transparent);
|
||||
border-radius: var(--radius-md);
|
||||
background:
|
||||
linear-gradient(135deg, color-mix(in srgb, var(--memo-color) 18%, transparent), transparent 54%),
|
||||
rgba(5, 7, 17, 0.5);
|
||||
transition:
|
||||
border-color var(--duration-fast) var(--ease-standard),
|
||||
box-shadow var(--duration-fast) var(--ease-standard),
|
||||
opacity var(--duration-fast) var(--ease-standard);
|
||||
}
|
||||
|
||||
.memo-card textarea {
|
||||
width: 100%;
|
||||
min-height: 76px;
|
||||
resize: vertical;
|
||||
border: 0;
|
||||
background: transparent;
|
||||
color: var(--color-text-primary);
|
||||
font: inherit;
|
||||
line-height: 1.45;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.memo-card.is-dragging {
|
||||
opacity: 0.58;
|
||||
}
|
||||
|
||||
.memo-drag-handle {
|
||||
position: absolute;
|
||||
top: var(--space-3);
|
||||
left: var(--space-3);
|
||||
display: inline-grid;
|
||||
width: 34px;
|
||||
min-width: 34px;
|
||||
min-height: 34px;
|
||||
place-items: center;
|
||||
padding: 0;
|
||||
color: var(--color-text-muted);
|
||||
cursor: grab;
|
||||
touch-action: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.memo-drag-handle:active {
|
||||
cursor: grabbing;
|
||||
}
|
||||
|
||||
.memo-card footer {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.memo-color-menu {
|
||||
top: auto;
|
||||
bottom: calc(100% + 8px);
|
||||
transform: translate(-50%, 4px);
|
||||
}
|
||||
|
||||
.notepad-color-dropdown:hover .memo-color-menu,
|
||||
.notepad-color-dropdown:focus-within .memo-color-menu,
|
||||
.notepad-color-dropdown.is-open .memo-color-menu {
|
||||
transform: translate(-50%, 0);
|
||||
}
|
||||
|
||||
.memo-color-menu::after {
|
||||
top: 100%;
|
||||
bottom: auto;
|
||||
}
|
||||
|
||||
.memo-color-menu::before {
|
||||
top: 100%;
|
||||
bottom: auto;
|
||||
border-top: 7px solid rgba(10, 13, 28, 0.99);
|
||||
border-bottom: 0;
|
||||
}
|
||||
|
||||
.memo-delete-button {
|
||||
width: 34px;
|
||||
min-width: 34px;
|
||||
min-height: 34px;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.memos-empty {
|
||||
display: inline-flex;
|
||||
min-height: 118px;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 8px;
|
||||
border-style: dashed;
|
||||
color: var(--color-text-secondary);
|
||||
}
|
||||
|
||||
@keyframes memos-ticker-scroll {
|
||||
from {
|
||||
transform: translateX(0);
|
||||
}
|
||||
|
||||
to {
|
||||
transform: translateX(-50%);
|
||||
}
|
||||
}
|
||||
|
|
@ -207,6 +207,11 @@
|
|||
-webkit-mask-image: url("/static/icons/notepad.svg");
|
||||
}
|
||||
|
||||
.module-icon-memos {
|
||||
mask-image: url("/static/icons/memos.svg");
|
||||
-webkit-mask-image: url("/static/icons/memos.svg");
|
||||
}
|
||||
|
||||
.module-icon-checklist {
|
||||
mask-image: url("/static/icons/checklist.svg");
|
||||
-webkit-mask-image: url("/static/icons/checklist.svg");
|
||||
|
|
|
|||
|
|
@ -1,12 +1,193 @@
|
|||
// Rôle : gère la surface de bloc-notes riche et sa barre de formatage.
|
||||
// Rôle : gère la surface de Bloc Note riche, ses pages et sa barre de formatage.
|
||||
@use "../mixins";
|
||||
|
||||
.notepad-module {
|
||||
position: relative;
|
||||
display: grid;
|
||||
gap: var(--space-3);
|
||||
padding: var(--space-4);
|
||||
}
|
||||
|
||||
.notepad-pages-dropdown {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
bottom: auto;
|
||||
left: 0;
|
||||
z-index: 20;
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
pointer-events: auto;
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
|
||||
.notepad-pages-dropdown.is-open {
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
width: min(360px, calc(100% - var(--space-4)));
|
||||
height: auto;
|
||||
z-index: 65;
|
||||
transform: none;
|
||||
}
|
||||
|
||||
.notepad-pages-toggle {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
right: 0;
|
||||
z-index: 66;
|
||||
display: inline-grid;
|
||||
width: 40px;
|
||||
min-width: 40px;
|
||||
min-height: 40px;
|
||||
place-items: center;
|
||||
padding: 0;
|
||||
border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
|
||||
background: rgba(39, 18, 69, 0.86);
|
||||
color: var(--color-text-primary);
|
||||
transform: translateY(-50%);
|
||||
transition:
|
||||
border-color var(--duration-fast) var(--ease-standard),
|
||||
background-color var(--duration-fast) var(--ease-standard),
|
||||
color var(--duration-fast) var(--ease-standard),
|
||||
box-shadow var(--duration-fast) var(--ease-standard);
|
||||
}
|
||||
|
||||
.notepad-pages-toggle .ui-icon {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.notepad-pages-toggle:active {
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
|
||||
.notepad-pages-toggle:hover,
|
||||
.notepad-pages-toggle.active {
|
||||
border-color: rgba(246, 196, 83, 0.44);
|
||||
background: rgba(56, 28, 92, 0.94);
|
||||
color: var(--color-accent-gold);
|
||||
}
|
||||
|
||||
.notepad-pages-menu {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
z-index: 64;
|
||||
display: grid;
|
||||
grid-template-rows: minmax(0, 1fr) auto;
|
||||
width: calc(100% - 40px);
|
||||
gap: var(--space-2);
|
||||
overflow: hidden;
|
||||
padding: var(--space-3);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--radius-md);
|
||||
background: rgba(10, 13, 28, 0.98);
|
||||
box-shadow: var(--shadow-lg);
|
||||
animation: notepad-pages-slide-in var(--duration-normal) var(--ease-standard);
|
||||
pointer-events: auto;
|
||||
}
|
||||
|
||||
.notepad-pages-list {
|
||||
display: grid;
|
||||
align-content: start;
|
||||
gap: 6px;
|
||||
min-height: 0;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.notepad-page-row {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
gap: 6px;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.notepad-page-main {
|
||||
min-width: 0;
|
||||
overflow: hidden;
|
||||
border: 1px solid rgba(150, 165, 205, 0.12);
|
||||
border-radius: var(--radius-sm);
|
||||
background: rgba(5, 7, 17, 0.36);
|
||||
}
|
||||
|
||||
.notepad-page-row:hover .notepad-page-main,
|
||||
.notepad-page-row:focus-within .notepad-page-main {
|
||||
border-color: rgba(150, 165, 205, 0.24);
|
||||
background: rgba(5, 7, 17, 0.5);
|
||||
}
|
||||
|
||||
.notepad-page-row.active .notepad-page-main {
|
||||
border-color: rgba(246, 196, 83, 0.42);
|
||||
background: rgba(246, 196, 83, 0.08);
|
||||
}
|
||||
|
||||
.notepad-page-select {
|
||||
width: 100%;
|
||||
min-height: 32px;
|
||||
justify-content: flex-start;
|
||||
overflow: hidden;
|
||||
padding: 0 8px;
|
||||
border-color: transparent;
|
||||
background: transparent;
|
||||
color: var(--color-text-primary);
|
||||
font-size: var(--font-size-sm);
|
||||
font-weight: 900;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.notepad-page-title-input {
|
||||
width: 100%;
|
||||
min-width: 0;
|
||||
min-height: 32px;
|
||||
padding: 0 8px;
|
||||
border: 1px solid rgba(150, 165, 205, 0.14);
|
||||
border-radius: var(--radius-sm);
|
||||
background: rgba(7, 10, 24, 0.72);
|
||||
color: var(--color-text-primary);
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
.notepad-page-actions {
|
||||
display: flex;
|
||||
gap: 4px;
|
||||
}
|
||||
|
||||
.notepad-page-edit,
|
||||
.notepad-page-delete {
|
||||
width: 28px;
|
||||
min-width: 28px;
|
||||
min-height: 28px;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.notepad-page-edit .ui-icon,
|
||||
.notepad-page-delete .ui-icon {
|
||||
width: 14px;
|
||||
height: 14px;
|
||||
}
|
||||
|
||||
@keyframes notepad-pages-slide-in {
|
||||
from {
|
||||
opacity: 0;
|
||||
transform: translateX(-14px);
|
||||
}
|
||||
|
||||
to {
|
||||
opacity: 1;
|
||||
transform: translateX(0);
|
||||
}
|
||||
}
|
||||
|
||||
.notepad-page-add {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 8px;
|
||||
min-height: 36px;
|
||||
align-self: end;
|
||||
}
|
||||
|
||||
.notepad-toolbar,
|
||||
.notepad-toolbar-group,
|
||||
.notepad-format-controls {
|
||||
|
|
@ -361,6 +542,7 @@
|
|||
.notepad-editor {
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
box-sizing: border-box;
|
||||
min-height: 260px;
|
||||
padding: var(--space-4);
|
||||
color: var(--color-text-primary);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue