@atlaskit/react-ufo 4.1.0 → 4.1.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @atlaskit/ufo-interaction-ignore
2
2
 
3
+ ## 4.1.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#187972](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/187972)
8
+ [`fff3f06f3e5e1`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/fff3f06f3e5e1) -
9
+ FG cleanup - platform_ufo_emit_vc_debug_data
10
+
3
11
  ## 4.1.0
4
12
 
5
13
  ### Minor Changes
@@ -13,7 +13,6 @@ var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/creat
13
13
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
14
14
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
15
15
  var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
16
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
17
16
  var _config = require("../../config");
18
17
  var _interactionMetrics = require("../../interaction-metrics");
19
18
  var _attachAbortListeners = require("./attachAbortListeners");
@@ -275,7 +274,7 @@ var VCObserver = exports.VCObserver = /*#__PURE__*/function () {
275
274
  }
276
275
  if (!_this.isPostInteraction) {
277
276
  // Only create revision debug details if callbacks exist
278
- shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function' && (0, _platformFeatureFlags.fg)('platform_ufo_emit_vc_debug_data');
277
+ shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function';
279
278
  if (shouldCreateDebugDetails) {
280
279
  v1RevisionDebugDetails = (0, _getVCRevisionDebugDetails.getVCRevisionDebugDetails)({
281
280
  revision: 'fy25.01',
@@ -302,7 +301,7 @@ var VCObserver = exports.VCObserver = /*#__PURE__*/function () {
302
301
  // Handle v2
303
302
  (_window$__ufo_devtool2 = (_window2 = window).__ufo_devtool_onVCRevisionReady__) === null || _window$__ufo_devtool2 === void 0 || _window$__ufo_devtool2.call(_window2, v2RevisionDebugDetails);
304
303
  }
305
- if (typeof window.__on_ufo_vc_debug_data_ready === 'function' && (0, _platformFeatureFlags.fg)('platform_ufo_emit_vc_debug_data')) {
304
+ if (typeof window.__on_ufo_vc_debug_data_ready === 'function') {
306
305
  if (!isTTVCv1Disabled) {
307
306
  (_window$__on_ufo_vc_d = (_window3 = window).__on_ufo_vc_debug_data_ready) === null || _window$__on_ufo_vc_d === void 0 || _window$__on_ufo_vc_d.call(_window3, v1RevisionDebugDetails);
308
307
  }
@@ -181,7 +181,7 @@ var AbstractVCCalculatorBase = exports.default = /*#__PURE__*/function () {
181
181
  viewportPercentage: log.viewportPercentage
182
182
  });
183
183
  }) : []; // Only calculate enhanced debug details if devtool callbacks exist
184
- shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function' && (0, _platformFeatureFlags.fg)('platform_ufo_emit_vc_debug_data'));
184
+ shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function');
185
185
  if (shouldCalculateDebugDetails && allEntries && vcLogs) {
186
186
  // Pre-sort vcLogs by time for efficient lookups
187
187
  sortedVcLogs = (0, _toConsumableArray2.default)(vcLogs).sort(function (a, b) {
@@ -292,7 +292,7 @@ var AbstractVCCalculatorBase = exports.default = /*#__PURE__*/function () {
292
292
  console.error('Error in onVCRevisionReady', e);
293
293
  }
294
294
  }
295
- if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function' && (0, _platformFeatureFlags.fg)('platform_ufo_emit_vc_debug_data')) {
295
+ if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function') {
296
296
  try {
297
297
  (_window6 = window) === null || _window6 === void 0 || (_window6$__on_ufo_vc_ = _window6.__on_ufo_vc_debug_data_ready) === null || _window6$__on_ufo_vc_ === void 0 || _window6$__on_ufo_vc_.call(_window6, v3RevisionDebugDetails);
298
298
  } catch (e) {
@@ -1,5 +1,4 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
- import { fg } from '@atlaskit/platform-feature-flags';
3
2
  import { isVCRevisionEnabled } from '../../config';
4
3
  import { getActiveInteraction } from '../../interaction-metrics';
5
4
  import { attachAbortListeners } from './attachAbortListeners';
@@ -285,7 +284,7 @@ export class VCObserver {
285
284
  }
286
285
  if (!this.isPostInteraction) {
287
286
  // Only create revision debug details if callbacks exist
288
- const shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function' && fg('platform_ufo_emit_vc_debug_data');
287
+ const shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function';
289
288
  if (shouldCreateDebugDetails) {
290
289
  const v1RevisionDebugDetails = getVCRevisionDebugDetails({
291
290
  revision: 'fy25.01',
@@ -316,7 +315,7 @@ export class VCObserver {
316
315
  // Handle v2
317
316
  (_window$__ufo_devtool2 = (_window2 = window).__ufo_devtool_onVCRevisionReady__) === null || _window$__ufo_devtool2 === void 0 ? void 0 : _window$__ufo_devtool2.call(_window2, v2RevisionDebugDetails);
318
317
  }
319
- if (typeof window.__on_ufo_vc_debug_data_ready === 'function' && fg('platform_ufo_emit_vc_debug_data')) {
318
+ if (typeof window.__on_ufo_vc_debug_data_ready === 'function') {
320
319
  var _window$__on_ufo_vc_d2, _window4;
321
320
  if (!isTTVCv1Disabled) {
322
321
  var _window$__on_ufo_vc_d, _window3;
@@ -109,7 +109,7 @@ export default class AbstractVCCalculatorBase {
109
109
  })) : [];
110
110
 
111
111
  // Only calculate enhanced debug details if devtool callbacks exist
112
- const shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function' && fg('platform_ufo_emit_vc_debug_data'));
112
+ const shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function');
113
113
  if (shouldCalculateDebugDetails && allEntries && vcLogs) {
114
114
  // Pre-sort vcLogs by time for efficient lookups
115
115
  const sortedVcLogs = [...vcLogs].sort((a, b) => a.time - b.time);
@@ -199,7 +199,7 @@ export default class AbstractVCCalculatorBase {
199
199
  console.error('Error in onVCRevisionReady', e);
200
200
  }
201
201
  }
202
- if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function' && fg('platform_ufo_emit_vc_debug_data')) {
202
+ if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function') {
203
203
  try {
204
204
  var _window6, _window6$__on_ufo_vc_;
205
205
  (_window6 = window) === null || _window6 === void 0 ? void 0 : (_window6$__on_ufo_vc_ = _window6.__on_ufo_vc_debug_data_ready) === null || _window6$__on_ufo_vc_ === void 0 ? void 0 : _window6$__on_ufo_vc_.call(_window6, v3RevisionDebugDetails);
@@ -9,7 +9,6 @@ var _excluded = ["__debug__element"];
9
9
  import _regeneratorRuntime from "@babel/runtime/regenerator";
10
10
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
11
11
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
12
- import { fg } from '@atlaskit/platform-feature-flags';
13
12
  import { isVCRevisionEnabled } from '../../config';
14
13
  import { getActiveInteraction } from '../../interaction-metrics';
15
14
  import { attachAbortListeners } from './attachAbortListeners';
@@ -268,7 +267,7 @@ export var VCObserver = /*#__PURE__*/function () {
268
267
  }
269
268
  if (!_this.isPostInteraction) {
270
269
  // Only create revision debug details if callbacks exist
271
- shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function' && fg('platform_ufo_emit_vc_debug_data');
270
+ shouldCreateDebugDetails = typeof window.__ufo_devtool_onVCRevisionReady__ === 'function' || typeof window.__on_ufo_vc_debug_data_ready === 'function';
272
271
  if (shouldCreateDebugDetails) {
273
272
  v1RevisionDebugDetails = getVCRevisionDebugDetails({
274
273
  revision: 'fy25.01',
@@ -295,7 +294,7 @@ export var VCObserver = /*#__PURE__*/function () {
295
294
  // Handle v2
296
295
  (_window$__ufo_devtool2 = (_window2 = window).__ufo_devtool_onVCRevisionReady__) === null || _window$__ufo_devtool2 === void 0 || _window$__ufo_devtool2.call(_window2, v2RevisionDebugDetails);
297
296
  }
298
- if (typeof window.__on_ufo_vc_debug_data_ready === 'function' && fg('platform_ufo_emit_vc_debug_data')) {
297
+ if (typeof window.__on_ufo_vc_debug_data_ready === 'function') {
299
298
  if (!isTTVCv1Disabled) {
300
299
  (_window$__on_ufo_vc_d = (_window3 = window).__on_ufo_vc_debug_data_ready) === null || _window$__on_ufo_vc_d === void 0 || _window$__on_ufo_vc_d.call(_window3, v1RevisionDebugDetails);
301
300
  }
@@ -175,7 +175,7 @@ var AbstractVCCalculatorBase = /*#__PURE__*/function () {
175
175
  viewportPercentage: log.viewportPercentage
176
176
  });
177
177
  }) : []; // Only calculate enhanced debug details if devtool callbacks exist
178
- shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function' && fg('platform_ufo_emit_vc_debug_data'));
178
+ shouldCalculateDebugDetails = !isPostInteraction && (typeof ((_window = window) === null || _window === void 0 ? void 0 : _window.__ufo_devtool_onVCRevisionReady__) === 'function' || typeof ((_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.__on_ufo_vc_debug_data_ready) === 'function');
179
179
  if (shouldCalculateDebugDetails && allEntries && vcLogs) {
180
180
  // Pre-sort vcLogs by time for efficient lookups
181
181
  sortedVcLogs = _toConsumableArray(vcLogs).sort(function (a, b) {
@@ -286,7 +286,7 @@ var AbstractVCCalculatorBase = /*#__PURE__*/function () {
286
286
  console.error('Error in onVCRevisionReady', e);
287
287
  }
288
288
  }
289
- if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function' && fg('platform_ufo_emit_vc_debug_data')) {
289
+ if (v3RevisionDebugDetails && typeof ((_window5 = window) === null || _window5 === void 0 ? void 0 : _window5.__on_ufo_vc_debug_data_ready) === 'function') {
290
290
  try {
291
291
  (_window6 = window) === null || _window6 === void 0 || (_window6$__on_ufo_vc_ = _window6.__on_ufo_vc_debug_data_ready) === null || _window6$__on_ufo_vc_ === void 0 || _window6$__on_ufo_vc_.call(_window6, v3RevisionDebugDetails);
292
292
  } catch (e) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/react-ufo",
3
- "version": "4.1.0",
3
+ "version": "4.1.1",
4
4
  "description": "Parts of React UFO that are publicly available",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -135,9 +135,6 @@
135
135
  "platform_ufo_enable_media_for_ttvc_v3": {
136
136
  "type": "boolean"
137
137
  },
138
- "platform_ufo_emit_vc_debug_data": {
139
- "type": "boolean"
140
- },
141
138
  "ufo_return_relative_request_start": {
142
139
  "type": "boolean"
143
140
  },