Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@zestia/ember-modal-dialog

Package Overview
Dependencies
Maintainers
3
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@zestia/ember-modal-dialog - npm Package Compare versions

Comparing version 1.0.3 to 1.0.4

6

addon/components/modal-dialog/component.js

@@ -29,6 +29,7 @@ import Component from '@ember/component';

constructor() {
super(...arguments);
init() {
super.init(...arguments);
this.rootElement = document.querySelector(':root');
this.documentElement = document.documentElement;
this._load();
}

@@ -67,3 +68,2 @@

this.rootElement.classList.add('has-modal');
this._load();
this._watchForContentChanges();

@@ -70,0 +70,0 @@ this._ready();

# Changelog
## 1.0.4
- Move `@onLoad` action from did insert hook to component initialisation hook
## 1.0.3

@@ -4,0 +8,0 @@

{
"name": "@zestia/ember-modal-dialog",
"version": "1.0.3",
"version": "1.0.4",
"description": "A simple modal dialog component for Ember apps",

@@ -5,0 +5,0 @@ "directories": {

@@ -51,3 +51,3 @@ # @zestia/ember-modal-dialog

The modal dialog component isn't designed to be used on its own, but rather wrapped with a parent component...
The modal dialog component isn't designed to be used on its own, but rather used to compose a new modal dialog component... in this example it's called "my-modal"

@@ -57,5 +57,8 @@ ```javascript

export default class MyModal extends Component {
@tracked person;
@tracked loadingError;
@action
loaded(person) {
set(this, 'person', person);
this.person = person;
}

@@ -65,3 +68,3 @@

failedToLoad(error) {
set(this, 'loadingError', error.message);
this.loadingError = error.message;
}

@@ -77,6 +80,8 @@ }

@onLoaded={{this.loaded}}
@onLoadError={{this.failedToLoad}} as |modal|>
@onLoadError={{this.failedToLoad}} as |modal|
>
<modal.Header>
Welcome
</modal.Header>
<modal.Content>

@@ -91,4 +96,7 @@ {{#if modal.isLoading}}

</modal.Content>
<modal.Footer>
<button {{on "click" modal.close}}>Close</button>
<button {{on "click" modal.close}}>
Close
</button>
</modal.Footer>

@@ -113,4 +121,5 @@ </ModalDialog>

@onClose={{this.hideMyModal}}
@onFetchPerson={{fn this.loadPerson 123}} />
@onFetchPerson={{fn this.loadPerson 123}}
/>
{{/if}}
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc