@player-ui/async-node-plugin 0.10.5--canary.609.21254 → 0.10.5--canary.597.21388

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.
@@ -2038,9 +2038,6 @@ var AsyncNodePlugin = function() {
2038
2038
  },
2039
2039
  AsyncNodePluginPlugin: function() {
2040
2040
  return AsyncNodePluginPlugin;
2041
- },
2042
- asyncTransform: function() {
2043
- return asyncTransform;
2044
2041
  }
2045
2042
  });
2046
2043
  var InterceptionManager = /*#__PURE__*/ function() {
@@ -4327,18 +4324,18 @@ var AsyncNodePlugin = function() {
4327
4324
  ]);
4328
4325
  return ValidatorRegistry;
4329
4326
  }();
4330
- var NodeType = /* @__PURE__ */ function(NodeType22) {
4331
- NodeType22["Asset"] = "asset";
4332
- NodeType22["View"] = "view";
4333
- NodeType22["Applicability"] = "applicability";
4334
- NodeType22["Template"] = "template";
4335
- NodeType22["Value"] = "value";
4336
- NodeType22["MultiNode"] = "multi-node";
4337
- NodeType22["Switch"] = "switch";
4338
- NodeType22["Async"] = "async";
4339
- NodeType22["Unknown"] = "unknown";
4340
- NodeType22["Empty"] = "empty";
4341
- return NodeType22;
4327
+ var NodeType = /* @__PURE__ */ function(NodeType2) {
4328
+ NodeType2["Asset"] = "asset";
4329
+ NodeType2["View"] = "view";
4330
+ NodeType2["Applicability"] = "applicability";
4331
+ NodeType2["Template"] = "template";
4332
+ NodeType2["Value"] = "value";
4333
+ NodeType2["MultiNode"] = "multi-node";
4334
+ NodeType2["Switch"] = "switch";
4335
+ NodeType2["Async"] = "async";
4336
+ NodeType2["Unknown"] = "unknown";
4337
+ NodeType2["Empty"] = "empty";
4338
+ return NodeType2;
4342
4339
  }(NodeType || {});
4343
4340
  var EMPTY_NODE = {
4344
4341
  type: "empty"
@@ -4476,15 +4473,6 @@ var AsyncNodePlugin = function() {
4476
4473
  ]);
4477
4474
  return Parser;
4478
4475
  }();
