Skip to content

Commit

Permalink
Color Outsourcing
Browse files Browse the repository at this point in the history
  • Loading branch information
Nicola Lanzilotto committed Jan 13, 2025
1 parent 8823532 commit 7a8dd89
Show file tree
Hide file tree
Showing 105 changed files with 1,576 additions and 2,175 deletions.
81 changes: 28 additions & 53 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1080,23 +1080,11 @@ export class AppComponent implements OnInit, AfterViewInit, OnDestroy {

ngAfterViewInit() {
this.runOnRouteChange();
// this.setPrechatFormInWidgetSettings();
const elemFooter = <HTMLElement>document.querySelector('footer');
// const eleWidget = <HTMLElement>document.querySelector('#tiledesk-container');
// this.logger.log('APP.COMP - elem FOOTER ', elemFooter);
// setTimeout(() => {
// this.logger.log('[APP-COMPONENT] window', window)
// var tiledeskiframe = document.getElementById('tiledeskiframe') as HTMLIFrameElement;
// this.logger.log('[APP-COMPONENT] tiledeskiframe', tiledeskiframe)
// if (tiledeskiframe) {
// if (window && window['tiledesk'] && window['tiledesk']['angularcomponent']) {
// window['tiledesk'].angularcomponent.component.g.preChatForm = false
// }
// }
// }, 3000);


this.hideFooter();
}

hideFooter() {
const elemFooter = <HTMLElement>document.querySelector('footer');
/* HIDE FOOTER IF IS LOGIN PAGE - SIGNUP PAGE */
this.router.events.subscribe((val) => {
if (this.location.path() !== '') {
Expand Down Expand Up @@ -1140,31 +1128,19 @@ export class AppComponent implements OnInit, AfterViewInit, OnDestroy {
elemFooter.setAttribute('style', '');
}

// WIDGET HIDDEN IF THE ROUTE IS request-for-panel
// if (this.route.indexOf('/request-for-panel') !== -1) {

// if (eleWidget) {
// eleWidget.style.display = 'none';
// } else {
// this.logger.log('APP.COMP - elem WIDGET ', eleWidget)
// }
// }

} else {
// this.logger.log('»> * ', this.route)
}
});

const elemAppFooter = <HTMLElement>document.querySelector('app-footer');

this.router.events.subscribe((val) => {
if (this.location.path() !== '') {
this.route = this.location.path();
// this.logger.log('»> ', this.route)
if (this.route.indexOf('/verify') !== -1) {

elemAppFooter.setAttribute('style', 'display:none;');
// this.logger.log('DETECT LOGIN PAGE')
// tslint:disable-next-line:max-line-length
} else {

elemAppFooter.setAttribute('style', '');
Expand All @@ -1174,36 +1150,35 @@ export class AppComponent implements OnInit, AfterViewInit, OnDestroy {
// this.logger.log('»> * ', this.route)
}
});

}


// setPrechatFormInWidgetSettings() {
// this.router.events.subscribe((val) => {
// if (this.location.path() !== '') {
// this.route = this.location.path();
// // this.logger.log('»> ', this.route)
// // tslint:disable-next-line:max-line-length
// if ((this.route === '/login') || (this.route === '/signup') || (this.route === '/forgotpsw') || (this.route.indexOf('/signup-on-invitation') !== -1)) {
setPrechatFormInWidgetSettings() {
this.router.events.subscribe((val) => {
if (this.location.path() !== '') {
this.route = this.location.path();
// this.logger.log('»> ', this.route)
// tslint:disable-next-line:max-line-length
if ((this.route === '/login') || (this.route === '/signup') || (this.route === '/forgotpsw') || (this.route.indexOf('/signup-on-invitation') !== -1)) {

// this.isPageWithNav = false;
this.isPageWithNav = false;

// if (window && window['tiledeskSettings']) {
// window['tiledeskSettings']['preChatForm'] = true
// }
// } else {
if (window && window['tiledeskSettings']) {
window['tiledeskSettings']['preChatForm'] = true
}
} else {

// this.isPageWithNav = true;
// if (window && window['tiledeskSettings']) {
// if (window['tiledeskSettings']['preChatForm']) {
// delete window['tiledeskSettings']['preChatForm'];
// }
// }
// }
// // this.logger.log('APP.COMP currentUrl ', this.route, 'tiledeskSettings ', window['tiledeskSettings']);
// }
// });
// }
this.isPageWithNav = true;
if (window && window['tiledeskSettings']) {
if (window['tiledeskSettings']['preChatForm']) {
delete window['tiledeskSettings']['preChatForm'];
}
}
}
// this.logger.log('APP.COMP currentUrl ', this.route, 'tiledeskSettings ', window['tiledeskSettings']);
}
});
}

isMaps(path) {
var titlee = this.location.prepareExternalUrl(this.location.path());
Expand Down
42 changes: 31 additions & 11 deletions src/app/auth/signin/signin.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -156,10 +156,17 @@ <h2>
<label for="password">Password</label>
<input type="password" id="password" class="input" formControlName="password" autocomplete="on" required>

<div *ngIf="formErrors.password" class="is-danger" translate>
<!-- <div *ngIf="formErrors.password" class="is-danger" translate>
{{ formErrors.password }}
</div>
<!-- [disabled]="!userForm.valid" -->
</div> -->

<p class="signin-forgot-pswrd">
{{ "ForgotYourPassword" | translate }}?
<span (click)="goToResetPsw()">
{{ "ClickHere" | translate }}
</span>
</p>

<button type="submit" class="btn signin-button" [ngStyle]="{'background-color': primaryBrandColor ? primaryBrandColor : '#f0806f' }">
<span *ngIf="!showSpinnerInLoginBtn">
<!-- Login -->
Expand All @@ -168,22 +175,35 @@ <h2>
<span *ngIf="showSpinnerInLoginBtn"> <i class="fa fa-spinner fa-spin"></i></span>
</button>

<!-- <span *ngIf="userForm.valid" class="help is-success">Form Looks Valid</span> -->
<div class="left-panel-signup-link" (click)="goToSignup()">
<!-- <a routerLink="/signup"> -->

<!-- <div class="left-panel-signup-link" (click)="goToSignup()">
{{ "DontHaveAnAccountYet" | translate }}
<span style="color: #03a5e8; cursor: pointer;">
{{ "SignUp" | translate }}
</span>
<!-- </a> -->
</div>
<!-- style="color: #666666; font-size: 1.1em; text-align: center; margin-top: 16px;" -->
<p class="signin-forgot-pswrd">
</div> -->

<!-- <p class="signin-forgot-pswrd">
{{ "ForgotYourPassword" | translate }}?
<span style="color: #03a5e8; cursor:pointer" (click)="goToResetPsw()">
{{ "ClickHere" | translate }}
</span>
</p>
</p> -->

<div class="h-20"></div>
<div *ngIf="hideGoogleAuthBtn" class="auth---divider"></div>


<div class="left-panel-signup-link" (click)="goToSignup()">

{{ "DontHaveAnAccountYet" | translate }}
<span>
{{ "SignUp" | translate }}
</span>

</div>
<!-- <a *ngIf="!passReset && userForm.controls.email.valid" class="help is-info" (click)="resetPassword()">Reset Password for {{userForm.value.email}}?</a>
<p *ngIf="passReset" class="help is-info">Reset requested. Check your email instructions.</p> -->

Expand Down
44 changes: 28 additions & 16 deletions src/app/auth/signin/signin.component.scss
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,13 @@
height: 56px;
font-size: 16px;
letter-spacing: 2px;
border-radius: var(--btn-border-radius);
}

.login-container {
// padding: 30px;
max-width: 400px;
// min-width: 400px;
min-width: 400px;
width: 100% !important;
// margin: 0 auto;
}
Expand Down Expand Up @@ -163,22 +164,35 @@ input:-webkit-autofill {
.left-panel-signup-link {
margin-top: 15px;
line-height: 21px;
font-family: Poppins, Roboto, Arial, sans-serif;
font-family: var(--header-font-family);
text-align: left !important;
color: #222;
font-weight: 400;
font-size: 15px;
}

.left-panel-signup-link > span {
color: var(--blue-20);
cursor: pointer;
}

.signin-forgot-pswrd {
// text-align: center;
margin-top: 15px;
line-height: 21px;
font-family: Poppins, Roboto, Arial, sans-serif;
// margin-top: 15px;
// line-height: 21px;
// font-size: 15px;
margin-top: 0px;
line-height: 10px;
font-size: 12px;
font-family: var(--header-font-family);
text-align: left !important;
color: #222;
font-weight: 400;
font-size: 15px;
margin-bottom: 18px;
}

.signin-forgot-pswrd > span {
color: var(--blue-20);
cursor:pointer
}

label {
Expand Down Expand Up @@ -208,17 +222,15 @@ label {
}

.left {
width: 40%;
// width: 40%;
width: 0px;
left: 0;
// background-color: $brand-secodary;
// color: #f0806f;
// background-color: rgb(15, 23, 42); // old
background-color: #d3e3ee; //new
// background-image: url(https://tiledesk.com/wp-content/uploads/2023/01/background_chatboat_design.jpg?id=10568welcome-text);
}

.right {
width: 60%;
// width: 60%;
width: 100%;
right: 0;
background-color: #fff;
}
Expand Down Expand Up @@ -299,9 +311,9 @@ label {
display: none;
}

.left-panel-signup-link {
display: none;
}
// .left-panel-signup-link {
// display: none;
// }

.left-panel-gotov1-link {
display: none;
Expand Down
6 changes: 3 additions & 3 deletions src/app/auth/signup/signup.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -375,16 +375,16 @@ <h2 *ngIf="appSumoActivationEmail">
<label class="i-accept-label" for="terms">
<!-- {{ "iAgree" | translate }} -->
{{ "IAccept" | translate }}
<a *ngIf="display_terms_and_conditions_link" style="color: #03a5e8" target="_blank"
<a *ngIf="display_terms_and_conditions_link" target="_blank"
[href]="terms_and_conditions_url">
{{ "TermsAndConditions" | translate }}<span *ngIf="display_dpa" style="color: #aaa;">, </span>
</a>
<a *ngIf="display_dpa" style="color: #03a5e8" target="_blank"
<a *ngIf="display_dpa" target="_blank"
[href]="dpa_url">
DPA
</a>
<span *ngIf="display_terms_and_conditions_link"> {{ "And" | translate }} </span>
<a style="color: #03a5e8" target="_blank" [href]="privacy_policy_url">
<a target="_blank" [href]="privacy_policy_url">
{{ privacy_policy_link_text }}
</a>
<!-- [checked]="checkModel" -->
Expand Down
Loading

0 comments on commit 7a8dd89

Please sign in to comment.