mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-12-20 01:10:13 +01:00
feat(demo): add landing page with docs (#1951)
This commit is contained in:
parent
67c9587b87
commit
43cc3a1556
190 changed files with 15425 additions and 21 deletions
|
|
@ -0,0 +1,40 @@
|
|||
/**
|
||||
* @license
|
||||
* Copyright Akveo. All Rights Reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*/
|
||||
|
||||
import { Component, ElementRef, ViewChild } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'ngx-landing-contact-section',
|
||||
templateUrl: './contact-section.component.html',
|
||||
styleUrls: ['./contact-section.component.scss'],
|
||||
})
|
||||
export class ContactSectionComponent {
|
||||
|
||||
@ViewChild('contactForm') contactForm: HTMLFormElement;
|
||||
@ViewChild('emailInput') emailInput: ElementRef;
|
||||
|
||||
isAgree = false;
|
||||
invalid = false;
|
||||
|
||||
constructor() {
|
||||
}
|
||||
|
||||
submitForm() {
|
||||
if (!this.emailInput.nativeElement.value) {
|
||||
this.invalid = true;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
this.contactForm.nativeElement.submit();
|
||||
this.invalid = false;
|
||||
this.emailInput.nativeElement.value = '';
|
||||
}
|
||||
|
||||
get disabledControl() {
|
||||
return this.isAgree ? null : 'disabled';
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue