@verdocs/web-sdk 1.14.12 → 1.15.0

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 (317) hide show
  1. package/dist/cjs/DateTime-ec575ec3.js +45 -0
  2. package/dist/cjs/{EnvelopeStore-a4231cf7.js → EnvelopeStore-00d2572c.js} +1 -1
  3. package/dist/cjs/{Envelopes-e5ffb6a5.js → Envelopes-43302e10.js} +17 -0
  4. package/dist/cjs/{Permissions-4b710db2.js → Permissions-0229bc30.js} +14 -0
  5. package/dist/cjs/{TemplateStore-f2fb6a62.js → TemplateStore-19f84862.js} +1 -1
  6. package/dist/cjs/{index-6528b430.js → index-7c19ba1d.js} +63 -219
  7. package/dist/cjs/ipc-test.cjs.entry.js +37 -0
  8. package/dist/cjs/loader.cjs.js +1 -1
  9. package/dist/cjs/{utils-f4efefe3.js → utils-2eefb975.js} +2 -2
  10. package/dist/cjs/verdocs-activity-box.cjs.entry.js +91 -0
  11. package/dist/cjs/verdocs-auth.cjs.entry.js +1 -1
  12. package/dist/cjs/verdocs-build.cjs.entry.js +2 -2
  13. package/dist/cjs/verdocs-button-panel_3.cjs.entry.js +2 -2
  14. package/dist/cjs/verdocs-contact-picker.cjs.entry.js +1 -1
  15. package/dist/cjs/verdocs-dropdown.cjs.entry.js +88 -0
  16. package/dist/cjs/{verdocs-template-document-page.cjs.entry.js → verdocs-envelope-document-page.cjs.entry.js} +14 -14
  17. package/dist/cjs/verdocs-envelope-recipient-summary.cjs.entry.js +4 -4
  18. package/dist/cjs/verdocs-envelope-sidebar.cjs.entry.js +5 -5
  19. package/dist/cjs/verdocs-envelopes-list.cjs.entry.js +233 -0
  20. package/dist/cjs/verdocs-field-checkbox.cjs.entry.js +3 -3
  21. package/dist/cjs/verdocs-field-date.cjs.entry.js +3 -3
  22. package/dist/cjs/verdocs-field-dropdown.cjs.entry.js +3 -3
  23. package/dist/cjs/verdocs-field-initial.cjs.entry.js +3 -3
  24. package/dist/cjs/verdocs-field-payment.cjs.entry.js +3 -3
  25. package/dist/cjs/verdocs-field-radio-button.cjs.entry.js +3 -3
  26. package/dist/cjs/verdocs-field-signature.cjs.entry.js +3 -3
  27. package/dist/cjs/verdocs-field-textarea.cjs.entry.js +4 -4
  28. package/dist/cjs/verdocs-field-textbox.cjs.entry.js +4 -4
  29. package/dist/cjs/verdocs-field-timestamp.cjs.entry.js +3 -3
  30. package/dist/cjs/verdocs-file-chooser_2.cjs.entry.js +1 -1
  31. package/dist/cjs/verdocs-organization-card.cjs.entry.js +1 -1
  32. package/dist/cjs/verdocs-preview.cjs.entry.js +5 -5
  33. package/dist/cjs/verdocs-quick-functions_3.cjs.entry.js +1 -1
  34. package/dist/cjs/verdocs-radio-button.cjs.entry.js +23 -0
  35. package/dist/cjs/verdocs-search.cjs.entry.js +1 -1
  36. package/dist/cjs/verdocs-send.cjs.entry.js +5 -5
  37. package/dist/cjs/verdocs-sign.cjs.entry.js +4 -4
  38. package/dist/cjs/verdocs-template-attachments_2.cjs.entry.js +236 -0
  39. package/dist/cjs/verdocs-template-document-page_2.cjs.entry.js +150 -0
  40. package/dist/cjs/{verdocs-template-attachments_4.cjs.entry.js → verdocs-template-fields_4.cjs.entry.js} +242 -233
  41. package/dist/cjs/verdocs-template-name.cjs.entry.js +2 -2
  42. package/dist/cjs/verdocs-template-reminders.cjs.entry.js +12 -2
  43. package/dist/cjs/verdocs-template-visibility.cjs.entry.js +2 -2
  44. package/dist/cjs/verdocs-templates-list.cjs.entry.js +91 -0
  45. package/dist/cjs/verdocs-view.cjs.entry.js +5 -5
  46. package/dist/cjs/verdocs-web-sdk.cjs.js +1 -1
  47. package/dist/collection/collection-manifest.json +5 -1
  48. package/dist/collection/components/envelopes/verdocs-activity-box/verdocs-activity-box.css +130 -0
  49. package/dist/collection/components/envelopes/verdocs-activity-box/verdocs-activity-box.js +246 -0
  50. package/dist/collection/components/envelopes/verdocs-activity-box/verdocs-activity-box.stories.js +15 -0
  51. package/dist/collection/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.css +74 -0
  52. package/dist/collection/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.js +474 -0
  53. package/dist/collection/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.stories.js +18 -0
  54. package/dist/collection/components/other/ipctest/ipc-test.css +4 -0
  55. package/dist/collection/components/other/ipctest/ipc-test.js +79 -0
  56. package/dist/collection/components/other/ipctest/ipc-test.stories.js +8 -0
  57. package/dist/collection/components/templates/verdocs-templates-list/verdocs-templates-list.css +3 -0
  58. package/dist/collection/components/templates/verdocs-templates-list/verdocs-templates-list.js +246 -0
  59. package/dist/collection/components/templates/verdocs-templates-list/verdocs-templates-list.stories.js +16 -0
  60. package/dist/components/DateTime.js +43 -0
  61. package/dist/components/Envelopes.js +17 -1
  62. package/dist/components/Permissions.js +13 -1
  63. package/dist/components/VerdocsEndpoint.js +30 -30
  64. package/dist/components/index.d.ts +4 -0
  65. package/dist/components/index.js +4 -0
  66. package/dist/components/index2.js +63 -219
  67. package/dist/components/ipc-test.d.ts +11 -0
  68. package/dist/components/ipc-test.js +142 -0
  69. package/dist/components/utils.js +1 -1
  70. package/dist/components/verdocs-activity-box.d.ts +11 -0
  71. package/dist/components/verdocs-activity-box.js +120 -0
  72. package/dist/components/verdocs-envelope-recipient-summary2.js +1 -1
  73. package/dist/components/verdocs-envelopes-list.d.ts +11 -0
  74. package/dist/components/verdocs-envelopes-list.js +298 -0
  75. package/dist/components/verdocs-sign.js +1 -1
  76. package/dist/components/verdocs-status-indicator.js +1 -7463
  77. package/dist/components/verdocs-status-indicator2.js +7465 -0
  78. package/dist/components/verdocs-template-fields2.js +1 -1
  79. package/dist/components/verdocs-template-reminders.js +10 -0
  80. package/dist/components/verdocs-templates-list.d.ts +11 -0
  81. package/dist/components/verdocs-templates-list.js +120 -0
  82. package/dist/components/verdocs-view2.js +2 -2
  83. package/dist/docs.json +667 -39
  84. package/dist/esm/DateTime-402fe7ca.js +43 -0
  85. package/dist/esm/{EnvelopeStore-28f5d8f5.js → EnvelopeStore-2a74a367.js} +1 -1
  86. package/dist/esm/{Envelopes-105a4a8f.js → Envelopes-e69b678a.js} +17 -1
  87. package/dist/esm/{Permissions-7192ef7c.js → Permissions-2ac18553.js} +13 -1
  88. package/dist/esm/{TemplateStore-87c99dfc.js → TemplateStore-852097c3.js} +1 -1
  89. package/dist/esm/{index-d264c496.js → index-914ed6f7.js} +63 -219
  90. package/dist/esm/ipc-test.entry.js +33 -0
  91. package/dist/esm/loader.js +1 -1
  92. package/dist/esm/{utils-1bb75f32.js → utils-8ae39b63.js} +3 -3
  93. package/dist/esm/verdocs-activity-box.entry.js +87 -0
  94. package/dist/esm/verdocs-auth.entry.js +1 -1
  95. package/dist/esm/verdocs-build.entry.js +2 -2
  96. package/dist/esm/verdocs-button-panel_3.entry.js +2 -2
  97. package/dist/esm/verdocs-contact-picker.entry.js +1 -1
  98. package/dist/esm/verdocs-dropdown.entry.js +84 -0
  99. package/dist/esm/{verdocs-template-document-page.entry.js → verdocs-envelope-document-page.entry.js} +14 -14
  100. package/dist/esm/verdocs-envelope-recipient-summary.entry.js +4 -4
  101. package/dist/esm/verdocs-envelope-sidebar.entry.js +5 -5
  102. package/dist/esm/verdocs-envelopes-list.entry.js +229 -0
  103. package/dist/esm/verdocs-field-checkbox.entry.js +3 -3
  104. package/dist/esm/verdocs-field-date.entry.js +3 -3
  105. package/dist/esm/verdocs-field-dropdown.entry.js +3 -3
  106. package/dist/esm/verdocs-field-initial.entry.js +3 -3
  107. package/dist/esm/verdocs-field-payment.entry.js +3 -3
  108. package/dist/esm/verdocs-field-radio-button.entry.js +3 -3
  109. package/dist/esm/verdocs-field-signature.entry.js +3 -3
  110. package/dist/esm/verdocs-field-textarea.entry.js +4 -4
  111. package/dist/esm/verdocs-field-textbox.entry.js +4 -4
  112. package/dist/esm/verdocs-field-timestamp.entry.js +3 -3
  113. package/dist/esm/verdocs-file-chooser_2.entry.js +1 -1
  114. package/dist/esm/verdocs-organization-card.entry.js +1 -1
  115. package/dist/esm/verdocs-preview.entry.js +5 -5
  116. package/dist/esm/verdocs-quick-functions_3.entry.js +1 -1
  117. package/dist/esm/verdocs-radio-button.entry.js +19 -0
  118. package/dist/esm/verdocs-search.entry.js +1 -1
  119. package/dist/esm/verdocs-send.entry.js +5 -5
  120. package/dist/esm/verdocs-sign.entry.js +4 -4
  121. package/dist/esm/verdocs-template-attachments_2.entry.js +231 -0
  122. package/dist/esm/verdocs-template-document-page_2.entry.js +145 -0
  123. package/dist/esm/{verdocs-template-attachments_4.entry.js → verdocs-template-fields_4.entry.js} +239 -230
  124. package/dist/esm/verdocs-template-name.entry.js +2 -2
  125. package/dist/esm/verdocs-template-reminders.entry.js +12 -2
  126. package/dist/esm/verdocs-template-visibility.entry.js +2 -2
  127. package/dist/esm/verdocs-templates-list.entry.js +87 -0
  128. package/dist/esm/verdocs-view.entry.js +5 -5
  129. package/dist/esm/verdocs-web-sdk.js +1 -1
  130. package/dist/esm-es5/DateTime-402fe7ca.js +1 -0
  131. package/dist/esm-es5/{EnvelopeStore-28f5d8f5.js → EnvelopeStore-2a74a367.js} +1 -1
  132. package/dist/esm-es5/Envelopes-e69b678a.js +1 -0
  133. package/dist/esm-es5/{Permissions-7192ef7c.js → Permissions-2ac18553.js} +1 -1
  134. package/dist/esm-es5/{TemplateStore-87c99dfc.js → TemplateStore-852097c3.js} +1 -1
  135. package/dist/esm-es5/{VerdocsEndpoint-6d7a17ce.js → VerdocsEndpoint-5b92f115.js} +1 -1
  136. package/dist/esm-es5/index-914ed6f7.js +1 -0
  137. package/dist/esm-es5/ipc-test.entry.js +1 -0
  138. package/dist/esm-es5/loader.js +1 -1
  139. package/dist/esm-es5/{utils-1bb75f32.js → utils-8ae39b63.js} +2 -2
  140. package/dist/esm-es5/verdocs-activity-box.entry.js +1 -0
  141. package/dist/esm-es5/verdocs-auth.entry.js +1 -1
  142. package/dist/esm-es5/verdocs-build.entry.js +1 -1
  143. package/dist/esm-es5/verdocs-button-panel_3.entry.js +1 -1
  144. package/dist/esm-es5/verdocs-contact-picker.entry.js +1 -1
  145. package/dist/esm-es5/verdocs-dropdown.entry.js +1 -0
  146. package/dist/esm-es5/verdocs-envelope-document-page.entry.js +1 -0
  147. package/dist/esm-es5/verdocs-envelope-recipient-summary.entry.js +1 -1
  148. package/dist/esm-es5/verdocs-envelope-sidebar.entry.js +1 -1
  149. package/dist/esm-es5/verdocs-envelopes-list.entry.js +1 -0
  150. package/dist/esm-es5/verdocs-field-checkbox.entry.js +1 -1
  151. package/dist/esm-es5/verdocs-field-date.entry.js +1 -1
  152. package/dist/esm-es5/verdocs-field-dropdown.entry.js +1 -1
  153. package/dist/esm-es5/verdocs-field-initial.entry.js +1 -1
  154. package/dist/esm-es5/verdocs-field-payment.entry.js +1 -1
  155. package/dist/esm-es5/verdocs-field-radio-button.entry.js +1 -1
  156. package/dist/esm-es5/verdocs-field-signature.entry.js +1 -1
  157. package/dist/esm-es5/verdocs-field-textarea.entry.js +1 -1
  158. package/dist/esm-es5/verdocs-field-textbox.entry.js +1 -1
  159. package/dist/esm-es5/verdocs-field-timestamp.entry.js +1 -1
  160. package/dist/esm-es5/verdocs-file-chooser_2.entry.js +1 -1
  161. package/dist/esm-es5/verdocs-organization-card.entry.js +1 -1
  162. package/dist/esm-es5/verdocs-preview.entry.js +1 -1
  163. package/dist/esm-es5/verdocs-quick-functions_3.entry.js +1 -1
  164. package/dist/esm-es5/verdocs-radio-button.entry.js +1 -0
  165. package/dist/esm-es5/verdocs-search.entry.js +1 -1
  166. package/dist/esm-es5/verdocs-send.entry.js +1 -1
  167. package/dist/esm-es5/verdocs-sign.entry.js +1 -1
  168. package/dist/esm-es5/verdocs-template-attachments_2.entry.js +1 -0
  169. package/dist/esm-es5/verdocs-template-document-page_2.entry.js +1 -0
  170. package/dist/esm-es5/verdocs-template-fields_4.entry.js +1 -0
  171. package/dist/esm-es5/verdocs-template-name.entry.js +1 -1
  172. package/dist/esm-es5/verdocs-template-reminders.entry.js +1 -1
  173. package/dist/esm-es5/verdocs-template-visibility.entry.js +1 -1
  174. package/dist/esm-es5/verdocs-templates-list.entry.js +1 -0
  175. package/dist/esm-es5/verdocs-view.entry.js +1 -1
  176. package/dist/esm-es5/verdocs-web-sdk.js +1 -1
  177. package/dist/types/components/envelopes/verdocs-activity-box/verdocs-activity-box.d.ts +60 -0
  178. package/dist/types/components/envelopes/verdocs-activity-box/verdocs-activity-box.stories.d.ts +10 -0
  179. package/dist/types/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.d.ts +76 -0
  180. package/dist/types/components/envelopes/verdocs-envelopes-list/verdocs-envelopes-list.stories.d.ts +10 -0
  181. package/dist/types/components/other/ipctest/ipc-test.d.ts +17 -0
  182. package/dist/types/components/other/ipctest/ipc-test.stories.d.ts +4 -0
  183. package/dist/types/components/templates/verdocs-templates-list/verdocs-templates-list.d.ts +55 -0
  184. package/dist/types/components/templates/verdocs-templates-list/verdocs-templates-list.stories.d.ts +7 -0
  185. package/dist/types/components.d.ts +228 -2
  186. package/dist/verdocs-web-sdk/{p-10bb1e56.entry.js → p-0177fb6c.entry.js} +1 -1
  187. package/dist/verdocs-web-sdk/{p-255a66f9.system.entry.js → p-0529a428.system.entry.js} +1 -1
  188. package/dist/verdocs-web-sdk/p-0a5390c7.js +1 -0
  189. package/dist/verdocs-web-sdk/{p-172f5d37.system.entry.js → p-0aaca8d5.system.entry.js} +1 -1
  190. package/dist/verdocs-web-sdk/{p-ff662b13.js → p-0b4ea5f9.js} +1 -1
  191. package/dist/verdocs-web-sdk/{p-ac2b339a.system.entry.js → p-0c0ac290.system.entry.js} +1 -1
  192. package/dist/verdocs-web-sdk/{p-bbdafeac.entry.js → p-0f8c70ec.entry.js} +1 -1
  193. package/dist/verdocs-web-sdk/{p-dfbf689b.entry.js → p-10e8d145.entry.js} +1 -1
  194. package/dist/verdocs-web-sdk/{p-8109a994.system.entry.js → p-13200610.system.entry.js} +1 -1
  195. package/dist/verdocs-web-sdk/p-138fd801.system.js +1 -0
  196. package/dist/verdocs-web-sdk/{p-2a3de488.system.entry.js → p-1420d87e.system.entry.js} +1 -1
  197. package/dist/verdocs-web-sdk/{p-83535db7.entry.js → p-16baf630.entry.js} +1 -1
  198. package/dist/verdocs-web-sdk/p-18a67b44.system.js +1 -0
  199. package/dist/verdocs-web-sdk/{p-237edd0b.entry.js → p-19e1c76a.entry.js} +1 -1
  200. package/dist/verdocs-web-sdk/{p-886461cd.system.entry.js → p-1a0cccea.system.entry.js} +1 -1
  201. package/dist/verdocs-web-sdk/{p-204f69c7.entry.js → p-1ae77200.entry.js} +1 -1
  202. package/dist/verdocs-web-sdk/p-1cf38cea.system.js +1 -1
  203. package/dist/verdocs-web-sdk/{p-c0635249.system.entry.js → p-208b2e94.system.entry.js} +1 -1
  204. package/dist/verdocs-web-sdk/{p-7399931a.system.entry.js → p-21e90bbf.system.entry.js} +1 -1
  205. package/dist/verdocs-web-sdk/{p-b1ffa27a.entry.js → p-22939ee9.entry.js} +1 -1
  206. package/dist/verdocs-web-sdk/p-244414ca.entry.js +1 -0
  207. package/dist/verdocs-web-sdk/p-2672bfb4.system.entry.js +1 -0
  208. package/dist/verdocs-web-sdk/{p-e5365d23.system.entry.js → p-2750155d.system.entry.js} +1 -1
  209. package/dist/verdocs-web-sdk/{p-2d2bdf3c.system.entry.js → p-2d32da1d.system.entry.js} +1 -1
  210. package/dist/verdocs-web-sdk/{p-a78616fe.entry.js → p-2d7d69a2.entry.js} +1 -1
  211. package/dist/verdocs-web-sdk/p-2f0cd03d.system.js +1 -0
  212. package/dist/verdocs-web-sdk/{p-3a9d248d.entry.js → p-31a49d0c.entry.js} +1 -1
  213. package/dist/verdocs-web-sdk/{p-8387794f.system.entry.js → p-31e3d00e.system.entry.js} +1 -1
  214. package/dist/verdocs-web-sdk/{p-d21e9e04.system.js → p-3c6f9c7f.system.js} +2 -2
  215. package/dist/verdocs-web-sdk/{p-9d90ed3d.system.entry.js → p-3e4f73cb.system.entry.js} +1 -1
  216. package/dist/verdocs-web-sdk/{p-017dc2a9.entry.js → p-3f9d879c.entry.js} +1 -1
  217. package/dist/verdocs-web-sdk/p-4083d24f.system.entry.js +1 -0
  218. package/dist/verdocs-web-sdk/{p-8fcb22ea.entry.js → p-438daf23.entry.js} +1 -1
  219. package/dist/verdocs-web-sdk/{p-18ee4fd5.js → p-4391cd11.js} +1 -1
  220. package/dist/verdocs-web-sdk/{p-3ea489e9.js → p-4b65e2f3.js} +1 -1
  221. package/dist/verdocs-web-sdk/{p-a6258dde.system.js → p-4cc5d833.system.js} +1 -1
  222. package/dist/verdocs-web-sdk/{p-bcda78a9.system.entry.js → p-4e025c82.system.entry.js} +1 -1
  223. package/dist/verdocs-web-sdk/{p-8dacb527.entry.js → p-4f0bf0de.entry.js} +1 -1
  224. package/dist/verdocs-web-sdk/{p-12f0c4e0.system.entry.js → p-51cfde70.system.entry.js} +1 -1
  225. package/dist/verdocs-web-sdk/p-522127c8.entry.js +1 -0
  226. package/dist/verdocs-web-sdk/p-52428dff.entry.js +1 -0
  227. package/dist/verdocs-web-sdk/{p-773a2544.system.entry.js → p-57ee65dc.system.entry.js} +1 -1
  228. package/dist/verdocs-web-sdk/p-58bb657b.entry.js +1 -0
  229. package/dist/verdocs-web-sdk/p-68662f17.entry.js +1 -0
  230. package/dist/verdocs-web-sdk/{p-43f5476c.entry.js → p-6c01e798.entry.js} +1 -1
  231. package/dist/verdocs-web-sdk/{p-f61f02a7.entry.js → p-6e62e65a.entry.js} +1 -1
  232. package/dist/verdocs-web-sdk/p-70b42a9c.system.entry.js +1 -0
  233. package/dist/verdocs-web-sdk/{p-ededd783.entry.js → p-7ac080d6.entry.js} +1 -1
  234. package/dist/verdocs-web-sdk/{p-750fabdb.entry.js → p-7fb69dde.entry.js} +1 -1
  235. package/dist/verdocs-web-sdk/{p-df439631.system.entry.js → p-8080f854.system.entry.js} +1 -1
  236. package/dist/verdocs-web-sdk/{p-9dd19ab5.system.entry.js → p-84457a67.system.entry.js} +1 -1
  237. package/dist/verdocs-web-sdk/p-87cf1148.entry.js +1 -0
  238. package/dist/verdocs-web-sdk/p-89aac159.system.entry.js +1 -0
  239. package/dist/verdocs-web-sdk/{p-5d19f075.entry.js → p-8aba7c0a.entry.js} +1 -1
  240. package/dist/verdocs-web-sdk/{p-8fb2cf32.js → p-8ec8d450.js} +2 -2
  241. package/dist/verdocs-web-sdk/{p-bf850bb9.system.entry.js → p-95fc08e1.system.entry.js} +1 -1
  242. package/dist/verdocs-web-sdk/p-9e9ab67f.entry.js +1 -0
  243. package/dist/verdocs-web-sdk/{p-a5eebbfa.entry.js → p-a5bce263.entry.js} +1 -1
  244. package/dist/verdocs-web-sdk/p-aa3fd489.entry.js +1 -0
  245. package/dist/verdocs-web-sdk/{p-d763dac2.entry.js → p-ac58dba7.entry.js} +1 -1
  246. package/dist/verdocs-web-sdk/p-acaf51f7.system.entry.js +1 -0
  247. package/dist/verdocs-web-sdk/{p-25870f11.system.entry.js → p-ad7f71cf.system.entry.js} +1 -1
  248. package/dist/verdocs-web-sdk/p-afeff3d1.system.entry.js +1 -0
  249. package/dist/verdocs-web-sdk/p-b43d0cd6.system.entry.js +1 -0
  250. package/dist/verdocs-web-sdk/{p-1236c197.system.entry.js → p-b56feb8c.system.entry.js} +1 -1
  251. package/dist/verdocs-web-sdk/{p-e702cf26.entry.js → p-be3c4aa9.entry.js} +1 -1
  252. package/dist/verdocs-web-sdk/p-c16d1ce1.js +1 -0
  253. package/dist/verdocs-web-sdk/p-c220af42.js +1 -0
  254. package/dist/verdocs-web-sdk/p-c6e4d0fc.system.entry.js +1 -0
  255. package/dist/verdocs-web-sdk/{p-c7dbe82b.system.entry.js → p-c6f6fe4f.system.entry.js} +1 -1
  256. package/dist/verdocs-web-sdk/{p-19450d55.system.entry.js → p-c841a530.system.entry.js} +1 -1
  257. package/dist/verdocs-web-sdk/p-cafd699c.entry.js +1 -0
  258. package/dist/verdocs-web-sdk/{p-1c4f6ae6.entry.js → p-cc3ff9dc.entry.js} +1 -1
  259. package/dist/verdocs-web-sdk/{p-365a8a00.entry.js → p-cd1e5de4.entry.js} +1 -1
  260. package/dist/verdocs-web-sdk/{p-a596cd4f.system.entry.js → p-d35f7faa.system.entry.js} +1 -1
  261. package/dist/verdocs-web-sdk/p-d5316866.entry.js +1 -0
  262. package/dist/verdocs-web-sdk/{p-365a0216.system.js → p-dc849a58.system.js} +1 -1
  263. package/dist/verdocs-web-sdk/p-dc9c4361.system.js +1 -0
  264. package/dist/verdocs-web-sdk/{p-56c65857.system.entry.js → p-e4ceaebf.system.entry.js} +1 -1
  265. package/dist/verdocs-web-sdk/{p-d09a9e1b.system.entry.js → p-e59117c8.system.entry.js} +1 -1
  266. package/dist/verdocs-web-sdk/{p-d146b48e.entry.js → p-e72c075e.entry.js} +1 -1
  267. package/dist/verdocs-web-sdk/p-e82a7328.js +1 -0
  268. package/dist/verdocs-web-sdk/p-e8418235.entry.js +1 -0
  269. package/dist/verdocs-web-sdk/{p-991afbb9.entry.js → p-ebca6188.entry.js} +1 -1
  270. package/dist/verdocs-web-sdk/p-ee84ffc0.system.js +1 -0
  271. package/dist/verdocs-web-sdk/p-f0749d37.system.entry.js +1 -0
  272. package/dist/verdocs-web-sdk/{p-5df694ab.system.entry.js → p-f1accb35.system.entry.js} +1 -1
  273. package/dist/verdocs-web-sdk/{p-7917673a.system.entry.js → p-f37f1ebc.system.entry.js} +1 -1
  274. package/dist/verdocs-web-sdk/{p-ca57cd6e.entry.js → p-f483cd49.entry.js} +1 -1
  275. package/dist/verdocs-web-sdk/p-f9c6fa6c.system.entry.js +1 -0
  276. package/dist/verdocs-web-sdk/p-fdc4e659.entry.js +1 -0
  277. package/dist/verdocs-web-sdk/verdocs-web-sdk.esm.js +1 -1
  278. package/package.json +2 -2
  279. package/dist/cjs/Roles-9b593b95.js +0 -28
  280. package/dist/cjs/verdocs-dropdown_2.cjs.entry.js +0 -187
  281. package/dist/cjs/verdocs-radio-button_3.cjs.entry.js +0 -241
  282. package/dist/cjs/verdocs-toolbar-icon.cjs.entry.js +0 -51
  283. package/dist/esm/Roles-6eb459df.js +0 -24
  284. package/dist/esm/verdocs-dropdown_2.entry.js +0 -182
  285. package/dist/esm/verdocs-radio-button_3.entry.js +0 -235
  286. package/dist/esm/verdocs-toolbar-icon.entry.js +0 -47
  287. package/dist/esm-es5/Envelopes-105a4a8f.js +0 -1
  288. package/dist/esm-es5/Roles-6eb459df.js +0 -1
  289. package/dist/esm-es5/index-d264c496.js +0 -1
  290. package/dist/esm-es5/verdocs-dropdown_2.entry.js +0 -1
  291. package/dist/esm-es5/verdocs-radio-button_3.entry.js +0 -1
  292. package/dist/esm-es5/verdocs-template-attachments_4.entry.js +0 -1
  293. package/dist/esm-es5/verdocs-template-document-page.entry.js +0 -1
  294. package/dist/esm-es5/verdocs-toolbar-icon.entry.js +0 -1
  295. package/dist/verdocs-web-sdk/p-1e8d9829.entry.js +0 -1
  296. package/dist/verdocs-web-sdk/p-27846894.system.entry.js +0 -1
  297. package/dist/verdocs-web-sdk/p-42aa31a9.entry.js +0 -1
  298. package/dist/verdocs-web-sdk/p-51a3ea62.system.js +0 -1
  299. package/dist/verdocs-web-sdk/p-76b73d80.entry.js +0 -1
  300. package/dist/verdocs-web-sdk/p-789dc7fe.entry.js +0 -1
  301. package/dist/verdocs-web-sdk/p-7a23c2c8.system.js +0 -1
  302. package/dist/verdocs-web-sdk/p-8027431e.js +0 -1
  303. package/dist/verdocs-web-sdk/p-807dbe83.entry.js +0 -1
  304. package/dist/verdocs-web-sdk/p-8229e6df.system.js +0 -1
  305. package/dist/verdocs-web-sdk/p-89f34463.system.entry.js +0 -1
  306. package/dist/verdocs-web-sdk/p-8c57f5d0.system.js +0 -1
  307. package/dist/verdocs-web-sdk/p-8fd812f4.system.js +0 -1
  308. package/dist/verdocs-web-sdk/p-a3931094.system.entry.js +0 -1
  309. package/dist/verdocs-web-sdk/p-a58691dc.entry.js +0 -1
  310. package/dist/verdocs-web-sdk/p-a654311c.system.entry.js +0 -1
  311. package/dist/verdocs-web-sdk/p-ab01f71e.js +0 -1
  312. package/dist/verdocs-web-sdk/p-ad11a39a.entry.js +0 -1
  313. package/dist/verdocs-web-sdk/p-c4c8af4c.system.entry.js +0 -1
  314. package/dist/verdocs-web-sdk/p-cf790f4f.js +0 -1
  315. package/dist/verdocs-web-sdk/p-d869c39c.js +0 -1
  316. package/dist/cjs/{VerdocsEndpoint-e6517a50.js → VerdocsEndpoint-f2af9468.js} +30 -30
  317. package/dist/esm/{VerdocsEndpoint-6d7a17ce.js → VerdocsEndpoint-5b92f115.js} +30 -30
