mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-12-16 15:40:11 +01:00
feat(docs): added get premium modal in landing
fix(docs): fixed styles for get download modal
This commit is contained in:
parent
780e230503
commit
b72fb30dd1
13 changed files with 287 additions and 6 deletions
|
|
@ -42,5 +42,6 @@
|
|||
</div>
|
||||
|
||||
<ngx-download-admin></ngx-download-admin>
|
||||
<ngx-premium></ngx-premium>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
$color-active: nb-theme(color-active-fg);
|
||||
|
||||
display: flex;
|
||||
padding: 3.375rem 0 0;
|
||||
padding: 3.375rem 0;
|
||||
max-width: 120rem;
|
||||
margin: 0 auto;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,3 @@
|
|||
<button matRipple (click)="openDialog()" class="btn btn-download">
|
||||
<button (click)="openDialog()" class="btn btn-download">
|
||||
Download
|
||||
</button>
|
||||
|
|
|
|||
|
|
@ -9,6 +9,7 @@
|
|||
|
||||
@include nb-install-component() {
|
||||
.btn {
|
||||
display: block;
|
||||
font-family: nb-theme(font-main), sans-serif;
|
||||
border-radius: 3px;
|
||||
border: none;
|
||||
|
|
|
|||
|
|
@ -1,8 +1,12 @@
|
|||
<nb-card>
|
||||
<nb-card-body>
|
||||
<nb-card-header>
|
||||
<span>Download</span>
|
||||
<div class="close-icon" (click)="closeDialog()">
|
||||
<i [innerHTML]="'close' | eva: { width: 26, height: 26, fill: '#222b45' }"></i>
|
||||
</div>
|
||||
</nb-card-header>
|
||||
<nb-card-body>
|
||||
|
||||
<div id="hubspotForm"></div>
|
||||
</nb-card-body>
|
||||
</nb-card>
|
||||
|
|
|
|||
|
|
@ -9,15 +9,22 @@
|
|||
@import '../../../@theme/styles/themes';
|
||||
|
||||
@include nb-install-component() {
|
||||
nb-card-body {
|
||||
position: relative;
|
||||
|
||||
nb-card {
|
||||
width: 30rem;
|
||||
}
|
||||
|
||||
nb-card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.close-icon {
|
||||
cursor: pointer;
|
||||
position: absolute;
|
||||
margin-left: auto;
|
||||
right: 0.1rem;
|
||||
top: 0.1rem;
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
::ng-deep .custom-form {
|
||||
|
|
@ -56,6 +63,20 @@
|
|||
}
|
||||
}
|
||||
|
||||
.hs-richtext .modal-body {
|
||||
padding: 0;
|
||||
margin-bottom: 1rem;
|
||||
p {
|
||||
margin-bottom: 0;
|
||||
text-align: left ! important;
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
|
||||
.hs-recaptcha {
|
||||
margin-top: 1rem;
|
||||
}
|
||||
|
||||
.hs-error-msgs {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,11 @@
|
|||
<nb-card>
|
||||
<nb-card-header>
|
||||
<span>Download</span>
|
||||
<div class="close-icon" (click)="closeDialog()">
|
||||
<i [innerHTML]="'close' | eva: { width: 26, height: 26, fill: '#222b45' }"></i>
|
||||
</div>
|
||||
</nb-card-header>
|
||||
<nb-card-body>
|
||||
<div id="hubspotForm"></div>
|
||||
</nb-card-body>
|
||||
</nb-card>
|
||||
|
|
@ -0,0 +1,113 @@
|
|||
/**
|
||||
* @license
|
||||
* Copyright Akveo. All Rights Reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*/
|
||||
|
||||
@import '~@nebular/theme/styles/global/breakpoints';
|
||||
|
||||
@import '../../../@theme/styles/themes';
|
||||
|
||||
@include nb-install-component() {
|
||||
|
||||
nb-card {
|
||||
width: 30rem;
|
||||
}
|
||||
|
||||
nb-card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.close-icon {
|
||||
cursor: pointer;
|
||||
margin-left: auto;
|
||||
right: 0.1rem;
|
||||
top: 0.1rem;
|
||||
width: fit-content;
|
||||
}
|
||||
|
||||
::ng-deep .custom-form {
|
||||
.modal-header {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.modal-body {
|
||||
padding-bottom: 0;
|
||||
}
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
input.hs-input {
|
||||
width: 100%;
|
||||
font-size: nb-theme(font-size-sm);
|
||||
padding: 0.75rem 1rem !important;
|
||||
border: 1px solid #e4e9f2;
|
||||
box-shadow: nb-theme(shadow-default);
|
||||
border-radius: 0.25rem;
|
||||
|
||||
&.invalid {
|
||||
box-shadow: 0 0 1.25rem 0 rgba(210, 45, 45, 0.6);
|
||||
}
|
||||
|
||||
&::placeholder {
|
||||
color: #434a59;
|
||||
opacity: 0.24;
|
||||
}
|
||||
|
||||
&:focus {
|
||||
outline: none;
|
||||
}
|
||||
}
|
||||
|
||||
.hs-richtext .modal-body {
|
||||
padding: 0;
|
||||
margin-bottom: 1rem;
|
||||
p {
|
||||
margin-bottom: 0;
|
||||
text-align: left ! important;
|
||||
}
|
||||
}
|
||||
|
||||
.hs-recaptcha {
|
||||
margin-top: 1rem;
|
||||
}
|
||||
|
||||
.hs-error-msgs {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.hs-form-required, .hs-error-msg {
|
||||
color: #f2545b;
|
||||
}
|
||||
|
||||
.hs_error_rollup {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.btn {
|
||||
margin-top: 2rem;
|
||||
font-family: nb-theme(font-main), sans-serif;
|
||||
border-radius: 3px;
|
||||
border: none;
|
||||
background-color: nb-theme(color-active-fg);
|
||||
color: #ffffff;
|
||||
padding: 1rem 2rem;
|
||||
box-shadow: nb-theme(shadow-btn);
|
||||
cursor: pointer;
|
||||
text-transform: uppercase;
|
||||
|
||||
&:hover {
|
||||
box-shadow: nb-theme(shadow-hover-green-btn);
|
||||
}
|
||||
|
||||
&:active {
|
||||
box-shadow: nb-theme(shadow-active-green-btn);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,36 @@
|
|||
/**
|
||||
* @license
|
||||
* Copyright Akveo. All Rights Reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*/
|
||||
|
||||
import { AfterViewInit, Component } from '@angular/core';
|
||||
import { NbDialogRef } from '@nebular/theme';
|
||||
|
||||
@Component({
|
||||
selector: 'ngx-premium-form',
|
||||
templateUrl: './premium-form.component.html',
|
||||
styleUrls: ['./premium-form.component.scss'],
|
||||
})
|
||||
export class PremiumFormComponent implements AfterViewInit {
|
||||
|
||||
|
||||
constructor(protected ref: NbDialogRef<PremiumFormComponent>) {
|
||||
}
|
||||
|
||||
ngAfterViewInit() {
|
||||
hbspt.forms.create({
|
||||
portalId: '2452262',
|
||||
formId: 'b066428e-c41a-4dce-bbc2-5690cf084a8f',
|
||||
target: '#hubspotForm',
|
||||
submitButtonClass: 'btn',
|
||||
css: '',
|
||||
cssClass: 'custom-form',
|
||||
redirectUrl: 'https://github.com/akveo/ngx-admin',
|
||||
});
|
||||
}
|
||||
|
||||
closeDialog() {
|
||||
this.ref.close();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,3 @@
|
|||
<button (click)="openDialog()" class="btn btn-download">
|
||||
Get ngx-admin PREMIUM for 89$
|
||||
</button>
|
||||
60
docs/app/shared/components/premium/premium.component.scss
Normal file
60
docs/app/shared/components/premium/premium.component.scss
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
/**
|
||||
* @license
|
||||
* Copyright Akveo. All Rights Reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*/
|
||||
|
||||
@import '../../../@theme/styles/themes';
|
||||
@import '~@nebular/theme/styles/global/breakpoints';
|
||||
|
||||
@include nb-install-component() {
|
||||
.btn {
|
||||
display: block;
|
||||
font-family: nb-theme(font-main), sans-serif;
|
||||
border-radius: 3px;
|
||||
border: none;
|
||||
background: #ffffff;
|
||||
color: #000000;
|
||||
padding: 1.125rem 0;
|
||||
box-shadow: nb-theme(shadow-default);
|
||||
cursor: pointer;
|
||||
text-transform: uppercase;
|
||||
|
||||
&.btn-download {
|
||||
margin-left: 1em;
|
||||
color: #ffffff;
|
||||
background-color: nb-theme(color-active-fg);
|
||||
box-shadow: nb-theme(shadow-btn);
|
||||
|
||||
&:hover {
|
||||
box-shadow: nb-theme(shadow-hover-green-btn);
|
||||
}
|
||||
|
||||
&:active {
|
||||
box-shadow: nb-theme(shadow-active-green-btn);
|
||||
}
|
||||
}
|
||||
|
||||
&.btn-download {
|
||||
margin-left: 0;
|
||||
margin-top: 1rem;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
box-shadow: nb-theme(shadow-hover-btn);
|
||||
}
|
||||
|
||||
&:active {
|
||||
box-shadow: nb-theme(shadow-active-btn);
|
||||
}
|
||||
}
|
||||
|
||||
@include media-breakpoint-down(md) {
|
||||
.btn {
|
||||
font-size: 0.7rem;
|
||||
padding-bottom: 1rem;
|
||||
padding-top: 1rem;
|
||||
}
|
||||
}
|
||||
}
|
||||
26
docs/app/shared/components/premium/premium.component.ts
Normal file
26
docs/app/shared/components/premium/premium.component.ts
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
/**
|
||||
* @license
|
||||
* Copyright Akveo. All Rights Reserved.
|
||||
* Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
*/
|
||||
|
||||
import { Component } from '@angular/core';
|
||||
import {NbDialogService} from '@nebular/theme';
|
||||
import {PremiumFormComponent} from '../premium-form/premium-form.component';
|
||||
|
||||
@Component({
|
||||
selector: 'ngx-premium',
|
||||
templateUrl: './premium.component.html',
|
||||
styleUrls: ['./premium.component.scss'],
|
||||
})
|
||||
export class PremiumComponent {
|
||||
|
||||
|
||||
constructor(private dialogService: NbDialogService) {
|
||||
}
|
||||
|
||||
openDialog() {
|
||||
this.dialogService.open(PremiumFormComponent);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -6,11 +6,15 @@ import { EvaIconsPipe } from './pipes/eva-icons.pipe';
|
|||
import { RouterModule } from '@angular/router';
|
||||
import { DownloadAdminComponent } from './components/download-admin/download-admin.component';
|
||||
import { DownloadFormComponent } from './components/download-form/download-form.component';
|
||||
import { PremiumComponent } from './components/premium/premium.component';
|
||||
import { PremiumFormComponent } from './components/premium-form/premium-form.component';
|
||||
|
||||
const component = [
|
||||
MaterialThemeLinkComponent,
|
||||
DownloadAdminComponent,
|
||||
DownloadFormComponent,
|
||||
PremiumComponent,
|
||||
PremiumFormComponent,
|
||||
];
|
||||
const pipes = [
|
||||
CapitalizePipe,
|
||||
|
|
@ -31,6 +35,7 @@ const pipes = [
|
|||
],
|
||||
entryComponents: [
|
||||
DownloadFormComponent,
|
||||
PremiumFormComponent,
|
||||
],
|
||||
exports: [
|
||||
NbPopoverModule,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue