diff --git a/CLAUDE.md b/CLAUDE.md index 37f7c84..45da5bf 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -104,3 +104,41 @@ see the updated count and skip the second notification. `notifications.store.ts` stores muted folders in `localStorage` (`muted-folders` key). Mute is per `accountId:folderId`, supports duration (ms) or permanent (`null`). Mute check walks up the folder parent chain — muting a parent silences all children. + +## Design system (Liquid Glass / Material 3) — `:global()` scoped-CSS gotcha + +`settings.store.ts` has `designSystem: 'liquid-glass' | 'material3'`, toggled in Settings +("Дизайн"). It sets `document.documentElement.dataset.design`, and `material3-theme.ts` +generates the full M3 color-role set (`--md-sys-color-*`) from a seed color via +`@material/material-color-utilities` (HCT/dynamic color, dark scheme only). +`material3-tokens.css` holds the static tokens (typescale/shape/elevation/motion) and remaps +the app's shared aliases (`--accent`, `--text-*`, `--radius-*`, `--glass-*`, `--shadow-*`) to +M3 roles, plus force-kills every `backdrop-filter` under `html[data-design='material3']`. + +Per-component M3 overrides live at the bottom of each component's own ` @@ -381,4 +413,40 @@ onUnmounted(() => document.removeEventListener('mousedown', onDocClick)) inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent); } + +/* ── Material 3 ── */ +html[data-design='material3'] .cp-panel { + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-medium); + box-shadow: var(--md-sys-elevation-2); +} + +html[data-design='material3'] .cp-sb { + box-shadow: inset 0 0 0 1px var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-extra-small); +} + +html[data-design='material3'] .cp-hue { + border-radius: var(--md-sys-shape-corner-full); + box-shadow: inset 0 0 0 1px var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .cp-preview { + border: 1.5px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} + +html[data-design='material3'] .cp-hex-input { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + border-radius: var(--md-sys-shape-corner-small); + color: var(--md-sys-color-on-surface); + box-shadow: none; +} + +html[data-design='material3'] .cp-hex-input:focus { + border-color: var(--md-sys-color-primary); + box-shadow: 0 0 0 1px var(--md-sys-color-primary); +} diff --git a/src/renderer/src/components/CustomSelect.vue b/src/renderer/src/components/CustomSelect.vue index 7495916..d6e5603 100644 --- a/src/renderer/src/components/CustomSelect.vue +++ b/src/renderer/src/components/CustomSelect.vue @@ -157,6 +157,30 @@ onUnmounted(() => document.removeEventListener('mousedown', onDocClick)) .select-arrow.rotated { transform: rotate(180deg); } + +/* ── Material 3 (Text field trigger) ── */ +html[data-design='material3'] .select-trigger { + border-radius: var(--md-sys-shape-corner-small); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + box-shadow: none; + font-size: var(--md-sys-typescale-body-large-size); +} + +html[data-design='material3'] .select-trigger:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-highest)); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .open .select-trigger { + border-color: var(--md-sys-color-primary); + box-shadow: 0 0 0 1px var(--md-sys-color-primary); +} + +html[data-design='material3'] .select-arrow { + color: var(--md-sys-color-on-surface-variant); +} @@ -208,4 +232,31 @@ onUnmounted(() => document.removeEventListener('mousedown', onDocClick)) justify-content: center; color: var(--accent); } + +/* ── Material 3 (Menu) ── */ +html[data-design='material3'] .select-dropdown { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-small); + box-shadow: var(--md-sys-elevation-2); +} + +html[data-design='material3'] .select-option { + border-radius: var(--md-sys-shape-corner-extra-small); + font-size: var(--md-sys-typescale-body-medium-size); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .select-option:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .select-option.active { + color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .option-check { + color: var(--md-sys-color-primary); +} diff --git a/src/renderer/src/components/Switch.vue b/src/renderer/src/components/Switch.vue new file mode 100644 index 0000000..8ccb067 --- /dev/null +++ b/src/renderer/src/components/Switch.vue @@ -0,0 +1,97 @@ + + + + + + + diff --git a/src/renderer/src/components/UpdateBanner.vue b/src/renderer/src/components/UpdateBanner.vue index c3b9134..38bf3e6 100644 --- a/src/renderer/src/components/UpdateBanner.vue +++ b/src/renderer/src/components/UpdateBanner.vue @@ -176,4 +176,54 @@ const updater = useUpdaterStore() opacity: 0; transform: translateX(-50%) translateY(12px); } + +/* ── Material 3 ── */ +html[data-design='material3'] .banner-body { + background: var(--md-sys-color-primary-container); + border: none; + border-radius: var(--md-sys-shape-corner-extra-small); + box-shadow: var(--md-sys-elevation-2); +} + +html[data-design='material3'] .banner-icon { + color: var(--md-sys-color-on-primary-container); +} + +html[data-design='material3'] .banner-title { + color: var(--md-sys-color-on-primary-container); + font-size: var(--md-sys-typescale-title-small-size); + font-weight: var(--md-sys-typescale-title-small-weight); +} + +html[data-design='material3'] .banner-sub { + color: color-mix(in srgb, var(--md-sys-color-on-primary-container) 75%, transparent); + font-size: var(--md-sys-typescale-body-small-size); +} + +html[data-design='material3'] .banner-progress-wrap { + background: color-mix(in srgb, var(--md-sys-color-on-primary-container) 20%, transparent); + border-radius: 0 0 var(--md-sys-shape-corner-extra-small) var(--md-sys-shape-corner-extra-small); +} + +html[data-design='material3'] .banner-progress-bar { + background: var(--md-sys-color-primary); + border-radius: 0 0 var(--md-sys-shape-corner-extra-small) var(--md-sys-shape-corner-extra-small); +} + +html[data-design='material3'] .btn-primary { + background: var(--md-sys-color-primary); + color: var(--md-sys-color-on-primary); + border-radius: var(--md-sys-shape-corner-full); + font-size: var(--md-sys-typescale-label-large-size); + font-weight: var(--md-sys-typescale-label-large-weight); +} + +html[data-design='material3'] .btn-dismiss { + color: var(--md-sys-color-on-primary-container); +} + +html[data-design='material3'] .btn-dismiss:hover { + background: color-mix(in srgb, var(--md-sys-color-on-primary-container) 12%, transparent); + color: var(--md-sys-color-on-primary-container); +} diff --git a/src/renderer/src/components/accounts/AddAccountDialog.vue b/src/renderer/src/components/accounts/AddAccountDialog.vue index 13a9de4..fb630b3 100644 --- a/src/renderer/src/components/accounts/AddAccountDialog.vue +++ b/src/renderer/src/components/accounts/AddAccountDialog.vue @@ -888,4 +888,244 @@ const providerName = computed(() => detectedPreset.value?.name ?? 'IMAP') color: var(--text-muted); margin: 0; } + +/* ══════════════════════════════════════════════════════════════════════════ + Material Design 3 — переопределения (активны только под data-design=material3) + ══════════════════════════════════════════════════════════════════════════ */ + +/* Overlay — скрим вместо стеклянного затемнения */ +html[data-design='material3'] .dialog-overlay { + background: color-mix(in srgb, var(--md-sys-color-scrim) 32%, transparent); +} + +/* Модальный диалог — elevation-3, extra-large shape, surface-container-high */ +html[data-design='material3'] .dialog { + background: var(--md-sys-color-surface-container-high); + border-radius: var(--md-sys-shape-corner-extra-large); + box-shadow: var(--md-sys-elevation-3); +} + +html[data-design='material3'] .dialog::before { + display: none; +} + +html[data-design='material3'] .dialog-header { + background: transparent; + border-bottom: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .header-avatar { + background: var(--md-sys-color-primary-container); + border: none; + box-shadow: none; + color: var(--md-sys-color-on-primary-container); +} + +/* Заголовок диалога — headline-small согласно контракту */ +html[data-design='material3'] .header-text h2 { + font-size: var(--md-sys-typescale-headline-small-size); + line-height: var(--md-sys-typescale-headline-small-line); + font-weight: var(--md-sys-typescale-headline-small-weight); + letter-spacing: var(--md-sys-typescale-headline-small-tracking); +} + +html[data-design='material3'] .close-btn { + background: transparent; + border: none; + box-shadow: none; + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .close-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .dialog-body { + scrollbar-color: var(--md-sys-color-outline-variant) transparent; +} + +/* Предупреждение о keychain — тонированный tertiary (у M3 нет отдельной warning-роли) */ +html[data-design='material3'] .warn-msg { + background: var(--md-sys-color-tertiary-container); + border: 1px solid transparent; + color: var(--md-sys-color-on-tertiary-container); +} + +html[data-design='material3'] .error-msg { + background: var(--md-sys-color-error-container); + border: 1px solid transparent; + color: var(--md-sys-color-on-error-container); +} + +/* Подписи полей формы — body-small согласно контракту */ +html[data-design='material3'] .form-group label:not(.checkbox-label):not(.toggle-switch) { + color: var(--md-sys-color-on-surface-variant); + font-size: var(--md-sys-typescale-body-small-size); + line-height: var(--md-sys-typescale-body-small-line); + font-weight: var(--md-sys-typescale-body-small-weight); + letter-spacing: var(--md-sys-typescale-body-small-tracking); + text-transform: none; +} + +/* Текстовые поля — Outlined text field, shape small */ +html[data-design='material3'] .form-group input[type="text"], +html[data-design='material3'] .form-group input[type="password"], +html[data-design='material3'] .form-group input[type="number"] { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + border-top-color: var(--md-sys-color-outline); + color: var(--md-sys-color-on-surface); + box-shadow: none; + border-radius: var(--md-sys-shape-corner-small); +} + +html[data-design='material3'] .form-group input:focus { + background: var(--md-sys-color-surface-container-highest); + border-color: var(--md-sys-color-primary); + border-top-color: var(--md-sys-color-primary); + box-shadow: 0 0 0 1px var(--md-sys-color-primary); +} + +html[data-design='material3'] .section-sep::before, +html[data-design='material3'] .section-sep::after { + background: var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .section-label-text { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + font-weight: var(--md-sys-typescale-label-small-weight); + letter-spacing: var(--md-sys-typescale-label-small-tracking); + color: var(--md-sys-color-on-surface-variant); + text-transform: none; +} + +/* Переключатель SSL/TLS */ +html[data-design='material3'] .toggle-track { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .toggle-track::after { + background: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .toggle-switch input:checked + .toggle-track { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); + box-shadow: none; +} + +html[data-design='material3'] .toggle-switch input:checked + .toggle-track::after { + background: var(--md-sys-color-on-primary); +} + +/* Чекбокс "самоподписанные сертификаты" */ +html[data-design='material3'] .checkbox-label { + font-size: var(--md-sys-typescale-body-small-size); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"] { + background: transparent; + border: 2px solid var(--md-sys-color-outline); + border-top-color: var(--md-sys-color-outline); + box-shadow: none; + border-radius: var(--md-sys-shape-corner-extra-small); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"]:checked { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"]:checked::after { + border-color: var(--md-sys-color-on-primary); + border-top: none; + border-left: none; +} + +/* Кнопка отправки формы — Filled button, полная форма, label-large */ +html[data-design='material3'] .submit-btn { + border-radius: var(--md-sys-shape-corner-full); + font-size: var(--md-sys-typescale-label-large-size); + font-weight: var(--md-sys-typescale-label-large-weight); + letter-spacing: var(--md-sys-typescale-label-large-tracking); + box-shadow: none; +} + +html[data-design='material3'] .submit-btn:hover:not(:disabled) { + box-shadow: var(--md-sys-elevation-1); +} + +/* Проверка подключения — строки статусов через контейнерные роли */ +html[data-design='material3'] .check-row { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-medium); +} + +html[data-design='material3'] .check-row.ok { + background: var(--md-sys-color-tertiary-container); + border-color: transparent; +} + +html[data-design='material3'] .check-row.ok .check-label, +html[data-design='material3'] .check-row.ok .check-detail { + color: var(--md-sys-color-on-tertiary-container); +} + +html[data-design='material3'] .check-row.error { + background: var(--md-sys-color-error-container); + border-color: transparent; +} + +html[data-design='material3'] .check-row.error .check-label, +html[data-design='material3'] .check-row.error .check-detail { + color: var(--md-sys-color-on-error-container); +} + +html[data-design='material3'] .check-icon { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .check-spinner { + border: 2px solid var(--md-sys-color-outline-variant); + border-top-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .check-idle { + background: var(--md-sys-color-outline-variant); +} + +/* Экран успеха */ +html[data-design='material3'] .success-check { + background: var(--md-sys-color-primary-container); + border: none; + box-shadow: none; + color: var(--md-sys-color-on-primary-container); +} + +html[data-design='material3'] .success-title { + font-size: var(--md-sys-typescale-title-medium-size); + line-height: var(--md-sys-typescale-title-medium-line); + font-weight: var(--md-sys-typescale-title-medium-weight); + letter-spacing: var(--md-sys-typescale-title-medium-tracking); +} + +html[data-design='material3'] .success-account { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-medium); +} + +html[data-design='material3'] .success-avatar { + background: var(--md-sys-color-primary-container); + border: none; + color: var(--md-sys-color-on-primary-container); +} diff --git a/src/renderer/src/components/accounts/EditAccountDialog.vue b/src/renderer/src/components/accounts/EditAccountDialog.vue index efdea39..82b1626 100644 --- a/src/renderer/src/components/accounts/EditAccountDialog.vue +++ b/src/renderer/src/components/accounts/EditAccountDialog.vue @@ -693,4 +693,219 @@ const isFormValid = computed(() => email.value.trim() && imapHost.value && smtpH .check-label { font-size: 13px; font-weight: 600; color: var(--text-primary); } .check-detail { font-size: 11px; color: var(--text-muted); font-family: var(--font-mono); } + +/* ══════════════════════════════════════════════════════════════════════════ + Material Design 3 — переопределения (активны только под data-design=material3) + ══════════════════════════════════════════════════════════════════════════ */ + +/* Overlay — скрим вместо стеклянного затемнения */ +html[data-design='material3'] .dialog-overlay { + background: color-mix(in srgb, var(--md-sys-color-scrim) 32%, transparent); +} + +/* Модальный диалог — elevation-3, extra-large shape, surface-container-high */ +html[data-design='material3'] .dialog { + background: var(--md-sys-color-surface-container-high); + border-radius: var(--md-sys-shape-corner-extra-large); + box-shadow: var(--md-sys-elevation-3); +} + +html[data-design='material3'] .dialog::before { + display: none; +} + +html[data-design='material3'] .dialog-header { + background: transparent; + border-bottom: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .header-avatar { + background: var(--md-sys-color-primary-container); + border: none; + box-shadow: none; + color: var(--md-sys-color-on-primary-container); +} + +/* Заголовок диалога — headline-small согласно контракту */ +html[data-design='material3'] .header-text h2 { + font-size: var(--md-sys-typescale-headline-small-size); + line-height: var(--md-sys-typescale-headline-small-line); + font-weight: var(--md-sys-typescale-headline-small-weight); + letter-spacing: var(--md-sys-typescale-headline-small-tracking); +} + +html[data-design='material3'] .header-sub { + font-size: var(--md-sys-typescale-body-small-size); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .close-btn { + background: transparent; + border: none; + box-shadow: none; + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .close-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .dialog-body { + scrollbar-color: var(--md-sys-color-outline-variant) transparent; +} + +html[data-design='material3'] .error-msg { + background: var(--md-sys-color-error-container); + border: 1px solid transparent; + color: var(--md-sys-color-on-error-container); +} + +/* Подписи полей формы — body-small согласно контракту */ +html[data-design='material3'] .form-group label:not(.checkbox-label):not(.toggle-switch) { + color: var(--md-sys-color-on-surface-variant); + font-size: var(--md-sys-typescale-body-small-size); + line-height: var(--md-sys-typescale-body-small-line); + font-weight: var(--md-sys-typescale-body-small-weight); + letter-spacing: var(--md-sys-typescale-body-small-tracking); + text-transform: none; +} + +html[data-design='material3'] .field-hint { + color: var(--md-sys-color-on-surface-variant); +} + +/* Текстовые поля — Outlined text field, shape small */ +html[data-design='material3'] .form-group input[type="text"], +html[data-design='material3'] .form-group input[type="password"], +html[data-design='material3'] .form-group input[type="number"] { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + border-top-color: var(--md-sys-color-outline); + color: var(--md-sys-color-on-surface); + box-shadow: none; + border-radius: var(--md-sys-shape-corner-small); +} + +html[data-design='material3'] .form-group input:focus { + background: var(--md-sys-color-surface-container-highest); + border-color: var(--md-sys-color-primary); + border-top-color: var(--md-sys-color-primary); + box-shadow: 0 0 0 1px var(--md-sys-color-primary); +} + +html[data-design='material3'] .section-sep::before, +html[data-design='material3'] .section-sep::after { + background: var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .section-label-text { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + font-weight: var(--md-sys-typescale-label-small-weight); + letter-spacing: var(--md-sys-typescale-label-small-tracking); + color: var(--md-sys-color-on-surface-variant); + text-transform: none; +} + +/* Переключатель SSL/TLS */ +html[data-design='material3'] .toggle-track { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .toggle-track::after { + background: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .toggle-switch input:checked + .toggle-track { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); + box-shadow: none; +} + +html[data-design='material3'] .toggle-switch input:checked + .toggle-track::after { + background: var(--md-sys-color-on-primary); +} + +/* Чекбокс "самоподписанные сертификаты" */ +html[data-design='material3'] .checkbox-label { + font-size: var(--md-sys-typescale-body-small-size); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"] { + background: transparent; + border: 2px solid var(--md-sys-color-outline); + border-top-color: var(--md-sys-color-outline); + box-shadow: none; + border-radius: var(--md-sys-shape-corner-extra-small); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"]:checked { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .checkbox-label input[type="checkbox"]:checked::after { + border-color: var(--md-sys-color-on-primary); + border-top: none; + border-left: none; +} + +/* Кнопка сохранения — Filled button, полная форма, label-large */ +html[data-design='material3'] .submit-btn { + border-radius: var(--md-sys-shape-corner-full); + font-size: var(--md-sys-typescale-label-large-size); + font-weight: var(--md-sys-typescale-label-large-weight); + letter-spacing: var(--md-sys-typescale-label-large-tracking); + box-shadow: none; +} + +html[data-design='material3'] .submit-btn:hover:not(:disabled) { + box-shadow: var(--md-sys-elevation-1); +} + +/* Проверка подключения — строки статусов через контейнерные роли */ +html[data-design='material3'] .check-row { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-medium); +} + +html[data-design='material3'] .check-row.ok { + background: var(--md-sys-color-tertiary-container); + border-color: transparent; +} + +html[data-design='material3'] .check-row.ok .check-label, +html[data-design='material3'] .check-row.ok .check-detail { + color: var(--md-sys-color-on-tertiary-container); +} + +html[data-design='material3'] .check-row.error { + background: var(--md-sys-color-error-container); + border-color: transparent; +} + +html[data-design='material3'] .check-row.error .check-label, +html[data-design='material3'] .check-row.error .check-detail { + color: var(--md-sys-color-on-error-container); +} + +html[data-design='material3'] .check-icon { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .check-spinner { + border: 2px solid var(--md-sys-color-outline-variant); + border-top-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .check-idle { + background: var(--md-sys-color-outline-variant); +} diff --git a/src/renderer/src/components/calendar/EventBlock.vue b/src/renderer/src/components/calendar/EventBlock.vue index 32669da..48f36b0 100644 --- a/src/renderer/src/components/calendar/EventBlock.vue +++ b/src/renderer/src/components/calendar/EventBlock.vue @@ -198,4 +198,56 @@ const statusClass = computed(() => { color: var(--ev-color); opacity: 0.7; } + +/* ── Material 3 ── */ +/* Компактные блоки (< 45 мин) — small shape, обычные — medium (M3: событие как маленькая карточка) */ +html[data-design='material3'] .event-block { + border-radius: var(--md-sys-shape-corner-small); + background: color-mix(in srgb, var(--ev-color) 22%, var(--md-sys-color-surface-container-high)); + border: 1px solid color-mix(in srgb, var(--ev-color) 40%, var(--md-sys-color-outline-variant)); + border-top-color: color-mix(in srgb, var(--ev-color) 40%, var(--md-sys-color-outline-variant)); + box-shadow: none; +} + +html[data-design='material3'] .event-block:not(.event-short) { + border-radius: var(--md-sys-shape-corner-medium); +} + +html[data-design='material3'] .event-block::before { + border-radius: var(--md-sys-shape-corner-small) 0 0 var(--md-sys-shape-corner-small); +} + +html[data-design='material3'] .event-block:hover { + transform: none; + filter: none; + background: color-mix(in srgb, var(--ev-color) 30%, var(--md-sys-color-surface-container-high)); + box-shadow: none; +} + +html[data-design='material3'] .ev-specular { + display: none; +} + +html[data-design='material3'] .ev-title { + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); + font-weight: var(--md-sys-typescale-label-medium-weight); + letter-spacing: var(--md-sys-typescale-label-medium-tracking); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .event-short .ev-title { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); +} + +html[data-design='material3'] .ev-time { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .ev-location { + color: var(--md-sys-color-on-surface-variant); +} diff --git a/src/renderer/src/components/calendar/EventDetailPopup.vue b/src/renderer/src/components/calendar/EventDetailPopup.vue index feaee56..bcf5c84 100644 --- a/src/renderer/src/components/calendar/EventDetailPopup.vue +++ b/src/renderer/src/components/calendar/EventDetailPopup.vue @@ -557,4 +557,193 @@ async function copyEmail(email: string) { font-size:13px; color:rgba(255,255,255,0.52); white-space:pre-wrap; line-height:1.7; margin:0; word-break:break-word; } + +/* ── Material 3 ── */ +/* Центрированное модальное окно → dialog-паттерн, extra-large shape, elevation-3 */ + +html[data-design='material3'] .backdrop { + background: color-mix(in srgb, var(--md-sys-color-scrim) 46%, transparent); +} + +html[data-design='material3'] .popup { + border-radius: var(--md-sys-shape-corner-extra-large); + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: var(--md-sys-elevation-3); + scrollbar-color: var(--md-sys-color-outline-variant) transparent; +} + +html[data-design='material3'] .popup::-webkit-scrollbar-thumb { + background: var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .specular { + display: none; +} + +html[data-design='material3'] .hero-wash { + display: none; +} + +html[data-design='material3'] .hero::after { + background: var(--md-sys-color-outline-variant); + height: 1px; +} + +html[data-design='material3'] .close-btn { + border-radius: var(--md-sys-shape-corner-full); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .close-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-highest)); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .evt-badge { + background: color-mix(in srgb, var(--sc) 18%, var(--md-sys-color-surface-container-high)); + border: 1px solid color-mix(in srgb, var(--sc) 30%, var(--md-sys-color-outline-variant)); + border-radius: var(--md-sys-shape-corner-full); +} + +html[data-design='material3'] .hero-title { + color: var(--md-sys-color-on-surface); + font-size: var(--md-sys-typescale-headline-small-size); + line-height: var(--md-sys-typescale-headline-small-line); + font-weight: var(--md-sys-typescale-headline-small-weight); + letter-spacing: var(--md-sys-typescale-headline-small-tracking); +} + +html[data-design='material3'] .hero-date, +html[data-design='material3'] .hero-dur { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); +} + +html[data-design='material3'] .hero-date { + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .hero-bull { + color: var(--md-sys-color-outline); +} +html[data-design='material3'] .hero-dur { + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .card { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-large); +} + +html[data-design='material3'] .row-icon { + border-radius: var(--md-sys-shape-corner-small); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .row-label, +html[data-design='material3'] .pgroup-head { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + font-weight: var(--md-sys-typescale-label-small-weight); + letter-spacing: var(--md-sys-typescale-label-small-tracking); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .row-value { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .loc-link { + color: var(--md-sys-color-primary); + text-decoration-color: color-mix(in srgb, var(--md-sys-color-primary) 45%, transparent); +} +html[data-design='material3'] .loc-link:hover { + color: var(--md-sys-color-primary); + text-decoration-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .psep { + background: var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .chevron-btn { + border-radius: var(--md-sys-shape-corner-small); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .chevron-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-highest)); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .ava { + background: color-mix(in srgb, var(--ac) 30%, var(--md-sys-color-surface-container-highest)); + border: 1.5px solid color-mix(in srgb, var(--ac) 40%, var(--md-sys-color-outline-variant)); + color: color-mix(in srgb, var(--ac) 85%, var(--md-sys-color-on-surface) 15%); +} + +html[data-design='material3'] .ava-status-dot { + box-shadow: 0 0 0 1.5px var(--md-sys-color-surface-container); +} + +html[data-design='material3'] .stack-ava { + box-shadow: 0 0 0 2px var(--md-sys-color-surface-container); +} + +html[data-design='material3'] .stack-more { + background: var(--md-sys-color-surface-container-highest); + border-color: var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .plist .prow:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 6%, transparent); +} + +html[data-design='material3'] .pname { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .optional-tag { + font-size: var(--md-sys-typescale-label-small-size); + border-radius: var(--md-sys-shape-corner-extra-small); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .pemail { + font-size: var(--md-sys-typescale-body-small-size); + line-height: var(--md-sys-typescale-body-small-line); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .copy-btn { + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .copy-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + border-color: var(--md-sys-color-outline-variant); + color: var(--md-sys-color-on-surface); +} +html[data-design='material3'] .copy-btn.ok { + color: var(--md-sys-color-primary); + background: color-mix(in srgb, var(--md-sys-color-primary) 12%, transparent); + border-color: color-mix(in srgb, var(--md-sys-color-primary) 25%, transparent); +} + +html[data-design='material3'] .desc-text { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + color: var(--md-sys-color-on-surface-variant); +} diff --git a/src/renderer/src/components/calendar/MiniCalendar.vue b/src/renderer/src/components/calendar/MiniCalendar.vue index 6de7a20..d8b48cb 100644 --- a/src/renderer/src/components/calendar/MiniCalendar.vue +++ b/src/renderer/src/components/calendar/MiniCalendar.vue @@ -365,4 +365,122 @@ function nextMonth(): void { 0 2px 14px rgba(168, 230, 0, 0.45), 0 0 0 1px rgba(168, 230, 0, 0.30); } + +/* ── Material 3 ── */ +html[data-design='material3'] .mini-cal { + border-radius: var(--md-sys-shape-corner-medium); + background: var(--md-sys-color-surface-container-low); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} + +html[data-design='material3'] .mini-month { + font-size: var(--md-sys-typescale-title-large-size); + line-height: var(--md-sys-typescale-title-large-line); + font-weight: var(--md-sys-typescale-title-large-weight); + letter-spacing: var(--md-sys-typescale-title-large-tracking); + color: var(--md-sys-color-on-surface); + text-shadow: none; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +html[data-design='material3'] .mini-nav { + border-radius: var(--md-sys-shape-corner-full); + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .mini-nav:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-highest)); + border-color: var(--md-sys-color-outline); + box-shadow: none; + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .mini-nav:active { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 10%, var(--md-sys-color-surface-container-highest)); + box-shadow: none; + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .dow-row { + border-bottom: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .dow { + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); + font-weight: var(--md-sys-typescale-label-medium-weight); + letter-spacing: var(--md-sys-typescale-label-medium-tracking); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .day-inner { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + font-weight: var(--md-sys-typescale-body-medium-weight); + color: var(--md-sys-color-on-surface-variant); + border-radius: var(--md-sys-shape-corner-full); +} + +html[data-design='material3'] .day-cell:hover:not(.in-range) .day-inner { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + box-shadow: none; + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .day-cell.other-month .day-inner { + color: color-mix(in srgb, var(--md-sys-color-on-surface-variant) 45%, transparent); +} + +/* Today (не в диапазоне) — тонированный контур, как в M3 date picker */ +html[data-design='material3'] .day-cell.is-today:not(.in-range) .day-inner { + color: var(--md-sys-color-primary); + font-size: var(--md-sys-typescale-title-small-size); + line-height: var(--md-sys-typescale-title-small-line); + font-weight: var(--md-sys-typescale-title-small-weight); + background: transparent; + box-shadow: inset 0 0 0 1px var(--md-sys-color-primary); +} + +/* Диапазон недели — плоская тональная полоса (secondary-container) */ +html[data-design='material3'] .day-cell.in-range:not(.range-start):not(.range-end)::before, +html[data-design='material3'] .day-cell.range-start:not(.range-end)::before, +html[data-design='material3'] .day-cell.range-end:not(.range-start)::before { + background: var(--md-sys-color-secondary-container); + border-top: none; + border-bottom: none; +} + +html[data-design='material3'] .day-cell.in-range:not(.range-start):not(.range-end) .day-inner { + color: var(--md-sys-color-on-secondary-container); + font-weight: var(--md-sys-typescale-body-medium-weight); +} + +/* Начало/конец диапазона — заполненный primary-круг, эталонный M3-паттерн выбранного дня */ +html[data-design='material3'] .day-cell.range-start .day-inner, +html[data-design='material3'] .day-cell.range-end .day-inner { + background: var(--md-sys-color-primary); + color: var(--md-sys-color-on-primary); + font-weight: var(--md-sys-typescale-title-small-weight); + box-shadow: none; +} + +html[data-design='material3'] .day-cell.is-today.in-range:not(.range-start):not(.range-end) .day-inner { + color: var(--md-sys-color-on-secondary-container); + font-size: var(--md-sys-typescale-title-small-size); + line-height: var(--md-sys-typescale-title-small-line); + font-weight: var(--md-sys-typescale-title-small-weight); + background: var(--md-sys-color-secondary-container); + box-shadow: inset 0 0 0 1px var(--md-sys-color-primary); +} + +html[data-design='material3'] .day-cell.is-today.range-start .day-inner, +html[data-design='material3'] .day-cell.is-today.range-end .day-inner { + box-shadow: inset 0 0 0 2px var(--md-sys-color-outline); +} diff --git a/src/renderer/src/components/calendar/WeekView.vue b/src/renderer/src/components/calendar/WeekView.vue index 5616ee9..ca3cce6 100644 --- a/src/renderer/src/components/calendar/WeekView.vue +++ b/src/renderer/src/components/calendar/WeekView.vue @@ -312,11 +312,11 @@ function calendarColor(calendarId: string): string { /> + - -
+ + @@ -327,6 +327,7 @@ function calendarColor(calendarId: string): string { flex-direction: column; height: 100%; overflow: hidden; + position: relative; } /* ── Day headers ── */ @@ -665,4 +666,145 @@ function calendarColor(calendarId: string): string { @keyframes spin { to { transform: rotate(360deg); } } + +/* ── Material 3 ── */ +html[data-design='material3'] .day-headers { + border-bottom: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface-container-low); +} + +html[data-design='material3'] .corner-badge { + background: var(--md-sys-color-secondary-container); + border: none; + color: var(--md-sys-color-on-secondary-container); + box-shadow: none; + border-radius: var(--md-sys-shape-corner-full); +} + +html[data-design='material3'] .day-header { + border-left: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .day-header.today { + background: color-mix(in srgb, var(--md-sys-color-primary) 6%, transparent); +} + +html[data-design='material3'] .day-name { + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); + font-weight: var(--md-sys-typescale-label-medium-weight); + letter-spacing: var(--md-sys-typescale-label-medium-tracking); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .day-header.today .day-name { + color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .day-num-wrap.today { + box-shadow: none; +} + +html[data-design='material3'] .day-num { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + font-weight: var(--md-sys-typescale-body-medium-weight); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .day-num-wrap.today .day-num { + font-size: var(--md-sys-typescale-title-small-size); + line-height: var(--md-sys-typescale-title-small-line); + font-weight: var(--md-sys-typescale-title-small-weight); +} + +html[data-design='material3'] .summary-dot { + box-shadow: none; +} + +html[data-design='material3'] .summary-hrs { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .allday-row { + border-bottom: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface-container-lowest); +} + +html[data-design='material3'] .allday-label { + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .allday-col { + border-left: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .allday-event { + border-radius: var(--md-sys-shape-corner-small); + background: color-mix(in srgb, var(--event-color) 22%, var(--md-sys-color-surface-container-high)); + border: 1px solid color-mix(in srgb, var(--event-color) 40%, var(--md-sys-color-outline-variant)); + color: var(--md-sys-color-on-surface); + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); +} + +html[data-design='material3'] .allday-event:hover { + filter: none; + background: color-mix(in srgb, var(--event-color) 30%, var(--md-sys-color-surface-container-high)); +} + +html[data-design='material3'] .grid-scroll { + scrollbar-color: var(--md-sys-color-outline-variant) transparent; +} + +html[data-design='material3'] .grid-scroll::-webkit-scrollbar-thumb { + background: var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .hour-label { + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + color: var(--md-sys-color-on-surface-variant); + opacity: 1; +} + +html[data-design='material3'] .day-col { + border-left: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .day-col.today { + background: color-mix(in srgb, var(--md-sys-color-primary) 4%, transparent); +} + +html[data-design='material3'] .hour-row { + border-top: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .half-hour-row { + border-top: 1px dashed color-mix(in srgb, var(--md-sys-color-outline-variant) 55%, transparent); +} + +/* «Сейчас» — красная линия, как в эталонных M3-календарях (error-роль) */ +html[data-design='material3'] .now-line { + background: var(--md-sys-color-error); + box-shadow: none; +} + +html[data-design='material3'] .now-dot { + background: var(--md-sys-color-error); + box-shadow: none; + animation: none; +} + +html[data-design='material3'] .loading-overlay { + background: color-mix(in srgb, var(--md-sys-color-scrim) 55%, transparent); +} + +html[data-design='material3'] .loading-ring { + border: 2px solid var(--md-sys-color-outline-variant); + border-top-color: var(--md-sys-color-primary); + box-shadow: none; +} diff --git a/src/renderer/src/components/layout/AppShell.vue b/src/renderer/src/components/layout/AppShell.vue index 18ffb73..99732ca 100644 --- a/src/renderer/src/components/layout/AppShell.vue +++ b/src/renderer/src/components/layout/AppShell.vue @@ -334,4 +334,93 @@ onUnmounted(() => document.removeEventListener('keydown', onGlobalKeydown)) transform: translateY(0); box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.18); } + +/* ── Material 3 ── */ +html[data-design='material3'] .app-shell { + background: var(--md-sys-color-surface); +} + +html[data-design='material3'] .account-bar { + border-radius: var(--md-sys-shape-corner-large); + border: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface-container-low); + box-shadow: none; +} + +html[data-design='material3'] .folder-pane { + border-radius: var(--md-sys-shape-corner-large); + border: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface-container-low); + box-shadow: none; +} + +html[data-design='material3'] .message-pane { + border-radius: var(--md-sys-shape-corner-large); + border: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface-container); + box-shadow: none; +} + +html[data-design='material3'] .preview-pane { + border-radius: var(--md-sys-shape-corner-large); + border: 1px solid var(--md-sys-color-outline-variant); + background: var(--md-sys-color-surface); + box-shadow: none; +} + +html[data-design='material3'] .resize-handle:hover::after, +html[data-design='material3'] .resize-handle:active::after { + background: var(--md-sys-color-primary); +} + +html[data-design='material3'] .empty-content { + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-extra-large); + box-shadow: var(--md-sys-elevation-2); +} + +html[data-design='material3'] .empty-content::before { + display: none; +} + +html[data-design='material3'] .empty-icon { + opacity: 0.7; + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .empty-content h2 { + font-size: var(--md-sys-typescale-headline-small-size); + line-height: var(--md-sys-typescale-headline-small-line); + font-weight: var(--md-sys-typescale-headline-small-weight); + letter-spacing: var(--md-sys-typescale-headline-small-tracking); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .empty-content p { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .add-btn { + background: var(--md-sys-color-primary); + color: var(--md-sys-color-on-primary); + border-radius: var(--md-sys-shape-corner-full); + font-size: var(--md-sys-typescale-label-large-size); + font-weight: var(--md-sys-typescale-label-large-weight); + box-shadow: none; +} + +html[data-design='material3'] .add-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-primary) 8%, var(--md-sys-color-primary)); + box-shadow: none; + transform: none; +} + +html[data-design='material3'] .add-btn:active { + background: color-mix(in srgb, var(--md-sys-color-on-primary) 10%, var(--md-sys-color-primary)); + box-shadow: none; + transform: none; +} diff --git a/src/renderer/src/components/layout/StatusBar.vue b/src/renderer/src/components/layout/StatusBar.vue index f456e0a..473adc1 100644 --- a/src/renderer/src/components/layout/StatusBar.vue +++ b/src/renderer/src/components/layout/StatusBar.vue @@ -72,4 +72,14 @@ const isConnected = computed(() => { .status-dot.connected { background: var(--success); } + +/* ── Material 3 ── */ +html[data-design='material3'] .statusbar { + background: var(--md-sys-color-surface-container-low); + border-top: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; + font-size: var(--md-sys-typescale-label-small-size); + line-height: var(--md-sys-typescale-label-small-line); + color: var(--md-sys-color-on-surface-variant); +} diff --git a/src/renderer/src/components/layout/TitleBar.vue b/src/renderer/src/components/layout/TitleBar.vue index b33fab6..a0bfc8a 100644 --- a/src/renderer/src/components/layout/TitleBar.vue +++ b/src/renderer/src/components/layout/TitleBar.vue @@ -78,4 +78,27 @@ function close(): void { background: var(--danger); color: white; } + +/* ── Material 3 ── */ +html[data-design='material3'] .titlebar { + background: var(--md-sys-color-surface-container-low); + border-bottom: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .app-title { + font-size: var(--md-sys-typescale-label-medium-size); + font-weight: var(--md-sys-typescale-label-medium-weight); + letter-spacing: var(--md-sys-typescale-label-medium-tracking); + color: var(--md-sys-color-on-surface-variant); +} + +html[data-design='material3'] .control-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .control-btn.close:hover { + background: var(--md-sys-color-error); + color: var(--md-sys-color-on-error); +} diff --git a/src/renderer/src/components/messages/MessageList.vue b/src/renderer/src/components/messages/MessageList.vue index 03c1b2e..34be746 100644 --- a/src/renderer/src/components/messages/MessageList.vue +++ b/src/renderer/src/components/messages/MessageList.vue @@ -1340,4 +1340,228 @@ async function handleSwipeAction(action: SwipeAction, messageId: string): Promis line-height: 16px; backdrop-filter: blur(4px); } + +/* ══════════════════════════ Material 3 ══════════════════════════ */ + +html[data-design='material3'] .message-list-header { + background: var(--md-sys-color-surface-container-low); + border-bottom: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} + +html[data-design='material3'] .folder-title { + font-size: var(--md-sys-typescale-title-large-size); + line-height: var(--md-sys-typescale-title-large-line); + font-weight: 500; +} + +/* Счётчик непрочитанных — accent (primary), не error: error зарезервирован под danger */ +html[data-design='material3'] .message-count { + font-size: var(--md-sys-typescale-label-small-size); + color: var(--md-sys-color-on-primary-container); + background: var(--md-sys-color-primary-container); + border: 1px solid transparent; + box-shadow: none; +} +html[data-design='material3'] .message-count:hover { + background: color-mix(in srgb, var(--md-sys-color-on-primary-container) 8%, var(--md-sys-color-primary-container)); + border-color: transparent; + box-shadow: none; +} +html[data-design='material3'] .message-count.unread-active { + background: var(--md-sys-color-primary); + color: var(--md-sys-color-on-primary); + border-color: transparent; + box-shadow: none; +} + +html[data-design='material3'] .icon-btn { + background: transparent; + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} +html[data-design='material3'] .icon-btn:hover:not(:disabled) { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} +html[data-design='material3'] .icon-btn:active:not(:disabled) { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 10%, transparent); + box-shadow: none; +} +html[data-design='material3'] .icon-btn.active { + color: var(--md-sys-color-on-primary-container); + background: var(--md-sys-color-primary-container); + border-color: transparent; + box-shadow: none; +} + +html[data-design='material3'] .bulk-actions { + background: var(--md-sys-color-surface-container); + border-bottom: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} +html[data-design='material3'] .bulk-count { + font-size: var(--md-sys-typescale-body-small-size); +} +html[data-design='material3'] .bulk-count-num { + font-size: var(--md-sys-typescale-label-small-size); + color: var(--md-sys-color-on-primary-container); + background: var(--md-sys-color-primary-container); + border: 1px solid transparent; +} +html[data-design='material3'] .bulk-btn { + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} +html[data-design='material3'] .bulk-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-high)); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} +html[data-design='material3'] .bulk-btn:active { + box-shadow: none; +} +html[data-design='material3'] .bulk-btn.danger { + color: var(--md-sys-color-error); + background: var(--md-sys-color-error-container); + border-color: transparent; + box-shadow: none; +} +html[data-design='material3'] .bulk-btn.danger:hover { + background: color-mix(in srgb, var(--md-sys-color-on-error-container) 10%, var(--md-sys-color-error-container)); + border-color: transparent; + color: var(--md-sys-color-on-error-container); + box-shadow: none; +} +html[data-design='material3'] .bulk-cancel:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); +} + +html[data-design='material3'] .select-all-row { + border-bottom: 1px solid var(--md-sys-color-outline-variant); + background: transparent; +} +html[data-design='material3'] .select-all-row:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); +} +html[data-design='material3'] .select-all-circle { + border-color: var(--md-sys-color-outline); +} +html[data-design='material3'] .select-all-circle.checked, +html[data-design='material3'] .select-all-circle.indeterminate { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); +} +html[data-design='material3'] .select-all-text { + font-size: var(--md-sys-typescale-body-small-size); +} + +html[data-design='material3'] .pull-indicator { + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} +html[data-design='material3'] .pull-indicator.ready, +html[data-design='material3'] .pull-indicator.refreshing { + border-color: var(--md-sys-color-primary); + box-shadow: none; +} + +/* Открытый тред — плоская tonal-поверхность вместо радужного glass-градиента */ +html[data-design='material3'] .thread-group--open { + border-radius: var(--md-sys-shape-corner-medium); + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline); + box-shadow: none; +} +html[data-design='material3'] .thread-group--open::before { + display: none; +} +html[data-design='material3'] .thread-group--open :deep(.thread-card), +html[data-design='material3'] .thread-group--open :deep(.thread-card.expanded) { + border-bottom: 1px solid var(--md-sys-color-outline-variant); +} +html[data-design='material3'] .thread-empty-filter { + border-top: 1px solid var(--md-sys-color-outline-variant); +} +html[data-design='material3'] .thread-children :deep(.thread-child-item:not(:first-child) .message-item) { + border-top: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .search-pill { + background: var(--md-sys-color-surface-container-high); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} +html[data-design='material3'] .search-pill:hover:not(.search-pill--open) { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-high)); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} +html[data-design='material3'] .search-pill--open { + background: var(--md-sys-color-surface-container-highest); + border-color: var(--md-sys-color-primary); + box-shadow: none; +} +html[data-design='material3'] .search-pill-icon { + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .search-pill--open .search-pill-icon { + color: var(--md-sys-color-primary); +} +html[data-design='material3'] .search-pill-input { + font-size: var(--md-sys-typescale-body-medium-size); +} +html[data-design='material3'] .search-pill-input::placeholder { + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .search-pill-close { + color: var(--md-sys-color-on-surface-variant); +} +html[data-design='material3'] .search-pill-close:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 10%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .search-results-count { + font-size: var(--md-sys-typescale-body-small-size); +} +html[data-design='material3'] .search-result-item { + border-radius: var(--md-sys-shape-corner-medium); + background: var(--md-sys-color-surface-container-low); + border: 1px solid transparent; +} +html[data-design='material3'] .search-result-item:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-low)); + border-color: transparent; + box-shadow: none; +} +html[data-design='material3'] .search-result-item.selected { + background: var(--md-sys-color-secondary-container); + border-color: transparent; + box-shadow: none; +} +html[data-design='material3'] .search-result-item.selected .search-result-from, +html[data-design='material3'] .search-result-item.selected .search-result-subject, +html[data-design='material3'] .search-result-item.selected .search-result-date { + color: var(--md-sys-color-on-secondary-container); +} +html[data-design='material3'] .search-result-from { + font-size: var(--md-sys-typescale-title-medium-size); + font-weight: var(--md-sys-typescale-title-medium-weight); +} +html[data-design='material3'] .search-result-date { + font-size: var(--md-sys-typescale-label-medium-size); +} +html[data-design='material3'] .search-result-subject { + font-size: var(--md-sys-typescale-body-medium-size); +} +html[data-design='material3'] .search-result-folder { + font-size: var(--md-sys-typescale-label-small-size); + color: var(--md-sys-color-primary); + background: var(--md-sys-color-primary-container); + border: 1px solid transparent; +} diff --git a/src/renderer/src/components/messages/MessageListItem.vue b/src/renderer/src/components/messages/MessageListItem.vue index fbe89ee..d36e303 100644 --- a/src/renderer/src/components/messages/MessageListItem.vue +++ b/src/renderer/src/components/messages/MessageListItem.vue @@ -494,4 +494,92 @@ onUnmounted(() => { } .flag-icon { color: var(--warning); } .attachment-icon { color: var(--text-muted); } + +/* ── Material 3 ── */ +html[data-design='material3'] .swipe-wrapper { + border-radius: var(--md-sys-shape-corner-medium); + background: var(--md-sys-color-surface-container-low); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} + +html[data-design='material3'] .swipe-wrapper:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-low)); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .swipe-wrapper:has(.message-item.selected) { + border-color: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .message-item { + background: none; +} + +html[data-design='material3'] .message-item.unread { + background: none; +} + +html[data-design='material3'] .message-item:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); +} + +html[data-design='material3'] .message-item.selected { + background: var(--md-sys-color-secondary-container); +} + +html[data-design='material3'] .message-item.selected::after { + box-shadow: none; +} + +html[data-design='material3'] .message-item.selected:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-secondary-container)); +} + +html[data-design='material3'] .message-item.selected .sender, +html[data-design='material3'] .message-item.selected .subject, +html[data-design='material3'] .message-item.selected .snippet, +html[data-design='material3'] .message-item.selected .date { + color: var(--md-sys-color-on-secondary-container); +} + +html[data-design='material3'] .message-item.checked { + background: color-mix(in srgb, var(--md-sys-color-primary) 12%, transparent); +} + +html[data-design='material3'] .message-item.checked:hover { + background: color-mix(in srgb, var(--md-sys-color-primary) 18%, transparent); +} + +html[data-design='material3'] .unread-dot { + box-shadow: none; +} + +html[data-design='material3'] .sender { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); +} + +html[data-design='material3'] .sender.font-bold { + font-size: var(--md-sys-typescale-title-medium-size); + line-height: var(--md-sys-typescale-title-medium-line); + font-weight: var(--md-sys-typescale-title-medium-weight); +} + +html[data-design='material3'] .subject { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); +} + +html[data-design='material3'] .date { + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); +} + +html[data-design='material3'] .snippet { + font-size: var(--md-sys-typescale-body-small-size); + line-height: var(--md-sys-typescale-body-small-line); +} diff --git a/src/renderer/src/components/messages/ThreadContextMenu.vue b/src/renderer/src/components/messages/ThreadContextMenu.vue index 90e926c..fbac320 100644 --- a/src/renderer/src/components/messages/ThreadContextMenu.vue +++ b/src/renderer/src/components/messages/ThreadContextMenu.vue @@ -115,4 +115,28 @@ onUnmounted(() => { .menu-item:active { background: rgba(255, 255, 255, 0.05); } + +/* ── Material 3 ── */ +html[data-design='material3'] .context-menu { + background: var(--md-sys-color-surface-container); + border: 1px solid var(--md-sys-color-outline-variant); + border-radius: var(--md-sys-shape-corner-small); + box-shadow: var(--md-sys-elevation-2); + animation: menu-in var(--md-sys-motion-duration-short4) var(--md-sys-motion-easing-emphasized-decelerate); +} + +html[data-design='material3'] .menu-item { + border-radius: var(--md-sys-shape-corner-extra-small); + font-size: var(--md-sys-typescale-body-medium-size); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .menu-item:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .menu-item:active { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 10%, transparent); +} diff --git a/src/renderer/src/components/messages/ThreadListItem.vue b/src/renderer/src/components/messages/ThreadListItem.vue index 6935c47..c33c6cb 100644 --- a/src/renderer/src/components/messages/ThreadListItem.vue +++ b/src/renderer/src/components/messages/ThreadListItem.vue @@ -403,4 +403,127 @@ const snippet = computed(() => props.thread.latest.snippet || '') .thread-card.expanded .thread-item { background: transparent; } + +/* ── Material 3 ── */ +html[data-design='material3'] .thread-card { + border-radius: var(--md-sys-shape-corner-medium); + background: var(--md-sys-color-surface-container-low); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; +} + +html[data-design='material3'] .thread-card:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, var(--md-sys-color-surface-container-low)); + border-color: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .thread-card.unread { + background: var(--md-sys-color-surface-container-low); +} + +html[data-design='material3'] .thread-card.selected { + border-color: var(--md-sys-color-outline); + box-shadow: none; +} + +html[data-design='material3'] .thread-item.selected { + background: var(--md-sys-color-secondary-container); +} + +html[data-design='material3'] .thread-item.selected .thread-participants, +html[data-design='material3'] .thread-item.selected .thread-subject, +html[data-design='material3'] .thread-item.selected .thread-date, +html[data-design='material3'] .thread-item.selected .thread-snippet { + color: var(--md-sys-color-on-secondary-container); +} + +html[data-design='material3'] .thread-item:not(.selected):hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); +} + +html[data-design='material3'] .thread-check-circle { + border-color: var(--md-sys-color-outline); +} + +html[data-design='material3'] .thread-check-circle.checked, +html[data-design='material3'] .thread-check-circle.indeterminate { + background: var(--md-sys-color-primary); + border-color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .unread-dot { + box-shadow: none; +} + +html[data-design='material3'] .thread-participants { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); +} + +html[data-design='material3'] .thread-participants.bold { + font-size: var(--md-sys-typescale-title-medium-size); + line-height: var(--md-sys-typescale-title-medium-line); + font-weight: var(--md-sys-typescale-title-medium-weight); +} + +html[data-design='material3'] .thread-date { + font-size: var(--md-sys-typescale-label-medium-size); + line-height: var(--md-sys-typescale-label-medium-line); +} + +html[data-design='material3'] .thread-subject { + font-size: var(--md-sys-typescale-body-medium-size); + line-height: var(--md-sys-typescale-body-medium-line); +} + +html[data-design='material3'] .thread-subject.bold { + font-weight: 500; + color: var(--md-sys-color-on-surface); +} + +html[data-design='material3'] .thread-snippet { + font-size: var(--md-sys-typescale-body-small-size); + line-height: var(--md-sys-typescale-body-small-line); +} + +html[data-design='material3'] .thread-count { + background: var(--md-sys-color-surface-container-highest); + border: 1px solid var(--md-sys-color-outline-variant); + box-shadow: none; + font-size: var(--md-sys-typescale-label-small-size); +} + +html[data-design='material3'] .thread-item.unread .thread-count { + color: var(--md-sys-color-primary); + background: var(--md-sys-color-primary-container); + border-color: transparent; +} + +html[data-design='material3'] .thread-filter-btn { + border-radius: var(--md-sys-shape-corner-extra-small); + background: transparent; + border: 1px solid var(--md-sys-color-outline-variant); +} + +html[data-design='material3'] .thread-filter-btn:hover { + background: color-mix(in srgb, var(--md-sys-color-on-surface) 8%, transparent); + border-color: var(--md-sys-color-outline); +} + +html[data-design='material3'] .thread-filter-btn.active { + color: var(--md-sys-color-primary); + background: var(--md-sys-color-primary-container); + border-color: transparent; +} + +html[data-design='material3'] .thread-chevron.open { + color: var(--md-sys-color-primary); +} + +html[data-design='material3'] .thread-card.expanded { + border-color: var(--md-sys-color-outline); + background: var(--md-sys-color-surface-container); + box-shadow: none; +} diff --git a/src/renderer/src/components/notifications/NotificationToast.vue b/src/renderer/src/components/notifications/NotificationToast.vue index 1f957ca..d38cea3 100644 --- a/src/renderer/src/components/notifications/NotificationToast.vue +++ b/src/renderer/src/components/notifications/NotificationToast.vue @@ -149,4 +149,46 @@ onMounted(() => { background: rgba(255, 255, 255, 0.12); color: var(--text-secondary); } + +/* ── Material 3 (Snackbar-like surface) ── */ +html[data-design='material3'] .toast { + background: var(--md-sys-color-inverse-surface); + border: none; + border-radius: var(--md-sys-shape-corner-extra-small); + box-shadow: var(--md-sys-elevation-3); +} + +html[data-design='material3'] .toast:hover { + background: color-mix(in srgb, var(--md-sys-color-inverse-on-surface) 6%, var(--md-sys-color-inverse-surface)); + border: none; +} + +html[data-design='material3'] .toast-icon { + color: var(--md-sys-color-inverse-primary); + background: color-mix(in srgb, var(--md-sys-color-inverse-primary) 16%, transparent); + border: none; +} + +html[data-design='material3'] .toast-from { + color: var(--md-sys-color-inverse-on-surface); + font-size: var(--md-sys-typescale-title-small-size); + font-weight: var(--md-sys-typescale-title-small-weight); +} + +html[data-design='material3'] .toast-subject, +html[data-design='material3'] .toast-account { + color: color-mix(in srgb, var(--md-sys-color-inverse-on-surface) 75%, transparent); + font-size: var(--md-sys-typescale-body-small-size); +} + +html[data-design='material3'] .toast-close { + background: transparent; + border: none; + color: color-mix(in srgb, var(--md-sys-color-inverse-on-surface) 75%, transparent); +} + +html[data-design='material3'] .toast-close:hover { + background: color-mix(in srgb, var(--md-sys-color-inverse-on-surface) 12%, transparent); + color: var(--md-sys-color-inverse-on-surface); +} diff --git a/src/renderer/src/components/preview/AttachmentStrip.vue b/src/renderer/src/components/preview/AttachmentStrip.vue index 6c94e45..b506c30 100644 --- a/src/renderer/src/components/preview/AttachmentStrip.vue +++ b/src/renderer/src/components/preview/AttachmentStrip.vue @@ -323,4 +323,67 @@ async function handleClick(att: Attachment): Promise