callumalpass_tasknotes/styles/base.css
Callum Alpass 471be7cd56 Refactor event listeners, modals, and styles to improve consistency and maintainability
• Remove workspace layout check in the EVENT_TASK_UPDATED handler (src/main.ts) so that editor decorations refresh regardless of app.workspace.layoutReady.

• Introduce two new modal components:
  – ICSEventInfoModal (src/modals/ICSEventInfoModal.ts): Displays detailed calendar event information including title, date/time, description, location, URL, and optional source.
  – TimeblockInfoModal (src/modals/TimeblockInfoModal.ts): Displays detailed timeblock information with title, time range, description, and attachments.

• Update TimeblockCreationModal (src/modals/TimeblockCreationModal.ts):
  – Adjust UI labels and placeholders (e.g., “Create timeblock”, “Deep work session”, “Start time”, “End time”) for consistent casing.

• Modify AdvancedCalendarView (src/views/AdvancedCalendarView.ts):
  – Replace manual DOM construction for modals with instantiation of the new ICSEventInfoModal and TimeblockInfoModal classes.

• Revise styling in base.css and task-inline-widget.css:
  – Rename keyframes from “task-flash”, “task-pulse”, and “task-fade-in” to “tn-task-flash”, “tn-task-pulse”, and “tn-task-fade-in” to namespace animations under the plugin.
  – Update CSS selectors to scope styles properly under .tasknotes-plugin.

• Remove legacy BEM compatibility classes from modal-bem.css to phase out temporary support for old form-group and related classes.

These changes enhance code readability, promote reuse of modal components, and align the UI styling with the plugin’s namespace for a cleaner, more maintainable codebase.
2025-06-21 08:48:50 +10:00

79 lines
1.6 KiB
CSS

/* Reduced motion support - scope to TaskNotes components only */
@media (prefers-reduced-motion: reduce) {
.tasknotes-container *,
.tasknotes-card *,
.tasknotes-button * {
animation-duration: 0.01ms !important;
animation-iteration-count: 1 !important;
transition-duration: 0.01ms !important;
}
}
/* Button click feedback - scope to TaskNotes buttons only */
.tasknotes-container button:active:not(:disabled),
.tasknotes-button:active:not(:disabled) {
transform: scale(0.98);
}
/* Performance optimization animations */
@keyframes tn-task-flash {
0% {
background-color: var(--interactive-accent-hover);
transform: scale(1.02);
}
100% {
background-color: transparent;
transform: scale(1);
}
}
@keyframes tn-task-pulse {
0%, 100% {
opacity: 1;
transform: scale(1);
}
50% {
opacity: 0.8;
transform: scale(1.01);
}
}
@keyframes tn-task-fade-in {
0% {
opacity: 0;
transform: translateY(-4px);
}
100% {
opacity: 1;
transform: translateY(0);
}
}
@keyframes tn-tracking-pulse {
0%, 100% {
opacity: 0.3;
transform: scale(1);
}
50% {
opacity: 0.6;
transform: scale(1.01);
}
}
/* Task update animations */
.tasknotes-plugin .task-flash {
animation: tn-task-flash 1500ms ease-out;
}
.tasknotes-plugin .task-pulse {
animation: tn-task-pulse 1000ms ease-in-out;
}
.tasknotes-plugin .task-fade-in {
animation: tn-task-fade-in 300ms ease-out;
}