@angular/core 16.0.0-next.4 → 16.0.0-next.5

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 (353) hide show
  1. package/{esm2020 → esm2022}/src/application_init.mjs +3 -3
  2. package/{esm2020 → esm2022}/src/application_module.mjs +4 -4
  3. package/esm2022/src/application_ref.mjs +908 -0
  4. package/{esm2020 → esm2022}/src/change_detection/change_detector_ref.mjs +6 -6
  5. package/esm2022/src/change_detection/differs/iterable_differs.mjs +81 -0
  6. package/esm2022/src/change_detection/differs/keyvalue_differs.mjs +74 -0
  7. package/{esm2020 → esm2022}/src/console.mjs +3 -3
  8. package/{esm2020 → esm2022}/src/core.mjs +2 -1
  9. package/esm2022/src/core_private_export.mjs +39 -0
  10. package/esm2022/src/core_reactivity_export_internal.mjs +12 -0
  11. package/esm2022/src/di/contextual.mjs +54 -0
  12. package/esm2022/src/di/index.mjs +29 -0
  13. package/esm2022/src/di/injector.mjs +62 -0
  14. package/esm2022/src/di/injector_compatibility.mjs +239 -0
  15. package/esm2022/src/di/provider_collection.mjs +279 -0
  16. package/esm2022/src/di/reflective_injector.mjs +311 -0
  17. package/esm2022/src/hydration/annotate.mjs +426 -0
  18. package/esm2022/src/hydration/api.mjs +143 -0
  19. package/esm2022/src/hydration/cleanup.mjs +103 -0
  20. package/esm2022/src/hydration/node_lookup_utils.mjs +273 -0
  21. package/esm2022/src/hydration/utils.mjs +219 -0
  22. package/esm2022/src/initial_render_pending_tasks.mjs +75 -0
  23. package/{esm2020 → esm2022}/src/linker/compiler.mjs +5 -5
  24. package/esm2022/src/linker/component_factory_resolver.mjs +42 -0
  25. package/{esm2020 → esm2022}/src/linker/destroy_ref.mjs +11 -11
  26. package/{esm2020 → esm2022}/src/linker/element_ref.mjs +6 -6
  27. package/esm2022/src/linker/query_list.mjs +169 -0
  28. package/{esm2020 → esm2022}/src/linker/template_ref.mjs +6 -6
  29. package/{esm2020 → esm2022}/src/linker/view_container_ref.mjs +6 -6
  30. package/esm2022/src/metadata/di.mjs +69 -0
  31. package/{esm2020 → esm2022}/src/metadata/directives.mjs +1 -1
  32. package/{esm2020 → esm2022}/src/metadata/do_boostrap.mjs +1 -1
  33. package/{esm2020 → esm2022}/src/metadata/ng_module.mjs +2 -2
  34. package/esm2022/src/metadata.mjs +18 -0
  35. package/{esm2020 → esm2022}/src/render/api.mjs +6 -6
  36. package/esm2022/src/render3/component_ref.mjs +386 -0
  37. package/{esm2020 → esm2022}/src/render3/context_discovery.mjs +1 -1
  38. package/esm2022/src/render3/features/standalone_feature.mjs +70 -0
  39. package/{esm2020 → esm2022}/src/render3/instructions/element.mjs +2 -2
  40. package/esm2022/src/render3/instructions/listener.mjs +244 -0
  41. package/esm2022/src/render3/instructions/mark_view_dirty.mjs +35 -0
  42. package/esm2022/src/render3/instructions/shared.mjs +1681 -0
  43. package/{esm2020 → esm2022}/src/render3/instructions/styling.mjs +5 -2
  44. package/esm2022/src/render3/interfaces/view.mjs +49 -0
  45. package/esm2022/src/render3/jit/module.mjs +531 -0
  46. package/esm2022/src/render3/node_manipulation.mjs +960 -0
  47. package/esm2022/src/render3/reactive_lview_consumer.mjs +80 -0
  48. package/esm2022/src/render3/reactivity/effect.mjs +67 -0
  49. package/{esm2020 → esm2022}/src/render3/util/change_detection_utils.mjs +2 -2
  50. package/esm2022/src/render3/view_ref.mjs +307 -0
  51. package/{esm2020 → esm2022}/src/sanitization/sanitizer.mjs +7 -7
  52. package/esm2022/src/signals/index.mjs +15 -0
  53. package/esm2022/src/signals/src/api.mjs +47 -0
  54. package/esm2022/src/signals/src/computed.mjs +139 -0
  55. package/esm2022/src/signals/src/graph.mjs +165 -0
  56. package/esm2022/src/signals/src/signal.mjs +75 -0
  57. package/esm2022/src/signals/src/watch.mjs +62 -0
  58. package/esm2022/src/signals/src/weak_ref.mjs +35 -0
  59. package/{esm2020 → esm2022}/src/testability/testability.mjs +5 -5
  60. package/esm2022/src/transfer_state.mjs +153 -0
  61. package/{esm2020 → esm2022}/src/version.mjs +1 -1
  62. package/{esm2020 → esm2022}/testing/src/logger.mjs +4 -4
  63. package/{esm2020 → esm2022}/testing/src/ng_zone_mock.mjs +4 -4
  64. package/{esm2020 → esm2022}/testing/src/test_bed.mjs +2 -2
  65. package/{fesm2020 → fesm2022}/core.mjs +869 -639
  66. package/fesm2022/core.mjs.map +1 -0
  67. package/{fesm2020 → fesm2022}/testing.mjs +406 -124
  68. package/fesm2022/testing.mjs.map +1 -0
  69. package/index.d.ts +334 -187
  70. package/package.json +8 -16
  71. package/schematics/migrations/guard-and-resolve-interfaces/bundle.js +694 -0
  72. package/schematics/migrations/guard-and-resolve-interfaces/bundle.js.map +7 -0
  73. package/schematics/migrations/{router-link-with-href → remove-module-id}/bundle.js +149 -151
  74. package/schematics/migrations/remove-module-id/bundle.js.map +7 -0
  75. package/schematics/migrations.json +8 -8
  76. package/schematics/ng-generate/standalone-migration/bundle.js +617 -251
  77. package/schematics/ng-generate/standalone-migration/bundle.js.map +2 -2
  78. package/testing/index.d.ts +1 -1
  79. package/esm2020/src/application_ref.mjs +0 -907
  80. package/esm2020/src/change_detection/differs/iterable_differs.mjs +0 -81
  81. package/esm2020/src/change_detection/differs/keyvalue_differs.mjs +0 -74
  82. package/esm2020/src/core_private_export.mjs +0 -38
  83. package/esm2020/src/core_reactivity_export_internal.mjs +0 -9
  84. package/esm2020/src/di/contextual.mjs +0 -37
  85. package/esm2020/src/di/index.mjs +0 -29
  86. package/esm2020/src/di/injector.mjs +0 -62
  87. package/esm2020/src/di/injector_compatibility.mjs +0 -236
  88. package/esm2020/src/di/provider_collection.mjs +0 -279
  89. package/esm2020/src/di/reflective_injector.mjs +0 -311
  90. package/esm2020/src/hydration/annotate.mjs +0 -384
  91. package/esm2020/src/hydration/api.mjs +0 -141
  92. package/esm2020/src/hydration/cleanup.mjs +0 -101
  93. package/esm2020/src/hydration/node_lookup_utils.mjs +0 -275
  94. package/esm2020/src/hydration/utils.mjs +0 -219
  95. package/esm2020/src/linker/component_factory_resolver.mjs +0 -42
  96. package/esm2020/src/linker/query_list.mjs +0 -169
  97. package/esm2020/src/metadata/di.mjs +0 -108
  98. package/esm2020/src/metadata.mjs +0 -18
  99. package/esm2020/src/render3/component_ref.mjs +0 -377
  100. package/esm2020/src/render3/features/standalone_feature.mjs +0 -70
  101. package/esm2020/src/render3/instructions/listener.mjs +0 -243
  102. package/esm2020/src/render3/instructions/shared.mjs +0 -1696
  103. package/esm2020/src/render3/interfaces/view.mjs +0 -47
  104. package/esm2020/src/render3/jit/module.mjs +0 -544
  105. package/esm2020/src/render3/node_manipulation.mjs +0 -961
  106. package/esm2020/src/render3/view_ref.mjs +0 -306
  107. package/esm2020/src/signals/index.mjs +0 -16
  108. package/esm2020/src/signals/src/api.mjs +0 -46
  109. package/esm2020/src/signals/src/computed.mjs +0 -142
  110. package/esm2020/src/signals/src/effect.mjs +0 -67
  111. package/esm2020/src/signals/src/graph.mjs +0 -114
  112. package/esm2020/src/signals/src/signal.mjs +0 -78
  113. package/esm2020/src/signals/src/watch.mjs +0 -54
  114. package/esm2020/src/signals/src/weak_ref.mjs +0 -27
  115. package/esm2020/src/transfer_state.mjs +0 -153
  116. package/fesm2015/core.mjs +0 -30473
  117. package/fesm2015/core.mjs.map +0 -1
  118. package/fesm2015/testing.mjs +0 -26417
  119. package/fesm2015/testing.mjs.map +0 -1
  120. package/fesm2020/core.mjs.map +0 -1
  121. package/fesm2020/testing.mjs.map +0 -1
  122. package/schematics/migrations/relative-link-resolution/bundle.js +0 -283
  123. package/schematics/migrations/relative-link-resolution/bundle.js.map +0 -7
  124. package/schematics/migrations/router-link-with-href/bundle.js.map +0 -7
  125. /package/{esm2020 → esm2022}/core.mjs +0 -0
  126. /package/{esm2020 → esm2022}/index.mjs +0 -0
  127. /package/{esm2020 → esm2022}/public_api.mjs +0 -0
  128. /package/{esm2020 → esm2022}/src/application_config.mjs +0 -0
  129. /package/{esm2020 → esm2022}/src/application_tokens.mjs +0 -0
  130. /package/{esm2020 → esm2022}/src/change_detection/change_detection.mjs +0 -0
  131. /package/{esm2020 → esm2022}/src/change_detection/constants.mjs +0 -0
  132. /package/{esm2020 → esm2022}/src/change_detection/differs/default_iterable_differ.mjs +0 -0
  133. /package/{esm2020 → esm2022}/src/change_detection/differs/default_keyvalue_differ.mjs +0 -0
  134. /package/{esm2020 → esm2022}/src/change_detection/pipe_transform.mjs +0 -0
  135. /package/{esm2020 → esm2022}/src/change_detection.mjs +0 -0
  136. /package/{esm2020 → esm2022}/src/compiler/compiler_facade.mjs +0 -0
  137. /package/{esm2020 → esm2022}/src/compiler/compiler_facade_interface.mjs +0 -0
  138. /package/{esm2020 → esm2022}/src/core_reactivity_export.mjs +0 -0
  139. /package/{esm2020 → esm2022}/src/core_render3_private_export.mjs +0 -0
  140. /package/{esm2020 → esm2022}/src/debug/debug_node.mjs +0 -0
  141. /package/{esm2020 → esm2022}/src/di/create_injector.mjs +0 -0
  142. /package/{esm2020 → esm2022}/src/di/forward_ref.mjs +0 -0
  143. /package/{esm2020 → esm2022}/src/di/initializer_token.mjs +0 -0
  144. /package/{esm2020 → esm2022}/src/di/inject_switch.mjs +0 -0
  145. /package/{esm2020 → esm2022}/src/di/injectable.mjs +0 -0
  146. /package/{esm2020 → esm2022}/src/di/injection_token.mjs +0 -0
  147. /package/{esm2020 → esm2022}/src/di/injector_marker.mjs +0 -0
  148. /package/{esm2020 → esm2022}/src/di/injector_token.mjs +0 -0
  149. /package/{esm2020 → esm2022}/src/di/interface/defs.mjs +0 -0
  150. /package/{esm2020 → esm2022}/src/di/interface/injector.mjs +0 -0
  151. /package/{esm2020 → esm2022}/src/di/interface/provider.mjs +0 -0
  152. /package/{esm2020 → esm2022}/src/di/internal_tokens.mjs +0 -0
  153. /package/{esm2020 → esm2022}/src/di/jit/environment.mjs +0 -0
  154. /package/{esm2020 → esm2022}/src/di/jit/injectable.mjs +0 -0
  155. /package/{esm2020 → esm2022}/src/di/jit/util.mjs +0 -0
  156. /package/{esm2020 → esm2022}/src/di/metadata.mjs +0 -0
  157. /package/{esm2020 → esm2022}/src/di/metadata_attr.mjs +0 -0
  158. /package/{esm2020 → esm2022}/src/di/null_injector.mjs +0 -0
  159. /package/{esm2020 → esm2022}/src/di/provider_token.mjs +0 -0
  160. /package/{esm2020 → esm2022}/src/di/r3_injector.mjs +0 -0
  161. /package/{esm2020 → esm2022}/src/di/reflective_errors.mjs +0 -0
  162. /package/{esm2020 → esm2022}/src/di/reflective_key.mjs +0 -0
  163. /package/{esm2020 → esm2022}/src/di/reflective_provider.mjs +0 -0
  164. /package/{esm2020 → esm2022}/src/di/scope.mjs +0 -0
  165. /package/{esm2020 → esm2022}/src/di.mjs +0 -0
  166. /package/{esm2020 → esm2022}/src/error_details_base_url.mjs +0 -0
  167. /package/{esm2020 → esm2022}/src/error_handler.mjs +0 -0
  168. /package/{esm2020 → esm2022}/src/errors.mjs +0 -0
  169. /package/{esm2020 → esm2022}/src/event_emitter.mjs +0 -0
  170. /package/{esm2020 → esm2022}/src/hydration/compression.mjs +0 -0
  171. /package/{esm2020 → esm2022}/src/hydration/error_handling.mjs +0 -0
  172. /package/{esm2020 → esm2022}/src/hydration/interfaces.mjs +0 -0
  173. /package/{esm2020 → esm2022}/src/hydration/skip_hydration.mjs +0 -0
  174. /package/{esm2020 → esm2022}/src/hydration/tokens.mjs +0 -0
  175. /package/{esm2020 → esm2022}/src/hydration/views.mjs +0 -0
  176. /package/{esm2020 → esm2022}/src/i18n/locale_data_api.mjs +0 -0
  177. /package/{esm2020 → esm2022}/src/i18n/locale_en.mjs +0 -0
  178. /package/{esm2020 → esm2022}/src/i18n/localization.mjs +0 -0
  179. /package/{esm2020 → esm2022}/src/i18n/tokens.mjs +0 -0
  180. /package/{esm2020 → esm2022}/src/interface/lifecycle_hooks.mjs +0 -0
  181. /package/{esm2020 → esm2022}/src/interface/simple_change.mjs +0 -0
  182. /package/{esm2020 → esm2022}/src/interface/type.mjs +0 -0
  183. /package/{esm2020 → esm2022}/src/linker/component_factory.mjs +0 -0
  184. /package/{esm2020 → esm2022}/src/linker/ng_module_factory.mjs +0 -0
  185. /package/{esm2020 → esm2022}/src/linker/ng_module_factory_loader.mjs +0 -0
  186. /package/{esm2020 → esm2022}/src/linker/ng_module_factory_loader_impl.mjs +0 -0
  187. /package/{esm2020 → esm2022}/src/linker/ng_module_registration.mjs +0 -0
  188. /package/{esm2020 → esm2022}/src/linker/view_ref.mjs +0 -0
  189. /package/{esm2020 → esm2022}/src/linker.mjs +0 -0
  190. /package/{esm2020 → esm2022}/src/metadata/ng_module_def.mjs +0 -0
  191. /package/{esm2020 → esm2022}/src/metadata/resource_loading.mjs +0 -0
  192. /package/{esm2020 → esm2022}/src/metadata/schema.mjs +0 -0
  193. /package/{esm2020 → esm2022}/src/metadata/view.mjs +0 -0
  194. /package/{esm2020 → esm2022}/src/platform_core_providers.mjs +0 -0
  195. /package/{esm2020 → esm2022}/src/r3_symbols.mjs +0 -0
  196. /package/{esm2020 → esm2022}/src/reflection/platform_reflection_capabilities.mjs +0 -0
  197. /package/{esm2020 → esm2022}/src/reflection/reflection_capabilities.mjs +0 -0
  198. /package/{esm2020 → esm2022}/src/render/api_flags.mjs +0 -0
  199. /package/{esm2020 → esm2022}/src/render.mjs +0 -0
  200. /package/{esm2020 → esm2022}/src/render3/assert.mjs +0 -0
  201. /package/{esm2020 → esm2022}/src/render3/bindings.mjs +0 -0
  202. /package/{esm2020 → esm2022}/src/render3/collect_native_nodes.mjs +0 -0
  203. /package/{esm2020 → esm2022}/src/render3/component.mjs +0 -0
  204. /package/{esm2020 → esm2022}/src/render3/definition.mjs +0 -0
  205. /package/{esm2020 → esm2022}/src/render3/definition_factory.mjs +0 -0
  206. /package/{esm2020 → esm2022}/src/render3/di.mjs +0 -0
  207. /package/{esm2020 → esm2022}/src/render3/di_setup.mjs +0 -0
  208. /package/{esm2020 → esm2022}/src/render3/errors.mjs +0 -0
  209. /package/{esm2020 → esm2022}/src/render3/errors_di.mjs +0 -0
  210. /package/{esm2020 → esm2022}/src/render3/features/copy_definition_feature.mjs +0 -0
  211. /package/{esm2020 → esm2022}/src/render3/features/host_directives_feature.mjs +0 -0
  212. /package/{esm2020 → esm2022}/src/render3/features/inherit_definition_feature.mjs +0 -0
  213. /package/{esm2020 → esm2022}/src/render3/features/ng_onchanges_feature.mjs +0 -0
  214. /package/{esm2020 → esm2022}/src/render3/features/providers_feature.mjs +0 -0
  215. /package/{esm2020 → esm2022}/src/render3/fields.mjs +0 -0
  216. /package/{esm2020 → esm2022}/src/render3/global_utils_api.mjs +0 -0
  217. /package/{esm2020 → esm2022}/src/render3/hooks.mjs +0 -0
  218. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_apply.mjs +0 -0
  219. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_debug.mjs +0 -0
  220. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_insert_before_index.mjs +0 -0
  221. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_locale_id.mjs +0 -0
  222. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_parse.mjs +0 -0
  223. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_postprocess.mjs +0 -0
  224. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_tree_shaking.mjs +0 -0
  225. /package/{esm2020 → esm2022}/src/render3/i18n/i18n_util.mjs +0 -0
  226. /package/{esm2020 → esm2022}/src/render3/index.mjs +0 -0
  227. /package/{esm2020 → esm2022}/src/render3/instructions/advance.mjs +0 -0
  228. /package/{esm2020 → esm2022}/src/render3/instructions/all.mjs +0 -0
  229. /package/{esm2020 → esm2022}/src/render3/instructions/attribute.mjs +0 -0
  230. /package/{esm2020 → esm2022}/src/render3/instructions/attribute_interpolation.mjs +0 -0
  231. /package/{esm2020 → esm2022}/src/render3/instructions/change_detection.mjs +0 -0
  232. /package/{esm2020 → esm2022}/src/render3/instructions/class_map_interpolation.mjs +0 -0
  233. /package/{esm2020 → esm2022}/src/render3/instructions/di.mjs +0 -0
  234. /package/{esm2020 → esm2022}/src/render3/instructions/di_attr.mjs +0 -0
  235. /package/{esm2020 → esm2022}/src/render3/instructions/element_container.mjs +0 -0
  236. /package/{esm2020 → esm2022}/src/render3/instructions/element_validation.mjs +0 -0
  237. /package/{esm2020 → esm2022}/src/render3/instructions/get_current_view.mjs +0 -0
  238. /package/{esm2020 → esm2022}/src/render3/instructions/host_property.mjs +0 -0
  239. /package/{esm2020 → esm2022}/src/render3/instructions/i18n.mjs +0 -0
  240. /package/{esm2020 → esm2022}/src/render3/instructions/i18n_icu_container_visitor.mjs +0 -0
  241. /package/{esm2020 → esm2022}/src/render3/instructions/interpolation.mjs +0 -0
  242. /package/{esm2020 → esm2022}/src/render3/instructions/namespace.mjs +0 -0
  243. /package/{esm2020 → esm2022}/src/render3/instructions/next_context.mjs +0 -0
  244. /package/{esm2020 → esm2022}/src/render3/instructions/projection.mjs +0 -0
  245. /package/{esm2020 → esm2022}/src/render3/instructions/property.mjs +0 -0
  246. /package/{esm2020 → esm2022}/src/render3/instructions/property_interpolation.mjs +0 -0
  247. /package/{esm2020 → esm2022}/src/render3/instructions/storage.mjs +0 -0
  248. /package/{esm2020 → esm2022}/src/render3/instructions/style_map_interpolation.mjs +0 -0
  249. /package/{esm2020 → esm2022}/src/render3/instructions/style_prop_interpolation.mjs +0 -0
  250. /package/{esm2020 → esm2022}/src/render3/instructions/template.mjs +0 -0
  251. /package/{esm2020 → esm2022}/src/render3/instructions/text.mjs +0 -0
  252. /package/{esm2020 → esm2022}/src/render3/instructions/text_interpolation.mjs +0 -0
  253. /package/{esm2020 → esm2022}/src/render3/interfaces/container.mjs +0 -0
  254. /package/{esm2020 → esm2022}/src/render3/interfaces/context.mjs +0 -0
  255. /package/{esm2020 → esm2022}/src/render3/interfaces/definition.mjs +0 -0
  256. /package/{esm2020 → esm2022}/src/render3/interfaces/document.mjs +0 -0
  257. /package/{esm2020 → esm2022}/src/render3/interfaces/i18n.mjs +0 -0
  258. /package/{esm2020 → esm2022}/src/render3/interfaces/injector.mjs +0 -0
  259. /package/{esm2020 → esm2022}/src/render3/interfaces/lview_tracking.mjs +0 -0
  260. /package/{esm2020 → esm2022}/src/render3/interfaces/node.mjs +0 -0
  261. /package/{esm2020 → esm2022}/src/render3/interfaces/projection.mjs +0 -0
  262. /package/{esm2020 → esm2022}/src/render3/interfaces/public_definitions.mjs +0 -0
  263. /package/{esm2020 → esm2022}/src/render3/interfaces/query.mjs +0 -0
  264. /package/{esm2020 → esm2022}/src/render3/interfaces/renderer.mjs +0 -0
  265. /package/{esm2020 → esm2022}/src/render3/interfaces/renderer_dom.mjs +0 -0
  266. /package/{esm2020 → esm2022}/src/render3/interfaces/sanitization.mjs +0 -0
  267. /package/{esm2020 → esm2022}/src/render3/interfaces/styling.mjs +0 -0
  268. /package/{esm2020 → esm2022}/src/render3/interfaces/type_checks.mjs +0 -0
  269. /package/{esm2020 → esm2022}/src/render3/jit/directive.mjs +0 -0
  270. /package/{esm2020 → esm2022}/src/render3/jit/environment.mjs +0 -0
  271. /package/{esm2020 → esm2022}/src/render3/jit/jit_options.mjs +0 -0
  272. /package/{esm2020 → esm2022}/src/render3/jit/module_patch.mjs +0 -0
  273. /package/{esm2020 → esm2022}/src/render3/jit/partial.mjs +0 -0
  274. /package/{esm2020 → esm2022}/src/render3/jit/pipe.mjs +0 -0
  275. /package/{esm2020 → esm2022}/src/render3/jit/util.mjs +0 -0
  276. /package/{esm2020 → esm2022}/src/render3/metadata.mjs +0 -0
  277. /package/{esm2020 → esm2022}/src/render3/namespaces.mjs +0 -0
  278. /package/{esm2020 → esm2022}/src/render3/ng_module_ref.mjs +0 -0
  279. /package/{esm2020 → esm2022}/src/render3/node_assert.mjs +0 -0
  280. /package/{esm2020 → esm2022}/src/render3/node_manipulation_i18n.mjs +0 -0
  281. /package/{esm2020 → esm2022}/src/render3/node_selector_matcher.mjs +0 -0
  282. /package/{esm2020 → esm2022}/src/render3/pipe.mjs +0 -0
  283. /package/{esm2020 → esm2022}/src/render3/profiler.mjs +0 -0
  284. /package/{esm2020 → esm2022}/src/render3/pure_function.mjs +0 -0
  285. /package/{esm2020 → esm2022}/src/render3/query.mjs +0 -0
  286. /package/{esm2020 → esm2022}/src/render3/state.mjs +0 -0
  287. /package/{esm2020 → esm2022}/src/render3/styling/class_differ.mjs +0 -0
  288. /package/{esm2020 → esm2022}/src/render3/styling/static_styling.mjs +0 -0
  289. /package/{esm2020 → esm2022}/src/render3/styling/style_binding_list.mjs +0 -0
  290. /package/{esm2020 → esm2022}/src/render3/styling/styling_parser.mjs +0 -0
  291. /package/{esm2020 → esm2022}/src/render3/tokens.mjs +0 -0
  292. /package/{esm2020 → esm2022}/src/render3/util/attrs_utils.mjs +0 -0
  293. /package/{esm2020 → esm2022}/src/render3/util/discovery_utils.mjs +0 -0
  294. /package/{esm2020 → esm2022}/src/render3/util/global_utils.mjs +0 -0
  295. /package/{esm2020 → esm2022}/src/render3/util/injector_utils.mjs +0 -0
  296. /package/{esm2020 → esm2022}/src/render3/util/misc_utils.mjs +0 -0
  297. /package/{esm2020 → esm2022}/src/render3/util/stringify_utils.mjs +0 -0
  298. /package/{esm2020 → esm2022}/src/render3/util/view_traversal_utils.mjs +0 -0
  299. /package/{esm2020 → esm2022}/src/render3/util/view_utils.mjs +0 -0
  300. /package/{esm2020 → esm2022}/src/render3/view_engine_compatibility_prebound.mjs +0 -0
  301. /package/{esm2020 → esm2022}/src/sanitization/bypass.mjs +0 -0
  302. /package/{esm2020 → esm2022}/src/sanitization/html_sanitizer.mjs +0 -0
  303. /package/{esm2020 → esm2022}/src/sanitization/iframe_attrs_validation.mjs +0 -0
  304. /package/{esm2020 → esm2022}/src/sanitization/inert_body.mjs +0 -0
  305. /package/{esm2020 → esm2022}/src/sanitization/sanitization.mjs +0 -0
  306. /package/{esm2020 → esm2022}/src/sanitization/security.mjs +0 -0
  307. /package/{esm2020 → esm2022}/src/sanitization/url_sanitizer.mjs +0 -0
  308. /package/{esm2020 → esm2022}/src/signals/src/untracked.mjs +0 -0
  309. /package/{esm2020 → esm2022}/src/util/array_utils.mjs +0 -0
  310. /package/{esm2020 → esm2022}/src/util/assert.mjs +0 -0
  311. /package/{esm2020 → esm2022}/src/util/char_code.mjs +0 -0
  312. /package/{esm2020 → esm2022}/src/util/closure.mjs +0 -0
  313. /package/{esm2020 → esm2022}/src/util/coercion.mjs +0 -0
  314. /package/{esm2020 → esm2022}/src/util/comparison.mjs +0 -0
  315. /package/{esm2020 → esm2022}/src/util/decorators.mjs +0 -0
  316. /package/{esm2020 → esm2022}/src/util/dom.mjs +0 -0
  317. /package/{esm2020 → esm2022}/src/util/empty.mjs +0 -0
  318. /package/{esm2020 → esm2022}/src/util/errors.mjs +0 -0
  319. /package/{esm2020 → esm2022}/src/util/global.mjs +0 -0
  320. /package/{esm2020 → esm2022}/src/util/is_dev_mode.mjs +0 -0
  321. /package/{esm2020 → esm2022}/src/util/iterable.mjs +0 -0
  322. /package/{esm2020 → esm2022}/src/util/lang.mjs +0 -0
  323. /package/{esm2020 → esm2022}/src/util/microtask.mjs +0 -0
  324. /package/{esm2020 → esm2022}/src/util/ng_dev_mode.mjs +0 -0
  325. /package/{esm2020 → esm2022}/src/util/ng_i18n_closure_mode.mjs +0 -0
  326. /package/{esm2020 → esm2022}/src/util/ng_jit_mode.mjs +0 -0
  327. /package/{esm2020 → esm2022}/src/util/ng_reflect.mjs +0 -0
  328. /package/{esm2020 → esm2022}/src/util/noop.mjs +0 -0
  329. /package/{esm2020 → esm2022}/src/util/property.mjs +0 -0
  330. /package/{esm2020 → esm2022}/src/util/raf.mjs +0 -0
  331. /package/{esm2020 → esm2022}/src/util/security/trusted_type_defs.mjs +0 -0
  332. /package/{esm2020 → esm2022}/src/util/security/trusted_types.mjs +0 -0
  333. /package/{esm2020 → esm2022}/src/util/security/trusted_types_bypass.mjs +0 -0
  334. /package/{esm2020 → esm2022}/src/util/stringify.mjs +0 -0
  335. /package/{esm2020 → esm2022}/src/view/provider_flags.mjs +0 -0
  336. /package/{esm2020 → esm2022}/src/zone/async-stack-tagging.mjs +0 -0
  337. /package/{esm2020 → esm2022}/src/zone/ng_zone.mjs +0 -0
  338. /package/{esm2020 → esm2022}/src/zone.mjs +0 -0
  339. /package/{esm2020 → esm2022}/testing/index.mjs +0 -0
  340. /package/{esm2020 → esm2022}/testing/public_api.mjs +0 -0
  341. /package/{esm2020 → esm2022}/testing/src/async.mjs +0 -0
  342. /package/{esm2020 → esm2022}/testing/src/component_fixture.mjs +0 -0
  343. /package/{esm2020 → esm2022}/testing/src/fake_async.mjs +0 -0
  344. /package/{esm2020 → esm2022}/testing/src/metadata_override.mjs +0 -0
  345. /package/{esm2020 → esm2022}/testing/src/metadata_overrider.mjs +0 -0
  346. /package/{esm2020 → esm2022}/testing/src/resolvers.mjs +0 -0
  347. /package/{esm2020 → esm2022}/testing/src/styling.mjs +0 -0
  348. /package/{esm2020 → esm2022}/testing/src/test_bed_common.mjs +0 -0
  349. /package/{esm2020 → esm2022}/testing/src/test_bed_compiler.mjs +0 -0
  350. /package/{esm2020 → esm2022}/testing/src/test_hooks.mjs +0 -0
  351. /package/{esm2020 → esm2022}/testing/src/testing.mjs +0 -0
  352. /package/{esm2020 → esm2022}/testing/src/testing_internal.mjs +0 -0
  353. /package/{esm2020 → esm2022}/testing/testing.mjs +0 -0
