slideshare/src/components/presentations/ThemeSelector.css
Michael Mainguy 9b0b16969f feat: implement complete presentation management system with aspect ratio support
## Major Features Added:

### Presentation Management
- Complete CRUD operations for presentations (create, read, update, delete)
- IndexedDB storage for offline presentation data
- Comprehensive presentation list view with metadata
- Navigation integration with header menu

### Slide Management
- Full slide editor with layout selection and content editing
- Live preview with theme styling applied
- Speaker notes functionality
- Enhanced layout previews with realistic sample content
- Themed layout selection with proper CSS inheritance

### Aspect Ratio System
- Support for 3 common presentation formats: 16:9, 4:3, 16:10
- Global CSS system baked into theme engine
- Visual aspect ratio selection in presentation creation
- Responsive scaling for different viewing contexts
- Print-optimized styling with proper dimensions

### User Experience Improvements
- Enhanced sample content generation for realistic previews
- Improved navigation with presentation management
- Better form styling and user interaction
- Comprehensive error handling and loading states
- Mobile-responsive design throughout

### Technical Infrastructure
- Complete TypeScript type system for presentations
- Modular component architecture
- CSS aspect ratio classes for theme consistency
- Enhanced template rendering with live updates
- Robust storage utilities with proper error handling

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-08-20 16:34:00 -05:00

204 lines
3.1 KiB
CSS

.theme-selector {
width: 100%;
}
.themes-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
gap: 1.5rem;
}
.theme-card {
background: white;
border: 2px solid #e2e8f0;
border-radius: 0.75rem;
overflow: hidden;
cursor: pointer;
transition: all 0.2s ease;
position: relative;
}
.theme-card:hover {
border-color: #cbd5e1;
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}
.theme-card.selected {
border-color: #22c55e;
box-shadow: 0 4px 6px -1px rgba(34, 197, 94, 0.2);
}
.theme-preview {
position: relative;
height: 120px;
background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
display: flex;
align-items: center;
justify-content: center;
padding: 1rem;
}
.color-preview-strip {
display: flex;
gap: 0.5rem;
align-items: center;
flex-wrap: wrap;
justify-content: center;
}
.color-swatch {
width: 48px;
height: 48px;
border-radius: 50%;
border: 3px solid white;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
flex-shrink: 0;
}
.no-colors {
color: #9ca3af;
font-size: 0.875rem;
text-align: center;
font-style: italic;
}
.selection-indicator {
position: absolute;
top: 0.75rem;
right: 0.75rem;
z-index: 10;
}
.theme-info {
padding: 1.5rem;
}
.theme-name {
margin: 0 0 0.5rem 0;
font-size: 1.125rem;
font-weight: 600;
color: #1e293b;
}
.theme-description {
margin: 0 0 1rem 0;
color: #64748b;
font-size: 0.875rem;
line-height: 1.4;
}
.theme-meta {
display: flex;
justify-content: space-between;
align-items: center;
gap: 1rem;
}
.theme-stats {
display: flex;
flex-direction: column;
gap: 0.25rem;
font-size: 0.75rem;
color: #6b7280;
}
.layouts-count {
font-weight: 500;
color: #475569;
}
.theme-author {
color: #6b7280;
}
.theme-version {
color: #9ca3af;
font-family: 'Courier New', monospace;
}
.theme-actions {
display: flex;
gap: 0.5rem;
}
.preview-link {
color: #3b82f6;
text-decoration: none;
font-size: 0.75rem;
font-weight: 500;
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
transition: background-color 0.2s ease;
}
.preview-link:hover {
background: #eff6ff;
text-decoration: none;
}
/* Empty State */
.empty-state {
text-align: center;
padding: 3rem;
color: #6b7280;
}
.empty-state h3 {
margin: 0 0 0.5rem 0;
color: #374151;
}
.empty-state p {
margin: 0;
font-size: 0.875rem;
}
/* Responsive Design */
@media (max-width: 768px) {
.themes-grid {
grid-template-columns: 1fr;
gap: 1rem;
}
.theme-card {
min-width: 0;
}
.theme-preview {
height: 100px;
padding: 0.75rem;
}
.color-swatch {
width: 36px;
height: 36px;
}
.theme-info {
padding: 1rem;
}
.theme-meta {
flex-direction: column;
align-items: flex-start;
gap: 0.75rem;
}
}
/* Focus states for accessibility */
.theme-card:focus {
outline: none;
border-color: #3b82f6;
box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}
/* Animation for selection */
@keyframes selectPulse {
0% { transform: scale(1); }
50% { transform: scale(1.05); }
100% { transform: scale(1); }
}
.theme-card.selected .selection-indicator {
animation: selectPulse 0.3s ease-out;
}