@angular/cdk 20.0.0-next.0 → 20.0.0-next.10

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 (401) hide show
  1. package/_adev_assets/cdk_testing.json +1 -0
  2. package/_adev_assets/cdk_testing_protractor.json +1 -0
  3. package/_adev_assets/cdk_testing_selenium_webdriver.json +1 -0
  4. package/_adev_assets/cdk_testing_testbed.json +1 -0
  5. package/a11y/index.d.ts +330 -1234
  6. package/a11y-module.d-DBHGyKoh.d.ts +314 -0
  7. package/a11y-prebuilt.css +1 -1
  8. package/accordion/index.d.ts +8 -27
  9. package/activedescendant-key-manager.d-Bjic5obv.d.ts +32 -0
  10. package/bidi/index.d.ts +3 -62
  11. package/bidi-module.d-IN1Vp56w.d.ts +57 -0
  12. package/clipboard/index.d.ts +62 -75
  13. package/coercion/index.d.ts +11 -33
  14. package/coercion/private/index.d.ts +2 -2
  15. package/collections/index.d.ts +14 -291
  16. package/data-source.d-Bblv7Zvh.d.ts +43 -0
  17. package/dialog/index.d.ts +217 -255
  18. package/drag-drop/index.d.ts +1085 -1157
  19. package/fesm2022/a11y-module-DpEjWNCj.mjs +951 -0
  20. package/fesm2022/a11y-module-DpEjWNCj.mjs.map +1 -0
  21. package/fesm2022/a11y.mjs +47 -2446
  22. package/fesm2022/a11y.mjs.map +1 -1
  23. package/fesm2022/accordion.mjs +12 -16
  24. package/fesm2022/accordion.mjs.map +1 -1
  25. package/fesm2022/activedescendant-key-manager-DC3-fwQI.mjs +16 -0
  26. package/fesm2022/activedescendant-key-manager-DC3-fwQI.mjs.map +1 -0
  27. package/fesm2022/array-I1yfCXUO.mjs +6 -0
  28. package/fesm2022/array-I1yfCXUO.mjs.map +1 -0
  29. package/fesm2022/bidi.mjs +17 -83
  30. package/fesm2022/bidi.mjs.map +1 -1
  31. package/fesm2022/breakpoints-observer-DpQzdtrE.mjs +179 -0
  32. package/fesm2022/breakpoints-observer-DpQzdtrE.mjs.map +1 -0
  33. package/fesm2022/cdk.mjs +1 -1
  34. package/fesm2022/cdk.mjs.map +1 -1
  35. package/fesm2022/clipboard.mjs +11 -16
  36. package/fesm2022/clipboard.mjs.map +1 -1
  37. package/fesm2022/coercion/private.mjs +0 -4
  38. package/fesm2022/coercion/private.mjs.map +1 -1
  39. package/fesm2022/coercion.mjs +5 -39
  40. package/fesm2022/coercion.mjs.map +1 -1
  41. package/fesm2022/collections.mjs +7 -476
  42. package/fesm2022/collections.mjs.map +1 -1
  43. package/fesm2022/css-pixel-value-C_HEqLhI.mjs +10 -0
  44. package/fesm2022/css-pixel-value-C_HEqLhI.mjs.map +1 -0
  45. package/fesm2022/data-source-D34wiQZj.mjs +15 -0
  46. package/fesm2022/data-source-D34wiQZj.mjs.map +1 -0
  47. package/fesm2022/dialog.mjs +88 -73
  48. package/fesm2022/dialog.mjs.map +1 -1
  49. package/fesm2022/directionality-Ck5Uc9Se.mjs +77 -0
  50. package/fesm2022/directionality-Ck5Uc9Se.mjs.map +1 -0
  51. package/fesm2022/dispose-view-repeater-strategy-D_JReLI1.mjs +44 -0
  52. package/fesm2022/dispose-view-repeater-strategy-D_JReLI1.mjs.map +1 -0
  53. package/fesm2022/drag-drop.mjs +128 -65
  54. package/fesm2022/drag-drop.mjs.map +1 -1
  55. package/fesm2022/element-x4z00URv.mjs +29 -0
  56. package/fesm2022/element-x4z00URv.mjs.map +1 -0
  57. package/fesm2022/fake-event-detection-DWOdFTFz.mjs +24 -0
  58. package/fesm2022/fake-event-detection-DWOdFTFz.mjs.map +1 -0
  59. package/fesm2022/focus-key-manager-C1rAQJ5z.mjs +22 -0
  60. package/fesm2022/focus-key-manager-C1rAQJ5z.mjs.map +1 -0
  61. package/fesm2022/focus-monitor-DKFfep8Q.mjs +627 -0
  62. package/fesm2022/focus-monitor-DKFfep8Q.mjs.map +1 -0
  63. package/fesm2022/id-generator-BwB8lolC.mjs +37 -0
  64. package/fesm2022/id-generator-BwB8lolC.mjs.map +1 -0
  65. package/fesm2022/keycodes-CpHkExLC.mjs +122 -0
  66. package/fesm2022/keycodes-CpHkExLC.mjs.map +1 -0
  67. package/fesm2022/keycodes.mjs +2 -124
  68. package/fesm2022/keycodes.mjs.map +1 -1
  69. package/fesm2022/layout.mjs +12 -184
  70. package/fesm2022/layout.mjs.map +1 -1
  71. package/fesm2022/list-key-manager-CyOIXo8P.mjs +360 -0
  72. package/fesm2022/list-key-manager-CyOIXo8P.mjs.map +1 -0
  73. package/fesm2022/listbox.mjs +21 -20
  74. package/fesm2022/listbox.mjs.map +1 -1
  75. package/fesm2022/menu.mjs +86 -75
  76. package/fesm2022/menu.mjs.map +1 -1
  77. package/fesm2022/observers/private.mjs +3 -7
  78. package/fesm2022/observers/private.mjs.map +1 -1
  79. package/fesm2022/observers.mjs +14 -18
  80. package/fesm2022/observers.mjs.map +1 -1
  81. package/fesm2022/overlay-module-BaGhSGqO.mjs +3062 -0
  82. package/fesm2022/overlay-module-BaGhSGqO.mjs.map +1 -0
  83. package/fesm2022/overlay.mjs +27 -3019
  84. package/fesm2022/overlay.mjs.map +1 -1
  85. package/fesm2022/passive-listeners-esHZRgIN.mjs +31 -0
  86. package/fesm2022/passive-listeners-esHZRgIN.mjs.map +1 -0
  87. package/fesm2022/platform-CPg0IbDW.mjs +77 -0
  88. package/fesm2022/platform-CPg0IbDW.mjs.map +1 -0
  89. package/fesm2022/platform.mjs +12 -293
  90. package/fesm2022/platform.mjs.map +1 -1
  91. package/fesm2022/portal.mjs +26 -63
  92. package/fesm2022/portal.mjs.map +1 -1
  93. package/fesm2022/private.mjs +7 -52
  94. package/fesm2022/private.mjs.map +1 -1
  95. package/fesm2022/recycle-view-repeater-strategy-DoWdPqVw.mjs +156 -0
  96. package/fesm2022/recycle-view-repeater-strategy-DoWdPqVw.mjs.map +1 -0
  97. package/fesm2022/scrolling-BkvA05C8.mjs +99 -0
  98. package/fesm2022/scrolling-BkvA05C8.mjs.map +1 -0
  99. package/fesm2022/scrolling.mjs +48 -48
  100. package/fesm2022/scrolling.mjs.map +1 -1
  101. package/fesm2022/selection-model-BCgC8uEN.mjs +221 -0
  102. package/fesm2022/selection-model-BCgC8uEN.mjs.map +1 -0
  103. package/fesm2022/shadow-dom-B0oHn41l.mjs +49 -0
  104. package/fesm2022/shadow-dom-B0oHn41l.mjs.map +1 -0
  105. package/fesm2022/stepper.mjs +43 -36
  106. package/fesm2022/stepper.mjs.map +1 -1
  107. package/fesm2022/style-loader-BDEAZOey.mjs +47 -0
  108. package/fesm2022/style-loader-BDEAZOey.mjs.map +1 -0
  109. package/fesm2022/table.mjs +170 -270
  110. package/fesm2022/table.mjs.map +1 -1
  111. package/fesm2022/test-environment-CT0XxPyp.mjs +19 -0
  112. package/fesm2022/test-environment-CT0XxPyp.mjs.map +1 -0
  113. package/fesm2022/testing/selenium-webdriver.mjs +2 -1
  114. package/fesm2022/testing/selenium-webdriver.mjs.map +1 -1
  115. package/fesm2022/testing/testbed.mjs +33 -74
  116. package/fesm2022/testing/testbed.mjs.map +1 -1
  117. package/fesm2022/testing.mjs.map +1 -1
  118. package/fesm2022/text-field.mjs +27 -27
  119. package/fesm2022/text-field.mjs.map +1 -1
  120. package/fesm2022/tree-key-manager-KnCoIkIC.mjs +360 -0
  121. package/fesm2022/tree-key-manager-KnCoIkIC.mjs.map +1 -0
  122. package/fesm2022/tree.mjs +47 -35
  123. package/fesm2022/tree.mjs.map +1 -1
  124. package/fesm2022/typeahead-9ZW4Dtsf.mjs +88 -0
  125. package/fesm2022/typeahead-9ZW4Dtsf.mjs.map +1 -0
  126. package/fesm2022/unique-selection-dispatcher-Cag6cZJ2.mjs +49 -0
  127. package/fesm2022/unique-selection-dispatcher-Cag6cZJ2.mjs.map +1 -0
  128. package/focus-key-manager.d-BIKDy8oD.d.ts +34 -0
  129. package/focus-monitor.d-CvvJeQRc.d.ts +210 -0
  130. package/harness-environment.d-BatBdODN.d.ts +620 -0
  131. package/index.d.ts +2 -2
  132. package/keycodes/index.d.ts +124 -244
  133. package/layout/index.d.ts +24 -25
  134. package/list-key-manager.d-BlK3jyRn.d.ts +165 -0
  135. package/listbox/index.d.ts +92 -107
  136. package/menu/index.d.ts +595 -683
  137. package/number-property.d-CJVxXUcb.d.ts +16 -0
  138. package/observers/index.d.ts +38 -44
  139. package/observers/private/index.d.ts +3 -3
  140. package/overlay/_index.scss +7 -1
  141. package/overlay/index.d.ts +137 -981
  142. package/overlay-module.d-BiAhhk6g.d.ts +801 -0
  143. package/overlay-prebuilt.css +1 -1
  144. package/package.json +2 -4
  145. package/platform/index.d.ts +32 -88
  146. package/platform.d-B3vREl3q.d.ts +33 -0
  147. package/portal/index.d.ts +5 -264
  148. package/portal-directives.d-DbeNrI5D.d.ts +211 -0
  149. package/private/index.d.ts +3 -20
  150. package/schematics/index.js +1 -1
  151. package/schematics/index.js.map +1 -0
  152. package/schematics/ng-add/index.js +11 -19
  153. package/schematics/ng-add/index.js.map +1 -0
  154. package/schematics/ng-add/schema.js +1 -1
  155. package/schematics/ng-add/schema.js.map +1 -0
  156. package/schematics/ng-generate/drag-drop/index.js +15 -6
  157. package/schematics/ng-generate/drag-drop/index.js.map +1 -0
  158. package/schematics/ng-generate/drag-drop/schema.js +1 -1
  159. package/schematics/ng-generate/drag-drop/schema.js.map +1 -0
  160. package/schematics/ng-update/data/attribute-selectors.js +1 -1
  161. package/schematics/ng-update/data/attribute-selectors.js.map +1 -0
  162. package/schematics/ng-update/data/class-names.js +1 -1
  163. package/schematics/ng-update/data/class-names.js.map +1 -0
  164. package/schematics/ng-update/data/constructor-checks.js +1 -1
  165. package/schematics/ng-update/data/constructor-checks.js.map +1 -0
  166. package/schematics/ng-update/data/css-selectors.js +1 -1
  167. package/schematics/ng-update/data/css-selectors.js.map +1 -0
  168. package/schematics/ng-update/data/css-tokens.js +1 -1
  169. package/schematics/ng-update/data/css-tokens.js.map +1 -0
  170. package/schematics/ng-update/data/element-selectors.js +1 -1
  171. package/schematics/ng-update/data/element-selectors.js.map +1 -0
  172. package/schematics/ng-update/data/index.js +1 -1
  173. package/schematics/ng-update/data/index.js.map +1 -0
  174. package/schematics/ng-update/data/input-names.js +1 -1
  175. package/schematics/ng-update/data/input-names.js.map +1 -0
  176. package/schematics/ng-update/data/method-call-checks.js +1 -1
  177. package/schematics/ng-update/data/method-call-checks.js.map +1 -0
  178. package/schematics/ng-update/data/output-names.js +1 -1
  179. package/schematics/ng-update/data/output-names.js.map +1 -0
  180. package/schematics/ng-update/data/property-names.js +1 -1
  181. package/schematics/ng-update/data/property-names.js.map +1 -0
  182. package/schematics/ng-update/data/symbol-removal.js +1 -1
  183. package/schematics/ng-update/data/symbol-removal.js.map +1 -0
  184. package/schematics/ng-update/devkit-file-system.js +2 -3
  185. package/schematics/ng-update/devkit-file-system.js.map +1 -0
  186. package/schematics/ng-update/devkit-migration-rule.js +13 -4
  187. package/schematics/ng-update/devkit-migration-rule.js.map +1 -0
  188. package/schematics/ng-update/devkit-migration.d.ts +2 -2
  189. package/schematics/ng-update/devkit-migration.js +1 -1
  190. package/schematics/ng-update/devkit-migration.js.map +1 -0
  191. package/schematics/ng-update/find-stylesheets.js +1 -1
  192. package/schematics/ng-update/find-stylesheets.js.map +1 -0
  193. package/schematics/ng-update/html-parsing/angular.js +2 -2
  194. package/schematics/ng-update/html-parsing/angular.js.map +1 -0
  195. package/schematics/ng-update/html-parsing/elements.js +3 -2
  196. package/schematics/ng-update/html-parsing/elements.js.map +1 -0
  197. package/schematics/ng-update/index.js +1 -1
  198. package/schematics/ng-update/index.js.map +1 -0
  199. package/schematics/ng-update/migrations/attribute-selectors.js +8 -5
  200. package/schematics/ng-update/migrations/attribute-selectors.js.map +1 -0
  201. package/schematics/ng-update/migrations/class-inheritance.js +11 -8
  202. package/schematics/ng-update/migrations/class-inheritance.js.map +1 -0
  203. package/schematics/ng-update/migrations/class-names.js +15 -12
  204. package/schematics/ng-update/migrations/class-names.js.map +1 -0
  205. package/schematics/ng-update/migrations/constructor-signature.js +10 -7
  206. package/schematics/ng-update/migrations/constructor-signature.js.map +1 -0
  207. package/schematics/ng-update/migrations/css-selectors.js +8 -5
  208. package/schematics/ng-update/migrations/css-selectors.js.map +1 -0
  209. package/schematics/ng-update/migrations/css-tokens.js +8 -5
  210. package/schematics/ng-update/migrations/css-tokens.js.map +1 -0
  211. package/schematics/ng-update/migrations/element-selectors.js +8 -5
  212. package/schematics/ng-update/migrations/element-selectors.js.map +1 -0
  213. package/schematics/ng-update/migrations/input-names.js +8 -5
  214. package/schematics/ng-update/migrations/input-names.js.map +1 -0
  215. package/schematics/ng-update/migrations/method-call-arguments.js +8 -5
  216. package/schematics/ng-update/migrations/method-call-arguments.js.map +1 -0
  217. package/schematics/ng-update/migrations/misc-template.js +6 -3
  218. package/schematics/ng-update/migrations/misc-template.js.map +1 -0
  219. package/schematics/ng-update/migrations/output-names.js +8 -5
  220. package/schematics/ng-update/migrations/output-names.js.map +1 -0
  221. package/schematics/ng-update/migrations/property-names.js +8 -5
  222. package/schematics/ng-update/migrations/property-names.js.map +1 -0
  223. package/schematics/ng-update/migrations/symbol-removal.js +10 -6
  224. package/schematics/ng-update/migrations/symbol-removal.js.map +1 -0
  225. package/schematics/ng-update/public-api.js +1 -1
  226. package/schematics/ng-update/public-api.js.map +1 -0
  227. package/schematics/ng-update/typescript/base-types.js +1 -1
  228. package/schematics/ng-update/typescript/base-types.js.map +1 -0
  229. package/schematics/ng-update/typescript/imports.js +1 -1
  230. package/schematics/ng-update/typescript/imports.js.map +1 -0
  231. package/schematics/ng-update/typescript/literal.js +1 -1
  232. package/schematics/ng-update/typescript/literal.js.map +1 -0
  233. package/schematics/ng-update/typescript/module-specifiers.js +1 -1
  234. package/schematics/ng-update/typescript/module-specifiers.js.map +1 -0
  235. package/schematics/ng-update/upgrade-data.js +1 -1
  236. package/schematics/ng-update/upgrade-data.js.map +1 -0
  237. package/schematics/paths.js +1 -1
  238. package/schematics/paths.js.map +1 -0
  239. package/schematics/update-tool/component-resource-collector.js +3 -5
  240. package/schematics/update-tool/component-resource-collector.js.map +1 -0
  241. package/schematics/update-tool/file-system.js +1 -1
  242. package/schematics/update-tool/file-system.js.map +1 -0
  243. package/schematics/update-tool/index.js +2 -8
  244. package/schematics/update-tool/index.js.map +1 -0
  245. package/schematics/update-tool/logger.js +1 -1
  246. package/schematics/update-tool/logger.js.map +1 -0
  247. package/schematics/update-tool/migration.js +3 -10
  248. package/schematics/update-tool/migration.js.map +1 -0
  249. package/schematics/update-tool/public-api.js +1 -1
  250. package/schematics/update-tool/public-api.js.map +1 -0
  251. package/schematics/update-tool/target-version.js +1 -1
  252. package/schematics/update-tool/target-version.js.map +1 -0
  253. package/schematics/update-tool/update-recorder.js +1 -1
  254. package/schematics/update-tool/update-recorder.js.map +1 -0
  255. package/schematics/update-tool/utils/decorators.js +1 -1
  256. package/schematics/update-tool/utils/decorators.js.map +1 -0
  257. package/schematics/update-tool/utils/diagnostics.js +1 -1
  258. package/schematics/update-tool/utils/diagnostics.js.map +1 -0
  259. package/schematics/update-tool/utils/functions.js +1 -1
  260. package/schematics/update-tool/utils/functions.js.map +1 -0
  261. package/schematics/update-tool/utils/imports.js +1 -1
  262. package/schematics/update-tool/utils/imports.js.map +1 -0
  263. package/schematics/update-tool/utils/line-mappings.js +1 -1
  264. package/schematics/update-tool/utils/line-mappings.js.map +1 -0
  265. package/schematics/update-tool/utils/parse-tsconfig.js +1 -1
  266. package/schematics/update-tool/utils/parse-tsconfig.js.map +1 -0
  267. package/schematics/update-tool/utils/property-name.js +1 -1
  268. package/schematics/update-tool/utils/property-name.js.map +1 -0
  269. package/schematics/update-tool/utils/virtual-host.js +2 -3
  270. package/schematics/update-tool/utils/virtual-host.js.map +1 -0
  271. package/schematics/update-tool/version-changes.js +1 -1
  272. package/schematics/update-tool/version-changes.js.map +1 -0
  273. package/schematics/utils/ast/ng-module-imports.js +1 -1
  274. package/schematics/utils/ast/ng-module-imports.js.map +1 -0
  275. package/schematics/utils/ast.d.ts +2 -2
  276. package/schematics/utils/ast.js +23 -12
  277. package/schematics/utils/ast.js.map +1 -0
  278. package/schematics/utils/build-component.js +22 -17
  279. package/schematics/utils/build-component.js.map +1 -0
  280. package/schematics/utils/get-project.d.ts +2 -2
  281. package/schematics/utils/get-project.js +1 -1
  282. package/schematics/utils/get-project.js.map +1 -0
  283. package/schematics/utils/html-manipulation.js +1 -1
  284. package/schematics/utils/html-manipulation.js.map +1 -0
  285. package/schematics/utils/index.js +1 -1
  286. package/schematics/utils/index.js.map +1 -0
  287. package/schematics/utils/parse5-element.js +1 -1
  288. package/schematics/utils/parse5-element.js.map +1 -0
  289. package/schematics/utils/project-index-file.d.ts +6 -3
  290. package/schematics/utils/project-index-file.js +30 -7
  291. package/schematics/utils/project-index-file.js.map +1 -0
  292. package/schematics/utils/project-main-file.d.ts +3 -2
  293. package/schematics/utils/project-main-file.js +1 -1
  294. package/schematics/utils/project-main-file.js.map +1 -0
  295. package/schematics/utils/project-style-file.d.ts +2 -2
  296. package/schematics/utils/project-style-file.js +1 -1
  297. package/schematics/utils/project-style-file.js.map +1 -0
  298. package/schematics/utils/project-targets.d.ts +5 -4
  299. package/schematics/utils/project-targets.js +15 -8
  300. package/schematics/utils/project-targets.js.map +1 -0
  301. package/schematics/utils/project-tsconfig-paths.d.ts +3 -3
  302. package/schematics/utils/project-tsconfig-paths.js +26 -14
  303. package/schematics/utils/project-tsconfig-paths.js.map +1 -0
  304. package/schematics/utils/schematic-options.d.ts +2 -2
  305. package/schematics/utils/schematic-options.js +27 -15
  306. package/schematics/utils/schematic-options.js.map +1 -0
  307. package/scrolling/index.d.ts +13 -638
  308. package/scrolling-module.d-DP0Qb7T9.d.ts +552 -0
  309. package/selection-model.d-DNgOONDg.d.ts +112 -0
  310. package/stepper/index.d.ts +75 -124
  311. package/style-loader.d-BXZfQZTF.d.ts +21 -0
  312. package/table/index.d.ts +292 -604
  313. package/testing/index.d.ts +33 -675
  314. package/testing/selenium-webdriver/index.d.ts +31 -20
  315. package/testing/testbed/index.d.ts +10 -19
  316. package/text-field/index.d.ts +12 -30
  317. package/text-field-prebuilt.css +1 -1
  318. package/tree/index.d.ts +208 -271
  319. package/tree-key-manager-strategy.d-XB6M79l-.d.ts +116 -0
  320. package/unique-selection-dispatcher.d-DSFqf1MM.d.ts +33 -0
  321. package/view-repeater.d-BKljR8u8.d.ts +89 -0
  322. package/schematics/index.mjs +0 -37
  323. package/schematics/ng-add/index.mjs +0 -39
  324. package/schematics/ng-add/package-config.d.ts +0 -12
  325. package/schematics/ng-add/package-config.js +0 -51
  326. package/schematics/ng-add/package-config.mjs +0 -51
  327. package/schematics/ng-add/schema.mjs +0 -10
  328. package/schematics/ng-generate/drag-drop/index.mjs +0 -33
  329. package/schematics/ng-generate/drag-drop/schema.mjs +0 -10
  330. package/schematics/ng-update/data/attribute-selectors.mjs +0 -12
  331. package/schematics/ng-update/data/class-names.mjs +0 -12
  332. package/schematics/ng-update/data/constructor-checks.mjs +0 -17
  333. package/schematics/ng-update/data/css-selectors.mjs +0 -12
  334. package/schematics/ng-update/data/css-tokens.mjs +0 -12
  335. package/schematics/ng-update/data/element-selectors.mjs +0 -12
  336. package/schematics/ng-update/data/index.mjs +0 -35
  337. package/schematics/ng-update/data/input-names.mjs +0 -12
  338. package/schematics/ng-update/data/method-call-checks.mjs +0 -12
  339. package/schematics/ng-update/data/output-names.mjs +0 -12
  340. package/schematics/ng-update/data/property-names.mjs +0 -12
  341. package/schematics/ng-update/data/symbol-removal.mjs +0 -12
  342. package/schematics/ng-update/devkit-file-system.mjs +0 -84
  343. package/schematics/ng-update/devkit-migration-rule.mjs +0 -133
  344. package/schematics/ng-update/devkit-migration.mjs +0 -20
  345. package/schematics/ng-update/find-stylesheets.mjs +0 -41
  346. package/schematics/ng-update/html-parsing/angular.mjs +0 -51
  347. package/schematics/ng-update/html-parsing/elements.mjs +0 -62
  348. package/schematics/ng-update/index.mjs +0 -29
  349. package/schematics/ng-update/migrations/attribute-selectors.mjs +0 -68
  350. package/schematics/ng-update/migrations/class-inheritance.mjs +0 -55
  351. package/schematics/ng-update/migrations/class-names.mjs +0 -88
  352. package/schematics/ng-update/migrations/constructor-signature.mjs +0 -136
  353. package/schematics/ng-update/migrations/css-selectors.mjs +0 -72
  354. package/schematics/ng-update/migrations/css-tokens.mjs +0 -80
  355. package/schematics/ng-update/migrations/element-selectors.mjs +0 -63
  356. package/schematics/ng-update/migrations/input-names.mjs +0 -56
  357. package/schematics/ng-update/migrations/method-call-arguments.mjs +0 -59
  358. package/schematics/ng-update/migrations/misc-template.mjs +0 -22
  359. package/schematics/ng-update/migrations/output-names.mjs +0 -43
  360. package/schematics/ng-update/migrations/property-names.mjs +0 -57
  361. package/schematics/ng-update/migrations/symbol-removal.mjs +0 -43
  362. package/schematics/ng-update/public-api.mjs +0 -36
  363. package/schematics/ng-update/typescript/base-types.mjs +0 -23
  364. package/schematics/ng-update/typescript/imports.mjs +0 -53
  365. package/schematics/ng-update/typescript/literal.mjs +0 -32
  366. package/schematics/ng-update/typescript/module-specifiers.mjs +0 -35
  367. package/schematics/ng-update/upgrade-data.mjs +0 -40
  368. package/schematics/paths.mjs +0 -16
  369. package/schematics/schematics.externs.js +0 -0
  370. package/schematics/tsconfig.json +0 -29
  371. package/schematics/update-tool/component-resource-collector.mjs +0 -166
  372. package/schematics/update-tool/file-system.mjs +0 -18
  373. package/schematics/update-tool/index.mjs +0 -178
  374. package/schematics/update-tool/logger.mjs +0 -18
  375. package/schematics/update-tool/migration.mjs +0 -77
  376. package/schematics/update-tool/public-api.mjs +0 -33
  377. package/schematics/update-tool/target-version.mjs +0 -27
  378. package/schematics/update-tool/update-recorder.mjs +0 -10
  379. package/schematics/update-tool/update-tool.externs.js +0 -0
  380. package/schematics/update-tool/utils/decorators.mjs +0 -41
  381. package/schematics/update-tool/utils/diagnostics.mjs +0 -18
  382. package/schematics/update-tool/utils/functions.mjs +0 -20
  383. package/schematics/update-tool/utils/imports.mjs +0 -110
  384. package/schematics/update-tool/utils/line-mappings.mjs +0 -75
  385. package/schematics/update-tool/utils/parse-tsconfig.mjs +0 -45
  386. package/schematics/update-tool/utils/property-name.mjs +0 -27
  387. package/schematics/update-tool/utils/virtual-host.mjs +0 -72
  388. package/schematics/update-tool/version-changes.mjs +0 -38
  389. package/schematics/utils/ast/ng-module-imports.mjs +0 -82
  390. package/schematics/utils/ast.mjs +0 -68
  391. package/schematics/utils/build-component.mjs +0 -183
  392. package/schematics/utils/get-project.mjs +0 -28
  393. package/schematics/utils/html-manipulation.mjs +0 -91
  394. package/schematics/utils/index.mjs +0 -36
  395. package/schematics/utils/parse5-element.mjs +0 -30
  396. package/schematics/utils/project-index-file.mjs +0 -20
  397. package/schematics/utils/project-main-file.mjs +0 -25
  398. package/schematics/utils/project-style-file.mjs +0 -42
  399. package/schematics/utils/project-targets.mjs +0 -39
  400. package/schematics/utils/project-tsconfig-paths.mjs +0 -34
  401. package/schematics/utils/schematic-options.mjs +0 -77
