@coolon/angular-ui-powerups 0.0.68 → 0.0.69
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/coolon-angular-ui-powerups.umd.js +16 -5
- package/bundles/coolon-angular-ui-powerups.umd.js.map +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js +1 -1
- package/bundles/coolon-angular-ui-powerups.umd.min.js.map +1 -1
- package/esm2015/lib/place/place-definition.js +12 -2
- package/esm2015/lib/place/place-router.js +5 -4
- package/esm2015/lib/place/route/parameter-definition.class.js +2 -2
- package/esm5/lib/place/place-definition.js +12 -2
- package/esm5/lib/place/place-router.js +5 -4
- package/esm5/lib/place/route/parameter-definition.class.js +2 -2
- package/fesm2015/coolon-angular-ui-powerups.js +16 -5
- package/fesm2015/coolon-angular-ui-powerups.js.map +1 -1
- package/fesm5/coolon-angular-ui-powerups.js +16 -5
- package/fesm5/coolon-angular-ui-powerups.js.map +1 -1
- package/package.json +1 -1
|
@@ -2389,7 +2389,7 @@ ParameterDefinition = /** @class */ (function () {
|
|
|
2389
2389
|
* @return {?}
|
|
2390
2390
|
*/
|
|
2391
2391
|
function (visit) {
|
|
2392
|
-
return !visit.hasParameter(this.name)
|
|
2392
|
+
return !visit.hasParameter(this.name);
|
|
2393
2393
|
};
|
|
2394
2394
|
return ParameterDefinition;
|
|
2395
2395
|
}());
|
|
@@ -2856,7 +2856,17 @@ var PlaceDefinition = /** @class */ (function () {
|
|
|
2856
2856
|
function (v) { return def.urlFormat.parse(v); }));
|
|
2857
2857
|
}
|
|
2858
2858
|
else {
|
|
2859
|
-
|
|
2859
|
+
/** @type {?} */
|
|
2860
|
+
var value = def.urlFormat.parse(params.get(def.name));
|
|
2861
|
+
// because our id routes redirect if the id isn't pressent we always have a id
|
|
2862
|
+
// parameter in our params. This will bugger our remember and defaultvalue sanitisation
|
|
2863
|
+
// as it'll see that the id is present (event thought its null). The sanitisation can't
|
|
2864
|
+
// check for null as that's a valid value for the id.
|
|
2865
|
+
/** @type {?} */
|
|
2866
|
+
var isEmptyRouteId = def.isRouteId && def.isEmptyValue(value);
|
|
2867
|
+
if (!isEmptyRouteId) {
|
|
2868
|
+
result[def.name] = value;
|
|
2869
|
+
}
|
|
2860
2870
|
}
|
|
2861
2871
|
}
|
|
2862
2872
|
}));
|
|
@@ -3786,6 +3796,9 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
3786
3796
|
return __awaiter(this, void 0, void 0, function () {
|
|
3787
3797
|
var _this = this;
|
|
3788
3798
|
return __generator(this, function (_a) {
|
|
3799
|
+
// we have to push to history so our remember sanitisers don't pick up the previous value
|
|
3800
|
+
// when it's been cleared by the user.
|
|
3801
|
+
this.placeHistory.add(next);
|
|
3789
3802
|
// FIXME: no route id -> route id duplicates route parameters
|
|
3790
3803
|
if (next.hasRoutingChangedFrom(previous)) {
|
|
3791
3804
|
return [2 /*return*/, this.doNavigation(next, (/**
|
|
@@ -3809,9 +3822,6 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
3809
3822
|
});
|
|
3810
3823
|
}))];
|
|
3811
3824
|
}
|
|
3812
|
-
else {
|
|
3813
|
-
this.placeHistory.add(next);
|
|
3814
|
-
}
|
|
3815
3825
|
return [2 /*return*/];
|
|
3816
3826
|
});
|
|
3817
3827
|
});
|
|
@@ -3843,6 +3853,7 @@ var PlaceRouter = /** @class */ (function (_super) {
|
|
|
3843
3853
|
return [3 /*break*/, 5];
|
|
3844
3854
|
case 3:
|
|
3845
3855
|
def = visit.placeDefinition;
|
|
3856
|
+
// @see https://coolon.atlassian.net/browse/AUP-41
|
|
3846
3857
|
parameterCommands = visit.hasRouteId() ?
|
|
3847
3858
|
[def.getFormattedRouteId(visit), def.getFormattedRouteParameters(visit)] :
|
|
3848
3859
|
[def.getFormattedRouteParameters(visit)];
|