Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
@crystalui/angular-modal
Advanced tools
This module allows for show modal and dialog boxes.
http://crystalui.org/components/modal
Install the npm package.
npm i @crystalui/angular-modal
Import module:
import {ModalModule} from '@crystalui/angular-modal';
@NgModule({
imports: [ModalModule]
})
To open the window, import the Modal
service and call the load()
method. As a parameter, pass your component. It will be the contents of the window.
import {Modal} from '@crystalui/angular-modal';
import {MyComponent} from './my.component';
public constructor(private modal: Modal) {};
showModal() {
this.modal.load({
id: 'my-modal',
component: MyComponent
});
}
id: string = undefined
// The identifier of the window. It will distinguish one window from another.
mode: "desktop" | "mobile" | "dialog" = "desktop"
// The type of the window template.
data: any
// Any data that needs to be pass to the window. In the window component, you can get them using `@Input() modalData: any`.
width: string = "800px"
// Width of the window.
height: string = "auto"
// Height of the window. By default, the height of the window is determined by the height of its content.
maxWidth: string = "calc(100% - 32px)"
// Maximum width of the window.
maxHeight: string = "calc(100% - 32px)"
// Maximum height of the window.
overlayBackdrop: boolean = true
// Whether the window has a backdrop.
backdropClass: string | { [key: string]: any; }
// Custom classes for the backdrop. Supports the same syntax as ngClass.
modalClass: string | { [key: string]: any; }
// Custom classes for the modal window. Supports the same syntax as ngClass.
name | description |
---|---|
load({ id: "my-modal", component: MyComponent }) | Shows the modal. |
close({ id: "my-modal" }) | Hides the modal. |
Window state changes are available by subscription stateEvents.subscribe()
.
name | description |
---|---|
show | The event is called before the modal appears. |
shown | The event is called after the animation of the appearance of the modal. |
hide | The event is called before the modal is hidden. |
hidden | The event is called after the animation of the modal is hidden. |
FAQs
This module allows for show modal and dialog boxes.
The npm package @crystalui/angular-modal receives a total of 2 weekly downloads. As such, @crystalui/angular-modal popularity was classified as not popular.
We found that @crystalui/angular-modal demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.