ember-modal-dialog
Advanced tools
Comparing version 0.8.2 to 0.8.3
@@ -16,3 +16,3 @@ import Ember from 'ember'; | ||
tagName: '', | ||
layout: layout, | ||
layout, | ||
modalService: inject.service('modal-dialog'), | ||
@@ -19,0 +19,0 @@ destinationElementId: oneWay('modalService.destinationElementId'), |
@@ -26,3 +26,5 @@ import Ember from 'ember'; | ||
didGetPositioned: observer('isPositioned', on('didInsertElement', function() { | ||
if (this._state !== 'inDOM') { return; } | ||
if (this._state !== 'inDOM') { | ||
return; | ||
} | ||
@@ -36,5 +38,7 @@ if (this.get('isPositioned')) { | ||
getWrappedTargetAttachmentElement: function() { | ||
getWrappedTargetAttachmentElement() { | ||
const target = this.get('target'); | ||
if (!target) { return null; } | ||
if (!target) { | ||
return null; | ||
} | ||
@@ -57,3 +61,3 @@ if (Ember.typeOf(target) === 'string') { | ||
updateTargetAttachment: function() { | ||
updateTargetAttachment() { | ||
let targetAttachment = this.get('targetAttachment'); | ||
@@ -66,3 +70,3 @@ // Convert tether-styled values like 'middle right' to 'right' | ||
); | ||
const targetAttachmentMethod = 'align' + capitalize(targetAttachment); | ||
const targetAttachmentMethod = `align${capitalize(targetAttachment)}`; | ||
const targetAttachmentElement = this.getWrappedTargetAttachmentElement(); | ||
@@ -73,3 +77,3 @@ | ||
alignCenter: function() { | ||
alignCenter() { | ||
const elementWidth = this.$().outerWidth(); | ||
@@ -84,3 +88,3 @@ const elementHeight = this.$().outerHeight(); | ||
alignLeft: function(targetAttachmentElement) { | ||
alignLeft(targetAttachmentElement) { | ||
Ember.assert('Left targetAttachment requires a target', targetAttachmentElement.length > 0); | ||
@@ -96,3 +100,3 @@ | ||
alignRight: function(targetAttachmentElement) { | ||
alignRight(targetAttachmentElement) { | ||
Ember.assert('Right targetAttachment requires a target', targetAttachmentElement.length > 0); | ||
@@ -108,3 +112,3 @@ | ||
alignTop: function(targetAttachmentElement) { | ||
alignTop(targetAttachmentElement) { | ||
Ember.assert('Top targetAttachment requires a target', targetAttachmentElement.length > 0); | ||
@@ -118,7 +122,7 @@ | ||
this.$().css('left', (originOffset.left + targetWidth/2 - elementWidth/2)) | ||
this.$().css('left', (originOffset.left + targetWidth / 2 - elementWidth / 2)) | ||
.css('top', originOffsetTop - elementHeight); | ||
}, | ||
alignBottom: function(targetAttachmentElement) { | ||
alignBottom(targetAttachmentElement) { | ||
Ember.assert('Bottom targetAttachment requires a target', targetAttachmentElement.length > 0); | ||
@@ -132,7 +136,7 @@ | ||
this.$().css('left', (originOffset.left + targetWidth/2 - elementWidth/2)) | ||
this.$().css('left', (originOffset.left + targetWidth / 2 - elementWidth / 2)) | ||
.css('top', originOffsetTop + targetHeight); | ||
}, | ||
alignNone: function() {} | ||
alignNone() {} | ||
}); |
@@ -10,3 +10,3 @@ import Ember from 'ember'; | ||
export default ModalDialog.extend({ | ||
layout: layout, | ||
layout, | ||
@@ -13,0 +13,0 @@ targetAttachmentClass: computed('targetAttachment', function() { |
# Change Log | ||
## [0.8.2](https://github.com/yapplabs/ember-modal-dialog/tree/0.8.2) (2015-10-26) | ||
[Full Changelog](https://github.com/yapplabs/ember-modal-dialog/compare/v0.8.1...0.8.2) | ||
## [0.8.3](https://github.com/yapplabs/ember-modal-dialog/tree/0.8.3) (2015-12-22) | ||
[Full Changelog](https://github.com/yapplabs/ember-modal-dialog/compare/v0.8.2...0.8.3) | ||
**Closed issues:** | ||
- Introduction to ember-modal-dialog at Global Ember Meetup [\#105](https://github.com/yapplabs/ember-modal-dialog/issues/105) | ||
- allow click outside to close with overlay [\#101](https://github.com/yapplabs/ember-modal-dialog/issues/101) | ||
- Simple install doesn't work [\#100](https://github.com/yapplabs/ember-modal-dialog/issues/100) | ||
- alignment properties don't seem to make a difference [\#98](https://github.com/yapplabs/ember-modal-dialog/issues/98) | ||
- Deprecation warning with Ember CLI 1.13.12 [\#96](https://github.com/yapplabs/ember-modal-dialog/issues/96) | ||
- Deprecation warning on Ember CLI master [\#89](https://github.com/yapplabs/ember-modal-dialog/issues/89) | ||
**Merged pull requests:** | ||
- Perform a big JSCS suave cleanup [\#110](https://github.com/yapplabs/ember-modal-dialog/pull/110) ([chrislopresto](https://github.com/chrislopresto)) | ||
- Add tether-dialog `constraints` property [\#109](https://github.com/yapplabs/ember-modal-dialog/pull/109) ([chrislopresto](https://github.com/chrislopresto)) | ||
- update suave so tests pass on master [\#108](https://github.com/yapplabs/ember-modal-dialog/pull/108) ([hmcq6](https://github.com/hmcq6)) | ||
- Fixing a small typo. [\#91](https://github.com/yapplabs/ember-modal-dialog/pull/91) ([kiwiupover](https://github.com/kiwiupover)) | ||
## [v0.8.2](https://github.com/yapplabs/ember-modal-dialog/tree/v0.8.2) (2015-10-26) | ||
[Full Changelog](https://github.com/yapplabs/ember-modal-dialog/compare/v0.8.1...v0.8.2) | ||
**Merged pull requests:** | ||
- Update to Ember CLI 1.13.8 [\#90](https://github.com/yapplabs/ember-modal-dialog/pull/90) ([chrislopresto](https://github.com/chrislopresto)) | ||
@@ -16,4 +35,2 @@ | ||
- How to pass along close action from inner component? [\#84](https://github.com/yapplabs/ember-modal-dialog/issues/84) | ||
- Acceptance testing the tether-dialog when input is in the block? [\#81](https://github.com/yapplabs/ember-modal-dialog/issues/81) | ||
- Alignment 'none' issue in positioned container [\#75](https://github.com/yapplabs/ember-modal-dialog/issues/75) | ||
@@ -28,6 +45,2 @@ **Merged pull requests:** | ||
**Fixed bugs:** | ||
- Opening modal fails in Ember 1.13.7+ [\#71](https://github.com/yapplabs/ember-modal-dialog/issues/71) | ||
**Closed issues:** | ||
@@ -34,0 +47,0 @@ |
{ | ||
"name": "ember-modal-dialog", | ||
"version": "0.8.2", | ||
"version": "0.8.3", | ||
"description": "An ember-cli addon for implementing modal dialogs", | ||
@@ -41,3 +41,3 @@ "directories": { | ||
"ember-legacy-views": "0.2.0", | ||
"ember-suave": "1.2.0", | ||
"ember-suave": "1.2.3", | ||
"ember-tether": "^0.1.3", | ||
@@ -44,0 +44,0 @@ "ember-truth-helpers": "1.2.0", |
@@ -106,4 +106,5 @@ # Ember Modal Dialog [![Build Status](https://travis-ci.org/yapplabs/ember-modal-dialog.svg?branch=master)](https://travis-ci.org/yapplabs/ember-modal-dialog) [![Ember Observer Score](http://emberobserver.com/badges/ember-modal-dialog.svg)](http://emberobserver.com/addons/ember-modal-dialog) | ||
`targetOffset` | Proxies to Hubspot Tether* | ||
`constraints` | Proxies to Hubspot Tether* | ||
* Please see [Hubspot Tether](http://github.hubspot.com/tether/) for usage documentation. | ||
\* Please see [Hubspot Tether](http://github.hubspot.com/tether/) for usage documentation. | ||
@@ -227,3 +228,3 @@ | ||
Ember.$('body').off('keyup.modal-dialog'); | ||
}.on('willDestroyElement'), | ||
}.on('willDestroyElement') | ||
}); | ||
@@ -323,2 +324,4 @@ ``` | ||
`github_changelog_generator --future-release=x.y.z` | ||
## Additional Resources | ||
@@ -325,0 +328,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
106651
340
332