@micromag/core 0.3.617 → 0.3.619
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/es/contexts.js +11 -4
- package/es/index.js +1 -2
- package/package.json +2 -2
package/es/contexts.js
CHANGED
|
@@ -1193,11 +1193,18 @@ var TrackingProvider = function TrackingProvider(_ref) {
|
|
|
1193
1193
|
disabled = _ref.disabled,
|
|
1194
1194
|
children = _ref.children;
|
|
1195
1195
|
var contextTracking = useTracking() || null;
|
|
1196
|
+
var refTracking = useRef(null);
|
|
1196
1197
|
var tracking = useMemo(function () {
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1198
|
+
if (refTracking.current === null) {
|
|
1199
|
+
refTracking.current = new Tracking({
|
|
1200
|
+
variables: _objectSpread(_objectSpread({}, contextTracking !== null ? contextTracking.getVariables() : null), variables),
|
|
1201
|
+
disabled: disabled
|
|
1202
|
+
});
|
|
1203
|
+
} else {
|
|
1204
|
+
refTracking.current.setVariables(_objectSpread(_objectSpread({}, refTracking.current.getVariables()), variables));
|
|
1205
|
+
refTracking.current.setDisabled(disabled);
|
|
1206
|
+
}
|
|
1207
|
+
return refTracking.current;
|
|
1201
1208
|
}, [contextTracking, variables, disabled]);
|
|
1202
1209
|
return /*#__PURE__*/React.createElement(TrackingContainer, {
|
|
1203
1210
|
tracking: tracking
|
package/es/index.js
CHANGED
|
@@ -2189,7 +2189,7 @@ var Tracking = /*#__PURE__*/function (_BaseTracking) {
|
|
|
2189
2189
|
_ref2$type = _ref2.type,
|
|
2190
2190
|
screenType = _ref2$type === undefined ? null : _ref2$type,
|
|
2191
2191
|
_ref2$metadata = _ref2.metadata,
|
|
2192
|
-
metadata = _ref2$metadata === undefined ?
|
|
2192
|
+
metadata = _ref2$metadata === undefined ? null : _ref2$metadata,
|
|
2193
2193
|
_ref2$parameters = _ref2.parameters,
|
|
2194
2194
|
_ref2$parameters2 = _ref2$parameters === undefined ? {} : _ref2$parameters,
|
|
2195
2195
|
parametersMetadata = _ref2$parameters2.metadata;
|
|
@@ -2204,7 +2204,6 @@ var Tracking = /*#__PURE__*/function (_BaseTracking) {
|
|
|
2204
2204
|
screenId: screenId,
|
|
2205
2205
|
screenType: screenType,
|
|
2206
2206
|
screenIndex: screenIndex,
|
|
2207
|
-
screensCount: screensCount,
|
|
2208
2207
|
screenTitle: screenTitle,
|
|
2209
2208
|
screenDescrition: screenDescrition,
|
|
2210
2209
|
screenProgress: screensCount !== null && screenIndex !== null ? (screenIndex + 1) / screensCount : null,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/core",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.619",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -144,5 +144,5 @@
|
|
|
144
144
|
"access": "public",
|
|
145
145
|
"registry": "https://registry.npmjs.org/"
|
|
146
146
|
},
|
|
147
|
-
"gitHead": "
|
|
147
|
+
"gitHead": "21a901b0f800114994f30dfe692c664d378e12f7"
|
|
148
148
|
}
|