jsf.js_next_gen 4.0.1-beta.8 → 4.0.2-beta.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.
Files changed (191) hide show
  1. package/dist/window/faces-development.js +51 -6
  2. package/dist/window/faces-development.js.br +0 -0
  3. package/dist/window/faces-development.js.gz +0 -0
  4. package/dist/window/faces-development.js.map +1 -1
  5. package/dist/window/faces.js +1 -1
  6. package/dist/window/faces.js.br +0 -0
  7. package/dist/window/faces.js.gz +0 -0
  8. package/dist/window/faces.js.map +1 -1
  9. package/dist/window/jsf-development.js +51 -6
  10. package/dist/window/jsf-development.js.br +0 -0
  11. package/dist/window/jsf-development.js.gz +0 -0
  12. package/dist/window/jsf-development.js.map +1 -1
  13. package/dist/window/jsf.js +1 -1
  14. package/dist/window/jsf.js.br +0 -0
  15. package/dist/window/jsf.js.gz +0 -0
  16. package/dist/window/jsf.js.map +1 -1
  17. package/package.json +2 -2
  18. package/src/main/typescript/impl/util/ExtDomQuery.ts +8 -5
  19. package/src/main/typescript/impl/xhrCore/XhrRequest.ts +9 -0
  20. package/src/main/typescript/test/xhrCore/RequestParamsTest.spec.ts +2 -1
  21. package/target/impl/util/ExtDomQuery.js +7 -4
  22. package/target/impl/util/ExtDomQuery.js.map +1 -1
  23. package/target/impl/xhrCore/XhrRequest.js +8 -0
  24. package/target/impl/xhrCore/XhrRequest.js.map +1 -1
  25. package/target/test/xhrCore/RequestParamsTest.spec.js +2 -1
  26. package/target/test/xhrCore/RequestParamsTest.spec.js.map +1 -1
  27. package/webpack.config.js +1 -1
  28. package/webpack.config.js.map +1 -1
  29. package/target/AssocArray.js +0 -281
  30. package/target/AssocArray.js.map +0 -1
  31. package/target/Config.js +0 -235
  32. package/target/Config.js.map +0 -1
  33. package/target/CryptoExtensions.js +0 -112
  34. package/target/CryptoExtensions.js.map +0 -1
  35. package/target/DomQuery.js +0 -1963
  36. package/target/DomQuery.js.map +0 -1
  37. package/target/Es2019Array.js +0 -117
  38. package/target/Es2019Array.js.map +0 -1
  39. package/target/Global.js +0 -38
  40. package/target/Global.js.map +0 -1
  41. package/target/IDomQuery.js +0 -3
  42. package/target/IDomQuery.js.map +0 -1
  43. package/target/Lang.js +0 -183
  44. package/target/Lang.js.map +0 -1
  45. package/target/Messaging.js +0 -645
  46. package/target/Messaging.js.map +0 -1
  47. package/target/Monad.js +0 -330
  48. package/target/Monad.js.map +0 -1
  49. package/target/Promise.js +0 -296
  50. package/target/Promise.js.map +0 -1
  51. package/target/PromiseShim.js +0 -30
  52. package/target/PromiseShim.js.map +0 -1
  53. package/target/SourcesCollectors.js +0 -444
  54. package/target/SourcesCollectors.js.map +0 -1
  55. package/target/Stream.js +0 -562
  56. package/target/Stream.js.map +0 -1
  57. package/target/TagBuilder.js +0 -178
  58. package/target/TagBuilder.js.map +0 -1
  59. package/target/XmlQuery.js +0 -84
  60. package/target/XmlQuery.js.map +0 -1
  61. package/target/classes/com/example/jsfs_js_ts/DecoratedFacesJS.class +0 -0
  62. package/target/classes/com/example/jsfs_js_ts/DecoratingResourceHandlerWrapper.class +0 -0
  63. package/target/classes/com/example/jsfs_js_ts/FacesJSMapFileResourceWrapper.class +0 -0
  64. package/target/classes/com/example/jsfs_js_ts/FacesJSMappingDecorator.class +0 -0
  65. package/target/impl/core/Context.js +0 -10
  66. package/target/impl/core/Context.js.map +0 -1
  67. package/target/impl/util/AsyncQueue.js +0 -109
  68. package/target/impl/util/AsyncQueue.js.map +0 -1
  69. package/target/impl/util/HiddenElementBuilder.js +0 -7
  70. package/target/impl/util/HiddenElementBuilder.js.map +0 -1
  71. package/target/impl/util/IAsyncRunnable.js +0 -27
  72. package/target/impl/util/IAsyncRunnable.js.map +0 -1
  73. package/target/impl/util/URLCodec.js +0 -77
  74. package/target/impl/util/URLCodec.js.map +0 -1
  75. package/target/impl/xhrCore/RequestContext.js +0 -11
  76. package/target/impl/xhrCore/RequestContext.js.map +0 -1
  77. package/target/impl/xhrCore/XhrQueHandler.js +0 -11
  78. package/target/impl/xhrCore/XhrQueHandler.js.map +0 -1
  79. package/target/impl/xhrCore/XhrQueueController.js +0 -62
  80. package/target/impl/xhrCore/XhrQueueController.js.map +0 -1
  81. package/target/index.js +0 -80
  82. package/target/index.js.map +0 -1
  83. package/target/index_core.js +0 -76
  84. package/target/index_core.js.map +0 -1
  85. package/target/test/frameworkBase/_ext/monadish/ExtendedArrayTest.spec.js +0 -76
  86. package/target/test/frameworkBase/_ext/monadish/ExtendedArrayTest.spec.js.map +0 -1
  87. package/target/test/frameworkBase/_ext/monadish/StreamTest.spec.js +0 -178
  88. package/target/test/frameworkBase/_ext/monadish/StreamTest.spec.js.map +0 -1
  89. package/target/test/myfaces/OnLoadSpec.js +0 -57
  90. package/target/test/myfaces/OnLoadSpec.js.map +0 -1
  91. package/target/test-classes/.gz +0 -0
  92. package/target/test-classes/com/example/jsfs_js_ts/JsfsJsTsApplicationTests.class +0 -0
  93. package/target/test-classes/fileuploadtest.html +0 -24
  94. package/target/test-classes/jsf-development.js +0 -3559
  95. package/target/test-classes/jsf-development.js.br +0 -0
  96. package/target/test-classes/jsf-development.js.gz +0 -0
  97. package/target/test-classes/jsf-development.js.map +0 -1
  98. package/target/test-classes/jsf.js +0 -3
  99. package/target/test-classes/jsf.js.br +0 -0
  100. package/target/test-classes/jsf.js.gz +0 -0
  101. package/target/types/main/typescript/AssocArray.d.ts +0 -86
  102. package/target/types/main/typescript/Config.d.ts +0 -94
  103. package/target/types/main/typescript/CryptoExtensions.d.ts +0 -87
  104. package/target/types/main/typescript/DomQuery.d.ts +0 -587
  105. package/target/types/main/typescript/Es2019Array.d.ts +0 -30
  106. package/target/types/main/typescript/Global.d.ts +0 -23
  107. package/target/types/main/typescript/IDomQuery.d.ts +0 -480
  108. package/target/types/main/typescript/Lang.d.ts +0 -97
  109. package/target/types/main/typescript/Messaging.d.ts +0 -285
  110. package/target/types/main/typescript/Monad.d.ts +0 -161
  111. package/target/types/main/typescript/Promise.d.ts +0 -58
  112. package/target/types/main/typescript/PromiseShim.d.ts +0 -22
  113. package/target/types/main/typescript/SourcesCollectors.d.ts +0 -280
  114. package/target/types/main/typescript/Stream.d.ts +0 -284
  115. package/target/types/main/typescript/TagBuilder.d.ts +0 -50
  116. package/target/types/main/typescript/XmlQuery.d.ts +0 -31
  117. package/target/types/main/typescript/api/_api.d.ts +0 -182
  118. package/target/types/main/typescript/api/faces.d.ts +0 -17
  119. package/target/types/main/typescript/api/jsf.d.ts +0 -17
  120. package/target/types/main/typescript/impl/AjaxImpl.d.ts +0 -164
  121. package/target/types/main/typescript/impl/PushImpl.d.ts +0 -38
  122. package/target/types/main/typescript/impl/core/Const.d.ts +0 -138
  123. package/target/types/main/typescript/impl/core/ImplTypes.d.ts +0 -16
  124. package/target/types/main/typescript/impl/i18n/Messages.d.ts +0 -102
  125. package/target/types/main/typescript/impl/util/Assertions.d.ts +0 -46
  126. package/target/types/main/typescript/impl/util/AsyncRunnable.d.ts +0 -112
  127. package/target/types/main/typescript/impl/util/ExtDomQuery.d.ts +0 -100
  128. package/target/types/main/typescript/impl/util/FileUtils.d.ts +0 -25
  129. package/target/types/main/typescript/impl/util/HiddenInputBuilder.d.ts +0 -37
  130. package/target/types/main/typescript/impl/util/IListener.d.ts +0 -18
  131. package/target/types/main/typescript/impl/util/Lang.d.ts +0 -138
  132. package/target/types/main/typescript/impl/util/XhrQueueController.d.ts +0 -51
  133. package/target/types/main/typescript/impl/xhrCore/ErrorData.d.ts +0 -37
  134. package/target/types/main/typescript/impl/xhrCore/EventData.d.ts +0 -25
  135. package/target/types/main/typescript/impl/xhrCore/IResponseProcessor.d.ts +0 -136
  136. package/target/types/main/typescript/impl/xhrCore/RequestDataResolver.d.ts +0 -84
  137. package/target/types/main/typescript/impl/xhrCore/ResonseDataResolver.d.ts +0 -60
  138. package/target/types/main/typescript/impl/xhrCore/Response.d.ts +0 -29
  139. package/target/types/main/typescript/impl/xhrCore/ResponseProcessor.d.ts +0 -208
  140. package/target/types/main/typescript/impl/xhrCore/XhrFormData.d.ts +0 -83
  141. package/target/types/main/typescript/impl/xhrCore/XhrRequest.d.ts +0 -102
  142. package/target/types/main/typescript/index.d.ts +0 -34
  143. package/target/types/main/typescript/index_core.d.ts +0 -29
  144. package/target/types/main/typescript/myfaces/OamSubmit.d.ts +0 -53
  145. package/target/types/main/typescript/test/frameworkBase/LangTest.spec.d.ts +0 -1
  146. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/DomQueryTest.spec.d.ts +0 -1
  147. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/LangTest.spec.d.ts +0 -16
  148. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/MappingProbes.d.ts +0 -39
  149. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/MappingTest.spec.d.ts +0 -16
  150. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/MonadTest.spec.d.ts +0 -16
  151. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/XmlQueryTest.spec.d.ts +0 -0
  152. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/markups/tobago-with-header.d.ts +0 -1
  153. package/target/types/main/typescript/test/frameworkBase/_ext/monadish/markups/tobago-without-header.d.ts +0 -1
  154. package/target/types/main/typescript/test/frameworkBase/_ext/shared/StandardInits.d.ts +0 -63
  155. package/target/types/main/typescript/test/frameworkBase/_ext/shared/XmlResponses.d.ts +0 -23
  156. package/target/types/main/typescript/test/impl/ImplTest.spec.d.ts +0 -16
  157. package/target/types/main/typescript/test/impl/ImplTest_23.spec.d.ts +0 -16
  158. package/target/types/main/typescript/test/impl/SeparatorCharsTest.spec.d.ts +0 -16
  159. package/target/types/main/typescript/test/myfaces/OamSubmit.spec.d.ts +0 -16
  160. package/target/types/main/typescript/test/myfaces/OnLoad.spec.d.ts +0 -16
  161. package/target/types/main/typescript/test/queue/AsynchronousProbe.d.ts +0 -38
  162. package/target/types/main/typescript/test/queue/AsynchronousQueueTest.spec.d.ts +0 -16
  163. package/target/types/main/typescript/test/xhrCore/ClientWindow.spec.d.ts +0 -1
  164. package/target/types/main/typescript/test/xhrCore/ErrorChainTest.spec.d.ts +0 -16
  165. package/target/types/main/typescript/test/xhrCore/EventTests.spec.d.ts +0 -16
  166. package/target/types/main/typescript/test/xhrCore/FakeWebsocket.d.ts +0 -24
  167. package/target/types/main/typescript/test/xhrCore/FileUploadTest.spec.d.ts +0 -1
  168. package/target/types/main/typescript/test/xhrCore/NamespacesRequestTest.spec.d.ts +0 -16
  169. package/target/types/main/typescript/test/xhrCore/OamSubmitTest.spec.d.ts +0 -16
  170. package/target/types/main/typescript/test/xhrCore/RequestParamsTest.spec.d.ts +0 -1
  171. package/target/types/main/typescript/test/xhrCore/RequestTest.spec.d.ts +0 -16
  172. package/target/types/main/typescript/test/xhrCore/RequestTest_23.spec.d.ts +0 -16
  173. package/target/types/main/typescript/test/xhrCore/ResponseTest.spec.d.ts +0 -16
  174. package/target/types/main/typescript/test/xhrCore/ResponseTest23.spec.d.ts +0 -16
  175. package/target/types/main/typescript/test/xhrCore/ShadowDomTest.spec.d.ts +0 -16
  176. package/target/types/main/typescript/test/xhrCore/TobagoFileUploadTest.spec.d.ts +0 -1
  177. package/target/types/main/typescript/test/xhrCore/WebsocketTest.d.ts +0 -1
  178. package/target/types/main/typescript/test/xhrCore/XhrFormDataTest.spec.d.ts +0 -16
  179. package/target/types/test/typescript/AssocArrayTest.spec.d.ts +0 -1
  180. package/target/types/test/typescript/DomQueryTest.spec.d.ts +0 -1
  181. package/target/types/test/typescript/ExtendedArrayTest.spec.d.ts +0 -1
  182. package/target/types/test/typescript/LangTest.spec.d.ts +0 -1
  183. package/target/types/test/typescript/MappingProbes.d.ts +0 -24
  184. package/target/types/test/typescript/MappingTest.spec.d.ts +0 -1
  185. package/target/types/test/typescript/MessagingTest.spec.d.ts +0 -1
  186. package/target/types/test/typescript/MonadTest.spec.d.ts +0 -16
  187. package/target/types/test/typescript/PromiseTest.spec.d.ts +0 -1
  188. package/target/types/test/typescript/StreamTest.spec.d.ts +0 -1
  189. package/target/types/test/typescript/XmlQueryTest.spec.d.ts +0 -1
  190. package/target/types/test/typescript/markups/tobago-with-header.d.ts +0 -1
  191. package/target/types/test/typescript/markups/tobago-without-header.d.ts +0 -1
