@league-of-foundry-developers/foundry-vtt-types 12.331.3-beta → 12.331.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (559) hide show
  1. package/README.md +17 -18
  2. package/package.json +91 -32
  3. package/src/configuration/configuration.d.mts +316 -0
  4. package/src/configuration/documents.d.mts +295 -0
  5. package/src/configuration/globals.d.mts +357 -0
  6. package/src/configuration/index.d.mts +5 -0
  7. package/src/foundry/client/apps/app.d.mts +129 -122
  8. package/src/foundry/client/apps/av/av-config.d.mts +12 -7
  9. package/src/foundry/client/apps/av/cameras.d.mts +12 -7
  10. package/src/foundry/client/apps/dice/dice-config.d.mts +59 -0
  11. package/src/foundry/client/apps/dice/index.d.mts +1 -0
  12. package/src/foundry/client/apps/form.d.mts +114 -86
  13. package/src/foundry/client/apps/forms/actor.d.mts +21 -11
  14. package/src/foundry/client/apps/forms/adventure-exporter.d.mts +12 -7
  15. package/src/foundry/client/apps/forms/adventure-importer.d.mts +14 -6
  16. package/src/foundry/client/apps/forms/base-sheet.d.mts +16 -8
  17. package/src/foundry/client/apps/forms/card-config.d.mts +16 -8
  18. package/src/foundry/client/apps/forms/cards-config.d.mts +15 -14
  19. package/src/foundry/client/apps/forms/combat-config.d.mts +7 -7
  20. package/src/foundry/client/apps/forms/combatant-config.d.mts +3 -3
  21. package/src/foundry/client/apps/forms/default-sheets-config.d.mts +1 -1
  22. package/src/foundry/client/apps/forms/effect-config.d.mts +7 -7
  23. package/src/foundry/client/apps/forms/folder-config.d.mts +10 -5
  24. package/src/foundry/client/apps/forms/fonts.d.mts +42 -35
  25. package/src/foundry/client/apps/forms/grid-config.d.mts +12 -13
  26. package/src/foundry/client/apps/forms/image-popout.d.mts +29 -23
  27. package/src/foundry/client/apps/forms/item.d.mts +9 -9
  28. package/src/foundry/client/apps/forms/journal-page-sheet.d.mts +16 -14
  29. package/src/foundry/client/apps/forms/journal-sheet.d.mts +48 -38
  30. package/src/foundry/client/apps/forms/macro-config.d.mts +7 -7
  31. package/src/foundry/client/apps/forms/measure-template.d.mts +10 -12
  32. package/src/foundry/client/apps/forms/ownership.d.mts +5 -5
  33. package/src/foundry/client/apps/forms/playlist-config.d.mts +8 -10
  34. package/src/foundry/client/apps/forms/playlist-sound-config.d.mts +7 -7
  35. package/src/foundry/client/apps/forms/roll-table-config.d.mts +11 -10
  36. package/src/foundry/client/apps/forms/scene-config.d.mts +40 -41
  37. package/src/foundry/client/apps/forms/sheet-config.d.mts +9 -21
  38. package/src/foundry/client/apps/forms/user-config.d.mts +13 -12
  39. package/src/foundry/client/apps/hud/chatbubble.d.mts +18 -6
  40. package/src/foundry/client/apps/hud/container.d.mts +4 -4
  41. package/src/foundry/client/apps/hud/controls.d.mts +126 -81
  42. package/src/foundry/client/apps/hud/hotbar.d.mts +17 -12
  43. package/src/foundry/client/apps/hud/hud.d.mts +5 -5
  44. package/src/foundry/client/apps/hud/menu.d.mts +10 -3
  45. package/src/foundry/client/apps/hud/navigation.d.mts +14 -9
  46. package/src/foundry/client/apps/hud/pause.d.mts +9 -4
  47. package/src/foundry/client/apps/hud/players.d.mts +14 -9
  48. package/src/foundry/client/apps/i18n.d.mts +31 -27
  49. package/src/foundry/client/apps/index.d.mts +1 -0
  50. package/src/foundry/client/apps/placeables/drawing-config.d.mts +41 -33
  51. package/src/foundry/client/apps/placeables/drawing-hud.d.mts +5 -5
  52. package/src/foundry/client/apps/placeables/index.d.mts +0 -2
  53. package/src/foundry/client/apps/placeables/note-config.d.mts +28 -18
  54. package/src/foundry/client/apps/placeables/tile-config.d.mts +23 -10
  55. package/src/foundry/client/apps/placeables/tile-hud.d.mts +10 -5
  56. package/src/foundry/client/apps/placeables/token-config.d.mts +91 -58
  57. package/src/foundry/client/apps/placeables/token-hud.d.mts +12 -7
  58. package/src/foundry/client/apps/placeables/wall-config.d.mts +21 -17
  59. package/src/foundry/client/apps/sidebar/apps/chat-popout.d.mts +5 -5
  60. package/src/foundry/client/apps/sidebar/apps/client-settings.d.mts +3 -3
  61. package/src/foundry/client/apps/sidebar/apps/compendium.d.mts +15 -13
  62. package/src/foundry/client/apps/sidebar/apps/invitation-links.d.mts +3 -3
  63. package/src/foundry/client/apps/sidebar/apps/keybindings-config.d.mts +3 -2
  64. package/src/foundry/client/apps/sidebar/apps/module-management.d.mts +6 -6
  65. package/src/foundry/client/apps/sidebar/apps/permission-config.d.mts +6 -6
  66. package/src/foundry/client/apps/sidebar/apps/support-details.d.mts +34 -29
  67. package/src/foundry/client/apps/sidebar/apps/tours-management.d.mts +2 -2
  68. package/src/foundry/client/apps/sidebar/apps/world-config.d.mts +13 -10
  69. package/src/foundry/client/apps/sidebar/directory-tab-mixin.d.mts +50 -35
  70. package/src/foundry/client/apps/sidebar/document-directory.d.mts +52 -38
  71. package/src/foundry/client/apps/sidebar/package-configuration.d.mts +4 -4
  72. package/src/foundry/client/apps/sidebar/sidebar-tab.d.mts +3 -3
  73. package/src/foundry/client/apps/sidebar/sidebar.d.mts +9 -4
  74. package/src/foundry/client/apps/sidebar/tabs/actors-directory.d.mts +11 -2
  75. package/src/foundry/client/apps/sidebar/tabs/cards-directory.d.mts +11 -2
  76. package/src/foundry/client/apps/sidebar/tabs/chat-log.d.mts +39 -27
  77. package/src/foundry/client/apps/sidebar/tabs/combat-tracker.d.mts +21 -12
  78. package/src/foundry/client/apps/sidebar/tabs/compendium-directory.d.mts +30 -15
  79. package/src/foundry/client/apps/sidebar/tabs/items-directory.d.mts +11 -2
  80. package/src/foundry/client/apps/sidebar/tabs/journal-directory.d.mts +11 -2
  81. package/src/foundry/client/apps/sidebar/tabs/macros-directory.d.mts +14 -5
  82. package/src/foundry/client/apps/sidebar/tabs/playlists-directory.d.mts +30 -22
  83. package/src/foundry/client/apps/sidebar/tabs/roll-table-directory.d.mts +11 -2
  84. package/src/foundry/client/apps/sidebar/tabs/scenes-directory.d.mts +14 -5
  85. package/src/foundry/client/apps/sidebar/tabs/settings.d.mts +23 -5
  86. package/src/foundry/client/apps/templates.d.mts +1 -1
  87. package/src/foundry/client/av/client.d.mts +1 -1
  88. package/src/foundry/client/av/clients/simplepeer.d.mts +11 -1
  89. package/src/foundry/client/av/master.d.mts +2 -2
  90. package/src/foundry/client/av/settings.d.mts +17 -15
  91. package/src/foundry/client/config.d.mts +444 -312
  92. package/src/foundry/client/core/document-index.d.mts +11 -3
  93. package/src/foundry/client/core/hooks.d.mts +2 -4
  94. package/src/foundry/client/core/image.d.mts +14 -13
  95. package/src/foundry/client/core/issues.d.mts +9 -4
  96. package/src/foundry/client/core/keybindings.d.mts +5 -5
  97. package/src/foundry/client/core/nue.d.mts +1 -1
  98. package/src/foundry/client/core/packages.d.mts +400 -62
  99. package/src/foundry/client/core/settings.d.mts +62 -38
  100. package/src/foundry/client/core/socket.d.mts +2 -2
  101. package/src/foundry/client/core/sorting.d.mts +6 -6
  102. package/src/foundry/client/core/time.d.mts +6 -3
  103. package/src/foundry/client/core/tooltip.d.mts +2 -2
  104. package/src/foundry/client/core/tour.d.mts +59 -50
  105. package/src/foundry/client/core/tours.d.mts +1 -1
  106. package/src/foundry/client/core/utils.d.mts +33 -10
  107. package/src/foundry/client/core/video.d.mts +1 -1
  108. package/src/foundry/client/core/workers.d.mts +24 -17
  109. package/src/foundry/client/data/abstract/canvas-document.d.mts +22 -28
  110. package/src/foundry/client/data/abstract/client-document.d.mts +238 -206
  111. package/src/foundry/client/data/abstract/directory-collection-mixin.d.mts +24 -40
  112. package/src/foundry/client/data/abstract/document-collection.d.mts +96 -68
  113. package/src/foundry/client/data/abstract/world-collection.d.mts +53 -54
  114. package/src/foundry/client/data/collections/actors.d.mts +30 -28
  115. package/src/foundry/client/data/collections/cards.d.mts +16 -3
  116. package/src/foundry/client/data/collections/combats.d.mts +18 -5
  117. package/src/foundry/client/data/collections/compendium-collection.d.mts +84 -101
  118. package/src/foundry/client/data/collections/compendium-folders.d.mts +6 -6
  119. package/src/foundry/client/data/collections/compendium-packs.d.mts +5 -5
  120. package/src/foundry/client/data/collections/fog.d.mts +16 -3
  121. package/src/foundry/client/data/collections/folder.d.mts +20 -6
  122. package/src/foundry/client/data/collections/items.d.mts +17 -4
  123. package/src/foundry/client/data/collections/journal.d.mts +22 -7
  124. package/src/foundry/client/data/collections/macros.d.mts +21 -19
  125. package/src/foundry/client/data/collections/messages.d.mts +19 -6
  126. package/src/foundry/client/data/collections/playlists.d.mts +17 -5
  127. package/src/foundry/client/data/collections/scenes.d.mts +24 -27
  128. package/src/foundry/client/data/collections/settings.d.mts +16 -3
  129. package/src/foundry/client/data/collections/tables.d.mts +18 -5
  130. package/src/foundry/client/data/collections/users.d.mts +22 -10
  131. package/src/foundry/client/data/documents/active-effect.d.mts +780 -112
  132. package/src/foundry/client/data/documents/actor-delta.d.mts +705 -31
  133. package/src/foundry/client/data/documents/actor.d.mts +806 -98
  134. package/src/foundry/client/data/documents/adventure.d.mts +522 -59
  135. package/src/foundry/client/data/documents/ambient-light.d.mts +427 -20
  136. package/src/foundry/client/data/documents/ambient-sound.d.mts +478 -14
  137. package/src/foundry/client/data/documents/card.d.mts +598 -44
  138. package/src/foundry/client/data/documents/cards.d.mts +862 -169
  139. package/src/foundry/client/data/documents/chat-message.d.mts +668 -77
  140. package/src/foundry/client/data/documents/combat.d.mts +757 -107
  141. package/src/foundry/client/data/documents/combatant.d.mts +545 -32
  142. package/src/foundry/client/data/documents/drawing.d.mts +545 -14
  143. package/src/foundry/client/data/documents/fog-exploration.d.mts +465 -30
  144. package/src/foundry/client/data/documents/folder.d.mts +567 -51
  145. package/src/foundry/client/data/documents/index.d.mts +2 -0
  146. package/src/foundry/client/data/documents/item.d.mts +691 -24
  147. package/src/foundry/client/data/documents/journal-entry-page.d.mts +654 -55
  148. package/src/foundry/client/data/documents/journal-entry.d.mts +631 -35
  149. package/src/foundry/client/data/documents/macro.d.mts +560 -31
  150. package/src/foundry/client/data/documents/measured-template.d.mts +484 -15
  151. package/src/foundry/client/data/documents/note.d.mts +498 -15
  152. package/src/foundry/client/data/documents/playlist-sound.d.mts +443 -45
  153. package/src/foundry/client/data/documents/playlist.d.mts +710 -99
  154. package/src/foundry/client/data/documents/region-behavior.d.mts +516 -0
  155. package/src/foundry/client/data/documents/region.d.mts +789 -0
  156. package/src/foundry/client/data/documents/scene.d.mts +1216 -159
  157. package/src/foundry/client/data/documents/setting.d.mts +406 -23
  158. package/src/foundry/client/data/documents/table-result.d.mts +488 -14
  159. package/src/foundry/client/data/documents/table.d.mts +667 -78
  160. package/src/foundry/client/data/documents/tile.d.mts +505 -14
  161. package/src/foundry/client/data/documents/token.d.mts +1191 -143
  162. package/src/foundry/client/data/documents/user.d.mts +613 -57
  163. package/src/foundry/client/data/documents/wall.d.mts +555 -14
  164. package/src/foundry/client/game.d.mts +60 -92
  165. package/src/foundry/client/head.d.mts +9 -9
  166. package/src/foundry/client/hooks.d.mts +259 -248
  167. package/src/foundry/client/pixi/board.d.mts +107 -94
  168. package/src/foundry/client/pixi/core/containers/base-canvas-group.d.mts +97 -25
  169. package/src/foundry/client/pixi/core/containers/cached-container.d.mts +37 -19
  170. package/src/foundry/client/pixi/core/containers/full-canvas-container.d.mts +7 -10
  171. package/src/foundry/client/pixi/core/containers/point-source-mesh.d.mts +25 -15
  172. package/src/foundry/client/pixi/core/containers/quad-mesh.d.mts +16 -6
  173. package/src/foundry/client/pixi/core/containers/quadtree.d.mts +113 -54
  174. package/src/foundry/client/pixi/core/containers/sprite-mesh.d.mts +69 -26
  175. package/src/foundry/client/pixi/core/containers/unbound-container.d.mts +20 -2
  176. package/src/foundry/client/pixi/core/interaction/canvas-animation.d.mts +164 -99
  177. package/src/foundry/client/pixi/core/interaction/control-icon.d.mts +61 -22
  178. package/src/foundry/client/pixi/core/interaction/mouse-handler.d.mts +120 -53
  179. package/src/foundry/client/pixi/core/interaction/ping.d.mts +62 -31
  180. package/src/foundry/client/pixi/core/interaction/pings/chevron.d.mts +23 -10
  181. package/src/foundry/client/pixi/core/interaction/pings/pulse.d.mts +91 -34
  182. package/src/foundry/client/pixi/core/interaction/render-flags.d.mts +69 -30
  183. package/src/foundry/client/pixi/core/interaction/resize-handle.d.mts +35 -5
  184. package/src/foundry/client/pixi/core/interaction/targets.d.mts +21 -18
  185. package/src/foundry/client/pixi/core/loader.d.mts +86 -76
  186. package/src/foundry/client/pixi/core/shapes/limited-angle-polygon.d.mts +42 -17
  187. package/src/foundry/client/pixi/core/shapes/polygon-mesher.d.mts +92 -64
  188. package/src/foundry/client/pixi/core/shapes/precise-text.d.mts +28 -10
  189. package/src/foundry/client/pixi/core/shapes/ray.d.mts +47 -23
  190. package/src/foundry/client/pixi/core/shapes/source-polygon.d.mts +170 -75
  191. package/src/foundry/client/pixi/extensions/circle.d.mts +128 -125
  192. package/src/foundry/client/pixi/extensions/graphics.d.mts +3 -1
  193. package/src/foundry/client/pixi/extensions/observable-transform.d.mts +5 -4
  194. package/src/foundry/client/pixi/extensions/polygon.d.mts +154 -134
  195. package/src/foundry/client/pixi/extensions/rectangle.d.mts +242 -259
  196. package/src/foundry/client/pixi/groups/effects.d.mts +75 -24
  197. package/src/foundry/client/pixi/groups/environment.d.mts +68 -19
  198. package/src/foundry/client/pixi/groups/hidden.d.mts +27 -11
  199. package/src/foundry/client/pixi/groups/interface.d.mts +62 -38
  200. package/src/foundry/client/pixi/groups/overlay.d.mts +19 -7
  201. package/src/foundry/client/pixi/groups/primary.d.mts +66 -44
  202. package/src/foundry/client/pixi/groups/rendered.d.mts +19 -7
  203. package/src/foundry/client/pixi/layers/base/canvas-layer.d.mts +11 -15
  204. package/src/foundry/client/pixi/layers/base/interaction-layer.d.mts +29 -28
  205. package/src/foundry/client/pixi/layers/base/placeables-layer.d.mts +306 -272
  206. package/src/foundry/client/pixi/layers/controls/cursor.d.mts +18 -9
  207. package/src/foundry/client/pixi/layers/controls/door.d.mts +32 -11
  208. package/src/foundry/client/pixi/layers/controls/layer.d.mts +89 -77
  209. package/src/foundry/client/pixi/layers/controls/ruler.d.mts +121 -96
  210. package/src/foundry/client/pixi/layers/effects/background-effects.d.mts +9 -12
  211. package/src/foundry/client/pixi/layers/effects/coloration-effects.d.mts +9 -10
  212. package/src/foundry/client/pixi/layers/effects/darkness-effects.d.mts +8 -8
  213. package/src/foundry/client/pixi/layers/effects/illumination-effects.d.mts +22 -22
  214. package/src/foundry/client/pixi/layers/effects/visibility.d.mts +106 -86
  215. package/src/foundry/client/pixi/layers/effects/weather/particles/effect.d.mts +14 -5
  216. package/src/foundry/client/pixi/layers/effects/weather/particles/leaves.d.mts +31 -2
  217. package/src/foundry/client/pixi/layers/effects/weather-effects.d.mts +137 -65
  218. package/src/foundry/client/pixi/layers/grid/highlight.d.mts +14 -4
  219. package/src/foundry/client/pixi/layers/grid/layer.d.mts +92 -92
  220. package/src/foundry/client/pixi/layers/grid/mesh.d.mts +37 -16
  221. package/src/foundry/client/pixi/layers/masks/depth.d.mts +12 -7
  222. package/src/foundry/client/pixi/layers/masks/occlusion.d.mts +19 -12
  223. package/src/foundry/client/pixi/layers/masks/vision.d.mts +104 -18
  224. package/src/foundry/client/pixi/layers/placeables/drawings.d.mts +16 -15
  225. package/src/foundry/client/pixi/layers/placeables/index.d.mts +1 -0
  226. package/src/foundry/client/pixi/layers/placeables/lighting.d.mts +12 -14
  227. package/src/foundry/client/pixi/layers/placeables/notes.d.mts +49 -32
  228. package/src/foundry/client/pixi/layers/placeables/regions.d.mts +113 -0
  229. package/src/foundry/client/pixi/layers/placeables/sounds.d.mts +81 -67
  230. package/src/foundry/client/pixi/layers/placeables/templates.d.mts +11 -15
  231. package/src/foundry/client/pixi/layers/placeables/tiles.d.mts +30 -21
  232. package/src/foundry/client/pixi/layers/placeables/tokens.d.mts +66 -52
  233. package/src/foundry/client/pixi/layers/placeables/walls.d.mts +54 -57
  234. package/src/foundry/client/pixi/perception/clockwise-sweep.d.mts +62 -27
  235. package/src/foundry/client/pixi/perception/detection-mode.d.mts +121 -47
  236. package/src/foundry/client/pixi/perception/fog.d.mts +38 -15
  237. package/src/foundry/client/pixi/perception/perception-manager.d.mts +136 -136
  238. package/src/foundry/client/pixi/perception/vision-mode.d.mts +91 -64
  239. package/src/foundry/client/pixi/perception/weiler-atherton-clipping.d.mts +44 -16
  240. package/src/foundry/client/pixi/placeable.d.mts +239 -137
  241. package/src/foundry/client/pixi/placeables/drawing.d.mts +255 -133
  242. package/src/foundry/client/pixi/placeables/index.d.mts +1 -0
  243. package/src/foundry/client/pixi/placeables/light.d.mts +193 -64
  244. package/src/foundry/client/pixi/placeables/note.d.mts +145 -54
  245. package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-canvas-object.d.mts +30 -8
  246. package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-graphics.d.mts +41 -11
  247. package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-occludable-object.d.mts +59 -18
  248. package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-sprite-mesh.d.mts +120 -37
  249. package/src/foundry/client/pixi/placeables/region.d.mts +280 -0
  250. package/src/foundry/client/pixi/placeables/sound.d.mts +205 -66
  251. package/src/foundry/client/pixi/placeables/template.d.mts +181 -100
  252. package/src/foundry/client/pixi/placeables/tile.d.mts +206 -140
  253. package/src/foundry/client/pixi/placeables/token.d.mts +916 -449
  254. package/src/foundry/client/pixi/placeables/wall.d.mts +249 -129
  255. package/src/foundry/client/pixi/webgl/extensions/batch-renderer.d.mts +72 -33
  256. package/src/foundry/client/pixi/webgl/extensions/batch-shader-generator.d.mts +10 -9
  257. package/src/foundry/client/pixi/webgl/helpers/{framebugger-snapshot.d.mts → framebuffer-snapshot.d.mts} +10 -9
  258. package/src/foundry/client/pixi/webgl/helpers/index.d.mts +1 -1
  259. package/src/foundry/client/pixi/webgl/helpers/smooth-noise.d.mts +38 -23
  260. package/src/foundry/client/pixi/webgl/helpers/texture-extractor.d.mts +82 -53
  261. package/src/foundry/client/pixi/webgl/shaders/base-shader-mixin.d.mts +12 -12
  262. package/src/foundry/client/pixi/webgl/shaders/base-shader.d.mts +45 -28
  263. package/src/foundry/client/pixi/webgl/shaders/filters/base-filter.d.mts +12 -11
  264. package/src/foundry/client/pixi/webgl/shaders/filters/base-mask-filter.d.mts +12 -10
  265. package/src/foundry/client/pixi/webgl/shaders/filters/blur.d.mts +22 -20
  266. package/src/foundry/client/pixi/webgl/shaders/filters/effects-masking.d.mts +36 -32
  267. package/src/foundry/client/pixi/webgl/shaders/filters/environment.d.mts +10 -9
  268. package/src/foundry/client/pixi/webgl/shaders/filters/glow-overlay.d.mts +12 -11
  269. package/src/foundry/client/pixi/webgl/shaders/filters/invisibility.d.mts +10 -9
  270. package/src/foundry/client/pixi/webgl/shaders/filters/outline-overlay.d.mts +12 -11
  271. package/src/foundry/client/pixi/webgl/shaders/filters/transition.d.mts +67 -60
  272. package/src/foundry/client/pixi/webgl/shaders/filters/visibility.d.mts +24 -17
  273. package/src/foundry/client/pixi/webgl/shaders/filters/vision-mask-filter.d.mts +13 -10
  274. package/src/foundry/client/pixi/webgl/shaders/filters/void.d.mts +10 -9
  275. package/src/foundry/client/pixi/webgl/shaders/filters/weather-occlusion-masks.d.mts +11 -10
  276. package/src/foundry/client/pixi/webgl/shaders/fragment-channel-mixin.d.mts +20 -14
  277. package/src/foundry/client/pixi/webgl/shaders/grid/grid.d.mts +12 -11
  278. package/src/foundry/client/pixi/webgl/shaders/lighting/background-lighting.d.mts +10 -9
  279. package/src/foundry/client/pixi/webgl/shaders/lighting/base-lighting.d.mts +33 -33
  280. package/src/foundry/client/pixi/webgl/shaders/lighting/coloration-lighting.d.mts +10 -9
  281. package/src/foundry/client/pixi/webgl/shaders/lighting/darkness-lighting.d.mts +10 -9
  282. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/bewitching-wave.d.mts +19 -17
  283. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/black-hole.d.mts +10 -9
  284. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/chroma.d.mts +10 -9
  285. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/emanation.d.mts +10 -9
  286. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/energy-field.d.mts +10 -9
  287. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/fairy-light.d.mts +19 -17
  288. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/flame.d.mts +19 -17
  289. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/fog.d.mts +10 -9
  290. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/force-grid.d.mts +10 -8
  291. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/ghost-light.d.mts +19 -17
  292. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/hexa-dome.d.mts +10 -9
  293. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/light-dome.d.mts +10 -9
  294. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/magical-gloom.d.mts +10 -9
  295. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/pulse.d.mts +19 -17
  296. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/radial-rainbow.d.mts +10 -9
  297. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/revolving-light.d.mts +10 -9
  298. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/roiling-mass.d.mts +10 -9
  299. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/siren-light.d.mts +19 -17
  300. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/smoke-patch.d.mts +20 -17
  301. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/star-light.d.mts +10 -9
  302. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/sunburst.d.mts +19 -17
  303. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/swirling-rainbow.d.mts +10 -9
  304. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/torch.d.mts +19 -17
  305. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/vortex.d.mts +19 -17
  306. package/src/foundry/client/pixi/webgl/shaders/lighting/effects/wave.d.mts +19 -17
  307. package/src/foundry/client/pixi/webgl/shaders/lighting/illumination-lighting.d.mts +10 -9
  308. package/src/foundry/client/pixi/webgl/shaders/region/adjust-darkness-level.d.mts +71 -29
  309. package/src/foundry/client/pixi/webgl/shaders/region/base.d.mts +54 -10
  310. package/src/foundry/client/pixi/webgl/shaders/region/highlight.d.mts +69 -9
  311. package/src/foundry/client/pixi/webgl/shaders/samplers/base-sampler.d.mts +24 -25
  312. package/src/foundry/client/pixi/webgl/shaders/samplers/baseline-illumination.d.mts +10 -9
  313. package/src/foundry/client/pixi/webgl/shaders/samplers/color-adjustment.d.mts +38 -29
  314. package/src/foundry/client/pixi/webgl/shaders/samplers/depth.d.mts +21 -17
  315. package/src/foundry/client/pixi/webgl/shaders/samplers/fog-of-war.d.mts +10 -9
  316. package/src/foundry/client/pixi/webgl/shaders/samplers/occlusion.d.mts +20 -18
  317. package/src/foundry/client/pixi/webgl/shaders/samplers/primary.d.mts +11 -2
  318. package/src/foundry/client/pixi/webgl/shaders/samplers/token-ring.d.mts +28 -2
  319. package/src/foundry/client/pixi/webgl/shaders/vision/background-vision.d.mts +10 -9
  320. package/src/foundry/client/pixi/webgl/shaders/vision/base-vision.d.mts +11 -9
  321. package/src/foundry/client/pixi/webgl/shaders/vision/coloration-vision.d.mts +10 -9
  322. package/src/foundry/client/pixi/webgl/shaders/vision/effects/amplification.d.mts +10 -9
  323. package/src/foundry/client/pixi/webgl/shaders/vision/effects/wave.d.mts +19 -17
  324. package/src/foundry/client/pixi/webgl/shaders/vision/illumination-vision.d.mts +10 -9
  325. package/src/foundry/client/pixi/webgl/shaders/weather/base-weather.d.mts +40 -36
  326. package/src/foundry/client/pixi/webgl/shaders/weather/effect.d.mts +27 -33
  327. package/src/foundry/client/pixi/webgl/shaders/weather/fog.d.mts +17 -16
  328. package/src/foundry/client/pixi/webgl/shaders/weather/rain.d.mts +19 -18
  329. package/src/foundry/client/pixi/webgl/shaders/weather/snow.d.mts +15 -14
  330. package/src/foundry/client/pixi/workers/texture-worker.d.mts +33 -53
  331. package/src/foundry/client/tours/setup-tour.d.mts +15 -10
  332. package/src/foundry/client/ui/context.d.mts +48 -40
  333. package/src/foundry/client/ui/dialog.d.mts +137 -126
  334. package/src/foundry/client/ui/drag.d.mts +1 -1
  335. package/src/foundry/client/ui/dragdrop.d.mts +34 -28
  336. package/src/foundry/client/ui/editor.d.mts +29 -21
  337. package/src/foundry/client/ui/filepicker.d.mts +43 -38
  338. package/src/foundry/client/ui/filter.d.mts +62 -50
  339. package/src/foundry/client/ui/forms.d.mts +22 -22
  340. package/src/foundry/client/ui/notifications.d.mts +10 -3
  341. package/src/foundry/client/ui/prosemirror.d.mts +15 -7
  342. package/src/foundry/client/ui/secrets.d.mts +42 -27
  343. package/src/foundry/client/ui/tabs.d.mts +40 -33
  344. package/src/foundry/client-esm/applications/_module.d.mts +3 -3
  345. package/src/foundry/client-esm/applications/_types.d.mts +0 -2
  346. package/src/foundry/client-esm/applications/api/_module.d.mts +2 -2
  347. package/src/foundry/client-esm/applications/api/application.d.mts +28 -19
  348. package/src/foundry/client-esm/applications/api/dialog.d.mts +20 -22
  349. package/src/foundry/client-esm/applications/api/document-sheet.d.mts +26 -12
  350. package/src/foundry/client-esm/applications/api/handlebars-application.d.mts +142 -126
  351. package/src/foundry/client-esm/applications/apps/_module.d.mts +2 -2
  352. package/src/foundry/client-esm/applications/apps/compendium-art-config.d.mts +10 -10
  353. package/src/foundry/client-esm/applications/apps/permission-config.d.mts +3 -3
  354. package/src/foundry/client-esm/applications/dice/_module.d.mts +2 -2
  355. package/src/foundry/client-esm/applications/dice/roll-resolver.d.mts +14 -2
  356. package/src/foundry/client-esm/applications/elements/_module.d.mts +2 -2
  357. package/src/foundry/client-esm/applications/elements/document-tags.d.mts +2 -0
  358. package/src/foundry/client-esm/applications/elements/file-picker.d.mts +1 -1
  359. package/src/foundry/client-esm/applications/elements/multi-select.d.mts +15 -5
  360. package/src/foundry/client-esm/applications/elements/string-tags.d.mts +1 -1
  361. package/src/foundry/client-esm/applications/forms/fields.d.mts +1 -1
  362. package/src/foundry/client-esm/applications/sheets/_module.d.mts +2 -2
  363. package/src/foundry/client-esm/applications/sheets/actor-sheet.d.mts +3 -3
  364. package/src/foundry/client-esm/applications/sheets/ambient-light-config.d.mts +10 -8
  365. package/src/foundry/client-esm/applications/sheets/ambient-sound-config.d.mts +9 -7
  366. package/src/foundry/client-esm/applications/sheets/item-sheet.d.mts +3 -3
  367. package/src/foundry/client-esm/applications/sheets/region-behavior-config.d.mts +30 -5
  368. package/src/foundry/client-esm/applications/sheets/region-config.d.mts +36 -5
  369. package/src/foundry/client-esm/applications/sheets/user-config.d.mts +8 -7
  370. package/src/foundry/client-esm/applications/ui/_module.d.mts +2 -2
  371. package/src/foundry/client-esm/applications/ui/region-legend.d.mts +45 -3
  372. package/src/foundry/client-esm/audio/_module.d.mts +2 -3
  373. package/src/foundry/client-esm/audio/_types.d.mts +2 -0
  374. package/src/foundry/client-esm/audio/biquad.d.mts +76 -26
  375. package/src/foundry/client-esm/audio/cache.d.mts +31 -20
  376. package/src/foundry/client-esm/audio/convolver.d.mts +47 -25
  377. package/src/foundry/client-esm/audio/helper.d.mts +124 -80
  378. package/src/foundry/client-esm/audio/sound.d.mts +230 -126
  379. package/src/foundry/client-esm/audio/timeout.d.mts +28 -12
  380. package/src/foundry/client-esm/canvas/_module.d.mts +2 -2
  381. package/src/foundry/client-esm/canvas/edges/_module.d.mts +2 -2
  382. package/src/foundry/client-esm/canvas/edges/collision.d.mts +69 -18
  383. package/src/foundry/client-esm/canvas/edges/edge.d.mts +110 -41
  384. package/src/foundry/client-esm/canvas/edges/edges.d.mts +10 -0
  385. package/src/foundry/client-esm/canvas/edges/vertex.d.mts +56 -26
  386. package/src/foundry/client-esm/canvas/regions/_module.d.mts +6 -11
  387. package/src/foundry/client-esm/canvas/regions/geometry.d.mts +38 -0
  388. package/src/foundry/client-esm/canvas/regions/mesh.d.mts +72 -0
  389. package/src/foundry/client-esm/canvas/regions/polygon-tree.d.mts +130 -0
  390. package/src/foundry/client-esm/canvas/regions/shape.d.mts +129 -0
  391. package/src/foundry/client-esm/canvas/scene-manager.d.mts +13 -3
  392. package/src/foundry/client-esm/canvas/smaa/blend.d.mts +14 -3
  393. package/src/foundry/client-esm/canvas/smaa/edges.d.mts +25 -3
  394. package/src/foundry/client-esm/canvas/smaa/smaa.d.mts +121 -23
  395. package/src/foundry/client-esm/canvas/smaa/weights.d.mts +26 -3
  396. package/src/foundry/client-esm/canvas/sources/_module.d.mts +2 -2
  397. package/src/foundry/client-esm/canvas/sources/base-effect-source.d.mts +84 -40
  398. package/src/foundry/client-esm/canvas/sources/base-light-source.d.mts +103 -39
  399. package/src/foundry/client-esm/canvas/sources/global-light-source.d.mts +89 -15
  400. package/src/foundry/client-esm/canvas/sources/point-darkness-source.d.mts +71 -27
  401. package/src/foundry/client-esm/canvas/sources/point-effect-source.d.mts +49 -20
  402. package/src/foundry/client-esm/canvas/sources/point-light-source.d.mts +57 -16
  403. package/src/foundry/client-esm/canvas/sources/point-movement-source.d.mts +31 -4
  404. package/src/foundry/client-esm/canvas/sources/point-sound-source.d.mts +45 -12
  405. package/src/foundry/client-esm/canvas/sources/point-vision-source.d.mts +98 -52
  406. package/src/foundry/client-esm/canvas/sources/rendered-effect-source.d.mts +180 -69
  407. package/src/foundry/client-esm/canvas/tokens/_module.d.mts +2 -3
  408. package/src/foundry/client-esm/canvas/tokens/ring-config.d.mts +175 -2
  409. package/src/foundry/client-esm/canvas/tokens/ring-data.d.mts +142 -2
  410. package/src/foundry/client-esm/canvas/tokens/ring.d.mts +284 -2
  411. package/src/foundry/client-esm/client.d.mts +47 -54
  412. package/src/foundry/client-esm/data/_module.d.mts +2 -2
  413. package/src/foundry/client-esm/data/client-backend.d.mts +22 -23
  414. package/src/foundry/client-esm/data/region-behaviors/_module.d.mts +11 -14
  415. package/src/foundry/client-esm/data/region-behaviors/adjust-darkness-level.d.mts +56 -0
  416. package/src/foundry/client-esm/data/region-behaviors/base.d.mts +59 -0
  417. package/src/foundry/client-esm/data/region-behaviors/display-scrolling-text.d.mts +64 -0
  418. package/src/foundry/client-esm/data/region-behaviors/execute-macro.d.mts +27 -0
  419. package/src/foundry/client-esm/data/region-behaviors/execute-script.d.mts +23 -0
  420. package/src/foundry/client-esm/data/region-behaviors/pause-game.d.mts +23 -0
  421. package/src/foundry/client-esm/data/region-behaviors/suppress-weather.d.mts +17 -0
  422. package/src/foundry/client-esm/data/region-behaviors/teleport-token.d.mts +32 -0
  423. package/src/foundry/client-esm/data/region-behaviors/toggle-behavior.d.mts +31 -0
  424. package/src/foundry/client-esm/dice/_module.d.mts +2 -3
  425. package/src/foundry/client-esm/dice/parser.d.mts +11 -25
  426. package/src/foundry/client-esm/dice/roll.d.mts +112 -89
  427. package/src/foundry/client-esm/dice/terms/_module.d.mts +2 -3
  428. package/src/foundry/client-esm/dice/terms/coin.d.mts +8 -5
  429. package/src/foundry/client-esm/dice/terms/dice.d.mts +93 -63
  430. package/src/foundry/client-esm/dice/terms/die.d.mts +11 -4
  431. package/src/foundry/client-esm/dice/terms/fate.d.mts +9 -2
  432. package/src/foundry/client-esm/dice/terms/function.d.mts +18 -18
  433. package/src/foundry/client-esm/dice/terms/numeric.d.mts +3 -5
  434. package/src/foundry/client-esm/dice/terms/operator.d.mts +2 -2
  435. package/src/foundry/client-esm/dice/terms/parenthetical.d.mts +9 -10
  436. package/src/foundry/client-esm/dice/terms/pool.d.mts +25 -31
  437. package/src/foundry/client-esm/dice/terms/string.d.mts +4 -4
  438. package/src/foundry/client-esm/dice/terms/term.d.mts +18 -4
  439. package/src/foundry/client-esm/dice/twister.d.mts +3 -3
  440. package/src/foundry/client-esm/helpers/_module.d.mts +2 -2
  441. package/src/foundry/client-esm/helpers/_types.d.mts +12 -46
  442. package/src/foundry/client-esm/helpers/compendium-art.d.mts +56 -4
  443. package/src/foundry/common/abstract/_types.d.mts +60 -54
  444. package/src/foundry/common/abstract/backend.d.mts +51 -45
  445. package/src/foundry/common/abstract/data.d.mts +265 -236
  446. package/src/foundry/common/abstract/document.d.mts +1449 -464
  447. package/src/foundry/common/abstract/embedded-collection-delta.d.mts +1 -1
  448. package/src/foundry/common/abstract/embedded-collection.d.mts +37 -7
  449. package/src/foundry/common/abstract/module.d.mts +3 -2
  450. package/src/foundry/common/abstract/singleton-collection.d.mts +1 -1
  451. package/src/foundry/common/abstract/socket.d.mts +1 -1
  452. package/src/foundry/common/abstract/type-data.d.mts +61 -55
  453. package/src/foundry/common/config.d.mts +11 -3
  454. package/src/foundry/common/constants.d.mts +261 -231
  455. package/src/foundry/common/data/data.d.mts +238 -102
  456. package/src/foundry/common/data/fields.d.mts +1334 -874
  457. package/src/foundry/common/data/module.d.mts +2 -2
  458. package/src/foundry/common/data/validation-failure.d.mts +12 -9
  459. package/src/foundry/common/documents/_module.d.mts +4 -2
  460. package/src/foundry/common/documents/_types.d.mts +22 -56
  461. package/src/foundry/common/documents/active-effect.d.mts +358 -194
  462. package/src/foundry/common/documents/actor-delta.d.mts +403 -73
  463. package/src/foundry/common/documents/actor.d.mts +359 -117
  464. package/src/foundry/common/documents/adventure.d.mts +312 -142
  465. package/src/foundry/common/documents/ambient-light.d.mts +296 -75
  466. package/src/foundry/common/documents/ambient-sound.d.mts +296 -109
  467. package/src/foundry/common/documents/card.d.mts +321 -187
  468. package/src/foundry/common/documents/cards.d.mts +353 -125
  469. package/src/foundry/common/documents/chat-message.d.mts +338 -167
  470. package/src/foundry/common/documents/combat.d.mts +358 -94
  471. package/src/foundry/common/documents/combatant.d.mts +323 -92
  472. package/src/foundry/common/documents/drawing.d.mts +327 -206
  473. package/src/foundry/common/documents/fog-exploration.d.mts +303 -69
  474. package/src/foundry/common/documents/folder.d.mts +307 -82
  475. package/src/foundry/common/documents/item.d.mts +377 -100
  476. package/src/foundry/common/documents/journal-entry-page.d.mts +327 -187
  477. package/src/foundry/common/documents/journal-entry.d.mts +345 -68
  478. package/src/foundry/common/documents/macro.d.mts +325 -139
  479. package/src/foundry/common/documents/measured-template.d.mts +328 -138
  480. package/src/foundry/common/documents/note.d.mts +312 -151
  481. package/src/foundry/common/documents/playlist-sound.d.mts +309 -102
  482. package/src/foundry/common/documents/playlist.d.mts +341 -131
  483. package/src/foundry/common/documents/region-behavior.d.mts +360 -0
  484. package/src/foundry/common/documents/region.d.mts +355 -0
  485. package/src/foundry/common/documents/roll-table.d.mts +320 -102
  486. package/src/foundry/common/documents/scene.d.mts +437 -350
  487. package/src/foundry/common/documents/setting.d.mts +285 -54
  488. package/src/foundry/common/documents/table-result.d.mts +326 -103
  489. package/src/foundry/common/documents/tile.d.mts +337 -172
  490. package/src/foundry/common/documents/token.d.mts +396 -447
  491. package/src/foundry/common/documents/user.d.mts +296 -173
  492. package/src/foundry/common/documents/wall.d.mts +303 -156
  493. package/src/foundry/common/grid/_module.d.mts +3 -3
  494. package/src/foundry/common/grid/base.d.mts +66 -49
  495. package/src/foundry/common/grid/gridless.d.mts +2 -2
  496. package/src/foundry/common/grid/hexagonal.d.mts +35 -28
  497. package/src/foundry/common/grid/square.d.mts +3 -3
  498. package/src/foundry/common/packages/base-module.d.mts +6 -24
  499. package/src/foundry/common/packages/base-package.d.mts +56 -31
  500. package/src/foundry/common/packages/base-system.d.mts +45 -63
  501. package/src/foundry/common/packages/base-world.d.mts +15 -61
  502. package/src/foundry/common/packages/module.d.mts +7 -7
  503. package/src/foundry/common/packages/sub-types.d.mts +4 -6
  504. package/src/foundry/common/primitives/array.d.mts +4 -4
  505. package/src/foundry/common/primitives/math.d.mts +7 -1
  506. package/src/foundry/common/primitives/number.d.mts +2 -2
  507. package/src/foundry/common/primitives/set.d.mts +17 -14
  508. package/src/foundry/common/primitives/string.d.mts +1 -1
  509. package/src/foundry/common/prosemirror/_module.d.mts +15 -15
  510. package/src/foundry/common/prosemirror/dirty-plugin.d.mts +1 -1
  511. package/src/foundry/common/prosemirror/dom-parser.d.mts +2 -1
  512. package/src/foundry/common/prosemirror/dropdown.d.mts +1 -1
  513. package/src/foundry/common/prosemirror/highlight-matches-plugin.d.mts +2 -2
  514. package/src/foundry/common/prosemirror/image-plugin.d.mts +1 -1
  515. package/src/foundry/common/prosemirror/menu.d.mts +3 -3
  516. package/src/foundry/common/prosemirror/paste-transformer.d.mts +1 -1
  517. package/src/foundry/common/prosemirror/plugin.d.mts +2 -2
  518. package/src/foundry/common/prosemirror/schema/index.d.mts +0 -1
  519. package/src/foundry/common/prosemirror/schema/lists.d.mts +2 -0
  520. package/src/foundry/common/prosemirror/util.d.mts +1 -1
  521. package/src/foundry/common/types.d.mts +3 -3
  522. package/src/foundry/common/utils/bitmask.d.mts +23 -11
  523. package/src/foundry/common/utils/collection.d.mts +61 -38
  524. package/src/foundry/common/utils/color.d.mts +20 -2
  525. package/src/foundry/common/utils/event-emitter.d.mts +32 -17
  526. package/src/foundry/common/utils/helpers.d.mts +36 -26
  527. package/src/foundry/common/utils/http.d.mts +2 -2
  528. package/src/foundry/common/utils/module.d.mts +2 -2
  529. package/src/foundry/common/utils/string-tree.d.mts +45 -39
  530. package/src/foundry/common/utils/word-tree.d.mts +10 -23
  531. package/src/foundry/index.d.mts +0 -1
  532. package/src/foundry/{clipper → public/scripts/clipper}/clipper.d.mts +58 -16
  533. package/src/foundry/public/scripts/index.d.mts +1 -0
  534. package/src/foundry/public/scripts/workers/image-compressor.d.mts +23 -0
  535. package/src/foundry/public/scripts/workers/index.d.mts +1 -0
  536. package/{index-lenient.d.mts → src/index-lenient.d.mts} +2 -0
  537. package/src/index.d.mts +6 -0
  538. package/src/tsconfig.json +15 -0
  539. package/src/types/augments/particles.d.mts +29 -0
  540. package/src/types/augments/pixi.d.mts +1024 -21
  541. package/src/types/augments/smooth.d.mts +31 -0
  542. package/src/types/augments/tinyMCE.d.mts +1 -1
  543. package/src/types/config.d.mts +18 -313
  544. package/src/types/documentConfiguration.d.mts +286 -542
  545. package/src/types/index.d.mts +1 -1
  546. package/src/types/lib.d.mts +12 -0
  547. package/src/types/workers/image-compressor.d.mts +176 -0
  548. package/src/utils/index.d.mts +1279 -0
  549. package/tsconfig.json +29 -0
  550. package/tsconfig.main.json +8 -0
  551. package/tsconfig.miscellaneous.json +16 -0
  552. package/index.d.mts +0 -5
  553. package/src/foundry/client/apps/placeables/light-config.d.mts +0 -100
  554. package/src/foundry/client/apps/placeables/sound-config.d.mts +0 -43
  555. package/src/foundry/common/documents/module.d.mts +0 -35
  556. package/src/foundry/common/primitives/regex.d.mts +0 -12
  557. package/src/types/helperTypes.d.mts +0 -583
  558. package/src/types/utils.d.mts +0 -539
  559. /package/src/foundry/{clipper → public/scripts/clipper}/index.d.mts +0 -0
