2026-02-14 18:22:42 +01:00
|
|
|
.editor {
|
2026-02-15 10:34:59 +01:00
|
|
|
background: var(--bg-primary);
|
|
|
|
|
color: var(--text-primary);
|
2026-02-14 18:22:42 +01:00
|
|
|
display: flex;
|
2026-02-14 20:07:23 +01:00
|
|
|
flex-direction: column;
|
2026-02-14 18:22:42 +01:00
|
|
|
flex: 1;
|
|
|
|
|
min-width: 0;
|
2026-02-14 20:07:23 +01:00
|
|
|
overflow: hidden;
|
2026-02-14 18:22:42 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__placeholder {
|
2026-02-14 20:07:23 +01:00
|
|
|
display: flex;
|
2026-02-14 21:26:58 +01:00
|
|
|
flex-direction: column;
|
2026-02-14 20:07:23 +01:00
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
height: 100%;
|
2026-02-14 18:22:42 +01:00
|
|
|
text-align: center;
|
2026-02-15 10:34:59 +01:00
|
|
|
color: var(--text-muted);
|
2026-02-14 21:26:58 +01:00
|
|
|
gap: 8px;
|
2026-02-14 18:22:42 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__placeholder p {
|
2026-02-14 21:26:58 +01:00
|
|
|
margin: 0;
|
|
|
|
|
font-size: 15px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__placeholder-hint {
|
|
|
|
|
font-size: 12px;
|
2026-02-15 10:34:59 +01:00
|
|
|
color: var(--text-faint);
|
2026-02-14 18:22:42 +01:00
|
|
|
}
|
|
|
|
|
|
2026-02-15 10:00:29 +01:00
|
|
|
.editor__drag-strip {
|
|
|
|
|
height: 48px;
|
|
|
|
|
flex-shrink: 0;
|
|
|
|
|
-webkit-app-region: drag;
|
|
|
|
|
app-region: drag;
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-14 20:15:44 +01:00
|
|
|
/* Tab bar */
|
|
|
|
|
.editor__tab-bar {
|
|
|
|
|
display: flex;
|
2026-02-15 10:34:59 +01:00
|
|
|
background: var(--bg-card);
|
|
|
|
|
border-bottom: 1px solid var(--border-primary);
|
2026-02-14 20:15:44 +01:00
|
|
|
overflow-x: auto;
|
|
|
|
|
flex-shrink: 0;
|
2026-02-15 10:00:29 +01:00
|
|
|
-webkit-app-region: drag;
|
|
|
|
|
app-region: drag;
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab-bar::-webkit-scrollbar {
|
|
|
|
|
height: 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
gap: 6px;
|
2026-02-14 21:26:58 +01:00
|
|
|
padding: 7px 14px;
|
2026-02-14 20:15:44 +01:00
|
|
|
font-size: 12px;
|
2026-02-15 10:34:59 +01:00
|
|
|
color: var(--text-tertiary);
|
2026-02-14 20:15:44 +01:00
|
|
|
cursor: pointer;
|
2026-02-15 10:34:59 +01:00
|
|
|
border-right: 1px solid var(--border-primary);
|
2026-02-14 20:15:44 +01:00
|
|
|
white-space: nowrap;
|
|
|
|
|
max-width: 180px;
|
|
|
|
|
flex-shrink: 0;
|
2026-02-14 21:26:58 +01:00
|
|
|
transition: all 0.1s;
|
2026-02-15 10:00:29 +01:00
|
|
|
-webkit-app-region: no-drag;
|
|
|
|
|
app-region: no-drag;
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab:hover {
|
2026-02-15 10:34:59 +01:00
|
|
|
background: var(--bg-hover-subtle);
|
|
|
|
|
color: var(--text-secondary);
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab--active {
|
2026-02-15 10:34:59 +01:00
|
|
|
background: var(--bg-primary);
|
|
|
|
|
color: var(--text-primary);
|
|
|
|
|
border-bottom: 2px solid var(--accent-blue);
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab-title {
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
text-overflow: ellipsis;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab-close {
|
|
|
|
|
background: none;
|
|
|
|
|
border: none;
|
2026-02-15 10:34:59 +01:00
|
|
|
color: var(--text-muted);
|
2026-02-14 20:15:44 +01:00
|
|
|
cursor: pointer;
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
padding: 0 2px;
|
|
|
|
|
line-height: 1;
|
|
|
|
|
border-radius: 3px;
|
2026-02-14 21:26:58 +01:00
|
|
|
opacity: 0;
|
|
|
|
|
transition: opacity 0.1s;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab:hover .editor__tab-close,
|
|
|
|
|
.editor__tab--active .editor__tab-close {
|
|
|
|
|
opacity: 1;
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__tab-close:hover {
|
2026-02-15 10:34:59 +01:00
|
|
|
background: var(--bg-hover);
|
|
|
|
|
color: var(--text-primary);
|
2026-02-14 20:15:44 +01:00
|
|
|
}
|
|
|
|
|
|
2026-02-15 19:50:23 +01:00
|
|
|
/* Wikilink inline content */
|
|
|
|
|
.wikilink {
|
|
|
|
|
color: var(--accent-blue, #2196f3);
|
|
|
|
|
cursor: pointer;
|
|
|
|
|
text-decoration: underline;
|
|
|
|
|
text-decoration-style: dotted;
|
|
|
|
|
text-underline-offset: 2px;
|
|
|
|
|
border-radius: 2px;
|
|
|
|
|
padding: 0 1px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.wikilink:hover {
|
|
|
|
|
background: var(--accent-blue-bg, rgba(33, 150, 243, 0.1));
|
|
|
|
|
text-decoration-style: solid;
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-15 19:14:55 +01:00
|
|
|
/* BlockNote container */
|
|
|
|
|
.editor__blocknote-container {
|
2026-02-14 20:07:23 +01:00
|
|
|
flex: 1;
|
|
|
|
|
overflow: auto;
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-15 19:14:55 +01:00
|
|
|
.editor__blocknote-container .bn-container {
|
2026-02-14 20:07:23 +01:00
|
|
|
height: 100%;
|
2026-02-15 19:14:55 +01:00
|
|
|
background: var(--bg-primary);
|
|
|
|
|
color: var(--text-primary);
|
|
|
|
|
font-size: 15px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__blocknote-container .bn-editor {
|
|
|
|
|
padding: 20px 40px;
|
|
|
|
|
max-width: 760px;
|
2026-02-14 18:22:42 +01:00
|
|
|
}
|
2026-02-15 12:58:00 +01:00
|
|
|
|
|
|
|
|
/* Tab bar actions (diff toggle) */
|
|
|
|
|
.editor__tab-bar-actions {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
margin-left: auto;
|
|
|
|
|
padding: 0 8px;
|
|
|
|
|
-webkit-app-region: no-drag;
|
|
|
|
|
app-region: no-drag;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__diff-toggle {
|
|
|
|
|
padding: 3px 10px;
|
|
|
|
|
font-size: 11px;
|
|
|
|
|
border: 1px solid var(--border-primary);
|
|
|
|
|
border-radius: 4px;
|
|
|
|
|
background: transparent;
|
|
|
|
|
color: var(--text-tertiary);
|
|
|
|
|
cursor: pointer;
|
|
|
|
|
transition: all 0.15s;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__diff-toggle:hover {
|
|
|
|
|
background: var(--bg-button);
|
|
|
|
|
color: var(--text-secondary);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__diff-toggle--active {
|
|
|
|
|
background: var(--accent-blue-bg);
|
|
|
|
|
color: var(--accent-blue);
|
|
|
|
|
border-color: var(--accent-blue-bg);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.editor__diff-toggle:disabled {
|
|
|
|
|
opacity: 0.5;
|
|
|
|
|
cursor: default;
|
|
|
|
|
}
|
|
|
|
|
|
2026-02-15 19:14:55 +01:00
|
|
|
/* Diff view */
|
2026-02-15 12:58:00 +01:00
|
|
|
.editor__diff-container {
|
|
|
|
|
flex: 1;
|
|
|
|
|
overflow: auto;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view {
|
|
|
|
|
font-family: 'SF Mono', 'Menlo', 'Consolas', monospace;
|
|
|
|
|
font-size: 13px;
|
|
|
|
|
line-height: 1.6;
|
|
|
|
|
padding: 12px 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__empty {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
height: 100%;
|
|
|
|
|
color: var(--text-muted);
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line {
|
|
|
|
|
display: flex;
|
|
|
|
|
padding: 0 16px;
|
|
|
|
|
min-height: 22px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line-number {
|
|
|
|
|
width: 40px;
|
|
|
|
|
flex-shrink: 0;
|
|
|
|
|
text-align: right;
|
|
|
|
|
padding-right: 12px;
|
|
|
|
|
color: var(--text-faint);
|
|
|
|
|
user-select: none;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line-content {
|
|
|
|
|
flex: 1;
|
|
|
|
|
white-space: pre-wrap;
|
|
|
|
|
word-break: break-all;
|
|
|
|
|
padding: 0 8px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--added {
|
|
|
|
|
background: rgba(76, 175, 80, 0.12);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--added .diff-view__line-content {
|
|
|
|
|
color: #4caf50;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--removed {
|
|
|
|
|
background: rgba(244, 67, 54, 0.12);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--removed .diff-view__line-content {
|
|
|
|
|
color: #f44336;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--hunk {
|
|
|
|
|
background: rgba(33, 150, 243, 0.08);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--hunk .diff-view__line-content {
|
|
|
|
|
color: var(--accent-blue, #2196f3);
|
|
|
|
|
font-style: italic;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--header {
|
|
|
|
|
background: var(--bg-hover-subtle);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--header .diff-view__line-content {
|
|
|
|
|
color: var(--text-muted);
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.diff-view__line--context .diff-view__line-content {
|
|
|
|
|
color: var(--text-secondary);
|
|
|
|
|
}
|
2026-02-15 19:18:08 +01:00
|
|
|
|
|
|
|
|
/* =============================================
|
|
|
|
|
Bear-style live preview: zero horizontal shift
|
|
|
|
|
============================================= */
|
|
|
|
|
|
|
|
|
|
/* FIX 1: Remove header underlines */
|
|
|
|
|
.cm-heading-line {
|
|
|
|
|
border-bottom: none !important;
|
|
|
|
|
text-decoration: none !important;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* FIX 2: Heading markers in left gutter area
|
|
|
|
|
The ## markers are absolutely positioned in the content's left padding (40px),
|
|
|
|
|
so they never affect text flow — zero horizontal shift. */
|
|
|
|
|
.cm-heading-line {
|
|
|
|
|
position: relative;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cm-heading-line .cm-formatting-block {
|
|
|
|
|
position: absolute !important;
|
|
|
|
|
top: 50%;
|
|
|
|
|
transform: translateY(-50%);
|
|
|
|
|
right: 100%;
|
|
|
|
|
padding-right: 4px;
|
|
|
|
|
font-size: 0.75rem !important;
|
|
|
|
|
line-height: 1;
|
|
|
|
|
opacity: 0;
|
|
|
|
|
transition: opacity 0.15s ease-out !important;
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
pointer-events: none;
|
|
|
|
|
color: var(--text-faint);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cm-heading-line .cm-formatting-block.cm-formatting-block-visible {
|
|
|
|
|
font-size: 0.75rem !important;
|
|
|
|
|
opacity: 0.5;
|
|
|
|
|
pointer-events: auto;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* FIX 3: List/block bullets — always visible, fixed width, zero shift
|
|
|
|
|
Override the library's font-size animation so the marker always occupies
|
|
|
|
|
the same space regardless of cursor position. */
|
|
|
|
|
.cm-line:not(.cm-heading-line) .cm-formatting-block {
|
|
|
|
|
font-size: 1em !important;
|
|
|
|
|
display: inline-block !important;
|
|
|
|
|
min-width: 1.5em !important;
|
|
|
|
|
vertical-align: baseline;
|
|
|
|
|
transition: color 0.15s ease-out, opacity 0.15s ease-out !important;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* Inactive state: hide source text, show bullet dot via ::before */
|
|
|
|
|
.cm-line:not(.cm-heading-line) .cm-formatting-block:not(.cm-formatting-block-visible) {
|
|
|
|
|
color: transparent !important;
|
|
|
|
|
opacity: 1 !important;
|
|
|
|
|
position: relative;
|
|
|
|
|
overflow: visible !important;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.cm-line:not(.cm-heading-line) .cm-formatting-block:not(.cm-formatting-block-visible)::before {
|
|
|
|
|
content: '\2022';
|
|
|
|
|
position: absolute;
|
|
|
|
|
left: 0;
|
|
|
|
|
color: var(--text-tertiary);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* Active state: show source marker (-, *, +, etc.) */
|
|
|
|
|
.cm-line:not(.cm-heading-line) .cm-formatting-block.cm-formatting-block-visible {
|
|
|
|
|
color: var(--text-faint) !important;
|
|
|
|
|
opacity: 1 !important;
|
|
|
|
|
}
|