feat(theme): refine retro monitor, ascii portrait, and ambient matrix rain in light mode
CI Pipeline - Quality & Build / Build & Validate Frontend (pull_request) Successful in 47s
Details
CI Pipeline - Quality & Build / Build & Test Backend (.NET) (pull_request) Successful in 33s
Details
CI Pipeline - Quality & Build / Continuous Deployment to Production VPS (pull_request) Has been skipped
Details
- Adapt ASCII portrait to obsidian sumi-ink (#0f172a) in light mode for crisp contrast - Restore classic beige NEC MultiSync CRT monitor with clean alpha mask and soft contact shadow - Enable continuous ambient matrix rain with cyber-zen matcha palette in light mode - Enhance floating glassmorphic navbar and light theme contrast across terminal and simulator - Support dual-theme 3D ThinkPad scroll sequence
|
|
@ -454,39 +454,71 @@
|
||||||
:host-context([data-theme='zen-light']) .project-card,
|
:host-context([data-theme='zen-light']) .project-card,
|
||||||
:host-context(body.theme-light) .project-card {
|
:host-context(body.theme-light) .project-card {
|
||||||
background: rgba(255, 255, 255, 0.88);
|
background: rgba(255, 255, 255, 0.88);
|
||||||
border-color: rgba(0, 0, 0, 0.08);
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
|
box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .project-card:hover,
|
:host-context([data-theme='zen-light']) .project-card:hover,
|
||||||
:host-context(body.theme-light) .project-card:hover {
|
:host-context(body.theme-light) .project-card:hover {
|
||||||
background: #ffffff;
|
background: #ffffff;
|
||||||
border-color: #000000;
|
border-color: var(--zen-accent-kintsugi);
|
||||||
box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
|
box-shadow: 0 12px 28px rgba(217, 119, 6, 0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .project-card.is-selected,
|
||||||
|
:host-context(body.theme-light) .project-card.is-selected {
|
||||||
|
border-color: var(--zen-accent-kintsugi);
|
||||||
|
box-shadow: 0 18px 36px rgba(15, 23, 42, 0.12), 0 0 20px rgba(217, 119, 6, 0.15);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .project-image-slot,
|
||||||
|
:host-context(body.theme-light) .project-image-slot {
|
||||||
|
background-color: #f1f5f9;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .tech-blueprint-slot,
|
||||||
|
:host-context(body.theme-light) .tech-blueprint-slot {
|
||||||
|
background:
|
||||||
|
radial-gradient(circle at center, rgba(3, 105, 161, 0.06) 0%, transparent 70%),
|
||||||
|
#f8fafc;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .blueprint-grid-overlay,
|
||||||
|
:host-context(body.theme-light) .blueprint-grid-overlay {
|
||||||
|
background-image:
|
||||||
|
linear-gradient(rgba(3, 105, 161, 0.08) 1px, transparent 1px),
|
||||||
|
linear-gradient(90deg, rgba(3, 105, 161, 0.08) 1px, transparent 1px);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .project-detail-overlay,
|
||||||
|
:host-context(body.theme-light) .project-detail-overlay {
|
||||||
|
background: rgba(15, 23, 42, 0.45);
|
||||||
|
backdrop-filter: blur(12px);
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .carousel-nav-btn,
|
:host-context([data-theme='zen-light']) .carousel-nav-btn,
|
||||||
:host-context(body.theme-light) .carousel-nav-btn {
|
:host-context(body.theme-light) .carousel-nav-btn {
|
||||||
background: rgba(0, 0, 0, 0.04);
|
background: rgba(15, 23, 42, 0.04);
|
||||||
border-color: rgba(0, 0, 0, 0.08);
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
color: #000000;
|
color: var(--zen-text-primary);
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .carousel-nav-btn:hover,
|
:host-context([data-theme='zen-light']) .carousel-nav-btn:hover,
|
||||||
:host-context(body.theme-light) .carousel-nav-btn:hover {
|
:host-context(body.theme-light) .carousel-nav-btn:hover {
|
||||||
background: rgba(0, 0, 0, 0.08);
|
background: rgba(15, 23, 42, 0.08);
|
||||||
border-color: #000000;
|
border-color: var(--zen-accent-kintsugi);
|
||||||
color: #000000;
|
color: var(--zen-accent-kintsugi);
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .tech-chip,
|
:host-context([data-theme='zen-light']) .tech-chip,
|
||||||
:host-context(body.theme-light) .tech-chip {
|
:host-context(body.theme-light) .tech-chip {
|
||||||
background: rgba(0, 0, 0, 0.04);
|
background: rgba(15, 23, 42, 0.04);
|
||||||
border-color: rgba(0, 0, 0, 0.08);
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
color: #374151;
|
color: var(--zen-text-secondary);
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .carousel-dot .dot-inner,
|
:host-context([data-theme='zen-light']) .carousel-dot .dot-inner,
|
||||||
:host-context(body.theme-light) .carousel-dot .dot-inner {
|
:host-context(body.theme-light) .carousel-dot .dot-inner {
|
||||||
background: rgba(0, 0, 0, 0.15);
|
background: rgba(15, 23, 42, 0.15);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -381,3 +381,95 @@
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Adaptación a Modo Claro (Vercel-inspired Glassmorphism) */
|
||||||
|
:host-context([data-theme='zen-light']) .project-detail-panel,
|
||||||
|
:host-context(body.theme-light) .project-detail-panel {
|
||||||
|
background: #ffffff;
|
||||||
|
border-color: rgba(15, 23, 42, 0.1);
|
||||||
|
box-shadow: 0 24px 60px rgba(15, 23, 42, 0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .main-image-viewport,
|
||||||
|
:host-context(body.theme-light) .main-image-viewport {
|
||||||
|
background: #f8fafc;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .main-image-viewport img,
|
||||||
|
:host-context(body.theme-light) .main-image-viewport img {
|
||||||
|
background-color: #f8fafc;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .thumb-btn,
|
||||||
|
:host-context(body.theme-light) .thumb-btn {
|
||||||
|
background: #f1f5f9;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .thumb-btn:hover,
|
||||||
|
:host-context(body.theme-light) .thumb-btn:hover {
|
||||||
|
border-color: rgba(15, 23, 42, 0.25);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .close-button,
|
||||||
|
:host-context(body.theme-light) .close-button {
|
||||||
|
background: rgba(15, 23, 42, 0.05);
|
||||||
|
border-color: rgba(15, 23, 42, 0.1);
|
||||||
|
color: var(--zen-text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .close-button:hover,
|
||||||
|
:host-context(body.theme-light) .close-button:hover {
|
||||||
|
background: rgba(15, 23, 42, 0.1);
|
||||||
|
border-color: var(--zen-accent-kintsugi);
|
||||||
|
color: var(--zen-accent-kintsugi);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .meta-pill,
|
||||||
|
:host-context(body.theme-light) .meta-pill {
|
||||||
|
background: rgba(15, 23, 42, 0.04);
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
color: var(--zen-text-primary);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .meta-pill.subtle,
|
||||||
|
:host-context(body.theme-light) .meta-pill.subtle {
|
||||||
|
color: var(--zen-text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .detail-block,
|
||||||
|
:host-context(body.theme-light) .detail-block {
|
||||||
|
background: #f8fafc;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .detail-tags span,
|
||||||
|
:host-context(body.theme-light) .detail-tags span {
|
||||||
|
background: rgba(15, 23, 42, 0.04);
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
color: var(--zen-text-secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .technical-blueprint-panel,
|
||||||
|
:host-context(body.theme-light) .technical-blueprint-panel {
|
||||||
|
background:
|
||||||
|
radial-gradient(circle at center, rgba(3, 105, 161, 0.05) 0%, transparent 70%),
|
||||||
|
#f8fafc;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .blueprint-circuit-bg,
|
||||||
|
:host-context(body.theme-light) .blueprint-circuit-bg {
|
||||||
|
background-image:
|
||||||
|
linear-gradient(rgba(3, 105, 161, 0.08) 1px, transparent 1px),
|
||||||
|
linear-gradient(90deg, rgba(3, 105, 161, 0.08) 1px, transparent 1px);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .blueprint-specs-list .spec-item,
|
||||||
|
:host-context(body.theme-light) .blueprint-specs-list .spec-item {
|
||||||
|
background: #ffffff;
|
||||||
|
border-color: rgba(15, 23, 42, 0.08);
|
||||||
|
color: var(--zen-text-secondary);
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -273,6 +273,27 @@
|
||||||
background: rgba(78, 155, 111, 0.12);
|
background: rgba(78, 155, 111, 0.12);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:host-context(body.theme-light) {
|
||||||
|
.hero-sticky-stage { background: #d9d9d9; }
|
||||||
|
.lateral-panel *, .mobile-only * { text-shadow: none; }
|
||||||
|
.zen-loader-pill, .zen-scroll-hint { background: var(--zen-bg-overlay); }
|
||||||
|
.lead-footer { border-color: var(--zen-border-subtle); }
|
||||||
|
.zen-chip { box-shadow: var(--zen-shadow-sm); }
|
||||||
|
.zen-chip:not(.chip-gold):not(.chip-matcha) {
|
||||||
|
background: var(--zen-bg-surface);
|
||||||
|
border-color: var(--zen-border-subtle);
|
||||||
|
}
|
||||||
|
.mobile-lead-card, .mobile-pillar-card {
|
||||||
|
background: var(--zen-bg-surface);
|
||||||
|
box-shadow: var(--zen-shadow-sm);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (prefers-reduced-motion: reduce) {
|
||||||
|
.lateral-panel, .zen-scroll-hint { transition: none; }
|
||||||
|
.loader-dot, .scroll-wheel-dot { animation: none; }
|
||||||
|
}
|
||||||
|
|
||||||
.mobile-only {
|
.mobile-only {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,46 @@
|
||||||
|
import { TestBed } from '@angular/core/testing';
|
||||||
|
import { ThemeService } from '../../../application/services/theme.service';
|
||||||
|
import { Hero3dComponent } from './hero-3d.component';
|
||||||
|
|
||||||
|
describe('Hero3dComponent theme sequences', () => {
|
||||||
|
it('keeps the canvas when switching themes and finishes loading after a failed frame', async () => {
|
||||||
|
const width = window.innerWidth;
|
||||||
|
const savedTheme = localStorage.getItem('portfolio_theme_mode');
|
||||||
|
const sources: string[] = [];
|
||||||
|
Object.defineProperty(window, 'innerWidth', { configurable: true, value: 1440 });
|
||||||
|
spyOn(window, 'Image').and.callFake(function () { return {
|
||||||
|
get src() { return ''; },
|
||||||
|
set src(value: string) { sources.push(value); },
|
||||||
|
naturalWidth: 0,
|
||||||
|
decode: () => sources.length === 1 ? Promise.reject(new Error('Failed frame')) : Promise.resolve()
|
||||||
|
} as HTMLImageElement; });
|
||||||
|
|
||||||
|
try {
|
||||||
|
await TestBed.configureTestingModule({ imports: [Hero3dComponent] }).compileComponents();
|
||||||
|
const theme = TestBed.inject(ThemeService);
|
||||||
|
theme.setTheme('light');
|
||||||
|
const fixture = TestBed.createComponent(Hero3dComponent);
|
||||||
|
fixture.detectChanges();
|
||||||
|
await fixture.whenStable();
|
||||||
|
fixture.detectChanges();
|
||||||
|
const canvas = fixture.nativeElement.querySelector('canvas');
|
||||||
|
expect(sources.length).toBe(240);
|
||||||
|
expect(sources.every(src => src.includes('/thinkpad-sequence-light/'))).toBeTrue();
|
||||||
|
expect(fixture.nativeElement.querySelector('.zen-loader-pill')).toBeNull();
|
||||||
|
|
||||||
|
theme.setTheme('dark');
|
||||||
|
fixture.detectChanges();
|
||||||
|
await fixture.whenStable();
|
||||||
|
fixture.detectChanges();
|
||||||
|
expect(sources.length).toBe(480);
|
||||||
|
expect(sources.slice(240).every(src => src.includes('/thinkpad-sequence/'))).toBeTrue();
|
||||||
|
expect(fixture.nativeElement.querySelector('canvas')).toBe(canvas);
|
||||||
|
expect(fixture.nativeElement.querySelector('.zen-loader-pill')).toBeNull();
|
||||||
|
fixture.destroy();
|
||||||
|
} finally {
|
||||||
|
Object.defineProperty(window, 'innerWidth', { configurable: true, value: width });
|
||||||
|
TestBed.inject(ThemeService).setTheme(savedTheme === 'light' ? 'light' : 'dark');
|
||||||
|
if (savedTheme === null) localStorage.removeItem('portfolio_theme_mode');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
@ -7,16 +7,17 @@ import {
|
||||||
ElementRef,
|
ElementRef,
|
||||||
ChangeDetectionStrategy,
|
ChangeDetectionStrategy,
|
||||||
signal,
|
signal,
|
||||||
|
effect,
|
||||||
inject,
|
inject,
|
||||||
NgZone,
|
NgZone,
|
||||||
input
|
input
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import { I18nService } from '../../../application/services/i18n.service';
|
import { I18nService } from '../../../application/services/i18n.service';
|
||||||
|
import { ThemeMode, ThemeService } from '../../../application/services/theme.service';
|
||||||
|
|
||||||
const TOTAL_FRAMES = 240;
|
const TOTAL_FRAMES = 240;
|
||||||
const LERP_FACTOR = 0.09;
|
const LERP_FACTOR = 0.09;
|
||||||
const SHARED_IMAGE_CACHE: HTMLImageElement[] = new Array(TOTAL_FRAMES + 1);
|
const SHARED_IMAGE_CACHE: Record<ThemeMode, HTMLImageElement[]> = { dark: [], light: [] };
|
||||||
let isPreloadDone = false;
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-hero-3d',
|
selector: 'app-hero-3d',
|
||||||
|
|
@ -32,6 +33,7 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
@ViewChild('canvas') private canvasRef!: ElementRef<HTMLCanvasElement>;
|
@ViewChild('canvas') private canvasRef!: ElementRef<HTMLCanvasElement>;
|
||||||
|
|
||||||
protected readonly i18n = inject(I18nService);
|
protected readonly i18n = inject(I18nService);
|
||||||
|
private readonly themeService = inject(ThemeService);
|
||||||
private readonly ngZone = inject(NgZone);
|
private readonly ngZone = inject(NgZone);
|
||||||
|
|
||||||
protected readonly activePhase = signal<number>(1);
|
protected readonly activePhase = signal<number>(1);
|
||||||
|
|
@ -39,6 +41,8 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
protected readonly isLoaded = signal<boolean>(false);
|
protected readonly isLoaded = signal<boolean>(false);
|
||||||
|
|
||||||
private ctx: CanvasRenderingContext2D | null = null;
|
private ctx: CanvasRenderingContext2D | null = null;
|
||||||
|
private images: HTMLImageElement[] = [];
|
||||||
|
private readonly isDesktop = signal(window.innerWidth > 900);
|
||||||
private targetFrame = 1;
|
private targetFrame = 1;
|
||||||
private currentInterpolatedFrame = 1;
|
private currentInterpolatedFrame = 1;
|
||||||
private lastRenderedFrame = 0;
|
private lastRenderedFrame = 0;
|
||||||
|
|
@ -49,6 +53,24 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
private intersectionObserver?: IntersectionObserver;
|
private intersectionObserver?: IntersectionObserver;
|
||||||
private mediaQueryList?: MediaQueryList;
|
private mediaQueryList?: MediaQueryList;
|
||||||
|
|
||||||
|
constructor() {
|
||||||
|
effect((onCleanup) => {
|
||||||
|
const mode = this.themeService.themeMode();
|
||||||
|
let active = true;
|
||||||
|
onCleanup(() => { active = false; });
|
||||||
|
this.images = SHARED_IMAGE_CACHE[mode];
|
||||||
|
this.loadProgress.set(0);
|
||||||
|
this.isLoaded.set(false);
|
||||||
|
this.lastRenderedFrame = 0;
|
||||||
|
this.renderFrame(Math.round(this.currentInterpolatedFrame));
|
||||||
|
if (!this.isDesktop()) {
|
||||||
|
this.isLoaded.set(true);
|
||||||
|
} else {
|
||||||
|
this.preloadImages(mode, () => active);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
this.targetFrame = 1;
|
this.targetFrame = 1;
|
||||||
this.currentInterpolatedFrame = 1;
|
this.currentInterpolatedFrame = 1;
|
||||||
|
|
@ -56,11 +78,6 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
this.activePhase.set(1);
|
this.activePhase.set(1);
|
||||||
|
|
||||||
this.checkReducedMotion();
|
this.checkReducedMotion();
|
||||||
if (typeof window !== 'undefined' && window.innerWidth <= 900) {
|
|
||||||
this.isLoaded.set(true);
|
|
||||||
} else {
|
|
||||||
this.preloadImages();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ngAfterViewInit(): void {
|
ngAfterViewInit(): void {
|
||||||
|
|
@ -114,53 +131,45 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private preloadImages(): void {
|
private preloadImages(mode: ThemeMode, isCurrent: () => boolean): void {
|
||||||
if (isPreloadDone) {
|
const images = this.images;
|
||||||
this.loadProgress.set(100);
|
|
||||||
this.isLoaded.set(true);
|
|
||||||
this.renderFrame(this.targetFrame);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
let loaded = 0;
|
let loaded = 0;
|
||||||
const startFrame = this.initialPosition() === 'bottom' ? TOTAL_FRAMES : 1;
|
const startFrame = this.isReducedMotion ? 1 : this.initialPosition() === 'bottom'
|
||||||
|
? TOTAL_FRAMES : Math.round(this.currentInterpolatedFrame);
|
||||||
|
|
||||||
const loadSingle = (index: number, cb?: () => void) => {
|
const loadSingle = async (index: number) => {
|
||||||
if (SHARED_IMAGE_CACHE[index]?.complete) {
|
const img = images[index] ??= new Image();
|
||||||
|
if (!img.src) img.src = this.getFramePath(mode, index);
|
||||||
|
try {
|
||||||
|
await img.decode();
|
||||||
|
} catch {
|
||||||
|
// Un fotograma fallido no bloquea el resto de la secuencia.
|
||||||
|
} finally {
|
||||||
loaded++;
|
loaded++;
|
||||||
cb?.();
|
if (isCurrent()) {
|
||||||
return;
|
if (loaded % 12 === 0 || loaded === TOTAL_FRAMES) {
|
||||||
}
|
this.loadProgress.set(Math.round((loaded / TOTAL_FRAMES) * 100));
|
||||||
const img = new Image();
|
this.isLoaded.set(loaded === TOTAL_FRAMES);
|
||||||
img.src = this.getFramePath(index);
|
}
|
||||||
img.onload = () => {
|
if (loaded === 1 || loaded === TOTAL_FRAMES) {
|
||||||
SHARED_IMAGE_CACHE[index] = img;
|
this.renderFrame(this.isReducedMotion ? 1 : Math.round(this.currentInterpolatedFrame));
|
||||||
loaded++;
|
|
||||||
cb?.();
|
|
||||||
if (loaded % 12 === 0 || loaded === TOTAL_FRAMES) {
|
|
||||||
this.loadProgress.set(Math.round((loaded / TOTAL_FRAMES) * 100));
|
|
||||||
if (loaded === TOTAL_FRAMES) {
|
|
||||||
isPreloadDone = true;
|
|
||||||
this.isLoaded.set(true);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
img.onerror = () => {
|
|
||||||
loaded++;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
loadSingle(startFrame, () => {
|
void loadSingle(startFrame).then(() => {
|
||||||
this.renderFrame(startFrame);
|
if (!isCurrent()) return;
|
||||||
for (let i = 1; i <= TOTAL_FRAMES; i++) {
|
for (let i = 1; i <= TOTAL_FRAMES; i++) {
|
||||||
if (i !== startFrame) loadSingle(i);
|
if (i !== startFrame) void loadSingle(i);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private getFramePath(index: number): string {
|
private getFramePath(mode: ThemeMode, index: number): string {
|
||||||
const padded = String(index).padStart(3, '0');
|
const padded = String(index).padStart(3, '0');
|
||||||
return `/assets/images/thinkpad-sequence/ezgif-frame-${padded}.jpg`;
|
const folder = mode === 'light' ? 'thinkpad-sequence-light' : 'thinkpad-sequence';
|
||||||
|
return `/assets/images/${folder}/ezgif-frame-${padded}.jpg`;
|
||||||
}
|
}
|
||||||
|
|
||||||
private onScroll = (): void => {
|
private onScroll = (): void => {
|
||||||
|
|
@ -189,6 +198,7 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
};
|
};
|
||||||
|
|
||||||
private onResize = (): void => {
|
private onResize = (): void => {
|
||||||
|
this.isDesktop.set(window.innerWidth > 900);
|
||||||
if (typeof window !== 'undefined' && window.innerWidth <= 900) {
|
if (typeof window !== 'undefined' && window.innerWidth <= 900) {
|
||||||
if (this.animationFrameId !== null) {
|
if (this.animationFrameId !== null) {
|
||||||
cancelAnimationFrame(this.animationFrameId);
|
cancelAnimationFrame(this.animationFrameId);
|
||||||
|
|
@ -271,30 +281,30 @@ export class Hero3dComponent implements OnInit, AfterViewInit, OnDestroy {
|
||||||
|
|
||||||
private getBestFrame(targetIndex: number): HTMLImageElement | null {
|
private getBestFrame(targetIndex: number): HTMLImageElement | null {
|
||||||
const rounded = Math.min(Math.max(1, Math.round(targetIndex)), TOTAL_FRAMES);
|
const rounded = Math.min(Math.max(1, Math.round(targetIndex)), TOTAL_FRAMES);
|
||||||
if (SHARED_IMAGE_CACHE[rounded]?.complete) return SHARED_IMAGE_CACHE[rounded];
|
if (this.images[rounded]?.naturalWidth) return this.images[rounded];
|
||||||
|
|
||||||
for (let offset = 1; offset < TOTAL_FRAMES; offset++) {
|
for (let offset = 1; offset < TOTAL_FRAMES; offset++) {
|
||||||
const prev = rounded - offset;
|
const prev = rounded - offset;
|
||||||
if (prev >= 1 && SHARED_IMAGE_CACHE[prev]?.complete) return SHARED_IMAGE_CACHE[prev];
|
if (prev >= 1 && this.images[prev]?.naturalWidth) return this.images[prev];
|
||||||
const next = rounded + offset;
|
const next = rounded + offset;
|
||||||
if (next <= TOTAL_FRAMES && SHARED_IMAGE_CACHE[next]?.complete) return SHARED_IMAGE_CACHE[next];
|
if (next <= TOTAL_FRAMES && this.images[next]?.naturalWidth) return this.images[next];
|
||||||
}
|
}
|
||||||
return SHARED_IMAGE_CACHE[1]?.complete ? SHARED_IMAGE_CACHE[1] : null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
private renderFrame(targetIndex: number): void {
|
private renderFrame(targetIndex: number): void {
|
||||||
if (!this.ctx || !this.canvasRef) return;
|
if (!this.ctx || !this.canvasRef) return;
|
||||||
this.resizeCanvas();
|
this.resizeCanvas();
|
||||||
|
|
||||||
const img = this.getBestFrame(targetIndex);
|
|
||||||
if (!img || !img.complete) return;
|
|
||||||
|
|
||||||
const canvas = this.canvasRef.nativeElement;
|
const canvas = this.canvasRef.nativeElement;
|
||||||
const ctx = this.ctx;
|
const ctx = this.ctx;
|
||||||
|
|
||||||
ctx.fillStyle = '#000000';
|
ctx.fillStyle = this.themeService.isLightMode() ? '#d9d9d9' : '#000000';
|
||||||
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
||||||
|
|
||||||
|
const img = this.getBestFrame(targetIndex);
|
||||||
|
if (!img) return;
|
||||||
|
|
||||||
const imgAspect = 16 / 9;
|
const imgAspect = 16 / 9;
|
||||||
const drawW = canvas.width;
|
const drawW = canvas.width;
|
||||||
const drawH = canvas.width / imgAspect;
|
const drawH = canvas.width / imgAspect;
|
||||||
|
|
|
||||||
|
|
@ -16,57 +16,77 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ==============================================================================
|
/* ==============================================================================
|
||||||
HEADER MINIMALISTA FLOTANTE (Glassmorphism & Cyber-Zen)
|
NAVBAR FLOTANTE GLASSMORPHISM (Barra desprendida con vidrio esmerilado)
|
||||||
============================================================================== */
|
============================================================================== */
|
||||||
|
|
||||||
.zen-header {
|
.zen-header {
|
||||||
|
--glass-bg: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)), rgba(12, 14, 20, 0.55);
|
||||||
|
--glass-edge: rgba(255, 255, 255, 0.09);
|
||||||
|
--glass-shadow: 0 10px 40px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.08);
|
||||||
|
--glass-track: rgba(255, 255, 255, 0.04);
|
||||||
|
--glass-chip: rgba(255, 255, 255, 0.1);
|
||||||
|
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 12px;
|
||||||
left: 0;
|
left: 50%;
|
||||||
right: 0;
|
transform: translateX(-50%);
|
||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
height: 56px;
|
|
||||||
padding: 0 clamp(0.75rem, 2vw, 2rem);
|
|
||||||
background: rgba(10, 10, 11, 0.88);
|
|
||||||
backdrop-filter: blur(14px) saturate(160%);
|
|
||||||
border-bottom: 1px solid var(--zen-border-subtle);
|
|
||||||
gap: var(--space-3);
|
gap: var(--space-3);
|
||||||
|
width: min(1240px, calc(100% - 24px));
|
||||||
|
height: 52px;
|
||||||
|
padding: 0 var(--space-2) 0 var(--space-4);
|
||||||
|
background: var(--glass-bg);
|
||||||
|
backdrop-filter: blur(20px) saturate(180%);
|
||||||
|
-webkit-backdrop-filter: blur(20px) saturate(180%);
|
||||||
|
border: 1px solid var(--glass-edge);
|
||||||
|
border-radius: var(--zen-radius-md);
|
||||||
|
box-shadow: var(--glass-shadow);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .zen-header {
|
||||||
|
--glass-bg: linear-gradient(135deg, rgba(255, 255, 255, 0.75), rgba(255, 255, 255, 0.45));
|
||||||
|
--glass-edge: rgba(15, 23, 42, 0.08);
|
||||||
|
--glass-shadow: 0 10px 40px rgba(15, 23, 42, 0.1), inset 0 1px 0 #ffffff;
|
||||||
|
--glass-track: rgba(15, 23, 42, 0.04);
|
||||||
|
--glass-chip: #ffffff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.brand-block-btn {
|
.brand-block-btn {
|
||||||
background: none;
|
background: none;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
transition: transform 0.2s ease;
|
transition: opacity var(--transition-fast);
|
||||||
}
|
}
|
||||||
|
|
||||||
.brand-block-btn:hover {
|
.brand-block-btn:hover {
|
||||||
transform: scale(1.05);
|
opacity: 0.75;
|
||||||
}
|
}
|
||||||
|
|
||||||
.brand-logo {
|
.brand-logo {
|
||||||
height: 30px;
|
height: 28px;
|
||||||
width: auto;
|
width: auto;
|
||||||
object-fit: contain;
|
object-fit: contain;
|
||||||
border-radius: var(--zen-radius-xs);
|
border-radius: var(--zen-radius-xs);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Barra de Navegación Rápida */
|
/* Riel de navegación hundido con chip activo elevado */
|
||||||
.zen-nav {
|
.zen-nav {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 4px;
|
gap: 2px;
|
||||||
|
padding: 3px;
|
||||||
|
background: var(--glass-track);
|
||||||
|
border: 1px solid var(--glass-edge);
|
||||||
|
border-radius: var(--zen-radius-sm);
|
||||||
overflow-x: auto;
|
overflow-x: auto;
|
||||||
scrollbar-width: none;
|
scrollbar-width: none;
|
||||||
-webkit-overflow-scrolling: touch;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.zen-nav::-webkit-scrollbar {
|
.zen-nav::-webkit-scrollbar {
|
||||||
|
|
@ -74,28 +94,40 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-item {
|
.nav-item {
|
||||||
|
position: relative;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
border: 1px solid transparent;
|
border: none;
|
||||||
color: var(--zen-text-secondary);
|
color: var(--zen-text-secondary);
|
||||||
font-family: var(--font-sans);
|
font-family: var(--font-sans);
|
||||||
font-size: 0.8125rem;
|
font-size: 0.8125rem;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
padding: 5px 12px;
|
padding: 6px 14px;
|
||||||
border-radius: var(--zen-radius-xs);
|
border-radius: var(--zen-radius-xs);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: all 0.2s ease;
|
transition: color var(--transition-fast), background var(--transition-fast);
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-item:hover {
|
.nav-item:hover {
|
||||||
color: var(--zen-text-primary);
|
color: var(--zen-text-primary);
|
||||||
background: rgba(255, 255, 255, 0.05);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-item.active {
|
.nav-item.active {
|
||||||
color: var(--zen-accent-kintsugi);
|
color: var(--zen-text-primary);
|
||||||
background: rgba(197, 155, 39, 0.12);
|
background: var(--glass-chip);
|
||||||
border-color: rgba(197, 155, 39, 0.4);
|
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
|
||||||
|
}
|
||||||
|
|
||||||
|
.nav-item.active::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
left: 50%;
|
||||||
|
bottom: 2px;
|
||||||
|
width: 14px;
|
||||||
|
height: 2px;
|
||||||
|
transform: translateX(-50%);
|
||||||
|
background: var(--zen-accent-kintsugi);
|
||||||
|
border-radius: 1px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.header-right-group {
|
.header-right-group {
|
||||||
|
|
@ -109,87 +141,58 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
justify-content: center;
|
font-family: var(--font-mono);
|
||||||
font-family: var(--font-sans);
|
line-height: 1.2;
|
||||||
line-height: 1.25;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.live-clock {
|
.live-clock {
|
||||||
font-size: 0.8125rem;
|
font-size: 0.8125rem;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
color: var(--zen-text-primary);
|
color: var(--zen-text-primary);
|
||||||
letter-spacing: 0.02em;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.location-label {
|
.location-label {
|
||||||
font-size: 0.6875rem;
|
font-size: 0.625rem;
|
||||||
color: var(--zen-text-muted);
|
color: var(--zen-text-muted);
|
||||||
|
letter-spacing: 0.04em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.lang-toggle-btn {
|
/* Control segmentado: idioma + tema en una sola pieza de vidrio */
|
||||||
font-family: var(--font-sans);
|
.header-controls {
|
||||||
font-size: 0.75rem;
|
display: flex;
|
||||||
font-weight: 700;
|
align-items: center;
|
||||||
color: var(--zen-text-secondary);
|
background: var(--glass-track);
|
||||||
background: var(--zen-bg-surface);
|
border: 1px solid var(--glass-edge);
|
||||||
border: 1px solid var(--zen-border-subtle);
|
border-radius: var(--zen-radius-sm);
|
||||||
border-radius: var(--zen-radius-xs);
|
overflow: hidden;
|
||||||
padding: 4px 8px;
|
|
||||||
cursor: pointer;
|
|
||||||
transition: var(--transition-fast);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.lang-toggle-btn:hover {
|
.lang-toggle-btn,
|
||||||
border-color: var(--zen-accent-kintsugi);
|
|
||||||
color: var(--zen-accent-kintsugi);
|
|
||||||
background: var(--zen-bg-elevated);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Botón Conmutador de Modo Claro / Oscuro (Glassmorphism) */
|
|
||||||
.theme-toggle-btn {
|
.theme-toggle-btn {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 32px;
|
height: 34px;
|
||||||
height: 32px;
|
min-width: 36px;
|
||||||
background: var(--zen-bg-surface);
|
padding: 0 10px;
|
||||||
border: 1px solid var(--zen-border-subtle);
|
background: transparent;
|
||||||
border-radius: var(--zen-radius-xs);
|
border: none;
|
||||||
color: var(--zen-text-primary);
|
color: var(--zen-text-secondary);
|
||||||
|
font-family: var(--font-mono);
|
||||||
|
font-size: 0.75rem;
|
||||||
|
font-weight: 700;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
|
transition: color var(--transition-fast), background var(--transition-fast);
|
||||||
padding: 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.theme-toggle-btn {
|
||||||
|
border-left: 1px solid var(--glass-edge);
|
||||||
|
}
|
||||||
|
|
||||||
|
.lang-toggle-btn:hover,
|
||||||
.theme-toggle-btn:hover {
|
.theme-toggle-btn:hover {
|
||||||
border-color: var(--zen-border-focus);
|
color: var(--zen-accent-kintsugi);
|
||||||
background: var(--zen-bg-elevated);
|
background: var(--glass-chip);
|
||||||
transform: scale(1.05);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Modo Claro Adaptativo para el Header y Navegación */
|
|
||||||
:host-context([data-theme='zen-light']) .zen-header,
|
|
||||||
:host-context(body.theme-light) .zen-header {
|
|
||||||
background: rgba(248, 249, 251, 0.88);
|
|
||||||
border-bottom: 1px solid var(--zen-border-subtle, rgba(15, 23, 42, 0.08));
|
|
||||||
}
|
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .nav-item,
|
|
||||||
:host-context(body.theme-light) .nav-item {
|
|
||||||
color: var(--zen-text-secondary, #475569);
|
|
||||||
}
|
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .nav-item:hover,
|
|
||||||
:host-context(body.theme-light) .nav-item:hover {
|
|
||||||
color: var(--zen-text-primary, #0f172a);
|
|
||||||
background: rgba(15, 23, 42, 0.05);
|
|
||||||
}
|
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .nav-item.active,
|
|
||||||
:host-context(body.theme-light) .nav-item.active {
|
|
||||||
color: var(--zen-text-primary, #0f172a);
|
|
||||||
background: rgba(15, 23, 42, 0.08);
|
|
||||||
border-color: rgba(15, 23, 42, 0.25);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .cyber-matrix-stage-wrapper,
|
:host-context([data-theme='zen-light']) .cyber-matrix-stage-wrapper,
|
||||||
|
|
@ -218,7 +221,7 @@
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 01. HERO SECTION (Modo Oscuro con Laptop 3D al scroll & Modo Claro estilo Vercel) */
|
/* 01. HERO SECTION (Laptop 3D al scroll en ambos temas) */
|
||||||
.hero-section {
|
.hero-section {
|
||||||
position: relative;
|
position: relative;
|
||||||
z-index: 10;
|
z-index: 10;
|
||||||
|
|
@ -226,11 +229,9 @@
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.hero-vercel-section {
|
:host-context([data-theme='zen-light']) .hero-section,
|
||||||
position: relative;
|
:host-context(body.theme-light) .hero-section {
|
||||||
z-index: 10;
|
background-color: #d9d9d9;
|
||||||
background-color: #ffffff;
|
|
||||||
width: 100%;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* CONTENEDOR MAESTRO DE ETAPAS PANTALLA COMPLETA CON MATRIX RAIN */
|
/* CONTENEDOR MAESTRO DE ETAPAS PANTALLA COMPLETA CON MATRIX RAIN */
|
||||||
|
|
@ -255,6 +256,11 @@
|
||||||
opacity: 0.28;
|
opacity: 0.28;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .global-matrix-bg,
|
||||||
|
:host-context(body.theme-light) .global-matrix-bg {
|
||||||
|
opacity: 0.38;
|
||||||
|
}
|
||||||
|
|
||||||
/* ETAPAS EN PANTALLA COMPLETA (100vh con centrado vertical y espacio negativo Zen) */
|
/* ETAPAS EN PANTALLA COMPLETA (100vh con centrado vertical y espacio negativo Zen) */
|
||||||
.fullscreen-stage {
|
.fullscreen-stage {
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
|
|
@ -348,7 +354,9 @@
|
||||||
|
|
||||||
@media (max-width: 640px) {
|
@media (max-width: 640px) {
|
||||||
.zen-header {
|
.zen-header {
|
||||||
padding: 0 0.75rem;
|
top: 8px;
|
||||||
|
width: calc(100% - 16px);
|
||||||
|
padding: 0 var(--space-1) 0 var(--space-2);
|
||||||
}
|
}
|
||||||
|
|
||||||
.time-location-block {
|
.time-location-block {
|
||||||
|
|
|
||||||
|
|
@ -78,13 +78,12 @@
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
<div class="header-right-group">
|
<div class="header-right-group">
|
||||||
<app-telemetry-hud></app-telemetry-hud>
|
|
||||||
|
|
||||||
<div class="time-location-block">
|
<div class="time-location-block">
|
||||||
<span class="live-clock">{{ currentTime() }}</span>
|
<span class="live-clock">{{ currentTime() }}</span>
|
||||||
<span class="location-label"> {{ i18n.t().location }}</span>
|
<span class="location-label"> {{ i18n.t().location }}</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="header-controls">
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
class="lang-toggle-btn"
|
class="lang-toggle-btn"
|
||||||
|
|
@ -120,31 +119,21 @@
|
||||||
</svg>
|
</svg>
|
||||||
}
|
}
|
||||||
</button>
|
</button>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<!-- SECCIÓN 01: Hero Adaptativo (Modo Claro Vercel / Modo Oscuro Laptop 3D) -->
|
<!-- SECCIÓN 01: Laptop animada al scroll con una secuencia por tema -->
|
||||||
@if (themeService.isLightMode()) {
|
<section id="hero" class="landing-section hero-section">
|
||||||
<section id="hero" class="landing-section hero-vercel-section">
|
<app-hero-3d></app-hero-3d>
|
||||||
<app-hero-vercel
|
<app-tech-stack-strip></app-tech-stack-strip>
|
||||||
(explore)="scrollToSection('projects')"
|
</section>
|
||||||
(terminal)="scrollToSection('terminal')"
|
|
||||||
(contact)="scrollToSection('contact')"
|
|
||||||
></app-hero-vercel>
|
|
||||||
</section>
|
|
||||||
} @else {
|
|
||||||
<section id="hero" class="landing-section hero-section">
|
|
||||||
<app-hero-3d></app-hero-3d>
|
|
||||||
<app-tech-stack-strip></app-tech-stack-strip>
|
|
||||||
</section>
|
|
||||||
}
|
|
||||||
|
|
||||||
<!-- CONTENEDOR DE SECCIONES CON LLUVIA MATRIX AMBIENTAL (PANTALLA COMPLETA) -->
|
<!-- CONTENEDOR DE SECCIONES CON LLUVIA MATRIX AMBIENTAL (PANTALLA COMPLETA) -->
|
||||||
<div class="cyber-matrix-stage-wrapper" [class.is-light]="themeService.isLightMode()">
|
<div class="cyber-matrix-stage-wrapper" [class.is-light]="themeService.isLightMode()">
|
||||||
<!-- Lienzo Matrix Global activo en Dark Mode para estas secciones -->
|
<!-- Lienzo Matrix Global activo en Dark Mode para estas secciones -->
|
||||||
@if (themeService.isDarkMode()) {
|
<!-- Lluvia Matrix ambiental continua (Visible en modo oscuro y claro) -->
|
||||||
<app-matrix-rain class="global-matrix-bg"></app-matrix-rain>
|
<app-matrix-rain class="global-matrix-bg"></app-matrix-rain>
|
||||||
}
|
|
||||||
|
|
||||||
<!-- SECCIÓN 02: Módulos Interactivos (Perfil Técnico & Retro Monitor CRT) -->
|
<!-- SECCIÓN 02: Módulos Interactivos (Perfil Técnico & Retro Monitor CRT) -->
|
||||||
<section id="retro" class="landing-section fullscreen-stage">
|
<section id="retro" class="landing-section fullscreen-stage">
|
||||||
|
|
|
||||||
|
|
@ -17,9 +17,7 @@ import { ContactSectionComponent } from '../contact-section/contact-section.comp
|
||||||
import { TechnicalProfileComponent } from '../technical-profile/technical-profile.component';
|
import { TechnicalProfileComponent } from '../technical-profile/technical-profile.component';
|
||||||
import { IncidentSimulatorComponent } from '../incident-simulator/incident-simulator.component';
|
import { IncidentSimulatorComponent } from '../incident-simulator/incident-simulator.component';
|
||||||
import { ChatBotComponent } from '../chat-bot/chat-bot.component';
|
import { ChatBotComponent } from '../chat-bot/chat-bot.component';
|
||||||
import { TelemetryHudComponent } from '../telemetry-hud/telemetry-hud.component';
|
|
||||||
import { MatrixRainComponent } from '../../shared/components/matrix-rain/matrix-rain.component';
|
import { MatrixRainComponent } from '../../shared/components/matrix-rain/matrix-rain.component';
|
||||||
import { HeroVercelComponent } from '../hero-vercel/hero-vercel.component';
|
|
||||||
import { TechStackStripComponent } from '../../shared/components/tech-stack-strip/tech-stack-strip.component';
|
import { TechStackStripComponent } from '../../shared/components/tech-stack-strip/tech-stack-strip.component';
|
||||||
import { I18nService } from '../../../application/services/i18n.service';
|
import { I18nService } from '../../../application/services/i18n.service';
|
||||||
import { ThemeService } from '../../../application/services/theme.service';
|
import { ThemeService } from '../../../application/services/theme.service';
|
||||||
|
|
@ -47,9 +45,7 @@ export const LANDING_SECTIONS: readonly LandingSection[] = [
|
||||||
TechnicalProfileComponent,
|
TechnicalProfileComponent,
|
||||||
IncidentSimulatorComponent,
|
IncidentSimulatorComponent,
|
||||||
ChatBotComponent,
|
ChatBotComponent,
|
||||||
TelemetryHudComponent,
|
|
||||||
MatrixRainComponent,
|
MatrixRainComponent,
|
||||||
HeroVercelComponent,
|
|
||||||
TechStackStripComponent
|
TechStackStripComponent
|
||||||
],
|
],
|
||||||
templateUrl: './landing.component.html',
|
templateUrl: './landing.component.html',
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,25 @@
|
||||||
filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.45));
|
filter: drop-shadow(0 20px 30px rgba(0, 0, 0, 0.45));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .monitor-background-img,
|
||||||
|
:host-context(body.theme-light) .monitor-background-img {
|
||||||
|
filter: drop-shadow(0 12px 24px rgba(15, 23, 42, 0.08));
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .vintage-monitor-wrapper::after,
|
||||||
|
:host-context(body.theme-light) .vintage-monitor-wrapper::after {
|
||||||
|
content: '';
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 18%;
|
||||||
|
width: 64%;
|
||||||
|
height: 24px;
|
||||||
|
background: radial-gradient(ellipse at center, rgba(15, 23, 42, 0.12) 0%, transparent 70%);
|
||||||
|
filter: blur(8px);
|
||||||
|
pointer-events: none;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
/* Área de Pantalla CRT Calibrada al Milímetro (81.83% del ancho del chasis) */
|
/* Área de Pantalla CRT Calibrada al Milímetro (81.83% del ancho del chasis) */
|
||||||
.monitor-screen-glass {
|
.monitor-screen-glass {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
|
|
|
||||||
|
|
@ -66,7 +66,8 @@
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .ascii-portrait,
|
:host-context([data-theme='zen-light']) .ascii-portrait,
|
||||||
:host-context(body.theme-light) .ascii-portrait {
|
:host-context(body.theme-light) .ascii-portrait {
|
||||||
color: #475569;
|
color: #0f172a;
|
||||||
|
opacity: 0.88;
|
||||||
}
|
}
|
||||||
|
|
||||||
.about-description {
|
.about-description {
|
||||||
|
|
|
||||||
|
|
@ -238,7 +238,83 @@
|
||||||
|
|
||||||
:host-context([data-theme='zen-light']) .arch-terminal-card,
|
:host-context([data-theme='zen-light']) .arch-terminal-card,
|
||||||
:host-context(body.theme-light) .arch-terminal-card {
|
:host-context(body.theme-light) .arch-terminal-card {
|
||||||
box-shadow: 0 20px 48px rgba(15, 23, 42, 0.16), 0 1px 3px rgba(15, 23, 42, 0.08);
|
background-color: #ffffff;
|
||||||
|
box-shadow: 0 20px 48px rgba(15, 23, 42, 0.12), 0 1px 3px rgba(15, 23, 42, 0.06);
|
||||||
border-color: rgba(15, 23, 42, 0.12);
|
border-color: rgba(15, 23, 42, 0.12);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-window-header,
|
||||||
|
:host-context(body.theme-light) .term-window-header {
|
||||||
|
background-color: #f1f5f9;
|
||||||
|
border-bottom: 1px solid rgba(15, 23, 42, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-title-block,
|
||||||
|
:host-context(body.theme-light) .term-title-block {
|
||||||
|
color: #475569;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-body,
|
||||||
|
:host-context(body.theme-light) .term-body {
|
||||||
|
background: radial-gradient(circle at top right, rgba(2, 132, 199, 0.04) 0%, transparent 60%);
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-image-banner,
|
||||||
|
:host-context(body.theme-light) .term-image-banner {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-banner-text,
|
||||||
|
:host-context([data-theme='zen-light']) .term-banner,
|
||||||
|
:host-context(body.theme-light) .term-banner-text,
|
||||||
|
:host-context(body.theme-light) .term-banner {
|
||||||
|
color: #0369a1;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-output,
|
||||||
|
:host-context(body.theme-light) .term-output {
|
||||||
|
color: #0f172a;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .typed-command,
|
||||||
|
:host-context([data-theme='zen-light']) .term-input,
|
||||||
|
:host-context(body.theme-light) .typed-command,
|
||||||
|
:host-context(body.theme-light) .term-input {
|
||||||
|
color: #0f172a;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-ghost-text,
|
||||||
|
:host-context(body.theme-light) .term-ghost-text {
|
||||||
|
color: #94a3b8;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .prompt-user,
|
||||||
|
:host-context(body.theme-light) .prompt-user {
|
||||||
|
color: #0284c7;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .prompt-path,
|
||||||
|
:host-context(body.theme-light) .prompt-path {
|
||||||
|
color: #7c3aed;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .prompt-symbol,
|
||||||
|
:host-context(body.theme-light) .prompt-symbol {
|
||||||
|
color: #059669;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .term-ascii,
|
||||||
|
:host-context(body.theme-light) .term-ascii {
|
||||||
|
color: #2563eb;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .git-branch,
|
||||||
|
:host-context(body.theme-light) .git-branch {
|
||||||
|
color: #64748b;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host-context([data-theme='zen-light']) .branch-name,
|
||||||
|
:host-context(body.theme-light) .branch-name {
|
||||||
|
color: #7c3aed;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ import {
|
||||||
NgZone,
|
NgZone,
|
||||||
inject
|
inject
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
|
import { ThemeService } from '../../../../application/services/theme.service';
|
||||||
|
|
||||||
interface RainColumn {
|
interface RainColumn {
|
||||||
x: number;
|
x: number;
|
||||||
|
|
@ -36,6 +37,7 @@ export class MatrixRainComponent implements AfterViewInit, OnDestroy {
|
||||||
|
|
||||||
private readonly hostRef = inject(ElementRef<HTMLElement>);
|
private readonly hostRef = inject(ElementRef<HTMLElement>);
|
||||||
private readonly ngZone = inject(NgZone);
|
private readonly ngZone = inject(NgZone);
|
||||||
|
private readonly themeService = inject(ThemeService);
|
||||||
|
|
||||||
private readonly columns: RainColumn[] = [];
|
private readonly columns: RainColumn[] = [];
|
||||||
private context?: CanvasRenderingContext2D;
|
private context?: CanvasRenderingContext2D;
|
||||||
|
|
@ -184,6 +186,8 @@ export class MatrixRainComponent implements AfterViewInit, OnDestroy {
|
||||||
this.context.textAlign = 'center';
|
this.context.textAlign = 'center';
|
||||||
this.context.textBaseline = 'top';
|
this.context.textBaseline = 'top';
|
||||||
|
|
||||||
|
const isLight = this.themeService.isLightMode();
|
||||||
|
|
||||||
for (const column of this.columns) {
|
for (const column of this.columns) {
|
||||||
for (let i = 0; i < column.characters.length; i++) {
|
for (let i = 0; i < column.characters.length; i++) {
|
||||||
const charY = column.y + i * fontSize;
|
const charY = column.y + i * fontSize;
|
||||||
|
|
@ -197,15 +201,28 @@ export class MatrixRainComponent implements AfterViewInit, OnDestroy {
|
||||||
|
|
||||||
if (alpha <= 0) continue;
|
if (alpha <= 0) continue;
|
||||||
|
|
||||||
this.context.fillStyle = isHead
|
if (isLight) {
|
||||||
? `rgba(235, 255, 240, ${Math.min(1, alpha + 0.4)})`
|
this.context.fillStyle = isHead
|
||||||
: isHighlight
|
? `rgba(15, 23, 42, ${Math.min(1, alpha + 0.45)})`
|
||||||
? `rgba(80, 255, 130, ${alpha})`
|
: isHighlight
|
||||||
: `rgba(20, 185, 85, ${alpha})`;
|
? `rgba(21, 128, 61, ${Math.min(1, alpha + 0.25)})`
|
||||||
|
: `rgba(22, 101, 52, ${alpha * 0.9})`;
|
||||||
|
|
||||||
if (isHead || isHighlight) {
|
if (isHead || isHighlight) {
|
||||||
this.context.shadowColor = 'rgba(40, 255, 110, 0.85)';
|
this.context.shadowColor = 'rgba(21, 128, 61, 0.4)';
|
||||||
this.context.shadowBlur = isHead ? 8 : 4;
|
this.context.shadowBlur = isHead ? 4 : 2;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.context.fillStyle = isHead
|
||||||
|
? `rgba(235, 255, 240, ${Math.min(1, alpha + 0.4)})`
|
||||||
|
: isHighlight
|
||||||
|
? `rgba(80, 255, 130, ${alpha})`
|
||||||
|
: `rgba(20, 185, 85, ${alpha})`;
|
||||||
|
|
||||||
|
if (isHead || isHighlight) {
|
||||||
|
this.context.shadowColor = 'rgba(40, 255, 110, 0.85)';
|
||||||
|
this.context.shadowBlur = isHead ? 8 : 4;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
this.context.fillText(column.characters[i], column.x, charY);
|
this.context.fillText(column.characters[i], column.x, charY);
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 280 KiB After Width: | Height: | Size: 462 KiB |
|
After Width: | Height: | Size: 64 KiB |
|
After Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 84 KiB |
|
After Width: | Height: | Size: 85 KiB |
|
After Width: | Height: | Size: 72 KiB |
|
After Width: | Height: | Size: 62 KiB |
|
After Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 50 KiB |
|
After Width: | Height: | Size: 45 KiB |
|
After Width: | Height: | Size: 40 KiB |
|
After Width: | Height: | Size: 38 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 37 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 36 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 35 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 34 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
After Width: | Height: | Size: 32 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 21 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 27 KiB |
|
After Width: | Height: | Size: 28 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 29 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |
|
After Width: | Height: | Size: 31 KiB |