@@ -580,6 +580,34 @@ var isString = Lang_1.Lang.isString;
580
580
  var eqi = Lang_1.Lang.equalsIgnoreCase;
581
581
  var objToArray = Lang_1.Lang.objToArray;
582
582
  const AssocArray_1 = __webpack_require__(/*! ./AssocArray */ "./node_modules/mona-dish/src/main/typescript/AssocArray.ts");
583
+ class NonceValueEmbedder extends Monad_1.ValueEmbedder {
584
+ constructor(rootElems) {
585
+ super(rootElems === null || rootElems === void 0 ? void 0 : rootElems[0], "nonce");
586
+ this.rootElems = rootElems;
587
+ }
588
+ isAbsent() {
589
+ const value = this.value;
590
+ return 'undefined' == typeof value || '' == value;
591
+ }
592
+ get value() {
593
+ var _a, _b, _c, _d, _e;
594
+ return (_c = (_b = (_a = this === null || this === void 0 ? void 0 : this.rootElems) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.nonce) !== null && _c !== void 0 ? _c : (_e = (_d = this === null || this === void 0 ? void 0 : this.rootElems) === null || _d === void 0 ? void 0 : _d[0]) === null || _e === void 0 ? void 0 : _e.getAttribute("nonce");
595
+ }
596
+ set value(newVal) {
597
+ var _a;
598
+ if (!((_a = this === null || this === void 0 ? void 0 : this.rootElems) === null || _a === void 0 ? void 0 : _a.length)) {
599
+ return;
600
+ }
601
+ this.rootElems.forEach((rootElem) => {
602
+ if ("undefined" != typeof (rootElem === null || rootElem === void 0 ? void 0 : rootElem.nonce)) {
603
+ rootElem.nonce = newVal;
604
+ }
605
+ else {
606
+ rootElem.setAttribute("nonce", newVal);
607
+ }
608
+ });
609
+ }
610
+ }
583
611
  /**
584
612
  *
585
613
  * // - submit checkboxes and radio inputs only if checked
@@ -983,8 +1011,7 @@ class DomQuery {
983
1011
  return new Es2019Array_1.Es2019Array(...this.rootNode.filter(item => item != null));
984
1012
  }
985
1013
  get nonce() {
986
- var _a, _b, _c, _d, _e;
987
- return Monad_1.Optional.fromNullable((_c = (_b = (_a = this === null || this === void 0 ? void 0 : this.rootNode) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.nonce) !== null && _c !== void 0 ? _c : (_e = (_d = this === null || this === void 0 ? void 0 : this.rootNode) === null || _d === void 0 ? void 0 : _d[0]) === null || _e === void 0 ? void 0 : _e.getAttribute("nonce"));
1014
+ return new NonceValueEmbedder(this.rootNode);
988
1015
  }
989
1016
  static querySelectorAllDeep(selector) {
990
1017
  return new DomQuery(document).querySelectorAllDeep(selector);
@@ -1678,11 +1705,18 @@ class DomQuery {
1678
1705
  case "checked":
1679
1706
  this.resolveAttributeHolder("checked").checked = value;
1680
1707
  break;
1708
+ case "nonce":
1709
+ // nonce will be handled below!
1710
+ break;
1681
1711
  default:
1682
1712
  this.attr(name).value = value;
1683
1713
  }
1684
1714
  }
1685
1715
  });
1716
+ //special nonce handling
1717
+ sourceItem.nonce.isPresent(() => {
1718
+ this.nonce.value = sourceItem.nonce.value;
1719
+ });
1686
1720
  return this;
1687
1721
  }
1688
1722
  /**
@@ -5815,19 +5849,19 @@ class ExtDomQuery extends mona_dish_1.DQ {
5815
5849
  * this is done once and only lazily
5816
5850
  */
5817
5851
  get nonce() {
5818
- var _a, _b, _c;
5852
+ var _a;
5819
5853
  //already processed
5820
5854
  let myfacesConfig = new ExtConfig(window.myfaces);
5821
5855
  let globalNonce = myfacesConfig.getIf("config", "cspMeta", "nonce");
5822
5856
  if (!!globalNonce.value) {
5823
- return mona_dish_1.Optional.fromNullable(globalNonce.value);
5857
+ return mona_dish_1.ValueEmbedder.fromNullable(globalNonce);
5824
5858
  }
5825
5859
  let curScript = new mona_dish_1.DQ(document.currentScript);
5826
5860
  //since our baseline atm is ie11 we cannot use document.currentScript globally
5827
5861
  let nonce = curScript.nonce;
5828
5862
  if (nonce.isPresent()) {
5829
5863
  // fast-path for modern browsers
5830
- return nonce;
5864
+ return mona_dish_1.ValueEmbedder.fromNullable(nonce);
5831
5865
  }
5832
5866
  // fallback if the currentScript method fails, we just search the jsf tags for nonce, this is
5833
5867
  // the last possibility
@@ -5835,7 +5869,10 @@ class ExtDomQuery extends mona_dish_1.DQ {
5835
5869
  .querySelectorAll("script[src], link[src]").asArray
5836
5870
  .filter((item) => item.nonce.isPresent() && item.attr(ATTR_SRC) != null)
5837
5871
  .filter(item => IS_FACES_SOURCE(item.attr(ATTR_SRC).value))) === null || _a === void 0 ? void 0 : _a[0]);
5838
- return mona_dish_1.Optional.fromNullable((_c = (_b = nonceScript.value) === null || _b === void 0 ? void 0 : _b.nonce) === null || _c === void 0 ? void 0 : _c.value);
5872
+ if (!(nonceScript === null || nonceScript === void 0 ? void 0 : nonceScript.value)) {
5873
+ return mona_dish_1.ValueEmbedder.absent;
5874
+ }
5875
+ return new mona_dish_1.DomQuery(nonceScript.value).nonce;
5839
5876
  }
