@player-ui/reference-assets-plugin 1.1.0--canary.866.38904 → 1.1.0-next.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.
@@ -8381,8 +8381,8 @@ var ReferenceAssetsPlugin = function() {
8381
8381
  ref: Symbol("not-started"),
8382
8382
  status: "not-started"
8383
8383
  };
8384
- var PLAYER_VERSION = true ? "1.1.0--canary.866.38904" : "unknown";
8385
- var COMMIT = true ? "4bb0e145f34d37972e689d8f184c53e1692d0cc5" : "unknown";
8384
+ var PLAYER_VERSION = true ? "1.1.0-next.1" : "unknown";
8385
+ var COMMIT = true ? "8d1e44b77769e923785e6218de2d9f99342b9b1a" : "unknown";
8386
8386
  var _Player = /*#__PURE__*/ function() {
8387
8387
  function _Player2(config) {
8388
8388
  var _this = this;
@@ -8404,8 +8404,7 @@ var ReferenceAssetsPlugin = function() {
8404
8404
  state: new SyncHook(),
8405
8405
  onStart: new SyncHook(),
8406
8406
  onEnd: new SyncHook(),
8407
- resolveFlowContent: new SyncWaterfallHook(),
8408
- transformContent: new SyncBailHook()
8407
+ resolveFlowContent: new SyncWaterfallHook()
8409
8408
  };
8410
8409
  if (config === null || config === void 0 ? void 0 : config.logger) {
8411
8410
  this.logger.addHandler(config.logger);
@@ -8419,9 +8418,6 @@ var ReferenceAssetsPlugin = function() {
8419
8418
  (_this_config_plugins = this.config.plugins) === null || _this_config_plugins === void 0 ? void 0 : _this_config_plugins.forEach(function(plugin) {
8420
8419
  plugin.apply(_this);
8421
8420
  });
8422
- this.hooks.transformContent.tap("player", function(payload, meta) {
8423
- return meta.format === "player" ? payload : void 0;
8424
- });
8425
8421
  }
8426
8422
  _create_class(_Player2, [
8427
8423
  {
@@ -8728,22 +8724,14 @@ var ReferenceAssetsPlugin = function() {
8728
8724
  },
8729
8725
  {
8730
8726
  key: "start",
8731
- value: function start(payload, options) {
8727
+ value: function start(payload) {
8732
8728
  return _async_to_generator(function() {
8733
- var _this, _options_format, meta, flow, _flow_id, ref, maybeUpdateState, _this_setupFlow, state, start, endProps, _tmp, error, errorState;
8729
+ var _this, _payload_id, ref, maybeUpdateState, _this_setupFlow, state, start, endProps, _tmp, error, errorState;
8734
8730
  return _ts_generator(this, function(_state) {
8735
8731
  switch(_state.label){
8736
8732
  case 0:
8737
8733
  _this = this;
8738
- meta = {
8739
- format: (_options_format = options === null || options === void 0 ? void 0 : options.format) !== null && _options_format !== void 0 ? _options_format : "player",
8740
- version: options === null || options === void 0 ? void 0 : options.version
8741
- };
8742
- flow = this.hooks.transformContent.call(payload, meta);
8743
- if (!flow) {
8744
- throw new Error('Player.start received content with format "'.concat(meta.format, '" that no plugin transformed into a Flow.'));
8745
- }
8746
- ref = Symbol((_flow_id = flow.id) !== null && _flow_id !== void 0 ? _flow_id : "payload");
8734
+ ref = Symbol((_payload_id = payload === null || payload === void 0 ? void 0 : payload.id) !== null && _payload_id !== void 0 ? _payload_id : "payload");
8747
8735
  maybeUpdateState = function(newState) {
8748
8736
  if (_this.state.ref !== ref) {
8749
8737
  _this.logger.warn("Received update for a flow that's not the current one");
@@ -8764,7 +8752,7 @@ var ReferenceAssetsPlugin = function() {
8764
8752
  ,
8765
8753
  4
8766
8754
  ]);
8767
- _this_setupFlow = this.setupFlow(flow), state = _this_setupFlow.state, start = _this_setupFlow.start;
8755
+ _this_setupFlow = this.setupFlow(payload), state = _this_setupFlow.state, start = _this_setupFlow.start;
8768
8756
  this.setState(_object_spread({
8769
8757
  ref: ref
8770
8758
  }, state));
@@ -8799,7 +8787,7 @@ var ReferenceAssetsPlugin = function() {
8799
8787
  errorState = {
8800
8788
  status: "error",
8801
8789
  ref: ref,
8802
- flow: flow,
8790
+ flow: payload,
8803
8791
  error: error
8804
8792
  };
8805
8793
  maybeUpdateState(errorState);