@@ -1,8 +1,8 @@
1
- import type { GetKey } from "../../types/helperTypes.d.mts";
2
1
  import type * as CONST from "../common/constants.d.mts";
3
2
  import type { DataModel, Document } from "../common/abstract/module.d.mts";
4
- import type PointLightSource from "../client-esm/canvas/sources/point-light-source.d.mts";
5
- import type { AnyObject, HandleEmptyObject, MaybePromise } from "../../types/utils.d.mts";
3
+ import type { GetKey, AnyObject, HandleEmptyObject, MaybePromise } from "#utils";
4
+ import type BaseLightSource from "../client-esm/canvas/sources/base-light-source.d.mts";
5
+ import type RenderedEffectSource from "../client-esm/canvas/sources/rendered-effect-source.d.mts";
6
6
 
7
7
  declare global {
8
8
  namespace CONFIG {
@@ -52,7 +52,7 @@ declare global {
52
52
  * resolver. This resolver must therefore be capable of handling manual
53
53
  * rolls.
54
54
  */
55
- resolver: typeof foundry.applications.dice.RollResolver;
55
+ resolver: foundry.applications.dice.RollResolver.AnyConstructor;
56
56
  }
57
57
 
58
58
  /**
@@ -67,7 +67,9 @@ declare global {
67
67
  options?: AnyObject,
68
68
  ) => Promise<number | void>;
69
69
 
70
- type RollFunction = (arg0: never, ...args: never[]) => MaybePromise<number>;
70
+ type RollFunction = (...args: Array<string | number>) => MaybePromise<number | `${number}`>;
71
+
72
+ type DTermDiceStrings = "d4" | "d6" | "d8" | "d10" | "d12" | "d20" | "d100";
71
73
  }
72
74
 
73
75
  interface Dice {
@@ -75,7 +77,7 @@ declare global {
75
77
  * The Dice types which are supported.
76
78
  * @defaultValue `[foundry.dice.terms.Die, foundry.dice.terms.FateDie]`
77
79
  */
78
- types: Array<typeof foundry.dice.terms.DiceTerm>;
80
+ types: Array<foundry.dice.terms.DiceTerm.AnyConstructor>;
79
81
 
80
82
  rollModes: CONFIG.Dice.RollModes;
81
83
 
@@ -83,7 +85,7 @@ declare global {
83
85
  * Configured Roll class definitions
84
86
  * @defaultValue `[Roll]`
85
87
  */
86
- rolls: Array<typeof foundry.dice.Roll>;
88
+ rolls: Array<foundry.dice.Roll.AnyConstructor>;
87
89
 
88
90
  /**
89
91
  * Configured DiceTerm class definitions
@@ -100,14 +102,14 @@ declare global {
100
102
  * }
101
103
  * ```
102
104
  */
103
- termTypes: Record<string, typeof foundry.dice.terms.RollTerm>;
105
+ termTypes: Record<string, foundry.dice.terms.RollTerm.AnyConstructor>;
104
106
 
105
107
  /** Configured roll terms and the classes they map to. */
106
108
  terms: {
107
- c: typeof foundry.dice.terms.Coin;
108
- d: typeof foundry.dice.terms.Die;
109
- f: typeof foundry.dice.terms.FateDie;
110
- } & Record<string, typeof foundry.dice.terms.DiceTerm>;
109
+ c: foundry.dice.terms.Coin.AnyConstructor;
110
+ d: foundry.dice.terms.Die.AnyConstructor;
111
+ f: foundry.dice.terms.FateDie.AnyConstructor;
112
+ } & Record<string, foundry.dice.terms.DiceTerm.AnyConstructor>;
111
113
 
112
114
  /**
113
115
  * A function used to provide random uniform values.
@@ -116,7 +118,7 @@ declare global {
116
118
  randomUniform: () => number;
117
119
 
118
120
  /** A parser implementation for parsing Roll expressions. */
119
- parser: typeof foundry.dice.RollParser;
121
+ parser: foundry.dice.RollParser.AnyConstructor;
120
122
 
121
123
  /** A collection of custom functions that can be included in roll expressions.*/
122
124
  functions: Record<string, CONFIG.Dice.RollFunction>;
@@ -130,7 +132,7 @@ declare global {
130
132
  /**
131
133
  * Configured status effects which are recognized by the game system
132
134
  */
133
- type StatusEffect = foundry.documents.BaseActiveEffect.ConstructorData & {
135
+ type StatusEffect = foundry.documents.BaseActiveEffect.CreateData & {
134
136
  /**
135
137
  * A string identifier for the effect
136
138
  */
@@ -231,7 +233,7 @@ declare global {
231
233
  * include or specifically exclude certain file paths or warning messages.
232
234
  * Exclusion rules take precedence over inclusion rules.
233
235
  *
234
- * @see {@link CONST.COMPATIBILITY_MODES}
236
+ * @see {@link CONST.COMPATIBILITY_MODES | `CONST.COMPATIBILITY_MODES`}
235
237
  *
236
238
  * @example Include Specific Errors
237
239
  * ```js
@@ -293,10 +295,10 @@ declare global {
293
295
  */
294
296
  Actor: {
295
297
  /** @defaultValue `Actor` */
296
- documentClass: Document.ConfiguredClassForName<"Actor">;
298
+ documentClass: Document.ImplementationClassFor<"Actor">;
297
299
 
298
300
  /** @defaultValue `Actors` */
299
- collection: typeof Actors;
301
+ collection: Actors.AnyConstructor;
300
302
 
301
303
  /** @defaultValue `[]` */
302
304
  compendiumIndexFields: string[];
@@ -311,18 +313,18 @@ declare global {
311
313
  * @defaultValue `{}`
312
314
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
313
315
  */
314
- dataModels: Record<string, typeof DataModel<any, Actor>>;
316
+ dataModels: Record<string, typeof DataModel<any, Actor.Implementation>>;
315
317
 
316
318
  /**
317
319
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
318
320
  */
319
- sheetClasses: Record<foundry.documents.BaseActor.TypeNames, Record<string, SheetClassConfig>>;
321
+ sheetClasses: Record<foundry.documents.BaseActor.SubType, Record<string, SheetClassConfig>>;
320
322
 
321
323
  /**
322
324
  * @defaultValue `{}`
323
325
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
324
326
  */
325
- typeLabels: Record<foundry.documents.BaseActor.TypeNames, string>;
327
+ typeLabels: Record<foundry.documents.BaseActor.SubType, string>;
326
328
 
327
329
  /** @defaultValue `{}` */
328
330
  typeIcons: Record<string, string>;
@@ -338,7 +340,7 @@ declare global {
338
340
  */
339
341
  Adventure: {
340
342
  /** @defaultValue `foundry.documents.BaseAdventure` */
341
- documentClass: Document.ConfiguredClassForName<"Adventure">;
343
+ documentClass: Document.ImplementationClassFor<"Adventure">;
342
344
 
343
345
  /**
344
346
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -365,13 +367,13 @@ declare global {
365
367
  */
366
368
  Cards: {
367
369
  /** @defaultValue `CardStacks` */
368
- collection: typeof CardStacks;
370
+ collection: CardStacks.AnyConstructor;
369
371
 
370
372
  /** @defaultValue `[]` */
371
373
  compendiumIndexFields: string[];
372
374
 
373
375
  /** @defaultValue `Cards` */
374
- documentClass: Document.ConfiguredClassForName<"Cards">;
376
+ documentClass: Document.ImplementationClassFor<"Cards">;
375
377
 
376
378
  /** @defaultValue `"fa-solid fa-cards"` */
377
379
  sidebarIcon: string;
@@ -380,7 +382,7 @@ declare global {
380
382
  * @defaultValue `{}`
381
383
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
382
384
  */
383
- dataModels: Record<string, typeof DataModel<any, Cards>>;
385
+ dataModels: Record<string, typeof DataModel<any, Cards.Implementation>>;
384
386
 
385
387
  /**
386
388
  * @defaultValue
@@ -404,13 +406,13 @@ declare global {
404
406
  /**
405
407
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
406
408
  */
407
- sheetClasses: Record<foundry.documents.BaseCards.TypeNames, Record<string, SheetClassConfig>>;
409
+ sheetClasses: Record<foundry.documents.BaseCards.SubType, Record<string, SheetClassConfig>>;
408
410
 
409
411
  /**
410
412
  * @defaultValue `{}`
411
413
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
412
414
  */
413
- typeLabels: Record<foundry.documents.BaseCards.TypeNames, string>;
415
+ typeLabels: Record<foundry.documents.BaseCards.SubType, string>;
414
416
 
415
417
  typeIcons: {
416
418
  /** @defaultValue `"fas fa-cards"` */
@@ -429,10 +431,10 @@ declare global {
429
431
  */
430
432
  ChatMessage: {
431
433
  /** @defaultValue `ChatMessage` */
432
- documentClass: Document.ConfiguredClassForName<"ChatMessage">;
434
+ documentClass: Document.ImplementationClassFor<"ChatMessage">;
433
435
 
434
436
  /** @defaultValue `Messages` */
435
- collection: typeof Messages;
437
+ collection: Messages.AnyConstructor;
436
438
 
437
439
  /** @defaultValue `"templates/sidebar/chat-message.html"` */
438
440
  template: string;
@@ -444,18 +446,18 @@ declare global {
444
446
  * @defaultValue `{}`
445
447
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
446
448
  */
447
- dataModels: Record<string, typeof DataModel<any, ChatMessage>>;
449
+ dataModels: Record<string, typeof DataModel<any, ChatMessage.Implementation>>;
448
450
 
449
451
  /**
450
452
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
451
453
  */
452
- sheetClasses: Record<foundry.documents.BaseChatMessage.TypeNames, Record<string, SheetClassConfig>>;
454
+ sheetClasses: Record<foundry.documents.BaseChatMessage.SubType, Record<string, SheetClassConfig>>;
453
455
 
454
456
  /**
455
457
  * @defaultValue `{}`
456
458
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
457
459
  */
458
- typeLabels: Record<foundry.documents.BaseChatMessage.TypeNames, string>;
460
+ typeLabels: Record<foundry.documents.BaseChatMessage.SubType, string>;
459
461
 
460
462
  /** @defaultValue `{}` */
461
463
  typeIcons: Record<string, string>;
@@ -469,10 +471,10 @@ declare global {
469
471
  */
470
472
  Combat: {
471
473
  /** @defaultValue `Combat` */
472
- documentClass: Document.ConfiguredClassForName<"Combat">;
474
+ documentClass: Document.ImplementationClassFor<"Combat">;
473
475
 
474
476
  /** @defaultValue `CombatEncounters` */
475
- collection: typeof CombatEncounters;
477
+ collection: CombatEncounters.AnyConstructor;
476
478
 
477
479
  /** @defaultValue `"fas fa-swords"` */
478
480
  sidebarIcon: string;
@@ -481,18 +483,18 @@ declare global {
481
483
  * @defaultValue `{}`
482
484
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
483
485
  */
484
- dataModels: Record<string, typeof DataModel<any, Combat>>;
486
+ dataModels: Record<string, typeof DataModel<any, Combat.Implementation>>;
485
487
 
486
488
  /**
487
489
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
488
490
  */
489
- sheetClasses: Record<foundry.documents.BaseCombat.TypeNames, Record<string, SheetClassConfig>>;
491
+ sheetClasses: Record<foundry.documents.BaseCombat.SubType, Record<string, SheetClassConfig>>;
490
492
 
491
493
  /**
492
494
  * @defaultValue `{}`
493
495
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
494
496
  */
495
- typeLabels: Record<foundry.documents.BaseCombat.TypeNames, string>;
497
+ typeLabels: Record<foundry.documents.BaseCombat.SubType, string>;
496
498
 
497
499
  /** @defaultValue `{}` */
498
500
  typeIcons: Record<string, string>;
@@ -537,7 +539,7 @@ declare global {
537
539
  */
538
540
  FogExploration: {
539
541
  /** @defaultValue `FogExploration` */
540
- documentClass: Document.ConfiguredClassForName<"FogExploration">;
542
+ documentClass: Document.ImplementationClassFor<"FogExploration">;
541
543
 
542
544
  /**
543
545
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -550,7 +552,7 @@ declare global {
550
552
  typeLabels?: Record<"base", string>;
551
553
 
552
554
  /** @defaultValue `FogExplorations` */
553
- collection: typeof FogExplorations;
555
+ collection: FogExplorations.AnyConstructor;
554
556
  };
555
557
 
556
558
  /**
@@ -558,10 +560,10 @@ declare global {
558
560
  */
559
561
  Folder: {
560
562
  /** @defaultValue `Folder` */
561
- documentClass: Document.ConfiguredClassForName<"Folder">;
563
+ documentClass: Document.ImplementationClassFor<"Folder">;
562
564
 
563
565
  /** @defaultValue `Folders` */
564
- collection: typeof Folders;
566
+ collection: Folders.AnyConstructor;
565
567
 
566
568
  /** @defaultValue `"fas fa-folder"` */
567
569
  sidebarIcon: string;
@@ -582,10 +584,10 @@ declare global {
582
584
  */
583
585
  Item: {
584
586
  /** @defaultValue `Item` */
585
- documentClass: Document.ConfiguredClassForName<"Item">;
587
+ documentClass: Document.ImplementationClassFor<"Item">;
586
588
 
587
589
  /** @defaultValue `Items` */
588
- collection: typeof Items;
590
+ collection: Items.AnyConstructor;
589
591
 
590
592
  /** @defaultValue `[]` */
591
593
  compendiumIndexFields: string[];
@@ -600,18 +602,18 @@ declare global {
600
602
  * @defaultValue `{}`
601
603
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
602
604
  */
603
- dataModels: Record<string, typeof DataModel<any, Item>>;
605
+ dataModels: Record<string, typeof DataModel<any, Item.Implementation>>;
604
606
 
605
607
  /**
606
608
  * @defaultValue `{}`
607
609
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
608
610
  */
609
- typeLabels: Record<foundry.documents.BaseItem.TypeNames, string>;
611
+ typeLabels: Record<foundry.documents.BaseItem.SubType, string>;
610
612
 
611
613
  /**
612
614
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
613
615
  */
614
- sheetClasses: Record<foundry.documents.BaseItem.TypeNames, Record<string, SheetClassConfig>>;
616
+ sheetClasses: Record<foundry.documents.BaseItem.SubType, Record<string, SheetClassConfig>>;
615
617
  };
616
618
 
617
619
  /**
@@ -619,7 +621,7 @@ declare global {
619
621
  */
620
622
  JournalEntry: {
621
623
  /** @defaultValue `JournalEntry` */
622
- documentClass: Document.ConfiguredClassForName<"JournalEntry">;
624
+ documentClass: Document.ImplementationClassFor<"JournalEntry">;
623
625
 
624
626
  /**
625
627
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -632,7 +634,7 @@ declare global {
632
634
  typeLabels?: Record<"base", string>;
633
635
 
634
636
  /** @defaultValue `Journal` */
635
- collection: typeof Journal;
637
+ collection: Journal.AnyConstructor;
636
638
 
637
639
  /** @defaultValue `[]` */
638
640
  compendiumIndexFields: string[];
@@ -732,20 +734,20 @@ declare global {
732
734
  */
733
735
  Macro: {
734
736
  /** @defaultValue `Macro` */
735
- documentClass: Document.ConfiguredClassForName<"Macro">;
737
+ documentClass: Document.ImplementationClassFor<"Macro">;
736
738
 
737
739
  /**
738
740
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
739
741
  */
740
- sheetClasses: Record<foundry.documents.BaseMacro.TypeNames, Record<string, SheetClassConfig>>;
742
+ sheetClasses: Record<foundry.documents.BaseMacro.SubType, Record<string, SheetClassConfig>>;
741
743
 
742
744
  /**
743
745
  * @remarks Initialized by `Localization#initialize`, is undefined until `i18nInit`
744
746
  */
745
- typeLabels?: Record<foundry.documents.BaseMacro.TypeNames, string>;
747
+ typeLabels?: Record<foundry.documents.BaseMacro.SubType, string>;
746
748
 
747
749
  /** @defaultValue `Macros` */
748
- collection: typeof Macros;
750
+ collection: Macros.AnyConstructor;
749
751
 
750
752
  /** @defaultValue `[]` */
751
753
  compendiumIndexFields: string[];
@@ -762,7 +764,7 @@ declare global {
762
764
  */
763
765
  Playlist: {
764
766
  /** @defaultValue `Playlist` */
765
- documentClass: Document.ConfiguredClassForName<"Playlist">;
767
+ documentClass: Document.ImplementationClassFor<"Playlist">;
766
768
 
767
769
  /**
768
770
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -775,7 +777,7 @@ declare global {
775
777
  typeLabels?: Record<"base", string>;
776
778
 
777
779
  /** @defaultValue `Playlists` */
778
- collection: typeof Playlists;
780
+ collection: Playlists.AnyConstructor;
779
781
 
780
782
  /** @defaultValue `[]` */
781
783
  compendiumIndexFields: string[];
@@ -795,7 +797,7 @@ declare global {
795
797
  */
796
798
  RollTable: {
797
799
  /** @defaultValue `RollTable` */
798
- documentClass: Document.ConfiguredClassForName<"RollTable">;
800
+ documentClass: Document.ImplementationClassFor<"RollTable">;
799
801
 
800
802
  /**
801
803
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -808,7 +810,7 @@ declare global {
808
810
  typeLabels?: Record<"base", string>;
809
811
 
810
812
  /** @defaultValue `RollTables` */
811
- collection: typeof RollTables;
813
+ collection: RollTables.AnyConstructor;
812
814
 
813
815
  /** @defaultValue `["formula"]` */
814
816
  compendiumIndexFields: string[];
@@ -831,7 +833,7 @@ declare global {
831
833
  */
832
834
  Scene: {
833
835
  /** @defaultValue `Scene` */
834
- documentClass: Document.ConfiguredClassForName<"Scene">;
836
+ documentClass: Document.ImplementationClassFor<"Scene">;
835
837
 
836
838
  /**
837
839
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -844,7 +846,7 @@ declare global {
844
846
  typeLabels?: Record<"base", string>;
845
847
 
846
848
  /** @defaultValue `Scenes` */
847
- collection: typeof Scenes;
849
+ collection: Scenes.AnyConstructor;
848
850
 
849
851
  /** @defaultValue `[]` */
850
852
  compendiumIndexFields: string[];
@@ -858,7 +860,7 @@ declare global {
858
860
 
859
861
  Setting: {
860
862
  /** @defaultValue `Setting` */
861
- documentClass: Document.ConfiguredClassForName<"Setting">;
863
+ documentClass: Document.ImplementationClassFor<"Setting">;
862
864
 
863
865
  /**
864
866
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -871,7 +873,7 @@ declare global {
871
873
  typeLabels?: Record<"base", string>;
872
874
 
873
875
  /** @defaultValue `WorldSettings` */
874
- collection: typeof WorldSettings;
876
+ collection: WorldSettings.AnyConstructor;
875
877
  };
876
878
 
877
879
  /**
@@ -879,7 +881,7 @@ declare global {
879
881
  */
880
882
  User: {
881
883
  /** @defaultValue `User` */
882
- documentClass: Document.ConfiguredClassForName<"User">;
884
+ documentClass: Document.ImplementationClassFor<"User">;
883
885
 
884
886
  /**
885
887
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -892,7 +894,7 @@ declare global {
892
894
  typeLabels?: Record<"base", string>;
893
895
 
894
896
  /** @defaultValue `Users` */
895
- collection: typeof Users;
897
+ collection: Users.AnyConstructor;
896
898
  };
897
899
 
898
900
  /**
@@ -914,7 +916,7 @@ declare global {
914
916
  /** @defaultValue `0xffffff` */
915
917
  brightestColor: number;
916
918
 
917
- chatBubblesClass: typeof ChatBubbles;
919
+ chatBubblesClass: ChatBubbles.AnyConstructor;
918
920
 
919
921
  /** @defaultValue `0.25` */
920
922
  darknessLightPenalty: number;
@@ -944,6 +946,7 @@ declare global {
944
946
 
945
947
  /**
946
948
  * The class used to render door control icons
949
+ * @remarks Not `AnyConstructor` because it's instantiated with a `Wall.Implementation` as its first argument
947
950
  */
948
951
  doorControlClass: typeof DoorControl;
949
952
 
@@ -959,14 +962,34 @@ declare global {
959
962
  /** @defaultValue `10000` */
960
963
  daylightToDarknessAnimationMS: number;
961
964
 
965
+ /**
966
+ * @defaultValue `foundry.canvas.sources.PointDarknessSource`
967
+ * @remarks Can't be `AnyConstructor` as it's instantiated expecting a compatible constructor
968
+ */
962
969
  darknessSourceClass: typeof foundry.canvas.sources.PointDarknessSource;
963
970
 
971
+ /**
972
+ * @defaultValue `foundry.canvas.sources.PointLightSource`
973
+ * @remarks Can't be `AnyConstructor` as it's instantiated expecting a compatible constructor
974
+ */
964
975
  lightSourceClass: typeof foundry.canvas.sources.PointLightSource;
965
976
 
977
+ /**
978
+ * @defaultValue `foundry.canvas.sources.GlobalLightSource`
979
+ * @remarks Can't be `AnyConstructor` as it's instantiated expecting a compatible constructor
980
+ */
966
981
  globalLightSourceClass: typeof foundry.canvas.sources.GlobalLightSource;
967
982
 
983
+ /**
984
+ * @defaultValue `foundry.canvas.sources.PointVisionSource`
985
+ * @remarks Can't be `AnyConstructor` as it's instantiated expecting a compatible constructor
986
+ */
968
987
  visionSourceClass: typeof foundry.canvas.sources.PointVisionSource;
969
988
 
989
+ /**
990
+ * @defaultValue `foundry.canvas.sources.PointSoundSource`
991
+ * @remarks Can't be `AnyConstructor` as it's instantiated via `new`
992
+ */
970
993
  soundSourceClass: typeof foundry.canvas.sources.PointSoundSource;
971
994
 
972
995
  groups: CONFIG.Canvas.Groups;
@@ -987,28 +1010,34 @@ declare global {
987
1010
  bright: number;
988
1011
  };
989
1012
 
990
- /** @defaultValue `FogManager` */
1013
+ /**
1014
+ * @defaultValue `FogManager`
1015
+ * @remarks Can't be `AnyConstructor` because Foundry assumes it can call `new` with the same arguments FogManager accepts
1016
+ */
991
1017
  fogManager: typeof FogManager;
992
1018
 
993
1019
  polygonBackends: {
994
1020
  /** @defaultValue `typeof ClockwiseSweepPolygon` */
995
- sight: typeof PointSourcePolygon;
1021
+ sight: PointSourcePolygon.AnyConstructor;
996
1022
  /** @defaultValue `typeof ClockwiseSweepPolygon` */
997
- light: typeof PointSourcePolygon;
1023
+ light: PointSourcePolygon.AnyConstructor;
998
1024
  /** @defaultValue `typeof ClockwiseSweepPolygon` */
999
- sound: typeof PointSourcePolygon;
1025
+ sound: PointSourcePolygon.AnyConstructor;
1000
1026
  /** @defaultValue `typeof ClockwiseSweepPolygon` */
1001
- move: typeof PointSourcePolygon;
1027
+ move: PointSourcePolygon.AnyConstructor;
1002
1028
  };
1003
1029
 
1004
1030
  /** @defaultValue `number` */
1005
1031
  darknessSourcePaddingMultiplier: number;
1006
1032
 
1007
- visibilityFilter: typeof VisibilityFilter;
1033
+ visibilityFilter: VisibilityFilter.AnyConstructor;
1008
1034
 
1009
- visualEffectsMaskingFilter: typeof VisualEffectsMaskingFilter;
1035
+ visualEffectsMaskingFilter: VisualEffectsMaskingFilter.AnyConstructor;
1010
1036
 
1011
- /** @defaultValue `Ruler` */
1037
+ /**
1038
+ * @defaultValue `Ruler`
1039
+ * @remarks Not `AnyConstructor` because it's instantiated with a `User.Implementation` as its first argument
1040
+ */
1012
1041
  rulerClass: typeof Ruler;
1013
1042
 
1014
1043
  /** @defaultValue `0.8` */
@@ -1020,21 +1049,109 @@ declare global {
1020
1049
  /** @defaultValue `4` */
1021
1050
  objectBorderThickness: number;
1022
1051
 
1023
- gridStyles: Record<string, CONFIG.Canvas.GridStyle>;
1052
+ gridStyles: {
1053
+ [key: string]: GridLayer.GridStyle;
1054
+
1055
+ /**
1056
+ * @defaultValue
1057
+ * ```js
1058
+ * {
1059
+ * label: "GRID.STYLES.SolidLines",
1060
+ * shaderClass: GridShader,
1061
+ * shaderOptions: {
1062
+ * style: 0
1063
+ * }
1064
+ * }
1065
+ * ```
1066
+ */
1067
+ solidLines: GridLayer.GridStyle;
1068
+
1069
+ /**
1070
+ * @defaultValue
1071
+ * ```js
1072
+ * {
1073
+ * label: "GRID.STYLES.DashedLines",
1074
+ * shaderClass: GridShader,
1075
+ * shaderOptions: {
1076
+ * style: 1
1077
+ * }
1078
+ * }
1079
+ * ```
1080
+ */
1081
+ dashedLines: GridLayer.GridStyle;
1082
+
1083
+ /**
1084
+ * @defaultValue
1085
+ * ```js
1086
+ * {
1087
+ * label: "GRID.STYLES.DottedLines",
1088
+ * shaderClass: GridShader,
1089
+ * shaderOptions: {
1090
+ * style: 0
1091
+ * }
1092
+ * }
1093
+ * ```
1094
+ */
1095
+ dottedLines: GridLayer.GridStyle;
1096
+
1097
+ /**
1098
+ * @defaultValue
1099
+ * ```js
1100
+ * {
1101
+ * label: "GRID.STYLES.SquarePoints",
1102
+ * shaderClass: GridShader,
1103
+ * shaderOptions: {
1104
+ * style: 0
1105
+ * }
1106
+ * }
1107
+ * ```
1108
+ */
1109
+ squarePoints: GridLayer.GridStyle;
1110
+
1111
+ /**
1112
+ * @defaultValue
1113
+ * ```js
1114
+ * {
1115
+ * label: "GRID.STYLES.DiamondPoints",
1116
+ * shaderClass: GridShader,
1117
+ * shaderOptions: {
1118
+ * style: 0
1119
+ * }
1120
+ * }
1121
+ * ```
1122
+ */
1123
+ diamondPoints: GridLayer.GridStyle;
1124
+
1125
+ /**
1126
+ * @defaultValue
1127
+ * ```js
1128
+ * {
1129
+ * label: "GRID.STYLES.RoundPoints",
1130
+ * shaderClass: GridShader,
1131
+ * shaderOptions: {
1132
+ * style: 0
1133
+ * }
1134
+ * }
1135
+ * ```
1136
+ */
1137
+ roundPoints: GridLayer.GridStyle;
1138
+ };
1139
+
1140
+ lightAnimations: {
1141
+ [key: string]: RenderedEffectSource.LightAnimationConfig;
1024
1142
 
1025
- lightAnimations: CONFIG.Canvas.LightSourceAnimationConfig & {
1026
1143
  flame: {
1027
1144
  /** @defaultValue `"LIGHT.AnimationFame"` */
1028
1145
  label: string;
1029
1146
 
1030
1147
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateFlickering` */
1031
- animation: CONFIG.Canvas.LightAnimationFunction;
1148
+ animation: BaseLightSource.LightAnimationFunction;
1032
1149
 
1033
1150
  /** @defaultValue `FlameIlluminationShader` */
1034
- illuminationShader: typeof AbstractBaseShader;
1151
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1035
1152
 
1036
1153
  /** @defaultValue `FlameColorationShader` */
1037
- colorationShader: typeof AbstractBaseShader;
1154
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1038
1155
  };
1039
1156
 
1040
1157
  torch: {
@@ -1042,13 +1159,13 @@ declare global {
1042
1159
  label: string;
1043
1160
 
1044
1161
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTorch` */
1045
- animation: CONFIG.Canvas.LightAnimationFunction;
1162
+ animation: BaseLightSource.LightAnimationFunction;
1046
1163
 
1047
1164
  /** @defaultValue `TorchIlluminationShader` */
1048
- illuminationShader: typeof AbstractBaseShader;
1165
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1049
1166
 
1050
1167
  /** @defaultValue `TorchColorationShader` */
1051
- colorationShader: typeof AbstractBaseShader;
1168
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1052
1169
  };
1053
1170
 
1054
1171
  revolving: {
@@ -1056,10 +1173,10 @@ declare global {
1056
1173
  label: string;
1057
1174
 
1058
1175
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1059
- animation: CONFIG.Canvas.LightAnimationFunction;
1176
+ animation: BaseLightSource.LightAnimationFunction;
1060
1177
 
1061
1178
  /** @defaultValue `RevolvingColorationShader` */
1062
- colorationShader: typeof AbstractBaseShader;
1179
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1063
1180
  };
1064
1181
 
1065
1182
  siren: {
@@ -1067,13 +1184,13 @@ declare global {
1067
1184
  label: string;
1068
1185
 
1069
1186
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTorch` */
1070
- animation: CONFIG.Canvas.LightAnimationFunction;
1187
+ animation: BaseLightSource.LightAnimationFunction;
1071
1188
 
1072
1189
  /** @defaultValue `SirenIlluminationShader` */
1073
- illuminationShader: typeof AbstractBaseShader;
1190
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1074
1191
 
1075
1192
  /** @defaultValue `SirenIlluminationShader` */
1076
- colorationShader: typeof AbstractBaseShader;
1193
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1077
1194
  };
1078
1195
 
1079
1196
  pulse: {
@@ -1081,13 +1198,13 @@ declare global {
1081
1198
  label: string;
1082
1199
 
1083
1200
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animatePulse` */
1084
- animation: CONFIG.Canvas.LightAnimationFunction;
1201
+ animation: BaseLightSource.LightAnimationFunction;
1085
1202
 
1086
1203
  /** @defaultValue `PulseIlluminationShader` */
1087
- illuminationShader: typeof AbstractBaseShader;
1204
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1088
1205
 
1089
1206
  /** @defaultValue `PulseColorationShader` */
1090
- colorationShader: typeof AbstractBaseShader;
1207
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1091
1208
  };
1092
1209
 
1093
1210
  chroma: {
@@ -1095,10 +1212,10 @@ declare global {
1095
1212
  label: string;
1096
1213
 
1097
1214
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1098
- animation: CONFIG.Canvas.LightAnimationFunction;
1215
+ animation: RenderedEffectSource.AnimationFunction;
1099
1216
 
1100
1217
  /** @defaultValue `ChromaColorationShader` */
1101
- colorationShader: typeof AbstractBaseShader;
1218
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1102
1219
  };
1103
1220
 
1104
1221
  wave: {
@@ -1106,13 +1223,13 @@ declare global {
1106
1223
  label: string;
1107
1224
 
1108
1225
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1109
- animation: CONFIG.Canvas.LightAnimationFunction;
1226
+ animation: RenderedEffectSource.AnimationFunction;
1110
1227
 
1111
1228
  /** @defaultValue `WaveIlluminationShader` */
1112
- illuminationShader: typeof AbstractBaseShader;
1229
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1113
1230
 
1114
1231
  /** @defaultValue `WaveColorationShader` */
1115
- colorationShader: typeof AbstractBaseShader;
1232
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1116
1233
  };
1117
1234
 
1118
1235
  fog: {
@@ -1120,10 +1237,10 @@ declare global {
1120
1237
  label: string;
1121
1238
 
1122
1239
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1123
- animation: CONFIG.Canvas.LightAnimationFunction;
1240
+ animation: RenderedEffectSource.AnimationFunction;
1124
1241
 
1125
1242
  /** @defaultValue `FogColorationShader` */
1126
- colorationShader: typeof AbstractBaseShader;
1243
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1127
1244
  };
1128
1245
 
1129
1246
  sunburst: {
@@ -1131,13 +1248,13 @@ declare global {
1131
1248
  label: string;
1132
1249
 
1133
1250
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1134
- animation: CONFIG.Canvas.LightAnimationFunction;
1251
+ animation: RenderedEffectSource.AnimationFunction;
1135
1252
 
1136
1253
  /** @defaultValue `SunburstIlluminationShader` */
1137
- illuminationShader: typeof AbstractBaseShader;
1254
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1138
1255
 
1139
1256
  /** @defaultValue `SunburstColorationShader` */
1140
- colorationShader: typeof AbstractBaseShader;
1257
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1141
1258
  };
1142
1259
 
1143
1260
  dome: {
@@ -1145,10 +1262,10 @@ declare global {
1145
1262
  label: string;
1146
1263
 
1147
1264
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1148
- animation: CONFIG.Canvas.LightAnimationFunction;
1265
+ animation: RenderedEffectSource.AnimationFunction;
1149
1266
 
1150
1267
  /** @defaultValue `LightDomeColorationShader` */
1151
- colorationShader: typeof AbstractBaseShader;
1268
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1152
1269
  };
1153
1270
 
1154
1271
  emanation: {
@@ -1156,10 +1273,10 @@ declare global {
1156
1273
  label: string;
1157
1274
 
1158
1275
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1159
- animation: CONFIG.Canvas.LightAnimationFunction;
1276
+ animation: RenderedEffectSource.AnimationFunction;
1160
1277
 
1161
1278
  /** @defaultValue `EmanationColorationShader` */
1162
- colorationShader: typeof AbstractBaseShader;
1279
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1163
1280
  };
1164
1281
 
1165
1282
  hexa: {
@@ -1167,10 +1284,10 @@ declare global {
1167
1284
  label: string;
1168
1285
 
1169
1286
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1170
- animation: CONFIG.Canvas.LightAnimationFunction;
1287
+ animation: RenderedEffectSource.AnimationFunction;
1171
1288
 
1172
1289
  /** @defaultValue `HexaDomeColorationShader` */
1173
- colorationShader: typeof AbstractBaseShader;
1290
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1174
1291
  };
1175
1292
 
1176
1293
  ghost: {
@@ -1178,13 +1295,13 @@ declare global {
1178
1295
  label: string;
1179
1296
 
1180
1297
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1181
- animation: CONFIG.Canvas.LightAnimationFunction;
1298
+ animation: RenderedEffectSource.AnimationFunction;
1182
1299
 
1183
1300
  /** @defaultValue `GhostLightIlluminationShader` */
1184
- illuminationShader: typeof AbstractBaseShader;
1301
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1185
1302
 
1186
1303
  /** @defaultValue `GhostLightColorationShader` */
1187
- colorationShader: typeof AbstractBaseShader;
1304
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1188
1305
  };
1189
1306
 
1190
1307
  energy: {
@@ -1192,10 +1309,10 @@ declare global {
1192
1309
  label: string;
1193
1310
 
1194
1311
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1195
- animation: CONFIG.Canvas.LightAnimationFunction;
1312
+ animation: RenderedEffectSource.AnimationFunction;
1196
1313
 
1197
1314
  /** @defaultValue `EnergyFieldColorationShader` */
1198
- colorationShader: typeof AbstractBaseShader;
1315
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1199
1316
  };
1200
1317
 
1201
1318
  vortex: {
@@ -1203,13 +1320,13 @@ declare global {
1203
1320
  label: string;
1204
1321
 
1205
1322
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1206
- animation: CONFIG.Canvas.LightAnimationFunction;
1323
+ animation: RenderedEffectSource.AnimationFunction;
1207
1324
 
1208
1325
  /** @defaultValue `VortexIlluminationShader` */
1209
- illuminationShader: typeof AbstractBaseShader;
1326
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1210
1327
 
1211
1328
  /** @defaultValue `VortexColorationShader` */
1212
- colorationShader: typeof AbstractBaseShader;
1329
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1213
1330
  };
1214
1331
 
1215
1332
  witchwave: {
@@ -1217,13 +1334,13 @@ declare global {
1217
1334
  label: string;
1218
1335
 
1219
1336
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1220
- animation: CONFIG.Canvas.LightAnimationFunction;
1337
+ animation: RenderedEffectSource.AnimationFunction;
1221
1338
 
1222
1339
  /** @defaultValue `BewitchingWaveIlluminationShader` */
1223
- illuminationShader: typeof AbstractBaseShader;
1340
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1224
1341
 
1225
1342
  /** @defaultValue `BewitchingWaveColorationShader` */
1226
- colorationShader: typeof AbstractBaseShader;
1343
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1227
1344
  };
1228
1345
 
1229
1346
  rainbowswirl: {
@@ -1231,10 +1348,10 @@ declare global {
1231
1348
  label: string;
1232
1349
 
1233
1350
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1234
- animation: CONFIG.Canvas.LightAnimationFunction;
1351
+ animation: RenderedEffectSource.AnimationFunction;
1235
1352
 
1236
1353
  /** @defaultValue `SwirlingRainbowColorationShader` */
1237
- colorationShader: typeof AbstractBaseShader;
1354
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1238
1355
  };
1239
1356
 
1240
1357
  radialrainbow: {
@@ -1242,10 +1359,10 @@ declare global {
1242
1359
  label: string;
1243
1360
 
1244
1361
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1245
- animation: CONFIG.Canvas.LightAnimationFunction;
1362
+ animation: RenderedEffectSource.AnimationFunction;
1246
1363
 
1247
1364
  /** @defaultValue `RadialRainbowColorationShader` */
1248
- colorationShader: typeof AbstractBaseShader;
1365
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1249
1366
  };
1250
1367
 
1251
1368
  fairy: {
@@ -1253,20 +1370,57 @@ declare global {
1253
1370
  label: string;
1254
1371
 
1255
1372
  /** @defaultValue `foundry.canvas.sources.LightSource.prototype.animateTime` */
1256
- animation: CONFIG.Canvas.LightAnimationFunction;
1373
+ animation: RenderedEffectSource.AnimationFunction;
1257
1374
 
1258
1375
  /** @defaultValue `FairyLightIlluminationShader` */
1259
- illuminationShader: typeof AbstractBaseShader;
1376
+ illuminationShader: AdaptiveIlluminationShader.AnyConstructor;
1260
1377
 
1261
1378
  /** @defaultValue `FairyLightColorationShader` */
1262
- colorationShader: typeof AbstractBaseShader;
1379
+ colorationShader: AdaptiveColorationShader.AnyConstructor;
1263
1380
  };
1264
1381
  };
1265
1382
 
1266
- darknessAnimations: CONFIG.Canvas.DarknessSourceAnimationConfig;
1383
+ darknessAnimations: {
1384
+ [key: string]: RenderedEffectSource.DarknessAnimationConfig;
1385
+
1386
+ magicalGloom: {
1387
+ /** @defaultValue `"LIGHT.AnimationMagicalGloom"` */
1388
+ label: string;
1389
+
1390
+ /** @defaultValue `foundry.canvas.sources.PointDarknessSource.prototype.animateTime` */
1391
+ animation: RenderedEffectSource.AnimationFunction;
1392
+
1393
+ /** @defaultValue `MagicalGloomDarknessShader` */
1394
+ darknessShader: AdaptiveDarknessShader.AnyConstructor;
1395
+ };
1396
+
1397
+ roiling: {
1398
+ /** @defaultValue `"LIGHT.AnimationRoilingMass"` */
1399
+ label: string;
1400
+
1401
+ /** @defaultValue `foundry.canvas.sources.PointDarknessSource.prototype.animateTime` */
1402
+ animation: RenderedEffectSource.AnimationFunction;
1403
+
1404
+ /** @defaultValue `RoilingDarknessShader` */
1405
+ darknessShader: AdaptiveDarknessShader.AnyConstructor;
1406
+ };
1407
+
1408
+ hole: {
1409
+ /** @defaultValue `"LIGHT.AnimationBlackHole"` */
1410
+ label: string;
1411
+
1412
+ /** @defaultValue `foundry.canvas.sources.PointDarknessSource.prototype.animateTime` */
1413
+ animation: RenderedEffectSource.AnimationFunction;
1414
+
1415
+ /** @defaultValue `BlackHoleDarknessShader` */
1416
+ darknessShader: AdaptiveDarknessShader.AnyConstructor;
1417
+ };
1418
+ };
1267
1419
 
1268
1420
  /**
1269
1421
  * A registry of Scenes which are managed by a specific SceneManager class.
1422
+ * @remarks Keys are Scene IDs
1423
+ * @privateRemarks Can't be `AnyConstructor` because it's instantiated expecting a compatible constructor
1270
1424
  */
1271
1425
  managedScenes: Record<string, typeof foundry.canvas.SceneManager>;
1272
1426
 
@@ -1558,7 +1712,7 @@ declare global {
1558
1712
  * Available Weather Effects implementations
1559
1713
  */
1560
1714
  weatherEffects: {
1561
- [key: string]: CONFIG.WeatherAmbienceConfiguration;
1715
+ [key: string]: WeatherEffects.AmbienceConfiguration;
1562
1716
 
1563
1717
  /**
1564
1718
  * @defaultValue
@@ -1573,7 +1727,7 @@ declare global {
1573
1727
  * }
1574
1728
  * ```
1575
1729
  */
1576
- leaves: CONFIG.WeatherAmbienceConfiguration;
1730
+ leaves: WeatherEffects.AmbienceConfiguration;
1577
1731
 
1578
1732
  /**
1579
1733
  * @defaultValue
@@ -1601,7 +1755,7 @@ declare global {
1601
1755
  * }
1602
1756
  * ```
1603
1757
  */
1604
- rain: CONFIG.WeatherAmbienceConfiguration;
1758
+ rain: WeatherEffects.AmbienceConfiguration;
1605
1759
 
1606
1760
  /**
1607
1761
  * @defaultValue
@@ -1642,7 +1796,7 @@ declare global {
1642
1796
  * }
1643
1797
  * ```
1644
1798
  */
1645
- rainStorm: CONFIG.WeatherAmbienceConfiguration;
1799
+ rainStorm: WeatherEffects.AmbienceConfiguration;
1646
1800
 
1647
1801
  /**
1648
1802
  * @defaultValue
@@ -1667,7 +1821,7 @@ declare global {
1667
1821
  * }
1668
1822
  * ```
1669
1823
  */
1670
- fog: CONFIG.WeatherAmbienceConfiguration;
1824
+ fog: WeatherEffects.AmbienceConfiguration;
1671
1825
 
1672
1826
  /**
1673
1827
  * @defaultValue
@@ -1693,7 +1847,7 @@ declare global {
1693
1847
  * }
1694
1848
  * ```
1695
1849
  * */
1696
- snow: CONFIG.WeatherAmbienceConfiguration;
1850
+ snow: WeatherEffects.AmbienceConfiguration;
1697
1851
 
1698
1852
  /**
1699
1853
  * @defaultValue
@@ -1731,7 +1885,7 @@ declare global {
1731
1885
  * }
1732
1886
  * ```
1733
1887
  */
1734
- blizzard: CONFIG.WeatherAmbienceConfiguration;
1888
+ blizzard: WeatherEffects.AmbienceConfiguration;
1735
1889
  };
1736
1890
 
1737
1891
  /**
@@ -2075,24 +2229,24 @@ declare global {
2075
2229
  */
2076
2230
  ActiveEffect: {
2077
2231
  /** @defaultValue `ActiveEffect` */
2078
- documentClass: Document.ConfiguredClassForName<"ActiveEffect">;
2232
+ documentClass: Document.ImplementationClassFor<"ActiveEffect">;
2079
2233
 
2080
2234
  /**
2081
2235
  * @defaultValue `{}`
2082
2236
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
2083
2237
  */
2084
- dataModels: Record<string, typeof DataModel<any, ChatMessage>>;
2238
+ dataModels: Record<string, typeof DataModel<any, ActiveEffect.Implementation>>;
2085
2239
 
2086
2240
  /**
2087
2241
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2088
2242
  */
2089
- sheetClasses: Record<foundry.documents.BaseActiveEffect.TypeNames, Record<string, SheetClassConfig>>;
2243
+ sheetClasses: Record<foundry.documents.BaseActiveEffect.SubType, Record<string, SheetClassConfig>>;
2090
2244
 
2091
2245
  /**
2092
2246
  * @defaultValue `{}`
2093
2247
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
2094
2248
  */
2095
- typeLabels: Record<foundry.documents.BaseActiveEffect.TypeNames, string>;
2249
+ typeLabels: Record<foundry.documents.BaseActiveEffect.SubType, string>;
2096
2250
 
2097
2251
  /** @defaultValue `{}` */
2098
2252
  typeIcons: Record<string, string>;
@@ -2112,7 +2266,7 @@ declare global {
2112
2266
  */
2113
2267
  ActorDelta: {
2114
2268
  /** @defaultValue `ActorDelta` */
2115
- documentClass: Document.ConfiguredClassForName<"ActorDelta">;
2269
+ documentClass: Document.ImplementationClassFor<"ActorDelta">;
2116
2270
 
2117
2271
  /**
2118
2272
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2130,24 +2284,24 @@ declare global {
2130
2284
  */
2131
2285
  Card: {
2132
2286
  /** @defaultValue `Card` */
2133
- documentClass: Document.ConfiguredClassForName<"Card">;
2287
+ documentClass: Document.ImplementationClassFor<"Card">;
2134
2288
 
2135
2289
  /**
2136
2290
  * @defaultValue `{}`
2137
2291
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
2138
2292
  */
2139
- dataModels: Record<string, typeof DataModel<any, Card>>;
2293
+ dataModels: Record<string, typeof DataModel<any, Card.Implementation>>;
2140
2294
 
2141
2295
  /**
2142
2296
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2143
2297
  */
2144
- sheetClasses: Record<foundry.documents.BaseCard.TypeNames, Record<string, SheetClassConfig>>;
2298
+ sheetClasses: Record<foundry.documents.BaseCard.SubType, Record<string, SheetClassConfig>>;
2145
2299
 
2146
2300
  /**
2147
2301
  * @defaultValue `{}`
2148
2302
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
2149
2303
  */
2150
- typeLabels: Record<foundry.documents.BaseCard.TypeNames, string>;
2304
+ typeLabels: Record<foundry.documents.BaseCard.SubType, string>;
2151
2305
 
2152
2306
  /** @defaultValue `{}` */
2153
2307
  typeIcons: Record<string, string>;
@@ -2158,39 +2312,39 @@ declare global {
2158
2312
  */
2159
2313
  TableResult: {
2160
2314
  /** @defaultValue `TableResult` */
2161
- documentClass: Document.ConfiguredClassForName<"TableResult">;
2315
+ documentClass: Document.ImplementationClassFor<"TableResult">;
2162
2316
 
2163
2317
  /**
2164
2318
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2165
2319
  */
2166
- sheetClasses: Record<foundry.documents.BaseTableResult.TypeNames, Record<string, SheetClassConfig>>;
2320
+ sheetClasses: Record<foundry.documents.BaseTableResult.SubType, Record<string, SheetClassConfig>>;
2167
2321
 
2168
2322
  /**
2169
2323
  * @remarks Initialized by `Localization#initialize`, is undefined until `i18nInit`
2170
2324
  */
2171
- typeLabels?: Record<foundry.documents.BaseTableResult.TypeNames, string>;
2325
+ typeLabels?: Record<foundry.documents.BaseTableResult.SubType, string>;
2172
2326
  };
2173
2327
 
2174
2328
  JournalEntryPage: {
2175
2329
  /** @defaultValue `JournalEntryPage` */
2176
- documentClass: Document.ConfiguredClassForName<"JournalEntryPage">;
2330
+ documentClass: Document.ImplementationClassFor<"JournalEntryPage">;
2177
2331
 
2178
2332
  /**
2179
2333
  * @defaultValue `{}`
2180
2334
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
2181
2335
  */
2182
- dataModels: Record<string, typeof DataModel<any, JournalEntryPage>>;
2336
+ dataModels: Record<string, typeof DataModel<any, JournalEntryPage.Implementation>>;
2183
2337
 
2184
2338
  /**
2185
2339
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2186
2340
  */
2187
- sheetClasses: Record<foundry.documents.BaseJournalEntryPage.TypeNames, Record<string, SheetClassConfig>>;
2341
+ sheetClasses: Record<foundry.documents.BaseJournalEntryPage.SubType, Record<string, SheetClassConfig>>;
2188
2342
 
2189
2343
  /**
2190
2344
  * @defaultValue `{}`
2191
2345
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
2192
2346
  */
2193
- typeLabels: Record<foundry.documents.BaseJournalEntryPage.TypeNames, string>;
2347
+ typeLabels: Record<foundry.documents.BaseJournalEntryPage.SubType, string>;
2194
2348
 
2195
2349
  typeIcons: {
2196
2350
  [type: string]: string;
@@ -2217,7 +2371,7 @@ declare global {
2217
2371
  */
2218
2372
  PlaylistSound: {
2219
2373
  /** @defaultValue `PlaylistSound` */
2220
- documentClass: Document.ConfiguredClassForName<"PlaylistSound">;
2374
+ documentClass: Document.ImplementationClassFor<"PlaylistSound">;
2221
2375
 
2222
2376
  /**
2223
2377
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2235,7 +2389,7 @@ declare global {
2235
2389
  */
2236
2390
  AmbientLight: {
2237
2391
  /** @defaultValue `AmbientLightDocument` */
2238
- documentClass: Document.ConfiguredClassForName<"AmbientLight">;
2392
+ documentClass: Document.ImplementationClassFor<"AmbientLight">;
2239
2393
 
2240
2394
  /**
2241
2395
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2247,11 +2401,12 @@ declare global {
2247
2401
  */
2248
2402
  typeLabels?: Record<"base", string>;
2249
2403
 
2250
- /** @defaultValue `AmbientLightDocument` */
2404
+ /** @defaultValue `typeof AmbientLightDocument` */
2405
+ // eslint-disable-next-line no-restricted-syntax
2251
2406
  objectClass: ConfiguredObjectClassOrDefault<typeof AmbientLight>;
2252
2407
 
2253
- /** @defaultValue `LightingLayer` */
2254
- layerClass: typeof LightingLayer;
2408
+ /** @defaultValue `typeof LightingLayer` */
2409
+ layerClass: LightingLayer.AnyConstructor;
2255
2410
  };
2256
2411
 
2257
2412
  /**
@@ -2259,7 +2414,7 @@ declare global {
2259
2414
  */
2260
2415
  AmbientSound: {
2261
2416
  /** @defaultValue `AmbientSoundDocument` */
2262
- documentClass: Document.ConfiguredClassForName<"AmbientSound">;
2417
+ documentClass: Document.ImplementationClassFor<"AmbientSound">;
2263
2418
 
2264
2419
  /**
2265
2420
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2271,11 +2426,12 @@ declare global {
2271
2426
  */
2272
2427
  typeLabels?: Record<"base", string>;
2273
2428
 
2274
- /** @defaultValue `AmbientSound` */
2429
+ /** @defaultValue `typeof AmbientSound` */
2430
+ // eslint-disable-next-line no-restricted-syntax
2275
2431
  objectClass: ConfiguredObjectClassOrDefault<typeof AmbientSound>;
2276
2432
 
2277
- /** @defaultValue `SoundsLayer` */
2278
- layerClass: typeof SoundsLayer;
2433
+ /** @defaultValue `typeof SoundsLayer` */
2434
+ layerClass: SoundsLayer.AnyConstructor;
2279
2435
  };
2280
2436
 
2281
2437
  /**
@@ -2283,24 +2439,24 @@ declare global {
2283
2439
  */
2284
2440
  Combatant: {
2285
2441
  /** @defaultValue `Combatant` */
2286
- documentClass: Document.ConfiguredClassForName<"Combatant">;
2442
+ documentClass: Document.ImplementationClassFor<"Combatant">;
2287
2443
 
2288
2444
  /**
2289
2445
  * @defaultValue `{}`
2290
2446
  * @remarks `TypeDataModel` is preferred to `DataModel` per core Foundry team
2291
2447
  */
2292
- dataModels: Record<string, typeof DataModel<any, ChatMessage>>;
2448
+ dataModels: Record<string, typeof DataModel<any, Combatant.Implementation>>;
2293
2449
 
2294
2450
  /**
2295
2451
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2296
2452
  */
2297
- sheetClasses: Record<foundry.documents.BaseCombatant.TypeNames, Record<string, SheetClassConfig>>;
2453
+ sheetClasses: Record<foundry.documents.BaseCombatant.SubType, Record<string, SheetClassConfig>>;
2298
2454
 
2299
2455
  /**
2300
2456
  * @defaultValue `{}`
2301
2457
  * @remarks Initialized by `Localization#initialize`, is an empty object until `i18nInit`
2302
2458
  */
2303
- typeLabels: Record<foundry.documents.BaseCombatant.TypeNames, string>;
2459
+ typeLabels: Record<foundry.documents.BaseCombatant.SubType, string>;
2304
2460
 
2305
2461
  /** @defaultValue `{}` */
2306
2462
  typeIcons: Record<string, string>;
@@ -2311,7 +2467,7 @@ declare global {
2311
2467
  */
2312
2468
  Drawing: {
2313
2469
  /** @defaultValue `DrawingDocument` */
2314
- documentClass: Document.ConfiguredClassForName<"Drawing">;
2470
+ documentClass: Document.ImplementationClassFor<"Drawing">;
2315
2471
 
2316
2472
  /**
2317
2473
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2323,13 +2479,14 @@ declare global {
2323
2479
  */
2324
2480
  typeLabels?: Record<"base", string>;
2325
2481
 
2326
- /** @defaultValue `Drawing` */
2482
+ /** @defaultValue `typeof Drawing` */
2483
+ // eslint-disable-next-line no-restricted-syntax
2327
2484
  objectClass: ConfiguredObjectClassOrDefault<typeof Drawing>;
2328
2485
 
2329
- /** @defaultValue `DrawingsLayer` */
2486
+ /** @defaultValue `typeof DrawingsLayer` */
2330
2487
  layerClass: typeof DrawingsLayer;
2331
2488
 
2332
- /** @defaultValue `DrawingHUD` */
2489
+ /** @defaultValue `typeof DrawingHUD` */
2333
2490
  hudClass: typeof DrawingHUD;
2334
2491
  };
2335
2492
 
@@ -2360,7 +2517,7 @@ declare global {
2360
2517
  };
2361
2518
 
2362
2519
  /** @defaultValue `MeasuredTemplateDocument` */
2363
- documentClass: Document.ConfiguredClassForName<"MeasuredTemplate">;
2520
+ documentClass: Document.ImplementationClassFor<"MeasuredTemplate">;
2364
2521
 
2365
2522
  /**
2366
2523
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2372,10 +2529,11 @@ declare global {
2372
2529
  */
2373
2530
  typeLabels?: Record<"base", string>;
2374
2531
 
2375
- /** @defaultValue `MeasuredTemplate` */
2532
+ /** @defaultValue `typeof MeasuredTemplate` */
2533
+ // eslint-disable-next-line no-restricted-syntax
2376
2534
  objectClass: ConfiguredObjectClassOrDefault<typeof MeasuredTemplate>;
2377
2535
 
2378
- /** @defaultValue `TemplateLayer` */
2536
+ /** @defaultValue `typeof TemplateLayer` */
2379
2537
  layerClass: typeof TemplateLayer;
2380
2538
  };
2381
2539
 
@@ -2384,7 +2542,7 @@ declare global {
2384
2542
  */
2385
2543
  Note: {
2386
2544
  /** @defaultValue `NoteDocument` */
2387
- documentClass: Document.ConfiguredClassForName<"Note">;
2545
+ documentClass: Document.ImplementationClassFor<"Note">;
2388
2546
 
2389
2547
  /**
2390
2548
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2396,21 +2554,42 @@ declare global {
2396
2554
  */
2397
2555
  typeLabels?: Record<"base", string>;
2398
2556
 
2399
- /** @defaultValue `Note` */
2557
+ /** @defaultValue `typeof Note` */
2558
+ // eslint-disable-next-line no-restricted-syntax
2400
2559
  objectClass: ConfiguredObjectClassOrDefault<typeof Note>;
2401
2560
 
2402
- /** @defaultValue `NotesLayer` */
2403
- layerClass: typeof NotesLayer;
2561
+ /** @defaultValue `typeof NotesLayer` */
2562
+ layerClass: NotesLayer.AnyConstructor;
2404
2563
  };
2405
2564
 
2406
- // TODO: Regions
2565
+ Region: {
2566
+ /** @defaultValue `RegionDocument` */
2567
+ documentClass: Document.ImplementationClassFor<"Region">;
2568
+
2569
+ /** @defaultValue `Region` */
2570
+ // eslint-disable-next-line no-restricted-syntax
2571
+ objectClass: ConfiguredObjectClassOrDefault<typeof Region>;
2572
+
2573
+ /** @defaultValue `RegionLayer` */
2574
+ layerClass: RegionLayer.AnyConstructor;
2575
+
2576
+ /**
2577
+ * @remarks added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
2578
+ */
2579
+ sheetClasses: Record<"base", Record<string, SheetClassConfig>>;
2580
+
2581
+ /**
2582
+ * @remarks Initialized by `Localization#initialize`, is undefined until `i18nInit`
2583
+ */
2584
+ typeLabels?: Record<"base", string>;
2585
+ };
2407
2586
 
2408
2587
  /**
2409
2588
  * Configuration for the Tile embedded document type and its representation on the game Canvas
2410
2589
  */
2411
2590
  Tile: {
2412
2591
  /** @defaultValue `TileDocument` */
2413
- documentClass: Document.ConfiguredClassForName<"Tile">;
2592
+ documentClass: Document.ImplementationClassFor<"Tile">;
2414
2593
 
2415
2594
  /**
2416
2595
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2422,14 +2601,15 @@ declare global {
2422
2601
  */
2423
2602
  typeLabels?: Record<"base", string>;
2424
2603
 
2425
- /** @defaultValue `Tile` */
2604
+ /** @defaultValue `typeof Tile` */
2605
+ // eslint-disable-next-line no-restricted-syntax
2426
2606
  objectClass: ConfiguredObjectClassOrDefault<typeof Tile>;
2427
2607
 
2428
- /** @defaultValue `TilesLayer` */
2429
- layerClass: typeof TilesLayer;
2608
+ /** @defaultValue `typeof TilesLayer` */
2609
+ layerClass: TilesLayer.AnyConstructor;
2430
2610
 
2431
- /** @defaultValue `TileHUD` */
2432
- hudClass: typeof TileHUD;
2611
+ /** @defaultValue `typeof TileHUD` */
2612
+ hudClass: TileHUD.AnyConstructor;
2433
2613
  };
2434
2614
 
2435
2615
  /**
@@ -2437,7 +2617,7 @@ declare global {
2437
2617
  */
2438
2618
  Token: {
2439
2619
  /** @defaultValue `TokenDocument` */
2440
- documentClass: Document.ConfiguredClassForName<"Token">;
2620
+ documentClass: Document.ImplementationClassFor<"Token">;
2441
2621
 
2442
2622
  /**
2443
2623
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2449,26 +2629,28 @@ declare global {
2449
2629
  */
2450
2630
  typeLabels?: Record<"base", string>;
2451
2631
 
2452
- /** @defaultValue `Token` */
2632
+ /** @defaultValue `typeof Token` */
2633
+ // eslint-disable-next-line no-restricted-syntax
2453
2634
  objectClass: ConfiguredObjectClassOrDefault<typeof Token>;
2454
2635
 
2455
- /** @defaultValue `TokenLayer` */
2456
- layerClass: typeof TokenLayer;
2636
+ /** @defaultValue `typeof TokenLayer` */
2637
+ layerClass: TokenLayer.AnyConstructor;
2457
2638
 
2458
- /** @defaultValue `TokenConfig` */
2459
- prototypeSheetClass: typeof TokenConfig;
2639
+ /** @defaultValue `typeof TokenConfig` */
2640
+ prototypeSheetClass: TokenConfig.AnyConstructor;
2460
2641
 
2461
- /** @defaultValue `TokenHUD` */
2462
- hudClass: typeof TokenHUD;
2642
+ /** @defaultValue `typeof TokenHUD` */
2643
+ hudClass: TokenHUD.AnyConstructor;
2463
2644
 
2464
2645
  /** @defaultValue `"TOKEN.Adjectives"` */
2465
2646
  adjectivesPrefix: string;
2466
2647
 
2467
2648
  /**
2468
2649
  * @defaultValue `foundry.canvas.tokens.TokenRingConfig`
2469
- * @remarks `"ring property is initialized in foundry.canvas.tokens.TokenRingConfig.initialize"`
2650
+ * @remarks Foundry leaves a comment claiming `"ring property is initialized in foundry.canvas.tokens.TokenRingConfig.initialize"`,
2651
+ * and while that's true, it's _instantiated_ here in `config.js` via defineProperty (`enumerable: true`)
2470
2652
  */
2471
- ring?: foundry.canvas.tokens.TokenRingConfig;
2653
+ readonly ring: foundry.canvas.tokens.TokenRingConfig;
2472
2654
  };
2473
2655
 
2474
2656
  /**
@@ -2476,7 +2658,7 @@ declare global {
2476
2658
  */
2477
2659
  Wall: {
2478
2660
  /** @defaultValue `WallDocument` */
2479
- documentClass: Document.ConfiguredClassForName<"Wall">;
2661
+ documentClass: Document.ImplementationClassFor<"Wall">;
2480
2662
 
2481
2663
  /**
2482
2664
  * @remarks Added by `DocumentSheetConfig._registerDefaultSheets` in `tail.js`
@@ -2488,11 +2670,12 @@ declare global {
2488
2670
  */
2489
2671
  typeLabels?: Record<"base", string>;
2490
2672
 
2491
- /** @defaultValue `Wall` */
2673
+ /** @defaultValue `typeof Wall` */
2674
+ // eslint-disable-next-line no-restricted-syntax
2492
2675
  objectClass: ConfiguredObjectClassOrDefault<typeof Wall>;
2493
2676
 
2494
- /** @defaultValue `WallsLayer` */
2495
- layerClass: typeof WallsLayer;
2677
+ /** @defaultValue `typeof WallsLayer` */
2678
+ layerClass: WallsLayer.AnyConstructor;
2496
2679
 
2497
2680
  /** @defaultValue `1` */
2498
2681
  thresholdAttenuationMultiplier: number;
@@ -2776,9 +2959,9 @@ declare global {
2776
2959
  * An enumeration of sound effects which can be applied to Sound instances.
2777
2960
  */
2778
2961
  soundEffects: {
2779
- lowPass: { label: string; effectClass: typeof AudioNode };
2780
- highpass: { label: string; effectClass: typeof AudioNode };
2781
- reverb: { label: string; effectClass: typeof AudioNode };
2962
+ lowPass: { label: string; effectClass: AudioNode.AnyConstructor };
2963
+ highpass: { label: string; effectClass: AudioNode.AnyConstructor };
2964
+ reverb: { label: string; effectClass: AudioNode.AnyConstructor };
2782
2965
  };
2783
2966
 
2784
2967
  /**
@@ -2802,7 +2985,7 @@ declare global {
2802
2985
  */
2803
2986
  WebRTC: {
2804
2987
  /** @defaultValue `SimplePeerAVClient` */
2805
- clientClass: GetKey<WebRTCConfig, "clientClass", typeof SimplePeerAVClient>;
2988
+ clientClass: GetKey<WebRTCConfig, "clientClass", SimplePeerAVClient.AnyConstructor>;
2806
2989
 
2807
2990
  /** @defaultValue `50` */
2808
2991
  detectPeerVolumeInterval: number;
@@ -2832,67 +3015,67 @@ declare global {
2832
3015
  namespace CONFIG {
2833
3016
  interface UI {
2834
3017
  /** @defaultValue `MainMenu` */
2835
- menu: typeof MainMenu;
3018
+ menu: MainMenu.AnyConstructor;
2836
3019
 
2837
3020
  /** @defaultValue `Sidebar` */
2838
- sidebar: typeof Sidebar;
3021
+ sidebar: Sidebar.AnyConstructor;
2839
3022
 
2840
3023
  /** @defaultValue `Pause` */
2841
- pause: typeof Pause;
3024
+ pause: Pause.AnyConstructor;
2842
3025
 
2843
3026
  /** @defaultValue `SceneNavigation` */
2844
- nav: typeof SceneNavigation;
3027
+ nav: SceneNavigation.AnyConstructor;
2845
3028
 
2846
3029
  /** @defaultValue `Notifications` */
2847
- notifications: typeof Notifications;
3030
+ notifications: Notifications.AnyConstructor;
2848
3031
 
2849
3032
  /** @defaultValue `ActorDirectory` */
2850
- actors: typeof ActorDirectory;
3033
+ actors: ActorDirectory.AnyConstructor;
2851
3034
 
2852
3035
  /** @defaultValue `CardsDirectory` */
2853
- cards: typeof CardsDirectory;
3036
+ cards: CardsDirectory.AnyConstructor;
2854
3037
 
2855
3038
  /** @defaultValue `ChatLog` */
2856
- chat: typeof ChatLog;
3039
+ chat: ChatLog.AnyConstructor;
2857
3040
 
2858
3041
  /** @defaultValue `CombatTracker` */
2859
- combat: typeof CombatTracker;
3042
+ combat: CombatTracker.AnyConstructor;
2860
3043
 
2861
3044
  /** @defaultValue `CompendiumDirectory` */
2862
- compendium: typeof CompendiumDirectory;
3045
+ compendium: CompendiumDirectory.AnyConstructor;
2863
3046
 
2864
3047
  /** @defaultValue `SceneControls` */
2865
- controls: typeof SceneControls;
3048
+ controls: SceneControls.AnyConstructor;
2866
3049
 
2867
3050
  /** @defaultValue `Hotbar` */
2868
- hotbar: typeof Hotbar;
3051
+ hotbar: Hotbar.AnyConstructor;
2869
3052
 
2870
3053
  /** @defaultValue `ItemDirectory` */
2871
- items: typeof ItemDirectory;
3054
+ items: ItemDirectory.AnyConstructor;
2872
3055
 
2873
3056
  /** @defaultValue `JournalDirectory` */
2874
- journal: typeof JournalDirectory;
3057
+ journal: JournalDirectory.AnyConstructor;
2875
3058
 
2876
3059
  /** @defaultValue `MacroDirectory` */
2877
- macros: typeof MacroDirectory;
3060
+ macros: MacroDirectory.AnyConstructor;
2878
3061
 
2879
3062
  /** @defaultValue `PlayerList` */
2880
- players: typeof PlayerList;
3063
+ players: PlayerList.AnyConstructor;
2881
3064
 
2882
3065
  /** @defaultValue `PlaylistDirectory` */
2883
- playlists: typeof PlaylistDirectory;
3066
+ playlists: PlaylistDirectory.AnyConstructor;
2884
3067
 
2885
3068
  /** @defaultValue `SceneDirectory` */
2886
- scenes: typeof SceneDirectory;
3069
+ scenes: SceneDirectory.AnyConstructor;
2887
3070
 
2888
3071
  /** @defaultValue `Settings` */
2889
- settings: typeof Settings;
3072
+ settings: Settings.AnyConstructor;
2890
3073
 
2891
3074
  /** @defaultValue `RollTableDirectory` */
2892
- tables: typeof RollTableDirectory;
3075
+ tables: RollTableDirectory.AnyConstructor;
2893
3076
 
2894
3077
  /** @defaultValue `CameraViews` */
2895
- webrtc: typeof CameraViews;
3078
+ webrtc: CameraViews.AnyConstructor;
2896
3079
  }
2897
3080
 
2898
3081
  namespace Canvas {
@@ -2924,97 +3107,56 @@ declare global {
2924
3107
 
2925
3108
  interface Layers {
2926
3109
  /** @defaultValue `{ layerClass: WeatherLayer, group: "primary" }` */
2927
- weather: LayerDefinition<typeof WeatherEffects>;
3110
+ weather: LayerDefinition<typeof WeatherEffects, "primary">;
2928
3111
 
2929
3112
  /** @defaultValue `{ layerClass: GridLayer, group: "interface" }` */
2930
- grid: LayerDefinition<typeof GridLayer>;
3113
+ grid: LayerDefinition<typeof GridLayer, "interface">;
2931
3114
 
2932
3115
  /** @defaultValue `{ layerClass: RegionLayer, group: "interface" }` */
2933
- // regions: LayerDefinition<typeof RegionLayer>;
3116
+ // regions: LayerDefinition<typeof RegionLayer, "interface">;
2934
3117
 
2935
3118
  /** @defaultValue `{ layerClass: DrawingsLayer, group: "interface" }` */
2936
- drawings: LayerDefinition<typeof DrawingsLayer>;
3119
+ drawings: LayerDefinition<typeof DrawingsLayer, "interface">;
2937
3120
 
2938
3121
  /** @defaultValue `{ layerClass: TemplateLayer, group: "interface" }` */
2939
- templates: LayerDefinition<typeof TemplateLayer>;
3122
+ templates: LayerDefinition<typeof TemplateLayer, "interface">;
2940
3123
 
2941
3124
  /** @defaultValue `{ layerClass: TokenLayer, group: "interface" }` */
2942
- tiles: LayerDefinition<typeof TilesLayer>;
3125
+ tiles: LayerDefinition<typeof TilesLayer, "interface">;
2943
3126
 
2944
3127
  /** @defaultValue `{ layerClass: WallsLayer, group: "interface" }` */
2945
- walls: LayerDefinition<typeof WallsLayer>;
3128
+ walls: LayerDefinition<typeof WallsLayer, "interface">;
2946
3129
 
2947
3130
  /** @defaultValue `{ layerClass: TokenLayer, group: "interface" }` */
2948
- tokens: LayerDefinition<typeof TokenLayer>;
3131
+ tokens: LayerDefinition<typeof TokenLayer, "interface">;
2949
3132
 
2950
3133
  /** @defaultValue `{ layerClass: SoundsLayer, group: "interface" }` */
2951
- sounds: LayerDefinition<typeof SoundsLayer>;
3134
+ sounds: LayerDefinition<typeof SoundsLayer, "interface">;
2952
3135
 
2953
3136
  /** @defaultValue `{ layerClass: LightingLayer, group: "interface" }` */
2954
- lighting: LayerDefinition<typeof LightingLayer>;
3137
+ lighting: LayerDefinition<typeof LightingLayer, "interface">;
2955
3138
 
2956
3139
  /** @defaultValue `{ layerClass: NotesLayer, group: "interface" }` */
2957
- notes: LayerDefinition<typeof NotesLayer>;
3140
+ notes: LayerDefinition<typeof NotesLayer, "interface">;
2958
3141
 
2959
3142
  /** @defaultValue `{ layerClass: ControlsLayer, group: "interface" }` */
2960
- controls: LayerDefinition<typeof ControlsLayer>;
2961
-
2962
- [key: string]: LayerDefinition;
3143
+ controls: LayerDefinition<typeof ControlsLayer, "interface">;
2963
3144
  }
2964
3145
 
2965
- interface GroupDefinition<
2966
- GroupClass extends ToSpriteConstructor<CanvasGroupConstructor> = ToSpriteConstructor<CanvasGroupConstructor>,
2967
- > {
3146
+ // This requires `CanvasGroupConstructor` because `Canvas##createGroups` assumes there's no parameters.
3147
+ interface GroupDefinition<GroupClass extends CanvasGroupConstructor = CanvasGroupConstructor> {
2968
3148
  groupClass: GroupClass;
2969
3149
  parent: string;
2970
3150
  zIndexDrawings?: number;
2971
3151
  zIndexScrollingText?: number;
2972
3152
  }
2973
3153
 
2974
- interface LayerDefinition<LayerClass extends typeof CanvasLayer = typeof CanvasLayer> {
3154
+ // This requires `typeof CanvasLayer` because `CanvasGroupMixin#_createLayers` assumes there's no parameters.
3155
+ interface LayerDefinition<LayerClass extends typeof CanvasLayer, Group extends keyof CONFIG["Canvas"]["groups"]> {
2975
3156
  layerClass: LayerClass;
2976
- group: keyof CONFIG["Canvas"]["groups"];
2977
- }
2978
-
2979
- interface GridStyle {
2980
- label: string;
2981
- shaderClass: typeof GridShader;
2982
- shaderOptions: {
2983
- style: number;
2984
- };
3157
+ group: Group;
2985
3158
  }
2986
3159
 
2987
- /**
2988
- * A light source animation configuration object.
2989
- */
2990
- type LightSourceAnimationConfig = Record<
2991
- string,
2992
- {
2993
- label: string;
2994
- animation: LightAnimationFunction;
2995
- backgroundShader?: typeof AdaptiveBackgroundShader;
2996
- illuminationShader?: typeof AbstractBaseShader;
2997
- colorationShader?: typeof AbstractBaseShader;
2998
- }
2999
- >;
3000
-
3001
- /**
3002
- * A darkness source animation configuration object.
3003
- */
3004
- type DarknessSourceAnimationConfig = Record<
3005
- string,
3006
- { label: string; animation: LightAnimationFunction; darknessShader: typeof AdaptiveDarknessShader }
3007
- >;
3008
-
3009
- type LightAnimationFunction = (
3010
- // `this` is technically not a `PointLightSource`.
3011
- // Instead it is `foundry.canvas.sources.Pointfoundry.canvas.sources.LightSource.prototype`.
3012
- // However differentiating this would be a lot of work for little gain as nothing critical happens in the constructor.
3013
- this: PointLightSource,
3014
- dt: number,
3015
- properties?: { speed?: number; intensity?: number; reverse?: false },
3016
- ) => void;
3017
-
3018
3160
  namespace Pings {
3019
3161
  interface Style {
3020
3162
  class: unknown;
@@ -3025,23 +3167,6 @@ declare global {
3025
3167
  }
3026
3168
  }
3027
3169
 
3028
- interface WeatherAmbienceConfiguration {
3029
- id: string;
3030
- label: string;
3031
- filter: {
3032
- enabled: boolean;
3033
- blendMode: PIXI.BLEND_MODES;
3034
- };
3035
- effects: WeatherEffectConfiguration;
3036
- }
3037
-
3038
- interface WeatherEffectConfiguration {
3039
- id: string;
3040
- effectClass: typeof ParticleEffect | typeof WeatherShaderEffect;
3041
- blendMode: PIXI.BLEND_MODES;
3042
- config: Record<string, unknown>;
3043
- }
3044
-
3045
3170
  // The point of this interface is to be declaration merged into so you can override `DefaultSpecialStatusEffects` and remove existing keys. It's never used when empty.
3046
3171
  // eslint-disable-next-line @typescript-eslint/no-empty-object-type
3047
3172
  interface SpecialStatusEffects {}
@@ -3082,24 +3207,40 @@ declare global {
3082
3207
  }
3083
3208
  }
3084
3209
 
3210
+ /** @privateRemarks Foundry does not document the array options */
3085
3211
  interface WallDoorSound {
3086
3212
  /** A localization string label */
3087
3213
  label: string;
3088
3214
 
3089
- /** A sound path when the door is closed */
3090
- close: string;
3215
+ /**
3216
+ * A sound path when the door is closed
3217
+ * @remarks If an array is provided, a random entry is chosen
3218
+ */
3219
+ close?: string | string[];
3091
3220
 
3092
- /** A sound path when the door becomes locked */
3093
- lock: string;
3221
+ /**
3222
+ * A sound path when the door becomes locked
3223
+ * @remarks If an array is provided, a random entry is chosen
3224
+ */
3225
+ lock?: string | string[];
3094
3226
 
3095
- /** A sound path when opening the door */
3096
- open: string;
3227
+ /**
3228
+ * A sound path when opening the door
3229
+ * @remarks If an array is provided, a random entry is chosen
3230
+ */
3231
+ open?: string | string[];
3097
3232
 
3098
- /** A sound path when attempting to open a locked door */
3099
- test: string;
3233
+ /**
3234
+ * A sound path when attempting to open a locked door
3235
+ * @remarks If an array is provided, a random entry is chosen
3236
+ */
3237
+ test?: string | string[];
3100
3238
 
3101
- /** A sound path when the door becomes unlocked */
3102
- unlock: string;
3239
+ /**
3240
+ * A sound path when the door becomes unlocked
3241
+ * @remarks If an array is provided, a random entry is chosen
3242
+ */
3243
+ unlock?: string | string[];
3103
3244
  }
3104
3245
 
3105
3246
  namespace Dice {
@@ -3128,7 +3269,7 @@ interface SheetClassConfig {
3128
3269
 
3129
3270
  canConfigure: boolean;
3130
3271
 
3131
- cls: typeof DocumentSheet;
3272
+ cls: DocumentSheet.AnyConstructor;
3132
3273
 
3133
3274
  default: boolean;
3134
3275
 
@@ -3137,7 +3278,7 @@ interface SheetClassConfig {
3137
3278
  label: string;
3138
3279
  }
3139
3280
 
3140
- type PixiContainerConstructor = typeof PIXI.Container;
3281
+ type PixiContainerConstructor = PIXI.Container.AnyConstructor;
3141
3282
  interface CanvasGroup extends PIXI.Container {
3142
3283
  sortableChildren: boolean;
3143
3284
  }
@@ -3147,16 +3288,7 @@ interface CanvasGroupConstructor extends PixiContainerConstructor {
3147
3288
 
3148
3289
  /**
3149
3290
  * The name of this canvas group
3150
- * @remarks Not used in EffectsCanvasGroup in v11
3291
+ * @remarks Can be undefined in some cases (e.g `EffectsCanvasGroup`) to prevent other groups using it as a parent
3151
3292
  */
3152
- groupName?: string;
3153
- }
3154
-
3155
- type AnySpriteClass = abstract new (sprite?: SpriteMesh) => unknown;
3156
-
3157
- type ToSpriteConstructor<Class extends AnySpriteClass> = ToSpriteConstructorInterface<Class>;
3158
-
3159
- // @ts-expect-error - Ignore the "incorrectly extends interface" error inherent to this pattern.
3160
- interface ToSpriteConstructorInterface<T extends AnySpriteClass> extends T {
3161
- new (sprite: SpriteMesh): InstanceType<T>;
3293
+ groupName?: string | undefined;
3162
3294
  }