Skip to content

Commit

Permalink
chore(all): prepare release 1.5.4
Browse files Browse the repository at this point in the history
  • Loading branch information
EisenbergEffect committed Oct 27, 2017
1 parent 22878ec commit 30096a8
Show file tree
Hide file tree
Showing 20 changed files with 71 additions and 16 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-templating-resources",
"version": "1.5.3",
"version": "1.5.4",
"description": "A standard set of behaviors, converters and other resources for use with the Aurelia templating library.",
"keywords": [
"aurelia",
Expand Down
4 changes: 3 additions & 1 deletion dist/amd/else.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ define(['exports', 'aurelia-templating', 'aurelia-dependency-injection', './if-c
Else.prototype.bind = function bind(bindingContext, overrideContext) {
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
};
Expand Down
4 changes: 3 additions & 1 deletion dist/amd/if-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ define(["exports"], function (exports) {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -49,6 +48,9 @@ define(["exports"], function (exports) {

IfCore.prototype._show = function _show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down
2 changes: 2 additions & 0 deletions dist/amd/if.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,8 @@ define(['exports', 'aurelia-templating', 'aurelia-dependency-injection', './if-c
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
};

Expand Down
13 changes: 11 additions & 2 deletions dist/aurelia-templating-resources.js
Original file line number Diff line number Diff line change
Expand Up @@ -396,7 +396,6 @@ export class IfCore {
// For example a view could be returned to the cache and reused while it's still
// attached to the DOM and animated.
if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -412,6 +411,12 @@ export class IfCore {

_show() {
if (this.showing) {
// Ensures the view is bound.
// It might not be the case when the if was unbound but not detached, then rebound.
// Typical case where this happens is nested ifs
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down Expand Up @@ -1676,7 +1681,9 @@ export class Else extends IfCore {
bind(bindingContext, overrideContext) {
super.bind(bindingContext, overrideContext);
// Render on initial
if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
}
Expand Down Expand Up @@ -1719,6 +1726,8 @@ export class If extends IfCore {
super.bind(bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
}

Expand Down
4 changes: 3 additions & 1 deletion dist/commonjs/else.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ var Else = exports.Else = (_dec = (0, _aureliaTemplating.customAttribute)('else'
Else.prototype.bind = function bind(bindingContext, overrideContext) {
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
};
Expand Down
4 changes: 3 additions & 1 deletion dist/commonjs/if-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ var IfCore = exports.IfCore = function () {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -48,6 +47,9 @@ var IfCore = exports.IfCore = function () {

IfCore.prototype._show = function _show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down
2 changes: 2 additions & 0 deletions dist/commonjs/if.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,8 @@ var If = exports.If = (_dec = (0, _aureliaTemplating.customAttribute)('if'), _de
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
};

Expand Down
4 changes: 3 additions & 1 deletion dist/es2015/else.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ export let Else = (_dec = customAttribute('else'), _dec2 = inject(BoundViewFacto
bind(bindingContext, overrideContext) {
super.bind(bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
}
Expand Down
4 changes: 3 additions & 1 deletion dist/es2015/if-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ export let IfCore = class IfCore {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -39,6 +38,9 @@ export let IfCore = class IfCore {

_show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down
2 changes: 2 additions & 0 deletions dist/es2015/if.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ export let If = (_dec = customAttribute('if'), _dec2 = inject(BoundViewFactory,
super.bind(bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
}

Expand Down
4 changes: 3 additions & 1 deletion dist/native-modules/else.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@ export var Else = (_dec = customAttribute('else'), _dec2 = inject(BoundViewFacto
Else.prototype.bind = function bind(bindingContext, overrideContext) {
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
};
Expand Down
4 changes: 3 additions & 1 deletion dist/native-modules/if-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ export var IfCore = function () {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -42,6 +41,9 @@ export var IfCore = function () {

IfCore.prototype._show = function _show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down
2 changes: 2 additions & 0 deletions dist/native-modules/if.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,8 @@ export var If = (_dec = customAttribute('if'), _dec2 = inject(BoundViewFactory,
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
};

Expand Down
4 changes: 3 additions & 1 deletion dist/system/else.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,9 @@ System.register(['aurelia-templating', 'aurelia-dependency-injection', './if-cor
Else.prototype.bind = function bind(bindingContext, overrideContext) {
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
};
Expand Down
4 changes: 3 additions & 1 deletion dist/system/if-core.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ System.register([], function (_export, _context) {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -52,6 +51,9 @@ System.register([], function (_export, _context) {

IfCore.prototype._show = function _show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down
2 changes: 2 additions & 0 deletions dist/system/if.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ System.register(['aurelia-templating', 'aurelia-dependency-injection', './if-cor
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
};

Expand Down
10 changes: 8 additions & 2 deletions dist/temp/aurelia-templating-resources.js
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,6 @@ var IfCore = exports.IfCore = function () {
this.view.unbind();

if (!this.viewFactory.isCaching) {
this.showing = false;
return;
}

Expand All @@ -436,6 +435,9 @@ var IfCore = exports.IfCore = function () {

IfCore.prototype._show = function _show() {
if (this.showing) {
if (!this.view.isBound) {
this.view.bind(this.bindingContext, this.overrideContext);
}
return;
}

Expand Down Expand Up @@ -1553,7 +1555,9 @@ var Else = exports.Else = (_dec15 = (0, _aureliaTemplating.customAttribute)('els
Else.prototype.bind = function bind(bindingContext, overrideContext) {
_IfCore.prototype.bind.call(this, bindingContext, overrideContext);

if (!this.ifVm.condition) {
if (this.ifVm.condition) {
this._hide();
} else {
this._show();
}
};
Expand Down Expand Up @@ -1591,6 +1595,8 @@ var If = exports.If = (_dec17 = (0, _aureliaTemplating.customAttribute)('if'), _
_IfCore2.prototype.bind.call(this, bindingContext, overrideContext);
if (this.condition) {
this._show();
} else {
this._hide();
}
};

Expand Down
10 changes: 10 additions & 0 deletions doc/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
<a name="1.5.4"></a>
## [1.5.4](https://github.com/aurelia/templating-resources/compare/1.5.3...1.5.4) (2017-10-27)


### Bug Fixes

* **if:** nested ifs don't work properly ([9548e16](https://github.com/aurelia/templating-resources/commit/9548e16)), closes [#328](https://github.com/aurelia/templating-resources/issues/328) [#327](https://github.com/aurelia/templating-resources/issues/327) [#326](https://github.com/aurelia/templating-resources/issues/326) [#322](https://github.com/aurelia/templating-resources/issues/322) [#317](https://github.com/aurelia/templating-resources/issues/317) [#315](https://github.com/aurelia/templating-resources/issues/315)



<a name="1.5.3"></a>
## [1.5.3](https://github.com/aurelia/templating-resources/compare/1.5.2...1.5.3) (2017-10-24)

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "aurelia-templating-resources",
"version": "1.5.3",
"version": "1.5.4",
"description": "A standard set of behaviors, converters and other resources for use with the Aurelia templating library.",
"keywords": [
"aurelia",
Expand Down

0 comments on commit 30096a8

Please sign in to comment.