@rindo/core 1.8.12 → 2.5.2

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 (608) hide show
  1. package/LICENSE.md +27 -27
  2. package/bin/cli.ts +20 -0
  3. package/bin/rindo +51 -22
  4. package/cli/index.cjs +1263 -0
  5. package/cli/index.d.ts +15 -0
  6. package/cli/index.js +1237 -0
  7. package/cli/package.json +14 -0
  8. package/compiler/lib.d.ts +24 -0
  9. package/compiler/lib.dom.d.ts +20230 -0
  10. package/compiler/lib.dom.iterable.d.ts +351 -0
  11. package/compiler/lib.es2015.collection.d.ts +89 -0
  12. package/compiler/lib.es2015.core.d.ts +517 -0
  13. package/compiler/lib.es2015.d.ts +30 -0
  14. package/compiler/lib.es2015.generator.d.ts +79 -0
  15. package/compiler/lib.es2015.iterable.d.ts +505 -0
  16. package/compiler/lib.es2015.promise.d.ts +150 -0
  17. package/compiler/lib.es2015.proxy.d.ts +41 -0
  18. package/compiler/lib.es2015.reflect.d.ts +123 -0
  19. package/compiler/lib.es2015.symbol.d.ts +48 -0
  20. package/compiler/lib.es2015.symbol.wellknown.d.ts +324 -0
  21. package/compiler/lib.es2016.array.include.d.ts +118 -0
  22. package/compiler/lib.es2016.d.ts +22 -0
  23. package/compiler/lib.es2016.full.d.ts +25 -0
  24. package/compiler/lib.es2017.d.ts +26 -0
  25. package/compiler/lib.es2017.full.d.ts +25 -0
  26. package/compiler/lib.es2017.intl.d.ts +32 -0
  27. package/compiler/lib.es2017.object.d.ts +51 -0
  28. package/compiler/lib.es2017.sharedmemory.d.ts +137 -0
  29. package/compiler/lib.es2017.string.d.ts +47 -0
  30. package/compiler/lib.es2017.typedarrays.d.ts +55 -0
  31. package/compiler/lib.es2018.asyncgenerator.d.ts +79 -0
  32. package/compiler/lib.es2018.asynciterable.d.ts +45 -0
  33. package/compiler/lib.es2018.d.ts +26 -0
  34. package/compiler/lib.es2018.full.d.ts +25 -0
  35. package/compiler/lib.es2018.intl.d.ts +61 -0
  36. package/compiler/lib.es2018.promise.d.ts +32 -0
  37. package/compiler/lib.es2018.regexp.d.ts +39 -0
  38. package/compiler/lib.es2019.array.d.ts +85 -0
  39. package/compiler/lib.es2019.d.ts +25 -0
  40. package/compiler/lib.es2019.full.d.ts +25 -0
  41. package/compiler/lib.es2019.object.d.ts +35 -0
  42. package/compiler/lib.es2019.string.d.ts +33 -0
  43. package/compiler/lib.es2019.symbol.d.ts +26 -0
  44. package/compiler/lib.es2020.bigint.d.ts +728 -0
  45. package/compiler/lib.es2020.d.ts +27 -0
  46. package/compiler/lib.es2020.full.d.ts +25 -0
  47. package/compiler/lib.es2020.intl.d.ts +310 -0
  48. package/compiler/lib.es2020.promise.d.ts +50 -0
  49. package/compiler/lib.es2020.sharedmemory.d.ts +99 -0
  50. package/compiler/lib.es2020.string.d.ts +30 -0
  51. package/compiler/lib.es2020.symbol.wellknown.d.ts +39 -0
  52. package/compiler/lib.es5.d.ts +4435 -0
  53. package/compiler/lib.es6.d.ts +25 -0
  54. package/compiler/lib.esnext.d.ts +25 -0
  55. package/compiler/lib.esnext.full.d.ts +25 -0
  56. package/compiler/lib.esnext.intl.d.ts +32 -0
  57. package/compiler/lib.esnext.promise.d.ts +43 -0
  58. package/compiler/lib.esnext.string.d.ts +35 -0
  59. package/compiler/lib.esnext.weakref.d.ts +75 -0
  60. package/compiler/lib.scripthost.d.ts +327 -0
  61. package/compiler/lib.webworker.d.ts +6042 -0
  62. package/compiler/lib.webworker.importscripts.d.ts +26 -0
  63. package/compiler/lib.webworker.iterable.d.ts +166 -0
  64. package/compiler/package.json +8 -6
  65. package/compiler/rindo.d.ts +95 -0
  66. package/compiler/rindo.js +65051 -6657
  67. package/compiler/rindo.min.js +4 -0
  68. package/dependencies.json +103 -0
  69. package/dev-server/client/app-error.d.ts +18 -0
  70. package/dev-server/client/events.d.ts +6 -0
  71. package/dev-server/client/hmr-components.d.ts +1 -0
  72. package/dev-server/client/hmr-external-styles.d.ts +1 -0
  73. package/dev-server/client/hmr-images.d.ts +1 -0
  74. package/dev-server/client/hmr-inline-styles.d.ts +1 -0
  75. package/dev-server/client/hmr-util.d.ts +9 -0
  76. package/dev-server/client/hmr-window.d.ts +10 -0
  77. package/dev-server/client/index.d.ts +6 -0
  78. package/dev-server/client/index.js +808 -0
  79. package/dev-server/client/logger.d.ts +5 -0
  80. package/dev-server/client/package.json +8 -0
  81. package/dev-server/client/progress.d.ts +3 -0
  82. package/dev-server/client/status.d.ts +4 -0
  83. package/dev-server/connector.html +6 -0
  84. package/dev-server/index.d.ts +3 -0
  85. package/dev-server/index.js +264 -0
  86. package/dev-server/open-in-editor-api.js +1 -0
  87. package/dev-server/package.json +8 -0
  88. package/dev-server/server-process.js +1738 -0
  89. package/dev-server/server-worker-thread.js +39 -0
  90. package/{dist/dev-server → dev-server}/templates/directory-index.html +132 -132
  91. package/{dist/dev-server → dev-server}/templates/initial-load.html +160 -160
  92. package/dev-server/ws.js +1 -0
  93. package/internal/app-data/index.cjs +90 -0
  94. package/internal/app-data/index.d.ts +4 -0
  95. package/internal/{client/build-conditionals.mjs → app-data/index.js} +25 -21
  96. package/internal/app-data/package.json +15 -0
  97. package/internal/client/css-shim.js +4 -0
  98. package/internal/client/{dom.rindo-client.mjs → dom.js} +73 -137
  99. package/{dist/client/index.mjs → internal/client/index.js} +863 -789
  100. package/internal/client/package.json +8 -0
  101. package/internal/client/patch-browser.js +120 -0
  102. package/internal/client/patch-esm.js +23 -0
  103. package/internal/client/polyfills/core-js.js +11 -10
  104. package/internal/client/polyfills/css-shim.js +1 -656
  105. package/internal/client/polyfills/dom.js +79 -146
  106. package/internal/client/polyfills/es5-html-element.js +1 -18
  107. package/internal/client/polyfills/index.js +34 -35
  108. package/internal/client/{shadow-css.rindo-client.mjs → shadow-css.js} +20 -17
  109. package/internal/hydrate/index.js +1097 -0
  110. package/internal/hydrate/package.json +7 -0
  111. package/internal/hydrate/runner.d.ts +217 -0
  112. package/internal/hydrate/runner.js +777 -0
  113. package/internal/hydrate/shadow-css.js +146 -0
  114. package/internal/index.d.ts +4 -18
  115. package/internal/index.js +1 -1
  116. package/internal/package.json +9 -6
  117. package/internal/rindo-core/index.cjs +1 -0
  118. package/internal/rindo-core/index.d.ts +51 -0
  119. package/internal/rindo-core/index.js +15 -0
  120. package/internal/rindo-ext-modules.d.ts +41 -0
  121. package/internal/rindo-private.d.ts +2128 -0
  122. package/internal/rindo-public-compiler.d.ts +2170 -0
  123. package/{dist/declarations/docs.d.ts → internal/rindo-public-docs.d.ts} +13 -1
  124. package/internal/rindo-public-runtime.d.ts +1555 -0
  125. package/internal/testing/index.js +1055 -0
  126. package/internal/testing/package.json +7 -0
  127. package/internal/testing/shadow-css.js +146 -0
  128. package/mock-doc/index.cjs +4610 -0
  129. package/mock-doc/index.d.ts +916 -0
  130. package/mock-doc/index.js +4574 -2
  131. package/mock-doc/package.json +15 -10
  132. package/package.json +132 -186
  133. package/readme.md +21 -174
  134. package/screenshot/compare/build/app.css +1 -1
  135. package/screenshot/compare/build/app.esm.js +1 -1
  136. package/screenshot/compare/build/app.js +33 -818
  137. package/screenshot/compare/build/{p-113f7459.js → p-081b0641.js} +1 -1
  138. package/screenshot/compare/build/p-227a1e18.entry.js +1 -0
  139. package/screenshot/compare/build/p-2c298727.entry.js +1 -0
  140. package/screenshot/compare/build/p-5479268c.entry.js +1 -0
  141. package/screenshot/compare/build/p-573ec8a4.entry.js +1 -0
  142. package/screenshot/compare/build/p-6ba08604.entry.js +1 -0
  143. package/screenshot/compare/build/p-6bc63295.entry.js +1 -0
  144. package/screenshot/compare/build/p-7a3759fd.entry.js +1 -0
  145. package/screenshot/compare/build/{p-ejpsp3kx.js → p-7b4e3ba7.js} +1 -1
  146. package/screenshot/compare/build/p-988eb362.css +1 -0
  147. package/screenshot/compare/build/p-9b6a9315.js +1 -0
  148. package/screenshot/compare/build/p-b4cc611c.entry.js +1 -0
  149. package/screenshot/compare/build/p-d1bf53f5.entry.js +1 -0
  150. package/screenshot/compare/build/{p-efb0eac6.js → p-e2efe0df.js} +1 -1
  151. package/screenshot/compare/build/p-e8ca6d97.entry.js +1 -0
  152. package/screenshot/compare/build/p-ec2f13e0.entry.js +1 -0
  153. package/screenshot/compare/build/p-f0b99977.entry.js +1 -0
  154. package/screenshot/compare/build/p-f4745c2f.entry.js +1 -0
  155. package/screenshot/compare/build/p-fbbae598.js +1 -0
  156. package/screenshot/compare/host.config.json +14 -14
  157. package/screenshot/compare/index.html +1 -1
  158. package/{dist/screenshot → screenshot}/connector-base.d.ts +1 -1
  159. package/{dist/screenshot → screenshot}/connector-local.d.ts +1 -1
  160. package/screenshot/connector.js +2 -3
  161. package/{dist/screenshot → screenshot}/index.d.ts +1 -1
  162. package/screenshot/index.js +659 -2
  163. package/screenshot/local-connector.js +2 -3
  164. package/screenshot/package.json +15 -13
  165. package/screenshot/pixel-match.js +62 -49
  166. package/screenshot/screenshot-compare.d.ts +3 -0
  167. package/{dist/screenshot → screenshot}/screenshot-fs.d.ts +1 -1
  168. package/sys/deno/index.js +1785 -0
  169. package/sys/deno/node-compat.js +2654 -0
  170. package/sys/deno/worker.js +44 -0
  171. package/sys/node/autoprefixer.js +8 -0
  172. package/sys/node/glob.js +1 -0
  173. package/sys/node/graceful-fs.js +1 -0
  174. package/sys/node/index.d.ts +18 -0
  175. package/sys/node/index.js +1386 -2
  176. package/sys/node/node-fetch.js +1 -0
  177. package/sys/node/package.json +8 -5
  178. package/sys/node/prompts.js +1 -0
  179. package/sys/node/worker.js +52 -0
  180. package/{dist/testing → testing}/index.d.ts +5 -6
  181. package/testing/index.js +4017 -2
  182. package/testing/jest/jest-config.d.ts +5 -0
  183. package/{dist/testing → testing}/jest/jest-environment.d.ts +4 -2
  184. package/{dist/testing → testing}/jest/jest-preprocessor.d.ts +1 -0
  185. package/{dist/testing → testing}/jest/jest-runner.d.ts +1 -1
  186. package/{dist/testing → testing}/jest/jest-screenshot.d.ts +1 -1
  187. package/{dist/testing → testing}/jest/jest-serializer.d.ts +1 -1
  188. package/testing/jest-environment.js +3 -3
  189. package/testing/jest-preprocessor.js +3 -3
  190. package/testing/jest-preset.js +32 -40
  191. package/testing/jest-runner.js +3 -3
  192. package/testing/jest-setuptestframework.js +3 -3
  193. package/{dist/testing → testing}/matchers/events.d.ts +9 -1
  194. package/{dist/testing → testing}/matchers/index.d.ts +3 -1
  195. package/{dist/testing → testing}/matchers/screenshot.d.ts +1 -1
  196. package/testing/mock-fetch.d.ts +11 -0
  197. package/testing/mocks.d.ts +14 -0
  198. package/testing/package.json +8 -6
  199. package/testing/puppeteer/index.d.ts +2 -0
  200. package/{dist/testing → testing}/puppeteer/puppeteer-browser.d.ts +3 -3
  201. package/{dist/testing → testing}/puppeteer/puppeteer-declarations.d.ts +18 -18
  202. package/{dist/testing → testing}/puppeteer/puppeteer-element.d.ts +7 -5
  203. package/testing/puppeteer/puppeteer-emulate.d.ts +2 -0
  204. package/{dist/testing → testing}/puppeteer/puppeteer-events.d.ts +9 -9
  205. package/testing/puppeteer/puppeteer-page.d.ts +2 -0
  206. package/testing/puppeteer/puppeteer-screenshot.d.ts +4 -0
  207. package/testing/reset-build-conditionals.d.ts +2 -0
  208. package/testing/spec-page.d.ts +2 -0
  209. package/testing/test-transpile.d.ts +2 -0
  210. package/{dist/testing → testing}/testing-logger.d.ts +10 -8
  211. package/testing/testing-sys.d.ts +1 -0
  212. package/{dist/testing → testing}/testing-utils.d.ts +3 -2
  213. package/testing/testing.d.ts +2 -0
  214. package/build-conditionals/index.d.ts +0 -2
  215. package/build-conditionals/index.mjs +0 -66
  216. package/build-conditionals/package.json +0 -6
  217. package/compiler/index.js +0 -2
  218. package/dist/cli/index.js +0 -6068
  219. package/dist/client/css-shim-14a9812e.js +0 -656
  220. package/dist/client/css-shim-69821662.js +0 -658
  221. package/dist/client/declarations/rindo.core.d.ts +0 -1347
  222. package/dist/client/dom-68c8fe31.js +0 -139
  223. package/dist/client/dom-af01458a.js +0 -137
  224. package/dist/client/index.js +0 -2937
  225. package/dist/client/polyfills/core-js.js +0 -10
  226. package/dist/client/polyfills/css-shim.js +0 -656
  227. package/dist/client/polyfills/dom.js +0 -146
  228. package/dist/client/polyfills/es5-html-element.js +0 -18
  229. package/dist/client/polyfills/index.js +0 -35
  230. package/dist/client/polyfills/promise.js +0 -9
  231. package/dist/client/polyfills/system.js +0 -6
  232. package/dist/client/shadow-css-6ef31c68.js +0 -386
  233. package/dist/client/shadow-css-8fd1a9e4.js +0 -388
  234. package/dist/compiler/app-core/app-es5-disabled.d.ts +0 -2
  235. package/dist/compiler/app-core/app-polyfills.d.ts +0 -3
  236. package/dist/compiler/app-core/build-conditionals.d.ts +0 -6
  237. package/dist/compiler/app-core/bundle-app-core.d.ts +0 -6
  238. package/dist/compiler/app-core/component-styles.d.ts +0 -4
  239. package/dist/compiler/app-core/format-component-runtime-meta.d.ts +0 -4
  240. package/dist/compiler/app-core/optimize-module.d.ts +0 -7
  241. package/dist/compiler/browser/build-conditionals-client.d.ts +0 -3
  242. package/dist/compiler/browser/compile-options.d.ts +0 -12
  243. package/dist/compiler/browser/compile.d.ts +0 -2
  244. package/dist/compiler/browser/create-compiler.d.ts +0 -14
  245. package/dist/compiler/browser/index.d.ts +0 -11
  246. package/dist/compiler/build/build-ctx.d.ts +0 -74
  247. package/dist/compiler/build/build-finish.d.ts +0 -3
  248. package/dist/compiler/build/build-hmr.d.ts +0 -2
  249. package/dist/compiler/build/build-results.d.ts +0 -2
  250. package/dist/compiler/build/build-stats.d.ts +0 -3
  251. package/dist/compiler/build/build.d.ts +0 -2
  252. package/dist/compiler/build/cache-stats.d.ts +0 -4
  253. package/dist/compiler/build/compiler-build-id.d.ts +0 -6
  254. package/dist/compiler/build/compiler-ctx.d.ts +0 -44
  255. package/dist/compiler/build/init-index-html.d.ts +0 -2
  256. package/dist/compiler/build/validate-files.d.ts +0 -2
  257. package/dist/compiler/build/write-build.d.ts +0 -2
  258. package/dist/compiler/cache.d.ts +0 -22
  259. package/dist/compiler/compiler.d.ts +0 -27
  260. package/dist/compiler/component-hydrate/bundle-hydrate-factory.d.ts +0 -3
  261. package/dist/compiler/component-hydrate/generate-hydrate-app.d.ts +0 -2
  262. package/dist/compiler/component-hydrate/hydrate-factory-closure.d.ts +0 -2
  263. package/dist/compiler/component-hydrate/update-to-hydrate-components.d.ts +0 -2
  264. package/dist/compiler/component-hydrate/write-hydrate-outputs.d.ts +0 -3
  265. package/dist/compiler/component-lazy/generate-cjs.d.ts +0 -3
  266. package/dist/compiler/component-lazy/generate-esm-browser.d.ts +0 -3
  267. package/dist/compiler/component-lazy/generate-esm.d.ts +0 -3
  268. package/dist/compiler/component-lazy/generate-lazy-app.d.ts +0 -3
  269. package/dist/compiler/component-lazy/generate-lazy-module.d.ts +0 -4
  270. package/dist/compiler/component-lazy/generate-system.d.ts +0 -3
  271. package/dist/compiler/component-lazy/update-to-lazy-component.d.ts +0 -2
  272. package/dist/compiler/component-lazy/write-lazy-entry-module.d.ts +0 -2
  273. package/dist/compiler/component-native/update-to-native-component.d.ts +0 -2
  274. package/dist/compiler/config/config-reload.d.ts +0 -3
  275. package/dist/compiler/config/config-utils.d.ts +0 -4
  276. package/dist/compiler/config/validate-config.d.ts +0 -4
  277. package/dist/compiler/config/validate-copy.d.ts +0 -2
  278. package/dist/compiler/config/validate-dev-server.d.ts +0 -2
  279. package/dist/compiler/config/validate-docs.d.ts +0 -2
  280. package/dist/compiler/config/validate-namespace.d.ts +0 -3
  281. package/dist/compiler/config/validate-output-stats.d.ts +0 -2
  282. package/dist/compiler/config/validate-outputs-angular.d.ts +0 -2
  283. package/dist/compiler/config/validate-outputs-custom.d.ts +0 -2
  284. package/dist/compiler/config/validate-outputs-dist-module.d.ts +0 -2
  285. package/dist/compiler/config/validate-outputs-dist.d.ts +0 -2
  286. package/dist/compiler/config/validate-outputs-hydrate-script.d.ts +0 -2
  287. package/dist/compiler/config/validate-outputs-www.d.ts +0 -2
  288. package/dist/compiler/config/validate-outputs.d.ts +0 -2
  289. package/dist/compiler/config/validate-paths.d.ts +0 -2
  290. package/dist/compiler/config/validate-plugins.d.ts +0 -2
  291. package/dist/compiler/config/validate-prerender.d.ts +0 -2
  292. package/dist/compiler/config/validate-rollup-config.d.ts +0 -2
  293. package/dist/compiler/config/validate-service-worker.d.ts +0 -2
  294. package/dist/compiler/config/validate-testing.d.ts +0 -2
  295. package/dist/compiler/config/validate-workers.d.ts +0 -2
  296. package/dist/compiler/copy/assets-copy-tasks.d.ts +0 -3
  297. package/dist/compiler/copy/hashed-copy.d.ts +0 -2
  298. package/dist/compiler/copy/local-copy-tasks.d.ts +0 -3
  299. package/dist/compiler/docs/constants.d.ts +0 -2
  300. package/dist/compiler/docs/custom/index.d.ts +0 -2
  301. package/dist/compiler/docs/docs.d.ts +0 -2
  302. package/dist/compiler/docs/generate-doc-data.d.ts +0 -3
  303. package/dist/compiler/docs/json/index.d.ts +0 -3
  304. package/dist/compiler/docs/readme/docs-util.d.ts +0 -13
  305. package/dist/compiler/docs/readme/index.d.ts +0 -3
  306. package/dist/compiler/docs/readme/markdown-css-props.d.ts +0 -2
  307. package/dist/compiler/docs/readme/markdown-dependencies.d.ts +0 -2
  308. package/dist/compiler/docs/readme/markdown-events.d.ts +0 -2
  309. package/dist/compiler/docs/readme/markdown-methods.d.ts +0 -2
  310. package/dist/compiler/docs/readme/markdown-props.d.ts +0 -2
  311. package/dist/compiler/docs/readme/markdown-slots.d.ts +0 -2
  312. package/dist/compiler/docs/readme/markdown-usage.d.ts +0 -6
  313. package/dist/compiler/docs/readme/output-docs.d.ts +0 -3
  314. package/dist/compiler/docs/style-docs.d.ts +0 -2
  315. package/dist/compiler/docs/vscode/index.d.ts +0 -2
  316. package/dist/compiler/entries/component-bundles.d.ts +0 -3
  317. package/dist/compiler/entries/component-graph.d.ts +0 -2
  318. package/dist/compiler/entries/default-bundles.d.ts +0 -3
  319. package/dist/compiler/entries/entry-modules.d.ts +0 -6
  320. package/dist/compiler/entries/resolve-component-dependencies.d.ts +0 -2
  321. package/dist/compiler/events.d.ts +0 -15
  322. package/dist/compiler/fs-watch/fs-watch-init.d.ts +0 -2
  323. package/dist/compiler/fs-watch/fs-watch-log.d.ts +0 -2
  324. package/dist/compiler/fs-watch/fs-watch-rebuild.d.ts +0 -7
  325. package/dist/compiler/html/inject-module-preloads.d.ts +0 -3
  326. package/dist/compiler/html/inject-sw-script.d.ts +0 -4
  327. package/dist/compiler/html/inline-esm-import.d.ts +0 -2
  328. package/dist/compiler/html/inline-style-sheets.d.ts +0 -2
  329. package/dist/compiler/html/update-global-styles-link.d.ts +0 -2
  330. package/dist/compiler/html/used-components.d.ts +0 -2
  331. package/dist/compiler/html/utils.d.ts +0 -2
  332. package/dist/compiler/html/validate-manifest-json.d.ts +0 -2
  333. package/dist/compiler/index.d.ts +0 -10
  334. package/dist/compiler/index.js +0 -18008
  335. package/dist/compiler/output-targets/empty-dir.d.ts +0 -6
  336. package/dist/compiler/output-targets/index.d.ts +0 -2
  337. package/dist/compiler/output-targets/output-angular.d.ts +0 -4
  338. package/dist/compiler/output-targets/output-app.d.ts +0 -4
  339. package/dist/compiler/output-targets/output-collection.d.ts +0 -3
  340. package/dist/compiler/output-targets/output-copy.d.ts +0 -2
  341. package/dist/compiler/output-targets/output-custom.d.ts +0 -2
  342. package/dist/compiler/output-targets/output-docs.d.ts +0 -2
  343. package/dist/compiler/output-targets/output-hydrate.d.ts +0 -2
  344. package/dist/compiler/output-targets/output-lazy-loader.d.ts +0 -2
  345. package/dist/compiler/output-targets/output-module.d.ts +0 -4
  346. package/dist/compiler/output-targets/output-prerender.d.ts +0 -2
  347. package/dist/compiler/output-targets/output-service-workers.d.ts +0 -2
  348. package/dist/compiler/output-targets/output-types.d.ts +0 -2
  349. package/dist/compiler/output-targets/output-utils.d.ts +0 -54
  350. package/dist/compiler/output-targets/output-www.d.ts +0 -2
  351. package/dist/compiler/plugin/plugin.d.ts +0 -6
  352. package/dist/compiler/prerender/crawl-urls.d.ts +0 -3
  353. package/dist/compiler/prerender/host-config.d.ts +0 -12
  354. package/dist/compiler/prerender/prerender-config.d.ts +0 -2
  355. package/dist/compiler/prerender/prerender-main.d.ts +0 -2
  356. package/dist/compiler/prerender/prerender-queue.d.ts +0 -3
  357. package/dist/compiler/prerender/prerender-template-html.d.ts +0 -2
  358. package/dist/compiler/prerender/prerendered-write-path.d.ts +0 -2
  359. package/dist/compiler/prerender/robots-txt.d.ts +0 -2
  360. package/dist/compiler/prerender/sitemap-xml.d.ts +0 -3
  361. package/dist/compiler/rollup-plugins/component-entry.d.ts +0 -3
  362. package/dist/compiler/rollup-plugins/css-transformer.d.ts +0 -3
  363. package/dist/compiler/rollup-plugins/global-scripts.d.ts +0 -4
  364. package/dist/compiler/rollup-plugins/image-plugin.d.ts +0 -3
  365. package/dist/compiler/rollup-plugins/in-memory-fs-read.d.ts +0 -3
  366. package/dist/compiler/rollup-plugins/loader.d.ts +0 -4
  367. package/dist/compiler/rollup-plugins/plugin-helper.d.ts +0 -5
  368. package/dist/compiler/rollup-plugins/rindo-build-conditionals.d.ts +0 -7
  369. package/dist/compiler/rollup-plugins/rindo-client.d.ts +0 -3
  370. package/dist/compiler/rollup-plugins/rindo-external-runtime.d.ts +0 -2
  371. package/dist/compiler/rollup-plugins/rindo-hydrate.d.ts +0 -3
  372. package/dist/compiler/rollup-plugins/rindo-public-plugin.d.ts +0 -2
  373. package/dist/compiler/service-worker/generate-sw.d.ts +0 -7
  374. package/dist/compiler/service-worker/service-worker-util.d.ts +0 -2
  375. package/dist/compiler/style/cached-styles.d.ts +0 -5
  376. package/dist/compiler/style/component-styles.d.ts +0 -2
  377. package/dist/compiler/style/css-imports.d.ts +0 -9
  378. package/dist/compiler/style/css-to-esm.d.ts +0 -5
  379. package/dist/compiler/style/generate-styles.d.ts +0 -2
  380. package/dist/compiler/style/global-styles.d.ts +0 -3
  381. package/dist/compiler/style/normalize-styles.d.ts +0 -2
  382. package/dist/compiler/style/optimize-css.d.ts +0 -2
  383. package/dist/compiler/style/scope-css.d.ts +0 -3
  384. package/dist/compiler/style/style-utils.d.ts +0 -10
  385. package/dist/compiler/transformers/add-component-meta-proxy.d.ts +0 -3
  386. package/dist/compiler/transformers/add-component-meta-static.d.ts +0 -4
  387. package/dist/compiler/transformers/add-imports.d.ts +0 -3
  388. package/dist/compiler/transformers/collections/add-external-import.d.ts +0 -2
  389. package/dist/compiler/transformers/collections/parse-collection-components.d.ts +0 -2
  390. package/dist/compiler/transformers/collections/parse-collection-deprecated.d.ts +0 -2
  391. package/dist/compiler/transformers/collections/parse-collection-manifest.d.ts +0 -7
  392. package/dist/compiler/transformers/collections/parse-collection-module.d.ts +0 -2
  393. package/dist/compiler/transformers/component-build-conditionals.d.ts +0 -2
  394. package/dist/compiler/transformers/component-hydrate/hydrate-component.d.ts +0 -3
  395. package/dist/compiler/transformers/component-hydrate/hydrate-runtime-cmp-meta.d.ts +0 -3
  396. package/dist/compiler/transformers/component-hydrate/tranform-to-hydrate-component.d.ts +0 -2
  397. package/dist/compiler/transformers/component-lazy/lazy-component.d.ts +0 -3
  398. package/dist/compiler/transformers/component-lazy/lazy-constructor.d.ts +0 -3
  399. package/dist/compiler/transformers/component-lazy/lazy-element-getter.d.ts +0 -3
  400. package/dist/compiler/transformers/component-lazy/transform-lazy-component.d.ts +0 -4
  401. package/dist/compiler/transformers/component-native/native-component.d.ts +0 -3
  402. package/dist/compiler/transformers/component-native/native-connected-callback.d.ts +0 -3
  403. package/dist/compiler/transformers/component-native/native-constructor.d.ts +0 -3
  404. package/dist/compiler/transformers/component-native/native-element-getter.d.ts +0 -3
  405. package/dist/compiler/transformers/component-native/native-static-style.d.ts +0 -3
  406. package/dist/compiler/transformers/component-native/tranform-to-native-component.d.ts +0 -4
  407. package/dist/compiler/transformers/core-runtime-apis.d.ts +0 -30
  408. package/dist/compiler/transformers/create-event.d.ts +0 -3
  409. package/dist/compiler/transformers/decorators-to-static/component-decorator.d.ts +0 -3
  410. package/dist/compiler/transformers/decorators-to-static/convert-decorators.d.ts +0 -3
  411. package/dist/compiler/transformers/decorators-to-static/decorator-utils.d.ts +0 -10
  412. package/dist/compiler/transformers/decorators-to-static/element-decorator.d.ts +0 -3
  413. package/dist/compiler/transformers/decorators-to-static/event-decorator.d.ts +0 -4
  414. package/dist/compiler/transformers/decorators-to-static/listen-decorator.d.ts +0 -6
  415. package/dist/compiler/transformers/decorators-to-static/method-decorator.d.ts +0 -3
  416. package/dist/compiler/transformers/decorators-to-static/prop-decorator.d.ts +0 -4
  417. package/dist/compiler/transformers/decorators-to-static/state-decorator.d.ts +0 -3
  418. package/dist/compiler/transformers/decorators-to-static/style-to-static.d.ts +0 -3
  419. package/dist/compiler/transformers/decorators-to-static/watch-decorator.d.ts +0 -3
  420. package/dist/compiler/transformers/define-custom-element.d.ts +0 -3
  421. package/dist/compiler/transformers/host-data-transform.d.ts +0 -3
  422. package/dist/compiler/transformers/legacy-props.d.ts +0 -3
  423. package/dist/compiler/transformers/remove-static-meta-properties.d.ts +0 -2
  424. package/dist/compiler/transformers/reserved-public-members.d.ts +0 -3
  425. package/dist/compiler/transformers/rindo-import-path.d.ts +0 -3
  426. package/dist/compiler/transformers/static-to-meta/call-expression.d.ts +0 -3
  427. package/dist/compiler/transformers/static-to-meta/class-methods.d.ts +0 -3
  428. package/dist/compiler/transformers/static-to-meta/component.d.ts +0 -3
  429. package/dist/compiler/transformers/static-to-meta/element-ref.d.ts +0 -2
  430. package/dist/compiler/transformers/static-to-meta/encapsulation.d.ts +0 -3
  431. package/dist/compiler/transformers/static-to-meta/events.d.ts +0 -3
  432. package/dist/compiler/transformers/static-to-meta/import.d.ts +0 -3
  433. package/dist/compiler/transformers/static-to-meta/listeners.d.ts +0 -3
  434. package/dist/compiler/transformers/static-to-meta/methods.d.ts +0 -3
  435. package/dist/compiler/transformers/static-to-meta/props.d.ts +0 -3
  436. package/dist/compiler/transformers/static-to-meta/states.d.ts +0 -3
  437. package/dist/compiler/transformers/static-to-meta/string-literal.d.ts +0 -3
  438. package/dist/compiler/transformers/static-to-meta/styles.d.ts +0 -3
  439. package/dist/compiler/transformers/static-to-meta/vdom.d.ts +0 -3
  440. package/dist/compiler/transformers/static-to-meta/visitor.d.ts +0 -3
  441. package/dist/compiler/transformers/static-to-meta/watchers.d.ts +0 -3
  442. package/dist/compiler/transformers/style-imports.d.ts +0 -3
  443. package/dist/compiler/transformers/transform-utils.d.ts +0 -31
  444. package/dist/compiler/transformers/update-component-class.d.ts +0 -3
  445. package/dist/compiler/transformers/update-rindo-core-import.d.ts +0 -3
  446. package/dist/compiler/transformers/watcher-meta-transform.d.ts +0 -3
  447. package/dist/compiler/transpile/compiler-options.d.ts +0 -4
  448. package/dist/compiler/transpile/transpile-app.d.ts +0 -2
  449. package/dist/compiler/transpile/transpile-module.d.ts +0 -5
  450. package/dist/compiler/transpile/transpile-service.d.ts +0 -3
  451. package/dist/compiler/transpile/transpile-to-es5-main.d.ts +0 -2
  452. package/dist/compiler/transpile/validate-types-main.d.ts +0 -2
  453. package/dist/compiler/types/generate-app-types.d.ts +0 -2
  454. package/dist/compiler/types/generate-component-types.d.ts +0 -8
  455. package/dist/compiler/types/generate-event-types.d.ts +0 -2
  456. package/dist/compiler/types/generate-method-types.d.ts +0 -2
  457. package/dist/compiler/types/generate-prop-types.d.ts +0 -2
  458. package/dist/compiler/types/generate-types.d.ts +0 -2
  459. package/dist/compiler/types/rindo-types.d.ts +0 -3
  460. package/dist/compiler/types/types-utils.d.ts +0 -4
  461. package/dist/compiler/types/update-import-refs.d.ts +0 -11
  462. package/dist/compiler/types/validate-package-json.d.ts +0 -9
  463. package/dist/declarations/assets.d.ts +0 -17
  464. package/dist/declarations/browser-compile.d.ts +0 -47
  465. package/dist/declarations/build-conditionals.d.ts +0 -91
  466. package/dist/declarations/build-events.d.ts +0 -19
  467. package/dist/declarations/build.d.ts +0 -247
  468. package/dist/declarations/cache.d.ts +0 -11
  469. package/dist/declarations/collection-manifest.d.ts +0 -106
  470. package/dist/declarations/collection.d.ts +0 -139
  471. package/dist/declarations/compiler.d.ts +0 -53
  472. package/dist/declarations/component-compiler-meta.d.ts +0 -198
  473. package/dist/declarations/component-constructor.d.ts +0 -61
  474. package/dist/declarations/component-interfaces.d.ts +0 -123
  475. package/dist/declarations/config.d.ts +0 -409
  476. package/dist/declarations/css-var-shim.d.ts +0 -9
  477. package/dist/declarations/decorators.d.ts +0 -150
  478. package/dist/declarations/dev-server.d.ts +0 -135
  479. package/dist/declarations/diagnostics.d.ts +0 -21
  480. package/dist/declarations/entry.d.ts +0 -28
  481. package/dist/declarations/events.d.ts +0 -13
  482. package/dist/declarations/file-system.d.ts +0 -91
  483. package/dist/declarations/fs-watch.d.ts +0 -15
  484. package/dist/declarations/host-element.d.ts +0 -53
  485. package/dist/declarations/hydrate.d.ts +0 -99
  486. package/dist/declarations/in-memory-fs.d.ts +0 -59
  487. package/dist/declarations/index.d.ts +0 -45
  488. package/dist/declarations/jsdoc.d.ts +0 -16
  489. package/dist/declarations/jsx.d.ts +0 -1050
  490. package/dist/declarations/logger.d.ts +0 -25
  491. package/dist/declarations/minify-js.d.ts +0 -11
  492. package/dist/declarations/module.d.ts +0 -35
  493. package/dist/declarations/optimize-css.d.ts +0 -12
  494. package/dist/declarations/output-targets.d.ts +0 -189
  495. package/dist/declarations/plugin.d.ts +0 -23
  496. package/dist/declarations/prerender.d.ts +0 -79
  497. package/dist/declarations/render.d.ts +0 -62
  498. package/dist/declarations/runtime.d.ts +0 -92
  499. package/dist/declarations/screenshots.d.ts +0 -192
  500. package/dist/declarations/server.d.ts +0 -19
  501. package/dist/declarations/style.d.ts +0 -35
  502. package/dist/declarations/system.d.ts +0 -174
  503. package/dist/declarations/testing.d.ts +0 -523
  504. package/dist/declarations/transpile.d.ts +0 -24
  505. package/dist/declarations/types.d.ts +0 -24
  506. package/dist/declarations/vdom.d.ts +0 -55
  507. package/dist/declarations/worker.d.ts +0 -33
  508. package/dist/dev-server/content-type-db.json +0 -1
  509. package/dist/dev-server/index.js +0 -887
  510. package/dist/dev-server/static/app-error.css +0 -257
  511. package/dist/dev-server/static/dev-server-client.html +0 -13
  512. package/dist/hydrate/index.d.ts +0 -101
  513. package/dist/hydrate/index.mjs +0 -1281
  514. package/dist/hydrate/platform.mjs +0 -347
  515. package/dist/index.d.ts +0 -99
  516. package/dist/index.js +0 -1
  517. package/dist/mock-doc/index.d.ts +0 -851
  518. package/dist/mock-doc/index.js +0 -3982
  519. package/dist/mock-doc/index.mjs +0 -3954
  520. package/dist/runtime/index.js +0 -2576
  521. package/dist/runtime/index.mjs +0 -2521
  522. package/dist/runtime/shadow-css-6ef31c68.js +0 -386
  523. package/dist/runtime/shadow-css-8fd1a9e4.js +0 -388
  524. package/dist/screenshot/index.js +0 -520
  525. package/dist/sys/node/graceful-fs.js +0 -975
  526. package/dist/sys/node/index.js +0 -33545
  527. package/dist/sys/node/node-fetch.js +0 -1779
  528. package/dist/sys/node/open-in-editor.js +0 -734
  529. package/dist/sys/node/sys-worker.js +0 -67035
  530. package/dist/sys/node/websocket.js +0 -3728
  531. package/dist/testing/build-conditionals.d.ts +0 -4
  532. package/dist/testing/build-conditionals.js +0 -43
  533. package/dist/testing/core.d.ts +0 -35
  534. package/dist/testing/core.js +0 -52
  535. package/dist/testing/index.js +0 -40511
  536. package/dist/testing/jest/jest-config.d.ts +0 -4
  537. package/dist/testing/mock-fetch.d.ts +0 -46
  538. package/dist/testing/mocks.d.ts +0 -12
  539. package/dist/testing/platform.d.ts +0 -23
  540. package/dist/testing/platform.js +0 -321
  541. package/dist/testing/puppeteer/puppeteer-emulate.d.ts +0 -2
  542. package/dist/testing/puppeteer/puppeteer-find.d.ts +0 -5
  543. package/dist/testing/puppeteer/puppeteer-page.d.ts +0 -2
  544. package/dist/testing/puppeteer/puppeteer-screenshot.d.ts +0 -4
  545. package/dist/testing/spec-page.d.ts +0 -5
  546. package/dist/testing/task-queue.d.ts +0 -15
  547. package/dist/testing/test-transpile.d.ts +0 -5
  548. package/dist/testing/testing-fs.d.ts +0 -31
  549. package/dist/testing/testing-sys.d.ts +0 -19
  550. package/dist/testing/testing.d.ts +0 -12
  551. package/dist/utils/index.js +0 -1575
  552. package/dist/utils/index.mjs +0 -1511
  553. package/internal/client/css-shim.rindo-client.mjs +0 -656
  554. package/internal/client/index.mjs +0 -2859
  555. package/internal/client/polyfills/promise.js +0 -9
  556. package/internal/images.d.ts +0 -5
  557. package/runtime/package.json +0 -5
  558. package/screenshot/compare/build/p-020f8d73.js +0 -1
  559. package/screenshot/compare/build/p-09qdknbg.system.entry.js +0 -1
  560. package/screenshot/compare/build/p-0a13mpsc.system.entry.js +0 -1
  561. package/screenshot/compare/build/p-168ec2c4.system.js +0 -1
  562. package/screenshot/compare/build/p-2ab1fdf1.system.js +0 -1
  563. package/screenshot/compare/build/p-2pxcsgrj.entry.js +0 -1
  564. package/screenshot/compare/build/p-42fb7034.system.js +0 -1
  565. package/screenshot/compare/build/p-54d9d7c2.system.js +0 -1
  566. package/screenshot/compare/build/p-67c1f911.js +0 -1
  567. package/screenshot/compare/build/p-68613371.system.js +0 -1
  568. package/screenshot/compare/build/p-7dvsjpu0.entry.js +0 -1
  569. package/screenshot/compare/build/p-aa67fb06.js +0 -1
  570. package/screenshot/compare/build/p-aeb3cec1.system.js +0 -1
  571. package/screenshot/compare/build/p-b6e44a24.js +0 -1
  572. package/screenshot/compare/build/p-c1c25b8a.js +0 -1
  573. package/screenshot/compare/build/p-c9bopbjy.system.entry.js +0 -1
  574. package/screenshot/compare/build/p-c9iqz1pp.system.entry.js +0 -1
  575. package/screenshot/compare/build/p-dizjz8rg.entry.js +0 -1
  576. package/screenshot/compare/build/p-dnta0rwp.system.entry.js +0 -1
  577. package/screenshot/compare/build/p-e9670d22.system.js +0 -1
  578. package/screenshot/compare/build/p-ei9jkpd0.system.entry.js +0 -1
  579. package/screenshot/compare/build/p-ejwcppol.entry.js +0 -1
  580. package/screenshot/compare/build/p-f6612d5d.system.js +0 -1
  581. package/screenshot/compare/build/p-foiivsfc.css +0 -1
  582. package/screenshot/compare/build/p-gpjjyogx.entry.js +0 -1
  583. package/screenshot/compare/build/p-howklem2.system.entry.js +0 -1
  584. package/screenshot/compare/build/p-knv9wvoc.entry.js +0 -1
  585. package/screenshot/compare/build/p-nsqsfhhy.entry.js +0 -1
  586. package/screenshot/compare/build/p-ojt278pp.entry.js +0 -1
  587. package/screenshot/compare/build/p-oywass99.entry.js +0 -1
  588. package/screenshot/compare/build/p-q3ujhub6.entry.js +0 -1
  589. package/screenshot/compare/build/p-qw4xnmxv.entry.js +0 -1
  590. package/screenshot/compare/build/p-t1wvevhc.system.entry.js +0 -1
  591. package/screenshot/compare/build/p-tnjarrex.system.entry.js +0 -1
  592. package/screenshot/compare/build/p-vhfpd6kk.system.entry.js +0 -1
  593. package/screenshot/compare/build/p-vk6rhemd.system.entry.js +0 -1
  594. package/screenshot/compare/build/p-w6bnm16k.entry.js +0 -1
  595. package/screenshot/compare/build/p-xje6d7zl.system.entry.js +0 -1
  596. package/screenshot/compare/build/p-y5jlrcha.system.entry.js +0 -1
  597. package/screenshot/compare/build/p-yh170wkt.entry.js +0 -1
  598. package/testing/jest.preprocessor.js +0 -7
  599. /package/{dist/dev-server → dev-server}/static/favicon.ico +0 -0
  600. /package/{dist/sys/node → dev-server}/visualstudio.vbs +0 -0
  601. /package/{dist/sys/node → dev-server}/xdg-open +0 -0
  602. /package/{dist/compiler/polyfills.d.ts → screenshot/compare/build/index.esm.js} +0 -0
  603. /package/{dist/screenshot → screenshot}/pixel-match.d.ts +0 -0
  604. /package/{dist/testing → testing}/jest/jest-setup-test-framework.d.ts +0 -0
  605. /package/{dist/testing → testing}/matchers/attributes.d.ts +0 -0
  606. /package/{dist/testing → testing}/matchers/class-list.d.ts +0 -0
  607. /package/{dist/testing → testing}/matchers/html.d.ts +0 -0
  608. /package/{dist/testing → testing}/matchers/text.d.ts +0 -0