@@ -1,419 +1,349 @@
1
- import { AfterViewInit } from '@angular/core';
2
- import { Direction } from '@angular/cdk/bidi';
3
- import { ElementRef } from '@angular/core';
4
- import { EventEmitter } from '@angular/core';
5
1
  import * as i0 from '@angular/core';
6
- import * as i7 from '@angular/cdk/scrolling';
7
- import { InjectionToken } from '@angular/core';
8
- import { NgZone } from '@angular/core';
9
- import { NumberInput } from '@angular/cdk/coercion';
10
- import { Observable } from 'rxjs';
11
- import { OnChanges } from '@angular/core';
12
- import { OnDestroy } from '@angular/core';
13
- import { Renderer2 } from '@angular/core';
14
- import { SimpleChanges } from '@angular/core';
15
- import { Subject } from 'rxjs';
16
- import { TemplateRef } from '@angular/core';
17
- import { ViewContainerRef } from '@angular/core';
18
- import { ViewportRuler } from '@angular/cdk/scrolling';
2
+ import { InjectionToken, ElementRef, NgZone, OnDestroy, EventEmitter, AfterViewInit, TemplateRef, OnChanges, SimpleChanges, ViewContainerRef, Renderer2 } from '@angular/core';
3
+ import { a as Direction } from '../bidi-module.d-IN1Vp56w.js';
4
+ import { Subject, Observable } from 'rxjs';
5
+ import { ViewportRuler } from '../scrolling/index.js';
6
+ import { N as NumberInput } from '../number-property.d-CJVxXUcb.js';
7
+ import { b as CdkScrollableModule } from '../scrolling-module.d-DP0Qb7T9.js';
8
+ export { C as ɵɵCdkScrollable } from '../scrolling-module.d-DP0Qb7T9.js';
9
+ import '../data-source.d-Bblv7Zvh.js';
19
10
 
11
+ /** Possible values that can be used to configure the drag start delay. */
12
+ type DragStartDelay = number | {
13
+ touch: number;
14
+ mouse: number;
15
+ };
16
+ /** Possible axis along which dragging can be locked. */
17
+ type DragAxis = 'x' | 'y';
18
+ /** Possible orientations for a drop list. */
19
+ type DropListOrientation = 'horizontal' | 'vertical' | 'mixed';
20
20
  /**
21
21
  * Injection token that can be used to configure the
22
22
  * behavior of the drag&drop-related components.
23
23
  */
24
- export declare const CDK_DRAG_CONFIG: InjectionToken<DragDropConfig>;
25
-
26
- /**
27
- * Injection token that can be used to reference instances of `CdkDragHandle`. It serves as
28
- * alternative token to the actual `CdkDragHandle` class which could cause unnecessary
29
- * retention of the class and its directive metadata.
30
- */
31
- export declare const CDK_DRAG_HANDLE: InjectionToken<CdkDragHandle>;
32
-
33
- /**
34
- * Injection token that can be used for a `CdkDrag` to provide itself as a parent to the
35
- * drag-specific child directive (`CdkDragHandle`, `CdkDragPreview` etc.). Used primarily
36
- * to avoid circular imports.
37
- * @docs-private
38
- */
39
- export declare const CDK_DRAG_PARENT: InjectionToken<CdkDrag<any>>;
40
-
41
- /**
42
- * Injection token that can be used to reference instances of `CdkDragPlaceholder`. It serves as
43
- * alternative token to the actual `CdkDragPlaceholder` class which could cause unnecessary
44
- * retention of the class and its directive metadata.
45
- */
46
- export declare const CDK_DRAG_PLACEHOLDER: InjectionToken<CdkDragPlaceholder<any>>;
47
-
48
- /**
49
- * Injection token that can be used to reference instances of `CdkDragPreview`. It serves as
50
- * alternative token to the actual `CdkDragPreview` class which could cause unnecessary
51
- * retention of the class and its directive metadata.
52
- */
53
- export declare const CDK_DRAG_PREVIEW: InjectionToken<CdkDragPreview<any>>;
54
-
24
+ declare const CDK_DRAG_CONFIG: InjectionToken<DragDropConfig>;
55
25
  /**
56
- * Injection token that can be used to reference instances of `CdkDropList`. It serves as
57
- * alternative token to the actual `CdkDropList` class which could cause unnecessary
58
- * retention of the class and its directive metadata.
26
+ * Object that can be used to configure the drag
27
+ * items and drop lists within a module or a component.
59
28
  */
60
- export declare const CDK_DROP_LIST: InjectionToken<CdkDropList<any>>;
29
+ interface DragDropConfig extends Partial<DragRefConfig> {
30
+ lockAxis?: DragAxis;
31
+ dragStartDelay?: DragStartDelay;
32
+ constrainPosition?: DragConstrainPosition;
33
+ previewClass?: string | string[];
34
+ boundaryElement?: string;
35
+ rootElementSelector?: string;
36
+ draggingDisabled?: boolean;
37
+ sortingDisabled?: boolean;
38
+ listAutoScrollDisabled?: boolean;
39
+ listOrientation?: DropListOrientation;
40
+ zIndex?: number;
41
+ previewContainer?: 'global' | 'parent';
42
+ }
61
43
 
62
44
  /**
63
- * Injection token that can be used to reference instances of `CdkDropListGroup`. It serves as
64
- * alternative token to the actual `CdkDropListGroup` class which could cause unnecessary
65
- * retention of the class and its directive metadata.
45
+ * Reference to a drop list. Used to manipulate or dispose of the container.
66
46
  */