5840
5877
  static searchJsfJsFor(item) {
5841
5878
  return new ExtDomQuery(document).searchJsfJsFor(item);
@@ -7916,6 +7953,7 @@ const Lang_1 = __webpack_require__(/*! ../util/Lang */ "./src/main/typescript/im
7916
7953
  const Const_1 = __webpack_require__(/*! ../core/Const */ "./src/main/typescript/impl/core/Const.ts");
7917
7954
  const RequestDataResolver_1 = __webpack_require__(/*! ./RequestDataResolver */ "./src/main/typescript/impl/xhrCore/RequestDataResolver.ts");
7918
7955
  var failSaveExecute = Lang_1.ExtLang.failSaveExecute;
7956
+ const ExtDomQuery_1 = __webpack_require__(/*! ../util/ExtDomQuery */ "./src/main/typescript/impl/util/ExtDomQuery.ts");
7919
7957
  /**
7920
7958
  * Faces XHR Request Wrapper
7921
7959
  * as AsyncRunnable for our Asynchronous queue
@@ -7995,6 +8033,13 @@ class XhrRequest extends AsyncRunnable_1.AsyncRunnable {
7995
8033
  this.requestContext.$nspEnabled = true;
7996
8034
  requestPassThroughParams.$nspEnabled = true;
7997
8035
  }
8036
+ const issuingItemId = this.internalContext.getIf(Const_1.CTX_PARAM_SRC_CTL_ID).value;
8037
+ if (issuingItemId) {
8038
+ const issuingItem = mona_dish_1.DQ.byId(issuingItemId);
8039
+ const arr = new ExtDomQuery_1.ExtConfig({});
8040
+ arr.assign(issuingItemId).value = issuingItem.val;
8041
+ formData.shallowMerge(arr, true, true);
8042
+ }
7998
8043
  this.responseContext = requestPassThroughParams.deepCopy;
7999
8044
  // we have to shift the internal passthroughs around to build up our response context
8000
8045
  const responseContext = this.responseContext;
Binary file
Binary file