/** * ComfyUI Annotations Extension - Styles * * Overlay positioning and appearance. * Supports both light and dark ComfyUI themes. */ /* ============================================================================ Overlay Container ============================================================================ */ .annotation-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 100; overflow: hidden; /* Default: pass-through to LiteGraph canvas */ pointer-events: none; /* Prevent text selection while drawing */ user-select: none; -webkit-user-select: none; } /* ============================================================================ Drawing Canvas ============================================================================ */ .annotation-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; /* Inherit pointer-events from parent */ pointer-events: inherit; /* Smooth rendering for curves */ image-rendering: auto; /* Touch action for drawing (disable browser gestures) */ touch-action: none; } /* ============================================================================ Cursor Styles (applied via JavaScript) ============================================================================ */ .annotation-canvas[data-mode="draw"] { cursor: crosshair; } .annotation-canvas[data-mode="erase"] { cursor: cell; } .annotation-canvas[data-mode="pan"] { cursor: default; } /* ============================================================================ Future: Toolbar Styles (Milestone 4+) ============================================================================ */ /* .annotation-toolbar { position: absolute; top: 20px; left: 50%; transform: translateX(-50%); z-index: 1050; pointer-events: auto; display: flex; align-items: center; gap: 8px; padding: 8px 16px; background: rgba(26, 26, 26, 0.9); border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; font-size: 13px; color: #e0e0e0; } body:not(.dark) .annotation-toolbar { background: rgba(255, 255, 255, 0.95); color: #333; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); } */ /* ============================================================================ Animations ============================================================================ */ @keyframes annotation-fade-in { from { opacity: 0; } to { opacity: 1; } } .annotation-overlay.visible { animation: annotation-fade-in 0.15s ease-out; } /* ============================================================================ High Contrast Mode Support ============================================================================ */ @media (prefers-contrast: high) { .annotation-overlay { /* Ensure strokes remain visible in high contrast */ } } /* ============================================================================ Reduced Motion Support ============================================================================ */ @media (prefers-reduced-motion: reduce) { .annotation-overlay, .annotation-overlay * { animation: none !important; transition: none !important; } }