@@ -1,283 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
6
- var __getProtoOf = Object.getPrototypeOf;
7
- var __hasOwnProp = Object.prototype.hasOwnProperty;
8
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
9
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
10
- var __spreadValues = (a, b) => {
11
- for (var prop in b || (b = {}))
12
- if (__hasOwnProp.call(b, prop))
13
- __defNormalProp(a, prop, b[prop]);
14
- if (__getOwnPropSymbols)
15
- for (var prop of __getOwnPropSymbols(b)) {
16
- if (__propIsEnum.call(b, prop))
17
- __defNormalProp(a, prop, b[prop]);
18
- }
19
- return a;
20
- };
21
- var __export = (target, all) => {
22
- for (var name in all)
23
- __defProp(target, name, { get: all[name], enumerable: true });
24
- };
25
- var __copyProps = (to, from, except, desc) => {
26
- if (from && typeof from === "object" || typeof from === "function") {
27
- for (let key of __getOwnPropNames(from))
28
- if (!__hasOwnProp.call(to, key) && key !== except)
29
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
30
- }
31
- return to;
32
- };
33
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
34
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
35
- mod
36
- ));
37
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
38
- var __async = (__this, __arguments, generator) => {
39
- return new Promise((resolve2, reject) => {
40
- var fulfilled = (value) => {
41
- try {
42
- step(generator.next(value));
43
- } catch (e) {
44
- reject(e);
45
- }
46
- };
47
- var rejected = (value) => {
48
- try {
49
- step(generator.throw(value));
50
- } catch (e) {
51
- reject(e);
52
- }
53
- };
54
- var step = (x) => x.done ? resolve2(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
55
- step((generator = generator.apply(__this, __arguments)).next());
56
- });
57
- };
58
-
59
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/migrations/relative-link-resolution/index.mjs
60
- var relative_link_resolution_exports = {};
61
- __export(relative_link_resolution_exports, {
62
- default: () => relative_link_resolution_default
63
- });
64
- module.exports = __toCommonJS(relative_link_resolution_exports);
65
- var import_schematics = require("@angular-devkit/schematics");
66
- var import_path2 = require("path");
67
-
68
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/utils/project_tsconfig_paths.mjs
69
- var import_core = require("@angular-devkit/core");
70
- function getProjectTsConfigPaths(tree) {
71
- return __async(this, null, function* () {
72
- const buildPaths = /* @__PURE__ */ new Set();
73
- const testPaths = /* @__PURE__ */ new Set();
74
- const workspace = yield getWorkspace(tree);
75
- for (const [, project] of workspace.projects) {
76
- for (const [name, target] of project.targets) {
77
- if (name !== "build" && name !== "test") {
78
- continue;
79
- }
80
- for (const [, options] of allTargetOptions(target)) {
81
- const tsConfig = options.tsConfig;
82
- if (typeof tsConfig !== "string" || !tree.exists(tsConfig)) {
83
- continue;
84
- }
85
- if (name === "build") {
86
- buildPaths.add((0, import_core.normalize)(tsConfig));
87
- } else {
88
- testPaths.add((0, import_core.normalize)(tsConfig));
89
- }
90
- }
91
- }
92
- }
93
- return {
94
- buildPaths: [...buildPaths],
95
- testPaths: [...testPaths]
96
- };
97
- });
98
- }
99
- function* allTargetOptions(target) {
100
- if (target.options) {
101
- yield [void 0, target.options];
102
- }
103
- if (!target.configurations) {
104
- return;
105
- }
106
- for (const [name, options] of Object.entries(target.configurations)) {
107
- if (options) {
108
- yield [name, options];
109
- }
110
- }
111
- }
112
- function createHost(tree) {
113
- return {
114
- readFile(path2) {
115
- return __async(this, null, function* () {
116
- const data = tree.read(path2);
117
- if (!data) {
118
- throw new Error("File not found.");
119
- }
120
- return import_core.virtualFs.fileBufferToString(data);
121
- });
122
- },
123
- writeFile(path2, data) {
124
- return __async(this, null, function* () {
125
- return tree.overwrite(path2, data);
126
- });
127
- },
128
- isDirectory(path2) {
129
- return __async(this, null, function* () {
130
- return !tree.exists(path2) && tree.getDir(path2).subfiles.length > 0;
131
- });
132
- },
133
- isFile(path2) {
134
- return __async(this, null, function* () {
135
- return tree.exists(path2);
136
- });
137
- }
138
- };
139
- }
140
- function getWorkspace(tree) {
141
- return __async(this, null, function* () {
142
- const host = createHost(tree);
143
- const { workspace } = yield import_core.workspaces.readWorkspace("/", host);
144
- return workspace;
145
- });
146
- }
147
-
148
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/utils/typescript/compiler_host.mjs
149
- var import_path = require("path");
150
- var import_typescript2 = __toESM(require("typescript"), 1);
151
-
152
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/utils/typescript/parse_tsconfig.mjs
153
- var path = __toESM(require("path"), 1);
154
- var import_typescript = __toESM(require("typescript"), 1);
155
- function parseTsconfigFile(tsconfigPath, basePath) {
156
- const { config } = import_typescript.default.readConfigFile(tsconfigPath, import_typescript.default.sys.readFile);
157
- const parseConfigHost = {
158
- useCaseSensitiveFileNames: import_typescript.default.sys.useCaseSensitiveFileNames,
159
- fileExists: import_typescript.default.sys.fileExists,
160
- readDirectory: import_typescript.default.sys.readDirectory,
161
- readFile: import_typescript.default.sys.readFile
162
- };
163
- if (!path.isAbsolute(basePath)) {
164
- throw Error("Unexpected relative base path has been specified.");
165
- }
166
- return import_typescript.default.parseJsonConfigFileContent(config, parseConfigHost, basePath, {});
167
- }
168
-
169
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/utils/typescript/compiler_host.mjs
170
- function createMigrationProgram(tree, tsconfigPath, basePath, fakeFileRead, additionalFiles) {
171
- const { rootNames, options, host } = createProgramOptions(tree, tsconfigPath, basePath, fakeFileRead, additionalFiles);
172
- return import_typescript2.default.createProgram(rootNames, options, host);
173
- }
174
- function createProgramOptions(tree, tsconfigPath, basePath, fakeFileRead, additionalFiles, optionOverrides) {
175
- tsconfigPath = (0, import_path.resolve)(basePath, tsconfigPath);
176
- const parsed = parseTsconfigFile(tsconfigPath, (0, import_path.dirname)(tsconfigPath));
177
- const options = optionOverrides ? __spreadValues(__spreadValues({}, parsed.options), optionOverrides) : parsed.options;
178
- const host = createMigrationCompilerHost(tree, options, basePath, fakeFileRead);
179
- return { rootNames: parsed.fileNames.concat(additionalFiles || []), options, host };
180
- }
181
- function createMigrationCompilerHost(tree, options, basePath, fakeRead) {
182
- const host = import_typescript2.default.createCompilerHost(options, true);
183
- const defaultReadFile = host.readFile;
184
- host.readFile = (fileName) => {
185
- var _a;
186
- const treeRelativePath = (0, import_path.relative)(basePath, fileName);
187
- let result = fakeRead == null ? void 0 : fakeRead(treeRelativePath);
188
- if (typeof result !== "string") {
189
- result = treeRelativePath.startsWith("..") ? defaultReadFile.call(host, fileName) : (_a = tree.read(treeRelativePath)) == null ? void 0 : _a.toString();
190
- }
191
- return typeof result === "string" ? result.replace(/^\uFEFF/, "") : void 0;
192
- };
193
- return host;
194
- }
195
- function canMigrateFile(basePath, sourceFile, program) {
196
- if (sourceFile.fileName.endsWith(".ngtypecheck.ts") || sourceFile.isDeclarationFile || program.isSourceFileFromExternalLibrary(sourceFile)) {
197
- return false;
198
- }
199
- return !(0, import_path.relative)(basePath, sourceFile.fileName).startsWith("..");
200
- }
201
-
202
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/migrations/relative-link-resolution/util.mjs
203
- var import_typescript3 = __toESM(require("typescript"), 1);
204
- var relativeLinkResolution = "relativeLinkResolution";
205
- var knownConfigValues = /* @__PURE__ */ new Set([`'legacy'`, `'corrected'`]);
206
- function migrateFile(sourceFile, rewriteFn) {
207
- let rewrites = [];
208
- const usages = getUsages(sourceFile);
209
- for (const { objectLiteral, property } of usages) {
210
- const replacementNode = import_typescript3.default.factory.updateObjectLiteralExpression(objectLiteral, objectLiteral.properties.filter((prop) => prop !== property));
211
- const printer = import_typescript3.default.createPrinter();
212
- const replacementText = printer.printNode(import_typescript3.default.EmitHint.Unspecified, replacementNode, sourceFile);
213
- rewrites.push({
214
- startPos: objectLiteral.getStart(),
215
- width: objectLiteral.getWidth(),
216
- replacement: replacementText
217
- });
218
- }
219
- rewrites = sortByStartPosDescending(rewrites);
220
- for (const rewrite of rewrites) {
221
- rewriteFn(rewrite.startPos, rewrite.width, rewrite.replacement);
222
- }
223
- }
224
- function getUsages(sourceFile) {
225
- const usages = [];
226
- const visitNode = (node) => {
227
- if (import_typescript3.default.isObjectLiteralExpression(node)) {
228
- const property = node.properties.find((prop) => import_typescript3.default.isPropertyAssignment(prop) && import_typescript3.default.isIdentifier(prop.name) && prop.name.text === relativeLinkResolution && knownConfigValues.has(prop.initializer.getText()));
229
- if (property) {
230
- usages.push({ objectLiteral: node, property });
231
- }
232
- }
233
- import_typescript3.default.forEachChild(node, visitNode);
234
- };
235
- import_typescript3.default.forEachChild(sourceFile, visitNode);
236
- return usages;
237
- }
238
- function sortByStartPosDescending(rewrites) {
239
- return rewrites.sort((entityA, entityB) => entityB.startPos - entityA.startPos);
240
- }
241
-
242
- // bazel-out/k8-fastbuild/bin/packages/core/schematics/migrations/relative-link-resolution/index.mjs
243
- function relative_link_resolution_default() {
244
- return (tree) => __async(this, null, function* () {
245
- const { buildPaths, testPaths } = yield getProjectTsConfigPaths(tree);
246
- const basePath = process.cwd();
247
- const allPaths = [...buildPaths, ...testPaths];
248
- if (!allPaths.length) {
249
- throw new import_schematics.SchematicsException("Could not find any tsconfig file. Cannot run a migration to cleanup the deprecated `relativeLinkResolution` config option.");
250
- }
251
- for (const tsconfigPath of allPaths) {
252
- runRelativeLinkResolutionMigration(tree, tsconfigPath, basePath);
253
- }
254
- });
255
- }
256
- function runRelativeLinkResolutionMigration(tree, tsconfigPath, basePath) {
257
- const program = createMigrationProgram(tree, tsconfigPath, basePath);
258
- const sourceFiles = program.getSourceFiles().filter((sourceFile) => canMigrateFile(basePath, sourceFile, program));
259
- for (const sourceFile of sourceFiles) {
260
- let update = null;
261
- const rewriter = (startPos, origLength, text) => {
262
- if (update === null) {
263
- update = tree.beginUpdate((0, import_path2.relative)(basePath, sourceFile.fileName));
264
- }
265
- update.remove(startPos, origLength);
266
- update.insertLeft(startPos, text);
267
- };
268
- migrateFile(sourceFile, rewriter);
269
- if (update !== null) {
270
- tree.commitUpdate(update);
271
- }
272
- }
273
- }
274
- // Annotate the CommonJS export names for ESM import in node:
275
- 0 && (module.exports = {});
276
- /**
277
- * @license
278
- * Copyright Google LLC All Rights Reserved.
279
- *
280
- * Use of this source code is governed by an MIT-style license that can be
281
- * found in the LICENSE file at https://angular.io/license
282
- */
283
- //# sourceMappingURL=bundle.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../packages/core/schematics/migrations/relative-link-resolution/index.ts", "../../../../../../../../packages/core/schematics/utils/project_tsconfig_paths.ts", "../../../../../../../../packages/core/schematics/utils/typescript/compiler_host.ts", "../../../../../../../../packages/core/schematics/utils/typescript/parse_tsconfig.ts", "../../../../../../../../packages/core/schematics/migrations/relative-link-resolution/util.ts"],
4
- "sourcesContent": ["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Rule, SchematicsException, Tree, UpdateRecorder} from '@angular-devkit/schematics';\nimport {relative} from 'path';\n\nimport {getProjectTsConfigPaths} from '../../utils/project_tsconfig_paths';\nimport {canMigrateFile, createMigrationProgram} from '../../utils/typescript/compiler_host';\n\nimport {migrateFile} from './util';\n\nexport default function(): Rule {\n return async (tree: Tree) => {\n const {buildPaths, testPaths} = await getProjectTsConfigPaths(tree);\n const basePath = process.cwd();\n const allPaths = [...buildPaths, ...testPaths];\n\n if (!allPaths.length) {\n throw new SchematicsException(\n 'Could not find any tsconfig file. ' +\n 'Cannot run a migration to cleanup the deprecated `relativeLinkResolution` config option.');\n }\n\n for (const tsconfigPath of allPaths) {\n runRelativeLinkResolutionMigration(tree, tsconfigPath, basePath);\n }\n };\n}\n\nfunction runRelativeLinkResolutionMigration(tree: Tree, tsconfigPath: string, basePath: string) {\n const program = createMigrationProgram(tree, tsconfigPath, basePath);\n const sourceFiles =\n program.getSourceFiles().filter(sourceFile => canMigrateFile(basePath, sourceFile, program));\n\n for (const sourceFile of sourceFiles) {\n let update: UpdateRecorder|null = null;\n\n const rewriter = (startPos: number, origLength: number, text: string) => {\n if (update === null) {\n // Lazily initialize update, because most files will not require migration.\n update = tree.beginUpdate(relative(basePath, sourceFile.fileName));\n }\n update.remove(startPos, origLength);\n update.insertLeft(startPos, text);\n };\n\n migrateFile(sourceFile, rewriter);\n\n if (update !== null) {\n tree.commitUpdate(update);\n }\n }\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {json, normalize, virtualFs, workspaces} from '@angular-devkit/core';\nimport {Tree} from '@angular-devkit/schematics';\n\n/**\n * Gets all tsconfig paths from a CLI project by reading the workspace configuration\n * and looking for common tsconfig locations.\n */\nexport async function getProjectTsConfigPaths(tree: Tree):\n Promise<{buildPaths: string[]; testPaths: string[];}> {\n // Start with some tsconfig paths that are generally used within CLI projects. Note\n // that we are not interested in IDE-specific tsconfig files (e.g. /tsconfig.json)\n const buildPaths = new Set<string>();\n const testPaths = new Set<string>();\n\n const workspace = await getWorkspace(tree);\n for (const [, project] of workspace.projects) {\n for (const [name, target] of project.targets) {\n if (name !== 'build' && name !== 'test') {\n continue;\n }\n\n for (const [, options] of allTargetOptions(target)) {\n const tsConfig = options.tsConfig;\n // Filter out tsconfig files that don't exist in the CLI project.\n if (typeof tsConfig !== 'string' || !tree.exists(tsConfig)) {\n continue;\n }\n\n if (name === 'build') {\n buildPaths.add(normalize(tsConfig));\n } else {\n testPaths.add(normalize(tsConfig));\n }\n }\n }\n }\n\n return {\n buildPaths: [...buildPaths],\n testPaths: [...testPaths],\n };\n}\n\n/** Get options for all configurations for the passed builder target. */\nfunction*\n allTargetOptions(target: workspaces.TargetDefinition):\n Iterable<[string | undefined, Record<string, json.JsonValue|undefined>]> {\n if (target.options) {\n yield [undefined, target.options];\n }\n\n if (!target.configurations) {\n return;\n }\n\n for (const [name, options] of Object.entries(target.configurations)) {\n if (options) {\n yield [name, options];\n }\n }\n}\n\nfunction createHost(tree: Tree): workspaces.WorkspaceHost {\n return {\n async readFile(path: string): Promise<string> {\n const data = tree.read(path);\n if (!data) {\n throw new Error('File not found.');\n }\n\n return virtualFs.fileBufferToString(data);\n },\n async writeFile(path: string, data: string): Promise<void> {\n return tree.overwrite(path, data);\n },\n async isDirectory(path: string): Promise<boolean> {\n // Approximate a directory check.\n // We don't need to consider empty directories and hence this is a good enough approach.\n // This is also per documentation, see:\n // https://angular.io/guide/schematics-for-libraries#get-the-project-configuration\n return !tree.exists(path) && tree.getDir(path).subfiles.length > 0;\n },\n async isFile(path: string): Promise<boolean> {\n return tree.exists(path);\n },\n };\n}\n\nasync function getWorkspace(tree: Tree): Promise<workspaces.WorkspaceDefinition> {\n const host = createHost(tree);\n const {workspace} = await workspaces.readWorkspace('/', host);\n\n return workspace;\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {Tree} from '@angular-devkit/schematics';\nimport {dirname, relative, resolve} from 'path';\nimport ts from 'typescript';\n\nimport {parseTsconfigFile} from './parse_tsconfig';\n\ntype FakeReadFileFn = (fileName: string) => string|undefined;\n\n/**\n * Creates a TypeScript program instance for a TypeScript project within\n * the virtual file system tree.\n * @param tree Virtual file system tree that contains the source files.\n * @param tsconfigPath Virtual file system path that resolves to the TypeScript project.\n * @param basePath Base path for the virtual file system tree.\n * @param fakeFileRead Optional file reader function. Can be used to overwrite files in\n * the TypeScript program, or to add in-memory files (e.g. to add global types).\n * @param additionalFiles Additional file paths that should be added to the program.\n */\nexport function createMigrationProgram(\n tree: Tree, tsconfigPath: string, basePath: string, fakeFileRead?: FakeReadFileFn,\n additionalFiles?: string[]) {\n const {rootNames, options, host} =\n createProgramOptions(tree, tsconfigPath, basePath, fakeFileRead, additionalFiles);\n return ts.createProgram(rootNames, options, host);\n}\n\n/**\n * Creates the options necessary to instantiate a TypeScript program.\n * @param tree Virtual file system tree that contains the source files.\n * @param tsconfigPath Virtual file system path that resolves to the TypeScript project.\n * @param basePath Base path for the virtual file system tree.\n * @param fakeFileRead Optional file reader function. Can be used to overwrite files in\n * the TypeScript program, or to add in-memory files (e.g. to add global types).\n * @param additionalFiles Additional file paths that should be added to the program.\n * @param optionOverrides Overrides of the parsed compiler options.\n */\nexport function createProgramOptions(\n tree: Tree, tsconfigPath: string, basePath: string, fakeFileRead?: FakeReadFileFn,\n additionalFiles?: string[], optionOverrides?: ts.CompilerOptions) {\n // Resolve the tsconfig path to an absolute path. This is needed as TypeScript otherwise\n // is not able to resolve root directories in the given tsconfig. More details can be found\n // in the following issue: https://github.com/microsoft/TypeScript/issues/37731.\n tsconfigPath = resolve(basePath, tsconfigPath);\n const parsed = parseTsconfigFile(tsconfigPath, dirname(tsconfigPath));\n const options = optionOverrides ? {...parsed.options, ...optionOverrides} : parsed.options;\n const host = createMigrationCompilerHost(tree, options, basePath, fakeFileRead);\n return {rootNames: parsed.fileNames.concat(additionalFiles || []), options, host};\n}\n\nfunction createMigrationCompilerHost(\n tree: Tree, options: ts.CompilerOptions, basePath: string,\n fakeRead?: FakeReadFileFn): ts.CompilerHost {\n const host = ts.createCompilerHost(options, true);\n const defaultReadFile = host.readFile;\n\n // We need to overwrite the host \"readFile\" method, as we want the TypeScript\n // program to be based on the file contents in the virtual file tree. Otherwise\n // if we run multiple migrations we might have intersecting changes and\n // source files.\n host.readFile = fileName => {\n const treeRelativePath = relative(basePath, fileName);\n let result: string|undefined = fakeRead?.(treeRelativePath);\n\n if (typeof result !== 'string') {\n // If the relative path resolved to somewhere outside of the tree, fall back to\n // TypeScript's default file reading function since the `tree` will throw an error.\n result = treeRelativePath.startsWith('..') ? defaultReadFile.call(host, fileName) :\n tree.read(treeRelativePath)?.toString();\n }\n\n // Strip BOM as otherwise TSC methods (Ex: getWidth) will return an offset,\n // which breaks the CLI UpdateRecorder.\n // See: https://github.com/angular/angular/pull/30719\n return typeof result === 'string' ? result.replace(/^\\uFEFF/, '') : undefined;\n };\n\n return host;\n}\n\n/**\n * Checks whether a file can be migrate by our automated migrations.\n * @param basePath Absolute path to the project.\n * @param sourceFile File being checked.\n * @param program Program that includes the source file.\n */\nexport function canMigrateFile(\n basePath: string, sourceFile: ts.SourceFile, program: ts.Program): boolean {\n // We shouldn't migrate .d.ts files, files from an external library or type checking files.\n if (sourceFile.fileName.endsWith('.ngtypecheck.ts') || sourceFile.isDeclarationFile ||\n program.isSourceFileFromExternalLibrary(sourceFile)) {\n return false;\n }\n\n // Our migrations are set up to create a `Program` from the project's tsconfig and to migrate all\n // the files within the program. This can include files that are outside of the Angular CLI\n // project. We can't migrate files outside of the project, because our file system interactions\n // go through the CLI's `Tree` which assumes that all files are within the project. See:\n // https://github.com/angular/angular-cli/blob/0b0961c9c233a825b6e4bb59ab7f0790f9b14676/packages/angular_devkit/schematics/src/tree/host-tree.ts#L131\n return !relative(basePath, sourceFile.fileName).startsWith('..');\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport * as path from 'path';\nimport ts from 'typescript';\n\nexport function parseTsconfigFile(tsconfigPath: string, basePath: string): ts.ParsedCommandLine {\n const {config} = ts.readConfigFile(tsconfigPath, ts.sys.readFile);\n const parseConfigHost = {\n useCaseSensitiveFileNames: ts.sys.useCaseSensitiveFileNames,\n fileExists: ts.sys.fileExists,\n readDirectory: ts.sys.readDirectory,\n readFile: ts.sys.readFile,\n };\n\n // Throw if incorrect arguments are passed to this function. Passing relative base paths\n // results in root directories not being resolved and in later type checking runtime errors.\n // More details can be found here: https://github.com/microsoft/TypeScript/issues/37731.\n if (!path.isAbsolute(basePath)) {\n throw Error('Unexpected relative base path has been specified.');\n }\n\n return ts.parseJsonConfigFileContent(config, parseConfigHost, basePath, {});\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport ts from 'typescript';\n\nconst relativeLinkResolution = 'relativeLinkResolution';\nconst knownConfigValues = new Set([`'legacy'`, `'corrected'`]);\n\nexport interface RewriteEntity {\n startPos: number;\n width: number;\n replacement: string;\n}\n\nexport interface MigratableNode {\n objectLiteral: ts.ObjectLiteralExpression;\n property: ts.ObjectLiteralElementLike;\n}\n\nexport type RewriteFn = (startPos: number, origLength: number, text: string) => void;\n\nexport function migrateFile(sourceFile: ts.SourceFile, rewriteFn: RewriteFn) {\n let rewrites: RewriteEntity[] = [];\n const usages = getUsages(sourceFile);\n for (const {objectLiteral, property} of usages) {\n const replacementNode = ts.factory.updateObjectLiteralExpression(\n objectLiteral, objectLiteral.properties.filter(prop => prop !== property));\n const printer = ts.createPrinter();\n const replacementText = printer.printNode(ts.EmitHint.Unspecified, replacementNode, sourceFile);\n rewrites.push({\n startPos: objectLiteral.getStart(),\n width: objectLiteral.getWidth(),\n replacement: replacementText,\n });\n }\n\n // Process rewrites last-to-first (based on start pos) to avoid offset shifts during rewrites.\n rewrites = sortByStartPosDescending(rewrites);\n for (const rewrite of rewrites) {\n rewriteFn(rewrite.startPos, rewrite.width, rewrite.replacement);\n }\n}\n\nfunction getUsages(sourceFile: ts.SourceFile): MigratableNode[] {\n const usages: MigratableNode[] = [];\n const visitNode = (node: ts.Node) => {\n if (ts.isObjectLiteralExpression(node)) {\n // Look for patterns like the following:\n // ```\n // { ... relativeLinkResolution: 'legacy', ... }\n // ```\n // or:\n // ```\n // { ... relativeLinkResolution: 'corrected', ... }\n // ```\n // If the value is unknown (i.e. not 'legacy' or 'corrected'),\n // do not attempt to rewrite (this might be an application-specific\n // configuration, not a part of Router).\n const property = node.properties.find(\n prop => ts.isPropertyAssignment(prop) && ts.isIdentifier(prop.name) &&\n prop.name.text === relativeLinkResolution &&\n knownConfigValues.has(prop.initializer.getText()));\n if (property) {\n usages.push({objectLiteral: node, property});\n }\n }\n ts.forEachChild(node, visitNode);\n };\n ts.forEachChild(sourceFile, visitNode);\n return usages;\n}\n\n/**\n * Sort all found usages based on their start positions in the source file in descending order (i.e.\n * last usage goes first on the list, etc). This is needed to avoid shifting offsets in the source\n * file (in case there are multiple usages) as we rewrite symbols.\n */\nfunction sortByStartPosDesc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,MAAM,cAAc,QAAQ;;EAEnE;AACF;AAEA,SAAS,mCAAmC,MAAY,cAAsB,UAAgB;AAC5F,QAAM,UAAU,uBAAuB,MAAM,cAAc,QAAQ;AACnE,QAAM,cACF,QAAQ,eAAc,EAAG,OAAO,gBAAc,eAAe,UAAU,YAAY,OAAO,CAAC;AAE/F,aAAW,cAAc,aAAa;AACpC,QAAI,SAA8B;AAElC,UAAM,WAAW,CAAC,UAAkB,YAAoB,SAAgB;AACtE,UAAI,WAAW,MAAM;AAEnB,iBAAS,KAAK,gBAAY,uBAAS,UAAU,WAAW,QAAQ,CAAC;;AAEnE,aAAO,OAAO,UAAU,UAAU;AAClC,aAAO,WAAW,UAAU,IAAI;IAClC;AAEA,gBAAY,YAAY,QAAQ;AAEhC,QAAI,WAAW,MAAM;AACnB,WAAK,aAAa,MAAM;;;AAG9B;",
6
- "names": ["import_path", "path", "import_typescript", "ts", "ts", "import_typescript", "ts"]
7
- }
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../../../packages/core/schematics/migrations/router-link-with-href/index.ts", "../../../../../../../../packages/core/schematics/utils/project_tsconfig_paths.ts", "../../../../../../../../packages/core/schematics/utils/typescript/compiler_host.ts", "../../../../../../../../packages/core/schematics/utils/typescript/parse_tsconfig.ts", "../../../../../../../../packages/core/schematics/migrations/router-link-with-href/util.ts", "../../../../../../../../packages/core/schematics/utils/typescript/imports.ts", "../../../../../../../../packages/core/schematics/utils/typescript/nodes.ts"],
4
- "sourcesContent": ["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Rule, SchematicsException, Tree, UpdateRecorder} from '@angular-devkit/schematics';\nimport {relative} from 'path';\n\nimport {getProjectTsConfigPaths} from '../../utils/project_tsconfig_paths';\nimport {canMigrateFile, createMigrationProgram} from '../../utils/typescript/compiler_host';\n\nimport {migrateFile} from './util';\n\nexport default function(): Rule {\n return async (tree: Tree) => {\n const {buildPaths, testPaths} = await getProjectTsConfigPaths(tree);\n const basePath = process.cwd();\n const allPaths = [...buildPaths, ...testPaths];\n\n if (!allPaths.length) {\n throw new SchematicsException(\n 'Could not find any tsconfig file. Cannot run the `RouterLinkWithHref` migration.');\n }\n\n for (const tsconfigPath of allPaths) {\n runRouterLinkWithHrefMigration(tree, tsconfigPath, basePath);\n }\n };\n}\n\nfunction runRouterLinkWithHrefMigration(tree: Tree, tsconfigPath: string, basePath: string) {\n const program = createMigrationProgram(tree, tsconfigPath, basePath);\n const typeChecker = program.getTypeChecker();\n const sourceFiles =\n program.getSourceFiles().filter(sourceFile => canMigrateFile(basePath, sourceFile, program));\n\n for (const sourceFile of sourceFiles) {\n let update: UpdateRecorder|null = null;\n\n const rewriter = (startPos: number, width: number, text: string|null) => {\n if (update === null) {\n // Lazily initialize update, because most files will not require migration.\n update = tree.beginUpdate(relative(basePath, sourceFile.fileName));\n }\n update.remove(startPos, width);\n if (text !== null) {\n update.insertLeft(startPos, text);\n }\n };\n\n migrateFile(sourceFile, typeChecker, rewriter);\n\n if (update !== null) {\n tree.commitUpdate(update);\n }\n }\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {json, normalize, virtualFs, workspaces} from '@angular-devkit/core';\nimport {Tree} from '@angular-devkit/schematics';\n\n/**\n * Gets all tsconfig paths from a CLI project by reading the workspace configuration\n * and looking for common tsconfig locations.\n */\nexport async function getProjectTsConfigPaths(tree: Tree):\n Promise<{buildPaths: string[]; testPaths: string[];}> {\n // Start with some tsconfig paths that are generally used within CLI projects. Note\n // that we are not interested in IDE-specific tsconfig files (e.g. /tsconfig.json)\n const buildPaths = new Set<string>();\n const testPaths = new Set<string>();\n\n const workspace = await getWorkspace(tree);\n for (const [, project] of workspace.projects) {\n for (const [name, target] of project.targets) {\n if (name !== 'build' && name !== 'test') {\n continue;\n }\n\n for (const [, options] of allTargetOptions(target)) {\n const tsConfig = options.tsConfig;\n // Filter out tsconfig files that don't exist in the CLI project.\n if (typeof tsConfig !== 'string' || !tree.exists(tsConfig)) {\n continue;\n }\n\n if (name === 'build') {\n buildPaths.add(normalize(tsConfig));\n } else {\n testPaths.add(normalize(tsConfig));\n }\n }\n }\n }\n\n return {\n buildPaths: [...buildPaths],\n testPaths: [...testPaths],\n };\n}\n\n/** Get options for all configurations for the passed builder target. */\nfunction*\n allTargetOptions(target: workspaces.TargetDefinition):\n Iterable<[string | undefined, Record<string, json.JsonValue|undefined>]> {\n if (target.options) {\n yield [undefined, target.options];\n }\n\n if (!target.configurations) {\n return;\n }\n\n for (const [name, options] of Object.entries(target.configurations)) {\n if (options) {\n yield [name, options];\n }\n }\n}\n\nfunction createHost(tree: Tree): workspaces.WorkspaceHost {\n return {\n async readFile(path: string): Promise<string> {\n const data = tree.read(path);\n if (!data) {\n throw new Error('File not found.');\n }\n\n return virtualFs.fileBufferToString(data);\n },\n async writeFile(path: string, data: string): Promise<void> {\n return tree.overwrite(path, data);\n },\n async isDirectory(path: string): Promise<boolean> {\n // Approximate a directory check.\n // We don't need to consider empty directories and hence this is a good enough approach.\n // This is also per documentation, see:\n // https://angular.io/guide/schematics-for-libraries#get-the-project-configuration\n return !tree.exists(path) && tree.getDir(path).subfiles.length > 0;\n },\n async isFile(path: string): Promise<boolean> {\n return tree.exists(path);\n },\n };\n}\n\nasync function getWorkspace(tree: Tree): Promise<workspaces.WorkspaceDefinition> {\n const host = createHost(tree);\n const {workspace} = await workspaces.readWorkspace('/', host);\n\n return workspace;\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {Tree} from '@angular-devkit/schematics';\nimport {dirname, relative, resolve} from 'path';\nimport ts from 'typescript';\n\nimport {parseTsconfigFile} from './parse_tsconfig';\n\ntype FakeReadFileFn = (fileName: string) => string|undefined;\n\n/**\n * Creates a TypeScript program instance for a TypeScript project within\n * the virtual file system tree.\n * @param tree Virtual file system tree that contains the source files.\n * @param tsconfigPath Virtual file system path that resolves to the TypeScript project.\n * @param basePath Base path for the virtual file system tree.\n * @param fakeFileRead Optional file reader function. Can be used to overwrite files in\n * the TypeScript program, or to add in-memory files (e.g. to add global types).\n * @param additionalFiles Additional file paths that should be added to the program.\n */\nexport function createMigrationProgram(\n tree: Tree, tsconfigPath: string, basePath: string, fakeFileRead?: FakeReadFileFn,\n additionalFiles?: string[]) {\n const {rootNames, options, host} =\n createProgramOptions(tree, tsconfigPath, basePath, fakeFileRead, additionalFiles);\n return ts.createProgram(rootNames, options, host);\n}\n\n/**\n * Creates the options necessary to instantiate a TypeScript program.\n * @param tree Virtual file system tree that contains the source files.\n * @param tsconfigPath Virtual file system path that resolves to the TypeScript project.\n * @param basePath Base path for the virtual file system tree.\n * @param fakeFileRead Optional file reader function. Can be used to overwrite files in\n * the TypeScript program, or to add in-memory files (e.g. to add global types).\n * @param additionalFiles Additional file paths that should be added to the program.\n * @param optionOverrides Overrides of the parsed compiler options.\n */\nexport function createProgramOptions(\n tree: Tree, tsconfigPath: string, basePath: string, fakeFileRead?: FakeReadFileFn,\n additionalFiles?: string[], optionOverrides?: ts.CompilerOptions) {\n // Resolve the tsconfig path to an absolute path. This is needed as TypeScript otherwise\n // is not able to resolve root directories in the given tsconfig. More details can be found\n // in the following issue: https://github.com/microsoft/TypeScript/issues/37731.\n tsconfigPath = resolve(basePath, tsconfigPath);\n const parsed = parseTsconfigFile(tsconfigPath, dirname(tsconfigPath));\n const options = optionOverrides ? {...parsed.options, ...optionOverrides} : parsed.options;\n const host = createMigrationCompilerHost(tree, options, basePath, fakeFileRead);\n return {rootNames: parsed.fileNames.concat(additionalFiles || []), options, host};\n}\n\nfunction createMigrationCompilerHost(\n tree: Tree, options: ts.CompilerOptions, basePath: string,\n fakeRead?: FakeReadFileFn): ts.CompilerHost {\n const host = ts.createCompilerHost(options, true);\n const defaultReadFile = host.readFile;\n\n // We need to overwrite the host \"readFile\" method, as we want the TypeScript\n // program to be based on the file contents in the virtual file tree. Otherwise\n // if we run multiple migrations we might have intersecting changes and\n // source files.\n host.readFile = fileName => {\n const treeRelativePath = relative(basePath, fileName);\n let result: string|undefined = fakeRead?.(treeRelativePath);\n\n if (typeof result !== 'string') {\n // If the relative path resolved to somewhere outside of the tree, fall back to\n // TypeScript's default file reading function since the `tree` will throw an error.\n result = treeRelativePath.startsWith('..') ? defaultReadFile.call(host, fileName) :\n tree.read(treeRelativePath)?.toString();\n }\n\n // Strip BOM as otherwise TSC methods (Ex: getWidth) will return an offset,\n // which breaks the CLI UpdateRecorder.\n // See: https://github.com/angular/angular/pull/30719\n return typeof result === 'string' ? result.replace(/^\\uFEFF/, '') : undefined;\n };\n\n return host;\n}\n\n/**\n * Checks whether a file can be migrate by our automated migrations.\n * @param basePath Absolute path to the project.\n * @param sourceFile File being checked.\n * @param program Program that includes the source file.\n */\nexport function canMigrateFile(\n basePath: string, sourceFile: ts.SourceFile, program: ts.Program): boolean {\n // We shouldn't migrate .d.ts files, files from an external library or type checking files.\n if (sourceFile.fileName.endsWith('.ngtypecheck.ts') || sourceFile.isDeclarationFile ||\n program.isSourceFileFromExternalLibrary(sourceFile)) {\n return false;\n }\n\n // Our migrations are set up to create a `Program` from the project's tsconfig and to migrate all\n // the files within the program. This can include files that are outside of the Angular CLI\n // project. We can't migrate files outside of the project, because our file system interactions\n // go through the CLI's `Tree` which assumes that all files are within the project. See:\n // https://github.com/angular/angular-cli/blob/0b0961c9c233a825b6e4bb59ab7f0790f9b14676/packages/angular_devkit/schematics/src/tree/host-tree.ts#L131\n return !relative(basePath, sourceFile.fileName).startsWith('..');\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport * as path from 'path';\nimport ts from 'typescript';\n\nexport function parseTsconfigFile(tsconfigPath: string, basePath: string): ts.ParsedCommandLine {\n const {config} = ts.readConfigFile(tsconfigPath, ts.sys.readFile);\n const parseConfigHost = {\n useCaseSensitiveFileNames: ts.sys.useCaseSensitiveFileNames,\n fileExists: ts.sys.fileExists,\n readDirectory: ts.sys.readDirectory,\n readFile: ts.sys.readFile,\n };\n\n // Throw if incorrect arguments are passed to this function. Passing relative base paths\n // results in root directories not being resolved and in later type checking runtime errors.\n // More details can be found here: https://github.com/microsoft/TypeScript/issues/37731.\n if (!path.isAbsolute(basePath)) {\n throw Error('Unexpected relative base path has been specified.');\n }\n\n return ts.parseJsonConfigFileContent(config, parseConfigHost, basePath, {});\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport ts from 'typescript';\n\nimport {getImportOfIdentifier, getImportSpecifier, removeSymbolFromNamedImports} from '../../utils/typescript/imports';\nimport {closestNode} from '../../utils/typescript/nodes';\n\nexport const routerLink = 'RouterLink';\nexport const routerLinkWithHref = 'RouterLinkWithHref';\nexport const routerModule = '@angular/router';\n\nexport interface RewriteEntity {\n startPos: number;\n width: number;\n replacement: string;\n}\n\nexport type RewriteFn = (startPos: number, width: number, text: string) => void;\n\nexport function migrateFile(\n sourceFile: ts.SourceFile, typeChecker: ts.TypeChecker, rewrite: RewriteFn) {\n const routerLinkWithHrefSpec = getImportSpecifier(sourceFile, routerModule, routerLinkWithHref);\n\n // No `RouterLinkWithHref` found, nothing to migrate, exit early.\n if (routerLinkWithHrefSpec === null) return;\n\n let rewrites = findUsages(sourceFile, typeChecker);\n\n // There are some usages of the `RouterLinkWithHref` symbol, which need to\n // be rewritten to `RouterLink` instead. Let's check if the `RouterLink` is\n // already imported.\n const routerLinkSpec = getImportSpecifier(sourceFile, routerModule, routerLink);\n\n if (routerLinkSpec) {\n // The `RouterLink` symbol is already imported, just drop the `RouterLinkWithHref` one.\n const routerLinkNamedImports =\n routerLinkWithHrefSpec ? closestNode(routerLinkWithHrefSpec, ts.isNamedImports) : null;\n if (routerLinkNamedImports !== null) {\n // Given an original import like this one:\n // ```\n // import {RouterModule, RouterLinkWithHref, RouterLink} from '@angular/router';\n // ```\n // The code below removes the `RouterLinkWithHref` from the named imports section\n // (i.e. `{RouterModule, RouterLinkWithHref, RouterLink}`) and prints an updated\n // version (`{RouterModule, RouterLink}`) to a string, which is used as a\n // replacement.\n const rewrittenNamedImports =\n removeSymbolFromNamedImports(routerLinkNamedImports, routerLinkWithHrefSpec);\n const printer = ts.createPrinter();\n const replacement =\n printer.printNode(ts.EmitHint.Unspecified, rewrittenNamedImports, sourceFile);\n rewrites.push({\n startPos: routerLinkNamedImports.getStart(),\n width: routerLinkNamedImports.getWidth(),\n replacement: replacement,\n });\n }\n } else {\n // The `RouterLink` symbol is not imported, but the `RouterLinkWithHref` is imported,\n // so rewrite `RouterLinkWithHref` -> `RouterLink`.\n rewrites.push({\n startPos: routerLinkWithHrefSpec.getStart(),\n width: routerLinkWithHrefSpec.getWidth(),\n replacement: routerLink,\n });\n }\n\n // Process rewrites last-to-first (based on start pos) to avoid offset shifts during rewrites.\n rewrites = sortByStartPosDescending(rewrites);\n for (const usage of rewrites) {\n rewrite(usage.startPos, usage.width, usage.replacement);\n }\n}\n\nfunction findUsages(sourceFile: ts.SourceFile, typeChecker: ts.TypeChecker): RewriteEntity[] {\n const usages: RewriteEntity[] = [];\n const visitNode = (node: ts.Node) => {\n if (ts.isImportSpecifier(node)) {\n // Skip this node and all of its children; imports are a special case.\n return;\n }\n if (ts.isIdentifier(node)) {\n const importIdentifier = getImportOfIdentifier(typeChecker, node);\n if (importIdentifier?.importModule === routerModule &&\n importIdentifier.name === routerLinkWithHref) {\n usages.push({\n startPos: node.getStart(),\n width: node.getWidth(),\n replacement: routerLink,\n });\n }\n }\n ts.forEachChild(node, visitNode);\n };\n ts.forEachChild(sourceFile, visitNode);\n return usages;\n}\n\n/**\n * Sort all found usages based on their start positions in the source file in descending order (i.e.\n * last usage goes first on the list, etc). This is needed to avoid shifting offsets in the source\n * file (in case there are multiple usages) as we rewrite symbols.\n */\nfunction sortByStartPosDescending(rewrites: RewriteEntity[]): RewriteEntity[] {\n return rewrites.sort((entityA, entityB) => entityB.startPos - entityA.startPos);\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport ts from 'typescript';\n\nexport type Import = {\n name: string,\n importModule: string,\n node: ts.ImportDeclaration\n};\n\n/** Gets import information about the specified identifier by using the Type checker. */\nexport function getImportOfIdentifier(typeChecker: ts.TypeChecker, node: ts.Identifier): Import|\n null {\n const symbol = typeChecker.getSymbolAtLocation(node);\n\n if (!symbol || symbol.declarations === undefined || !symbol.declarations.length) {\n return null;\n }\n\n const decl = symbol.declarations[0];\n\n if (!ts.isImportSpecifier(decl)) {\n return null;\n }\n\n const importDecl = decl.parent.parent.parent;\n\n if (!ts.isStringLiteral(importDecl.moduleSpecifier)) {\n return null;\n }\n\n return {\n // Handles aliased imports: e.g. \"import {Component as myComp} from ...\";\n name: decl.propertyName ? decl.propertyName.text : decl.name.text,\n importModule: importDecl.moduleSpecifier.text,\n node: importDecl\n };\n}\n\n\n/**\n * Gets a top-level import specifier with a specific name that is imported from a particular module.\n * E.g. given a file that looks like:\n *\n * ```\n * import { Component, Directive } from '@angular/core';\n * import { Foo } from './foo';\n * ```\n *\n * Calling `getImportSpecifier(sourceFile, '@angular/core', 'Directive')` will yield the node\n * referring to `Directive` in the top import.\n *\n * @param sourceFile File in which to look for imports.\n * @param moduleName Name of the import's module.\n * @param specifierName Original name of the specifier to look for. Aliases will be resolved to\n * their original name.\n */\nexport function getImportSpecifier(\n sourceFile: ts.SourceFile, moduleName: string|RegExp,\n specifierName: string): ts.ImportSpecifier|null {\n for (const node of sourceFile.statements) {\n if (ts.isImportDeclaration(node) && ts.isStringLiteral(node.moduleSpecifier)) {\n const isMatch = typeof moduleName === 'string' ? node.moduleSpecifier.text === moduleName :\n moduleName.test(node.moduleSpecifier.text);\n const namedBindings = node.importClause?.namedBindings;\n if (isMatch && namedBindings && ts.isNamedImports(namedBindings)) {\n const match = findImportSpecifier(namedBindings.elements, specifierName);\n if (match) {\n return match;\n }\n }\n }\n }\n\n return null;\n}\n\n\n/**\n * Replaces an import inside a named imports node with a different one.\n *\n * @param node Node that contains the imports.\n * @param existingImport Import that should be replaced.\n * @param newImportName Import that should be inserted.\n */\nexport function replaceImport(\n node: ts.NamedImports, existingImport: string, newImportName: string) {\n const isAlreadyImported = findImportSpecifier(node.elements, newImportName);\n if (isAlreadyImported) {\n return node;\n }\n\n const existingImportNode = findImportSpecifier(node.elements, existingImport);\n if (!existingImportNode) {\n return node;\n }\n\n const importPropertyName =\n existingImportNode.propertyName ? ts.factory.createIdentifier(newImportName) : undefined;\n const importName = existingImportNode.propertyName ? existingImportNode.name :\n ts.factory.createIdentifier(newImportName);\n\n return ts.factory.updateNamedImports(node, [\n ...node.elements.filter(current => current !== existingImportNode),\n // Create a new import while trying to preserve the alias of the old one.\n ts.factory.createImportSpecifier(false, importPropertyName, importName)\n ]);\n}\n\n/**\n * Removes a symbol from the named imports and updates a node\n * that represents a given named imports.\n *\n * @param node Node that contains the imports.\n * @param symbol Symbol that should be removed.\n * @returns An updated node (ts.NamedImports).\n */\nexport function removeSymbolFromNamedImports(node: ts.NamedImports, symbol: ts.ImportSpecifier) {\n return ts.factory.updateNamedImports(node, [\n ...node.elements.filter(current => current !== symbol),\n ]);\n}\n\n/** Finds an import specifier with a particular name. */\nexport function findImportSpecifier(\n nodes: ts.NodeArray<ts.ImportSpecifier>, specifierName: string): ts.ImportSpecifier|undefined {\n return nodes.find(element => {\n const {name, propertyName} = element;\n return propertyName ? propertyName.text === specifierName : name.text === specifierName;\n });\n}\n", "/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport ts from 'typescript';\n\n/** Checks whether the given TypeScript node has the specified modifier set. */\nexport function hasModifier(node: ts.Node, modifierKind: ts.SyntaxKind) {\n return ts.canHaveModifiers(node) && !!node.modifiers &&\n node.modifiers.some(m => m.kind === modifierKind);\n}\n\n/** Find the closest parent node of a particular kind. */\nexport function closestNode<T extends ts.Node>(node: ts.Node, predicate: (n: ts.Node) => n is T): T|\n null {\n let current = node.parent;\n\n while (current && !ts.isSourceFile(current)) {\n if (predicate(current)) {\n return current;\n }\n current = current.parent;\n }\n\n return null;\n}\n\n/**\n * Checks whether a particular node is part of a null check. E.g. given:\n * `foo.bar ? foo.bar.value : null` the null check would be `foo.bar`.\n */\nexport function isNullCheck(node: ts.Node): boolean {\n if (!node.parent) {\n return false;\n }\n\n // `foo.bar && foo.bar.value` where `node` is `foo.bar`.\n if (ts.isBinaryExpression(node.parent) && node.parent.left === node) {\n return true;\n }\n\n // `foo.bar && foo.bar.parent && foo.bar.parent.value`\n // where `node` is `foo.bar`.\n if (node.parent.parent && ts.isBinaryExpression(node.parent.parent) &&\n node.parent.parent.left === node.parent) {\n return true;\n }\n\n // `if (foo.bar) {...}` where `node` is `foo.bar`.\n if (ts.isIfStatement(node.parent) && node.parent.expression === node) {\n return true;\n }\n\n // `foo.bar ? foo.bar.value : null` where `node` is `foo.bar`.\n if (ts.isConditionalExpression(node.parent) && node.parent.condition === node) {\n return true;\n }\n\n return false;\n}\n\n/** Checks whether a property access is safe (e.g. `foo.parent?.value`). */\nexport function isSafeAccess(node: ts.Node): boolean {\n return node.parent != null && ts.isPropertyAccessExpression(node.parent) &&\n node.parent.expression === node && node.parent.questionDotToken != null;\n}\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;AAQA,wBAA8D;AAC9D,IAAAA,eAAuB;;;ACDvB,kBAAqD;AAOrD,SAAsB,wBAAwB,MAAU;;AAItD,UA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AAClE,UAAM,WAAW,QAAQ,IAAG;AAC5B,UAAM,WAAW,CAAC,GAAG,YAAY,GAAG,SAAS;AAE7C,QAAI,CAAC,SAAS,QAAQ;AACpB,YAAM,IAAI,sCACN,kFAAkF;;AAGxF,eAAW,gBAAgB,UAAU;AACnC,qCAA+B,MAAM,cAAc,QAAQ;;EAE/D;AACF;AAEA,SAAS,+BAA+B,MAAY,cAAsB,UAAgB;AACxF,QAAM,UAAU,uBAAuB,MAAM,cAAc,QAAQ;AACnE,QAAM,cAAc,QAAQ,eAAc;AAC1C,QAAM,cACF,QAAQ,eAAc,EAAG,OAAO,gBAAc,eAAe,UAAU,YAAY,OAAO,CAAC;AAE/F,aAAW,cAAc,aAAa;AACpC,QAAI,SAA8B;AAElC,UAAM,WAAW,CAAC,UAAkB,OAAe,SAAqB;AACtE,UAAI,WAAW,MAAM;AAEnB,iBAAS,KAAK,gBAAY,uBAAS,UAAU,WAAW,QAAQ,CAAC;;AAEnE,aAAO,OAAO,UAAU,KAAK;AAC7B,UAAI,SAAS,MAAM;AACjB,eAAO,WAAW,UAAU,IAAI;;IAEpC;AAEA,gBAAY,YAAY,aAAa,QAAQ;AAE7C,QAAI,WAAW,MAAM;AACnB,WAAK,aAAa,MAAM;;;AAG9B;",
6
- "names": ["import_path", "path", "import_typescript", "ts", "ts", "import_typescript", "import_typescript", "ts", "ts", "import_typescript", "ts", "ts"]
7
- }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes