@player-ui/async-node-plugin 1.1.0--canary.866.38513 → 1.1.0--canary.866.38904

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.
@@ -8062,8 +8062,8 @@ var AsyncNodePlugin = function() {
8062
8062
  ref: Symbol("not-started"),
8063
8063
  status: "not-started"
8064
8064
  };
8065
- var PLAYER_VERSION = true ? "1.1.0--canary.866.38513" : "unknown";
8066
- var COMMIT = true ? "4ebf47a2b8843a4c1f8979f42e0053f2a45e1a9d" : "unknown";
8065
+ var PLAYER_VERSION = true ? "1.1.0--canary.866.38904" : "unknown";
8066
+ var COMMIT = true ? "4bb0e145f34d37972e689d8f184c53e1692d0cc5" : "unknown";
8067
8067
  var _Player = /*#__PURE__*/ function() {
8068
8068
  function _Player2(config) {
8069
8069
  var _this = this;
@@ -8086,7 +8086,7 @@ var AsyncNodePlugin = function() {
8086
8086
  onStart: new SyncHook(),
8087
8087
  onEnd: new SyncHook(),
8088
8088
  resolveFlowContent: new SyncWaterfallHook(),
8089
- transformContent: new SyncWaterfallHook()
8089
+ transformContent: new SyncBailHook()
8090
8090
  };
8091
8091
  if (config === null || config === void 0 ? void 0 : config.logger) {
8092
8092
  this.logger.addHandler(config.logger);
@@ -8100,6 +8100,9 @@ var AsyncNodePlugin = function() {
8100
8100
  (_this_config_plugins = this.config.plugins) === null || _this_config_plugins === void 0 ? void 0 : _this_config_plugins.forEach(function(plugin) {
8101
8101
  plugin.apply(_this);
8102
8102
  });
8103
+ this.hooks.transformContent.tap("player", function(payload, meta) {
8104
+ return meta.format === "player" ? payload : void 0;
8105
+ });
8103
8106
  }
8104
8107
  _create_class(_Player2, [
8105
8108
  {
@@ -8418,7 +8421,10 @@ var AsyncNodePlugin = function() {
8418
8421
  version: options === null || options === void 0 ? void 0 : options.version
8419
8422
  };
8420
8423
  flow = this.hooks.transformContent.call(payload, meta);
8421
- ref = Symbol((_flow_id = flow === null || flow === void 0 ? void 0 : flow.id) !== null && _flow_id !== void 0 ? _flow_id : "payload");
8424
+ if (!flow) {
8425
+ throw new Error('Player.start received content with format "'.concat(meta.format, '" that no plugin transformed into a Flow.'));
8426
+ }
8427
+ ref = Symbol((_flow_id = flow.id) !== null && _flow_id !== void 0 ? _flow_id : "payload");
8422
8428
  maybeUpdateState = function(newState) {
8423
8429
  if (_this.state.ref !== ref) {
8424
8430
  _this.logger.warn("Received update for a flow that's not the current one");