1.0.1 • Published 3 years ago

angular-glass v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

AngularGlass

This project was generated with Angular CLI version 12.0.3.

Usage guide

Install Package

    npm install angular-glass

Import module from package into your app module

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';

import { AppComponent } from './app.component';

import { GlassModule } from "angular-glass";

@NgModule({
  declarations: [
    AppComponent,
  ],
  imports: [
    BrowserModule,
    GlassModule
  ],
  providers: [],
  bootstrap: [AppComponent]
})
export class AppModule { }

Use directive inside component html

<div class="parent">
  <div class="container" asGlass [outlineWidth]=4>
    <p>This is a Test for glassMorphism module angular-glass</p>
  </div>
</div>

Properties you can bind to after adding the asGlass directive to any html element

PropertyDefault ValuePermitted Values
blur4any integer from 0-20
opacity0.250-1
borderRadius10any positive number
showOutlinetrueboolean
outlineWidth1any positive number
r255any number between 0-255
g255any number between 0-255
b255any number between 0-255

Sample Images

Tinted Abstract background Abstract Shape Login Screen