@@ -0,0 +1,2128 @@
1
+ import type { BuildEvents, BuildLog, BuildOutput, CompilerBuildResults, CompilerBuildStart, CompilerFsStats, CompilerRequestResponse, CompilerSystem, Config, CopyResults, DevServerConfig, DevServerEditor, Diagnostic, FsWriteOptions, Logger, LoggerTimeSpan, OptimizeCssInput, OptimizeCssOutput, OutputTargetWww, PageReloadStrategy, PrerenderConfig, StyleDoc, LoggerLineUpdater } from './rindo-public-compiler';
2
+ import type { ComponentInterface, ListenOptions, ListenTargetOptions, VNode, VNodeData } from './rindo-public-runtime';
3
+ export interface PrintLine {
4
+ lineIndex: number;
5
+ lineNumber: number;
6
+ text?: string;
7
+ errorCharStart: number;
8
+ errorLength?: number;
9
+ }
10
+ export interface AssetsMeta {
11
+ absolutePath: string;
12
+ cmpRelativePath: string;
13
+ originalComponentPath: string;
14
+ }
15
+ export interface ParsedImport {
16
+ importPath: string;
17
+ basename: string;
18
+ ext: string;
19
+ data: ImportData;
20
+ }
21
+ export interface ImportData {
22
+ tag?: string;
23
+ encapsulation?: string;
24
+ mode?: string;
25
+ }
26
+ export interface SerializeImportData extends ImportData {
27
+ importeePath: string;
28
+ importerPath?: string;
29
+ }
30
+ export interface BuildFeatures {
31
+ style: boolean;
32
+ mode: boolean;
33
+ shadowDom: boolean;
34
+ shadowDelegatesFocus: boolean;
35
+ scoped: boolean;
36
+ /**
37
+ * Every component has a render function
38
+ */
39
+ allRenderFn: boolean;
40
+ /**
41
+ * At least one component has a render function
42
+ */
43
+ hasRenderFn: boolean;
44
+ vdomRender: boolean;
45
+ vdomAttribute: boolean;
46
+ vdomClass: boolean;
47
+ vdomFunctional: boolean;
48
+ vdomKey: boolean;
49
+ vdomListener: boolean;
50
+ vdomPropOrAttr: boolean;
51
+ vdomRef: boolean;
52
+ vdomStyle: boolean;
53
+ vdomText: boolean;
54
+ vdomXlink: boolean;
55
+ slotRelocation: boolean;
56
+ slot: boolean;
57
+ svg: boolean;
58
+ element: boolean;
59
+ event: boolean;
60
+ hostListener: boolean;
61
+ hostListenerTargetWindow: boolean;
62
+ hostListenerTargetDocument: boolean;
63
+ hostListenerTargetBody: boolean;
64
+ /**
65
+ * @deprecated Prevented from new apps, but left in for older collections
66
+ */
67
+ hostListenerTargetParent: boolean;
68
+ hostListenerTarget: boolean;
69
+ method: boolean;
70
+ prop: boolean;
71
+ propMutable: boolean;
72
+ state: boolean;
73
+ watchCallback: boolean;
74
+ member: boolean;
75
+ updatable: boolean;
76
+ propBoolean: boolean;
77
+ propNumber: boolean;
78
+ propString: boolean;
79
+ lifecycle: boolean;
80
+ cmpDidLoad: boolean;
81
+ cmpShouldUpdate: boolean;
82
+ cmpWillLoad: boolean;
83
+ cmpDidUpdate: boolean;
84
+ cmpWillUpdate: boolean;
85
+ cmpWillRender: boolean;
86
+ cmpDidRender: boolean;
87
+ cmpDidUnload: boolean;
88
+ connectedCallback: boolean;
89
+ disconnectedCallback: boolean;
90
+ asyncLoading: boolean;
91
+ observeAttribute: boolean;
92
+ reflect: boolean;
93
+ taskQueue: boolean;
94
+ }
95
+ export interface BuildConditionals extends Partial<BuildFeatures> {
96
+ hotModuleReplacement?: boolean;
97
+ isDebug?: boolean;
98
+ isTesting?: boolean;
99
+ isDev?: boolean;
100
+ devTools?: boolean;
101
+ hydrateServerSide?: boolean;
102
+ hydrateClientSide?: boolean;
103
+ lifecycleDOMEvents?: boolean;
104
+ cssAnnotations?: boolean;
105
+ lazyLoad?: boolean;
106
+ profile?: boolean;
107
+ cssVarShim?: boolean;
108
+ constructableCSS?: boolean;
109
+ appendChildSlotFix?: boolean;
110
+ slotChildNodesFix?: boolean;
111
+ cloneNodeFix?: boolean;
112
+ dynamicImportShim?: boolean;
113
+ hydratedAttribute?: boolean;
114
+ hydratedClass?: boolean;
115
+ initializeNextTick?: boolean;
116
+ safari10?: boolean;
117
+ scriptDataOpts?: boolean;
118
+ shadowDomShim?: boolean;
119
+ asyncQueue?: boolean;
120
+ transformTagName?: boolean;
121
+ attachStyles?: boolean;
122
+ }
123
+ export declare type ModuleFormat = 'amd' | 'cjs' | 'es' | 'iife' | 'system' | 'umd' | 'commonjs' | 'esm' | 'module' | 'systemjs';
124
+ export interface RollupResultModule {
125
+ id: string;
126
+ }
127
+ export interface RollupResults {
128
+ modules: RollupResultModule[];
129
+ }
130
+ export interface BuildCtx {
131
+ buildId: number;
132
+ buildResults: CompilerBuildResults;
133
+ buildMessages: string[];
134
+ bundleBuildCount: number;
135
+ collections: Collection[];
136
+ compilerCtx: CompilerCtx;
137
+ components: ComponentCompilerMeta[];
138
+ componentGraph: Map<string, string[]>;
139
+ config: Config;
140
+ createTimeSpan(msg: string, debug?: boolean): LoggerTimeSpan;
141
+ data: any;
142
+ debug: (msg: string) => void;
143
+ diagnostics: Diagnostic[];
144
+ dirsAdded: string[];
145
+ dirsDeleted: string[];
146
+ entryModules: EntryModule[];
147
+ filesAdded: string[];
148
+ filesChanged: string[];
149
+ filesDeleted: string[];
150
+ filesUpdated: string[];
151
+ filesWritten: string[];
152
+ globalStyle: string | undefined;
153
+ hasConfigChanges: boolean;
154
+ hasError: boolean;
155
+ hasFinished: boolean;
156
+ hasHtmlChanges: boolean;
157
+ hasPrintedResults: boolean;
158
+ hasServiceWorkerChanges: boolean;
159
+ hasScriptChanges: boolean;
160
+ hasStyleChanges: boolean;
161
+ hasWarning: boolean;
162
+ hydrateAppFilePath: string;
163
+ indexBuildCount: number;
164
+ indexDoc: Document;
165
+ isRebuild: boolean;
166
+ moduleFiles: Module[];
167
+ packageJson: PackageJsonData;
168
+ pendingCopyTasks: Promise<CopyResults>[];
169
+ progress(task: BuildTask): void;
170
+ requiresFullBuild: boolean;
171
+ rollupResults?: RollupResults;
172
+ scriptsAdded: string[];
173
+ scriptsDeleted: string[];
174
+ startTime: number;
175
+ styleBuildCount: number;
176
+ stylesPromise: Promise<void>;
177
+ stylesUpdated: BuildStyleUpdate[];
178
+ timeSpan: LoggerTimeSpan;
179
+ timestamp: string;
180
+ transpileBuildCount: number;
181
+ validateTypesBuild?(): Promise<void>;
182
+ validateTypesHandler?: (results: any) => Promise<void>;
183
+ validateTypesPromise?: Promise<any>;
184
+ }
185
+ export interface BuildStyleUpdate {
186
+ styleTag: string;
187
+ styleText: string;
188
+ styleMode: string;
189
+ }
190
+ export declare type BuildTask = any;
191
+ export declare type BuildStatus = 'pending' | 'error' | 'disabled' | 'default';
192
+ export interface BuildStats {
193
+ compiler: {
194
+ name: string;
195
+ version: string;
196
+ };
197
+ app: {
198
+ namespace: string;
199
+ fsNamespace: string;
200
+ components: number;
201
+ entries: number;
202
+ bundles: number;
203
+ };
204
+ options: {
205
+ minifyJs: boolean;
206
+ minifyCss: boolean;
207
+ hashFileNames: boolean;
208
+ hashedFileNameLength: number;
209
+ buildEs5: boolean;
210
+ };
211
+ components: BuildComponent[];
212
+ entries: BuildEntry[];
213
+ rollupResults: RollupResults;
214
+ sourceGraph: BuildSourceGraph;
215
+ collections: {
216
+ name: string;
217
+ source: string;
218
+ tags: string[];
219
+ }[];
220
+ }
221
+ export interface BuildEntry {
222
+ entryId: string;
223
+ components: BuildComponent[];
224
+ bundles: BuildBundle[];
225
+ inputs: string[];
226
+ modes?: string[];
227
+ encapsulations: Encapsulation[];
228
+ }
229
+ export interface BuildBundle {
230
+ fileName: string;
231
+ outputs: string[];
232
+ size?: number;
233
+ mode?: string;
234
+ scopedStyles?: boolean;
235
+ target?: string;
236
+ }
237
+ export interface BuildSourceGraph {
238
+ [filePath: string]: string[];
239
+ }
240
+ export interface BuildComponent {
241
+ tag: string;
242
+ dependencyOf?: string[];
243
+ dependencies?: string[];
244
+ }
245
+ export interface BundleOutputChunk {
246
+ code: string;
247
+ fileName: string;
248
+ isDynamicEntry: boolean;
249
+ isEntry: boolean;
250
+ map: any;
251
+ dynamicImports: string[];
252
+ imports: string[];
253
+ exports: string[];
254
+ modules: {
255
+ [modulePath: string]: {
256
+ renderedExports: string[];
257
+ removedExports: string[];
258
+ renderedLength: number;
259
+ originalLength: number;
260
+ };
261
+ };
262
+ name: string;
263
+ }
264
+ export declare type SourceTarget = 'es5' | 'es2017' | 'latest';
265
+ export interface BundleEntryInputs {
266
+ [entryKey: string]: string;
267
+ }
268
+ export declare type RollupResult = RollupChunkResult | RollupAssetResult;
269
+ export interface RollupAssetResult {
270
+ type: 'asset';
271
+ fileName: string;
272
+ content: string;
273
+ }
274
+ export interface RollupChunkResult {
275
+ type: 'chunk';
276
+ entryKey: string;
277
+ fileName: string;
278
+ code: string;
279
+ isEntry: boolean;
280
+ isComponent: boolean;
281
+ isCore: boolean;
282
+ isIndex: boolean;
283
+ isBrowserLoader: boolean;
284
+ imports: string[];
285
+ moduleFormat: ModuleFormat;
286
+ }
287
+ export interface BundleModule {
288
+ entryKey: string;
289
+ rollupResult: RollupChunkResult;
290
+ cmps: ComponentCompilerMeta[];
291
+ output: BundleModuleOutput;
292
+ }
293
+ export interface BundleModuleOutput {
294
+ bundleId: string;
295
+ fileName: string;
296
+ code: string;
297
+ }
298
+ export interface Cache {
299
+ get(key: string): Promise<string>;
300
+ put(key: string, value: string): Promise<boolean>;
301
+ has(key: string): Promise<boolean>;
302
+ createKey(domain: string, ...args: any[]): Promise<string>;
303
+ commit(): Promise<void>;
304
+ clear(): void;
305
+ clearDiskCache(): Promise<void>;
306
+ getMemoryStats(): string;
307
+ initCacheDir(): Promise<void>;
308
+ }
309
+ export interface CollectionCompilerMeta {
310
+ collectionName?: string;
311
+ moduleId?: string;
312
+ moduleDir?: string;
313
+ moduleFiles?: Module[];
314
+ global?: Module;
315
+ compiler?: CollectionCompilerVersion;
316
+ isInitialized?: boolean;
317
+ hasExports?: boolean;
318
+ dependencies?: string[];
319
+ bundles?: {
320
+ components: string[];
321
+ }[];
322
+ }
323
+ export interface CollectionCompilerVersion {
324
+ name: string;
325
+ version: string;
326
+ typescriptVersion?: string;
327
+ }
328
+ export interface CollectionManifest {
329
+ entries?: CollectionComponentEntryPath[];
330
+ collections?: CollectionDependencyManifest[];
331
+ global?: string;
332
+ compiler?: CollectionCompilerVersion;
333
+ bundles?: CollectionBundleManifest[];
334
+ }
335
+ export declare type CollectionComponentEntryPath = string;
336
+ export interface CollectionBundleManifest {
337
+ components: string[];
338
+ }
339
+ export interface CollectionDependencyManifest {
340
+ name: string;
341
+ tags: string[];
342
+ }
343
+ /** OLD WAY */
344
+ export interface Collection {
345
+ collectionName?: string;
346
+ moduleDir?: string;
347
+ moduleFiles?: any[];
348
+ global?: any;
349
+ compiler?: CollectionCompiler;
350
+ isInitialized?: boolean;
351
+ hasExports?: boolean;
352
+ dependencies?: string[];
353
+ bundles?: {
354
+ components: string[];
355
+ }[];
356
+ }
357
+ export interface CollectionCompiler {
358
+ name: string;
359
+ version: string;
360
+ typescriptVersion?: string;
361
+ }
362
+ export interface AppRegistry {
363
+ namespace?: string;
364
+ fsNamespace?: string;
365
+ loader?: string;
366
+ core?: string;
367
+ corePolyfilled?: string;
368
+ global?: string;
369
+ components?: AppRegistryComponents;
370
+ }
371
+ export interface AppRegistryComponents {
372
+ [tagName: string]: {
373
+ bundleIds: ModeBundleIds;
374
+ encapsulation?: 'shadow' | 'scoped';
375
+ };
376
+ }
377
+ /** OLD WAY */
378
+ export interface ModuleFile {
379
+ sourceFilePath: string;
380
+ jsFilePath?: string;
381
+ dtsFilePath?: string;
382
+ cmpMeta?: any;
383
+ isCollectionDependency?: boolean;
384
+ excludeFromCollection?: boolean;
385
+ originalCollectionComponentPath?: string;
386
+ externalImports?: string[];
387
+ localImports?: string[];
388
+ potentialCmpRefs?: string[];
389
+ hasSlot?: boolean;
390
+ hasSvg?: boolean;
391
+ }
392
+ export interface ModuleBundles {
393
+ [bundleId: string]: string;
394
+ }
395
+ export interface CollectionData {
396
+ components?: ComponentData[];
397
+ collections?: CollectionDependencyData[];
398
+ global?: string;
399
+ modules?: string[];
400
+ compiler?: {
401
+ name: string;
402
+ version: string;
403
+ typescriptVersion?: string;
404
+ };
405
+ bundles?: CollectionBundle[];
406
+ }
407
+ export interface CollectionBundle {
408
+ components: string[];
409
+ }
410
+ export interface CollectionDependencyData {
411
+ name: string;
412
+ tags: string[];
413
+ }
414
+ export interface ComponentData {
415
+ tag?: string;
416
+ componentPath?: string;
417
+ componentClass?: string;
418
+ dependencies?: string[];
419
+ styles?: StylesData;
420
+ props?: PropData[];
421
+ states?: StateData[];
422
+ listeners?: ListenerData[];
423
+ methods?: MethodData[];
424
+ events?: EventData[];
425
+ connect?: ConnectData[];
426
+ context?: ContextData[];
427
+ hostElement?: HostElementData;
428
+ host?: any;
429
+ assetPaths?: string[];
430
+ slot?: 'hasSlots' | 'hasNamedSlots';
431
+ shadow?: boolean;
432
+ scoped?: boolean;
433
+ priority?: 'low';
434
+ }
435
+ export interface StylesData {
436
+ [modeName: string]: StyleData;
437
+ }
438
+ export interface StyleData {
439
+ stylePaths?: string[];
440
+ style?: string;
441
+ }
442
+ export interface PropData {
443
+ name?: string;
444
+ type?: 'Boolean' | 'Number' | 'String' | 'Any';
445
+ mutable?: boolean;
446
+ attr?: string;
447
+ reflectToAttr?: boolean;
448
+ watch?: string[];
449
+ }
450
+ export interface StateData {
451
+ name: string;
452
+ }
453
+ export interface ListenerData {
454
+ event: string;
455
+ method: string;
456
+ capture?: boolean;
457
+ passive?: boolean;
458
+ enabled?: boolean;
459
+ }
460
+ export interface MethodData {
461
+ name: string;
462
+ }
463
+ export interface EventData {
464
+ event: string;
465
+ method?: string;
466
+ bubbles?: boolean;
467
+ cancelable?: boolean;
468
+ composed?: boolean;
469
+ }
470
+ export interface ConnectData {
471
+ name: string;
472
+ tag?: string;
473
+ }
474
+ export interface ContextData {
475
+ name: string;
476
+ id?: string;
477
+ }
478
+ export interface HostElementData {
479
+ name: string;
480
+ }
481
+ export interface BuildOutputFile {
482
+ name: string;
483
+ content: string;
484
+ }
485
+ export declare type OnCallback = (buildStart: CompilerBuildStart) => void;
486
+ export declare type RemoveCallback = () => boolean;
487
+ export interface CompilerCtx {
488
+ version: number;
489
+ activeBuildId: number;
490
+ activeDirsAdded: string[];
491
+ activeDirsDeleted: string[];
492
+ activeFilesAdded: string[];
493
+ activeFilesDeleted: string[];
494
+ activeFilesUpdated: string[];
495
+ addWatchDir: (path: string, recursive: boolean) => void;
496
+ addWatchFile: (path: string) => void;
497
+ cache: Cache;
498
+ cssModuleImports: Map<string, string[]>;
499
+ cachedGlobalStyle: string;
500
+ collections: CollectionCompilerMeta[];
501
+ compilerOptions: any;
502
+ events: BuildEvents;
503
+ fs: InMemoryFileSystem;
504
+ hasSuccessfulBuild: boolean;
505
+ isActivelyBuilding: boolean;
506
+ lastBuildResults: CompilerBuildResults;
507
+ moduleMap: ModuleMap;
508
+ nodeMap: NodeMap;
509
+ resolvedCollections: Set<string>;
510
+ rollupCacheHydrate: any;
511
+ rollupCacheLazy: any;
512
+ rollupCacheNative: any;
513
+ styleModeNames: Set<string>;
514
+ changedModules: Set<string>;
515
+ changedFiles: Set<string>;
516
+ worker?: CompilerWorkerContext;
517
+ rollupCache: Map<string, any>;
518
+ reset(): void;
519
+ }
520
+ export declare type NodeMap = WeakMap<any, ComponentCompilerMeta>;
521
+ /** Must be serializable to JSON!! */
522
+ export interface ComponentCompilerFeatures {
523
+ hasAttribute: boolean;
524
+ hasAttributeChangedCallbackFn: boolean;
525
+ hasComponentWillLoadFn: boolean;
526
+ hasComponentDidLoadFn: boolean;
527
+ hasComponentShouldUpdateFn: boolean;
528
+ hasComponentWillUpdateFn: boolean;
529
+ hasComponentDidUpdateFn: boolean;
530
+ hasComponentWillRenderFn: boolean;
531
+ hasComponentDidRenderFn: boolean;
532
+ hasComponentDidUnloadFn: boolean;
533
+ hasConnectedCallbackFn: boolean;
534
+ hasDisconnectedCallbackFn: boolean;
535
+ hasElement: boolean;
536
+ hasEvent: boolean;
537
+ hasLifecycle: boolean;
538
+ hasListener: boolean;
539
+ hasListenerTarget: boolean;
540
+ hasListenerTargetWindow: boolean;
541
+ hasListenerTargetDocument: boolean;
542
+ hasListenerTargetBody: boolean;
543
+ /**
544
+ * @deprecated Prevented from new apps, but left in for older collections
545
+ */
546
+ hasListenerTargetParent: boolean;
547
+ hasMember: boolean;
548
+ hasMethod: boolean;
549
+ hasMode: boolean;
550
+ hasProp: boolean;
551
+ hasPropBoolean: boolean;
552
+ hasPropNumber: boolean;
553
+ hasPropString: boolean;
554
+ hasPropMutable: boolean;
555
+ hasReflect: boolean;
556
+ hasRenderFn: boolean;
557
+ hasState: boolean;
558
+ hasStyle: boolean;
559
+ hasVdomAttribute: boolean;
560
+ hasVdomClass: boolean;
561
+ hasVdomFunctional: boolean;
562
+ hasVdomKey: boolean;
563
+ hasVdomListener: boolean;
564
+ hasVdomPropOrAttr: boolean;
565
+ hasVdomRef: boolean;
566
+ hasVdomRender: boolean;
567
+ hasVdomStyle: boolean;
568
+ hasVdomText: boolean;
569
+ hasVdomXlink: boolean;
570
+ hasWatchCallback: boolean;
571
+ htmlAttrNames: string[];
572
+ htmlTagNames: string[];
573
+ htmlParts: string[];
574
+ isUpdateable: boolean;
575
+ isPlain: boolean;
576
+ potentialCmpRefs: string[];
577
+ }
578
+ /** Must be serializable to JSON!! */
579
+ export interface ComponentCompilerMeta extends ComponentCompilerFeatures {
580
+ assetsDirs: CompilerAssetDir[];
581
+ componentClassName: string;
582
+ elementRef: string;
583
+ encapsulation: Encapsulation;
584
+ shadowDelegatesFocus: boolean;
585
+ excludeFromCollection: boolean;
586
+ isCollectionDependency: boolean;
587
+ docs: CompilerJsDoc;
588
+ jsFilePath: string;
589
+ listeners: ComponentCompilerListener[];
590
+ events: ComponentCompilerEvent[];
591
+ methods: ComponentCompilerMethod[];
592
+ virtualProperties: ComponentCompilerVirtualProperty[];
593
+ properties: ComponentCompilerProperty[];
594
+ watchers: ComponentCompilerWatch[];
595
+ sourceFilePath: string;
596
+ states: ComponentCompilerState[];
597
+ styleDocs: CompilerStyleDoc[];
598
+ styles: StyleCompiler[];
599
+ tagName: string;
600
+ internal: boolean;
601
+ legacyConnect: ComponentCompilerLegacyConnect[];
602
+ legacyContext: ComponentCompilerLegacyContext[];
603
+ dependencies?: string[];
604
+ dependents?: string[];
605
+ directDependencies?: string[];
606
+ directDependents?: string[];
607
+ }
608
+ export interface ComponentCompilerLegacyConnect {
609
+ name: string;
610
+ connect: string;
611
+ }
612
+ export interface ComponentCompilerLegacyContext {
613
+ name: string;
614
+ context: string;
615
+ }
616
+ export declare type Encapsulation = 'shadow' | 'scoped' | 'none';
617
+ export interface ComponentCompilerStaticProperty {
618
+ mutable: boolean;
619
+ optional: boolean;
620
+ required: boolean;
621
+ type: ComponentCompilerPropertyType;
622
+ complexType: ComponentCompilerPropertyComplexType;
623
+ attribute?: string;
624
+ reflect?: boolean;
625
+ docs: CompilerJsDoc;
626
+ defaultValue?: string;
627
+ }
628
+ export interface ComponentCompilerProperty extends ComponentCompilerStaticProperty {
629
+ name: string;
630
+ internal: boolean;
631
+ }
632
+ export interface ComponentCompilerVirtualProperty {
633
+ name: string;
634
+ type: string;
635
+ docs: string;
636
+ }
637
+ export declare type ComponentCompilerPropertyType = 'any' | 'string' | 'boolean' | 'number' | 'unknown';
638
+ export interface ComponentCompilerPropertyComplexType {
639
+ original: string;
640
+ resolved: string;
641
+ references: ComponentCompilerTypeReferences;
642
+ }
643
+ export interface ComponentCompilerTypeReferences {
644
+ [key: string]: ComponentCompilerTypeReference;
645
+ }
646
+ export interface ComponentCompilerTypeReference {
647
+ location: 'local' | 'global' | 'import';
648
+ path?: string;
649
+ }
650
+ export interface ComponentCompilerStaticEvent {
651
+ name: string;
652
+ method: string;
653
+ bubbles: boolean;
654
+ cancelable: boolean;
655
+ composed: boolean;
656
+ docs: CompilerJsDoc;
657
+ complexType: ComponentCompilerEventComplexType;
658
+ }
659
+ export interface ComponentCompilerEvent extends ComponentCompilerStaticEvent {
660
+ internal: boolean;
661
+ }
662
+ export interface ComponentCompilerEventComplexType {
663
+ original: string;
664
+ resolved: string;
665
+ references: ComponentCompilerTypeReferences;
666
+ }
667
+ export interface ComponentCompilerListener {
668
+ name: string;
669
+ method: string;
670
+ capture: boolean;
671
+ passive: boolean;
672
+ target: ListenTargetOptions | undefined;
673
+ }
674
+ export interface ComponentCompilerStaticMethod {
675
+ docs: CompilerJsDoc;
676
+ complexType: ComponentCompilerMethodComplexType;
677
+ }
678
+ export interface ComponentCompilerMethodComplexType {
679
+ signature: string;
680
+ parameters: CompilerJsDoc[];
681
+ references: ComponentCompilerTypeReferences;
682
+ return: string;
683
+ }
684
+ export interface ComponentCompilerWatch {
685
+ propName: string;
686
+ methodName: string;
687
+ }
688
+ export interface ComponentCompilerMethod extends ComponentCompilerStaticMethod {
689
+ name: string;
690
+ internal: boolean;
691
+ }
692
+ export interface ComponentCompilerState {
693
+ name: string;
694
+ }
695
+ export interface CompilerJsDoc {
696
+ text: string;
697
+ tags: CompilerJsDocTagInfo[];
698
+ }
699
+ export interface CompilerJsDocTagInfo {
700
+ name: string;
701
+ text?: string;
702
+ }
703
+ export interface CompilerStyleDoc {
704
+ name: string;
705
+ docs: string;
706
+ annotation: 'prop';
707
+ }
708
+ export interface CompilerAssetDir {
709
+ absolutePath?: string;
710
+ cmpRelativePath?: string;
711
+ originalComponentPath?: string;
712
+ }
713
+ export interface ComponentCompilerData {
714
+ exportLine: string;
715
+ filePath: string;
716
+ cmp: ComponentCompilerMeta;
717
+ uniqueComponentClassName?: string;
718
+ importLine?: string;
719
+ }
720
+ export interface ComponentConstructor {
721
+ is?: string;
722
+ properties?: ComponentConstructorProperties;
723
+ watchers?: ComponentConstructorWatchers;
724
+ events?: ComponentConstructorEvent[];
725
+ listeners?: ComponentConstructorListener[];
726
+ style?: string;
727
+ styleId?: string;
728
+ encapsulation?: ComponentConstructorEncapsulation;
729
+ observedAttributes?: string[];
730
+ cmpMeta?: ComponentRuntimeMeta;
731
+ isProxied?: boolean;
732
+ isStyleRegistered?: boolean;
733
+ }
734
+ export interface ComponentConstructorWatchers {
735
+ [propName: string]: string[];
736
+ }
737
+ export interface ComponentTestingConstructor extends ComponentConstructor {
738
+ COMPILER_META: ComponentCompilerMeta;
739
+ prototype?: {
740
+ componentWillLoad?: Function;
741
+ componentWillUpdate?: Function;
742
+ componentWillRender?: Function;
743
+ __componentWillLoad?: Function;
744
+ __componentWillUpdate?: Function;
745
+ __componentWillRender?: Function;
746
+ };
747
+ }
748
+ export interface ComponentNativeConstructor extends ComponentConstructor {
749
+ cmpMeta: ComponentRuntimeMeta;
750
+ }
751
+ export declare type ComponentConstructorEncapsulation = 'shadow' | 'scoped' | 'none';
752
+ export interface ComponentConstructorProperties {
753
+ [propName: string]: ComponentConstructorProperty;
754
+ }
755
+ export interface ComponentConstructorProperty {
756
+ attribute?: string;
757
+ elementRef?: boolean;
758
+ method?: boolean;
759
+ mutable?: boolean;
760
+ reflect?: boolean;
761
+ state?: boolean;
762
+ type?: ComponentConstructorPropertyType;
763
+ watchCallbacks?: string[];
764
+ }
765
+ export declare type ComponentConstructorPropertyType = StringConstructor | BooleanConstructor | NumberConstructor | 'string' | 'boolean' | 'number';
766
+ export interface ComponentConstructorEvent {
767
+ name: string;
768
+ method: string;
769
+ bubbles: boolean;
770
+ cancelable: boolean;
771
+ composed: boolean;
772
+ }
773
+ export interface ComponentConstructorListener {
774
+ name: string;
775
+ method: string;
776
+ capture?: boolean;
777
+ passive?: boolean;
778
+ }
779
+ export interface HostConfig {
780
+ hosting?: {
781
+ rules?: HostRule[];
782
+ };
783
+ }
784
+ export interface HostRule {
785
+ include: string;
786
+ headers: HostRuleHeader[];
787
+ }
788
+ export interface HostRuleHeader {
789
+ name?: string;
790
+ value?: string;
791
+ }
792
+ export interface CssVarShim {
793
+ i(): Promise<any>;
794
+ addLink(linkEl: HTMLLinkElement): Promise<any>;
795
+ addGlobalStyle(styleEl: HTMLStyleElement): void;
796
+ createHostStyle(hostEl: HTMLElement, templateName: string, cssText: string, isScoped: boolean): HTMLStyleElement;
797
+ removeHost(hostEl: HTMLElement): void;
798
+ updateHost(hostEl: HTMLElement): void;
799
+ updateGlobal(): void;
800
+ }
801
+ export interface DevClientWindow extends Window {
802
+ ['s-dev-server']: boolean;
803
+ ['s-initial-load']: boolean;
804
+ ['s-build-id']: number;
805
+ WebSocket: new (socketUrl: string, protos: string[]) => WebSocket;
806
+ devServerConfig?: DevClientConfig;
807
+ }
808
+ export interface DevClientConfig {
809
+ basePath: string;
810
+ editors: DevServerEditor[];
811
+ reloadStrategy: PageReloadStrategy;
812
+ socketUrl?: string;
813
+ }
814
+ export interface HttpRequest {
815
+ method: 'GET' | 'POST' | 'PUT' | 'DELETE' | 'HEAD' | 'OPTIONS';
816
+ acceptHeader: string;
817
+ url: URL;
818
+ searchParams: URLSearchParams;
819
+ pathname?: string;
820
+ filePath?: string;
821
+ stats?: CompilerFsStats;
822
+ headers?: {
823
+ [name: string]: string;
824
+ };
825
+ host?: string;
826
+ }
827
+ export interface DevServerMessage {
828
+ startServer?: DevServerConfig;
829
+ closeServer?: boolean;
830
+ serverStarted?: DevServerConfig;
831
+ serverClosed?: boolean;
832
+ buildStart?: boolean;
833
+ buildLog?: BuildLog;
834
+ buildResults?: CompilerBuildResults;
835
+ requestBuildResults?: boolean;
836
+ error?: {
837
+ message?: string;
838
+ type?: string;
839
+ stack?: any;
840
+ };
841
+ isActivelyBuilding?: boolean;
842
+ compilerRequestPath?: string;
843
+ compilerRequestResults?: CompilerRequestResponse;
844
+ requestLog?: {
845
+ method: string;
846
+ url: string;
847
+ status: number;
848
+ };
849
+ }
850
+ export declare type DevServerSendMessage = (msg: DevServerMessage) => void;
851
+ export interface DevServerContext {
852
+ connectorHtml: string;
853
+ dirTemplate: string;
854
+ getBuildResults: () => Promise<CompilerBuildResults>;
855
+ getCompilerRequest: (path: string) => Promise<CompilerRequestResponse>;
856
+ isServerListening: boolean;
857
+ logRequest: (req: {
858
+ method: string;
859
+ pathname?: string;
860
+ }, status: number) => void;
861
+ prerenderConfig: PrerenderConfig;
862
+ serve302: (req: any, res: any, pathname?: string) => void;
863
+ serve404: (req: any, res: any, xSource: string, content?: string) => void;
864
+ serve500: (req: any, res: any, error: any, xSource: string) => void;
865
+ sys: CompilerSystem;
866
+ }
867
+ export declare type InitServerProcess = (sendMsg: (msg: DevServerMessage) => void) => (msg: DevServerMessage) => void;
868
+ export interface DevResponseHeaders {
869
+ 'cache-control'?: string;
870
+ 'expires'?: string;
871
+ 'content-type'?: string;
872
+ 'content-length'?: number;
873
+ 'date'?: string;
874
+ 'access-control-allow-origin'?: string;
875
+ 'access-control-expose-headers'?: string;
876
+ 'content-encoding'?: 'gzip';
877
+ 'vary'?: 'Accept-Encoding';
878
+ 'server'?: string;
879
+ 'x-directory-index'?: string;
880
+ 'x-source'?: string;
881
+ }
882
+ export interface OpenInEditorData {
883
+ file?: string;
884
+ line?: number;
885
+ column?: number;
886
+ open?: string;
887
+ editor?: string;
888
+ exists?: boolean;
889
+ error?: string;
890
+ }
891
+ export interface EntryModule {
892
+ entryKey: string;
893
+ cmps: ComponentCompilerMeta[];
894
+ }
895
+ export interface EntryBundle {
896
+ fileName: string;
897
+ text: string;
898
+ outputs: string[];
899
+ modeName: string;
900
+ isScopedStyles: boolean;
901
+ sourceTarget: string;
902
+ }
903
+ export interface EntryComponent {
904
+ tag: string;
905
+ dependencyOf?: string[];
906
+ }
907
+ export interface ComponentRef {
908
+ tag: string;
909
+ filePath: string;
910
+ }
911
+ export interface ModuleGraph {
912
+ filePath: string;
913
+ importPaths: string[];
914
+ }
915
+ export interface AddEventListener {
916
+ (elm: Element | Document | Window, eventName: string, cb: EventListenerCallback, opts?: ListenOptions): Function;
917
+ }
918
+ export interface EventListenerCallback {
919
+ (ev?: any): void;
920
+ }
921
+ export interface EventEmitterData<T = any> {
922
+ detail?: T;
923
+ bubbles?: boolean;
924
+ cancelable?: boolean;
925
+ composed?: boolean;
926
+ }
927
+ export interface FsReadOptions {
928
+ useCache?: boolean;
929
+ setHash?: boolean;
930
+ }
931
+ export interface FsReaddirOptions {
932
+ inMemoryOnly?: boolean;
933
+ recursive?: boolean;
934
+ /**
935
+ * Directory names to exclude. Just the basename,
936
+ * not the entire path. Basically for "node_moduels".
937
+ */
938
+ excludeDirNames?: string[];
939
+ /**
940
+ * Extensions we know we can avoid. Each extension
941
+ * should include the `.` so that we can test for both
942
+ * `.d.ts.` and `.ts`. If `excludeExtensions` isn't provided it
943
+ * doesn't try to exclude anything. This only checks against
944
+ * the filename, not directory names when recursive.
945
+ */
946
+ excludeExtensions?: string[];
947
+ }
948
+ export interface FsReaddirItem {
949
+ absPath: string;
950
+ relPath: string;
951
+ isDirectory: boolean;
952
+ isFile: boolean;
953
+ }
954
+ export interface FsWriteResults {
955
+ changedContent: boolean;
956
+ queuedWrite: boolean;
957
+ ignored: boolean;
958
+ }
959
+ export declare type FsItems = Map<string, FsItem>;
960
+ export interface FsItem {
961
+ fileText: string;
962
+ isFile: boolean;
963
+ isDirectory: boolean;
964
+ size: number;
965
+ mtimeMs: number;
966
+ exists: boolean;
967
+ queueCopyFileToDest: string;
968
+ queueWriteToDisk: boolean;
969
+ queueDeleteFromDisk?: boolean;
970
+ useCache: boolean;
971
+ }
972
+ export interface HostElement extends HTMLElement {
973
+ connectedCallback?: () => void;
974
+ attributeChangedCallback?: (attribName: string, oldVal: string, newVal: string, namespace: string) => void;
975
+ disconnectedCallback?: () => void;
976
+ host?: Element;
977
+ forceUpdate?: () => void;
978
+ /**
979
+ * Unique rindo id for this element
980
+ */
981
+ ['s-id']?: string;
982
+ /**
983
+ * Content Reference:
984
+ * Reference to the HTML Comment that's placed inside of the
985
+ * host element's original content. This comment is used to
986
+ * always represent where host element's light dom is.
987
+ */
988
+ ['s-cr']?: RenderNode;
989
+ /**
990
+ * Lifecycle ready
991
+ */
992
+ ['s-lr']?: boolean;
993
+ /**
994
+ * On Render Callbacks:
995
+ * Array of callbacks to fire off after it has rendered.
996
+ */
997
+ ['s-rc']?: (() => void)[];
998
+ /**
999
+ * Scope Id
1000
+ * The scope id of this component when using scoped css encapsulation
1001
+ * or using shadow dom but the browser doesn't support it
1002
+ */
1003
+ ['s-sc']?: string;
1004
+ /**
1005
+ * Hot Module Replacement, dev mode only
1006
+ */
1007
+ ['s-hmr']?: (versionId: string) => void;
1008
+ /**
1009
+ * Callback method for when HMR finishes
1010
+ */
1011
+ ['s-hmr-load']?: () => void;
1012
+ ['s-p']?: Promise<void>[];
1013
+ componentOnReady?: () => Promise<this>;
1014
+ }
1015
+ export interface InMemoryFileSystem {
1016
+ sys?: CompilerSystem;
1017
+ accessData(filePath: string): Promise<{
1018
+ exists: boolean;
1019
+ isDirectory: boolean;
1020
+ isFile: boolean;
1021
+ }>;
1022
+ access(filePath: string): Promise<boolean>;
1023
+ /**
1024
+ * Synchronous!!! Do not use!!!
1025
+ * (Only typescript transpiling is allowed to use)
1026
+ * @param filePath
1027
+ */
1028
+ accessSync(filePath: string): boolean;
1029
+ copyFile(srcFile: string, dest: string): Promise<void>;
1030
+ emptyDirs(dirPaths: string[]): Promise<void>;
1031
+ readdir(dirPath: string, opts?: FsReaddirOptions): Promise<FsReaddirItem[]>;
1032
+ readFile(filePath: string, opts?: FsReadOptions): Promise<string>;
1033
+ /**
1034
+ * Synchronous!!! Do not use!!!
1035
+ * (Only typescript transpiling is allowed to use)
1036
+ * @param filePath
1037
+ */
1038
+ readFileSync(filePath: string, opts?: FsReadOptions): string;
1039
+ remove(itemPath: string): Promise<void>;
1040
+ stat(itemPath: string): Promise<{
1041
+ isFile: boolean;
1042
+ isDirectory: boolean;
1043
+ }>;
1044
+ /**
1045
+ * Synchronous!!! Do not use!!!
1046
+ * (Only typescript transpiling is allowed to use)
1047
+ * @param itemPath
1048
+ */
1049
+ statSync(itemPath: string): {
1050
+ exists: boolean;
1051
+ isFile: boolean;
1052
+ isDirectory: boolean;
1053
+ };
1054
+ writeFile(filePath: string, content: string, opts?: FsWriteOptions): Promise<FsWriteResults>;
1055
+ writeFiles(files: {
1056
+ [filePath: string]: string;
1057
+ } | Map<string, String>, opts?: FsWriteOptions): Promise<FsWriteResults[]>;
1058
+ commit(): Promise<{
1059
+ filesWritten: string[];
1060
+ filesDeleted: string[];
1061
+ filesCopied: string[][];
1062
+ dirsDeleted: string[];
1063
+ dirsAdded: string[];
1064
+ }>;
1065
+ cancelDeleteFilesFromDisk(filePaths: string[]): void;
1066
+ cancelDeleteDirectoriesFromDisk(filePaths: string[]): void;
1067
+ clearDirCache(dirPath: string): void;
1068
+ clearFileCache(filePath: string): void;
1069
+ getItem(itemPath: string): FsItem;
1070
+ getBuildOutputs(): BuildOutput[];
1071
+ clearCache(): void;
1072
+ keys(): string[];
1073
+ getMemoryStats(): string;
1074
+ }
1075
+ export interface HydrateResults {
1076
+ buildId: string;
1077
+ diagnostics: Diagnostic[];
1078
+ url: string;
1079
+ host: string;
1080
+ hostname: string;
1081
+ href: string;
1082
+ port: string;
1083
+ pathname: string;
1084
+ search: string;
1085
+ hash: string;
1086
+ html: string;
1087
+ components: HydrateComponent[];
1088
+ anchors: HydrateAnchorElement[];
1089
+ imgs: HydrateImgElement[];
1090
+ scripts: HydrateScriptElement[];
1091
+ styles: HydrateStyleElement[];
1092
+ staticData: HydrateStaticData[];
1093
+ title: string;
1094
+ hydratedCount: number;
1095
+ httpStatus: number;
1096
+ }
1097
+ export interface HydrateComponent {
1098
+ tag: string;
1099
+ mode: string;
1100
+ count: number;
1101
+ depth: number;
1102
+ }
1103
+ export interface HydrateElement {
1104
+ [attrName: string]: string | undefined;
1105
+ }
1106
+ export interface HydrateAnchorElement extends HydrateElement {
1107
+ href?: string;
1108
+ target?: string;
1109
+ }
1110
+ export interface HydrateImgElement extends HydrateElement {
1111
+ src?: string;
1112
+ }
1113
+ export interface HydrateScriptElement extends HydrateElement {
1114
+ src?: string;
1115
+ type?: string;
1116
+ }
1117
+ export interface HydrateStyleElement extends HydrateElement {
1118
+ href?: string;
1119
+ }
1120
+ export interface HydrateStaticData {
1121
+ id: string;
1122
+ type: string;
1123
+ content: string;
1124
+ }
1125
+ export interface JsDoc {
1126
+ name: string;
1127
+ documentation: string;
1128
+ type: string;
1129
+ tags: JSDocTagInfo[];
1130
+ default?: string;
1131
+ parameters?: JsDoc[];
1132
+ returns?: {
1133
+ type: string;
1134
+ documentation: string;
1135
+ };
1136
+ }
1137
+ export interface JSDocTagInfo {
1138
+ name: string;
1139
+ text?: string;
1140
+ }
1141
+ export interface MinifyJsResult {
1142
+ code: string;
1143
+ sourceMap: any;
1144
+ error: {
1145
+ message: string;
1146
+ filename: string;
1147
+ line: number;
1148
+ col: number;
1149
+ pos: number;
1150
+ };
1151
+ }
1152
+ export declare type ModuleMap = Map<string, Module>;
1153
+ /**
1154
+ * Module gets serialized/parsed as JSON
1155
+ * cannot use Map or Set
1156
+ */
1157
+ export interface Module {
1158
+ cmps: ComponentCompilerMeta[];
1159
+ coreRuntimeApis: string[];
1160
+ collectionName: string;
1161
+ dtsFilePath: string;
1162
+ excludeFromCollection: boolean;
1163
+ externalImports: string[];
1164
+ htmlAttrNames: string[];
1165
+ htmlTagNames: string[];
1166
+ htmlParts: string[];
1167
+ isCollectionDependency: boolean;
1168
+ isLegacy: boolean;
1169
+ jsFilePath: string;
1170
+ localImports: string[];
1171
+ originalImports: string[];
1172
+ originalCollectionComponentPath: string;
1173
+ potentialCmpRefs: string[];
1174
+ sourceFilePath: string;
1175
+ staticSourceFile: any;
1176
+ staticSourceFileText: string;
1177
+ hasVdomAttribute: boolean;
1178
+ hasVdomClass: boolean;
1179
+ hasVdomFunctional: boolean;
1180
+ hasVdomKey: boolean;
1181
+ hasVdomListener: boolean;
1182
+ hasVdomPropOrAttr: boolean;
1183
+ hasVdomRef: boolean;
1184
+ hasVdomRender: boolean;
1185
+ hasVdomStyle: boolean;
1186
+ hasVdomText: boolean;
1187
+ hasVdomXlink: boolean;
1188
+ }
1189
+ export interface Plugin {
1190
+ name?: string;
1191
+ pluginType?: string;
1192
+ load?: (id: string, context: PluginCtx) => Promise<string> | string;
1193
+ resolveId?: (importee: string, importer: string, context: PluginCtx) => Promise<string> | string;
1194
+ transform?: (sourceText: string, id: string, context: PluginCtx) => Promise<PluginTransformResults> | PluginTransformResults | string;
1195
+ }
1196
+ export interface PluginTransformResults {
1197
+ code?: string;
1198
+ map?: string;
1199
+ id?: string;
1200
+ diagnostics?: Diagnostic[];
1201
+ dependencies?: string[];
1202
+ }
1203
+ export interface PluginCtx {
1204
+ config: Config;
1205
+ sys: CompilerSystem;
1206
+ fs: InMemoryFileSystem;
1207
+ cache: Cache;
1208
+ diagnostics: Diagnostic[];
1209
+ }
1210
+ export interface PrerenderUrlResults {
1211
+ anchorUrls: string[];
1212
+ diagnostics: Diagnostic[];
1213
+ filePath: string;
1214
+ }
1215
+ export interface PrerenderUrlRequest {
1216
+ appDir: string;
1217
+ buildId: string;
1218
+ baseUrl: string;
1219
+ componentGraphPath: string;
1220
+ devServerHostUrl: string;
1221
+ hydrateAppFilePath: string;
1222
+ isDebug: boolean;
1223
+ prerenderConfigPath: string;
1224
+ staticSite: boolean;
1225
+ templateId: string;
1226
+ url: string;
1227
+ writeToFilePath: string;
1228
+ }
1229
+ export interface PrerenderManager {
1230
+ config: Config;
1231
+ prerenderUrlWorker: (prerenderRequest: PrerenderUrlRequest) => Promise<PrerenderUrlResults>;
1232
+ devServerHostUrl: string;
1233
+ diagnostics: Diagnostic[];
1234
+ hydrateAppFilePath: string;
1235
+ isDebug: boolean;
1236
+ logCount: number;
1237
+ outputTarget: OutputTargetWww;
1238
+ prerenderConfig: PrerenderConfig;
1239
+ prerenderConfigPath: string;
1240
+ progressLogger?: LoggerLineUpdater;
1241
+ resolve: Function;
1242
+ staticSite: boolean;
1243
+ templateId: string;
1244
+ componentGraphPath: string;
1245
+ urlsProcessing: Set<string>;
1246
+ urlsPending: Set<string>;
1247
+ urlsCompleted: Set<string>;
1248
+ maxConcurrency: number;
1249
+ }
1250
+ /**
1251
+ * Generic node that represents all of the
1252
+ * different types of nodes we'd see when rendering
1253
+ */
1254
+ export interface RenderNode extends HostElement {
1255
+ /**
1256
+ * Shadow root's host
1257
+ */
1258
+ host?: Element;
1259
+ /**
1260
+ * Is Content Reference Node:
1261
+ * This node is a content reference node.
1262
+ */
1263
+ ['s-cn']?: boolean;
1264
+ /**
1265
+ * Is a slot reference node:
1266
+ * This is a node that represents where a slots
1267
+ * was originally located.
1268
+ */
1269
+ ['s-sr']?: boolean;
1270
+ /**
1271
+ * Slot name
1272
+ */
1273
+ ['s-sn']?: string;
1274
+ /**
1275
+ * Host element tag name:
1276
+ * The tag name of the host element that this
1277
+ * node was created in.
1278
+ */
1279
+ ['s-hn']?: string;
1280
+ /**
1281
+ * Original Location Reference:
1282
+ * A reference pointing to the comment
1283
+ * which represents the original location
1284
+ * before it was moved to its slot.
1285
+ */
1286
+ ['s-ol']?: RenderNode;
1287
+ /**
1288
+ * Node reference:
1289
+ * This is a reference for a original location node
1290
+ * back to the node that's been moved around.
1291
+ */
1292
+ ['s-nr']?: RenderNode;
1293
+ /**
1294
+ * Scope Id
1295
+ */
1296
+ ['s-si']?: string;
1297
+ /**
1298
+ * Host Id (hydrate only)
1299
+ */
1300
+ ['s-host-id']?: number;
1301
+ /**
1302
+ * Node Id (hydrate only)
1303
+ */
1304
+ ['s-node-id']?: number;
1305
+ /**
1306
+ * Used to know the components encapsulation.
1307
+ * empty "" for shadow, "c" from scoped
1308
+ */
1309
+ ['s-en']?: '' | /*shadow*/ 'c';
1310
+ }
1311
+ export declare type LazyBundlesRuntimeData = LazyBundleRuntimeData[];
1312
+ export declare type LazyBundleRuntimeData = [
1313
+ /** bundleIds */
1314
+ string,
1315
+ ComponentRuntimeMetaCompact[]
1316
+ ];
1317
+ export declare type ComponentRuntimeMetaCompact = [
1318
+ /** flags */
1319
+ number,
1320
+ /** tagname */
1321
+ string,
1322
+ /** members */
1323
+ {
1324
+ [memberName: string]: ComponentRuntimeMember;
1325
+ }?,
1326
+ /** listeners */
1327
+ ComponentRuntimeHostListener[]?
1328
+ ];
1329
+ export interface ComponentRuntimeMeta {
1330
+ $flags$: number;
1331
+ $tagName$: string;
1332
+ $members$?: ComponentRuntimeMembers;
1333
+ $listeners$?: ComponentRuntimeHostListener[];
1334
+ $attrsToReflect$?: [string, string][];
1335
+ $watchers$?: ComponentConstructorWatchers;
1336
+ $lazyBundleId$?: string;
1337
+ }
1338
+ export interface ComponentRuntimeMembers {
1339
+ [memberName: string]: ComponentRuntimeMember;
1340
+ }
1341
+ export declare type ComponentRuntimeMember = [
1342
+ /**
1343
+ * flags data
1344
+ */
1345
+ number,
1346
+ /**
1347
+ * attribute name to observe
1348
+ */
1349
+ string?
1350
+ ];
1351
+ export declare type ComponentRuntimeHostListener = [
1352
+ /**
1353
+ * event flags
1354
+ */
1355
+ number,
1356
+ /**
1357
+ * event name,
1358
+ */
1359
+ string,
1360
+ /**
1361
+ * event method,
1362
+ */
1363
+ string
1364
+ ];
1365
+ export declare type ModeBundleId = ModeBundleIds | string;
1366
+ export interface ModeBundleIds {
1367
+ [modeName: string]: string;
1368
+ }
1369
+ export declare type RuntimeRef = HostElement | {};
1370
+ export interface HostRef {
1371
+ $ancestorComponent$?: HostElement;
1372
+ $flags$: number;
1373
+ $cmpMeta$: ComponentRuntimeMeta;
1374
+ $hostElement$?: HostElement;
1375
+ $instanceValues$?: Map<string, any>;
1376
+ $lazyInstance$?: ComponentInterface;
1377
+ $onReadyPromise$?: Promise<any>;
1378
+ $onReadyResolve$?: (elm: any) => void;
1379
+ $onInstancePromise$?: Promise<any>;
1380
+ $onInstanceResolve$?: (elm: any) => void;
1381
+ $onRenderResolve$?: () => void;
1382
+ $vnode$?: VNode;
1383
+ $queuedListeners$?: [string, any][];
1384
+ $rmListeners$?: (() => void)[];
1385
+ $modeName$?: string;
1386
+ $renderCount$?: number;
1387
+ }
1388
+ export interface PlatformRuntime {
1389
+ $cssShim$?: CssVarShim;
1390
+ $flags$: number;
1391
+ $orgLocNodes$?: Map<string, RenderNode>;
1392
+ $resourcesUrl$: string;
1393
+ jmp: (c: Function) => any;
1394
+ raf: (c: FrameRequestCallback) => number;
1395
+ ael: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
1396
+ rel: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
1397
+ ce: (eventName: string, opts?: any) => CustomEvent;
1398
+ }
1399
+ export declare type RefMap = WeakMap<any, HostRef>;
1400
+ export declare type StyleMap = Map<string, CSSStyleSheet | string>;
1401
+ export declare type RootAppliedStyleMap = WeakMap<Element, Set<string>>;
1402
+ export declare type AppliedStyleMap = Set<string>;
1403
+ export declare type ActivelyProcessingCmpMap = Set<Element>;
1404
+ export interface ScreenshotConnector {
1405
+ initBuild(opts: ScreenshotConnectorOptions): Promise<void>;
1406
+ completeBuild(masterBuild: ScreenshotBuild): Promise<ScreenshotBuildResults>;
1407
+ getMasterBuild(): Promise<ScreenshotBuild>;
1408
+ pullMasterBuild(): Promise<void>;
1409
+ publishBuild(buildResults: ScreenshotBuildResults): Promise<ScreenshotBuildResults>;
1410
+ getScreenshotCache(): Promise<ScreenshotCache>;
1411
+ updateScreenshotCache(screenshotCache: ScreenshotCache, buildResults: ScreenshotBuildResults): Promise<ScreenshotCache>;
1412
+ generateJsonpDataUris(build: ScreenshotBuild): Promise<void>;
1413
+ sortScreenshots(screenshots: Screenshot[]): Screenshot[];
1414
+ toJson(masterBuild: ScreenshotBuild, screenshotCache: ScreenshotCache): string;
1415
+ }
1416
+ export interface ScreenshotBuildResults {
1417
+ appNamespace: string;
1418
+ masterBuild: ScreenshotBuild;
1419
+ currentBuild: ScreenshotBuild;
1420
+ compare: ScreenshotCompareResults;
1421
+ }
1422
+ export interface ScreenshotCompareResults {
1423
+ id: string;
1424
+ a: {
1425
+ id: string;
1426
+ message: string;
1427
+ author: string;
1428
+ url: string;
1429
+ previewUrl: string;
1430
+ };
1431
+ b: {
1432
+ id: string;
1433
+ message: string;
1434
+ author: string;
1435
+ url: string;
1436
+ previewUrl: string;
1437
+ };
1438
+ timestamp: number;
1439
+ url: string;
1440
+ appNamespace: string;
1441
+ diffs: ScreenshotDiff[];
1442
+ }
1443
+ export interface ScreenshotConnectorOptions {
1444
+ buildId: string;
1445
+ buildMessage: string;
1446
+ buildAuthor?: string;
1447
+ buildUrl?: string;
1448
+ previewUrl?: string;
1449
+ appNamespace: string;
1450
+ buildTimestamp: number;
1451
+ logger: Logger;
1452
+ rootDir: string;
1453
+ cacheDir: string;
1454
+ packageDir: string;
1455
+ screenshotDirName?: string;
1456
+ imagesDirName?: string;
1457
+ buildsDirName?: string;
1458
+ currentBuildDir?: string;
1459
+ updateMaster?: boolean;
1460
+ allowableMismatchedPixels?: number;
1461
+ allowableMismatchedRatio?: number;
1462
+ pixelmatchThreshold?: number;
1463
+ waitBeforeScreenshot?: number;
1464
+ pixelmatchModulePath?: string;
1465
+ }
1466
+ export interface ScreenshotBuildData {
1467
+ buildId: string;
1468
+ rootDir: string;
1469
+ screenshotDir: string;
1470
+ imagesDir: string;
1471
+ buildsDir: string;
1472
+ currentBuildDir: string;
1473
+ updateMaster: boolean;
1474
+ allowableMismatchedPixels: number;
1475
+ allowableMismatchedRatio: number;
1476
+ pixelmatchThreshold: number;
1477
+ masterScreenshots: {
1478
+ [screenshotId: string]: string;
1479
+ };
1480
+ cache: {
1481
+ [cacheKey: string]: number;
1482
+ };
1483
+ timeoutBeforeScreenshot: number;
1484
+ pixelmatchModulePath: string;
1485
+ }
1486
+ export interface PixelMatchInput {
1487
+ imageAPath: string;
1488
+ imageBPath: string;
1489
+ width: number;
1490
+ height: number;
1491
+ pixelmatchThreshold: number;
1492
+ }
1493
+ export interface ScreenshotBuild {
1494
+ id: string;
1495
+ message: string;
1496
+ author?: string;
1497
+ url?: string;
1498
+ previewUrl?: string;
1499
+ appNamespace: string;
1500
+ timestamp: number;
1501
+ screenshots: Screenshot[];
1502
+ }
1503
+ export interface ScreenshotCache {
1504
+ timestamp?: number;
1505
+ lastBuildId?: string;
1506
+ size?: number;
1507
+ items?: {
1508
+ /**
1509
+ * Cache key
1510
+ */
1511
+ key: string;
1512
+ /**
1513
+ * Timestamp used to remove the oldest data
1514
+ */
1515
+ ts: number;
1516
+ /**
1517
+ * Mismatched pixels
1518
+ */
1519
+ mp: number;
1520
+ }[];
1521
+ }
1522
+ export interface Screenshot {
1523
+ id: string;
1524
+ desc?: string;
1525
+ image: string;
1526
+ device?: string;
1527
+ userAgent?: string;
1528
+ width?: number;
1529
+ height?: number;
1530
+ deviceScaleFactor?: number;
1531
+ hasTouch?: boolean;
1532
+ isLandscape?: boolean;
1533
+ isMobile?: boolean;
1534
+ testPath?: string;
1535
+ diff?: ScreenshotDiff;
1536
+ }
1537
+ export interface ScreenshotDiff {
1538
+ mismatchedPixels: number;
1539
+ id?: string;
1540
+ desc?: string;
1541
+ imageA?: string;
1542
+ imageB?: string;
1543
+ device?: string;
1544
+ userAgent?: string;
1545
+ width?: number;
1546
+ height?: number;
1547
+ deviceScaleFactor?: number;
1548
+ hasTouch?: boolean;
1549
+ isLandscape?: boolean;
1550
+ isMobile?: boolean;
1551
+ allowableMismatchedPixels: number;
1552
+ allowableMismatchedRatio: number;
1553
+ testPath?: string;
1554
+ cacheKey?: string;
1555
+ }
1556
+ export interface ScreenshotOptions {
1557
+ /**
1558
+ * When true, takes a screenshot of the full scrollable page.
1559
+ * Default: `false`
1560
+ */
1561
+ fullPage?: boolean;
1562
+ /**
1563
+ * An object which specifies clipping region of the page.
1564
+ */
1565
+ clip?: ScreenshotBoundingBox;
1566
+ /**
1567
+ * Hides default white background and allows capturing screenshots with transparency.
1568
+ * Default: `false`
1569
+ */
1570
+ omitBackground?: boolean;
1571
+ /**
1572
+ * Matching threshold, ranges from `0` to 1. Smaller values make the comparison
1573
+ * more sensitive. Defaults to the testing config `pixelmatchThreshold` value;
1574
+ */
1575
+ pixelmatchThreshold?: number;
1576
+ }
1577
+ export interface ScreenshotBoundingBox {
1578
+ /**
1579
+ * The x-coordinate of top-left corner.
1580
+ */
1581
+ x: number;
1582
+ /**
1583
+ * The y-coordinate of top-left corner.
1584
+ */
1585
+ y: number;
1586
+ /**
1587
+ * The width in pixels.
1588
+ */
1589
+ width: number;
1590
+ /**
1591
+ * The height in pixels.
1592
+ */
1593
+ height: number;
1594
+ }
1595
+ export interface ServerConfigInput {
1596
+ app: ExpressApp;
1597
+ configPath?: string;
1598
+ }
1599
+ export interface ServerConfigOutput {
1600
+ config: Config;
1601
+ logger: Logger;
1602
+ wwwDir: string;
1603
+ destroy?: () => void;
1604
+ }
1605
+ export interface ExpressApp {
1606
+ use?: Function;
1607
+ }
1608
+ export interface MiddlewareConfig {
1609
+ config: string | Config;
1610
+ destroy?: () => void;
1611
+ }
1612
+ export interface StyleCompiler {
1613
+ modeName: string;
1614
+ styleId: string;
1615
+ styleStr: string;
1616
+ styleIdentifier: string;
1617
+ externalStyles: ExternalStyleCompiler[];
1618
+ }
1619
+ export interface ExternalStyleCompiler {
1620
+ absolutePath: string;
1621
+ relativePath: string;
1622
+ originalComponentPath: string;
1623
+ }
1624
+ export interface CompilerModeStyles {
1625
+ [modeName: string]: string[];
1626
+ }
1627
+ export interface CssImportData {
1628
+ srcImport: string;
1629
+ updatedImport?: string;
1630
+ url: string;
1631
+ filePath?: string;
1632
+ altFilePath?: string;
1633
+ styleText?: string;
1634
+ }
1635
+ export interface CssToEsmImportData {
1636
+ srcImportText: string;
1637
+ varName: string;
1638
+ url: string;
1639
+ filePath: string;
1640
+ }
1641
+ export interface TransformCssToEsmInput {
1642
+ input: string;
1643
+ module?: 'cjs' | 'esm' | string;
1644
+ file?: string;
1645
+ tag?: string;
1646
+ encapsulation?: string;
1647
+ mode?: string;
1648
+ commentOriginalSelector?: boolean;
1649
+ sourceMap?: boolean;
1650
+ minify?: boolean;
1651
+ docs?: boolean;
1652
+ autoprefixer?: any;
1653
+ styleImportData?: string;
1654
+ }
1655
+ export interface TransformCssToEsmOutput {
1656
+ styleText: string;
1657
+ output: string;
1658
+ map: any;
1659
+ diagnostics: Diagnostic[];
1660
+ defaultVarName: string;
1661
+ styleDocs: StyleDoc[];
1662
+ imports: {
1663
+ varName: string;
1664
+ importPath: string;
1665
+ }[];
1666
+ }
1667
+ export interface PackageJsonData {
1668
+ 'name'?: string;
1669
+ 'version'?: string;
1670
+ 'main'?: string;
1671
+ 'description'?: string;
1672
+ 'bin'?: {
1673
+ [key: string]: string;
1674
+ };
1675
+ 'browser'?: string;
1676
+ 'module'?: string;
1677
+ 'jsnext:main'?: string;
1678
+ 'collection:main'?: string;
1679
+ 'unpkg'?: string;
1680
+ 'collection'?: string;
1681
+ 'types'?: string;
1682
+ 'files'?: string[];
1683
+ ['dist-tags']?: {
1684
+ latest: string;
1685
+ };
1686
+ 'dependencies'?: {
1687
+ [moduleId: string]: string;
1688
+ };
1689
+ 'devDependencies'?: {
1690
+ [moduleId: string]: string;
1691
+ };
1692
+ 'repository'?: {
1693
+ type?: string;
1694
+ url?: string;
1695
+ };
1696
+ 'private'?: boolean;
1697
+ 'scripts'?: {
1698
+ [runName: string]: string;
1699
+ };
1700
+ 'license'?: string;
1701
+ 'keywords'?: string[];
1702
+ }
1703
+ export interface Workbox {
1704
+ generateSW(swConfig: any): Promise<any>;
1705
+ generateFileManifest(): Promise<any>;
1706
+ getFileManifestEntries(): Promise<any>;
1707
+ injectManifest(swConfig: any): Promise<any>;
1708
+ copyWorkboxLibraries(wwwDir: string): Promise<any>;
1709
+ }
1710
+ export interface Url {
1711
+ href?: string;
1712
+ protocol?: string;
1713
+ auth?: string;
1714
+ hostname?: string;
1715
+ host?: string;
1716
+ port?: string;
1717
+ pathname?: string;
1718
+ path?: string;
1719
+ search?: string;
1720
+ query?: string | any;
1721
+ hash?: string;
1722
+ }
1723
+ declare global {
1724
+ namespace jest {
1725
+ interface Matchers<R, T> {
1726
+ /**
1727
+ * Compares HTML, but first normalizes the HTML so all
1728
+ * whitespace, attribute order and css class order are
1729
+ * the same. When given an element, it will compare
1730
+ * the element's `outerHTML`. When given a Document Fragment,
1731
+ * such as a Shadow Root, it'll compare its `innerHTML`.
1732
+ * Otherwise it'll compare two strings representing HTML.
1733
+ */
1734
+ toEqualHtml(expectHtml: string): void;
1735
+ /**
1736
+ * Compares HTML light DOKM only, but first normalizes the HTML so all
1737
+ * whitespace, attribute order and css class order are
1738
+ * the same. When given an element, it will compare
1739
+ * the element's `outerHTML`. When given a Document Fragment,
1740
+ * such as a Shadow Root, it'll compare its `innerHTML`.
1741
+ * Otherwise it'll compare two strings representing HTML.
1742
+ */
1743
+ toEqualLightHtml(expectLightHtml: string): void;
1744
+ /**
1745
+ * When given an element, it'll compare the element's
1746
+ * `textContent`. Otherwise it'll compare two strings. This
1747
+ * matcher will also `trim()` each string before comparing.
1748
+ */
1749
+ toEqualText(expectTextContent: string): void;
1750
+ /**
1751
+ * Checks if an element simply has the attribute. It does
1752
+ * not check any values of the attribute
1753
+ */
1754
+ toHaveAttribute(expectAttrName: string): void;
1755
+ /**
1756
+ * Checks if an element's attribute value equals the expect value.
1757
+ */
1758
+ toEqualAttribute(expectAttrName: string, expectAttrValue: any): void;
1759
+ /**
1760
+ * Checks if an element's has each of the expected attribute
1761
+ * names and values.
1762
+ */
1763
+ toEqualAttributes(expectAttrs: {
1764
+ [attrName: string]: any;
1765
+ }): void;
1766
+ /**
1767
+ * Checks if an element has the expected css class.
1768
+ */
1769
+ toHaveClass(expectClassName: string): void;
1770
+ /**
1771
+ * Checks if an element has each of the expected css classes
1772
+ * in the array.
1773
+ */
1774
+ toHaveClasses(expectClassNames: string[]): void;
1775
+ /**
1776
+ * Checks if an element has the exact same css classes
1777
+ * as the expected array of css classes.
1778
+ */
1779
+ toMatchClasses(expectClassNames: string[]): void;
1780
+ /**
1781
+ * When given an EventSpy, checks if the event has been
1782
+ * received or not.
1783
+ */
1784
+ toHaveReceivedEvent(): void;
1785
+ /**
1786
+ * When given an EventSpy, checks how many times the
1787
+ * event has been received.
1788
+ */
1789
+ toHaveReceivedEventTimes(count: number): void;
1790
+ /**
1791
+ * When given an EventSpy, checks the event has
1792
+ * received the correct custom event `detail` data.
1793
+ */
1794
+ toHaveReceivedEventDetail(eventDetail: any): void;
1795
+ /**
1796
+ * When given an EventSpy, checks the first event has
1797
+ * received the correct custom event `detail` data.
1798
+ */
1799
+ toHaveFirstReceivedEventDetail(eventDetail: any): void;
1800
+ /**
1801
+ * When given an EventSpy, checks the event at an index
1802
+ * has received the correct custom event `detail` data.
1803
+ */
1804
+ toHaveNthReceivedEventDetail(index: number, eventDetail: any): void;
1805
+ /**
1806
+ * Used to evaluate the results of `compareScreenshot()`, such as
1807
+ * `expect(compare).toMatchScreenshot()`. The `allowableMismatchedRatio`
1808
+ * value from the testing config is used by default if
1809
+ * `MatchScreenshotOptions` were not provided.
1810
+ */
1811
+ toMatchScreenshot(opts?: MatchScreenshotOptions): void;
1812
+ }
1813
+ }
1814
+ }
1815
+ export interface MatchScreenshotOptions {
1816
+ /**
1817
+ * The `allowableMismatchedPixels` value is the total number of pixels
1818
+ * that can be mismatched until the test fails. For example, if the value
1819
+ * is `100`, and if there were `101` pixels that were mismatched then the
1820
+ * test would fail. If the `allowableMismatchedRatio` is provided it will
1821
+ * take precedence, otherwise `allowableMismatchedPixels` will be used.
1822
+ */
1823
+ allowableMismatchedPixels?: number;
1824
+ /**
1825
+ * The `allowableMismatchedRatio` ranges from `0` to `1` and is used to
1826
+ * determine an acceptable ratio of pixels that can be mismatched before
1827
+ * the image is considered to have changes. Realistically, two screenshots
1828
+ * representing the same content may have a small number of pixels that
1829
+ * are not identical due to anti-aliasing, which is perfectly normal. The
1830
+ * `allowableMismatchedRatio` is the number of pixels that were mismatched,
1831
+ * divided by the total number of pixels in the screenshot. For example,
1832
+ * a ratio value of `0.06` means 6% of the pixels can be mismatched before
1833
+ * the image is considered to have changes. If the `allowableMismatchedRatio`
1834
+ * is provided it will take precedence, otherwise `allowableMismatchedPixels`
1835
+ * will be used.
1836
+ */
1837
+ allowableMismatchedRatio?: number;
1838
+ }
1839
+ export interface EventSpy {
1840
+ events: SerializedEvent[];
1841
+ eventName: string;
1842
+ firstEvent: SerializedEvent;
1843
+ lastEvent: SerializedEvent;
1844
+ length: number;
1845
+ next(): Promise<{
1846
+ done: boolean;
1847
+ value: SerializedEvent;
1848
+ }>;
1849
+ }
1850
+ export interface SerializedEvent {
1851
+ bubbles: boolean;
1852
+ cancelBubble: boolean;
1853
+ cancelable: boolean;
1854
+ composed: boolean;
1855
+ currentTarget: any;
1856
+ defaultPrevented: boolean;
1857
+ detail: any;
1858
+ eventPhase: any;
1859
+ isTrusted: boolean;
1860
+ returnValue: any;
1861
+ srcElement: any;
1862
+ target: any;
1863
+ timeStamp: number;
1864
+ type: string;
1865
+ isSerializedEvent: boolean;
1866
+ }
1867
+ export interface EventInitDict {
1868
+ bubbles?: boolean;
1869
+ cancelable?: boolean;
1870
+ composed?: boolean;
1871
+ detail?: any;
1872
+ }
1873
+ export interface JestEnvironmentGlobal {
1874
+ __NEW_TEST_PAGE__: () => Promise<any>;
1875
+ __CLOSE_OPEN_PAGES__: () => Promise<any>;
1876
+ Context: any;
1877
+ loadTestWindow: (testWindow: any) => Promise<void>;
1878
+ h: any;
1879
+ resourcesUrl: string;
1880
+ currentSpec?: {
1881
+ id: string;
1882
+ description: string;
1883
+ fullName: string;
1884
+ testPath: string;
1885
+ };
1886
+ env: {
1887
+ [prop: string]: string;
1888
+ };
1889
+ screenshotDescriptions: Set<string>;
1890
+ }
1891
+ export interface E2EProcessEnv {
1892
+ RINDO_COMMIT_ID?: string;
1893
+ RINDO_COMMIT_MESSAGE?: string;
1894
+ RINDO_REPO_URL?: string;
1895
+ RINDO_SCREENSHOT_CONNECTOR?: string;
1896
+ RINDO_SCREENSHOT_SERVER?: string;
1897
+ __RINDO_EMULATE_CONFIGS__?: string;
1898
+ __RINDO_ENV__?: string;
1899
+ __RINDO_EMULATE__?: string;
1900
+ __RINDO_BROWSER_URL__?: string;
1901
+ __RINDO_APP_SCRIPT_URL__?: string;
1902
+ __RINDO_APP_STYLE_URL__?: string;
1903
+ __RINDO_BROWSER_WS_ENDPOINT__?: string;
1904
+ __RINDO_BROWSER_WAIT_UNTIL?: string;
1905
+ __RINDO_SCREENSHOT__?: 'true';
1906
+ __RINDO_SCREENSHOT_BUILD__?: string;
1907
+ __RINDO_E2E_TESTS__?: 'true';
1908
+ __RINDO_E2E_DEVTOOLS__?: 'true';
1909
+ __RINDO_SPEC_TESTS__?: 'true';
1910
+ __RINDO_PUPPETEER_MODULE__?: string;
1911
+ __RINDO_DEFAULT_TIMEOUT__?: string;
1912
+ }
1913
+ export interface AnyHTMLElement extends HTMLElement {
1914
+ [key: string]: any;
1915
+ }
1916
+ export interface SpecPage {
1917
+ /**
1918
+ * Mocked testing `document.body`.
1919
+ */
1920
+ body: HTMLBodyElement;
1921
+ /**
1922
+ * Mocked testing `document`.
1923
+ */
1924
+ doc: HTMLDocument;
1925
+ /**
1926
+ * The first component found within the mocked `document.body`. If a component isn't found, then it'll return `document.body.firstElementChild`.
1927
+ */
1928
+ root?: AnyHTMLElement;
1929
+ /**
1930
+ * Similar to `root`, except returns the component instance. If a root component was not found it'll return `null`.
1931
+ */
1932
+ rootInstance?: any;
1933
+ /**
1934
+ * Convenience function to set `document.body.innerHTML` and `waitForChanges()`. Function argument should be an html string.
1935
+ */
1936
+ setContent: (html: string) => Promise<any>;
1937
+ /**
1938
+ * After changes have been made to a component, such as a update to a property or attribute, the test page does not automatically apply the changes. In order to wait for, and apply the update, call `await page.waitForChanges()`.
1939
+ */
1940
+ waitForChanges: () => Promise<any>;
1941
+ /**
1942
+ * Mocked testing `window`.
1943
+ */
1944
+ win: Window;
1945
+ build: BuildConditionals;
1946
+ flushLoadModule: (bundleId?: string) => Promise<any>;
1947
+ flushQueue: () => Promise<any>;
1948
+ styles: Map<string, string>;
1949
+ }
1950
+ export interface NewSpecPageOptions {
1951
+ /**
1952
+ * An array of components to test. Component classes can be imported into the spec file, then their reference should be added to the `component` array in order to be used throughout the test.
1953
+ */
1954
+ components: any[];
1955
+ /**
1956
+ * Sets the mocked `document.cookie`.
1957
+ */
1958
+ cookie?: string;
1959
+ /**
1960
+ * Sets the mocked `dir` attribute on `<html>`.
1961
+ */
1962
+ direction?: string;
1963
+ flushQueue?: boolean;
1964
+ /**
1965
+ * The initial HTML used to generate the test. This can be useful to construct a collection of components working together, and assign HTML attributes. This value sets the mocked `document.body.innerHTML`.
1966
+ */
1967
+ html?: string;
1968
+ /**
1969
+ * The initial JSX used to generate the test.
1970
+ * Use `template` when you want to initialize a component using their properties, instead of their HTML attributes.
1971
+ * It will render the specified template (JSX) into `document.body`.
1972
+ */
1973
+ template?: () => any;
1974
+ /**
1975
+ * Sets the mocked `lang` attribute on `<html>`.
1976
+ */
1977
+ language?: string;
1978
+ /**
1979
+ * Useful for debugging hydrating components client-side. Sets that the `html` option already includes annotated prerender attributes and comments.
1980
+ */
1981
+ hydrateClientSide?: boolean;
1982
+ /**
1983
+ * Useful for debugging hydrating components server-side. The output HTML will also include prerender annotations.
1984
+ */
1985
+ hydrateServerSide?: boolean;
1986
+ /**
1987
+ * Sets the mocked `document.referrer`.
1988
+ */
1989
+ referrer?: string;
1990
+ /**
1991
+ * Manually set if the mocked document supports Shadow DOM or not. Default is `true`.
1992
+ */
1993
+ supportsShadowDom?: boolean;
1994
+ /**
1995
+ * When a component is prerendered it includes HTML annotations, such as `s-id` attributes and `<!-t.0->` comments. This information is used by clientside hydrating. Default is `false`.
1996
+ */
1997
+ includeAnnotations?: boolean;
1998
+ /**
1999
+ * Sets the mocked browser's `location.href`.
2000
+ */
2001
+ url?: string;
2002
+ /**
2003
+ * Sets the mocked browser's `navigator.userAgent`.
2004
+ */
2005
+ userAgent?: string;
2006
+ /**
2007
+ * By default, any changes to component properties and attributes must `page.waitForChanges()` in order to test the updates. As an option, `autoAppluChanges` continuously flushes the queue on the background. Default is `false`.
2008
+ */
2009
+ autoApplyChanges?: boolean;
2010
+ /**
2011
+ * By default, styles are not attached to the DOM and they are not reflected in the serialized HTML.
2012
+ * Setting this option to `true` will include the component's styles in the serializable output.
2013
+ */
2014
+ attachStyles?: boolean;
2015
+ strictBuild?: boolean;
2016
+ }
2017
+ export interface TypesImportData {
2018
+ [key: string]: TypesMemberNameData[];
2019
+ }
2020
+ export interface TypesMemberNameData {
2021
+ localName: string;
2022
+ importName?: string;
2023
+ }
2024
+ export interface TypesModule {
2025
+ isDep: boolean;
2026
+ tagName: string;
2027
+ tagNameAsPascal: string;
2028
+ htmlElementName: string;
2029
+ component: string;
2030
+ jsx: string;
2031
+ element: string;
2032
+ }
2033
+ export declare type TypeInfo = {
2034
+ name: string;
2035
+ type: string;
2036
+ optional: boolean;
2037
+ required: boolean;
2038
+ internal: boolean;
2039
+ jsdoc?: string;
2040
+ }[];
2041
+ export interface Hyperscript {
2042
+ (sel: any): VNode;
2043
+ (sel: Node, data: VNodeData): VNode;
2044
+ (sel: any, data: VNodeData): VNode;
2045
+ (sel: any, text: string): VNode;
2046
+ (sel: any, children: Array<VNode | undefined | null>): VNode;
2047
+ (sel: any, data: VNodeData, text: string): VNode;
2048
+ (sel: any, data: VNodeData, children: Array<VNode | undefined | null>): VNode;
2049
+ (sel: any, data: VNodeData, children: VNode): VNode;
2050
+ }
2051
+ export declare type ChildType = VNode | number | string;
2052
+ export declare type PropsType = VNodeProdData | number | string | null;
2053
+ export interface VNodeProdData {
2054
+ key?: string | number;
2055
+ class?: {
2056
+ [className: string]: boolean;
2057
+ } | string;
2058
+ className?: {
2059
+ [className: string]: boolean;
2060
+ } | string;
2061
+ style?: any;
2062
+ [key: string]: any;
2063
+ }
2064
+ export interface CompilerWorkerContext {
2065
+ optimizeCss(inputOpts: OptimizeCssInput): Promise<OptimizeCssOutput>;
2066
+ prepareModule(input: string, minifyOpts: any, transpile: boolean, inlineHelpers: boolean): Promise<{
2067
+ output: string;
2068
+ diagnostics: Diagnostic[];
2069
+ }>;
2070
+ prerenderWorker(prerenderRequest: PrerenderUrlRequest): Promise<PrerenderUrlResults>;
2071
+ transformCssToEsm(input: TransformCssToEsmInput): Promise<TransformCssToEsmOutput>;
2072
+ }
2073
+ export interface MsgToWorker {
2074
+ rindoId: number;
2075
+ args: any[];
2076
+ }
2077
+ export interface MsgFromWorker {
2078
+ rindoId?: number;
2079
+ rindoRtnValue: any;
2080
+ rindoRtnError: string;
2081
+ }
2082
+ export interface CompilerWorkerTask {
2083
+ rindoId?: number;
2084
+ inputArgs?: any[];
2085
+ resolve: (val: any) => any;
2086
+ reject: (msg: string) => any;
2087
+ retries?: number;
2088
+ }
2089
+ export declare type WorkerMsgHandler = (msgToWorker: MsgToWorker) => Promise<any>;
2090
+ export interface WorkerTask {
2091
+ taskId: number;
2092
+ method: string;
2093
+ args: any[];
2094
+ resolve: (val: any) => any;
2095
+ reject: (msg: string) => any;
2096
+ retries: number;
2097
+ isLongRunningTask: boolean;
2098
+ workerKey: string;
2099
+ }
2100
+ export interface WorkerMessage {
2101
+ taskId?: number;
2102
+ method?: string;
2103
+ args?: any[];
2104
+ value?: any;
2105
+ error?: string;
2106
+ exit?: boolean;
2107
+ }
2108
+ export declare type WorkerRunner = (methodName: string, args: any[]) => Promise<any>;
2109
+ export interface WorkerRunnerOptions {
2110
+ isLongRunningTask?: boolean;
2111
+ workerKey?: string;
2112
+ }
2113
+ export interface WorkerContext {
2114
+ tsHost?: any;
2115
+ tsProgram?: any;
2116
+ }
2117
+ export interface TranspileModuleResults {
2118
+ sourceFilePath: string;
2119
+ code: string;
2120
+ map: any;
2121
+ diagnostics: Diagnostic[];
2122
+ moduleFile: Module;
2123
+ }
2124
+ export interface ValidateTypesResults {
2125
+ diagnostics: Diagnostic[];
2126
+ dirPaths: string[];
2127
+ filePaths: string[];
2128
+ }