4479
- function unpackAndPush(item, initial) {
4480
- if (Array.isArray(item)) {
4481
- item.forEach(function(i) {
4482
- unpackAndPush(i, initial);
4483
- });
4484
- } else {
4485
- initial.push(item);
4486
- }
4487
- }
4488
4476
  var withContext = function(model) {
4489
4477
  return {
4490
4478
  get: function(binding, options) {
@@ -4705,13 +4693,7 @@ var AsyncNodePlugin = function() {
4705
4693
  var newValues = resolvedAST.values.map(function(mValue) {
4706
4694
  var mTree = _this.computeTree(mValue, rawParentToPassIn, dataChanges, cacheUpdate, resolveOptions, resolvedAST, prevASTMap);
4707
4695
  if (mTree.value !== void 0 && mTree.value !== null) {
4708
- if (mValue.type === "async" && mValue.flatten && mTree.value.asset && Array.isArray(mTree.value.asset.values)) {
4709
- mTree.value.asset.values.forEach(function(v) {
4710
- unpackAndPush(v, childValue);
4711
- });
4712
- } else {
4713
- childValue.push(mTree.value);
4714
- }
4696
+ childValue.push(mTree.value);
4715
4697
  }
4716
4698
  mTree.dependencies.forEach(function(bindingDep) {
4717
4699
  return childDependencies.add(bindingDep);
@@ -4866,112 +4848,6 @@ var AsyncNodePlugin = function() {
4866
4848
  ]);
4867
4849
  return ViewInstance;
4868
4850
  }();
4869
- var Builder = /*#__PURE__*/ function() {
4870
- function _Builder() {
4871
- _class_call_check(this, _Builder);
4872
- }
4873
- _create_class(_Builder, null, [
4874
- {
4875
- key: "asset",
4876
- value: /**
4877
- * Creates an asset node
4878
- *
4879
- * @param value - the value to put in the asset node
4880
- */ function asset(value) {
4881
- return {
4882
- type: "asset",
4883
- value: value
4884
- };
4885
- }
4886
- },
4887
- {
4888
- key: "assetWrapper",
4889
- value: function assetWrapper(value) {
4890
- var valueNode = _Builder.value();
4891
- _Builder.addChild(valueNode, "asset", value);
4892
- return valueNode;
4893
- }
4894
- },
4895
- {
4896
- key: "value",
4897
- value: /**
4898
- * Creates a value node
4899
- *
4900
- * @param v - The object to put in the value node
4901
- */ function value(v) {
4902
- return {
4903
- type: "value",
4904
- value: v
4905
- };
4906
- }
4907
- },
4908
- {
4909
- key: "multiNode",
4910
- value: /**
4911
- * Creates a multiNode and associates the multiNode as the parent
4912
- * of all the value nodes
4913
- *
4914
- * @param values - the value, applicability or async nodes to put in the multinode
4915
- */ function multiNode() {
4916
- for(var _len = arguments.length, values = new Array(_len), _key = 0; _key < _len; _key++){
4917
- values[_key] = arguments[_key];
4918
- }
4919
- var m = {
4920
- type: "multi-node",
4921
- override: true,
4922
- values: values
4923
- };
4924
- values.forEach(function(v) {
4925
- v.parent = m;
4926
- });
4927
- return m;
4928
- }
4929
- },
4930
- {
4931
- key: "asyncNode",
4932
- value: /**
4933
- * Creates an async node
4934
- *
4935
- * @param id - the id of async node. It should be identical for each async node
4936
- */ function asyncNode(id) {
4937
- var flatten2 = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : true;
4938
- return {
4939
- id: id,
4940
- type: "async",
4941
- flatten: flatten2,
4942
- value: {
4943
- type: "value",
4944
- value: {
4945
- id: id
4946
- }
4947
- }
4948
- };
4949
- }
4950
- },
4951
- {
4952
- key: "addChild",
4953
- value: /**
4954
- * Adds a child node to a node
4955
- *
4956
- * @param node - The node to add a child to
4957
- * @param path - The path at which to add the child
4958
- * @param child - The child node
4959
- */ function addChild(node, path, child) {
4960
- child.parent = node;
4961
- var newChild = {
4962
- path: Array.isArray(path) ? path : [
4963
- path
4964
- ],
4965
- value: child
4966
- };
4967
- node.children = node.children || [];
4968
- node.children.push(newChild);
4969
- return node;
4970
- }
4971
- }
4972
- ]);
4973
- return _Builder;
4974
- }();
4975
4851
  var TemplatePlugin = /*#__PURE__*/ function() {
4976
4852
  function TemplatePlugin(options) {
4977
4853
  _class_call_check(this, TemplatePlugin);
@@ -7609,28 +7485,6 @@ var AsyncNodePlugin = function() {
7609
7485
  // ../../../../../../../../../../../execroot/_main/bazel-out/k8-fastbuild/bin/plugins/async-node/core/src/index.ts
7610
7486
  var import_queue_microtask2 = __toESM(require_queue_microtask());
7611
7487
  var import_timm10 = __toESM(require_timm());
7612
- // ../../../../../../../../../../../execroot/_main/bazel-out/k8-fastbuild/bin/plugins/async-node/core/src/transform.ts
7613
- var asyncTransform = function(assetId, wrapperAssetType, asset, flatten2) {
7614
- var id = "async-" + assetId;
7615
- var asyncNode = Builder.asyncNode(id, flatten2);
7616
- var multiNode;
7617
- var assetNode;
7618
- if (asset) {
7619
- assetNode = Builder.assetWrapper(asset);
7620
- multiNode = Builder.multiNode(assetNode, asyncNode);
7621
- } else {
7622
- multiNode = Builder.multiNode(asyncNode);
7623
- }
7624
- var wrapperAsset = Builder.asset({
7625
- id: wrapperAssetType + "-" + id,
7626
- type: wrapperAssetType
7627
- });
7628
- Builder.addChild(wrapperAsset, [
7629
- "values"
7630
- ], multiNode);
7631
- return wrapperAsset;
7632
- };
7633
- // ../../../../../../../../../../../execroot/_main/bazel-out/k8-fastbuild/bin/plugins/async-node/core/src/index.ts
7634
7488
  var AsyncNodePlugin = /*#__PURE__*/ function() {
7635
7489
  function AsyncNodePlugin(options) {
7636
7490
  var _this = this;