@@ -1,16 +1,23 @@
1
1
  'use strict';
2
2
 
3
+ function _typeof(obj) {
4
+ "@babel/helpers - typeof";
5
+
6
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
7
+ return typeof obj;
8
+ } : function (obj) {
9
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
10
+ }, _typeof(obj);
11
+ }
12
+
3
13
  function toInteger(dirtyNumber) {
4
14
  if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {
5
15
  return NaN;
6
16
  }
7
-
8
17
  var number = Number(dirtyNumber);
9
-
10
18
  if (isNaN(number)) {
11
19
  return number;
12
20
  }
13
-
14
21
  return number < 0 ? Math.ceil(number) : Math.floor(number);
15
22
  }
16
23
 
@@ -20,7 +27,6 @@ function requiredArgs(required, args) {
20
27
  }
21
28
  }
22
29
 
23
- function _typeof$1(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$1 = function _typeof(obj) { return typeof obj; }; } else { _typeof$1 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$1(obj); }
24
30
  /**
25
31
  * @name toDate
26
32
  * @category Common Helpers
@@ -51,12 +57,12 @@ function _typeof$1(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "func
51
57
  * const result = toDate(1392098430000)
52
58
  * //=> Tue Feb 11 2014 11:30:30
53
59
  */
54
-
55
60
  function toDate(argument) {
56
61
  requiredArgs(1, arguments);
57
- var argStr = Object.prototype.toString.call(argument); // Clone the date
62
+ var argStr = Object.prototype.toString.call(argument);
58
63
 
59
- if (argument instanceof Date || _typeof$1(argument) === 'object' && argStr === '[object Date]') {
64
+ // Clone the date
65
+ if (argument instanceof Date || _typeof(argument) === 'object' && argStr === '[object Date]') {
60
66
  // Prevent the date to lose the milliseconds when passed to new Date() in IE10
61
67
  return new Date(argument.getTime());
62
68
  } else if (typeof argument === 'number' || argStr === '[object Number]') {
@@ -64,11 +70,10 @@ function toDate(argument) {
64
70
  } else {
65
71
  if ((typeof argument === 'string' || argStr === '[object String]') && typeof console !== 'undefined') {
66
72
  // eslint-disable-next-line no-console
67
- console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"); // eslint-disable-next-line no-console
68
-
73
+ console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments");
74
+ // eslint-disable-next-line no-console
69
75
  console.warn(new Error().stack);
70
76
  }
71
-
72
77
  return new Date(NaN);
73
78
  }
74
79
  }
@@ -91,7 +96,6 @@ function toDate(argument) {
91
96
  * const result = addMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750)
92
97
  * //=> Thu Jul 10 2014 12:45:30.750
93
98
  */
94
-
95
99
  function addMilliseconds(dirtyDate, dirtyAmount) {
96
100
  requiredArgs(2, arguments);
97
101
  var timestamp = toDate(dirtyDate).getTime();
@@ -121,7 +125,6 @@ function getTimezoneOffsetInMilliseconds(date) {
121
125
  return date.getTime() - utcDate.getTime();
122
126
  }
123
127
 
124
- function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
125
128
  /**
126
129
  * @name isDate
127
130
  * @category Common Helpers
@@ -154,7 +157,6 @@ function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "functi
154
157
  * const result = isDate({})
155
158
  * //=> false
156
159
  */
157
-
158
160
  function isDate(value) {
159
161
  requiredArgs(1, arguments);
160
162
  return value instanceof Date || _typeof(value) === 'object' && Object.prototype.toString.call(value) === '[object Date]';
@@ -191,14 +193,11 @@ function isDate(value) {
191
193
  * const result = isValid(new Date(''))
192
194
  * //=> false
193
195
  */
194
-
195
196
  function isValid(dirtyDate) {
196
197
  requiredArgs(1, arguments);
197
-
198
198
  if (!isDate(dirtyDate) && typeof dirtyDate !== 'number') {
199
199
  return false;
200
200
  }
201
-
202
201
  var date = toDate(dirtyDate);
203
202
  return !isNaN(Number(date));
204
203
  }
@@ -221,7 +220,6 @@ function isValid(dirtyDate) {
221
220
  * const result = subMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750)
222
221
  * //=> Thu Jul 10 2014 12:45:29.250
223
222
  */
224
-
225
223
  function subMilliseconds(dirtyDate, dirtyAmount) {
226
224
  requiredArgs(2, arguments);
227
225
  var amount = toInteger(dirtyAmount);
@@ -263,7 +261,6 @@ function getUTCISOWeekYear(dirtyDate) {
263
261
  fourthOfJanuaryOfThisYear.setUTCFullYear(year, 0, 4);
264
262
  fourthOfJanuaryOfThisYear.setUTCHours(0, 0, 0, 0);
265
263
  var startOfThisYear = startOfUTCISOWeek(fourthOfJanuaryOfThisYear);
266
-
267
264
  if (date.getTime() >= startOfNextYear.getTime()) {
268
265
  return year + 1;
269
266
  } else if (date.getTime() >= startOfThisYear.getTime()) {
@@ -287,24 +284,24 @@ var MILLISECONDS_IN_WEEK$1 = 604800000;
287
284
  function getUTCISOWeek(dirtyDate) {
288
285
  requiredArgs(1, arguments);
289
286
  var date = toDate(dirtyDate);
290
- var diff = startOfUTCISOWeek(date).getTime() - startOfUTCISOWeekYear(date).getTime(); // Round the number of days to the nearest integer
287
+ var diff = startOfUTCISOWeek(date).getTime() - startOfUTCISOWeekYear(date).getTime();
288
+
289
+ // Round the number of days to the nearest integer
291
290
  // because the number of milliseconds in a week is not constant
292
291
  // (e.g. it's different in the week of the daylight saving time clock shift)
293
-
294
292
  return Math.round(diff / MILLISECONDS_IN_WEEK$1) + 1;
295
293
  }
296
294
 
297
295
  function startOfUTCWeek(dirtyDate, options) {
298
296
  var _ref, _ref2, _ref3, _options$weekStartsOn, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
299
-
300
297
  requiredArgs(1, arguments);
301
298
  var defaultOptions = getDefaultOptions();
302
- var weekStartsOn = toInteger((_ref = (_ref2 = (_ref3 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.weekStartsOn) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.weekStartsOn) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.weekStartsOn) !== null && _ref !== void 0 ? _ref : 0); // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
299
+ var weekStartsOn = toInteger((_ref = (_ref2 = (_ref3 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.weekStartsOn) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.weekStartsOn) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.weekStartsOn) !== null && _ref !== void 0 ? _ref : 0);
303
300
 
301
+ // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
304
302
  if (!(weekStartsOn >= 0 && weekStartsOn <= 6)) {
305
303
  throw new RangeError('weekStartsOn must be between 0 and 6 inclusively');
306
304
  }
307
-
308
305
  var date = toDate(dirtyDate);
309
306
  var day = date.getUTCDay();
310
307
  var diff = (day < weekStartsOn ? 7 : 0) + day - weekStartsOn;
@@ -315,17 +312,16 @@ function startOfUTCWeek(dirtyDate, options) {
315
312
 
316
313
  function getUTCWeekYear(dirtyDate, options) {
317
314
  var _ref, _ref2, _ref3, _options$firstWeekCon, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
318
-
319
315
  requiredArgs(1, arguments);
320
316
  var date = toDate(dirtyDate);
321
317
  var year = date.getUTCFullYear();
322
318
  var defaultOptions = getDefaultOptions();
323
- var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1); // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
319
+ var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1);
324
320
 
321
+ // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
325
322
  if (!(firstWeekContainsDate >= 1 && firstWeekContainsDate <= 7)) {
326
323
  throw new RangeError('firstWeekContainsDate must be between 1 and 7 inclusively');
327
324
  }
328
-
329
325
  var firstWeekOfNextYear = new Date(0);
330
326
  firstWeekOfNextYear.setUTCFullYear(year + 1, 0, firstWeekContainsDate);
331
327
  firstWeekOfNextYear.setUTCHours(0, 0, 0, 0);
@@ -334,7 +330,6 @@ function getUTCWeekYear(dirtyDate, options) {
334
330
  firstWeekOfThisYear.setUTCFullYear(year, 0, firstWeekContainsDate);
335
331
  firstWeekOfThisYear.setUTCHours(0, 0, 0, 0);
336
332
  var startOfThisYear = startOfUTCWeek(firstWeekOfThisYear, options);
337
-
338
333
  if (date.getTime() >= startOfNextYear.getTime()) {
339
334
  return year + 1;
340
335
  } else if (date.getTime() >= startOfThisYear.getTime()) {
@@ -346,7 +341,6 @@ function getUTCWeekYear(dirtyDate, options) {
346
341
 
347
342
  function startOfUTCWeekYear(dirtyDate, options) {
348
343
  var _ref, _ref2, _ref3, _options$firstWeekCon, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
349
-
350
344
  requiredArgs(1, arguments);
351
345
  var defaultOptions = getDefaultOptions();
352
346
  var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1);
@@ -362,21 +356,20 @@ var MILLISECONDS_IN_WEEK = 604800000;
362
356
  function getUTCWeek(dirtyDate, options) {
363
357
  requiredArgs(1, arguments);
364
358
  var date = toDate(dirtyDate);
365
- var diff = startOfUTCWeek(date, options).getTime() - startOfUTCWeekYear(date, options).getTime(); // Round the number of days to the nearest integer
359
+ var diff = startOfUTCWeek(date, options).getTime() - startOfUTCWeekYear(date, options).getTime();
360
+
361
+ // Round the number of days to the nearest integer
366
362
  // because the number of milliseconds in a week is not constant
367
363
  // (e.g. it's different in the week of the daylight saving time clock shift)
368
-
369
364
  return Math.round(diff / MILLISECONDS_IN_WEEK) + 1;
370
365
  }
371
366
 
372
367
  function addLeadingZeros(number, targetLength) {
373
368
  var sign = number < 0 ? '-' : '';
374
369
  var output = Math.abs(number).toString();
375
-
376
370
  while (output.length < targetLength) {
377
371
  output = '0' + output;
378
372
  }
379
-
380
373
  return sign + output;
381
374
  }
382
375
 
@@ -392,7 +385,6 @@ function addLeadingZeros(number, targetLength) {
392
385
  *
393
386
  * Letters marked by * are not implemented but reserved by Unicode standard.
394
387
  */
395
-
396
388
  var formatters$1 = {
397
389
  // Year
398
390
  y: function y(date, token) {
@@ -404,8 +396,9 @@ var formatters$1 = {
404
396
  // | AD 123 | 123 | 23 | 123 | 0123 | 00123 |
405
397
  // | AD 1234 | 1234 | 34 | 1234 | 1234 | 01234 |
406
398
  // | AD 12345 | 12345 | 45 | 12345 | 12345 | 12345 |
407
- var signedYear = date.getUTCFullYear(); // Returns 1 for 1 BC (which is year 0 in JavaScript)
408
399
 
400
+ var signedYear = date.getUTCFullYear();
401
+ // Returns 1 for 1 BC (which is year 0 in JavaScript)
409
402
  var year = signedYear > 0 ? signedYear : 1 - signedYear;
410
403
  return addLeadingZeros(token === 'yy' ? year % 100 : year, token.length);
411
404
  },
@@ -421,18 +414,14 @@ var formatters$1 = {
421
414
  // AM or PM
422
415
  a: function a(date, token) {
423
416
  var dayPeriodEnumValue = date.getUTCHours() / 12 >= 1 ? 'pm' : 'am';
424
-
425
417
  switch (token) {
426
418
  case 'a':
427
419
  case 'aa':
428
420
  return dayPeriodEnumValue.toUpperCase();
429
-
430
421
  case 'aaa':
431
422
  return dayPeriodEnumValue;
432
-
433
423
  case 'aaaaa':
434
424
  return dayPeriodEnumValue[0];
435
-
436
425
  case 'aaaa':
437
426
  default:
438
427
  return dayPeriodEnumValue === 'am' ? 'a.m.' : 'p.m.';
@@ -473,7 +462,6 @@ var dayPeriodEnum = {
473
462
  evening: 'evening',
474
463
  night: 'night'
475
464
  };
476
-
477
465
  /*
478
466
  * | | Unit | | Unit |
479
467
  * |-----|--------------------------------|-----|--------------------------------|
@@ -519,11 +507,11 @@ var dayPeriodEnum = {
519
507
  * - `P` is long localized date format
520
508
  * - `p` is long localized time format
521
509
  */
510
+
522
511
  var formatters = {
523
512
  // Era
524
513
  G: function G(date, token, localize) {
525
514
  var era = date.getUTCFullYear() > 0 ? 1 : 0;
526
-
527
515
  switch (token) {
528
516
  // AD, BC
529
517
  case 'G':
@@ -533,13 +521,11 @@ var formatters = {
533
521
  width: 'abbreviated'
534
522
  });
535
523
  // A, B
536
-
537
524
  case 'GGGGG':
538
525
  return localize.era(era, {
539
526
  width: 'narrow'
540
527
  });
541
528
  // Anno Domini, Before Christ
542
-
543
529
  case 'GGGG':
544
530
  default:
545
531
  return localize.era(era, {
@@ -551,41 +537,42 @@ var formatters = {
551
537
  y: function y(date, token, localize) {
552
538
  // Ordinal number
553
539
  if (token === 'yo') {
554
- var signedYear = date.getUTCFullYear(); // Returns 1 for 1 BC (which is year 0 in JavaScript)
555
-
540
+ var signedYear = date.getUTCFullYear();
541
+ // Returns 1 for 1 BC (which is year 0 in JavaScript)
556
542
  var year = signedYear > 0 ? signedYear : 1 - signedYear;
557
543
  return localize.ordinalNumber(year, {
558
544
  unit: 'year'
559
545
  });
560
546
  }
561
-
562
547
  return formatters$1.y(date, token);
563
548
  },
564
549
  // Local week-numbering year
565
550
  Y: function Y(date, token, localize, options) {
566
- var signedWeekYear = getUTCWeekYear(date, options); // Returns 1 for 1 BC (which is year 0 in JavaScript)
567
-
568
- var weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear; // Two digit year
551
+ var signedWeekYear = getUTCWeekYear(date, options);
552
+ // Returns 1 for 1 BC (which is year 0 in JavaScript)
553
+ var weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear;
569
554
 
555
+ // Two digit year
570
556
  if (token === 'YY') {
571
557
  var twoDigitYear = weekYear % 100;
572
558
  return addLeadingZeros(twoDigitYear, 2);
573
- } // Ordinal number
574
-
559
+ }
575
560
 
561
+ // Ordinal number
576
562
  if (token === 'Yo') {
577
563
  return localize.ordinalNumber(weekYear, {
578
564
  unit: 'year'
579
565
  });
580
- } // Padding
581
-
566
+ }
582
567
 
568
+ // Padding
583
569
  return addLeadingZeros(weekYear, token.length);
584
570
  },
585
571
  // ISO week-numbering year
586
572
  R: function R(date, token) {
587
- var isoWeekYear = getUTCISOWeekYear(date); // Padding
573
+ var isoWeekYear = getUTCISOWeekYear(date);
588
574
 
575
+ // Padding
589
576
  return addLeadingZeros(isoWeekYear, token.length);
590
577
  },
591
578
  // Extended year. This is a single number designating the year of this calendar system.
@@ -604,37 +591,31 @@ var formatters = {
604
591
  // Quarter
605
592
  Q: function Q(date, token, localize) {
606
593
  var quarter = Math.ceil((date.getUTCMonth() + 1) / 3);
607
-
608
594
  switch (token) {
609
595
  // 1, 2, 3, 4
610
596
  case 'Q':
611
597
  return String(quarter);
612
598
  // 01, 02, 03, 04
613
-
614
599
  case 'QQ':
615
600
  return addLeadingZeros(quarter, 2);
616
601
  // 1st, 2nd, 3rd, 4th
617
-
618
602
  case 'Qo':
619
603
  return localize.ordinalNumber(quarter, {
620
604
  unit: 'quarter'
621
605
  });
622
606
  // Q1, Q2, Q3, Q4
623
-
624
607
  case 'QQQ':
625
608
  return localize.quarter(quarter, {
626
609
  width: 'abbreviated',
627
610
  context: 'formatting'
628
611
  });
629
612
  // 1, 2, 3, 4 (narrow quarter; could be not numerical)
630
-
631
613
  case 'QQQQQ':
632
614
  return localize.quarter(quarter, {
633
615
  width: 'narrow',
634
616
  context: 'formatting'
635
617
  });
636
618
  // 1st quarter, 2nd quarter, ...
637
-
638
619
  case 'QQQQ':
639
620
  default:
640
621
  return localize.quarter(quarter, {
@@ -646,37 +627,31 @@ var formatters = {
646
627
  // Stand-alone quarter
647
628
  q: function q(date, token, localize) {
648
629
  var quarter = Math.ceil((date.getUTCMonth() + 1) / 3);
649
-
650
630
  switch (token) {
651
631
  // 1, 2, 3, 4
652
632
  case 'q':
653
633
  return String(quarter);
654
634
  // 01, 02, 03, 04
655
-
656
635
  case 'qq':
657
636
  return addLeadingZeros(quarter, 2);
658
637
  // 1st, 2nd, 3rd, 4th
659
-
660
638
  case 'qo':
661
639
  return localize.ordinalNumber(quarter, {
662
640
  unit: 'quarter'
663
641
  });
664
642
  // Q1, Q2, Q3, Q4
665
-
666
643
  case 'qqq':
667
644
  return localize.quarter(quarter, {
668
645
  width: 'abbreviated',
669
646
  context: 'standalone'
670
647
  });
671
648
  // 1, 2, 3, 4 (narrow quarter; could be not numerical)
672
-
673
649
  case 'qqqqq':
674
650
  return localize.quarter(quarter, {
675
651
  width: 'narrow',
676
652
  context: 'standalone'
677
653
  });
678
654
  // 1st quarter, 2nd quarter, ...
679
-
680
655
  case 'qqqq':
681
656
  default:
682
657
  return localize.quarter(quarter, {
@@ -688,33 +663,28 @@ var formatters = {
688
663
  // Month
689
664
  M: function M(date, token, localize) {
690
665
  var month = date.getUTCMonth();
691
-
692
666
  switch (token) {
693
667
  case 'M':
694
668
  case 'MM':
695
669
  return formatters$1.M(date, token);
696
670
  // 1st, 2nd, ..., 12th
697
-
698
671
  case 'Mo':
699
672
  return localize.ordinalNumber(month + 1, {
700
673
  unit: 'month'
701
674
  });
702
675
  // Jan, Feb, ..., Dec
703
-
704
676
  case 'MMM':
705
677
  return localize.month(month, {
706
678
  width: 'abbreviated',
707
679
  context: 'formatting'
708
680
  });
709
681
  // J, F, ..., D
710
-
711
682
  case 'MMMMM':
712
683
  return localize.month(month, {
713
684
  width: 'narrow',
714
685
  context: 'formatting'
715
686
  });
716
687
  // January, February, ..., December
717
-
718
688
  case 'MMMM':
719
689
  default:
720
690
  return localize.month(month, {
@@ -726,37 +696,31 @@ var formatters = {
726
696
  // Stand-alone month
727
697
  L: function L(date, token, localize) {
728
698
  var month = date.getUTCMonth();
729
-
730
699
  switch (token) {
731
700
  // 1, 2, ..., 12
732
701
  case 'L':
733
702
  return String(month + 1);
734
703
  // 01, 02, ..., 12
735
-
736
704
  case 'LL':
737
705
  return addLeadingZeros(month + 1, 2);
738
706
  // 1st, 2nd, ..., 12th
739
-
740
707
  case 'Lo':
741
708
  return localize.ordinalNumber(month + 1, {
742
709
  unit: 'month'
743
710
  });
744
711
  // Jan, Feb, ..., Dec
745
-
746
712
  case 'LLL':
747
713
  return localize.month(month, {
748
714
  width: 'abbreviated',
749
715
  context: 'standalone'
750
716
  });
751
717
  // J, F, ..., D
752
-
753
718
  case 'LLLLL':
754
719
  return localize.month(month, {
755
720
  width: 'narrow',
756
721
  context: 'standalone'
757
722
  });
758
723
  // January, February, ..., December
759
-
760
724
  case 'LLLL':
761
725
  default:
762
726
  return localize.month(month, {
@@ -768,25 +732,21 @@ var formatters = {
768
732
  // Local week of year
769
733
  w: function w(date, token, localize, options) {
770
734
  var week = getUTCWeek(date, options);
771
-
772
735
  if (token === 'wo') {
773
736
  return localize.ordinalNumber(week, {
774
737
  unit: 'week'
775
738
  });
776
739
  }
777
-
778
740
  return addLeadingZeros(week, token.length);
779
741
  },
780
742
  // ISO week of year
781
743
  I: function I(date, token, localize) {
782
744
  var isoWeek = getUTCISOWeek(date);
783
-
784
745
  if (token === 'Io') {
785
746
  return localize.ordinalNumber(isoWeek, {
786
747
  unit: 'week'
787
748
  });
788
749
  }
789
-
790
750
  return addLeadingZeros(isoWeek, token.length);
791
751
  },
792
752
  // Day of the month
@@ -796,25 +756,21 @@ var formatters = {
796
756
  unit: 'date'
797
757
  });
798
758
  }
799
-
800
759
  return formatters$1.d(date, token);
801
760
  },
802
761
  // Day of year
803
762
  D: function D(date, token, localize) {
804
763
  var dayOfYear = getUTCDayOfYear(date);
805
-
806
764
  if (token === 'Do') {
807
765
  return localize.ordinalNumber(dayOfYear, {
808
766
  unit: 'dayOfYear'
809
767
  });
810
768
  }
811
-
812
769
  return addLeadingZeros(dayOfYear, token.length);
813
770
  },
814
771
  // Day of week
815
772
  E: function E(date, token, localize) {
816
773
  var dayOfWeek = date.getUTCDay();
817
-
818
774
  switch (token) {
819
775
  // Tue
820
776
  case 'E':
@@ -825,21 +781,18 @@ var formatters = {
825
781
  context: 'formatting'
826
782
  });
827
783
  // T
828
-
829
784
  case 'EEEEE':
830
785
  return localize.day(dayOfWeek, {
831
786
  width: 'narrow',
832
787
  context: 'formatting'
833
788
  });
834
789
  // Tu
835
-
836
790
  case 'EEEEEE':
837
791
  return localize.day(dayOfWeek, {
838
792
  width: 'short',
839
793
  context: 'formatting'
840
794
  });
841
795
  // Tuesday
842
-
843
796
  case 'EEEE':
844
797
  default:
845
798
  return localize.day(dayOfWeek, {
@@ -852,43 +805,36 @@ var formatters = {
852
805
  e: function e(date, token, localize, options) {
853
806
  var dayOfWeek = date.getUTCDay();
854
807
  var localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
855
-
856
808
  switch (token) {
857
809
  // Numerical value (Nth day of week with current locale or weekStartsOn)
858
810
  case 'e':
859
811
  return String(localDayOfWeek);
860
812
  // Padded numerical value
861
-
862
813
  case 'ee':
863
814
  return addLeadingZeros(localDayOfWeek, 2);
864
815
  // 1st, 2nd, ..., 7th
865
-
866
816
  case 'eo':
867
817
  return localize.ordinalNumber(localDayOfWeek, {
868
818
  unit: 'day'
869
819
  });
870
-
871
820
  case 'eee':
872
821
  return localize.day(dayOfWeek, {
873
822
  width: 'abbreviated',
874
823
  context: 'formatting'
875
824
  });
876
825
  // T
877
-
878
826
  case 'eeeee':
879
827
  return localize.day(dayOfWeek, {
880
828
  width: 'narrow',
881
829
  context: 'formatting'
882
830
  });
883
831
  // Tu
884
-
885
832
  case 'eeeeee':
886
833
  return localize.day(dayOfWeek, {
887
834
  width: 'short',
888
835
  context: 'formatting'
889
836
  });
890
837
  // Tuesday
891
-
892
838
  case 'eeee':
893
839
  default:
894
840
  return localize.day(dayOfWeek, {
@@ -901,43 +847,36 @@ var formatters = {
901
847
  c: function c(date, token, localize, options) {
902
848
  var dayOfWeek = date.getUTCDay();
903
849
  var localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
904
-
905
850
  switch (token) {
906
851
  // Numerical value (same as in `e`)
907
852
  case 'c':
908
853
  return String(localDayOfWeek);
909
854
  // Padded numerical value
910
-
911
855
  case 'cc':
912
856
  return addLeadingZeros(localDayOfWeek, token.length);
913
857
  // 1st, 2nd, ..., 7th
914
-
915
858
  case 'co':
916
859
  return localize.ordinalNumber(localDayOfWeek, {
917
860
  unit: 'day'
918
861
  });
919
-
920
862
  case 'ccc':
921
863
  return localize.day(dayOfWeek, {
922
864
  width: 'abbreviated',
923
865
  context: 'standalone'
924
866
  });
925
867
  // T
926
-
927
868
  case 'ccccc':
928
869
  return localize.day(dayOfWeek, {
929
870
  width: 'narrow',
930
871
  context: 'standalone'
931
872
  });
932
873
  // Tu
933
-
934
874
  case 'cccccc':
935
875
  return localize.day(dayOfWeek, {
936
876
  width: 'short',
937
877
  context: 'standalone'
938
878
  });
939
879
  // Tuesday
940
-
941
880
  case 'cccc':
942
881
  default:
943
882
  return localize.day(dayOfWeek, {
@@ -950,44 +889,37 @@ var formatters = {
950
889
  i: function i(date, token, localize) {
951
890
  var dayOfWeek = date.getUTCDay();
952
891
  var isoDayOfWeek = dayOfWeek === 0 ? 7 : dayOfWeek;
953
-
954
892
  switch (token) {
955
893
  // 2
956
894
  case 'i':
957
895
  return String(isoDayOfWeek);
958
896
  // 02
959
-
960
897
  case 'ii':
961
898
  return addLeadingZeros(isoDayOfWeek, token.length);
962
899
  // 2nd
963
-
964
900
  case 'io':
965
901
  return localize.ordinalNumber(isoDayOfWeek, {
966
902
  unit: 'day'
967
903
  });
968
904
  // Tue
969
-
970
905
  case 'iii':
971
906
  return localize.day(dayOfWeek, {
972
907
  width: 'abbreviated',
973
908
  context: 'formatting'
974
909
  });
975
910
  // T
976
-
977
911
  case 'iiiii':
978
912
  return localize.day(dayOfWeek, {
979
913
  width: 'narrow',
980
914
  context: 'formatting'
981
915
  });
982
916
  // Tu
983
-
984
917
  case 'iiiiii':
985
918
  return localize.day(dayOfWeek, {
986
919
  width: 'short',
987
920
  context: 'formatting'
988
921
  });
989
922
  // Tuesday
990
-
991
923
  case 'iiii':
992
924
  default:
993
925
  return localize.day(dayOfWeek, {
@@ -1000,7 +932,6 @@ var formatters = {
1000
932
  a: function a(date, token, localize) {
1001
933
  var hours = date.getUTCHours();
1002
934
  var dayPeriodEnumValue = hours / 12 >= 1 ? 'pm' : 'am';
1003
-
1004
935
  switch (token) {
1005
936
  case 'a':
1006
937
  case 'aa':
@@ -1008,19 +939,16 @@ var formatters = {
1008
939
  width: 'abbreviated',
1009
940
  context: 'formatting'
1010
941
  });
1011
-
1012
942
  case 'aaa':
1013
943
  return localize.dayPeriod(dayPeriodEnumValue, {
1014
944
  width: 'abbreviated',
1015
945
  context: 'formatting'
1016
946
  }).toLowerCase();
1017
-
1018
947
  case 'aaaaa':
1019
948
  return localize.dayPeriod(dayPeriodEnumValue, {
1020
949
  width: 'narrow',
1021
950
  context: 'formatting'
1022
951
  });
1023
-
1024
952
  case 'aaaa':
1025
953
  default:
1026
954
  return localize.dayPeriod(dayPeriodEnumValue, {
@@ -1033,7 +961,6 @@ var formatters = {
1033
961
  b: function b(date, token, localize) {
1034
962
  var hours = date.getUTCHours();
1035
963
  var dayPeriodEnumValue;
1036
-
1037
964
  if (hours === 12) {
1038
965
  dayPeriodEnumValue = dayPeriodEnum.noon;
1039
966
  } else if (hours === 0) {
@@ -1041,7 +968,6 @@ var formatters = {
1041
968
  } else {
1042
969
  dayPeriodEnumValue = hours / 12 >= 1 ? 'pm' : 'am';
1043
970
  }
1044
-
1045
971
  switch (token) {
1046
972
  case 'b':
1047
973
  case 'bb':
@@ -1049,19 +975,16 @@ var formatters = {
1049
975
  width: 'abbreviated',
1050
976
  context: 'formatting'
1051
977
  });
1052
-
1053
978
  case 'bbb':
1054
979
  return localize.dayPeriod(dayPeriodEnumValue, {
1055
980
  width: 'abbreviated',
1056
981
  context: 'formatting'
1057
982
  }).toLowerCase();
1058
-
1059
983
  case 'bbbbb':
1060
984
  return localize.dayPeriod(dayPeriodEnumValue, {
1061
985
  width: 'narrow',
1062
986
  context: 'formatting'
1063
987
  });
1064
-
1065
988
  case 'bbbb':
1066
989
  default:
1067
990
  return localize.dayPeriod(dayPeriodEnumValue, {
@@ -1074,7 +997,6 @@ var formatters = {
1074
997
  B: function B(date, token, localize) {
1075
998
  var hours = date.getUTCHours();
1076
999
  var dayPeriodEnumValue;
1077
-
1078
1000
  if (hours >= 17) {
1079
1001
  dayPeriodEnumValue = dayPeriodEnum.evening;
1080
1002
  } else if (hours >= 12) {
@@ -1084,7 +1006,6 @@ var formatters = {
1084
1006
  } else {
1085
1007
  dayPeriodEnumValue = dayPeriodEnum.night;
1086
1008
  }
1087
-
1088
1009
  switch (token) {
1089
1010
  case 'B':
1090
1011
  case 'BB':
@@ -1093,13 +1014,11 @@ var formatters = {
1093
1014
  width: 'abbreviated',
1094
1015
  context: 'formatting'
1095
1016
  });
1096
-
1097
1017
  case 'BBBBB':
1098
1018
  return localize.dayPeriod(dayPeriodEnumValue, {
1099
1019
  width: 'narrow',
1100
1020
  context: 'formatting'
1101
1021
  });
1102
-
1103
1022
  case 'BBBB':
1104
1023
  default:
1105
1024
  return localize.dayPeriod(dayPeriodEnumValue, {
@@ -1117,7 +1036,6 @@ var formatters = {
1117
1036
  unit: 'hour'
1118
1037
  });
1119
1038
  }
1120
-
1121
1039
  return formatters$1.h(date, token);
1122
1040
  },
1123
1041
  // Hour [0-23]
@@ -1127,32 +1045,27 @@ var formatters = {
1127
1045
  unit: 'hour'
1128
1046
  });
1129
1047
  }
1130
-
1131
1048
  return formatters$1.H(date, token);
1132
1049
  },
1133
1050
  // Hour [0-11]
1134
1051
  K: function K(date, token, localize) {
1135
1052
  var hours = date.getUTCHours() % 12;
1136
-
1137
1053
  if (token === 'Ko') {
1138
1054
  return localize.ordinalNumber(hours, {
1139
1055
  unit: 'hour'
1140
1056
  });
1141
1057
  }
1142
-
1143
1058
  return addLeadingZeros(hours, token.length);
1144
1059
  },
1145
1060
  // Hour [1-24]
1146
1061
  k: function k(date, token, localize) {
1147
1062
  var hours = date.getUTCHours();
1148
1063
  if (hours === 0) hours = 24;
1149
-
1150
1064
  if (token === 'ko') {
1151
1065
  return localize.ordinalNumber(hours, {
1152
1066
  unit: 'hour'
1153
1067
  });
1154
1068
  }
1155
-
1156
1069
  return addLeadingZeros(hours, token.length);
1157
1070
  },
1158
1071
  // Minute
@@ -1162,7 +1075,6 @@ var formatters = {
1162
1075
  unit: 'minute'
1163
1076
  });
1164
1077
  }
1165
-
1166
1078
  return formatters$1.m(date, token);
1167
1079
  },
1168
1080
  // Second
@@ -1172,7 +1084,6 @@ var formatters = {
1172
1084
  unit: 'second'
1173
1085
  });
1174
1086
  }
1175
-
1176
1087
  return formatters$1.s(date, token);
1177
1088
  },
1178
1089
  // Fraction of second
@@ -1183,30 +1094,27 @@ var formatters = {
1183
1094
  X: function X(date, token, _localize, options) {
1184
1095
  var originalDate = options._originalDate || date;
1185
1096
  var timezoneOffset = originalDate.getTimezoneOffset();
1186
-
1187
1097
  if (timezoneOffset === 0) {
1188
1098
  return 'Z';
1189
1099
  }
1190
-
1191
1100
  switch (token) {
1192
1101
  // Hours and optional minutes
1193
1102
  case 'X':
1194
1103
  return formatTimezoneWithOptionalMinutes(timezoneOffset);
1104
+
1195
1105
  // Hours, minutes and optional seconds without `:` delimiter
1196
1106
  // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
1197
1107
  // so this token always has the same output as `XX`
1198
-
1199
1108
  case 'XXXX':
1200
1109
  case 'XX':
1201
1110
  // Hours and minutes without `:` delimiter
1202
1111
  return formatTimezone(timezoneOffset);
1112
+
1203
1113
  // Hours, minutes and optional seconds with `:` delimiter
1204
1114
  // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
1205
1115
  // so this token always has the same output as `XXX`
1206
-
1207
1116
  case 'XXXXX':
1208
1117
  case 'XXX': // Hours and minutes with `:` delimiter
1209
-
1210
1118
  default:
1211
1119
  return formatTimezone(timezoneOffset, ':');
1212
1120
  }
@@ -1215,26 +1123,24 @@ var formatters = {
1215
1123
  x: function x(date, token, _localize, options) {
1216
1124
  var originalDate = options._originalDate || date;
1217
1125
  var timezoneOffset = originalDate.getTimezoneOffset();
1218
-
1219
1126
  switch (token) {
1220
1127
  // Hours and optional minutes
1221
1128
  case 'x':
1222
1129
  return formatTimezoneWithOptionalMinutes(timezoneOffset);
1130
+
1223
1131
  // Hours, minutes and optional seconds without `:` delimiter
1224
1132
  // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
1225
1133
  // so this token always has the same output as `xx`
1226
-
1227
1134
  case 'xxxx':
1228
1135
  case 'xx':
1229
1136
  // Hours and minutes without `:` delimiter
1230
1137
  return formatTimezone(timezoneOffset);
1138
+
1231
1139
  // Hours, minutes and optional seconds with `:` delimiter
1232
1140
  // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
1233
1141
  // so this token always has the same output as `xxx`
1234
-
1235
1142
  case 'xxxxx':
1236
1143
  case 'xxx': // Hours and minutes with `:` delimiter
1237
-
1238
1144
  default:
1239
1145
  return formatTimezone(timezoneOffset, ':');
1240
1146
  }
@@ -1243,7 +1149,6 @@ var formatters = {
1243
1149
  O: function O(date, token, _localize, options) {
1244
1150
  var originalDate = options._originalDate || date;
1245
1151
  var timezoneOffset = originalDate.getTimezoneOffset();
1246
-
1247
1152
  switch (token) {
1248
1153
  // Short
1249
1154
  case 'O':
@@ -1251,7 +1156,6 @@ var formatters = {
1251
1156
  case 'OOO':
1252
1157
  return 'GMT' + formatTimezoneShort(timezoneOffset, ':');
1253
1158
  // Long
1254
-
1255
1159
  case 'OOOO':
1256
1160
  default:
1257
1161
  return 'GMT' + formatTimezone(timezoneOffset, ':');
@@ -1261,7 +1165,6 @@ var formatters = {
1261
1165
  z: function z(date, token, _localize, options) {
1262
1166
  var originalDate = options._originalDate || date;
1263
1167
  var timezoneOffset = originalDate.getTimezoneOffset();
1264
-
1265
1168
  switch (token) {
1266
1169
  // Short
1267
1170
  case 'z':
@@ -1269,7 +1172,6 @@ var formatters = {
1269
1172
  case 'zzz':
1270
1173
  return 'GMT' + formatTimezoneShort(timezoneOffset, ':');
1271
1174
  // Long
1272
-
1273
1175
  case 'zzzz':
1274
1176
  default:
1275
1177
  return 'GMT' + formatTimezone(timezoneOffset, ':');
@@ -1288,30 +1190,24 @@ var formatters = {
1288
1190
  return addLeadingZeros(timestamp, token.length);
1289
1191
  }
1290
1192
  };
1291
-
1292
1193
  function formatTimezoneShort(offset, dirtyDelimiter) {
1293
1194
  var sign = offset > 0 ? '-' : '+';
1294
1195
  var absOffset = Math.abs(offset);
1295
1196
  var hours = Math.floor(absOffset / 60);
1296
1197
  var minutes = absOffset % 60;
1297
-
1298
1198
  if (minutes === 0) {
1299
1199
  return sign + String(hours);
1300
1200
  }
1301
-
1302
1201
  var delimiter = dirtyDelimiter || '';
1303
1202
  return sign + String(hours) + delimiter + addLeadingZeros(minutes, 2);
1304
1203
  }
1305
-
1306
1204
  function formatTimezoneWithOptionalMinutes(offset, dirtyDelimiter) {
1307
1205
  if (offset % 60 === 0) {
1308
1206
  var sign = offset > 0 ? '-' : '+';
1309
1207
  return sign + addLeadingZeros(Math.abs(offset) / 60, 2);
1310
1208
  }
1311
-
1312
1209
  return formatTimezone(offset, dirtyDelimiter);
1313
1210
  }
1314
-
1315
1211
  function formatTimezone(offset, dirtyDelimiter) {
1316
1212
  var delimiter = dirtyDelimiter || '';
1317
1213
  var sign = offset > 0 ? '-' : '+';
@@ -1327,17 +1223,14 @@ var dateLongFormatter = function dateLongFormatter(pattern, formatLong) {
1327
1223
  return formatLong.date({
1328
1224
  width: 'short'
1329
1225
  });
1330
-
1331
1226
  case 'PP':
1332
1227
  return formatLong.date({
1333
1228
  width: 'medium'
1334
1229
  });
1335
-
1336
1230
  case 'PPP':
1337
1231
  return formatLong.date({
1338
1232
  width: 'long'
1339
1233
  });
1340
-
1341
1234
  case 'PPPP':
1342
1235
  default:
1343
1236
  return formatLong.date({
@@ -1345,24 +1238,20 @@ var dateLongFormatter = function dateLongFormatter(pattern, formatLong) {
1345
1238
  });
1346
1239
  }
1347
1240
  };
1348
-
1349
1241
  var timeLongFormatter = function timeLongFormatter(pattern, formatLong) {
1350
1242
  switch (pattern) {
1351
1243
  case 'p':
1352
1244
  return formatLong.time({
1353
1245
  width: 'short'
1354
1246
  });
1355
-
1356
1247
  case 'pp':
1357
1248
  return formatLong.time({
1358
1249
  width: 'medium'
1359
1250
  });
1360
-
1361
1251
  case 'ppp':
1362
1252
  return formatLong.time({
1363
1253
  width: 'long'
1364
1254
  });
1365
-
1366
1255
  case 'pppp':
1367
1256
  default:
1368
1257
  return formatLong.time({
@@ -1370,37 +1259,30 @@ var timeLongFormatter = function timeLongFormatter(pattern, formatLong) {
1370
1259
  });
1371
1260
  }
1372
1261
  };
1373
-
1374
1262
  var dateTimeLongFormatter = function dateTimeLongFormatter(pattern, formatLong) {
1375
1263
  var matchResult = pattern.match(/(P+)(p+)?/) || [];
1376
1264
  var datePattern = matchResult[1];
1377
1265
  var timePattern = matchResult[2];
1378
-
1379
1266
  if (!timePattern) {
1380
1267
  return dateLongFormatter(pattern, formatLong);
1381
1268
  }
1382
-
1383
1269
  var dateTimeFormat;
1384
-
1385
1270
  switch (datePattern) {
1386
1271
  case 'P':
1387
1272
  dateTimeFormat = formatLong.dateTime({
1388
1273
  width: 'short'
1389
1274
  });
1390
1275
  break;
1391
-
1392
1276
  case 'PP':
1393
1277
  dateTimeFormat = formatLong.dateTime({
1394
1278
  width: 'medium'
1395
1279
  });
1396
1280
  break;
1397
-
1398
1281
  case 'PPP':
1399
1282
  dateTimeFormat = formatLong.dateTime({
1400
1283
  width: 'long'
1401
1284
  });
1402
1285
  break;
1403
-
1404
1286
  case 'PPPP':
1405
1287
  default:
1406
1288
  dateTimeFormat = formatLong.dateTime({
@@ -1408,10 +1290,8 @@ var dateTimeLongFormatter = function dateTimeLongFormatter(pattern, formatLong)
1408
1290
  });
1409
1291
  break;
1410
1292
  }
1411
-
1412
1293
  return dateTimeFormat.replace('{{date}}', dateLongFormatter(datePattern, formatLong)).replace('{{time}}', timeLongFormatter(timePattern, formatLong));
1413
1294
  };
1414
-
1415
1295
  var longFormatters = {
1416
1296
  p: timeLongFormatter,
1417
1297
  P: dateTimeLongFormatter
@@ -1500,11 +1380,9 @@ var formatDistanceLocale = {
1500
1380
  other: 'almost {{count}} years'
1501
1381
  }
1502
1382
  };
1503
-
1504
1383
  var formatDistance = function formatDistance(token, count, options) {
1505
1384
  var result;
1506
1385
  var tokenValue = formatDistanceLocale[token];
1507
-
1508
1386
  if (typeof tokenValue === 'string') {
1509
1387
  result = tokenValue;
1510
1388
  } else if (count === 1) {
@@ -1512,7 +1390,6 @@ var formatDistance = function formatDistance(token, count, options) {
1512
1390
  } else {
1513
1391
  result = tokenValue.other.replace('{{count}}', count.toString());
1514
1392
  }
1515
-
1516
1393
  if (options !== null && options !== void 0 && options.addSuffix) {
1517
1394
  if (options.comparison && options.comparison > 0) {
1518
1395
  return 'in ' + result;
@@ -1520,7 +1397,6 @@ var formatDistance = function formatDistance(token, count, options) {
1520
1397
  return result + ' ago';
1521
1398
  }
1522
1399
  }
1523
-
1524
1400
  return result;
1525
1401
  };
1526
1402
 
@@ -1575,7 +1451,6 @@ var formatRelativeLocale = {
1575
1451
  nextWeek: "eeee 'at' p",
1576
1452
  other: 'P'
1577
1453
  };
1578
-
1579
1454
  var formatRelative = function formatRelative(token, _date, _baseDate, _options) {
1580
1455
  return formatRelativeLocale[token];
1581
1456
  };
@@ -1584,21 +1459,17 @@ function buildLocalizeFn(args) {
1584
1459
  return function (dirtyIndex, options) {
1585
1460
  var context = options !== null && options !== void 0 && options.context ? String(options.context) : 'standalone';
1586
1461
  var valuesArray;
1587
-
1588
1462
  if (context === 'formatting' && args.formattingValues) {
1589
1463
  var defaultWidth = args.defaultFormattingWidth || args.defaultWidth;
1590
1464
  var width = options !== null && options !== void 0 && options.width ? String(options.width) : defaultWidth;
1591
1465
  valuesArray = args.formattingValues[width] || args.formattingValues[defaultWidth];
1592
1466
  } else {
1593
1467
  var _defaultWidth = args.defaultWidth;
1594
-
1595
1468
  var _width = options !== null && options !== void 0 && options.width ? String(options.width) : args.defaultWidth;
1596
-
1597
1469
  valuesArray = args.values[_width] || args.values[_defaultWidth];
1598
1470
  }
1599
-
1600
- var index = args.argumentCallback ? args.argumentCallback(dirtyIndex) : dirtyIndex; // @ts-ignore: For some reason TypeScript just don't want to match it, no matter how hard we try. I challenge you to try to remove it!
1601
-
1471
+ var index = args.argumentCallback ? args.argumentCallback(dirtyIndex) : dirtyIndex;
1472
+ // @ts-ignore: For some reason TypeScript just don't want to match it, no matter how hard we try. I challenge you to try to remove it!
1602
1473
  return valuesArray[index];
1603
1474
  };
1604
1475
  }
@@ -1612,11 +1483,12 @@ var quarterValues = {
1612
1483
  narrow: ['1', '2', '3', '4'],
1613
1484
  abbreviated: ['Q1', 'Q2', 'Q3', 'Q4'],
1614
1485
  wide: ['1st quarter', '2nd quarter', '3rd quarter', '4th quarter']
1615
- }; // Note: in English, the names of days of the week and months are capitalized.
1486
+ };
1487
+
1488
+ // Note: in English, the names of days of the week and months are capitalized.
1616
1489
  // If you are making a new locale based on this one, check if the same is true for the language you're working on.
1617
1490
  // Generally, formatted dates should look like they are in the middle of a sentence,
1618
1491
  // e.g. in Spanish language the weekdays and months should be in the lowercase.
1619
-
1620
1492
  var monthValues = {
1621
1493
  narrow: ['J', 'F', 'M', 'A', 'M', 'J', 'J', 'A', 'S', 'O', 'N', 'D'],
1622
1494
  abbreviated: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
@@ -1692,9 +1564,10 @@ var formattingDayPeriodValues = {
1692
1564
  night: 'at night'
1693
1565
  }
1694
1566
  };
1695
-
1696
1567
  var ordinalNumber = function ordinalNumber(dirtyNumber, _options) {
1697
- var number = Number(dirtyNumber); // If ordinal numbers depend on context, for example,
1568
+ var number = Number(dirtyNumber);
1569
+
1570
+ // If ordinal numbers depend on context, for example,
1698
1571
  // if they are different for different grammatical genders,
1699
1572
  // use `options.unit`.
1700
1573
  //
@@ -1702,23 +1575,18 @@ var ordinalNumber = function ordinalNumber(dirtyNumber, _options) {
1702
1575
  // 'day', 'hour', 'minute', 'second'.
1703
1576
 
1704
1577
  var rem100 = number % 100;
1705
-
1706
1578
  if (rem100 > 20 || rem100 < 10) {
1707
1579
  switch (rem100 % 10) {
1708
1580
  case 1:
1709
1581
  return number + 'st';
1710
-
1711
1582
  case 2:
1712
1583
  return number + 'nd';
1713
-
1714
1584
  case 3:
1715
1585
  return number + 'rd';
1716
1586
  }
1717
1587
  }
1718
-
1719
1588
  return number + 'th';
1720
1589
  };
1721
-
1722
1590
  var localize = {
1723
1591
  ordinalNumber: ordinalNumber,
1724
1592
  era: buildLocalizeFn({
@@ -1754,11 +1622,9 @@ function buildMatchFn(args) {
1754
1622
  var width = options.width;
1755
1623
  var matchPattern = width && args.matchPatterns[width] || args.matchPatterns[args.defaultMatchWidth];
1756
1624
  var matchResult = string.match(matchPattern);
1757
-
1758
1625
  if (!matchResult) {
1759
1626
  return null;
1760
1627
  }
1761
-
1762
1628
  var matchedString = matchResult[0];
1763
1629
  var parsePatterns = width && args.parsePatterns[width] || args.parsePatterns[args.defaultParseWidth];
1764
1630
  var key = Array.isArray(parsePatterns) ? findIndex(parsePatterns, function (pattern) {
@@ -1776,24 +1642,20 @@ function buildMatchFn(args) {
1776
1642
  };
1777
1643
  };
1778
1644
  }
1779
-
1780
1645
  function findKey(object, predicate) {
1781
1646
  for (var key in object) {
1782
1647
  if (object.hasOwnProperty(key) && predicate(object[key])) {
1783
1648
  return key;
1784
1649
  }
1785
1650
  }
1786
-
1787
1651
  return undefined;
1788
1652
  }
1789
-
1790
1653
  function findIndex(array, predicate) {
1791
1654
  for (var key = 0; key < array.length; key++) {
1792
1655
  if (predicate(array[key])) {
1793
1656
  return key;
1794
1657
  }
1795
1658
  }
1796
-
1797
1659
  return undefined;
1798
1660
  }
1799
1661
 
@@ -1928,9 +1790,7 @@ var locale = {
1928
1790
  localize: localize,
1929
1791
  match: match,
1930
1792
  options: {
1931
- weekStartsOn: 0
1932
- /* Sunday */
1933
- ,
1793
+ weekStartsOn: 0 /* Sunday */,
1934
1794
  firstWeekContainsDate: 1
1935
1795
  }
1936
1796
  };
@@ -1945,14 +1805,15 @@ var locale = {
1945
1805
  // If there is no matching single quote
1946
1806
  // then the sequence will continue until the end of the string.
1947
1807
  // - . matches any single character unmatched by previous parts of the RegExps
1808
+ var formattingTokensRegExp = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g;
1948
1809
 
1949
- var formattingTokensRegExp = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g; // This RegExp catches symbols escaped by quotes, and also
1810
+ // This RegExp catches symbols escaped by quotes, and also
1950
1811
  // sequences of symbols P, p, and the combinations like `PPPPPPPppppp`
1951
-
1952
1812
  var longFormattingTokensRegExp = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g;
1953
1813
  var escapedStringRegExp = /^'([^]*?)'?$/;
1954
1814
  var doubleQuoteRegExp = /''/g;
1955
1815
  var unescapedLatinCharacterRegExp = /[a-zA-Z]/;
1816
+
1956
1817
  /**
1957
1818
  * @name format
1958
1819
  * @category Common Helpers
@@ -2247,40 +2108,36 @@ var unescapedLatinCharacterRegExp = /[a-zA-Z]/;
2247
2108
 
2248
2109
  function format(dirtyDate, dirtyFormatStr, options) {
2249
2110
  var _ref, _options$locale, _ref2, _ref3, _ref4, _options$firstWeekCon, _options$locale2, _options$locale2$opti, _defaultOptions$local, _defaultOptions$local2, _ref5, _ref6, _ref7, _options$weekStartsOn, _options$locale3, _options$locale3$opti, _defaultOptions$local3, _defaultOptions$local4;
2250
-
2251
2111
  requiredArgs(2, arguments);
2252
2112
  var formatStr = String(dirtyFormatStr);
2253
2113
  var defaultOptions = getDefaultOptions();
2254
2114
  var locale$1 = (_ref = (_options$locale = options === null || options === void 0 ? void 0 : options.locale) !== null && _options$locale !== void 0 ? _options$locale : defaultOptions.locale) !== null && _ref !== void 0 ? _ref : locale;
2255
- var firstWeekContainsDate = toInteger((_ref2 = (_ref3 = (_ref4 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale2 = options.locale) === null || _options$locale2 === void 0 ? void 0 : (_options$locale2$opti = _options$locale2.options) === null || _options$locale2$opti === void 0 ? void 0 : _options$locale2$opti.firstWeekContainsDate) !== null && _ref4 !== void 0 ? _ref4 : defaultOptions.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : 1); // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
2115
+ var firstWeekContainsDate = toInteger((_ref2 = (_ref3 = (_ref4 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale2 = options.locale) === null || _options$locale2 === void 0 ? void 0 : (_options$locale2$opti = _options$locale2.options) === null || _options$locale2$opti === void 0 ? void 0 : _options$locale2$opti.firstWeekContainsDate) !== null && _ref4 !== void 0 ? _ref4 : defaultOptions.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : 1);
2256
2116
 
2117
+ // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
2257
2118
  if (!(firstWeekContainsDate >= 1 && firstWeekContainsDate <= 7)) {
2258
2119
  throw new RangeError('firstWeekContainsDate must be between 1 and 7 inclusively');
2259
2120
  }
2121
+ var weekStartsOn = toInteger((_ref5 = (_ref6 = (_ref7 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale3 = options.locale) === null || _options$locale3 === void 0 ? void 0 : (_options$locale3$opti = _options$locale3.options) === null || _options$locale3$opti === void 0 ? void 0 : _options$locale3$opti.weekStartsOn) !== null && _ref7 !== void 0 ? _ref7 : defaultOptions.weekStartsOn) !== null && _ref6 !== void 0 ? _ref6 : (_defaultOptions$local3 = defaultOptions.locale) === null || _defaultOptions$local3 === void 0 ? void 0 : (_defaultOptions$local4 = _defaultOptions$local3.options) === null || _defaultOptions$local4 === void 0 ? void 0 : _defaultOptions$local4.weekStartsOn) !== null && _ref5 !== void 0 ? _ref5 : 0);
2260
2122
 
2261
- var weekStartsOn = toInteger((_ref5 = (_ref6 = (_ref7 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale3 = options.locale) === null || _options$locale3 === void 0 ? void 0 : (_options$locale3$opti = _options$locale3.options) === null || _options$locale3$opti === void 0 ? void 0 : _options$locale3$opti.weekStartsOn) !== null && _ref7 !== void 0 ? _ref7 : defaultOptions.weekStartsOn) !== null && _ref6 !== void 0 ? _ref6 : (_defaultOptions$local3 = defaultOptions.locale) === null || _defaultOptions$local3 === void 0 ? void 0 : (_defaultOptions$local4 = _defaultOptions$local3.options) === null || _defaultOptions$local4 === void 0 ? void 0 : _defaultOptions$local4.weekStartsOn) !== null && _ref5 !== void 0 ? _ref5 : 0); // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
2262
-
2123
+ // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
2263
2124
  if (!(weekStartsOn >= 0 && weekStartsOn <= 6)) {
2264
2125
  throw new RangeError('weekStartsOn must be between 0 and 6 inclusively');
2265
2126
  }
2266
-
2267
2127
  if (!locale$1.localize) {
2268
2128
  throw new RangeError('locale must contain localize property');
2269
2129
  }
2270
-
2271
2130
  if (!locale$1.formatLong) {
2272
2131
  throw new RangeError('locale must contain formatLong property');
2273
2132
  }
2274
-
2275
2133
  var originalDate = toDate(dirtyDate);
2276
-
2277
2134
  if (!isValid(originalDate)) {
2278
2135
  throw new RangeError('Invalid time value');
2279
- } // Convert the date in system timezone to the same date in UTC+00:00 timezone.
2136
+ }
2137
+
2138
+ // Convert the date in system timezone to the same date in UTC+00:00 timezone.
2280
2139
  // This ensures that when UTC functions will be implemented, locales will be compatible with them.
2281
2140
  // See an issue about UTC functions: https://github.com/date-fns/date-fns/issues/376
2282
-
2283
-
2284
2141
  var timezoneOffset = getTimezoneOffsetInMilliseconds(originalDate);
2285
2142
  var utcDate = subMilliseconds(originalDate, timezoneOffset);
2286
2143
  var formatterOptions = {
@@ -2291,55 +2148,42 @@ function format(dirtyDate, dirtyFormatStr, options) {
2291
2148
  };
2292
2149
  var result = formatStr.match(longFormattingTokensRegExp).map(function (substring) {
2293
2150
  var firstCharacter = substring[0];
2294
-
2295
2151
  if (firstCharacter === 'p' || firstCharacter === 'P') {
2296
2152
  var longFormatter = longFormatters[firstCharacter];
2297
2153
  return longFormatter(substring, locale$1.formatLong);
2298
2154
  }
2299
-
2300
2155
  return substring;
2301
2156
  }).join('').match(formattingTokensRegExp).map(function (substring) {
2302
2157
  // Replace two single quote characters with one single quote character
2303
2158
  if (substring === "''") {
2304
2159
  return "'";
2305
2160
  }
2306
-
2307
2161
  var firstCharacter = substring[0];
2308
-
2309
2162
  if (firstCharacter === "'") {
2310
2163
  return cleanEscapedString(substring);
2311
2164
  }
2312
-
2313
2165
  var formatter = formatters[firstCharacter];
2314
-
2315
2166
  if (formatter) {
2316
2167
  if (!(options !== null && options !== void 0 && options.useAdditionalWeekYearTokens) && isProtectedWeekYearToken(substring)) {
2317
2168
  throwProtectedError(substring, dirtyFormatStr, String(dirtyDate));
2318
2169
  }
2319
-
2320
2170
  if (!(options !== null && options !== void 0 && options.useAdditionalDayOfYearTokens) && isProtectedDayOfYearToken(substring)) {
2321
2171
  throwProtectedError(substring, dirtyFormatStr, String(dirtyDate));
2322
2172
  }
2323
-
2324
2173
  return formatter(utcDate, substring, locale$1.localize, formatterOptions);
2325
2174
  }
2326
-
2327
2175
  if (firstCharacter.match(unescapedLatinCharacterRegExp)) {
2328
2176
  throw new RangeError('Format string contains an unescaped latin alphabet character `' + firstCharacter + '`');
2329
2177
  }
2330
-
2331
2178
  return substring;
2332
2179
  }).join('');
2333
2180
  return result;
2334
2181
  }
2335
-
2336
2182
  function cleanEscapedString(input) {
2337
2183
  var matched = input.match(escapedStringRegExp);
2338
-
2339
2184
  if (!matched) {
2340
2185
  return input;
2341
2186
  }
2342
-
2343
2187
  return matched[1].replace(doubleQuoteRegExp, "'");
2344
2188
  }
2345
2189