67
- export declare const CDK_DROP_LIST_GROUP: InjectionToken<CdkDropListGroup<unknown>>;
68
-
69
- /** Element that can be moved inside a CdkDropList container. */
70
- export declare class CdkDrag<T = any> implements AfterViewInit, OnChanges, OnDestroy {
71
- element: ElementRef<HTMLElement>;
72
- dropContainer: CdkDropList<any>;
73
- private _ngZone;
74
- private _viewContainerRef;
75
- private _dir;
76
- private _changeDetectorRef;
77
- private _selfHandle;
78
- private _parentDrag;
47
+ declare class DropListRef<T = any> {
79
48
  private _dragDropRegistry;
80
- private readonly _destroyed;
81
- private _handles;
82
- private _previewTemplate;
83
- private _placeholderTemplate;
84
- /** Reference to the underlying drag instance. */
85
- _dragRef: DragRef<CdkDrag<T>>;
86
- /** Arbitrary data to attach to this drag instance. */
87
- data: T;
88
- /** Locks the position of the dragged element along the specified axis. */
89
- lockAxis: DragAxis;
49
+ private _ngZone;
50
+ private _viewportRuler;
51
+ /** Element that the drop list is attached to. */
52
+ element: HTMLElement | ElementRef<HTMLElement>;
53
+ /** Whether starting a dragging sequence from this container is disabled. */
54
+ disabled: boolean;
55
+ /** Whether sorting items within the list is disabled. */
56
+ sortingDisabled: boolean;
57
+ /** Locks the position of the draggable elements inside the container along the specified axis. */
58
+ lockAxis: 'x' | 'y';
90
59
  /**
91
- * Selector that will be used to determine the root draggable element, starting from
92
- * the `cdkDrag` element and going up the DOM. Passing an alternate root element is useful
93
- * when trying to enable dragging on an element that you might not have access to.
60
+ * Whether auto-scrolling the view when the user
61
+ * moves their pointer close to the edges is disabled.
94
62
  */
95
- rootElementSelector: string;
63
+ autoScrollDisabled: boolean;
64
+ /** Number of pixels to scroll for each frame when auto-scrolling an element. */
65
+ autoScrollStep: number;
96
66
  /**
97
- * Node or selector that will be used to determine the element to which the draggable's
98
- * position will be constrained. If a string is passed in, it'll be used as a selector that
99
- * will be matched starting from the element's parent and going up the DOM until a match
100
- * has been found.
67
+ * Function that is used to determine whether an item
68
+ * is allowed to be moved into a drop container.
101
69
  */
102
- boundaryElement: string | ElementRef<HTMLElement> | HTMLElement;
70
+ enterPredicate: (drag: DragRef, drop: DropListRef) => boolean;
71
+ /** Function that is used to determine whether an item can be sorted into a particular index. */
72
+ sortPredicate: (index: number, drag: DragRef, drop: DropListRef) => boolean;
73
+ /** Emits right before dragging has started. */
74
+ readonly beforeStarted: Subject<void>;
103
75
  /**
104
- * Amount of milliseconds to wait after the user has put their
105
- * pointer down before starting to drag the element.
76
+ * Emits when the user has moved a new drag item into this container.
106
77
  */
107
- dragStartDelay: DragStartDelay;
78
+ readonly entered: Subject<{
79
+ item: DragRef;
80
+ container: DropListRef;
81
+ currentIndex: number;
82
+ }>;
108
83
  /**
109
- * Sets the position of a `CdkDrag` that is outside of a drop container.
110
- * Can be used to restore the element's position for a returning user.
84
+ * Emits when the user removes an item from the container
85
+ * by dragging it into another container.
111
86
  */
112
- freeDragPosition: Point;
113
- /** Whether starting to drag this element is disabled. */
114
- get disabled(): boolean;
115
- set disabled(value: boolean);
116
- private _disabled;
87
+ readonly exited: Subject<{
88
+ item: DragRef;
89
+ container: DropListRef;
90
+ }>;
91
+ /** Emits when the user drops an item inside the container. */
92
+ readonly dropped: Subject<{
93
+ item: DragRef;
94
+ currentIndex: number;
95
+ previousIndex: number;
96
+ container: DropListRef;
97
+ previousContainer: DropListRef;
98
+ isPointerOverContainer: boolean;
99
+ distance: Point;
100
+ dropPoint: Point;
101
+ event: MouseEvent | TouchEvent;
102
+ }>;
103
+ /** Emits as the user is swapping items while actively dragging. */
104
+ readonly sorted: Subject<{
105
+ previousIndex: number;
106
+ currentIndex: number;
107
+ container: DropListRef;
108
+ item: DragRef;
109
+ }>;
110
+ /** Emits when a dragging sequence is started in a list connected to the current one. */
111
+ readonly receivingStarted: Subject<{
112
+ receiver: DropListRef;
113
+ initiator: DropListRef;
114
+ items: DragRef[];
115
+ }>;
116
+ /** Emits when a dragging sequence is stopped from a list connected to the current one. */
117
+ readonly receivingStopped: Subject<{
118
+ receiver: DropListRef;
119
+ initiator: DropListRef;
120
+ }>;
121
+ /** Arbitrary data that can be attached to the drop list. */
122
+ data: T;
123
+ /** Element that is the direct parent of the drag items. */
124
+ private _container;
125
+ /** Whether an item in the list is being dragged. */
126
+ private _isDragging;
127
+ /** Keeps track of the positions of any parent scrollable elements. */
128
+ private _parentPositions;
129
+ /** Strategy being used to sort items within the list. */
130
+ private _sortStrategy;
131
+ /** Cached `DOMRect` of the drop list. */
132
+ private _domRect;
133
+ /** Draggable items in the container. */
134
+ private _draggables;
135
+ /** Drop lists that are connected to the current one. */
136
+ private _siblings;
137
+ /** Connected siblings that currently have a dragged item. */
138
+ private _activeSiblings;
139
+ /** Subscription to the window being scrolled. */
140
+ private _viewportScrollSubscription;
141
+ /** Vertical direction in which the list is currently scrolling. */
142
+ private _verticalScrollDirection;
143
+ /** Horizontal direction in which the list is currently scrolling. */
144
+ private _horizontalScrollDirection;
145
+ /** Node that is being auto-scrolled. */
146
+ private _scrollNode;
147
+ /** Used to signal to the current auto-scroll sequence when to stop. */
148
+ private readonly _stopScrollTimers;
149
+ /** Shadow root of the current element. Necessary for `elementFromPoint` to resolve correctly. */
150
+ private _cachedShadowRoot;
151
+ /** Reference to the document. */
152
+ private _document;
153
+ /** Elements that can be scrolled while the user is dragging. */
154
+ private _scrollableElements;
155
+ /** Initial value for the element's `scroll-snap-type` style. */
156
+ private _initialScrollSnap;
157
+ /** Direction of the list's layout. */
158
+ private _direction;
159
+ constructor(element: ElementRef<HTMLElement> | HTMLElement, _dragDropRegistry: DragDropRegistry, _document: any, _ngZone: NgZone, _viewportRuler: ViewportRuler);
160
+ /** Removes the drop list functionality from the DOM element. */
161
+ dispose(): void;
162
+ /** Whether an item from this list is currently being dragged. */
163
+ isDragging(): boolean;
164
+ /** Starts dragging an item. */
165
+ start(): void;
117
166
  /**
118
- * Function that can be used to customize the logic of how the position of the drag item
119
- * is limited while it's being dragged. Gets called with a point containing the current position
120
- * of the user's pointer on the page, a reference to the item being dragged and its dimensions.
121
- * Should return a point describing where the item should be rendered.
167
+ * Attempts to move an item into the container.
168
+ * @param item Item that was moved into the container.
169
+ * @param pointerX Position of the item along the X axis.
170
+ * @param pointerY Position of the item along the Y axis.
171
+ * @param index Index at which the item entered. If omitted, the container will try to figure it
172
+ * out automatically.
122
173
  */
123
- constrainPosition?: DragConstrainPosition;
124
- /** Class to be added to the preview element. */
125
- previewClass: string | string[];
174
+ enter(item: DragRef, pointerX: number, pointerY: number, index?: number): void;
126
175
  /**
127
- * Configures the place into which the preview of the item will be inserted. Can be configured
128
- * globally through `CDK_DROP_LIST`. Possible values:
129
- * - `global` - Preview will be inserted at the bottom of the `<body>`. The advantage is that
130
- * you don't have to worry about `overflow: hidden` or `z-index`, but the item won't retain
131
- * its inherited styles.
132
- * - `parent` - Preview will be inserted into the parent of the drag item. The advantage is that
133
- * inherited styles will be preserved, but it may be clipped by `overflow: hidden` or not be
134
- * visible due to `z-index`. Furthermore, the preview is going to have an effect over selectors
135
- * like `:nth-child` and some flexbox configurations.
136
- * - `ElementRef<HTMLElement> | HTMLElement` - Preview will be inserted into a specific element.
137
- * Same advantages and disadvantages as `parent`.
176
+ * Removes an item from the container after it was dragged into another container by the user.
177
+ * @param item Item that was dragged out.
138
178
  */
139
- previewContainer: PreviewContainer;
179
+ exit(item: DragRef): void;
140
180
  /**
141
- * If the parent of the dragged element has a `scale` transform, it can throw off the
142
- * positioning when the user starts dragging. Use this input to notify the CDK of the scale.
181
+ * Drops an item into this container.
182
+ * @param item Item being dropped into the container.
183
+ * @param currentIndex Index at which the item should be inserted.
184
+ * @param previousIndex Index of the item when dragging started.
185
+ * @param previousContainer Container from which the item got dragged in.
186
+ * @param isPointerOverContainer Whether the user's pointer was over the
187
+ * container when the item was dropped.
188
+ * @param distance Distance the user has dragged since the start of the dragging sequence.
189
+ * @param event Event that triggered the dropping sequence.
190
+ *
191
+ * @breaking-change 15.0.0 `previousIndex` and `event` parameters to become required.
143
192
  */
144
- scale: number;
145
- /** Emits when the user starts dragging the item. */
146
- readonly started: EventEmitter<CdkDragStart>;
147
- /** Emits when the user has released a drag item, before any animations have started. */
148
- readonly released: EventEmitter<CdkDragRelease>;
149
- /** Emits when the user stops dragging an item in the container. */
150
- readonly ended: EventEmitter<CdkDragEnd>;
151
- /** Emits when the user has moved the item into a new container. */
152
- readonly entered: EventEmitter<CdkDragEnter<any>>;
153
- /** Emits when the user removes the item its container by dragging it into another container. */
154
- readonly exited: EventEmitter<CdkDragExit<any>>;
155
- /** Emits when the user drops the item inside a container. */
156
- readonly dropped: EventEmitter<CdkDragDrop<any>>;
193
+ drop(item: DragRef, currentIndex: number, previousIndex: number, previousContainer: DropListRef, isPointerOverContainer: boolean, distance: Point, dropPoint: Point, event?: MouseEvent | TouchEvent): void;
157
194
  /**
158
- * Emits as the user is dragging the item. Use with caution,
159
- * because this event will fire for every pixel that the user has dragged.
195
+ * Sets the draggable items that are a part of this list.
196
+ * @param items Items that are a part of this list.
160
197
  */
161
- readonly moved: Observable<CdkDragMove<T>>;
162
- private _injector;
163
- constructor(...args: unknown[]);
198
+ withItems(items: DragRef[]): this;
199
+ /** Sets the layout direction of the drop list. */
200
+ withDirection(direction: Direction): this;
164
201
  /**
165
- * Returns the element that is being used as a placeholder
166
- * while the current element is being dragged.
202
+ * Sets the containers that are connected to this one. When two or more containers are
203
+ * connected, the user will be allowed to transfer items between them.
204
+ * @param connectedTo Other containers that the current containers should be connected to.
167
205
  */
168
- getPlaceholderElement(): HTMLElement;
169
- /** Returns the root draggable element. */
170
- getRootElement(): HTMLElement;
171
- /** Resets a standalone drag item to its initial position. */
172
- reset(): void;
206
+ connectedTo(connectedTo: DropListRef[]): this;
173
207
  /**
174
- * Gets the pixel coordinates of the draggable outside of a drop container.
208
+ * Sets the orientation of the container.
209
+ * @param orientation New orientation for the container.
175
210
  */
176
- getFreeDragPosition(): Readonly<Point>;
211
+ withOrientation(orientation: DropListOrientation): this;
177
212
  /**
178
- * Sets the current position in pixels the draggable outside of a drop container.
179
- * @param value New position to be set.
213
+ * Sets which parent elements are can be scrolled while the user is dragging.
214
+ * @param elements Elements that can be scrolled.
180
215
  */
181
- setFreeDragPosition(value: Point): void;
182
- ngAfterViewInit(): void;
183
- ngOnChanges(changes: SimpleChanges): void;
184
- ngOnDestroy(): void;
185
- _addHandle(handle: CdkDragHandle): void;
186
- _removeHandle(handle: CdkDragHandle): void;
187
- _setPreviewTemplate(preview: CdkDragPreview): void;
188
- _resetPreviewTemplate(preview: CdkDragPreview): void;
189
- _setPlaceholderTemplate(placeholder: CdkDragPlaceholder): void;
190
- _resetPlaceholderTemplate(placeholder: CdkDragPlaceholder): void;
191
- /** Syncs the root element with the `DragRef`. */
192
- private _updateRootElement;
193
- /** Gets the boundary element, based on the `boundaryElement` value. */
194
- private _getBoundaryElement;
195
- /** Syncs the inputs of the CdkDrag with the options of the underlying DragRef. */
196
- private _syncInputs;
197
- /** Handles the events from the underlying `DragRef`. */
198
- private _handleEvents;
199
- /** Assigns the default input values based on a provided config object. */
200
- private _assignDefaults;
201
- /** Sets up the listener that syncs the handles with the drag ref. */
202
- private _setupHandlesListener;
203
- static ɵfac: i0.ɵɵFactoryDeclaration<CdkDrag<any>, never>;
204
- static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDrag<any>, "[cdkDrag]", ["cdkDrag"], { "data": { "alias": "cdkDragData"; "required": false; }; "lockAxis": { "alias": "cdkDragLockAxis"; "required": false; }; "rootElementSelector": { "alias": "cdkDragRootElement"; "required": false; }; "boundaryElement": { "alias": "cdkDragBoundary"; "required": false; }; "dragStartDelay": { "alias": "cdkDragStartDelay"; "required": false; }; "freeDragPosition": { "alias": "cdkDragFreeDragPosition"; "required": false; }; "disabled": { "alias": "cdkDragDisabled"; "required": false; }; "constrainPosition": { "alias": "cdkDragConstrainPosition"; "required": false; }; "previewClass": { "alias": "cdkDragPreviewClass"; "required": false; }; "previewContainer": { "alias": "cdkDragPreviewContainer"; "required": false; }; "scale": { "alias": "cdkDragScale"; "required": false; }; }, { "started": "cdkDragStarted"; "released": "cdkDragReleased"; "ended": "cdkDragEnded"; "entered": "cdkDragEntered"; "exited": "cdkDragExited"; "dropped": "cdkDragDropped"; "moved": "cdkDragMoved"; }, never, never, true, never>;
205
- static ngAcceptInputType_disabled: unknown;
206
- static ngAcceptInputType_scale: unknown;
207
- }
208
-
209
- /** Event emitted when the user drops a draggable item inside a drop container. */
210
- export declare interface CdkDragDrop<T, O = T, I = any> {
211
- /** Index of the item when it was picked up. */
212
- previousIndex: number;
213
- /** Current index of the item. */
214
- currentIndex: number;
215
- /** Item that is being dropped. */
216
- item: CdkDrag<I>;
217
- /** Container in which the item was dropped. */
218
- container: CdkDropList<T>;
219
- /** Container from which the item was picked up. Can be the same as the `container`. */
220
- previousContainer: CdkDropList<O>;
221
- /** Whether the user's pointer was over the container when the item was dropped. */
222
- isPointerOverContainer: boolean;
223
- /** Distance in pixels that the user has dragged since the drag sequence started. */
224
- distance: {
225
- x: number;
226
- y: number;
227
- };
228
- /** Position where the pointer was when the item was dropped */
229
- dropPoint: {
230
- x: number;
231
- y: number;
232
- };
233
- /** Native event that caused the drop event. */
234
- event: MouseEvent | TouchEvent;
235
- }
236
-
237
- /** Event emitted when the user stops dragging a draggable. */
238
- export declare interface CdkDragEnd<T = any> {
239
- /** Draggable that emitted the event. */
240
- source: CdkDrag<T>;
241
- /** Distance in pixels that the user has dragged since the drag sequence started. */
242
- distance: {
243
- x: number;
244
- y: number;
245
- };
246
- /** Position where the pointer was when the item was dropped */
247
- dropPoint: {
216
+ withScrollableParents(elements: HTMLElement[]): this;
217
+ /**
218
+ * Configures the drop list so that a different element is used as the container for the
219
+ * dragged items. This is useful for the cases when one might not have control over the
220
+ * full DOM that sets up the dragging.
221
+ * Note that the alternate container needs to be a descendant of the drop list.
222
+ * @param container New element container to be assigned.
223
+ */
224
+ withElementContainer(container: HTMLElement): this;
225
+ /** Gets the scrollable parents that are registered with this drop container. */
226
+ getScrollableParents(): readonly HTMLElement[];
227
+ /**
228
+ * Figures out the index of an item in the container.
229
+ * @param item Item whose index should be determined.
230
+ */
231
+ getItemIndex(item: DragRef): number;
232
+ /**
233
+ * Whether the list is able to receive the item that
234
+ * is currently being dragged inside a connected drop list.
235
+ */
236
+ isReceiving(): boolean;
237
+ /**
238
+ * Sorts an item inside the container based on its position.
239
+ * @param item Item to be sorted.
240
+ * @param pointerX Position of the item along the X axis.
241
+ * @param pointerY Position of the item along the Y axis.
242
+ * @param pointerDelta Direction in which the pointer is moving along each axis.
243
+ */
244
+ _sortItem(item: DragRef, pointerX: number, pointerY: number, pointerDelta: {
248
245
  x: number;
249
246
  y: number;
250
- };
251
- /** Native event that caused the dragging to stop. */
252
- event: MouseEvent | TouchEvent;
253
- }
254
-
255
- /** Event emitted when the user moves an item into a new drop container. */
256
- export declare interface CdkDragEnter<T = any, I = T> {
257
- /** Container into which the user has moved the item. */
258
- container: CdkDropList<T>;
259
- /** Item that was moved into the container. */
260
- item: CdkDrag<I>;
261
- /** Index at which the item has entered the container. */
262
- currentIndex: number;
263
- }
264
-
265
- /**
266
- * Event emitted when the user removes an item from a
267
- * drop container by moving it into another one.
268
- */
269
- export declare interface CdkDragExit<T = any, I = T> {
270
- /** Container from which the user has a removed an item. */
271
- container: CdkDropList<T>;
272
- /** Item that was removed from the container. */
273
- item: CdkDrag<I>;
247
+ }): void;
248
+ /**
249
+ * Checks whether the user's pointer is close to the edges of either the
250
+ * viewport or the drop list and starts the auto-scroll sequence.
251
+ * @param pointerX User's pointer position along the x axis.
252
+ * @param pointerY User's pointer position along the y axis.
253
+ */
254
+ _startScrollingIfNecessary(pointerX: number, pointerY: number): void;
255
+ /** Stops any currently-running auto-scroll sequences. */
256
+ _stopScrolling(): void;
257
+ /** Starts the dragging sequence within the list. */
258
+ private _draggingStarted;
259
+ /** Caches the positions of the configured scrollable parents. */
260
+ private _cacheParentPositions;
261
+ /** Resets the container to its initial state. */
262
+ private _reset;
263
+ /** Starts the interval that'll auto-scroll the element. */
264
+ private _startScrollInterval;
265
+ /**
266
+ * Checks whether the user's pointer is positioned over the container.
267
+ * @param x Pointer position along the X axis.
268
+ * @param y Pointer position along the Y axis.
269
+ */
270
+ _isOverContainer(x: number, y: number): boolean;
271
+ /**
272
+ * Figures out whether an item should be moved into a sibling
273
+ * drop container, based on its current position.
274
+ * @param item Drag item that is being moved.
275
+ * @param x Position of the item along the X axis.
276
+ * @param y Position of the item along the Y axis.
277
+ */
278
+ _getSiblingContainerFromPosition(item: DragRef, x: number, y: number): DropListRef | undefined;
279
+ /**
280
+ * Checks whether the drop list can receive the passed-in item.
281
+ * @param item Item that is being dragged into the list.
282
+ * @param x Position of the item along the X axis.
283
+ * @param y Position of the item along the Y axis.
284
+ */
285
+ _canReceive(item: DragRef, x: number, y: number): boolean;
286
+ /**
287
+ * Called by one of the connected drop lists when a dragging sequence has started.
288
+ * @param sibling Sibling in which dragging has started.
289
+ */
290
+ _startReceiving(sibling: DropListRef, items: DragRef[]): void;
291
+ /**
292
+ * Called by a connected drop list when dragging has stopped.
293
+ * @param sibling Sibling whose dragging has stopped.
294
+ */
295
+ _stopReceiving(sibling: DropListRef): void;
296
+ /**
297
+ * Starts listening to scroll events on the viewport.
298
+ * Used for updating the internal state of the list.
299
+ */
300
+ private _listenToScrollEvents;
301
+ /**
302
+ * Lazily resolves and returns the shadow root of the element. We do this in a function, rather
303
+ * than saving it in property directly on init, because we want to resolve it as late as possible
304
+ * in order to ensure that the element has been moved into the shadow DOM. Doing it inside the
305
+ * constructor might be too early if the element is inside of something like `ngFor` or `ngIf`.
306
+ */
307
+ private _getShadowRoot;
308
+ /** Notifies any siblings that may potentially receive the item. */
309
+ private _notifyReceivingSiblings;
274
310
  }
275
311
 
276
- /** Handle that can be used to drag a CdkDrag instance. */
277
- export declare class CdkDragHandle implements AfterViewInit, OnDestroy {
312
+ /** Container that wraps a set of draggable items. */
313
+ declare class CdkDropList<T = any> implements OnDestroy {
278
314
  element: ElementRef<HTMLElement>;
279
- private _parentDrag;
280
- private _dragDropRegistry;
281
- /** Emits when the state of the handle has changed. */
282
- readonly _stateChanges: Subject<CdkDragHandle>;
283
- /** Whether starting to drag through this handle is disabled. */
284
- get disabled(): boolean;
285
- set disabled(value: boolean);
286
- private _disabled;
287
- constructor(...args: unknown[]);
288
- ngAfterViewInit(): void;
289
- ngOnDestroy(): void;
290
- static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragHandle, never>;
291
- static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragHandle, "[cdkDragHandle]", never, { "disabled": { "alias": "cdkDragHandleDisabled"; "required": false; }; }, {}, never, never, true, never>;
292
- static ngAcceptInputType_disabled: unknown;
293
- }
294
-
295
- /** Event emitted as the user is dragging a draggable item. */
296
- export declare interface CdkDragMove<T = any> {
297
- /** Item that is being dragged. */
298
- source: CdkDrag<T>;
299
- /** Position of the user's pointer on the page. */
300
- pointerPosition: {
301
- x: number;
302
- y: number;
303
- };
304
- /** Native event that is causing the dragging. */
305
- event: MouseEvent | TouchEvent;
306
- /** Distance in pixels that the user has dragged since the drag sequence started. */
307
- distance: {
308
- x: number;
309
- y: number;
310
- };
311
- /**
312
- * Indicates the direction in which the user is dragging the element along each axis.
313
- * `1` means that the position is increasing (e.g. the user is moving to the right or downwards),
314
- * whereas `-1` means that it's decreasing (they're moving to the left or upwards). `0` means
315
- * that the position hasn't changed.
316
- */
317
- delta: {
318
- x: -1 | 0 | 1;
319
- y: -1 | 0 | 1;
320
- };
321
- }
322
-
323
- /**
324
- * Element that will be used as a template for the placeholder of a CdkDrag when
325
- * it is being dragged. The placeholder is displayed in place of the element being dragged.
326
- */
327
- export declare class CdkDragPlaceholder<T = any> implements OnDestroy {
328
- templateRef: TemplateRef<T>;
329
- private _drag;
330
- /** Context data to be added to the placeholder template instance. */
331
- data: T;
332
- constructor(...args: unknown[]);
333
- ngOnDestroy(): void;
334
- static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragPlaceholder<any>, never>;
335
- static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragPlaceholder<any>, "ng-template[cdkDragPlaceholder]", never, { "data": { "alias": "data"; "required": false; }; }, {}, never, never, true, never>;
336
- }
337
-
338
- /**
339
- * Element that will be used as a template for the preview
340
- * of a CdkDrag when it is being dragged.
341
- */
342
- export declare class CdkDragPreview<T = any> implements OnDestroy {
343
- templateRef: TemplateRef<T>;
344
- private _drag;
345
- /** Context data to be added to the preview template instance. */
346
- data: T;
347
- /** Whether the preview should preserve the same size as the item that is being dragged. */
348
- matchSize: boolean;
349
- constructor(...args: unknown[]);
350
- ngOnDestroy(): void;
351
- static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragPreview<any>, never>;
352
- static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragPreview<any>, "ng-template[cdkDragPreview]", never, { "data": { "alias": "data"; "required": false; }; "matchSize": { "alias": "matchSize"; "required": false; }; }, {}, never, never, true, never>;
353
- static ngAcceptInputType_matchSize: unknown;
354
- }
355
-
356
- /** Event emitted when the user releases an item, before any animations have started. */
357
- export declare interface CdkDragRelease<T = any> {
358
- /** Draggable that emitted the event. */
359
- source: CdkDrag<T>;
360
- /** Native event that caused the release event. */
361
- event: MouseEvent | TouchEvent;
362
- }
363
-
364
- /** Event emitted when the user swaps the position of two drag items. */
365
- export declare interface CdkDragSortEvent<T = any, I = T> {
366
- /** Index from which the item was sorted previously. */
367
- previousIndex: number;
368
- /** Index that the item is currently in. */
369
- currentIndex: number;
370
- /** Container that the item belongs to. */
371
- container: CdkDropList<T>;
372
- /** Item that is being sorted. */
373
- item: CdkDrag<I>;
374
- }
375
-
376
- /** Event emitted when the user starts dragging a draggable. */
377
- export declare interface CdkDragStart<T = any> {
378
- /** Draggable that emitted the event. */
379
- source: CdkDrag<T>;
380
- /** Native event that started the drag sequence. */
381
- event: MouseEvent | TouchEvent;
382
- }
383
-
384
- /** Container that wraps a set of draggable items. */
385
- export declare class CdkDropList<T = any> implements OnDestroy {
386
- element: ElementRef<HTMLElement>;
387
- private _changeDetectorRef;
388
- private _scrollDispatcher;
389
- private _dir;
390
- private _group;
391
- /** Emits when the list has been destroyed. */
392
- private readonly _destroyed;
393
- /** Whether the element's scrollable parents have been resolved. */
394
- private _scrollableParentsResolved;
395
- /** Keeps track of the drop lists that are currently on the page. */
396
- private static _dropLists;
397
- /** Reference to the underlying drop list instance. */
398
- _dropListRef: DropListRef<CdkDropList<T>>;
399
- /**
400
- * Other draggable containers that this container is connected to and into which the
401
- * container's items can be transferred. Can either be references to other drop containers,
402
- * or their unique IDs.
403
- */
404
- connectedTo: (CdkDropList | string)[] | CdkDropList | string;
405
- /** Arbitrary data to attach to this container. */
406
- data: T;
407
- /** Direction in which the list is oriented. */
408
- orientation: DropListOrientation;
409
- /**
410
- * Unique ID for the drop zone. Can be used as a reference
411
- * in the `connectedTo` of another `CdkDropList`.
412
- */
413
- id: string;
414
- /** Locks the position of the draggable elements inside the container along the specified axis. */
415
- lockAxis: DragAxis;
416
- /** Whether starting a dragging sequence from this container is disabled. */
315
+ private _changeDetectorRef;
316
+ private _scrollDispatcher;
317
+ private _dir;
318
+ private _group;
319
+ /** Refs that have been synced with the drop ref most recently. */
320
+ private _latestSortedRefs;
321
+ /** Emits when the list has been destroyed. */
322
+ private readonly _destroyed;
323
+ /** Whether the element's scrollable parents have been resolved. */
324
+ private _scrollableParentsResolved;
325
+ /** Keeps track of the drop lists that are currently on the page. */
326
+ private static _dropLists;
327
+ /** Reference to the underlying drop list instance. */
328
+ _dropListRef: DropListRef<CdkDropList<T>>;
329
+ /**
330
+ * Other draggable containers that this container is connected to and into which the
331
+ * container's items can be transferred. Can either be references to other drop containers,
332
+ * or their unique IDs.
333
+ */
334
+ connectedTo: (CdkDropList | string)[] | CdkDropList | string;
335
+ /** Arbitrary data to attach to this container. */
336
+ data: T;
337
+ /** Direction in which the list is oriented. */
338
+ orientation: DropListOrientation;
339
+ /**
340
+ * Unique ID for the drop zone. Can be used as a reference
341
+ * in the `connectedTo` of another `CdkDropList`.
342
+ */
343
+ id: string;
344
+ /** Locks the position of the draggable elements inside the container along the specified axis. */
345
+ lockAxis: DragAxis;
346
+ /** Whether starting a dragging sequence from this container is disabled. */
417
347
  get disabled(): boolean;
418
348
  set disabled(value: boolean);
419
349
  private _disabled;
@@ -489,419 +419,293 @@ export declare class CdkDropList<T = any> implements OnDestroy {
489
419
  static ngAcceptInputType_autoScrollDisabled: unknown;
490
420
  }
491
421
 
422
+ /** Event emitted when the user starts dragging a draggable. */
423
+ interface CdkDragStart<T = any> {
424
+ /** Draggable that emitted the event. */
425
+ source: CdkDrag<T>;
426
+ /** Native event that started the drag sequence. */
427
+ event: MouseEvent | TouchEvent;
428
+ }
429
+ /** Event emitted when the user releases an item, before any animations have started. */
430
+ interface CdkDragRelease<T = any> {
431
+ /** Draggable that emitted the event. */
432
+ source: CdkDrag<T>;
433
+ /** Native event that caused the release event. */
434
+ event: MouseEvent | TouchEvent;
435
+ }
436
+ /** Event emitted when the user stops dragging a draggable. */
437
+ interface CdkDragEnd<T = any> {
438
+ /** Draggable that emitted the event. */
439
+ source: CdkDrag<T>;
440
+ /** Distance in pixels that the user has dragged since the drag sequence started. */
441
+ distance: {
442
+ x: number;
443
+ y: number;
444
+ };
445
+ /** Position where the pointer was when the item was dropped */
446
+ dropPoint: {
447
+ x: number;
448
+ y: number;
449
+ };
450
+ /** Native event that caused the dragging to stop. */
451
+ event: MouseEvent | TouchEvent;
452
+ }
453
+ /** Event emitted when the user moves an item into a new drop container. */
454
+ interface CdkDragEnter<T = any, I = T> {
455
+ /** Container into which the user has moved the item. */
456
+ container: CdkDropList<T>;
457
+ /** Item that was moved into the container. */
458
+ item: CdkDrag<I>;
459
+ /** Index at which the item has entered the container. */
460
+ currentIndex: number;
461
+ }
462
+ /**
463
+ * Event emitted when the user removes an item from a
464
+ * drop container by moving it into another one.
465
+ */
466
+ interface CdkDragExit<T = any, I = T> {
467
+ /** Container from which the user has a removed an item. */
468
+ container: CdkDropList<T>;
469
+ /** Item that was removed from the container. */
470
+ item: CdkDrag<I>;
471
+ }
472
+ /** Event emitted when the user drops a draggable item inside a drop container. */
473
+ interface CdkDragDrop<T, O = T, I = any> {
474
+ /** Index of the item when it was picked up. */
475
+ previousIndex: number;
476
+ /** Current index of the item. */
477
+ currentIndex: number;
478
+ /** Item that is being dropped. */
479
+ item: CdkDrag<I>;
480
+ /** Container in which the item was dropped. */
481
+ container: CdkDropList<T>;
482
+ /** Container from which the item was picked up. Can be the same as the `container`. */
483
+ previousContainer: CdkDropList<O>;
484
+ /** Whether the user's pointer was over the container when the item was dropped. */
485
+ isPointerOverContainer: boolean;
486
+ /** Distance in pixels that the user has dragged since the drag sequence started. */
487
+ distance: {
488
+ x: number;
489
+ y: number;
490
+ };
491
+ /** Position where the pointer was when the item was dropped */
492
+ dropPoint: {
493
+ x: number;
494
+ y: number;
495
+ };
496
+ /** Native event that caused the drop event. */
497
+ event: MouseEvent | TouchEvent;
498
+ }
499
+ /** Event emitted as the user is dragging a draggable item. */
500
+ interface CdkDragMove<T = any> {
501
+ /** Item that is being dragged. */
502
+ source: CdkDrag<T>;
503
+ /** Position of the user's pointer on the page. */
504
+ pointerPosition: {
505
+ x: number;
506
+ y: number;
507
+ };
508
+ /** Native event that is causing the dragging. */
509
+ event: MouseEvent | TouchEvent;
510
+ /** Distance in pixels that the user has dragged since the drag sequence started. */
511
+ distance: {
512
+ x: number;
513
+ y: number;
514
+ };
515
+ /**
516
+ * Indicates the direction in which the user is dragging the element along each axis.
517
+ * `1` means that the position is increasing (e.g. the user is moving to the right or downwards),
518
+ * whereas `-1` means that it's decreasing (they're moving to the left or upwards). `0` means
519
+ * that the position hasn't changed.
520
+ */
521
+ delta: {
522
+ x: -1 | 0 | 1;
523
+ y: -1 | 0 | 1;
524
+ };
525
+ }
526
+ /** Event emitted when the user swaps the position of two drag items. */
527
+ interface CdkDragSortEvent<T = any, I = T> {
528
+ /** Index from which the item was sorted previously. */
529
+ previousIndex: number;
530
+ /** Index that the item is currently in. */
531
+ currentIndex: number;
532
+ /** Container that the item belongs to. */
533
+ container: CdkDropList<T>;
534
+ /** Item that is being sorted. */
535
+ item: CdkDrag<I>;
536
+ }
537
+
492
538
  /**
493
- * Declaratively connects sibling `cdkDropList` instances together. All of the `cdkDropList`
494
- * elements that are placed inside a `cdkDropListGroup` will be connected to each other
495
- * automatically. Can be used as an alternative to the `cdkDropListConnectedTo` input
496
- * from `cdkDropList`.
539
+ * Injection token that can be used to reference instances of `CdkDragHandle`. It serves as
540
+ * alternative token to the actual `CdkDragHandle` class which could cause unnecessary
541
+ * retention of the class and its directive metadata.
497
542
  */
498
- export declare class CdkDropListGroup<T> implements OnDestroy {
499
- /** Drop lists registered inside the group. */
500
- readonly _items: Set<T>;
501
- /** Whether starting a dragging sequence from inside this group is disabled. */
502
- disabled: boolean;
543
+ declare const CDK_DRAG_HANDLE: InjectionToken<CdkDragHandle>;
544
+ /** Handle that can be used to drag a CdkDrag instance. */
545
+ declare class CdkDragHandle implements AfterViewInit, OnDestroy {
546
+ element: ElementRef<HTMLElement>;
547
+ private _parentDrag;
548
+ private _dragDropRegistry;
549
+ /** Emits when the state of the handle has changed. */
550
+ readonly _stateChanges: Subject<CdkDragHandle>;
551
+ /** Whether starting to drag through this handle is disabled. */
552
+ get disabled(): boolean;
553
+ set disabled(value: boolean);
554
+ private _disabled;
555
+ constructor(...args: unknown[]);
556
+ ngAfterViewInit(): void;
503
557
  ngOnDestroy(): void;
504
- static ɵfac: i0.ɵɵFactoryDeclaration<CdkDropListGroup<any>, never>;
505
- static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDropListGroup<any>, "[cdkDropListGroup]", ["cdkDropListGroup"], { "disabled": { "alias": "cdkDropListGroupDisabled"; "required": false; }; }, {}, never, never, true, never>;
558
+ static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragHandle, never>;
559
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragHandle, "[cdkDragHandle]", never, { "disabled": { "alias": "cdkDragHandleDisabled"; "required": false; }; }, {}, never, never, true, never>;
506
560
  static ngAcceptInputType_disabled: unknown;
507
561
  }
508
562
 
509
563
  /**
510
- * Copies an item from one array to another, leaving it in its
511
- * original position in current array.
512
- * @param currentArray Array from which to copy the item.
513
- * @param targetArray Array into which is copy the item.
514
- * @param currentIndex Index of the item in its current array.
515
- * @param targetIndex Index at which to insert the item.
516
- *
564
+ * Injection token that can be used to reference instances of `CdkDragPlaceholder`. It serves as
565
+ * alternative token to the actual `CdkDragPlaceholder` class which could cause unnecessary
566
+ * retention of the class and its directive metadata.
517
567
  */
518
- export declare function copyArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
519
-
520
- /** Possible axis along which dragging can be locked. */
521
- export declare type DragAxis = 'x' | 'y';
522
-
523
- /** Function that can be used to constrain the position of a dragged element. */
524
- export declare type DragConstrainPosition = (userPointerPosition: Point, dragRef: DragRef, dimensions: DOMRect, pickupPositionInElement: Point) => Point;
525
-
568
+ declare const CDK_DRAG_PLACEHOLDER: InjectionToken<CdkDragPlaceholder<any>>;
526
569
  /**
527
- * Service that allows for drag-and-drop functionality to be attached to DOM elements.
570
+ * Element that will be used as a template for the placeholder of a CdkDrag when
571
+ * it is being dragged. The placeholder is displayed in place of the element being dragged.
528
572
  */
529
- export declare class DragDrop {
530
- private _document;
531
- private _ngZone;
532
- private _viewportRuler;
533
- private _dragDropRegistry;
534
- private _renderer;
573
+ declare class CdkDragPlaceholder<T = any> implements OnDestroy {
574
+ templateRef: TemplateRef<T>;
575
+ private _drag;
576
+ /** Context data to be added to the placeholder template instance. */
577
+ data: T;
535
578
  constructor(...args: unknown[]);
536
- /**
537
- * Turns an element into a draggable item.
538
- * @param element Element to which to attach the dragging functionality.
539
- * @param config Object used to configure the dragging behavior.
540
- */
541
- createDrag<T = any>(element: ElementRef<HTMLElement> | HTMLElement, config?: DragRefConfig): DragRef<T>;
542
- /**
543
- * Turns an element into a drop list.
544
- * @param element Element to which to attach the drop list functionality.
545
- */
546
- createDropList<T = any>(element: ElementRef<HTMLElement> | HTMLElement): DropListRef<T>;
547
- static ɵfac: i0.ɵɵFactoryDeclaration<DragDrop, never>;
548
- static ɵprov: i0.ɵɵInjectableDeclaration<DragDrop>;
579
+ ngOnDestroy(): void;
580
+ static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragPlaceholder<any>, never>;
581
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragPlaceholder<any>, "ng-template[cdkDragPlaceholder]", never, { "data": { "alias": "data"; "required": false; }; }, {}, never, never, true, never>;
549
582
  }
550
583
 
551
584
  /**
552
- * Object that can be used to configure the drag
553
- * items and drop lists within a module or a component.
585
+ * Injection token that can be used to reference instances of `CdkDragPreview`. It serves as
586
+ * alternative token to the actual `CdkDragPreview` class which could cause unnecessary
587
+ * retention of the class and its directive metadata.
554
588
  */
555
- export declare interface DragDropConfig extends Partial<DragRefConfig> {
556
- lockAxis?: DragAxis;
557
- dragStartDelay?: DragStartDelay;
558
- constrainPosition?: DragConstrainPosition;
559
- previewClass?: string | string[];
560
- boundaryElement?: string;
561
- rootElementSelector?: string;
562
- draggingDisabled?: boolean;
563
- sortingDisabled?: boolean;
564
- listAutoScrollDisabled?: boolean;
565
- listOrientation?: DropListOrientation;
566
- zIndex?: number;
567
- previewContainer?: 'global' | 'parent';
568
- }
569
-
570
- export declare class DragDropModule {
571
- static ɵfac: i0.ɵɵFactoryDeclaration<DragDropModule, never>;
572
- static ɵmod: i0.ɵɵNgModuleDeclaration<DragDropModule, never, [typeof i1.CdkDropList, typeof i2.CdkDropListGroup, typeof i3.CdkDrag, typeof i4.CdkDragHandle, typeof i5.CdkDragPreview, typeof i6.CdkDragPlaceholder], [typeof i7.CdkScrollableModule, typeof i1.CdkDropList, typeof i2.CdkDropListGroup, typeof i3.CdkDrag, typeof i4.CdkDragHandle, typeof i5.CdkDragPreview, typeof i6.CdkDragPlaceholder]>;
573
- static ɵinj: i0.ɵɵInjectorDeclaration<DragDropModule>;
574
- }
575
-
589
+ declare const CDK_DRAG_PREVIEW: InjectionToken<CdkDragPreview<any>>;
576
590
  /**
577
- * Service that keeps track of all the drag item and drop container
578
- * instances, and manages global event listeners on the `document`.
579
- * @docs-private
591
+ * Element that will be used as a template for the preview
592
+ * of a CdkDrag when it is being dragged.
580
593
  */
581
- export declare class DragDropRegistry<_ = unknown, __ = unknown> implements OnDestroy {
582
- private _ngZone;
583
- private _document;
584
- private _styleLoader;
585
- private _renderer;
586
- private _cleanupDocumentTouchmove;
587
- /** Registered drop container instances. */
588
- private _dropInstances;
589
- /** Registered drag item instances. */
590
- private _dragInstances;
591
- /** Drag item instances that are currently being dragged. */
592
- private _activeDragInstances;
593
- /** Keeps track of the event listeners that we've bound to the `document`. */
594
- private _globalListeners;
595
- /**
596
- * Predicate function to check if an item is being dragged. Moved out into a property,
597
- * because it'll be called a lot and we don't want to create a new function every time.
598
- */
599
- private _draggingPredicate;
600
- /**
601
- * Map tracking DOM nodes and their corresponding drag directives. Note that this is different
602
- * from looking through the `_dragInstances` and getting their root node, because the root node
603
- * isn't necessarily the node that the directive is set on.
604
- */
605
- private _domNodesToDirectives;
606
- /**
607
- * Emits the `touchmove` or `mousemove` events that are dispatched
608
- * while the user is dragging a drag item instance.
609
- */
610
- readonly pointerMove: Subject<TouchEvent | MouseEvent>;
611
- /**
612
- * Emits the `touchend` or `mouseup` events that are dispatched
613
- * while the user is dragging a drag item instance.
614
- */
615
- readonly pointerUp: Subject<TouchEvent | MouseEvent>;
616
- /**
617
- * Emits when the viewport has been scrolled while the user is dragging an item.
618
- * @deprecated To be turned into a private member. Use the `scrolled` method instead.
619
- * @breaking-change 13.0.0
620
- */
621
- readonly scroll: Subject<Event>;
594
+ declare class CdkDragPreview<T = any> implements OnDestroy {
595
+ templateRef: TemplateRef<T>;
596
+ private _drag;
597
+ /** Context data to be added to the preview template instance. */
598
+ data: T;
599
+ /** Whether the preview should preserve the same size as the item that is being dragged. */
600
+ matchSize: boolean;
622
601
  constructor(...args: unknown[]);
623
- /** Adds a drop container to the registry. */
624
- registerDropContainer(drop: DropListRef): void;
625
- /** Adds a drag item instance to the registry. */
626
- registerDragItem(drag: DragRef): void;
627
- /** Removes a drop container from the registry. */
628
- removeDropContainer(drop: DropListRef): void;
629
- /** Removes a drag item instance from the registry. */
630
- removeDragItem(drag: DragRef): void;
631
- /**
632
- * Starts the dragging sequence for a drag instance.
633
- * @param drag Drag instance which is being dragged.
634
- * @param event Event that initiated the dragging.
635
- */
636
- startDragging(drag: DragRef, event: TouchEvent | MouseEvent): void;
637
- /** Stops dragging a drag item instance. */
638
- stopDragging(drag: DragRef): void;
639
- /** Gets whether a drag item instance is currently being dragged. */
640
- isDragging(drag: DragRef): boolean;
641
- /**
642
- * Gets a stream that will emit when any element on the page is scrolled while an item is being
643
- * dragged.
644
- * @param shadowRoot Optional shadow root that the current dragging sequence started from.
645
- * Top-level listeners won't pick up events coming from the shadow DOM so this parameter can
646
- * be used to include an additional top-level listener at the shadow root level.
647
- */
648
- scrolled(shadowRoot?: DocumentOrShadowRoot | null): Observable<Event>;
649
- /**
650
- * Tracks the DOM node which has a draggable directive.
651
- * @param node Node to track.
652
- * @param dragRef Drag directive set on the node.
653
- */
654
- registerDirectiveNode(node: Node, dragRef: CdkDrag): void;
655
- /**
656
- * Stops tracking a draggable directive node.
657
- * @param node Node to stop tracking.
658
- */
659
- removeDirectiveNode(node: Node): void;
660
- /**
661
- * Gets the drag directive corresponding to a specific DOM node, if any.
662
- * @param node Node for which to do the lookup.
663
- */
664
- getDragDirectiveForNode(node: Node): CdkDrag | null;
665
602
  ngOnDestroy(): void;
666
- /**
667
- * Event listener that will prevent the default browser action while the user is dragging.
668
- * @param event Event whose default action should be prevented.
669
- */
670
- private _preventDefaultWhileDragging;
671
- /** Event listener for `touchmove` that is bound even if no dragging is happening. */
672
- private _persistentTouchmoveListener;
673
- /** Clears out the global event listeners from the `document`. */
674
- private _clearGlobalListeners;
675
- static ɵfac: i0.ɵɵFactoryDeclaration<DragDropRegistry<any, any>, never>;
676
- static ɵprov: i0.ɵɵInjectableDeclaration<DragDropRegistry<any, any>>;
677
- }
678
-
679
- /** Template that can be used to create a drag helper element (e.g. a preview or a placeholder). */
680
- declare interface DragHelperTemplate<T = any> {
681
- template: TemplateRef<T> | null;
682
- viewContainer: ViewContainerRef;
683
- context: T;
684
- }
685
-
686
- /** Template that can be used to create a drag preview element. */
687
- declare interface DragPreviewTemplate<T = any> {
688
- matchSize?: boolean;
689
- template: TemplateRef<T> | null;
690
- viewContainer: ViewContainerRef;
691
- context: T;
603
+ static ɵfac: i0.ɵɵFactoryDeclaration<CdkDragPreview<any>, never>;
604
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDragPreview<any>, "ng-template[cdkDragPreview]", never, { "data": { "alias": "data"; "required": false; }; "matchSize": { "alias": "matchSize"; "required": false; }; }, {}, never, never, true, never>;
605
+ static ngAcceptInputType_matchSize: unknown;
692
606
  }
693
607
 
694
608
  /**
695
- * Reference to a draggable item. Used to manipulate or dispose of the item.
609
+ * Injection token that can be used to reference instances of `CdkDropList`. It serves as
610
+ * alternative token to the actual `CdkDropList` class which could cause unnecessary
611
+ * retention of the class and its directive metadata.
696
612
  */
697
- export declare class DragRef<T = any> {
698
- private _config;
699
- private _document;
613
+ declare const CDK_DROP_LIST: InjectionToken<CdkDropList<any>>;
614
+ /** Element that can be moved inside a CdkDropList container. */
615
+ declare class CdkDrag<T = any> implements AfterViewInit, OnChanges, OnDestroy {
616
+ element: ElementRef<HTMLElement>;
617
+ dropContainer: CdkDropList<any>;
700
618
  private _ngZone;
701
- private _viewportRuler;
619
+ private _viewContainerRef;
620
+ private _dir;
621
+ private _changeDetectorRef;
622
+ private _selfHandle;
623
+ private _parentDrag;
702
624
  private _dragDropRegistry;
703
- private _renderer;
704
- private _rootElementCleanups;
705
- private _cleanupShadowRootSelectStart;
706
- /** Element displayed next to the user's pointer while the element is dragged. */
707
- private _preview;
708
- /** Container into which to insert the preview. */
709
- private _previewContainer;
710
- /** Reference to the view of the placeholder element. */
711
- private _placeholderRef;
712
- /** Element that is rendered instead of the draggable item while it is being sorted. */
713
- private _placeholder;
714
- /** Coordinates within the element at which the user picked up the element. */
715
- private _pickupPositionInElement;
716
- /** Coordinates on the page at which the user picked up the element. */
717
- private _pickupPositionOnPage;
718
- /**
719
- * Anchor node used to save the place in the DOM where the element was
720
- * picked up so that it can be restored at the end of the drag sequence.
721
- */
722
- private _anchor;
723
- /**
724
- * CSS `transform` applied to the element when it isn't being dragged. We need a
725
- * passive transform in order for the dragged element to retain its new position
726
- * after the user has stopped dragging and because we need to know the relative
727
- * position in case they start dragging again. This corresponds to `element.style.transform`.
728
- */
729
- private _passiveTransform;
730
- /** CSS `transform` that is applied to the element while it's being dragged. */
731
- private _activeTransform;
732
- /** Inline `transform` value that the element had before the first dragging sequence. */
733
- private _initialTransform?;
734
- /**
735
- * Whether the dragging sequence has been started. Doesn't
736
- * necessarily mean that the element has been moved.
737
- */
738
- private _hasStartedDragging;
739
- /** Whether the element has moved since the user started dragging it. */
740
- private _hasMoved;
741
- /** Drop container in which the DragRef resided when dragging began. */
742
- private _initialContainer;
743
- /** Index at which the item started in its initial container. */
744
- private _initialIndex;
745
- /** Cached positions of scrollable parent elements. */
746
- private _parentPositions;
747
- /** Emits when the item is being moved. */
748
- private readonly _moveEvents;
749
- /** Keeps track of the direction in which the user is dragging along each axis. */
750
- private _pointerDirectionDelta;
751
- /** Pointer position at which the last change in the delta occurred. */
752
- private _pointerPositionAtLastDirectionChange;
753
- /** Position of the pointer at the last pointer event. */
754
- private _lastKnownPointerPosition;
755
- /**
756
- * Root DOM node of the drag instance. This is the element that will
757
- * be moved around as the user is dragging.
758
- */
759
- private _rootElement;
760
- /**
761
- * Nearest ancestor SVG, relative to which coordinates are calculated if dragging SVGElement
762
- */
763
- private _ownerSVGElement;
764
- /**
765
- * Inline style value of `-webkit-tap-highlight-color` at the time the
766
- * dragging was started. Used to restore the value once we're done dragging.
767
- */
768
- private _rootElementTapHighlight;
769
- /** Subscription to pointer movement events. */
770
- private _pointerMoveSubscription;
771
- /** Subscription to the event that is dispatched when the user lifts their pointer. */
772
- private _pointerUpSubscription;
773
- /** Subscription to the viewport being scrolled. */
774
- private _scrollSubscription;
775
- /** Subscription to the viewport being resized. */
776
- private _resizeSubscription;
777
- /**
778
- * Time at which the last touch event occurred. Used to avoid firing the same
779
- * events multiple times on touch devices where the browser will fire a fake
780
- * mouse event for each touch event, after a certain time.
781
- */
782
- private _lastTouchEventTime;
783
- /** Time at which the last dragging sequence was started. */
784
- private _dragStartTime;
785
- /** Cached reference to the boundary element. */
786
- private _boundaryElement;
787
- /** Whether the native dragging interactions have been enabled on the root element. */
788
- private _nativeInteractionsEnabled;
789
- /** Client rect of the root element when the dragging sequence has started. */
790
- private _initialDomRect?;
791
- /** Cached dimensions of the preview element. Should be read via `_getPreviewRect`. */
792
- private _previewRect?;
793
- /** Cached dimensions of the boundary element. */
794
- private _boundaryRect?;
795
- /** Element that will be used as a template to create the draggable item's preview. */
796
- private _previewTemplate?;
797
- /** Template for placeholder element rendered to show where a draggable would be dropped. */
798
- private _placeholderTemplate?;
799
- /** Elements that can be used to drag the draggable item. */
800
- private _handles;
801
- /** Registered handles that are currently disabled. */
802
- private _disabledHandles;
803
- /** Droppable container that the draggable is a part of. */
804
- private _dropContainer?;
805
- /** Layout direction of the item. */
806
- private _direction;
807
- /** Ref that the current drag item is nested in. */
808
- private _parentDragRef;
625
+ private readonly _destroyed;
626
+ private _handles;
627
+ private _previewTemplate;
628
+ private _placeholderTemplate;
629
+ /** Reference to the underlying drag instance. */
630
+ _dragRef: DragRef<CdkDrag<T>>;
631
+ /** Arbitrary data to attach to this drag instance. */
632
+ data: T;
633
+ /** Locks the position of the dragged element along the specified axis. */
634
+ lockAxis: DragAxis;
809
635
  /**
810
- * Cached shadow root that the element is placed in. `null` means that the element isn't in
811
- * the shadow DOM and `undefined` means that it hasn't been resolved yet. Should be read via
812
- * `_getShadowRoot`, not directly.
636
+ * Selector that will be used to determine the root draggable element, starting from
637
+ * the `cdkDrag` element and going up the DOM. Passing an alternate root element is useful
638
+ * when trying to enable dragging on an element that you might not have access to.
813
639
  */
814
- private _cachedShadowRoot;
815
- /** Axis along which dragging is locked. */
816
- lockAxis: 'x' | 'y';
640
+ rootElementSelector: string;
641
+ /**
642
+ * Node or selector that will be used to determine the element to which the draggable's
643
+ * position will be constrained. If a string is passed in, it'll be used as a selector that
644
+ * will be matched starting from the element's parent and going up the DOM until a match
645
+ * has been found.
646
+ */
647
+ boundaryElement: string | ElementRef<HTMLElement> | HTMLElement;
817
648
  /**
818
649
  * Amount of milliseconds to wait after the user has put their
819
650
  * pointer down before starting to drag the element.
820
651
  */
821
- dragStartDelay: number | {
822
- touch: number;
823
- mouse: number;
824
- };
825
- /** Class to be added to the preview element. */
826
- previewClass: string | string[] | undefined;
652
+ dragStartDelay: DragStartDelay;
827
653
  /**
828
- * If the parent of the dragged element has a `scale` transform, it can throw off the
829
- * positioning when the user starts dragging. Use this input to notify the CDK of the scale.
654
+ * Sets the position of a `CdkDrag` that is outside of a drop container.
655
+ * Can be used to restore the element's position for a returning user.
830
656
  */
831
- scale: number;
657
+ freeDragPosition: Point;
832
658
  /** Whether starting to drag this element is disabled. */
833
659
  get disabled(): boolean;
834
660
  set disabled(value: boolean);
835
661
  private _disabled;
836
- /** Emits as the drag sequence is being prepared. */
837
- readonly beforeStarted: Subject<void>;
662
+ /**
663
+ * Function that can be used to customize the logic of how the position of the drag item
664
+ * is limited while it's being dragged. Gets called with a point containing the current position
665
+ * of the user's pointer on the page, a reference to the item being dragged and its dimensions.
666
+ * Should return a point describing where the item should be rendered.
667
+ */
668
+ constrainPosition?: DragConstrainPosition;
669
+ /** Class to be added to the preview element. */
670
+ previewClass: string | string[];
671
+ /**
672
+ * Configures the place into which the preview of the item will be inserted. Can be configured
673
+ * globally through `CDK_DROP_LIST`. Possible values:
674
+ * - `global` - Preview will be inserted at the bottom of the `<body>`. The advantage is that
675
+ * you don't have to worry about `overflow: hidden` or `z-index`, but the item won't retain
676
+ * its inherited styles.
677
+ * - `parent` - Preview will be inserted into the parent of the drag item. The advantage is that
678
+ * inherited styles will be preserved, but it may be clipped by `overflow: hidden` or not be
679
+ * visible due to `z-index`. Furthermore, the preview is going to have an effect over selectors
680
+ * like `:nth-child` and some flexbox configurations.
681
+ * - `ElementRef<HTMLElement> | HTMLElement` - Preview will be inserted into a specific element.
682
+ * Same advantages and disadvantages as `parent`.
683
+ */
684
+ previewContainer: PreviewContainer;
685
+ /**
686
+ * If the parent of the dragged element has a `scale` transform, it can throw off the
687
+ * positioning when the user starts dragging. Use this input to notify the CDK of the scale.
688
+ */
689
+ scale: number;
838
690
  /** Emits when the user starts dragging the item. */
839
- readonly started: Subject<{
840
- source: DragRef;
841
- event: MouseEvent | TouchEvent;
842
- }>;
691
+ readonly started: EventEmitter<CdkDragStart>;
843
692
  /** Emits when the user has released a drag item, before any animations have started. */
844
- readonly released: Subject<{
845
- source: DragRef;
846
- event: MouseEvent | TouchEvent;
847
- }>;
693
+ readonly released: EventEmitter<CdkDragRelease>;
848
694
  /** Emits when the user stops dragging an item in the container. */
849
- readonly ended: Subject<{
850
- source: DragRef;
851
- distance: Point;
852
- dropPoint: Point;
853
- event: MouseEvent | TouchEvent;
854
- }>;
695
+ readonly ended: EventEmitter<CdkDragEnd>;
855
696
  /** Emits when the user has moved the item into a new container. */
856
- readonly entered: Subject<{
857
- container: DropListRef;
858
- item: DragRef;
859
- currentIndex: number;
860
- }>;
697
+ readonly entered: EventEmitter<CdkDragEnter<any>>;
861
698
  /** Emits when the user removes the item its container by dragging it into another container. */
862
- readonly exited: Subject<{
863
- container: DropListRef;
864
- item: DragRef;
865
- }>;
699
+ readonly exited: EventEmitter<CdkDragExit<any>>;
866
700
  /** Emits when the user drops the item inside a container. */
867
- readonly dropped: Subject<{
868
- previousIndex: number;
869
- currentIndex: number;
870
- item: DragRef;
871
- container: DropListRef;
872
- previousContainer: DropListRef;
873
- distance: Point;
874
- dropPoint: Point;
875
- isPointerOverContainer: boolean;
876
- event: MouseEvent | TouchEvent;
877
- }>;
701
+ readonly dropped: EventEmitter<CdkDragDrop<any>>;
878
702
  /**
879
703
  * Emits as the user is dragging the item. Use with caution,
880
704
  * because this event will fire for every pixel that the user has dragged.
881
705
  */
882
- readonly moved: Observable<{
883
- source: DragRef;
884
- pointerPosition: {
885
- x: number;
886
- y: number;
887
- };
888
- event: MouseEvent | TouchEvent;
889
- distance: Point;
890
- delta: {
891
- x: -1 | 0 | 1;
892
- y: -1 | 0 | 1;
893
- };
894
- }>;
895
- /** Arbitrary data that can be attached to the drag item. */
896
- data: T;
897
- /**
898
- * Function that can be used to customize the logic of how the position of the drag item
899
- * is limited while it's being dragged. Gets called with a point containing the current position
900
- * of the user's pointer on the page, a reference to the item being dragged and its dimensions.
901
- * Should return a point describing where the item should be rendered.
902
- */
903
- constrainPosition?: DragConstrainPosition;
904
- constructor(element: ElementRef<HTMLElement> | HTMLElement, _config: DragRefConfig, _document: Document, _ngZone: NgZone, _viewportRuler: ViewportRuler, _dragDropRegistry: DragDropRegistry, _renderer: Renderer2);
706
+ readonly moved: Observable<CdkDragMove<T>>;
707
+ private _injector;
708
+ constructor(...args: unknown[]);
905
709
  /**
906
710
  * Returns the element that is being used as a placeholder
907
711
  * while the current element is being dragged.
@@ -909,458 +713,566 @@ export declare class DragRef<T = any> {
909
713
  getPlaceholderElement(): HTMLElement;
910
714
  /** Returns the root draggable element. */
911
715
  getRootElement(): HTMLElement;
716
+ /** Resets a standalone drag item to its initial position. */
717
+ reset(): void;
718
+ /** Resets drag item to end of boundary element. */
719
+ resetToBoundary(): void;
912
720
  /**
913
- * Gets the currently-visible element that represents the drag item.
914
- * While dragging this is the placeholder, otherwise it's the root element.
721
+ * Gets the pixel coordinates of the draggable outside of a drop container.
915
722
  */
916
- getVisibleElement(): HTMLElement;
917
- /** Registers the handles that can be used to drag the element. */
918
- withHandles(handles: (HTMLElement | ElementRef<HTMLElement>)[]): this;
723
+ getFreeDragPosition(): Readonly<Point>;
919
724
  /**
920
- * Registers the template that should be used for the drag preview.
921
- * @param template Template that from which to stamp out the preview.
725
+ * Sets the current position in pixels the draggable outside of a drop container.
726
+ * @param value New position to be set.
922
727
  */
923
- withPreviewTemplate(template: DragPreviewTemplate | null): this;
728
+ setFreeDragPosition(value: Point): void;
729
+ ngAfterViewInit(): void;
730
+ ngOnChanges(changes: SimpleChanges): void;
731
+ ngOnDestroy(): void;
732
+ _addHandle(handle: CdkDragHandle): void;
733
+ _removeHandle(handle: CdkDragHandle): void;
734
+ _setPreviewTemplate(preview: CdkDragPreview): void;
735
+ _resetPreviewTemplate(preview: CdkDragPreview): void;
736
+ _setPlaceholderTemplate(placeholder: CdkDragPlaceholder): void;
737
+ _resetPlaceholderTemplate(placeholder: CdkDragPlaceholder): void;
738
+ /** Syncs the root element with the `DragRef`. */
739
+ private _updateRootElement;
740
+ /** Gets the boundary element, based on the `boundaryElement` value. */
741
+ private _getBoundaryElement;
742
+ /** Syncs the inputs of the CdkDrag with the options of the underlying DragRef. */
743
+ private _syncInputs;
744
+ /** Handles the events from the underlying `DragRef`. */
745
+ private _handleEvents;
746
+ /** Assigns the default input values based on a provided config object. */
747
+ private _assignDefaults;
748
+ /** Sets up the listener that syncs the handles with the drag ref. */
749
+ private _setupHandlesListener;
750
+ static ɵfac: i0.ɵɵFactoryDeclaration<CdkDrag<any>, never>;
751
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDrag<any>, "[cdkDrag]", ["cdkDrag"], { "data": { "alias": "cdkDragData"; "required": false; }; "lockAxis": { "alias": "cdkDragLockAxis"; "required": false; }; "rootElementSelector": { "alias": "cdkDragRootElement"; "required": false; }; "boundaryElement": { "alias": "cdkDragBoundary"; "required": false; }; "dragStartDelay": { "alias": "cdkDragStartDelay"; "required": false; }; "freeDragPosition": { "alias": "cdkDragFreeDragPosition"; "required": false; }; "disabled": { "alias": "cdkDragDisabled"; "required": false; }; "constrainPosition": { "alias": "cdkDragConstrainPosition"; "required": false; }; "previewClass": { "alias": "cdkDragPreviewClass"; "required": false; }; "previewContainer": { "alias": "cdkDragPreviewContainer"; "required": false; }; "scale": { "alias": "cdkDragScale"; "required": false; }; }, { "started": "cdkDragStarted"; "released": "cdkDragReleased"; "ended": "cdkDragEnded"; "entered": "cdkDragEntered"; "exited": "cdkDragExited"; "dropped": "cdkDragDropped"; "moved": "cdkDragMoved"; }, never, never, true, never>;
752
+ static ngAcceptInputType_disabled: unknown;
753
+ static ngAcceptInputType_scale: unknown;
754
+ }
755
+
756
+ /**
757
+ * Service that keeps track of all the drag item and drop container
758
+ * instances, and manages global event listeners on the `document`.
759
+ * @docs-private
760
+ */
761
+ declare class DragDropRegistry implements OnDestroy {
762
+ private _ngZone;
763
+ private _document;
764
+ private _styleLoader;
765
+ private _renderer;
766
+ private _cleanupDocumentTouchmove;
767
+ private _scroll;
768
+ /** Registered drop container instances. */
769
+ private _dropInstances;
770
+ /** Registered drag item instances. */
771
+ private _dragInstances;
772
+ /** Drag item instances that are currently being dragged. */
773
+ private _activeDragInstances;
774
+ /** Keeps track of the event listeners that we've bound to the `document`. */
775
+ private _globalListeners;
924
776
  /**
925
- * Registers the template that should be used for the drag placeholder.
926
- * @param template Template that from which to stamp out the placeholder.
777
+ * Predicate function to check if an item is being dragged. Moved out into a property,
778
+ * because it'll be called a lot and we don't want to create a new function every time.
927
779
  */
928
- withPlaceholderTemplate(template: DragHelperTemplate | null): this;
780
+ private _draggingPredicate;
929
781
  /**
930
- * Sets an alternate drag root element. The root element is the element that will be moved as
931
- * the user is dragging. Passing an alternate root element is useful when trying to enable
932
- * dragging on an element that you might not have access to.
782
+ * Map tracking DOM nodes and their corresponding drag directives. Note that this is different
783
+ * from looking through the `_dragInstances` and getting their root node, because the root node
784
+ * isn't necessarily the node that the directive is set on.
933
785
  */
934
- withRootElement(rootElement: ElementRef<HTMLElement> | HTMLElement): this;
786
+ private _domNodesToDirectives;
935
787
  /**
936
- * Element to which the draggable's position will be constrained.
788
+ * Emits the `touchmove` or `mousemove` events that are dispatched
789
+ * while the user is dragging a drag item instance.
937
790
  */
938
- withBoundaryElement(boundaryElement: ElementRef<HTMLElement> | HTMLElement | null): this;
939
- /** Sets the parent ref that the ref is nested in. */
940
- withParent(parent: DragRef<unknown> | null): this;
941
- /** Removes the dragging functionality from the DOM element. */
942
- dispose(): void;
943
- /** Checks whether the element is currently being dragged. */
944
- isDragging(): boolean;
945
- /** Resets a standalone drag item to its initial position. */
946
- reset(): void;
791
+ readonly pointerMove: Subject<TouchEvent | MouseEvent>;
947
792
  /**
948
- * Sets a handle as disabled. While a handle is disabled, it'll capture and interrupt dragging.
949
- * @param handle Handle element that should be disabled.
793
+ * Emits the `touchend` or `mouseup` events that are dispatched
794
+ * while the user is dragging a drag item instance.
950
795
  */
951
- disableHandle(handle: HTMLElement): void;
796
+ readonly pointerUp: Subject<TouchEvent | MouseEvent>;
797
+ constructor(...args: unknown[]);
798
+ /** Adds a drop container to the registry. */
799
+ registerDropContainer(drop: DropListRef): void;
800
+ /** Adds a drag item instance to the registry. */
801
+ registerDragItem(drag: DragRef): void;
802
+ /** Removes a drop container from the registry. */
803
+ removeDropContainer(drop: DropListRef): void;
804
+ /** Removes a drag item instance from the registry. */
805
+ removeDragItem(drag: DragRef): void;
952
806
  /**
953
- * Enables a handle, if it has been disabled.
954
- * @param handle Handle element to be enabled.
807
+ * Starts the dragging sequence for a drag instance.
808
+ * @param drag Drag instance which is being dragged.
809
+ * @param event Event that initiated the dragging.
955
810
  */
956
- enableHandle(handle: HTMLElement): void;
957
- /** Sets the layout direction of the draggable item. */
958
- withDirection(direction: Direction): this;
959
- /** Sets the container that the item is part of. */
960
- _withDropContainer(container: DropListRef): void;
811
+ startDragging(drag: DragRef, event: TouchEvent | MouseEvent): void;
812
+ /** Stops dragging a drag item instance. */
813
+ stopDragging(drag: DragRef): void;
814
+ /** Gets whether a drag item instance is currently being dragged. */
815
+ isDragging(drag: DragRef): boolean;
961
816
  /**
962
- * Gets the current position in pixels the draggable outside of a drop container.
817
+ * Gets a stream that will emit when any element on the page is scrolled while an item is being
818
+ * dragged.
819
+ * @param shadowRoot Optional shadow root that the current dragging sequence started from.
820
+ * Top-level listeners won't pick up events coming from the shadow DOM so this parameter can
821
+ * be used to include an additional top-level listener at the shadow root level.
963
822
  */
964
- getFreeDragPosition(): Readonly<Point>;
823
+ scrolled(shadowRoot?: DocumentOrShadowRoot | null): Observable<Event>;
965
824
  /**
966
- * Sets the current position in pixels the draggable outside of a drop container.
967
- * @param value New position to be set.
825
+ * Tracks the DOM node which has a draggable directive.
826
+ * @param node Node to track.
827
+ * @param dragRef Drag directive set on the node.
968
828
  */
969
- setFreeDragPosition(value: Point): this;
829
+ registerDirectiveNode(node: Node, dragRef: CdkDrag): void;
970
830
  /**
971
- * Sets the container into which to insert the preview element.
972
- * @param value Container into which to insert the preview.
831
+ * Stops tracking a draggable directive node.
832
+ * @param node Node to stop tracking.
973
833
  */
974
- withPreviewContainer(value: PreviewContainer): this;
975
- /** Updates the item's sort order based on the last-known pointer position. */
976
- _sortFromLastPointerPosition(): void;
977
- /** Unsubscribes from the global subscriptions. */
978
- private _removeListeners;
979
- /** Destroys the preview element and its ViewRef. */
980
- private _destroyPreview;
981
- /** Destroys the placeholder element and its ViewRef. */
982
- private _destroyPlaceholder;
983
- /** Handler for the `mousedown`/`touchstart` events. */
984
- private _pointerDown;
985
- /** Handler that is invoked when the user moves their pointer after they've initiated a drag. */
986
- private _pointerMove;
987
- /** Handler that is invoked when the user lifts their pointer up, after initiating a drag. */
988
- private _pointerUp;
834
+ removeDirectiveNode(node: Node): void;
989
835
  /**
990
- * Clears subscriptions and stops the dragging sequence.
991
- * @param event Browser event object that ended the sequence.
836
+ * Gets the drag directive corresponding to a specific DOM node, if any.
837
+ * @param node Node for which to do the lookup.
992
838
  */
993
- private _endDragSequence;
994
- /** Starts the dragging sequence. */
995
- private _startDragSequence;
839
+ getDragDirectiveForNode(node: Node): CdkDrag | null;
840
+ ngOnDestroy(): void;
996
841
  /**
997
- * Sets up the different variables and subscriptions
998
- * that will be necessary for the dragging sequence.
999
- * @param referenceElement Element that started the drag sequence.
1000
- * @param event Browser event object that started the sequence.
842
+ * Event listener that will prevent the default browser action while the user is dragging.
843
+ * @param event Event whose default action should be prevented.
1001
844
  */
1002
- private _initializeDragSequence;
1003
- /** Cleans up the DOM artifacts that were added to facilitate the element being dragged. */
1004
- private _cleanupDragArtifacts;
845
+ private _preventDefaultWhileDragging;
846
+ /** Event listener for `touchmove` that is bound even if no dragging is happening. */
847
+ private _persistentTouchmoveListener;
848
+ /** Clears out the global event listeners from the `document`. */
849
+ private _clearGlobalListeners;
850
+ static ɵfac: i0.ɵɵFactoryDeclaration<DragDropRegistry, never>;
851
+ static ɵprov: i0.ɵɵInjectableDeclaration<DragDropRegistry>;
852
+ }
853
+
854
+ /** Template that can be used to create a drag preview element. */
855
+ interface DragPreviewTemplate<T = any> {
856
+ matchSize?: boolean;
857
+ template: TemplateRef<T> | null;
858
+ viewContainer: ViewContainerRef;
859
+ context: T;
860
+ }
861
+
862
+ /** Object that can be used to configure the behavior of DragRef. */
863
+ interface DragRefConfig {
1005
864
  /**
1006
- * Updates the item's position in its drop container, or moves it
1007
- * into a new one, depending on its current drag position.
865
+ * Minimum amount of pixels that the user should
866
+ * drag, before the CDK initiates a drag sequence.
1008
867
  */
1009
- private _updateActiveDropContainer;
868
+ dragStartThreshold: number;
1010
869
  /**
1011
- * Animates the preview element from its current position to the location of the drop placeholder.
1012
- * @returns Promise that resolves when the animation completes.
870
+ * Amount the pixels the user should drag before the CDK
871
+ * considers them to have changed the drag direction.
1013
872
  */
1014
- private _animatePreviewToPlaceholder;
1015
- /** Creates an element that will be shown instead of the current element while dragging. */
1016
- private _createPlaceholderElement;
873
+ pointerDirectionChangeThreshold: number;
874
+ /** `z-index` for the absolutely-positioned elements that are created by the drag item. */
875
+ zIndex?: number;
876
+ /** Ref that the current drag item is nested in. */
877
+ parentDragRef?: DragRef;
878
+ }
879
+ /** Function that can be used to constrain the position of a dragged element. */
880
+ type DragConstrainPosition = (userPointerPosition: Point, dragRef: DragRef, dimensions: DOMRect, pickupPositionInElement: Point) => Point;
881
+ /** Template that can be used to create a drag helper element (e.g. a preview or a placeholder). */
882
+ interface DragHelperTemplate<T = any> {
883
+ template: TemplateRef<T> | null;
884
+ viewContainer: ViewContainerRef;
885
+ context: T;
886
+ }
887
+ /** Point on the page or within an element. */
888
+ interface Point {
889
+ x: number;
890
+ y: number;
891
+ }
892
+ /**
893
+ * Possible places into which the preview of a drag item can be inserted.
894
+ * - `global` - Preview will be inserted at the bottom of the `<body>`. The advantage is that
895
+ * you don't have to worry about `overflow: hidden` or `z-index`, but the item won't retain
896
+ * its inherited styles.
897
+ * - `parent` - Preview will be inserted into the parent of the drag item. The advantage is that
898
+ * inherited styles will be preserved, but it may be clipped by `overflow: hidden` or not be
899
+ * visible due to `z-index`. Furthermore, the preview is going to have an effect over selectors
900
+ * like `:nth-child` and some flexbox configurations.
901
+ * - `ElementRef<HTMLElement> | HTMLElement` - Preview will be inserted into a specific element.
902
+ * Same advantages and disadvantages as `parent`.
903
+ */
904
+ type PreviewContainer = 'global' | 'parent' | ElementRef<HTMLElement> | HTMLElement;
905
+ /**
906
+ * Reference to a draggable item. Used to manipulate or dispose of the item.
907
+ */
908
+ declare class DragRef<T = any> {
909
+ private _config;
910
+ private _document;
911
+ private _ngZone;
912
+ private _viewportRuler;
913
+ private _dragDropRegistry;
914
+ private _renderer;
915
+ private _rootElementCleanups;
916
+ private _cleanupShadowRootSelectStart;
917
+ /** Element displayed next to the user's pointer while the element is dragged. */
918
+ private _preview;
919
+ /** Container into which to insert the preview. */
920
+ private _previewContainer;
921
+ /** Reference to the view of the placeholder element. */
922
+ private _placeholderRef;
923
+ /** Element that is rendered instead of the draggable item while it is being sorted. */
924
+ private _placeholder;
925
+ /** Coordinates within the element at which the user picked up the element. */
926
+ private _pickupPositionInElement;
927
+ /** Coordinates on the page at which the user picked up the element. */
928
+ private _pickupPositionOnPage;
1017
929
  /**
1018
- * Figures out the coordinates at which an element was picked up.
1019
- * @param referenceElement Element that initiated the dragging.
1020
- * @param event Event that initiated the dragging.
930
+ * Anchor node used to save the place in the DOM where the element was
931
+ * picked up so that it can be restored at the end of the drag sequence.
1021
932
  */
1022
- private _getPointerPositionInElement;
1023
- /** Determines the point of the page that was touched by the user. */
1024
- private _getPointerPositionOnPage;
1025
- /** Gets the pointer position on the page, accounting for any position constraints. */
1026
- private _getConstrainedPointerPosition;
1027
- /** Updates the current drag delta, based on the user's current pointer position on the page. */
1028
- private _updatePointerDirectionDelta;
1029
- /** Toggles the native drag interactions, based on how many handles are registered. */
1030
- private _toggleNativeDragInteractions;
1031
- /** Removes the manually-added event listeners from the root element. */
1032
- private _removeRootElementListeners;
933
+ private _anchor;
1033
934
  /**
1034
- * Applies a `transform` to the root element, taking into account any existing transforms on it.
1035
- * @param x New transform value along the X axis.
1036
- * @param y New transform value along the Y axis.
935
+ * CSS `transform` applied to the element when it isn't being dragged. We need a
936
+ * passive transform in order for the dragged element to retain its new position
937
+ * after the user has stopped dragging and because we need to know the relative
938
+ * position in case they start dragging again. This corresponds to `element.style.transform`.
1037
939
  */
1038
- private _applyRootElementTransform;
940
+ private _passiveTransform;
941
+ /** CSS `transform` that is applied to the element while it's being dragged. */
942
+ private _activeTransform;
943
+ /** Inline `transform` value that the element had before the first dragging sequence. */
944
+ private _initialTransform?;
1039
945
  /**
1040
- * Applies a `transform` to the preview, taking into account any existing transforms on it.
1041
- * @param x New transform value along the X axis.
1042
- * @param y New transform value along the Y axis.
946
+ * Whether the dragging sequence has been started. Doesn't
947
+ * necessarily mean that the element has been moved.
1043
948
  */
1044
- private _applyPreviewTransform;
949
+ private _hasStartedDragging;
950
+ /** Whether the element has moved since the user started dragging it. */
951
+ private _hasMoved;
952
+ /** Drop container in which the DragRef resided when dragging began. */
953
+ private _initialContainer;
954
+ /** Index at which the item started in its initial container. */
955
+ private _initialIndex;
956
+ /** Cached positions of scrollable parent elements. */
957
+ private _parentPositions;
958
+ /** Emits when the item is being moved. */
959
+ private readonly _moveEvents;
960
+ /** Keeps track of the direction in which the user is dragging along each axis. */
961
+ private _pointerDirectionDelta;
962
+ /** Pointer position at which the last change in the delta occurred. */
963
+ private _pointerPositionAtLastDirectionChange;
964
+ /** Position of the pointer at the last pointer event. */
965
+ private _lastKnownPointerPosition;
1045
966
  /**
1046
- * Gets the distance that the user has dragged during the current drag sequence.
1047
- * @param currentPosition Current position of the user's pointer.
967
+ * Root DOM node of the drag instance. This is the element that will
968
+ * be moved around as the user is dragging.
1048
969
  */
1049
- private _getDragDistance;
1050
- /** Cleans up any cached element dimensions that we don't need after dragging has stopped. */
1051
- private _cleanupCachedDimensions;
970
+ private _rootElement;
1052
971
  /**
1053
- * Checks whether the element is still inside its boundary after the viewport has been resized.
1054
- * If not, the position is adjusted so that the element fits again.
972
+ * Nearest ancestor SVG, relative to which coordinates are calculated if dragging SVGElement
1055
973
  */
1056
- private _containInsideBoundaryOnResize;
1057
- /** Gets the drag start delay, based on the event type. */
1058
- private _getDragStartDelay;
1059
- /** Updates the internal state of the draggable element when scrolling has occurred. */
1060
- private _updateOnScroll;
1061
- /** Gets the scroll position of the viewport. */
1062
- private _getViewportScrollPosition;
974
+ private _ownerSVGElement;
1063
975
  /**
1064
- * Lazily resolves and returns the shadow root of the element. We do this in a function, rather
1065
- * than saving it in property directly on init, because we want to resolve it as late as possible
1066
- * in order to ensure that the element has been moved into the shadow DOM. Doing it inside the
1067
- * constructor might be too early if the element is inside of something like `ngFor` or `ngIf`.
976
+ * Inline style value of `-webkit-tap-highlight-color` at the time the
977
+ * dragging was started. Used to restore the value once we're done dragging.
1068
978
  */
1069
- private _getShadowRoot;
1070
- /** Gets the element into which the drag preview should be inserted. */
1071
- private _getPreviewInsertionPoint;
1072
- /** Lazily resolves and returns the dimensions of the preview. */
1073
- private _getPreviewRect;
1074
- /** Handles a native `dragstart` event. */
1075
- private _nativeDragStart;
1076
- /** Gets a handle that is the target of an event. */
1077
- private _getTargetHandle;
1078
- }
1079
-
1080
- /** Object that can be used to configure the behavior of DragRef. */
1081
- export declare interface DragRefConfig {
979
+ private _rootElementTapHighlight;
980
+ /** Subscription to pointer movement events. */
981
+ private _pointerMoveSubscription;
982
+ /** Subscription to the event that is dispatched when the user lifts their pointer. */
983
+ private _pointerUpSubscription;
984
+ /** Subscription to the viewport being scrolled. */
985
+ private _scrollSubscription;
986
+ /** Subscription to the viewport being resized. */
987
+ private _resizeSubscription;
1082
988
  /**
1083
- * Minimum amount of pixels that the user should
1084
- * drag, before the CDK initiates a drag sequence.
989
+ * Time at which the last touch event occurred. Used to avoid firing the same
990
+ * events multiple times on touch devices where the browser will fire a fake
991
+ * mouse event for each touch event, after a certain time.
1085
992
  */
1086
- dragStartThreshold: number;
993
+ private _lastTouchEventTime;
994
+ /** Time at which the last dragging sequence was started. */
995
+ private _dragStartTime;
996
+ /** Cached reference to the boundary element. */
997
+ private _boundaryElement;
998
+ /** Whether the native dragging interactions have been enabled on the root element. */
999
+ private _nativeInteractionsEnabled;
1000
+ /** Client rect of the root element when the dragging sequence has started. */
1001
+ private _initialDomRect?;
1002
+ /** Cached dimensions of the preview element. Should be read via `_getPreviewRect`. */
1003
+ private _previewRect?;
1004
+ /** Cached dimensions of the boundary element. */
1005
+ private _boundaryRect?;
1006
+ /** Element that will be used as a template to create the draggable item's preview. */
1007
+ private _previewTemplate?;
1008
+ /** Template for placeholder element rendered to show where a draggable would be dropped. */
1009
+ private _placeholderTemplate?;
1010
+ /** Elements that can be used to drag the draggable item. */
1011
+ private _handles;
1012
+ /** Registered handles that are currently disabled. */
1013
+ private _disabledHandles;
1014
+ /** Droppable container that the draggable is a part of. */
1015
+ private _dropContainer?;
1016
+ /** Layout direction of the item. */
1017
+ private _direction;
1018
+ /** Ref that the current drag item is nested in. */
1019
+ private _parentDragRef;
1087
1020
  /**
1088
- * Amount the pixels the user should drag before the CDK
1089
- * considers them to have changed the drag direction.
1021
+ * Cached shadow root that the element is placed in. `null` means that the element isn't in
1022
+ * the shadow DOM and `undefined` means that it hasn't been resolved yet. Should be read via
1023
+ * `_getShadowRoot`, not directly.
1090
1024
  */
1091
- pointerDirectionChangeThreshold: number;
1092
- /** `z-index` for the absolutely-positioned elements that are created by the drag item. */
1093
- zIndex?: number;
1094
- /** Ref that the current drag item is nested in. */
1095
- parentDragRef?: DragRef;
1096
- }
1097
-
1098
- /** Possible values that can be used to configure the drag start delay. */
1099
- export declare type DragStartDelay = number | {
1100
- touch: number;
1101
- mouse: number;
1102
- };
1103
-
1104
- /** Possible orientations for a drop list. */
1105
- export declare type DropListOrientation = 'horizontal' | 'vertical' | 'mixed';
1106
-
1107
- /**
1108
- * Reference to a drop list. Used to manipulate or dispose of the container.
1109
- */
1110
- export declare class DropListRef<T = any> {
1111
- private _dragDropRegistry;
1112
- private _ngZone;
1113
- private _viewportRuler;
1114
- /** Element that the drop list is attached to. */
1115
- element: HTMLElement | ElementRef<HTMLElement>;
1116
- /** Whether starting a dragging sequence from this container is disabled. */
1117
- disabled: boolean;
1118
- /** Whether sorting items within the list is disabled. */
1119
- sortingDisabled: boolean;
1120
- /** Locks the position of the draggable elements inside the container along the specified axis. */
1025
+ private _cachedShadowRoot;
1026
+ /** Axis along which dragging is locked. */
1121
1027
  lockAxis: 'x' | 'y';
1122
1028
  /**
1123
- * Whether auto-scrolling the view when the user
1124
- * moves their pointer close to the edges is disabled.
1029
+ * Amount of milliseconds to wait after the user has put their
1030
+ * pointer down before starting to drag the element.
1125
1031
  */
1126
- autoScrollDisabled: boolean;
1127
- /** Number of pixels to scroll for each frame when auto-scrolling an element. */
1128
- autoScrollStep: number;
1032
+ dragStartDelay: number | {
1033
+ touch: number;
1034
+ mouse: number;
1035
+ };
1036
+ /** Class to be added to the preview element. */
1037
+ previewClass: string | string[] | undefined;
1129
1038
  /**
1130
- * Function that is used to determine whether an item
1131
- * is allowed to be moved into a drop container.
1039
+ * If the parent of the dragged element has a `scale` transform, it can throw off the
1040
+ * positioning when the user starts dragging. Use this input to notify the CDK of the scale.
1132
1041
  */
1133
- enterPredicate: (drag: DragRef, drop: DropListRef) => boolean;
1134
- /** Function that is used to determine whether an item can be sorted into a particular index. */
1135
- sortPredicate: (index: number, drag: DragRef, drop: DropListRef) => boolean;
1136
- /** Emits right before dragging has started. */
1042
+ scale: number;
1043
+ /** Whether starting to drag this element is disabled. */
1044
+ get disabled(): boolean;
1045
+ set disabled(value: boolean);
1046
+ private _disabled;
1047
+ /** Emits as the drag sequence is being prepared. */
1137
1048
  readonly beforeStarted: Subject<void>;
1138
- /**
1139
- * Emits when the user has moved a new drag item into this container.
1140
- */
1049
+ /** Emits when the user starts dragging the item. */
1050
+ readonly started: Subject<{
1051
+ source: DragRef;
1052
+ event: MouseEvent | TouchEvent;
1053
+ }>;
1054
+ /** Emits when the user has released a drag item, before any animations have started. */
1055
+ readonly released: Subject<{
1056
+ source: DragRef;
1057
+ event: MouseEvent | TouchEvent;
1058
+ }>;
1059
+ /** Emits when the user stops dragging an item in the container. */
1060
+ readonly ended: Subject<{
1061
+ source: DragRef;
1062
+ distance: Point;
1063
+ dropPoint: Point;
1064
+ event: MouseEvent | TouchEvent;
1065
+ }>;
1066
+ /** Emits when the user has moved the item into a new container. */
1141
1067
  readonly entered: Subject<{
1142
- item: DragRef;
1143
1068
  container: DropListRef;
1069
+ item: DragRef;
1144
1070
  currentIndex: number;
1145
1071
  }>;
1146
- /**
1147
- * Emits when the user removes an item from the container
1148
- * by dragging it into another container.
1149
- */
1072
+ /** Emits when the user removes the item its container by dragging it into another container. */
1150
1073
  readonly exited: Subject<{
1151
- item: DragRef;
1152
1074
  container: DropListRef;
1075
+ item: DragRef;
1153
1076
  }>;
1154
- /** Emits when the user drops an item inside the container. */
1077
+ /** Emits when the user drops the item inside a container. */
1155
1078
  readonly dropped: Subject<{
1156
- item: DragRef;
1157
- currentIndex: number;
1158
1079
  previousIndex: number;
1080
+ currentIndex: number;
1081
+ item: DragRef;
1159
1082
  container: DropListRef;
1160
1083
  previousContainer: DropListRef;
1161
- isPointerOverContainer: boolean;
1162
1084
  distance: Point;
1163
1085
  dropPoint: Point;
1086
+ isPointerOverContainer: boolean;
1164
1087
  event: MouseEvent | TouchEvent;
1165
1088
  }>;
1166
- /** Emits as the user is swapping items while actively dragging. */
1167
- readonly sorted: Subject<{
1168
- previousIndex: number;
1169
- currentIndex: number;
1170
- container: DropListRef;
1171
- item: DragRef;
1172
- }>;
1173
- /** Emits when a dragging sequence is started in a list connected to the current one. */
1174
- readonly receivingStarted: Subject<{
1175
- receiver: DropListRef;
1176
- initiator: DropListRef;
1177
- items: DragRef[];
1178
- }>;
1179
- /** Emits when a dragging sequence is stopped from a list connected to the current one. */
1180
- readonly receivingStopped: Subject<{
1181
- receiver: DropListRef;
1182
- initiator: DropListRef;
1089
+ /**
1090
+ * Emits as the user is dragging the item. Use with caution,
1091
+ * because this event will fire for every pixel that the user has dragged.
1092
+ */
1093
+ readonly moved: Observable<{
1094
+ source: DragRef;
1095
+ pointerPosition: {
1096
+ x: number;
1097
+ y: number;
1098
+ };
1099
+ event: MouseEvent | TouchEvent;
1100
+ distance: Point;
1101
+ delta: {
1102
+ x: -1 | 0 | 1;
1103
+ y: -1 | 0 | 1;
1104
+ };
1183
1105
  }>;
1184
- /** Arbitrary data that can be attached to the drop list. */
1106
+ /** Arbitrary data that can be attached to the drag item. */
1185
1107
  data: T;
1186
- /** Element that is the direct parent of the drag items. */
1187
- private _container;
1188
- /** Whether an item in the list is being dragged. */
1189
- private _isDragging;
1190
- /** Keeps track of the positions of any parent scrollable elements. */
1191
- private _parentPositions;
1192
- /** Strategy being used to sort items within the list. */
1193
- private _sortStrategy;
1194
- /** Cached `DOMRect` of the drop list. */
1195
- private _domRect;
1196
- /** Draggable items in the container. */
1197
- private _draggables;
1198
- /** Drop lists that are connected to the current one. */
1199
- private _siblings;
1200
- /** Connected siblings that currently have a dragged item. */
1201
- private _activeSiblings;
1202
- /** Subscription to the window being scrolled. */
1203
- private _viewportScrollSubscription;
1204
- /** Vertical direction in which the list is currently scrolling. */
1205
- private _verticalScrollDirection;
1206
- /** Horizontal direction in which the list is currently scrolling. */
1207
- private _horizontalScrollDirection;
1208
- /** Node that is being auto-scrolled. */
1209
- private _scrollNode;
1210
- /** Used to signal to the current auto-scroll sequence when to stop. */
1211
- private readonly _stopScrollTimers;
1212
- /** Shadow root of the current element. Necessary for `elementFromPoint` to resolve correctly. */
1213
- private _cachedShadowRoot;
1214
- /** Reference to the document. */
1215
- private _document;
1216
- /** Elements that can be scrolled while the user is dragging. */
1217
- private _scrollableElements;
1218
- /** Initial value for the element's `scroll-snap-type` style. */
1219
- private _initialScrollSnap;
1220
- /** Direction of the list's layout. */
1221
- private _direction;
1222
- constructor(element: ElementRef<HTMLElement> | HTMLElement, _dragDropRegistry: DragDropRegistry, _document: any, _ngZone: NgZone, _viewportRuler: ViewportRuler);
1223
- /** Removes the drop list functionality from the DOM element. */
1224
- dispose(): void;
1225
- /** Whether an item from this list is currently being dragged. */
1226
- isDragging(): boolean;
1227
- /** Starts dragging an item. */
1228
- start(): void;
1229
1108
  /**
1230
- * Attempts to move an item into the container.
1231
- * @param item Item that was moved into the container.
1232
- * @param pointerX Position of the item along the X axis.
1233
- * @param pointerY Position of the item along the Y axis.
1234
- * @param index Index at which the item entered. If omitted, the container will try to figure it
1235
- * out automatically.
1109
+ * Function that can be used to customize the logic of how the position of the drag item
1110
+ * is limited while it's being dragged. Gets called with a point containing the current position
1111
+ * of the user's pointer on the page, a reference to the item being dragged and its dimensions.
1112
+ * Should return a point describing where the item should be rendered.
1236
1113
  */
1237
- enter(item: DragRef, pointerX: number, pointerY: number, index?: number): void;
1114
+ constrainPosition?: DragConstrainPosition;
1115
+ constructor(element: ElementRef<HTMLElement> | HTMLElement, _config: DragRefConfig, _document: Document, _ngZone: NgZone, _viewportRuler: ViewportRuler, _dragDropRegistry: DragDropRegistry, _renderer: Renderer2);
1238
1116
  /**
1239
- * Removes an item from the container after it was dragged into another container by the user.
1240
- * @param item Item that was dragged out.
1117
+ * Returns the element that is being used as a placeholder
1118
+ * while the current element is being dragged.
1241
1119
  */
1242
- exit(item: DragRef): void;
1120
+ getPlaceholderElement(): HTMLElement;
1121
+ /** Returns the root draggable element. */
1122
+ getRootElement(): HTMLElement;
1243
1123
  /**
1244
- * Drops an item into this container.
1245
- * @param item Item being dropped into the container.
1246
- * @param currentIndex Index at which the item should be inserted.
1247
- * @param previousIndex Index of the item when dragging started.
1248
- * @param previousContainer Container from which the item got dragged in.
1249
- * @param isPointerOverContainer Whether the user's pointer was over the
1250
- * container when the item was dropped.
1251
- * @param distance Distance the user has dragged since the start of the dragging sequence.
1252
- * @param event Event that triggered the dropping sequence.
1253
- *
1254
- * @breaking-change 15.0.0 `previousIndex` and `event` parameters to become required.
1124
+ * Gets the currently-visible element that represents the drag item.
1125
+ * While dragging this is the placeholder, otherwise it's the root element.
1255
1126
  */
1256
- drop(item: DragRef, currentIndex: number, previousIndex: number, previousContainer: DropListRef, isPointerOverContainer: boolean, distance: Point, dropPoint: Point, event?: MouseEvent | TouchEvent): void;
1127
+ getVisibleElement(): HTMLElement;
1128
+ /** Registers the handles that can be used to drag the element. */
1129
+ withHandles(handles: (HTMLElement | ElementRef<HTMLElement>)[]): this;
1257
1130
  /**
1258
- * Sets the draggable items that are a part of this list.
1259
- * @param items Items that are a part of this list.
1131
+ * Registers the template that should be used for the drag preview.
1132
+ * @param template Template that from which to stamp out the preview.
1260
1133
  */
1261
- withItems(items: DragRef[]): this;
1262
- /** Sets the layout direction of the drop list. */
1263
- withDirection(direction: Direction): this;
1134
+ withPreviewTemplate(template: DragPreviewTemplate | null): this;
1264
1135
  /**
1265
- * Sets the containers that are connected to this one. When two or more containers are
1266
- * connected, the user will be allowed to transfer items between them.
1267
- * @param connectedTo Other containers that the current containers should be connected to.
1136
+ * Registers the template that should be used for the drag placeholder.
1137
+ * @param template Template that from which to stamp out the placeholder.
1138
+ */
1139
+ withPlaceholderTemplate(template: DragHelperTemplate | null): this;
1140
+ /**
1141
+ * Sets an alternate drag root element. The root element is the element that will be moved as
1142
+ * the user is dragging. Passing an alternate root element is useful when trying to enable
1143
+ * dragging on an element that you might not have access to.
1144
+ */
1145
+ withRootElement(rootElement: ElementRef<HTMLElement> | HTMLElement): this;
1146
+ /**
1147
+ * Element to which the draggable's position will be constrained.
1148
+ */
1149
+ withBoundaryElement(boundaryElement: ElementRef<HTMLElement> | HTMLElement | null): this;
1150
+ /** Sets the parent ref that the ref is nested in. */
1151
+ withParent(parent: DragRef<unknown> | null): this;
1152
+ /** Removes the dragging functionality from the DOM element. */
1153
+ dispose(): void;
1154
+ /** Checks whether the element is currently being dragged. */
1155
+ isDragging(): boolean;
1156
+ /** Resets a standalone drag item to its initial position. */
1157
+ reset(): void;
1158
+ /** Resets drag item to end of boundary element. */
1159
+ resetToBoundary(): void;
1160
+ /**
1161
+ * Sets a handle as disabled. While a handle is disabled, it'll capture and interrupt dragging.
1162
+ * @param handle Handle element that should be disabled.
1268
1163
  */
1269
- connectedTo(connectedTo: DropListRef[]): this;
1164
+ disableHandle(handle: HTMLElement): void;
1270
1165
  /**
1271
- * Sets the orientation of the container.
1272
- * @param orientation New orientation for the container.
1166
+ * Enables a handle, if it has been disabled.
1167
+ * @param handle Handle element to be enabled.
1273
1168
  */
1274
- withOrientation(orientation: DropListOrientation): this;
1169
+ enableHandle(handle: HTMLElement): void;
1170
+ /** Sets the layout direction of the draggable item. */
1171
+ withDirection(direction: Direction): this;
1172
+ /** Sets the container that the item is part of. */
1173
+ _withDropContainer(container: DropListRef): void;
1275
1174
  /**
1276
- * Sets which parent elements are can be scrolled while the user is dragging.
1277
- * @param elements Elements that can be scrolled.
1175
+ * Gets the current position in pixels the draggable outside of a drop container.
1278
1176
  */
1279
- withScrollableParents(elements: HTMLElement[]): this;
1177
+ getFreeDragPosition(): Readonly<Point>;
1280
1178
  /**
1281
- * Configures the drop list so that a different element is used as the container for the
1282
- * dragged items. This is useful for the cases when one might not have control over the
1283
- * full DOM that sets up the dragging.
1284
- * Note that the alternate container needs to be a descendant of the drop list.
1285
- * @param container New element container to be assigned.
1179
+ * Sets the current position in pixels the draggable outside of a drop container.
1180
+ * @param value New position to be set.
1286
1181
  */
1287
- withElementContainer(container: HTMLElement): this;
1288
- /** Gets the scrollable parents that are registered with this drop container. */
1289
- getScrollableParents(): readonly HTMLElement[];
1182
+ setFreeDragPosition(value: Point): this;
1290
1183
  /**
1291
- * Figures out the index of an item in the container.
1292
- * @param item Item whose index should be determined.
1184
+ * Sets the container into which to insert the preview element.
1185
+ * @param value Container into which to insert the preview.
1293
1186
  */
1294
- getItemIndex(item: DragRef): number;
1187
+ withPreviewContainer(value: PreviewContainer): this;
1188
+ /** Updates the item's sort order based on the last-known pointer position. */
1189
+ _sortFromLastPointerPosition(): void;
1190
+ /** Unsubscribes from the global subscriptions. */
1191
+ private _removeListeners;
1192
+ /** Destroys the preview element and its ViewRef. */
1193
+ private _destroyPreview;
1194
+ /** Destroys the placeholder element and its ViewRef. */
1195
+ private _destroyPlaceholder;
1196
+ /** Handler for the `mousedown`/`touchstart` events. */
1197
+ private _pointerDown;
1198
+ /** Handler that is invoked when the user moves their pointer after they've initiated a drag. */
1199
+ private _pointerMove;
1200
+ /** Handler that is invoked when the user lifts their pointer up, after initiating a drag. */
1201
+ private _pointerUp;
1295
1202
  /**
1296
- * Whether the list is able to receive the item that
1297
- * is currently being dragged inside a connected drop list.
1203
+ * Clears subscriptions and stops the dragging sequence.
1204
+ * @param event Browser event object that ended the sequence.
1298
1205
  */
1299
- isReceiving(): boolean;
1206
+ private _endDragSequence;
1207
+ /** Starts the dragging sequence. */
1208
+ private _startDragSequence;
1300
1209
  /**
1301
- * Sorts an item inside the container based on its position.
1302
- * @param item Item to be sorted.
1303
- * @param pointerX Position of the item along the X axis.
1304
- * @param pointerY Position of the item along the Y axis.
1305
- * @param pointerDelta Direction in which the pointer is moving along each axis.
1210
+ * Sets up the different variables and subscriptions
1211
+ * that will be necessary for the dragging sequence.
1212
+ * @param referenceElement Element that started the drag sequence.
1213
+ * @param event Browser event object that started the sequence.
1306
1214
  */
1307
- _sortItem(item: DragRef, pointerX: number, pointerY: number, pointerDelta: {
1308
- x: number;
1309
- y: number;
1310
- }): void;
1215
+ private _initializeDragSequence;
1216
+ /** Cleans up the DOM artifacts that were added to facilitate the element being dragged. */
1217
+ private _cleanupDragArtifacts;
1311
1218
  /**
1312
- * Checks whether the user's pointer is close to the edges of either the
1313
- * viewport or the drop list and starts the auto-scroll sequence.
1314
- * @param pointerX User's pointer position along the x axis.
1315
- * @param pointerY User's pointer position along the y axis.
1219
+ * Updates the item's position in its drop container, or moves it
1220
+ * into a new one, depending on its current drag position.
1316
1221
  */
1317
- _startScrollingIfNecessary(pointerX: number, pointerY: number): void;
1318
- /** Stops any currently-running auto-scroll sequences. */
1319
- _stopScrolling(): void;
1320
- /** Starts the dragging sequence within the list. */
1321
- private _draggingStarted;
1322
- /** Caches the positions of the configured scrollable parents. */
1323
- private _cacheParentPositions;
1324
- /** Resets the container to its initial state. */
1325
- private _reset;
1326
- /** Starts the interval that'll auto-scroll the element. */
1327
- private _startScrollInterval;
1222
+ private _updateActiveDropContainer;
1328
1223
  /**
1329
- * Checks whether the user's pointer is positioned over the container.
1330
- * @param x Pointer position along the X axis.
1331
- * @param y Pointer position along the Y axis.
1224
+ * Animates the preview element from its current position to the location of the drop placeholder.
1225
+ * @returns Promise that resolves when the animation completes.
1332
1226
  */
1333
- _isOverContainer(x: number, y: number): boolean;
1227
+ private _animatePreviewToPlaceholder;
1228
+ /** Creates an element that will be shown instead of the current element while dragging. */
1229
+ private _createPlaceholderElement;
1334
1230
  /**
1335
- * Figures out whether an item should be moved into a sibling
1336
- * drop container, based on its current position.
1337
- * @param item Drag item that is being moved.
1338
- * @param x Position of the item along the X axis.
1339
- * @param y Position of the item along the Y axis.
1231
+ * Figures out the coordinates at which an element was picked up.
1232
+ * @param referenceElement Element that initiated the dragging.
1233
+ * @param event Event that initiated the dragging.
1340
1234
  */
1341
- _getSiblingContainerFromPosition(item: DragRef, x: number, y: number): DropListRef | undefined;
1235
+ private _getPointerPositionInElement;
1236
+ /** Determines the point of the page that was touched by the user. */
1237
+ private _getPointerPositionOnPage;
1238
+ /** Gets the pointer position on the page, accounting for any position constraints. */
1239
+ private _getConstrainedPointerPosition;
1240
+ /** Updates the current drag delta, based on the user's current pointer position on the page. */
1241
+ private _updatePointerDirectionDelta;
1242
+ /** Toggles the native drag interactions, based on how many handles are registered. */
1243
+ private _toggleNativeDragInteractions;
1244
+ /** Removes the manually-added event listeners from the root element. */
1245
+ private _removeRootElementListeners;
1342
1246
  /**
1343
- * Checks whether the drop list can receive the passed-in item.
1344
- * @param item Item that is being dragged into the list.
1345
- * @param x Position of the item along the X axis.
1346
- * @param y Position of the item along the Y axis.
1247
+ * Applies a `transform` to the root element, taking into account any existing transforms on it.
1248
+ * @param x New transform value along the X axis.
1249
+ * @param y New transform value along the Y axis.
1347
1250
  */
1348
- _canReceive(item: DragRef, x: number, y: number): boolean;
1251
+ private _applyRootElementTransform;
1349
1252
  /**
1350
- * Called by one of the connected drop lists when a dragging sequence has started.
1351
- * @param sibling Sibling in which dragging has started.
1253
+ * Applies a `transform` to the preview, taking into account any existing transforms on it.
1254
+ * @param x New transform value along the X axis.
1255
+ * @param y New transform value along the Y axis.
1352
1256
  */
1353
- _startReceiving(sibling: DropListRef, items: DragRef[]): void;
1257
+ private _applyPreviewTransform;
1354
1258
  /**
1355
- * Called by a connected drop list when dragging has stopped.
1356
- * @param sibling Sibling whose dragging has stopped.
1259
+ * Gets the distance that the user has dragged during the current drag sequence.
1260
+ * @param currentPosition Current position of the user's pointer.
1357
1261
  */
1358
- _stopReceiving(sibling: DropListRef): void;
1262
+ private _getDragDistance;
1263
+ /** Cleans up any cached element dimensions that we don't need after dragging has stopped. */
1264
+ private _cleanupCachedDimensions;
1359
1265
  /**
1360
- * Starts listening to scroll events on the viewport.
1361
- * Used for updating the internal state of the list.
1266
+ * Checks whether the element is still inside its boundary after the viewport has been resized.
1267
+ * If not, the position is adjusted so that the element fits again.
1362
1268
  */
1363
- private _listenToScrollEvents;
1269
+ private _containInsideBoundaryOnResize;
1270
+ /** Gets the drag start delay, based on the event type. */
1271
+ private _getDragStartDelay;
1272
+ /** Updates the internal state of the draggable element when scrolling has occurred. */
1273
+ private _updateOnScroll;
1274
+ /** Gets the scroll position of the viewport. */
1275
+ private _getViewportScrollPosition;
1364
1276
  /**
1365
1277
  * Lazily resolves and returns the shadow root of the element. We do this in a function, rather
1366
1278
  * than saving it in property directly on init, because we want to resolve it as late as possible
@@ -1368,51 +1280,48 @@ export declare class DropListRef<T = any> {
1368
1280
  * constructor might be too early if the element is inside of something like `ngFor` or `ngIf`.
1369
1281
  */
1370
1282
  private _getShadowRoot;
1371
- /** Notifies any siblings that may potentially receive the item. */
1372
- private _notifyReceivingSiblings;
1373
- }
1374
-
1375
- declare namespace i1 {
1376
- export {
1377
- CdkDropList
1378
- }
1379
- }
1380
-
1381
- declare namespace i2 {
1382
- export {
1383
- CDK_DROP_LIST_GROUP,
1384
- CdkDropListGroup
1385
- }
1386
- }
1387
-
1388
- declare namespace i3 {
1389
- export {
1390
- CDK_DROP_LIST,
1391
- CdkDrag
1392
- }
1393
- }
1394
-
1395
- declare namespace i4 {
1396
- export {
1397
- CDK_DRAG_HANDLE,
1398
- CdkDragHandle
1399
- }
1400
- }
1401
-
1402
- declare namespace i5 {
1403
- export {
1404
- CDK_DRAG_PREVIEW,
1405
- CdkDragPreview
1406
- }
1283
+ /** Gets the element into which the drag preview should be inserted. */
1284
+ private _getPreviewInsertionPoint;
1285
+ /** Lazily resolves and returns the dimensions of the preview. */
1286
+ private _getPreviewRect;
1287
+ /** Handles a native `dragstart` event. */
1288
+ private _nativeDragStart;
1289
+ /** Gets a handle that is the target of an event. */
1290
+ private _getTargetHandle;
1407
1291
  }
1408
1292
 
1409
- declare namespace i6 {
1410
- export {
1411
- CDK_DRAG_PLACEHOLDER,
1412
- CdkDragPlaceholder
1413
- }
1293
+ /**
1294
+ * Service that allows for drag-and-drop functionality to be attached to DOM elements.
1295
+ */
1296
+ declare class DragDrop {
1297
+ private _document;
1298
+ private _ngZone;
1299
+ private _viewportRuler;
1300
+ private _dragDropRegistry;
1301
+ private _renderer;
1302
+ constructor(...args: unknown[]);
1303
+ /**
1304
+ * Turns an element into a draggable item.
1305
+ * @param element Element to which to attach the dragging functionality.
1306
+ * @param config Object used to configure the dragging behavior.
1307
+ */
1308
+ createDrag<T = any>(element: ElementRef<HTMLElement> | HTMLElement, config?: DragRefConfig): DragRef<T>;
1309
+ /**
1310
+ * Turns an element into a drop list.
1311
+ * @param element Element to which to attach the drop list functionality.
1312
+ */
1313
+ createDropList<T = any>(element: ElementRef<HTMLElement> | HTMLElement): DropListRef<T>;
1314
+ static ɵfac: i0.ɵɵFactoryDeclaration<DragDrop, never>;
1315
+ static ɵprov: i0.ɵɵInjectableDeclaration<DragDrop>;
1414
1316
  }
1415
1317
 
1318
+ /**
1319
+ * Injection token that can be used for a `CdkDrag` to provide itself as a parent to the
1320
+ * drag-specific child directive (`CdkDragHandle`, `CdkDragPreview` etc.). Used primarily
1321
+ * to avoid circular imports.
1322
+ * @docs-private
1323
+ */
1324
+ declare const CDK_DRAG_PARENT: InjectionToken<CdkDrag<any>>;
1416
1325
 
1417
1326
  /**
1418
1327
  * Moves an item one index in an array to another.
@@ -1420,28 +1329,7 @@ declare namespace i6 {
1420
1329
  * @param fromIndex Starting index of the item.
1421
1330
  * @param toIndex Index to which the item should be moved.
1422
1331
  */
1423
- export declare function moveItemInArray<T = any>(array: T[], fromIndex: number, toIndex: number): void;
1424
-
1425
- /** Point on the page or within an element. */
1426
- export declare interface Point {
1427
- x: number;
1428
- y: number;
1429
- }
1430
-
1431
- /**
1432
- * Possible places into which the preview of a drag item can be inserted.
1433
- * - `global` - Preview will be inserted at the bottom of the `<body>`. The advantage is that
1434
- * you don't have to worry about `overflow: hidden` or `z-index`, but the item won't retain
1435
- * its inherited styles.
1436
- * - `parent` - Preview will be inserted into the parent of the drag item. The advantage is that
1437
- * inherited styles will be preserved, but it may be clipped by `overflow: hidden` or not be
1438
- * visible due to `z-index`. Furthermore, the preview is going to have an effect over selectors
1439
- * like `:nth-child` and some flexbox configurations.
1440
- * - `ElementRef<HTMLElement> | HTMLElement` - Preview will be inserted into a specific element.
1441
- * Same advantages and disadvantages as `parent`.
1442
- */
1443
- export declare type PreviewContainer = 'global' | 'parent' | ElementRef<HTMLElement> | HTMLElement;
1444
-
1332
+ declare function moveItemInArray<T = any>(array: T[], fromIndex: number, toIndex: number): void;
1445
1333
  /**
1446
1334
  * Moves an item from one array to another.
1447
1335
  * @param currentArray Array from which to transfer the item.
@@ -1449,6 +1337,46 @@ export declare type PreviewContainer = 'global' | 'parent' | ElementRef<HTMLElem
1449
1337
  * @param currentIndex Index of the item in its current array.
1450
1338
  * @param targetIndex Index at which to insert the item.
1451
1339
  */
1452
- export declare function transferArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
1340
+ declare function transferArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
1341
+ /**
1342
+ * Copies an item from one array to another, leaving it in its
1343
+ * original position in current array.
1344
+ * @param currentArray Array from which to copy the item.
1345
+ * @param targetArray Array into which is copy the item.
1346
+ * @param currentIndex Index of the item in its current array.
1347
+ * @param targetIndex Index at which to insert the item.
1348
+ *
1349
+ */
1350
+ declare function copyArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
1351
+
1352
+ /**
1353
+ * Injection token that can be used to reference instances of `CdkDropListGroup`. It serves as
1354
+ * alternative token to the actual `CdkDropListGroup` class which could cause unnecessary
1355
+ * retention of the class and its directive metadata.
1356
+ */
1357
+ declare const CDK_DROP_LIST_GROUP: InjectionToken<CdkDropListGroup<unknown>>;
1358
+ /**
1359
+ * Declaratively connects sibling `cdkDropList` instances together. All of the `cdkDropList`
1360
+ * elements that are placed inside a `cdkDropListGroup` will be connected to each other
1361
+ * automatically. Can be used as an alternative to the `cdkDropListConnectedTo` input
1362
+ * from `cdkDropList`.
1363
+ */
1364
+ declare class CdkDropListGroup<T> implements OnDestroy {
1365
+ /** Drop lists registered inside the group. */
1366
+ readonly _items: Set<T>;
1367
+ /** Whether starting a dragging sequence from inside this group is disabled. */
1368
+ disabled: boolean;
1369
+ ngOnDestroy(): void;
1370
+ static ɵfac: i0.ɵɵFactoryDeclaration<CdkDropListGroup<any>, never>;
1371
+ static ɵdir: i0.ɵɵDirectiveDeclaration<CdkDropListGroup<any>, "[cdkDropListGroup]", ["cdkDropListGroup"], { "disabled": { "alias": "cdkDropListGroupDisabled"; "required": false; }; }, {}, never, never, true, never>;
1372
+ static ngAcceptInputType_disabled: unknown;
1373
+ }
1374
+
1375
+ declare class DragDropModule {
1376
+ static ɵfac: i0.ɵɵFactoryDeclaration<DragDropModule, never>;
1377
+ static ɵmod: i0.ɵɵNgModuleDeclaration<DragDropModule, never, [typeof CdkDropList, typeof CdkDropListGroup, typeof CdkDrag, typeof CdkDragHandle, typeof CdkDragPreview, typeof CdkDragPlaceholder], [typeof CdkScrollableModule, typeof CdkDropList, typeof CdkDropListGroup, typeof CdkDrag, typeof CdkDragHandle, typeof CdkDragPreview, typeof CdkDragPlaceholder]>;
1378
+ static ɵinj: i0.ɵɵInjectorDeclaration<DragDropModule>;
1379
+ }
1453
1380
 
1454
- export { }
1381
+ export { CDK_DRAG_CONFIG, CDK_DRAG_HANDLE, CDK_DRAG_PARENT, CDK_DRAG_PLACEHOLDER, CDK_DRAG_PREVIEW, CDK_DROP_LIST, CDK_DROP_LIST_GROUP, CdkDrag, CdkDragHandle, CdkDragPlaceholder, CdkDragPreview, CdkDropList, CdkDropListGroup, DragDrop, DragDropModule, DragDropRegistry, DragRef, DropListRef, copyArrayItem, moveItemInArray, transferArrayItem };
1382
+ export type { CdkDragDrop, CdkDragEnd, CdkDragEnter, CdkDragExit, CdkDragMove, CdkDragRelease, CdkDragSortEvent, CdkDragStart, DragAxis, DragConstrainPosition, DragDropConfig, DragRefConfig, DragStartDelay, DropListOrientation, Point, PreviewContainer };