Commit e79c0327 by Natthaphat Pankiang

หน้า signup

parent 89580e27
<div class="auth">
<div class="grid grid-cols-12 gap-6 w-full h-full">
<div class="lg:col-span-6 col-span-12 hidden lg:block relative">
<div class="cover relative w-full h-full z-[1] p-10">
<a routerLink="/dashboard/sales" class="header-logo">
<img style="width: 93px; height: 36px;" src="./assets/img/register_images/logo-login-light.png" alt="logo"
class="ltr:ml-auto rtl:mr-auto block" />
</a>
<div class="authentication-page justify-center w-full max-w-7xl mx-auto p-0">
<img src="./assets/img/register_images/Sign-up-pana2.png" alt="logo" class="mx-auto h-[500px]" />
</div>
</div>
</div>
<!-- ========== MAIN CONTENT ========== -->
<main id="content" class="w-full max-w-md mx-auto p-6">
<div class="lg:col-span-6 col-span-12">
<div class="authentication-page w-full">
<!-- ========== MAIN CONTENT ========== -->
<main id="content" class="w-full max-w-md mx-auto p-6 mt-7">
<a routerLink="/dashboard/sales" class="header-logo">
<img
src="./assets/img/brand-logos/desktop-logo.png"
alt="logo"
class="mx-auto block dark:hidden"
/>
<img
src="./assets/img/brand-logos/desktop-dark.png"
alt="logo"
class="mx-auto hidden dark:block"
/>
<img src="./assets/img/brand-logos/logo.png" alt="logo" class="mx-auto block dark:hidden mt-1" />
<img src="./assets/img/brand-logos/logo.png" alt="logo" class="mx-auto hidden dark:block mt-1" />
</a>
<div class="mt-7 bg-white rounded-sm shadow-sm dark:bg-bgdark">
<div class="mt-2">
<div class="p-4 sm:p-7">
<div class="text-center">
<h1 class="block text-2xl font-bold text-gray-800 dark:text-white">
Sign up
</h1>
<p class="mt-3 text-sm text-gray-600 dark:text-white/70">
Already have an account?
<a
class="text-primary decoration-2 hover:underline font-medium"
routerLink="/signin/basic"
>
Sign in here
</a>
</p>
</div>
<div class="mt-5">
<button
type="button"
class="w-full py-2 px-3 inline-flex justify-center items-center gap-2 rounded-sm border font-medium bg-white text-gray-700 shadow-sm align-middle hover:bg-gray-50 focus:outline-none focus:ring-0 focus:ring-offset-0 focus:ring-offset-white focus:ring-primary transition-all text-sm dark:bg-bgdark dark:hover:bg-black/20 dark:border-white/10 dark:text-white/70 dark:hover:text-white dark:focus:ring-offset-white/10"
>
<img
src="./assets/img/authentication/social/1.png"
class="w-4 h-4"
alt="google-img"
/>Sign in with Google
</button>
<div
class="py-3 flex items-center text-xs text-gray-400 uppercase before:flex-[1_1_0%] before:border-t before:border-gray-200 ltr:before:mr-6 rtl:before:ml-6 after:flex-[1_1_0%] after:border-t after:border-gray-200 ltr:after:ml-6 rtl:after:mr-6 dark:text-white/70 dark:before:border-white/10 dark:after:border-white/10"
>
Or
</div>
<!-- Form -->
<form>
<div class="grid gap-y-4">
<!-- Form Group -->
<div>
<label class="block text-sm mb-2 dark:text-white"
>Full Name</label
>
<label class="block text-sm mb-2 dark:text-white">Full Name</label>
<div class="relative">
<input
type="text"
name="text"
<input type="text" name="text"
class="py-2 px-3 block w-full border-gray-200 rounded-sm text-sm focus:border-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:text-white/70"
required
/>
required />
</div>
</div>
<!-- End Form Group -->
<!-- Form Group -->
<div>
<label class="block text-sm mb-2 dark:text-white"
>Email address</label
>
<label class="block text-sm mb-2 dark:text-white">Email address</label>
<div class="relative">
<input
type="email"
name="email"
<input type="email" name="email"
class="py-2 px-3 block w-full border-gray-200 rounded-sm text-sm focus:border-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:text-white/70"
required
/>
required />
</div>
</div>
<!-- End Form Group -->
<!-- Form Group -->
<div>
<label for="password" class="block text-sm mb-2 dark:text-white"
>Password</label
>
<label for="password" class="block text-sm mb-2 dark:text-white">Password</label>
<div class="relative">
<input
type="password"
id="password"
name="password"
<input type="password" id="password" name="password"
class="py-2 px-3 block w-full border-gray-200 rounded-sm text-sm focus:border-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:text-white/70"
required
/>
required />
</div>
</div>
<!-- End Form Group -->
<!-- Form Group -->
<div>
<label
for="confirm-password"
class="block text-sm mb-2 dark:text-white"
>Confirm Password</label
>
<label for="confirm-password" class="block text-sm mb-2 dark:text-white">Confirm Password</label>
<div class="relative">
<input
type="password"
id="confirm-password"
name="confirm-password"
<input type="password" id="confirm-password" name="confirm-password"
class="py-2 px-3 block w-full border-gray-200 rounded-sm text-sm focus:border-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:text-white/70"
required
/>
required />
</div>
</div>
<!-- End Form Group -->
......@@ -122,35 +79,49 @@
<!-- Checkbox -->
<div class="flex items-center">
<div class="flex">
<input
id="remember-me"
name="remember-me"
type="checkbox"
class="shrink-0 mt-0.5 border-gray-200 rounded text-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:checked:bg-primary dark:checked:border-primary dark:focus:ring-offset-white/10"
/>
<input id="remember-me" name="remember-me" type="checkbox"
class="shrink-0 mt-0.5 border-gray-200 rounded text-primary focus:ring-primary dark:bg-bgdark dark:border-white/10 dark:checked:bg-primary dark:checked:border-primary dark:focus:ring-offset-white/10" />
</div>
<div class="ltr:ml-3 rtl:mr-3">
<label for="remember-me" class="text-sm dark:text-white"
>I accept the
<a
class="text-primary decoration-2 hover:underline font-medium"
routerLink="/page/terms-conditions"
>Terms and Conditions</a
></label>
<label for="remember-me" class="text-sm dark:text-white">I accept the
<a class="text-primary decoration-2 hover:underline font-medium"
routerLink="/page/terms-conditions">Terms and Conditions</a></label>
</div>
</div>
<!-- <div
class="py-3 flex items-center text-xs text-gray-400 uppercase before:flex-[1_1_0%] before:border-t before:border-gray-200 ltr:before:mr-6 rtl:before:ml-6 after:flex-[1_1_0%] after:border-t after:border-gray-200 ltr:after:ml-6 rtl:after:mr-6 dark:text-white/70 dark:before:border-white/10 dark:after:border-white/10">
Or
</div>
<button type="button"
class="w-full py-2 px-3 inline-flex justify-center items-center gap-2 rounded-sm border font-medium bg-white text-gray-700 shadow-sm align-middle hover:bg-gray-50 focus:outline-none focus:ring-0 focus:ring-offset-0 focus:ring-offset-white focus:ring-primary transition-all text-sm dark:bg-bgdark dark:hover:bg-black/20 dark:border-white/10 dark:text-white/70 dark:hover:text-white dark:focus:ring-offset-white/10">
<img src="./assets/img/register_images/google-icon.png" class="w-4 h-4" alt="google-img" />Sign
in with Google
</button> -->
<!-- End Checkbox -->
<button
type="submit"
class="py-2 px-3 inline-flex justify-center items-center gap-2 rounded-sm border border-transparent font-semibold bg-primary text-white hover:bg-primary focus:outline-none focus:ring-0 focus:ring-primary focus:ring-offset-0 transition-all text-sm dark:focus:ring-offset-white/10"
>
<button type="submit"
class="py-2 px-3 inline-flex justify-center items-center gap-2 rounded-sm border border-transparent font-semibold bg-primary text-white hover:bg-primary focus:outline-none focus:ring-0 focus:ring-primary focus:ring-offset-0 transition-all text-sm dark:focus:ring-offset-white/10">
Sign up
</button>
<div class="text-center">
<p class="mt-1 text-sm text-gray-600 dark:text-white/70">
Already have an account?
<a class="text-primary decoration-2 hover:underline font-medium" routerLink="/auth/login">
Sign in here
</a>
</p>
</div>
</div>
</form>
<!-- End Form -->
</div>
</div>
</div>
</main>
<!-- ========== END MAIN CONTENT ========== -->
</main>
<!-- ========== END MAIN CONTENT ========== -->
</div>
</div>
</div>
</div>
@media (min-width: 480px){
.authentication-page{
padding-top: 1rem;
padding-bottom: 1rem;
}
}
.cover::before{
position: absolute;
left: 0px;
right: 0px;
top: 0px;
z-index: -1;
height: 100%;
width: 100%;
content: var(--tw-content);
background-image: url('/assets/img/register_images/bg_signup.jpg');
background-size: cover;
background-position: center;
}
\ No newline at end of file
import { Component } from '@angular/core';
import { DOCUMENT } from '@angular/common';
import { Component, ElementRef, Inject, Renderer2 } from '@angular/core';
@Component({
selector: 'app-register-page',
......@@ -6,5 +7,38 @@ import { Component } from '@angular/core';
styleUrls: ['./register-page.component.scss']
})
export class RegisterPageComponent {
constructor(@Inject(DOCUMENT) private document: Document,private elementRef: ElementRef,
private renderer: Renderer2) {}
ngOnInit(): void {
this.renderer.addClass(this.document.body, 'h-full');
this.renderer.addClass(this.document.body, '!py-0');
this.renderer.addClass(this.document.body, 'bg-white');
this.renderer.addClass(this.document.body, 'dark:bg-bgdark');
const authe : any = document.querySelector('.auth');
authe.setAttribute('class','h-full');
const html: any = this.elementRef.nativeElement.ownerDocument.documentElement;
html.classList.add('h-full', 'light');
html.removeAttribute('data-header-styles', 'light');
if (localStorage.getItem('synto-header-mode') == 'dark') {
const html: any = this.elementRef.nativeElement.ownerDocument.documentElement;
html.classList.add('h-full', 'dark');
}
}
ngOnDestroy(): void {
this.renderer.removeClass(this.document.body, 'h-full');
this.renderer.removeClass(this.document.body, '!py-0');
this.renderer.removeClass(this.document.body, 'bg-white');
this.renderer.removeClass(this.document.body, 'dark:bg-bgdark');
if (localStorage.getItem('synto-header-mode') == 'dark') {
const html: any = this.elementRef.nativeElement.ownerDocument.documentElement;
html.classList.remove('h-full', 'dark');
}
const authe: any = document.querySelector('.h-full');
authe.removeAttribute('class', 'h-full');
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment