managing-media
# Managing Media & Files This Claude Code skill provides systematic patterns for implementing media and file management across all formats, including file uploads with drag-drop and resumable functionality, image galleries with lightbox and carousel layouts, video and audio players with custom controls and captions, document viewers for PDF and Office files, and optimization strategies like compression, responsive images, and lazy loading. Use this skill when building file upload systems, displaying media galleries, creating custom players, handling large files, integrating cloud storage, or implementing media accessibility features.
git clone --depth 1 https://github.com/ancoleman/ai-design-components /tmp/managing-media && cp -r /tmp/managing-media/skills/managing-media ~/.claude/skills/managing-mediaSKILL.md
# Managing Media & Files ## Purpose This skill provides systematic patterns for implementing media and file management components across all formats (images, videos, audio, documents). It covers upload workflows, display patterns, player controls, optimization strategies, and accessibility requirements to ensure performant, accessible, and user-friendly media experiences. ## When to Use Activate this skill when: - Implementing file upload (single, multiple, drag-and-drop) - Building image galleries, carousels, or lightboxes - Creating video or audio players - Displaying PDF or document viewers - Optimizing media for performance (responsive images, lazy loading) - Handling large file uploads (chunked, resumable) - Integrating cloud storage (S3, Cloudinary) - Implementing media accessibility (alt text, captions, transcripts) - Designing empty states for missing media ## Quick Decision Framework Select implementation based on media type and requirements: ``` Images → Gallery pattern + lazy loading + responsive srcset Videos → Player with controls + captions + adaptive streaming Audio → Player with waveform + playlist support Documents (PDF) → Viewer with navigation + search + download File Upload (<10MB) → Basic drag-drop with preview File Upload (>10MB) → Chunked upload with progress + resume Multiple Files → Queue management + parallel uploads ``` For detailed selection criteria, reference `references/implementation-guide.md`. ## File Upload Patterns ### Basic Upload (<10MB) For small files with simple requirements: - Drag-and-drop zone with visual feedback - Click to browse fallback - File type and size validation - Preview thumbnails for images - Progress indicator - Reference `references/upload-patterns.md` Example: `examples/basic-upload.tsx` ### Advanced Upload (>10MB) For large files requiring reliability: - Chunked uploads (resume on failure) - Parallel uploads for multiple files - Upload queue management - Cancel and retry controls - Client-side compression - Reference `references/advanced-upload.md` Example: `examples/chunked-upload.tsx` ### Image-Specific Upload For image files with editing requirements: - Crop and rotate tools - Client-side resize before upload - Format conversion (PNG → WebP) - Alt text input field (accessibility) - Reference `references/image-upload.md` Example: `examples/image-upload-crop.tsx` ## Image Display Components ### Image Gallery For collections of images: - Grid or masonry layout - Lazy loading (native or custom) - Lightbox on click - Zoom and pan controls - Keyboard navigation (arrow keys) - Responsive design - Reference `references/gallery-patterns.md` Example: `examples/image-gallery.tsx` ### Carousel/Slider For sequential image display: - Auto-play (optional, pausable for accessibility) - Dot or thumbnail navigation - Touch/swipe support - ARIA roles for accessibility - Infinite loop option - Reference `references/carousel-patterns.md` Example: `examples/carousel.tsx` ### Image Optimization Essential optimization strategies: - Responsive images using `srcset` and `sizes` - Modern formats (WebP with JPG fallback) - Progressive JPEGs - Blur-up placeholders - CDN integration - Reference `references/image-optimization.md` ## Video Components ### Video Player For custom video playback: - Custom controls or native - Play/pause, volume, fullscreen - Captions/subtitles (VTT format) - Playback speed control - Picture-in-picture support - Keyboard shortcuts - Reference `references/video-player.md` Example: `examples/video-player.tsx` ### Video Optimization Performance strategies for video: - Adaptive streaming (HLS, DASH) - Thumbnail preview on hover - Lazy loading off-screen videos - Preload strategies (`metadata`, `auto`, `none`) - Multiple quality levels - Reference `references/video-optimization.md` ## Audio Components ### Audio Player For audio playback: - Play/pause, seek, volume controls - Waveform visualization (optional) - Playlist support - Download option - Playback speed control - Visual indicators for accessibility - Reference `references/audio-player.md` Example: `examples/audio-player.tsx` ## Document Viewers ### PDF Viewer For PDF document display: - Page navigation (prev/next, jump to page) - Zoom in/out controls - Text search within document - Download and print options - Thumbnail sidebar - Reference `references/pdf-viewer.md` Example: `examples/pdf-viewer.tsx` ### Office Document Preview For DOCX, XLSX, PPTX files: - Read-only preview or editable - Cloud-based rendering (Google Docs Viewer, Office Online) - Local rendering (limited support) - Download option - Reference `references/office-viewer.md` ## Performance Optimization ### File Size Guidelines Validate client-side before upload: - Images: <5MB recommended - Videos: <100MB for web, larger for cloud - Audio: <10MB - Documents: <25MB - Provide clear error messages - Suggest compression tools ### Image Optimization Checklist ```bash # Generate optimized image set python scripts/optimize_images.py --input image.jpg --formats webp,jpg,avif ``` Strategies: - Compress before upload (client or server) - Generate multiple sizes (thumbnails, medium, large) - Use responsive `srcset` for device targeting - Convert to modern formats (WebP, AVIF) - Serve via CDN with edge caching Reference `references/performance-optimization.md` for complete guide. ### Video Optimization Checklist Strategies: - Transcode to multiple qualities (360p, 720p, 1080p) - Implement adaptive bitrate streaming - Use CDN with edge caching - Lazy load videos outside viewport - Provide poster images ## Accessibility Requirements ### Images Essential patterns: - Alt text required for meaningful images - Empty alt (`alt=""`) for decorative images - Use `<figure>` and `<figcaption>` for context - Sufficient color contrast for overlays - Reference `references/accessibility-images.md` ### Vide
Manage Linux systems covering systemd services, process management, filesystems, networking, performance tuning, and troubleshooting. Use when deploying applications, optimizing server performance, diagnosing production issues, or managing users and security on Linux servers.
Data pipelines, feature stores, and embedding generation for AI/ML systems. Use when building RAG pipelines, ML feature serving, or data transformations. Covers feature stores (Feast, Tecton), embedding pipelines, chunking strategies, orchestration (Dagster, Prefect, Airflow), dbt transformations, data versioning (LakeFS), and experiment tracking (MLflow, W&B).
Strategic guidance for designing modern data platforms, covering storage paradigms (data lake, warehouse, lakehouse), modeling approaches (dimensional, normalized, data vault, wide tables), data mesh principles, and medallion architecture patterns. Use when architecting data platforms, choosing between centralized vs decentralized patterns, selecting table formats (Iceberg, Delta Lake), or designing data governance frameworks.
Design cloud network architectures with VPC patterns, subnet strategies, zero trust principles, and hybrid connectivity. Use when planning VPC topology, implementing multi-cloud networking, or establishing secure network segmentation for cloud workloads.
Design comprehensive security architectures using defense-in-depth, zero trust principles, threat modeling (STRIDE, PASTA), and control frameworks (NIST CSF, CIS Controls, ISO 27001). Use when designing security for new systems, auditing existing architectures, or establishing security governance programs.
Assembles component outputs from AI Design Components skills into unified, production-ready component systems with validated token integration, proper import chains, and framework-specific scaffolding. Use as the capstone skill after running theming, layout, dashboard, data-viz, or feedback skills to wire components into working React/Next.js, Python, or Rust projects.
Builds AI chat interfaces and conversational UI with streaming responses, context management, and multi-modal support. Use when creating ChatGPT-style interfaces, AI assistants, code copilots, or conversational agents. Handles streaming text, token limits, regeneration, feedback loops, tool usage visualization, and AI-specific error patterns. Provides battle-tested components from leading AI products with accessibility and performance built in.
Constructs secure, efficient CI/CD pipelines with supply chain security (SLSA), monorepo optimization, caching strategies, and parallelization patterns for GitHub Actions, GitLab CI, and Argo Workflows. Use when setting up automated testing, building, or deployment workflows.