complete visual overhaul
This commit is contained in:
1 parent
02bc2faca0
commit
25d06ec49a
51 files changed
+694
-664
No files matched your search
@@ -9,16 +9,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
#vanta-services-bg {
|
||||
animation: fadeIn 1s ease-out;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
z-index: -100;
|
||||
}
|
||||
|
||||
.services-container {
|
||||
position: relative;
|
||||
color: white;
|
||||
@@ -40,11 +30,12 @@
|
||||
.services-header h1 {
|
||||
font-size: 2.5rem;
|
||||
background: transparent;
|
||||
border-bottom: 4px solid white;
|
||||
border-left: 6px solid white;
|
||||
border-right: 6px solid white;
|
||||
border-radius: 12px;
|
||||
margin: 8px auto 8px auto;
|
||||
max-width: 280px;
|
||||
padding: 10px;
|
||||
border-radius: 45px;
|
||||
}
|
||||
|
||||
.services-header .subtitle {
|
||||
|
||||
@@ -1,4 +1,10 @@
|
||||
<div id="vanta-services-bg"></div>
|
||||
<app-parallax
|
||||
[baseColor]="'#1a1030'"
|
||||
[bgGradient]="
|
||||
'radial-gradient(circle 120vw at center, rgba(90,78,130,0.32), transparent 40%), ' +
|
||||
'linear-gradient(180deg,#1b172c 0%, #0b0b0f 100%);'
|
||||
">
|
||||
</app-parallax>
|
||||
<div class="height-container">
|
||||
<div class="services-container">
|
||||
<div class="services-header" [ngStyle]="{'margin-top': isMobile ? '60px' : '120px'}">
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import {AfterViewInit, Component, Inject, OnDestroy, OnInit, PLATFORM_ID} from '@angular/core';
|
||||
import {VantaBackgroundService} from '../shared/services/vanta-background.service';
|
||||
import {Component, OnInit} from '@angular/core';
|
||||
import {DeviceDetectorService} from '../shared/services/device-detector.service';
|
||||
import {Title} from '@angular/platform-browser';
|
||||
import {isPlatformBrowser, NgIf, NgFor, NgStyle} from '@angular/common';
|
||||
import {NgIf, NgFor, NgStyle} from '@angular/common';
|
||||
import {TranslatePipe, TranslateService} from '@ngx-translate/core';
|
||||
import {HttpClient} from '@angular/common/http';
|
||||
import {ParallaxComponent} from '../shared/parallax/parallax.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-services',
|
||||
@@ -12,14 +12,14 @@ import {HttpClient} from '@angular/common/http';
|
||||
NgStyle,
|
||||
NgIf,
|
||||
NgFor,
|
||||
TranslatePipe
|
||||
TranslatePipe,
|
||||
ParallaxComponent
|
||||
],
|
||||
templateUrl: './services.component.html',
|
||||
styleUrl: './services.component.css'
|
||||
})
|
||||
|
||||
export class ServicesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
private readonly elementId = 'vanta-services-bg';
|
||||
export class ServicesComponent implements OnInit {
|
||||
private apiUrl = '/api/stripe/create-checkout-session';
|
||||
isMobile: boolean = false;
|
||||
activeTab: string[] = [];
|
||||
@@ -33,12 +33,10 @@ export class ServicesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
}[] = [];
|
||||
|
||||
constructor(
|
||||
private vantaService: VantaBackgroundService,
|
||||
private deviceService: DeviceDetectorService,
|
||||
private titleService: Title,
|
||||
private translate: TranslateService,
|
||||
private http: HttpClient,
|
||||
@Inject(PLATFORM_ID) private platformId: Object
|
||||
private http: HttpClient
|
||||
) {}
|
||||
|
||||
switchTab(serviceIndex: number, tab: string): void {
|
||||
@@ -48,9 +46,6 @@ export class ServicesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
ngOnInit() {
|
||||
this.titleService.setTitle('Services | itzMiney');
|
||||
this.isMobile = this.deviceService.isMobile;
|
||||
if (isPlatformBrowser(this.platformId)) {
|
||||
window.addEventListener('resize', this.onResize.bind(this));
|
||||
}
|
||||
this.loadServices();
|
||||
this.translate.onLangChange.subscribe(() => this.loadServices());
|
||||
}
|
||||
@@ -145,24 +140,6 @@ export class ServicesComponent implements OnInit, OnDestroy, AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
ngAfterViewInit() {
|
||||
this.vantaService.initVanta(this.elementId, {
|
||||
color: 0x7272bd,
|
||||
backgroundColor: 0x291c3c
|
||||
});
|
||||
}
|
||||
ngOnDestroy() {
|
||||
this.vantaService.destroyVanta(this.elementId);
|
||||
if (isPlatformBrowser(this.platformId)) {
|
||||
window.removeEventListener('resize', this.onResize);
|
||||
}
|
||||
}
|
||||
|
||||
onResize() {
|
||||
// Update the minHeight and minWidth when the window is resized
|
||||
this.vantaService.resizeVanta(this.elementId);
|
||||
}
|
||||
|
||||
checkout(priceId: string): void {
|
||||
this.http.post<any>(this.apiUrl, { priceId }).subscribe({
|
||||
next: (response) => {
|
||||
|
||||
Reference in new issue
Block a user