targetj 1.0.180 → 1.0.181
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/build/BaseModel.js +2 -16
- package/build/TargetExecutor.js +5 -4
- package/package.json +1 -1
package/build/BaseModel.js
CHANGED
|
@@ -318,7 +318,7 @@ var BaseModel = exports.BaseModel = /*#__PURE__*/function () {
|
|
|
318
318
|
}
|
|
319
319
|
var targetType = _typeof(target);
|
|
320
320
|
var cleanKey = _TargetUtil.TargetUtil.getTargetName(key);
|
|
321
|
-
var isInactiveKey = key.startsWith('_');
|
|
321
|
+
var isInactiveKey = key.startsWith('_') || key.endsWith('$') && !target.active;
|
|
322
322
|
var isExternalEvent = _TargetData.TargetData.allEventMap[cleanKey];
|
|
323
323
|
var isInternalEvent = _TargetData.TargetData.internalEventMap[cleanKey];
|
|
324
324
|
if (!_TargetData.TargetData.controlTargetMap[key]) {
|
|
@@ -802,24 +802,10 @@ var BaseModel = exports.BaseModel = /*#__PURE__*/function () {
|
|
|
802
802
|
}, {
|
|
803
803
|
key: "addToActiveTargets",
|
|
804
804
|
value: function addToActiveTargets(key) {
|
|
805
|
-
var _this3 = this;
|
|
806
805
|
if (!this.activeTargetMap[key] && this.canTargetBeActivated(key)) {
|
|
807
806
|
var _this$getParent;
|
|
808
807
|
this.activeTargetMap[key] = true;
|
|
809
|
-
|
|
810
|
-
var priorityIndex = priorityOrder.indexOf(key);
|
|
811
|
-
if (priorityIndex !== -1) {
|
|
812
|
-
this.activeTargetList = this.activeTargetList.filter(function (item) {
|
|
813
|
-
return !priorityOrder.includes(item);
|
|
814
|
-
});
|
|
815
|
-
priorityOrder.forEach(function (priorityKey) {
|
|
816
|
-
if (_this3.activeTargetMap[priorityKey]) {
|
|
817
|
-
_this3.activeTargetList.unshift(priorityKey);
|
|
818
|
-
}
|
|
819
|
-
});
|
|
820
|
-
} else {
|
|
821
|
-
this.activeTargetList.push(key);
|
|
822
|
-
}
|
|
808
|
+
this.activeTargetList.push(key);
|
|
823
809
|
(_this$getParent = this.getParent()) === null || _this$getParent === void 0 || _this$getParent.addToActiveChildren(this);
|
|
824
810
|
}
|
|
825
811
|
}
|
package/build/TargetExecutor.js
CHANGED
|
@@ -41,7 +41,7 @@ var TargetExecutor = exports.TargetExecutor = /*#__PURE__*/function () {
|
|
|
41
41
|
targetValue.originalTargetName = originalTargetName;
|
|
42
42
|
targetValue.originalTModel = originalTModel;
|
|
43
43
|
if (_TargetUtil.TargetUtil.isListTarget(value)) {
|
|
44
|
-
TargetExecutor.assignListTarget(targetValue, value.list, value.list[0], steps, interval, easing);
|
|
44
|
+
TargetExecutor.assignListTarget(tmodel, key, targetValue, value.list, value.list[0], steps, interval, easing);
|
|
45
45
|
} else if (_TargetUtil.TargetUtil.isObjectTarget(key, value)) {
|
|
46
46
|
var completeValue = _TargetData.TargetData.cssFunctionMap[key] ? _objectSpread(_objectSpread({}, _TargetData.TargetData.cssFunctionMap[key]), value) : value;
|
|
47
47
|
Object.keys(completeValue).forEach(function (objectKey) {
|
|
@@ -88,7 +88,7 @@ var TargetExecutor = exports.TargetExecutor = /*#__PURE__*/function () {
|
|
|
88
88
|
}
|
|
89
89
|
}, {
|
|
90
90
|
key: "assignListTarget",
|
|
91
|
-
value: function assignListTarget(targetValue, valueList, initialValue, steps, interval, easing) {
|
|
91
|
+
value: function assignListTarget(tmodel, key, targetValue, valueList, initialValue, steps, interval, easing) {
|
|
92
92
|
targetValue.valueList = valueList;
|
|
93
93
|
targetValue.stepList = Array.isArray(steps) ? steps : _TUtil.TUtil.isDefined(steps) ? [steps] : [1];
|
|
94
94
|
targetValue.intervalList = Array.isArray(interval) ? interval : _TUtil.TUtil.isDefined(interval) ? [interval] : [0];
|
|
@@ -99,8 +99,9 @@ var TargetExecutor = exports.TargetExecutor = /*#__PURE__*/function () {
|
|
|
99
99
|
targetValue.steps = targetValue.stepList[0];
|
|
100
100
|
targetValue.interval = targetValue.intervalList[0];
|
|
101
101
|
targetValue.easing = targetValue.easingList[0];
|
|
102
|
-
targetValue.step =
|
|
102
|
+
targetValue.step = Math.min(1, targetValue.steps);
|
|
103
103
|
targetValue.cycles = 0;
|
|
104
|
+
tmodel.val(key, initialValue);
|
|
104
105
|
}
|
|
105
106
|
}, {
|
|
106
107
|
key: "executeEventHandlerTarget",
|
|
@@ -159,7 +160,7 @@ var TargetExecutor = exports.TargetExecutor = /*#__PURE__*/function () {
|
|
|
159
160
|
(0, _App.getLoader)().fetch(tmodel, newValue);
|
|
160
161
|
TargetExecutor.assignSingleTarget(targetValue, newValue, undefined, 0, newCycles, newInterval);
|
|
161
162
|
} else if (_TargetUtil.TargetUtil.isListTarget(newValue)) {
|
|
162
|
-
TargetExecutor.assignListTarget(targetValue, newValue.list, newValue.list[0], newSteps, newInterval, easing);
|
|
163
|
+
TargetExecutor.assignListTarget(tmodel, key, targetValue, newValue.list, newValue.list[0], newSteps, newInterval, easing);
|
|
163
164
|
} else {
|
|
164
165
|
var _tmodel$targets$key$d, _tmodel$targets$key;
|
|
165
166
|
if (newSteps > 0 && !_TUtil.TUtil.areEqual(tmodel.val(key), newValue, (_tmodel$targets$key$d = (_tmodel$targets$key = tmodel.targets[key]) === null || _tmodel$targets$key === void 0 ? void 0 : _tmodel$targets$key.deepEquality) !== null && _tmodel$targets$key$d !== void 0 ? _tmodel$targets$key$d : false)) {
|
package/package.json
CHANGED