@ada-support/embed2 1.1.38 → 1.1.39

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.
@@ -8,8 +8,8 @@ interface OwnProps {
8
8
  adaSettings: StartOptions;
9
9
  entryContainer: HTMLElement;
10
10
  unmountCallback: () => void;
11
- initializationResolve: () => void;
12
- initializationReject: (error: Error) => void;
11
+ initializationResolve?: () => void;
12
+ initializationReject?: (error: Error) => void;
13
13
  }
14
14
  declare const _default: (ownProps: OwnProps) => h.JSX.Element;
15
15
  export default _default;
@@ -1,6 +1,3 @@
1
- export interface AgentArrivePayload {
2
- agentName: string;
3
- }
4
1
  export declare const browserHasNotificationSupport: boolean;
5
2
  export declare function checkIfUserHasGivenPermission(): boolean;
6
3
  export declare function requestNotificationPermission(): Promise<NotificationPermission | undefined> | null;
@@ -11,4 +8,4 @@ export declare function createNotification(title: string, isChatOpen: boolean, o
11
8
  /**
12
9
  * Used to listen for changes in Notification permission state
13
10
  */
14
- export declare function notificationPermListener(notificationPermChangeHandler: (notificationStatus: NotificationPermission) => void): Promise<void>;
11
+ export declare function notificationPermListener(notificationPermChangeHandler: (notificationStatus: NotificationPermission) => void): void;
@@ -1 +1 @@
1
- export default function checkRollout(rollout: number, handle: string): boolean;
1
+ export declare function checkRollout(rollout: number, handle: string): boolean;
@@ -8798,7 +8798,7 @@ var client = new error_tracker_BrowserClient({
8798
8798
  return event;
8799
8799
  },
8800
8800
  environment: "production",
8801
- release: "1.1.38-864fd65",
8801
+ release: "1.1.39-0590af1",
8802
8802
  sampleRate: 0.25,
8803
8803
  autoSessionTracking: false,
8804
8804
  // Integrations don't seem to work with Sentry: https://github.com/getsentry/sentry-javascript/issues/2541
@@ -9500,7 +9500,7 @@ function getEmbedURL(_ref) {
9500
9500
  polyfillVersionString = "legacy";
9501
9501
  }
9502
9502
 
9503
- return concat_default()(_context5 = concat_default()(_context6 = concat_default()(_context7 = "".concat(host, "/embed/")).call(_context7, polyfillVersionString, "/")).call(_context6, frameName, "/")).call(_context5, "864fd65", "/index.html");
9503
+ return concat_default()(_context5 = concat_default()(_context6 = concat_default()(_context7 = "".concat(host, "/embed/")).call(_context7, polyfillVersionString, "/")).call(_context6, frameName, "/")).call(_context5, "0590af1", "/index.html");
9504
9504
  }
9505
9505
  /**
9506
9506
  * Generate the Chat / API URL
@@ -11745,7 +11745,7 @@ var ChatFrame = /*#__PURE__*/function (_Component) {
11745
11745
  cluster: cluster,
11746
11746
  domain: domain,
11747
11747
  qp: {
11748
- embedVersion: slice_default()("864fd65").call("864fd65", 0, 7),
11748
+ embedVersion: slice_default()("0590af1").call("0590af1", 0, 7),
11749
11749
  greeting: greeting,
11750
11750
  language: language,
11751
11751
  skipGreeting: skipGreeting,
@@ -12827,6 +12827,54 @@ var Container = /*#__PURE__*/function (_Component) {
12827
12827
  bindLocationChangeOverrides();
12828
12828
  window.addEventListener("locationchange", this.locationChangeHandlerBound);
12829
12829
  }
12830
+ /** To be called when `props.appConnectionState` value changes */
12831
+
12832
+ }, {
12833
+ key: "onAppConnectionStateChange",
12834
+ value: function onAppConnectionStateChange() {
12835
+ var _this$props2 = this.props,
12836
+ appConnectionState = _this$props2.appConnectionState,
12837
+ initializationReject = _this$props2.initializationReject,
12838
+ initializationResolve = _this$props2.initializationResolve,
12839
+ adaSettings = _this$props2.adaSettings;
12840
+
12841
+ switch (appConnectionState) {
12842
+ case ConnectionState.Done:
12843
+ {
12844
+ if (!initializationResolve) {
12845
+ throw new errors/* AdaEmbedError */.S("`initializationResolve` is undefined");
12846
+ }
12847
+
12848
+ initializationResolve();
12849
+ this.bindEmbedActionEventHandlerOnce();
12850
+
12851
+ if (adaSettings.adaReadyCallback) {
12852
+ adaSettings.adaReadyCallback({
12853
+ isRolledOut: true
12854
+ });
12855
+ }
12856
+
12857
+ break;
12858
+ }
12859
+
12860
+ case ConnectionState.Failure:
12861
+ {
12862
+ if (!initializationReject) {
12863
+ throw new errors/* AdaEmbedError */.S("`initializationReject` is undefined");
12864
+ }
12865
+
12866
+ var _error = new errors/* AdaEmbedError */.S("Embed startup failed. This is likely because one or all frame components failed to connect. Please check your internet connection.");
12867
+
12868
+ initializationReject(_error);
12869
+ this.unmount();
12870
+ break;
12871
+ }
12872
+
12873
+ default:
12874
+ {// Do nothing
12875
+ }
12876
+ }
12877
+ }
12830
12878
  }, {
12831
12879
  key: "componentDidUpdate",
12832
12880
  value: function componentDidUpdate(prevProps) {
@@ -12834,20 +12882,17 @@ var Container = /*#__PURE__*/function (_Component) {
12834
12882
  _client$ui_settings$e,
12835
12883
  _this2 = this;
12836
12884
 
12837
- var _this$props2 = this.props,
12838
- isDrawerOpen = _this$props2.isDrawerOpen,
12839
- appConnectionState = _this$props2.appConnectionState,
12840
- initializationReject = _this$props2.initializationReject,
12841
- initializationResolve = _this$props2.initializationResolve,
12842
- chatterToken = _this$props2.chatterToken,
12843
- client = _this$props2.client,
12844
- isChatWebsocketConnected = _this$props2.isChatWebsocketConnected,
12845
- adaSettings = _this$props2.adaSettings,
12846
- chatterInLiveChat = _this$props2.chatterInLiveChat,
12847
- messageService = _this$props2.messageService,
12848
- wasCampaignShownButNowClosed = _this$props2.wasCampaignShownButNowClosed;
12849
- var adaReadyCallback = adaSettings.adaReadyCallback,
12850
- toggleCallback = adaSettings.toggleCallback;
12885
+ var _this$props3 = this.props,
12886
+ isDrawerOpen = _this$props3.isDrawerOpen,
12887
+ appConnectionState = _this$props3.appConnectionState,
12888
+ chatterToken = _this$props3.chatterToken,
12889
+ client = _this$props3.client,
12890
+ isChatWebsocketConnected = _this$props3.isChatWebsocketConnected,
12891
+ adaSettings = _this$props3.adaSettings,
12892
+ chatterInLiveChat = _this$props3.chatterInLiveChat,
12893
+ messageService = _this$props3.messageService,
12894
+ wasCampaignShownButNowClosed = _this$props3.wasCampaignShownButNowClosed;
12895
+ var toggleCallback = adaSettings.toggleCallback;
12851
12896
 
12852
12897
  if ((client === null || client === void 0 ? void 0 : (_client$ui_settings = client.ui_settings) === null || _client$ui_settings === void 0 ? void 0 : (_client$ui_settings$e = _client$ui_settings.embed) === null || _client$ui_settings$e === void 0 ? void 0 : _client$ui_settings$e.style) === "text") {
12853
12898
  this.computeButtonFrameWidth();
@@ -12858,23 +12903,7 @@ var Container = /*#__PURE__*/function (_Component) {
12858
12903
 
12859
12904
 
12860
12905
  if (prevProps.appConnectionState !== appConnectionState) {
12861
- if (appConnectionState === ConnectionState.Done) {
12862
- initializationResolve();
12863
- this.bindEmbedActionEventHandlerOnce();
12864
-
12865
- if (adaReadyCallback) {
12866
- adaReadyCallback({
12867
- isRolledOut: true
12868
- });
12869
- }
12870
- }
12871
-
12872
- if (appConnectionState === ConnectionState.Failure) {
12873
- var _error = new errors/* AdaEmbedError */.S("Embed startup failed. This is likely because one or all frame components failed to connect. Please check your internet connection.");
12874
-
12875
- initializationReject(_error);
12876
- this.unmount();
12877
- }
12906
+ this.onAppConnectionStateChange();
12878
12907
  }
12879
12908
 
12880
12909
  var _this$state = this.state,
@@ -12948,10 +12977,10 @@ var Container = /*#__PURE__*/function (_Component) {
12948
12977
  }, {
12949
12978
  key: "shouldRenderChatFrame",
12950
12979
  get: function get() {
12951
- var _this$props3 = this.props,
12952
- isDrawerOpen = _this$props3.isDrawerOpen,
12953
- adaSettings = _this$props3.adaSettings,
12954
- chatterInLiveChat = _this$props3.chatterInLiveChat;
12980
+ var _this$props4 = this.props,
12981
+ isDrawerOpen = _this$props4.isDrawerOpen,
12982
+ adaSettings = _this$props4.adaSettings,
12983
+ chatterInLiveChat = _this$props4.chatterInLiveChat;
12955
12984
  var parentElement = adaSettings.parentElement,
12956
12985
  preload = adaSettings.preload;
12957
12986
  var _this$state2 = this.state,
@@ -12995,9 +13024,9 @@ var Container = /*#__PURE__*/function (_Component) {
12995
13024
  }, {
12996
13025
  key: "computeButtonFrameWidth",
12997
13026
  value: function computeButtonFrameWidth() {
12998
- var _this$props4 = this.props,
12999
- entryContainer = _this$props4.entryContainer,
13000
- client = _this$props4.client;
13027
+ var _this$props5 = this.props,
13028
+ entryContainer = _this$props5.entryContainer,
13029
+ client = _this$props5.client;
13001
13030
  var buttonPadding = 26;
13002
13031
  var iconWithSpace = 30;
13003
13032
  var margins = 48;
@@ -13016,11 +13045,13 @@ var Container = /*#__PURE__*/function (_Component) {
13016
13045
  }, {
13017
13046
  key: "unmount",
13018
13047
  value: function unmount() {
13019
- var _this$props5 = this.props,
13020
- entryContainer = _this$props5.entryContainer,
13021
- messageService = _this$props5.messageService,
13022
- unmountCallback = _this$props5.unmountCallback;
13023
- entryContainer.parentNode.removeChild(entryContainer);
13048
+ var _entryContainer$paren;
13049
+
13050
+ var _this$props6 = this.props,
13051
+ entryContainer = _this$props6.entryContainer,
13052
+ messageService = _this$props6.messageService,
13053
+ unmountCallback = _this$props6.unmountCallback;
13054
+ (_entryContainer$paren = entryContainer.parentNode) === null || _entryContainer$paren === void 0 ? void 0 : _entryContainer$paren.removeChild(entryContainer);
13024
13055
  messageService.getAllChannels().forEach(function (channel) {
13025
13056
  channel.clearTimeoutsAndListeners();
13026
13057
  });
@@ -13031,9 +13062,9 @@ var Container = /*#__PURE__*/function (_Component) {
13031
13062
  }, {
13032
13063
  key: "trackEvent",
13033
13064
  value: function trackEvent(trackEventParams) {
13034
- var _this$props6 = this.props,
13035
- adaSettings = _this$props6.adaSettings,
13036
- chatterToken = _this$props6.chatterToken;
13065
+ var _this$props7 = this.props,
13066
+ adaSettings = _this$props7.adaSettings,
13067
+ chatterToken = _this$props7.chatterToken;
13037
13068
  trackEventImpl(adaSettings, chatterToken, trackEventParams);
13038
13069
  }
13039
13070
  }, {
@@ -13060,10 +13091,10 @@ var Container = /*#__PURE__*/function (_Component) {
13060
13091
  value: function triggerCampaign(params) {
13061
13092
  var _client$marketing_cam;
13062
13093
 
13063
- var _this$props7 = this.props,
13064
- client = _this$props7.client,
13065
- isDrawerOpen = _this$props7.isDrawerOpen,
13066
- setState = _this$props7.setState;
13094
+ var _this$props8 = this.props,
13095
+ client = _this$props8.client,
13096
+ isDrawerOpen = _this$props8.isDrawerOpen,
13097
+ setState = _this$props8.setState;
13067
13098
  var chatHasBeenRendered = this.state.chatHasBeenRendered;
13068
13099
  var campaignKey = params.campaignKey,
13069
13100
  ignoreStatus = params.ignoreStatus,
@@ -13107,9 +13138,9 @@ var Container = /*#__PURE__*/function (_Component) {
13107
13138
  var _this4 = this;
13108
13139
 
13109
13140
  var useDelay = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
13110
- var _this$props8 = this.props,
13111
- adaSettings = _this$props8.adaSettings,
13112
- client = _this$props8.client;
13141
+ var _this$props9 = this.props,
13142
+ adaSettings = _this$props9.adaSettings,
13143
+ client = _this$props9.client;
13113
13144
  var campaignToTrigger = getCampaignToTrigger(adaSettings, client.marketing_campaigns, params, !client.features.afm_proactive_messaging);
13114
13145
 
13115
13146
  if (campaignToTrigger) {
@@ -13132,13 +13163,13 @@ var Container = /*#__PURE__*/function (_Component) {
13132
13163
  var _handleEmbedAction = (0,asyncToGenerator/* default */.Z)( /*#__PURE__*/regenerator_default().mark(function _callee2(type, payload, id) {
13133
13164
  var _this5 = this;
13134
13165
 
13135
- var _this$props9, client, messageService, adaSettings, parentElement, localChannel, xStorageChannel, chatChannel, toggleChat, _this$props10, isDrawerOpen, drawerHasBeenOpened, chatterToken, contentToReturn, _this$props11, metaFields, setState, metaData, newMetaFields, _this$props12, sensitiveMetaFields, _setState, _ref, greeting, language, _newMetaFields, _sensitiveMetaFields, _ref$resetChatHistory, resetChatHistory, _setState2, chatHasBeenRendered, newState, _setState3, _ref2, body, duration, EXTRA_PROACTIVE_DELAY;
13166
+ var _this$props10, client, messageService, adaSettings, parentElement, localChannel, xStorageChannel, chatChannel, toggleChat, _this$props11, isDrawerOpen, drawerHasBeenOpened, chatterToken, contentToReturn, _this$props12, metaFields, setState, metaData, newMetaFields, _this$props13, sensitiveMetaFields, _setState, _ref, greeting, language, _newMetaFields, _sensitiveMetaFields, _ref$resetChatHistory, resetChatHistory, _setState2, chatHasBeenRendered, newState, _setState3, _ref2, body, duration, EXTRA_PROACTIVE_DELAY;
13136
13167
 
13137
13168
  return regenerator_default().wrap(function _callee2$(_context3) {
13138
13169
  while (1) {
13139
13170
  switch (_context3.prev = _context3.next) {
13140
13171
  case 0:
13141
- _this$props9 = this.props, client = _this$props9.client, messageService = _this$props9.messageService, adaSettings = _this$props9.adaSettings;
13172
+ _this$props10 = this.props, client = _this$props10.client, messageService = _this$props10.messageService, adaSettings = _this$props10.adaSettings;
13142
13173
  parentElement = adaSettings.parentElement;
13143
13174
  localChannel = messageService.getChannel("local");
13144
13175
  xStorageChannel = messageService.getChannel(XSTORAGE_IFRAME);
@@ -13196,7 +13227,7 @@ var Container = /*#__PURE__*/function (_Component) {
13196
13227
  return _context3.abrupt("break", 85);
13197
13228
 
13198
13229
  case 24:
13199
- _this$props10 = this.props, isDrawerOpen = _this$props10.isDrawerOpen, drawerHasBeenOpened = _this$props10.drawerHasBeenOpened, chatterToken = _this$props10.chatterToken;
13230
+ _this$props11 = this.props, isDrawerOpen = _this$props11.isDrawerOpen, drawerHasBeenOpened = _this$props11.drawerHasBeenOpened, chatterToken = _this$props11.chatterToken;
13200
13231
  contentToReturn = {
13201
13232
  isDrawerOpen: isDrawerOpen,
13202
13233
  isChatOpen: isDrawerOpen || Boolean(parentElement),
@@ -13207,7 +13238,7 @@ var Container = /*#__PURE__*/function (_Component) {
13207
13238
  return _context3.abrupt("break", 85);
13208
13239
 
13209
13240
  case 28:
13210
- _this$props11 = this.props, metaFields = _this$props11.metaFields, setState = _this$props11.setState;
13241
+ _this$props12 = this.props, metaFields = _this$props12.metaFields, setState = _this$props12.setState;
13211
13242
  metaData = payload;
13212
13243
  newMetaFields = Container_objectSpread(Container_objectSpread({}, metaFields), metaData);
13213
13244
  _context3.next = 33;
@@ -13220,7 +13251,7 @@ var Container = /*#__PURE__*/function (_Component) {
13220
13251
  return _context3.abrupt("break", 85);
13221
13252
 
13222
13253
  case 35:
13223
- _this$props12 = this.props, sensitiveMetaFields = _this$props12.sensitiveMetaFields, _setState = _this$props12.setState;
13254
+ _this$props13 = this.props, sensitiveMetaFields = _this$props13.sensitiveMetaFields, _setState = _this$props13.setState;
13224
13255
  _context3.next = 38;
13225
13256
  return _setState({
13226
13257
  sensitiveMetaFields: Container_objectSpread(Container_objectSpread({}, sensitiveMetaFields), payload)
@@ -13446,13 +13477,13 @@ var Container = /*#__PURE__*/function (_Component) {
13446
13477
  var _initialize = (0,asyncToGenerator/* default */.Z)( /*#__PURE__*/regenerator_default().mark(function _callee3() {
13447
13478
  var _context4;
13448
13479
 
13449
- var _this$props13, adaSettings, setState, handle, cluster, domain, rolloutOverride, adaReadyCallback, privateMode, language, adaSettingsWithoutFunctions, clientResponse, newClient, baseApiUrl, businessEvents, marketingCampaigns, _context5, _context6, chatIsOn, rollout, chatterInLiveChat;
13480
+ var _this$props14, adaSettings, setState, handle, cluster, domain, rolloutOverride, adaReadyCallback, privateMode, language, adaSettingsWithoutFunctions, clientResponse, newClient, baseApiUrl, businessEvents, marketingCampaigns, _context5, _context6, chatIsOn, rollout, chatterInLiveChat;
13450
13481
 
13451
13482
  return regenerator_default().wrap(function _callee3$(_context8) {
13452
13483
  while (1) {
13453
13484
  switch (_context8.prev = _context8.next) {
13454
13485
  case 0:
13455
- _this$props13 = this.props, adaSettings = _this$props13.adaSettings, setState = _this$props13.setState;
13486
+ _this$props14 = this.props, adaSettings = _this$props14.adaSettings, setState = _this$props14.setState;
13456
13487
  handle = adaSettings.handle, cluster = adaSettings.cluster, domain = adaSettings.domain, rolloutOverride = adaSettings.rolloutOverride, adaReadyCallback = adaSettings.adaReadyCallback, privateMode = adaSettings.privateMode;
13457
13488
  language = adaSettings.language || get_browser_language(); // We do not want to store functions in our store. The rest of the values are useful however.
13458
13489
 
@@ -13653,10 +13684,10 @@ var Container = /*#__PURE__*/function (_Component) {
13653
13684
  }, {
13654
13685
  key: "renderChatFrame",
13655
13686
  value: function renderChatFrame() {
13656
- var _this$props14 = this.props,
13657
- messageService = _this$props14.messageService,
13658
- store = _this$props14.store,
13659
- adaSettings = _this$props14.adaSettings;
13687
+ var _this$props15 = this.props,
13688
+ messageService = _this$props15.messageService,
13689
+ store = _this$props15.store,
13690
+ adaSettings = _this$props15.adaSettings;
13660
13691
  var _this$state3 = this.state,
13661
13692
  campaignToTrigger = _this$state3.campaignToTrigger,
13662
13693
  followUpResponseId = _this$state3.followUpResponseId;
@@ -13679,9 +13710,9 @@ var Container = /*#__PURE__*/function (_Component) {
13679
13710
  value: function renderIntroFrame() {
13680
13711
  var _client$intro;
13681
13712
 
13682
- var _this$props15 = this.props,
13683
- adaSettings = _this$props15.adaSettings,
13684
- client = _this$props15.client;
13713
+ var _this$props16 = this.props,
13714
+ adaSettings = _this$props16.adaSettings,
13715
+ client = _this$props16.client;
13685
13716
  var parentElement = adaSettings.parentElement;
13686
13717
  var hideIntroOverride = this.state.hideIntroOverride;
13687
13718
 
@@ -13695,9 +13726,9 @@ var Container = /*#__PURE__*/function (_Component) {
13695
13726
  }, {
13696
13727
  key: "renderMaskFrame",
13697
13728
  value: function renderMaskFrame() {
13698
- var _this$props16 = this.props,
13699
- adaSettings = _this$props16.adaSettings,
13700
- hideMask = _this$props16.hideMask;
13729
+ var _this$props17 = this.props,
13730
+ adaSettings = _this$props17.adaSettings,
13731
+ hideMask = _this$props17.hideMask;
13701
13732
  var parentElement = adaSettings.parentElement;
13702
13733
 
13703
13734
  if (parentElement || hideMask) {
@@ -13709,12 +13740,12 @@ var Container = /*#__PURE__*/function (_Component) {
13709
13740
  }, {
13710
13741
  key: "renderBackdrop",
13711
13742
  value: function renderBackdrop() {
13712
- var _this$props17 = this.props,
13713
- client = _this$props17.client,
13714
- adaSettings = _this$props17.adaSettings,
13715
- chatDimensions = _this$props17.chatDimensions,
13716
- isDrawerOpen = _this$props17.isDrawerOpen,
13717
- isIntroShown = _this$props17.isIntroShown;
13743
+ var _this$props18 = this.props,
13744
+ client = _this$props18.client,
13745
+ adaSettings = _this$props18.adaSettings,
13746
+ chatDimensions = _this$props18.chatDimensions,
13747
+ isDrawerOpen = _this$props18.isDrawerOpen,
13748
+ isIntroShown = _this$props18.isIntroShown;
13718
13749
  var parentElement = adaSettings.parentElement; // checking for a non-empty parentElement here to
13719
13750
  // hide the backdrop in the SDKs
13720
13751
 
@@ -14392,7 +14423,7 @@ var Embed = /*#__PURE__*/function () {
14392
14423
  * Bind to the window object so it can be used by the entry file.
14393
14424
  */
14394
14425
 
14395
- (0,defineProperty/* default */.Z)(Embed, "embed2Version", "864fd65");
14426
+ (0,defineProperty/* default */.Z)(Embed, "embed2Version", "0590af1");
14396
14427
 
14397
14428
  window.__AdaEmbedConstructor = Embed;
14398
14429
 
@@ -14752,9 +14783,9 @@ function _log() {
14752
14783
  service: "embed",
14753
14784
  env: "production",
14754
14785
  embedVersion: 2,
14755
- version: "1.1.38",
14786
+ version: "1.1.39",
14756
14787
  isNpm: true,
14757
- commitHash: "864fd65"
14788
+ commitHash: "0590af1"
14758
14789
  }))
14759
14790
  });
14760
14791
 
@@ -25695,7 +25726,7 @@ function _loadClientChunk() {
25695
25726
  polyfillVersionString = "legacy";
25696
25727
  }
25697
25728
 
25698
- clientScriptSource = concat_default()(_context17 = concat_default()(_context18 = "".concat(host, "/embed/")).call(_context18, polyfillVersionString, "/client/")).call(_context17, "864fd65", "/index.js");
25729
+ clientScriptSource = concat_default()(_context17 = concat_default()(_context18 = "".concat(host, "/embed/")).call(_context18, polyfillVersionString, "/client/")).call(_context17, "0590af1", "/index.js");
25699
25730
  } // `window.__AdaEmbedConstructor` gets created in the "client" bundle
25700
25731
 
25701
25732
 
@@ -25808,7 +25839,7 @@ function createEmbedObject() {
25808
25839
  throw new Error("`window.__AdaEmbedConstructor` is not defined");
25809
25840
 
25810
25841
  case 7:
25811
- if (!(adaSettings.customDomains && window.__AdaEmbedConstructor.embed2Version !== "864fd65")) {
25842
+ if (!(adaSettings.customDomains && window.__AdaEmbedConstructor.embed2Version !== "0590af1")) {
25812
25843
  _context2.next = 9;
25813
25844
  break;
25814
25845
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ada-support/embed2",
3
- "version": "1.1.38",
3
+ "version": "1.1.39",
4
4
  "description": "",
5
5
  "main": "dist/npm-entry",
6
6
  "typings": "dist/npm-entry/index.d.ts",
@@ -13,7 +13,7 @@
13
13
  "build:modern": "TS_NODE_PROJECT=wp.tsconfig.json NODE_ENV=production BROWSERSLIST_ENV=modern npx webpack --config webpack.prod.ts",
14
14
  "build:npm-types": "tsc --project tsconfig.npm.json --declaration --outDir dist/npm-entry --emitDeclarationOnly --allowJs false --checkJs false",
15
15
  "build:npm": "./npm-build.sh",
16
- "lint": "tsc --noEmit --strict false && ./node_modules/.bin/eslint --report-unused-disable-directives --ext .js,.jsx,.ts,.tsx . --max-warnings 25",
16
+ "lint": "tsc --noEmit --strict false && ./node_modules/.bin/eslint --report-unused-disable-directives --ext .js,.jsx,.ts,.tsx . --max-warnings 24",
17
17
  "lint:fix": "yarn lint --fix",
18
18
  "test": "jest",
19
19
  "check-types": "./node_modules/typescript/bin/tsc --project ./tsconfig.json --noEmit --strict false",
@@ -56,6 +56,7 @@
56
56
  "devDependencies": {
57
57
  "@ada-support/embed-types": "^1.0.4",
58
58
  "@ada-support/eslint-config-ada": "^1.2.1",
59
+ "@testing-library/preact": "^2.0.1",
59
60
  "@types/enzyme": "^3.10.11",
60
61
  "@types/jest": "^27.0.2",
61
62
  "@types/json-stable-stringify": "^1.0.33",
@@ -70,7 +71,7 @@
70
71
  "cypress": "^9.6.1",
71
72
  "depcheck": "^1.4.3",
72
73
  "enzyme": "^3.11.0",
73
- "enzyme-adapter-preact-pure": "^2.2.0",
74
+ "enzyme-adapter-preact-pure": "^4.0.1",
74
75
  "eslint": "^8.8.0",
75
76
  "eslint-plugin-chai-friendly": "^0.7.2",
76
77
  "eslint-plugin-compat": "^4.0.2",
@@ -80,6 +81,7 @@
80
81
  "jest": "^27.5.1",
81
82
  "jest-localstorage-mock": "^2.4.0",
82
83
  "lint-staged": "^11.2.3",
84
+ "mock-xmlhttprequest": "^7.0.4",
83
85
  "npm-run-all": "^4.1.5",
84
86
  "start-server-and-test": "^1.14.0",
85
87
  "testcafe": "^1.18.4",