@league-of-foundry-developers/foundry-vtt-types 0.8.9-9 → 9.245.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (295) hide show
  1. package/README.md +44 -27
  2. package/index.d.ts +2 -2
  3. package/package.json +34 -15
  4. package/src/foundry/common/abstract/document.mjs.d.ts +24 -10
  5. package/src/foundry/common/config.mjs/index.d.ts +1 -0
  6. package/src/foundry/common/config.mjs/releaseData.d.ts +98 -0
  7. package/src/foundry/common/constants.mjs.d.ts +403 -213
  8. package/src/foundry/common/data/data.mjs/activeEffectData.d.ts +36 -29
  9. package/src/foundry/common/data/data.mjs/actorData.d.ts +32 -21
  10. package/src/foundry/common/data/data.mjs/adventureData.d.ts +165 -0
  11. package/src/foundry/common/data/data.mjs/ambientLightData.d.ts +45 -124
  12. package/src/foundry/common/data/data.mjs/ambientSoundData.d.ts +49 -77
  13. package/src/foundry/common/data/data.mjs/animationData.d.ts +17 -9
  14. package/src/foundry/common/data/data.mjs/cardData.d.ts +265 -0
  15. package/src/foundry/common/data/data.mjs/cardFaceData.d.ts +66 -0
  16. package/src/foundry/common/data/data.mjs/cardsData.d.ts +238 -0
  17. package/src/foundry/common/data/data.mjs/chatMessageData.d.ts +51 -39
  18. package/src/foundry/common/data/data.mjs/chatSpeakerData.d.ts +18 -11
  19. package/src/foundry/common/data/data.mjs/combatData.d.ts +51 -25
  20. package/src/foundry/common/data/data.mjs/combatantData.d.ts +48 -30
  21. package/src/foundry/common/data/data.mjs/darknessActivation.d.ts +8 -7
  22. package/src/foundry/common/data/data.mjs/drawingData.d.ts +68 -67
  23. package/src/foundry/common/data/data.mjs/effectChangeData.d.ts +21 -25
  24. package/src/foundry/common/data/data.mjs/effectDurationData.d.ts +24 -23
  25. package/src/foundry/common/data/data.mjs/fogExplorationData.d.ts +23 -16
  26. package/src/foundry/common/data/data.mjs/folderData.d.ts +28 -25
  27. package/src/foundry/common/data/data.mjs/index.d.ts +5 -0
  28. package/src/foundry/common/data/data.mjs/itemData.d.ts +26 -18
  29. package/src/foundry/common/data/data.mjs/journalEntryData.d.ts +24 -23
  30. package/src/foundry/common/data/data.mjs/lightData.d.ts +228 -0
  31. package/src/foundry/common/data/data.mjs/macroData.d.ts +52 -35
  32. package/src/foundry/common/data/data.mjs/measuredTemplateData.d.ts +41 -38
  33. package/src/foundry/common/data/data.mjs/noteData.d.ts +47 -37
  34. package/src/foundry/common/data/data.mjs/playlistData.d.ts +55 -26
  35. package/src/foundry/common/data/data.mjs/playlistSoundData.d.ts +32 -16
  36. package/src/foundry/common/data/data.mjs/prototypeTokenData.d.ts +7 -11
  37. package/src/foundry/common/data/data.mjs/rollTableData.d.ts +30 -24
  38. package/src/foundry/common/data/data.mjs/sceneData.d.ts +132 -111
  39. package/src/foundry/common/data/data.mjs/settingData.d.ts +11 -8
  40. package/src/foundry/common/data/data.mjs/tableResultData.d.ts +30 -26
  41. package/src/foundry/common/data/data.mjs/tileData.d.ts +43 -36
  42. package/src/foundry/common/data/data.mjs/tileOcclusion.d.ts +10 -9
  43. package/src/foundry/common/data/data.mjs/tokenBarData.d.ts +6 -3
  44. package/src/foundry/common/data/data.mjs/tokenData.d.ts +105 -157
  45. package/src/foundry/common/data/data.mjs/userData.d.ts +118 -33
  46. package/src/foundry/common/data/data.mjs/videoData.d.ts +9 -8
  47. package/src/foundry/common/data/data.mjs/wallData.d.ts +67 -39
  48. package/src/foundry/common/data/fields.mjs.d.ts +180 -83
  49. package/src/foundry/common/documents.mjs/baseActiveEffect.d.ts +9 -3
  50. package/src/foundry/common/documents.mjs/baseActor.d.ts +17 -45
  51. package/src/foundry/common/documents.mjs/baseAdventure.d.ts +38 -0
  52. package/src/foundry/common/documents.mjs/baseAmbientLight.d.ts +3 -0
  53. package/src/foundry/common/documents.mjs/baseAmbientSound.d.ts +3 -1
  54. package/src/foundry/common/documents.mjs/baseCard.d.ts +62 -0
  55. package/src/foundry/common/documents.mjs/baseCards.d.ts +39 -0
  56. package/src/foundry/common/documents.mjs/baseChatMessage.d.ts +3 -0
  57. package/src/foundry/common/documents.mjs/baseCombat.d.ts +5 -2
  58. package/src/foundry/common/documents.mjs/baseCombatant.d.ts +9 -2
  59. package/src/foundry/common/documents.mjs/baseDrawing.d.ts +11 -1
  60. package/src/foundry/common/documents.mjs/baseFogExploration.d.ts +4 -3
  61. package/src/foundry/common/documents.mjs/baseFolder.d.ts +10 -1
  62. package/src/foundry/common/documents.mjs/baseItem.d.ts +11 -29
  63. package/src/foundry/common/documents.mjs/baseJournalEntry.d.ts +3 -0
  64. package/src/foundry/common/documents.mjs/baseMacro.d.ts +16 -14
  65. package/src/foundry/common/documents.mjs/baseMeasuredTemplate.d.ts +4 -1
  66. package/src/foundry/common/documents.mjs/baseNote.d.ts +2 -2
  67. package/src/foundry/common/documents.mjs/basePlaylist.d.ts +1 -0
  68. package/src/foundry/common/documents.mjs/basePlaylistSound.d.ts +2 -1
  69. package/src/foundry/common/documents.mjs/baseRollTable.d.ts +3 -0
  70. package/src/foundry/common/documents.mjs/baseScene.d.ts +1 -0
  71. package/src/foundry/common/documents.mjs/baseSetting.d.ts +1 -0
  72. package/src/foundry/common/documents.mjs/baseTableResult.d.ts +10 -3
  73. package/src/foundry/common/documents.mjs/baseTile.d.ts +1 -0
  74. package/src/foundry/common/documents.mjs/baseToken.d.ts +3 -0
  75. package/src/foundry/common/documents.mjs/baseUser.d.ts +7 -1
  76. package/src/foundry/common/documents.mjs/baseWall.d.ts +7 -10
  77. package/src/foundry/common/documents.mjs/index.d.ts +3 -0
  78. package/src/foundry/common/module.mjs.d.ts +3 -0
  79. package/src/foundry/common/packages.mjs/moduleData.d.ts +12 -9
  80. package/src/foundry/common/packages.mjs/packageAuthorData.d.ts +24 -24
  81. package/src/foundry/common/packages.mjs/packageCompendiumData.d.ts +27 -21
  82. package/src/foundry/common/packages.mjs/packageData.d.ts +108 -82
  83. package/src/foundry/common/packages.mjs/packageDependencyData.d.ts +18 -11
  84. package/src/foundry/common/packages.mjs/packageLanguageData.d.ts +16 -15
  85. package/src/foundry/common/packages.mjs/systemData.d.ts +21 -20
  86. package/src/foundry/common/packages.mjs/tagPackageAvailability.d.ts +3 -3
  87. package/src/foundry/common/packages.mjs/worldData.d.ts +29 -18
  88. package/src/foundry/common/types.mjs.d.ts +95 -0
  89. package/src/foundry/common/utils/geometry.mjs.d.ts +148 -0
  90. package/src/foundry/common/utils/helpers.mjs.d.ts +64 -39
  91. package/src/foundry/common/utils/module.mjs.d.ts +1 -0
  92. package/src/foundry/common/utils/primitives.mjs.d.ts +106 -16
  93. package/src/foundry/foundry.js/application.d.ts +138 -110
  94. package/src/foundry/foundry.js/applications/basePlaceableHUD.d.ts +2 -2
  95. package/src/foundry/foundry.js/applications/basePlaceableHUDs/drawingHUD.d.ts +2 -2
  96. package/src/foundry/foundry.js/applications/basePlaceableHUDs/tileHUD.d.ts +2 -2
  97. package/src/foundry/foundry.js/applications/basePlaceableHUDs/tokenHUD.d.ts +3 -3
  98. package/src/foundry/foundry.js/applications/cameraViews.d.ts +2 -2
  99. package/src/foundry/foundry.js/applications/chatPopout.d.ts +3 -3
  100. package/src/foundry/foundry.js/applications/compendium.d.ts +2 -2
  101. package/src/foundry/foundry.js/applications/dialog.d.ts +1 -1
  102. package/src/foundry/foundry.js/applications/filePicker.d.ts +2 -2
  103. package/src/foundry/foundry.js/applications/formApplication.d.ts +46 -15
  104. package/src/foundry/foundry.js/applications/formApplications/avConfig.d.ts +1 -1
  105. package/src/foundry/foundry.js/applications/formApplications/combatTrackerConfig.d.ts +2 -2
  106. package/src/foundry/foundry.js/applications/formApplications/defaultTokenConfig.d.ts +1 -1
  107. package/src/foundry/foundry.js/applications/formApplications/documentSheet.d.ts +20 -31
  108. package/src/foundry/foundry.js/applications/formApplications/documentSheets/activeEffectConfig.d.ts +3 -3
  109. package/src/foundry/foundry.js/applications/formApplications/documentSheets/actorSheet.d.ts +2 -2
  110. package/src/foundry/foundry.js/applications/formApplications/documentSheets/ambientLightConfig.d.ts +104 -0
  111. package/src/foundry/foundry.js/applications/formApplications/documentSheets/ambientSoundConfig.d.ts +5 -5
  112. package/src/foundry/foundry.js/applications/formApplications/documentSheets/combatantConfig.d.ts +3 -3
  113. package/src/foundry/foundry.js/applications/formApplications/documentSheets/folderConfig.d.ts +3 -3
  114. package/src/foundry/foundry.js/applications/formApplications/documentSheets/index.d.ts +1 -0
  115. package/src/foundry/foundry.js/applications/formApplications/documentSheets/itemSheet.d.ts +1 -1
  116. package/src/foundry/foundry.js/applications/formApplications/documentSheets/journalSheet.d.ts +1 -1
  117. package/src/foundry/foundry.js/applications/formApplications/documentSheets/lightConfig.d.ts +5 -79
  118. package/src/foundry/foundry.js/applications/formApplications/documentSheets/macroConfig.d.ts +3 -3
  119. package/src/foundry/foundry.js/applications/formApplications/documentSheets/measuredTemplateConfig.d.ts +4 -4
  120. package/src/foundry/foundry.js/applications/formApplications/documentSheets/noteConfig.d.ts +5 -5
  121. package/src/foundry/foundry.js/applications/formApplications/documentSheets/permissionControl.d.ts +7 -7
  122. package/src/foundry/foundry.js/applications/formApplications/documentSheets/playlistConfig.d.ts +4 -4
  123. package/src/foundry/foundry.js/applications/formApplications/documentSheets/playlistSoundConfig.d.ts +3 -3
  124. package/src/foundry/foundry.js/applications/formApplications/documentSheets/rollTableConfig.d.ts +7 -10
  125. package/src/foundry/foundry.js/applications/formApplications/documentSheets/sceneConfig.d.ts +7 -7
  126. package/src/foundry/foundry.js/applications/formApplications/documentSheets/tileConfig.d.ts +3 -3
  127. package/src/foundry/foundry.js/applications/formApplications/documentSheets/userConfig.d.ts +7 -7
  128. package/src/foundry/foundry.js/applications/formApplications/drawingConfig.d.ts +2 -2
  129. package/src/foundry/foundry.js/applications/formApplications/entitySheetConfig.d.ts +3 -3
  130. package/src/foundry/foundry.js/applications/formApplications/gridConfig.d.ts +2 -2
  131. package/src/foundry/foundry.js/applications/formApplications/imagePopout.d.ts +2 -2
  132. package/src/foundry/foundry.js/applications/formApplications/index.d.ts +1 -0
  133. package/src/foundry/foundry.js/applications/formApplications/keybindingsConfig.d.ts +257 -0
  134. package/src/foundry/foundry.js/applications/formApplications/moduleManagement.d.ts +2 -2
  135. package/src/foundry/foundry.js/applications/formApplications/permissionConfig.d.ts +2 -2
  136. package/src/foundry/foundry.js/applications/formApplications/settingsConfig.d.ts +1 -1
  137. package/src/foundry/foundry.js/applications/formApplications/tokenConfig.d.ts +11 -12
  138. package/src/foundry/foundry.js/applications/formApplications/wallConfig.d.ts +9 -9
  139. package/src/foundry/foundry.js/applications/formApplications/worldConfig.d.ts +1 -1
  140. package/src/foundry/foundry.js/applications/frameViewer.d.ts +1 -1
  141. package/src/foundry/foundry.js/applications/headsUpDisplay.d.ts +2 -2
  142. package/src/foundry/foundry.js/applications/hotbar.d.ts +2 -2
  143. package/src/foundry/foundry.js/applications/mainMenu.d.ts +2 -2
  144. package/src/foundry/foundry.js/applications/notifications.d.ts +7 -4
  145. package/src/foundry/foundry.js/applications/pause.d.ts +2 -2
  146. package/src/foundry/foundry.js/applications/playerList.d.ts +2 -2
  147. package/src/foundry/foundry.js/applications/sceneControls.d.ts +2 -2
  148. package/src/foundry/foundry.js/applications/sceneNavigation.d.ts +3 -3
  149. package/src/foundry/foundry.js/applications/sidebar.d.ts +2 -2
  150. package/src/foundry/foundry.js/applications/sidebarTab.d.ts +5 -8
  151. package/src/foundry/foundry.js/applications/sidebarTabs/chatLog.d.ts +8 -7
  152. package/src/foundry/foundry.js/applications/sidebarTabs/combatTracker.d.ts +26 -28
  153. package/src/foundry/foundry.js/applications/sidebarTabs/compendiumDirectory.d.ts +4 -4
  154. package/src/foundry/foundry.js/applications/sidebarTabs/settings.d.ts +2 -2
  155. package/src/foundry/foundry.js/applications/sidebarTabs/sidebarDirectories/cardsDirectory.d.ts +7 -0
  156. package/src/foundry/foundry.js/applications/sidebarTabs/sidebarDirectories/index.d.ts +1 -0
  157. package/src/foundry/foundry.js/applications/sidebarTabs/sidebarDirectories/playlistDirectory.d.ts +2 -2
  158. package/src/foundry/foundry.js/applications/sidebarTabs/sidebarDirectory.d.ts +3 -3
  159. package/src/foundry/foundry.js/audioContainer.d.ts +28 -10
  160. package/src/foundry/foundry.js/avSettings.d.ts +7 -7
  161. package/src/foundry/foundry.js/canvas.d.ts +153 -46
  162. package/src/foundry/foundry.js/canvasAnimation.d.ts +31 -8
  163. package/src/foundry/foundry.js/canvasDocumentMixin.d.ts +7 -0
  164. package/src/foundry/foundry.js/clientDocumentMixin.d.ts +47 -92
  165. package/src/foundry/foundry.js/clientDocuments/activeEffect.d.ts +3 -2
  166. package/src/foundry/foundry.js/clientDocuments/actor.d.ts +11 -11
  167. package/src/foundry/foundry.js/clientDocuments/canvasDocuments/ambientSoundDocument.d.ts +1 -6
  168. package/src/foundry/foundry.js/clientDocuments/card.d.ts +134 -0
  169. package/src/foundry/foundry.js/clientDocuments/cards.d.ts +370 -0
  170. package/src/foundry/foundry.js/clientDocuments/chatMessage.d.ts +11 -10
  171. package/src/foundry/foundry.js/clientDocuments/combat.d.ts +46 -48
  172. package/src/foundry/foundry.js/clientDocuments/combatant.d.ts +15 -18
  173. package/src/foundry/foundry.js/clientDocuments/folder.d.ts +15 -11
  174. package/src/foundry/foundry.js/clientDocuments/index.d.ts +2 -0
  175. package/src/foundry/foundry.js/clientDocuments/item.d.ts +3 -4
  176. package/src/foundry/foundry.js/clientDocuments/playlist.d.ts +4 -3
  177. package/src/foundry/foundry.js/clientDocuments/rollTable.d.ts +2 -2
  178. package/src/foundry/foundry.js/clientDocuments/scene.d.ts +30 -23
  179. package/src/foundry/foundry.js/clientKeybindings.d.ts +309 -0
  180. package/src/foundry/foundry.js/clientSettings.d.ts +12 -10
  181. package/src/foundry/foundry.js/collections/documentCollection.d.ts +1 -1
  182. package/src/foundry/foundry.js/collections/documentCollections/compendiumCollection.d.ts +1 -1
  183. package/src/foundry/foundry.js/collections/documentCollections/worldCollections/cardStacks.d.ts +9 -0
  184. package/src/foundry/foundry.js/collections/documentCollections/worldCollections/folders.d.ts +1 -1
  185. package/src/foundry/foundry.js/collections/documentCollections/worldCollections/index.d.ts +1 -0
  186. package/src/foundry/foundry.js/collections/documentCollections/worldCollections/playlists.d.ts +3 -2
  187. package/src/foundry/foundry.js/collisionResult.d.ts +60 -0
  188. package/src/foundry/foundry.js/config.d.ts +487 -907
  189. package/src/foundry/foundry.js/dragDrop.d.ts +27 -34
  190. package/src/foundry/foundry.js/game.d.ts +171 -50
  191. package/src/foundry/foundry.js/gamepadManager.d.ts +41 -0
  192. package/src/foundry/foundry.js/handlebarsHelpers.d.ts +4 -4
  193. package/src/foundry/foundry.js/hooks.d.ts +210 -84
  194. package/src/foundry/foundry.js/imageHelper.d.ts +26 -2
  195. package/src/foundry/foundry.js/keyboardManager.d.ts +165 -213
  196. package/src/foundry/foundry.js/mouseManager.d.ts +18 -0
  197. package/src/foundry/foundry.js/newUserExperience.d.ts +34 -0
  198. package/src/foundry/foundry.js/pixi/containers/cachedContainer.d.ts +8 -0
  199. package/src/foundry/foundry.js/pixi/containers/cachedContainers/index.d.ts +1 -0
  200. package/src/foundry/foundry.js/pixi/containers/cachedContainers/primaryCanvasGroup.d.ts +42 -0
  201. package/src/foundry/foundry.js/pixi/containers/canvasLayers/gridLayer.d.ts +2 -2
  202. package/src/foundry/foundry.js/pixi/containers/canvasLayers/index.d.ts +1 -1
  203. package/src/foundry/foundry.js/pixi/containers/canvasLayers/placeablesLayers/wallsLayer.d.ts +3 -3
  204. package/src/foundry/foundry.js/pixi/containers/canvasLayers/{effectsLayer.d.ts → weatherLayer.d.ts} +7 -7
  205. package/src/foundry/foundry.js/pixi/containers/effectsCanvasGroup.d.ts +29 -0
  206. package/src/foundry/foundry.js/pixi/containers/index.d.ts +3 -0
  207. package/src/foundry/foundry.js/pixi/containers/interfaceCanvasGroup.d.ts +27 -0
  208. package/src/foundry/foundry.js/pixi/containers/placeableObject.d.ts +2 -2
  209. package/src/foundry/foundry.js/pixi/containers/placeableObjects/token.d.ts +3 -3
  210. package/src/foundry/foundry.js/pixi/index.d.ts +3 -0
  211. package/src/foundry/foundry.js/pixi/meshes/index.d.ts +1 -0
  212. package/src/foundry/foundry.js/pixi/meshes/samplerMesh.d.ts +22 -0
  213. package/src/foundry/foundry.js/pixi/points/index.d.ts +1 -0
  214. package/src/foundry/foundry.js/pixi/points/wallEndpoint.d.ts +92 -0
  215. package/src/foundry/foundry.js/pixi/polygons/index.d.ts +2 -1
  216. package/src/foundry/foundry.js/pixi/polygons/pointSourcePolygon.d.ts +98 -0
  217. package/src/foundry/foundry.js/pixi/polygons/pointSourcePolygons/clockwiseSweepPolygon.d.ts +396 -0
  218. package/src/foundry/foundry.js/pixi/polygons/pointSourcePolygons/index.d.ts +1 -0
  219. package/src/foundry/foundry.js/pixi/rectangles/normalizedRectangle.d.ts +7 -0
  220. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShader.d.ts +11 -37
  221. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShader.d.ts +114 -0
  222. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveBackgroundShader.d.ts +57 -0
  223. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShader.d.ts +47 -0
  224. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/bewitchingWaveColorationShader.d.ts +6 -0
  225. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/chromaColorationShader.d.ts +6 -0
  226. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/emanationColorationShader.d.ts +6 -0
  227. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/energyFieldColorationShader.d.ts +6 -0
  228. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/fairyLightColorationShader.d.ts +6 -0
  229. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/fogColorationShader.d.ts +6 -0
  230. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/ghostLightColorationShader.d.ts +1 -1
  231. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/hexaDomeColorationShader.d.ts +6 -0
  232. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/index.d.ts +5 -0
  233. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/lightDomeColorationShader.d.ts +6 -0
  234. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/pulseColorationShader.d.ts +1 -1
  235. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/radialRainbowColorationShader.d.ts +6 -0
  236. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/sunburstColorationShader.d.ts +1 -1
  237. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/swirlingRainbowColorationShader.d.ts +6 -0
  238. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/torchColorationShader.d.ts +3 -2
  239. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveColorationShaders/vortexColorationShader.d.ts +6 -0
  240. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardColorationShaders → adaptiveLightingShaders/adaptiveColorationShaders}/waveColorationShader.d.ts +1 -1
  241. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveIlluminationShader.d.ts +63 -0
  242. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveIlluminationShaders/bewitchingWaveIlluminationShader.d.ts +6 -0
  243. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/blackHoleIlluminationShader.d.ts +1 -1
  244. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveIlluminationShaders/fairyLightIlluminationShader.d.ts +6 -0
  245. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/ghostLightIlluminationShader.d.ts +1 -1
  246. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/index.d.ts +3 -0
  247. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/pulseIlluminationShader.d.ts +1 -1
  248. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/roilingIlluminationShader.d.ts +1 -1
  249. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/sunburstIlluminationShader.d.ts +1 -2
  250. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/torchIlluminationShader.d.ts +1 -1
  251. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/adaptiveIlluminationShaders/vortexIlluminationShader.d.ts +6 -0
  252. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/{standardIlluminationShaders → adaptiveLightingShaders/adaptiveIlluminationShaders}/waveIlluminationShader.d.ts +1 -1
  253. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/adaptiveLightingShaders/index.d.ts +5 -0
  254. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/baseSamplerShader.d.ts +22 -0
  255. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/index.d.ts +3 -4
  256. package/src/foundry/foundry.js/pixi/texts/preciseText.d.ts +10 -2
  257. package/src/foundry/foundry.js/pixi/transforms/index.d.ts +1 -0
  258. package/src/foundry/foundry.js/pixi/transforms/synchronizedTransform.d.ts +38 -0
  259. package/src/foundry/foundry.js/pointSource.d.ts +59 -328
  260. package/src/foundry/foundry.js/pointSources/index.d.ts +3 -0
  261. package/src/foundry/foundry.js/pointSources/lightSource.d.ts +417 -0
  262. package/src/foundry/foundry.js/pointSources/soundSource.d.ts +46 -0
  263. package/src/foundry/foundry.js/pointSources/visionSource.d.ts +125 -0
  264. package/src/foundry/foundry.js/polygonEdge.d.ts +26 -0
  265. package/src/foundry/foundry.js/polygonVertex.d.ts +89 -0
  266. package/src/foundry/foundry.js/quadtree.d.ts +2 -2
  267. package/src/foundry/foundry.js/quadtreeCulling.d.ts +11 -0
  268. package/src/foundry/foundry.js/ray.d.ts +156 -162
  269. package/src/foundry/foundry.js/rays/index.d.ts +1 -0
  270. package/src/foundry/foundry.js/rays/sightRay.d.ts +34 -0
  271. package/src/foundry/foundry.js/roll.d.ts +51 -65
  272. package/src/foundry/foundry.js/rollTerm.d.ts +7 -4
  273. package/src/foundry/foundry.js/rollTerms/diceTerm.d.ts +4 -22
  274. package/src/foundry/foundry.js/rollTerms/mathTerm.d.ts +3 -0
  275. package/src/foundry/foundry.js/rollTerms/parentheticalTerm.d.ts +3 -0
  276. package/src/foundry/foundry.js/rollTerms/poolTerm.d.ts +3 -5
  277. package/src/foundry/foundry.js/rollTerms/stringTerm.d.ts +4 -1
  278. package/src/foundry/foundry.js/screenCulling.d.ts +19 -0
  279. package/src/foundry/foundry.js/searchFilter.d.ts +37 -33
  280. package/src/foundry/foundry.js/specialEffect.d.ts +1 -1
  281. package/src/foundry/foundry.js/textEditor.d.ts +1 -1
  282. package/src/foundry/foundry.js/textureLoader.d.ts +28 -18
  283. package/src/foundry/foundry.js/textureUtils.d.ts +5 -8
  284. package/src/foundry/foundry.js/videoHelper.d.ts +2 -1
  285. package/src/foundry/index.d.ts +29 -26
  286. package/src/types/utils.d.ts +11 -3
  287. package/src/foundry/foundry.js/pixi/polygons/sourcePolygon.d.ts +0 -25
  288. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShader.d.ts +0 -21
  289. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/chromaColorationShader.d.ts +0 -18
  290. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/emanationColorationShader.d.ts +0 -17
  291. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/energyFieldColorationShader.d.ts +0 -18
  292. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/fogColorationShader.d.ts +0 -17
  293. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/hexaDomeColorationShader.d.ts +0 -17
  294. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardColorationShaders/lightDomeColorationShader.d.ts +0 -17
  295. package/src/foundry/foundry.js/pixi/shaders/abstractBaseShaders/standardIlluminationShader.d.ts +0 -22
@@ -27,42 +27,62 @@ export const ASCII = `__________________________________________________________
27
27
  /**
28
28
  * Define the allowed ActiveEffect application modes
29
29
  */
30
- export const ACTIVE_EFFECT_MODES: {
30
+ export const ACTIVE_EFFECT_MODES: Readonly<{
31
31
  CUSTOM: 0;
32
32
  MULTIPLY: 1;
33
33
  ADD: 2;
34
34
  DOWNGRADE: 3;
35
35
  UPGRADE: 4;
36
36
  OVERRIDE: 5;
37
- };
37
+ }>;
38
+ export type ACTIVE_EFFECT_MODES = ValueOf<typeof ACTIVE_EFFECT_MODES>;
38
39
 
39
40
  /**
40
- * Define the string name used for the base entity type when specific sub-types are not defined by the system
41
+ * Define the string name used for the base document type when specific sub-types are not defined by the system
41
42
  */
42
- export const BASE_ENTITY_TYPE: 'base';
43
+ export const BASE_DOCUMENT_TYPE: 'base';
44
+
45
+ /**
46
+ * Define the methods by which a Card can be drawn from a Cards stack
47
+ * TOP and FIRST are synonymous, as are BOTTOM and LAST.
48
+ */
49
+ export const CARD_DRAW_MODES: Readonly<{
50
+ FIRST: 0;
51
+ TOP: 0;
52
+ LAST: 1;
53
+ BOTTOM: 1;
54
+ RANDOM: 2;
55
+ }>;
56
+ export type CARD_DRAW_MODES = ValueOf<typeof CARD_DRAW_MODES>;
57
+
58
+ /**
59
+ * An enumeration of canvas performance modes.
60
+ */
61
+ export const CANVAS_PERFORMANCE_MODES: Readonly<{
62
+ LOW: 0;
63
+ MED: 1;
64
+ HIGH: 2;
65
+ MAX: 3;
66
+ }>;
67
+ export type CANVAS_PERFORMANCE_MODES = ValueOf<typeof CANVAS_PERFORMANCE_MODES>;
43
68
 
44
69
  /**
45
70
  * Valid Chat Message types
46
71
  */
47
- export const CHAT_MESSAGE_TYPES: {
72
+ export const CHAT_MESSAGE_TYPES: Readonly<{
48
73
  OTHER: 0;
49
74
  OOC: 1;
50
75
  IC: 2;
51
76
  EMOTE: 3;
52
77
  WHISPER: 4;
53
78
  ROLL: 5;
54
- };
55
-
56
- /**
57
- * The allowed Entity types which may exist within a Compendium pack
58
- * This is a subset of ENTITY_TYPES
59
- */
60
- export const COMPENDIUM_ENTITY_TYPES: ['Actor', 'Item', 'Scene', 'JournalEntry', 'Macro', 'RollTable', 'Playlist'];
79
+ }>;
80
+ export type CHAT_MESSAGE_TYPES = ValueOf<typeof CHAT_MESSAGE_TYPES>;
61
81
 
62
82
  /**
63
83
  * Define the set of languages which have built-in support in the core software
64
84
  */
65
- export const CORE_SUPPORTED_LANGUAGES: ['en'];
85
+ export const CORE_SUPPORTED_LANGUAGES: readonly ['en'];
66
86
 
67
87
  /**
68
88
  * The default artwork used for Token images if none is provided
@@ -71,34 +91,100 @@ export const DEFAULT_TOKEN: 'icons/svg/mystery-man.svg';
71
91
 
72
92
  /**
73
93
  * The default artwork used for Note placeables if none is provided
94
+ * @deprecated since v9, use NoteData.DEFAULT_ICON instead.
74
95
  */
75
96
  export const DEFAULT_NOTE_ICON: 'icons/svg/book.svg';
76
97
 
77
98
  /**
78
99
  * The default icon image used for Macro documents if no other image is provided
100
+ * @deprecated since v9, use MacroData.DEFAULT_ICON instead.
79
101
  */
80
102
  export const DEFAULT_MACRO_ICON: 'icons/svg/dice-target.svg';
81
103
 
104
+ /**
105
+ * Define the allowed Document class types.
106
+ */
107
+ export const DOCUMENT_TYPES: readonly [
108
+ 'Actor',
109
+ 'Cards',
110
+ 'ChatMessage',
111
+ 'Combat',
112
+ 'Item',
113
+ 'Folder',
114
+ 'JournalEntry',
115
+ 'Macro',
116
+ 'Playlist',
117
+ 'RollTable',
118
+ 'Scene',
119
+ 'User'
120
+ ];
121
+ export type DOCUMENT_TYPES = ValueOf<typeof DOCUMENT_TYPES>;
122
+
123
+ /**
124
+ * The allowed Document types which may exist within a Compendium pack.
125
+ */
126
+ export const COMPENDIUM_DOCUMENT_TYPES: readonly [
127
+ 'Actor',
128
+ 'Cards',
129
+ 'Item',
130
+ 'JournalEntry',
131
+ 'Macro',
132
+ 'Playlist',
133
+ 'RollTable',
134
+ 'Scene',
135
+ 'Adventure'
136
+ ];
137
+ export type COMPENDIUM_DOCUMENT_TYPES = ValueOf<typeof COMPENDIUM_DOCUMENT_TYPES>;
138
+
139
+ /**
140
+ * Define the allowed permission levels for a non-user Document.
141
+ * Each level is assigned a value in ascending order. Higher levels grant more permissions.
142
+ */
143
+ export const DOCUMENT_PERMISSION_LEVELS: Readonly<{
144
+ NONE: 0;
145
+ LIMITED: 1;
146
+ OBSERVER: 2;
147
+ OWNER: 3;
148
+ }>;
149
+ export type DOCUMENT_PERMISSION_LEVELS = ValueOf<typeof DOCUMENT_PERMISSION_LEVELS>;
150
+
151
+ /**
152
+ * Define the allowed Document types which may be dynamically linked in chat
153
+ */
154
+ export const DOCUMENT_LINK_TYPES: readonly [
155
+ 'Actor',
156
+ 'Cards',
157
+ 'Item',
158
+ 'Scene',
159
+ 'JournalEntry',
160
+ 'Macro',
161
+ 'RollTable',
162
+ 'PlaylistSound'
163
+ ];
164
+ export type DOCUMENT_LINK_TYPES = ValueOf<typeof DOCUMENT_LINK_TYPES>;
165
+
82
166
  /**
83
167
  * The supported dice roll visibility modes
84
168
  */
85
- export const DICE_ROLL_MODES: {
86
- PUBLIC: 'roll';
169
+ export const DICE_ROLL_MODES: Readonly<{
170
+ PUBLIC: 'publicroll';
87
171
  PRIVATE: 'gmroll';
88
172
  BLIND: 'blindroll';
89
173
  SELF: 'selfroll';
90
- };
174
+ }>;
175
+ export type DICE_ROLL_MODES = ValueOf<typeof DICE_ROLL_MODES>;
91
176
 
92
177
  /**
93
178
  * The allowed Drawing types which may be saved
94
179
  */
95
- export const DRAWING_TYPES: {
180
+ export const DRAWING_TYPES: Readonly<{
96
181
  RECTANGLE: 'r';
97
182
  ELLIPSE: 'e';
98
183
  TEXT: 't';
99
184
  POLYGON: 'p';
100
185
  FREEHAND: 'f';
101
- };
186
+ }>;
187
+ export type DRAWING_TYPES = ValueOf<typeof DRAWING_TYPES>;
102
188
 
103
189
  /**
104
190
  * The allowed fill types which a Drawing object may display
@@ -106,49 +192,27 @@ export const DRAWING_TYPES: {
106
192
  * SOLID: The drawing is filled with a solid color
107
193
  * PATTERN: The drawing is filled with a tiled image pattern
108
194
  */
109
- export const DRAWING_FILL_TYPES: {
195
+ export const DRAWING_FILL_TYPES: Readonly<{
110
196
  NONE: 0;
111
197
  SOLID: 1;
112
198
  PATTERN: 2;
113
- };
199
+ }>;
200
+ export type DRAWING_FILL_TYPES = ValueOf<typeof DRAWING_FILL_TYPES>;
114
201
 
115
202
  /**
116
- * Define the allowed Entity class types
203
+ * Define the allowed Document types which Folders may contain
117
204
  */
118
- export const ENTITY_TYPES: [
205
+ export const FOLDER_DOCUMENT_TYPES: readonly [
119
206
  'Actor',
120
- 'ChatMessage',
121
- 'Combat',
122
207
  'Item',
123
- 'Folder',
208
+ 'Scene',
124
209
  'JournalEntry',
125
- 'Macro',
126
210
  'Playlist',
127
211
  'RollTable',
128
- 'Scene',
129
- 'User'
212
+ 'Cards',
213
+ 'Macro'
130
214
  ];
131
-
132
- /**
133
- * Define the allowed Entity types which may be dynamically linked in chat
134
- */
135
- export const ENTITY_LINK_TYPES: ['Actor', 'Item', 'Scene', 'JournalEntry', 'Macro', 'RollTable'];
136
-
137
- /**
138
- * Define the allowed permission levels for a non-user Entity.
139
- * Each level is assigned a value in ascending order. Higher levels grant more permissions.
140
- */
141
- export const ENTITY_PERMISSIONS: {
142
- NONE: 0;
143
- LIMITED: 1;
144
- OBSERVER: 2;
145
- OWNER: 3;
146
- };
147
-
148
- /**
149
- * Define the allowed Entity types which Folders may contain
150
- */
151
- export const FOLDER_ENTITY_TYPES: ['Actor', 'Item', 'Scene', 'JournalEntry', 'Playlist', 'RollTable'];
215
+ export type FOLDER_DOCUMENT_TYPES = ValueOf<typeof FOLDER_DOCUMENT_TYPES>;
152
216
 
153
217
  /**
154
218
  * The maximum allowed level of depth for Folder nesting
@@ -158,7 +222,7 @@ export const FOLDER_MAX_DEPTH: 3;
158
222
  /**
159
223
  * A list of allowed game URL names
160
224
  */
161
- export const GAME_VIEWS: ['game', 'stream'];
225
+ export const GAME_VIEWS: readonly ['game', 'stream'];
162
226
 
163
227
  /**
164
228
  * The minimum allowed grid size which is supported by the software
@@ -168,41 +232,35 @@ export const GRID_MIN_SIZE: 50;
168
232
  /**
169
233
  * The allowed Grid types which are supported by the software
170
234
  */
171
- export const GRID_TYPES: {
235
+ export const GRID_TYPES: Readonly<{
172
236
  GRIDLESS: 0;
173
237
  SQUARE: 1;
174
238
  HEXODDR: 2;
175
239
  HEXEVENR: 3;
176
240
  HEXODDQ: 4;
177
241
  HEXEVENQ: 5;
178
- };
242
+ }>;
243
+ export type GRID_TYPES = ValueOf<typeof GRID_TYPES>;
179
244
 
180
245
  /**
181
246
  * A list of supported setup URL names
182
247
  */
183
- export const SETUP_VIEWS: ['license', 'setup', 'players', 'join'];
184
-
185
- /**
186
- * Enumerate the source types which can be used for an AmbientLight placeable object
187
- */
188
- export const SOURCE_TYPES: {
189
- LOCAL: 'l';
190
- GLOBAL: 'g';
191
- UNIVERSAL: 'u';
192
- };
248
+ export const SETUP_VIEWS: readonly ['license', 'setup', 'players', 'join', 'auth'];
193
249
 
194
250
  /**
195
251
  * An Array of valid MacroAction scope values
196
252
  */
197
- export const MACRO_SCOPES: ['global', 'actors', 'actor'];
253
+ export const MACRO_SCOPES: readonly ['global', 'actors', 'actor'];
254
+ export type MACRO_SCOPES = ValueOf<typeof MACRO_SCOPES>;
198
255
 
199
256
  /**
200
257
  * An enumeration of valid Macro types
201
258
  */
202
- export const MACRO_TYPES: {
259
+ export const MACRO_TYPES: Readonly<{
203
260
  SCRIPT: 'script';
204
261
  CHAT: 'chat';
205
- };
262
+ }>;
263
+ export type MACRO_TYPES = ValueOf<typeof MACRO_TYPES>;
206
264
 
207
265
  /**
208
266
  * The allowed playback modes for an audio Playlist
@@ -211,29 +269,43 @@ export const MACRO_TYPES: {
211
269
  * SHUFFLE: The playlist plays sounds one at a time in randomized order
212
270
  * SIMULTANEOUS: The playlist plays all contained sounds at the same time
213
271
  */
214
- export const PLAYLIST_MODES: {
272
+ export const PLAYLIST_MODES: Readonly<{
215
273
  DISABLED: -1;
216
274
  SEQUENTIAL: 0;
217
275
  SHUFFLE: 1;
218
276
  SIMULTANEOUS: 2;
219
- };
277
+ }>;
278
+ export type PLAYLIST_MODES = ValueOf<typeof PLAYLIST_MODES>;
279
+
280
+ /**
281
+ * The available sort modes for an audio Playlist.
282
+ * ALPHABETICAL (default): Sort sounds alphabetically.
283
+ * MANUAL: Sort sounds by manual drag-and-drop.
284
+ */
285
+ export const PLAYLIST_SORT_MODES: Readonly<{
286
+ ALPHABETICAL: 'a';
287
+ MANUAL: 'm';
288
+ }>;
289
+ export type PLAYLIST_SORT_MODES = ValueOf<typeof PLAYLIST_SORT_MODES>;
220
290
 
221
291
  /**
222
292
  * The allowed package types
223
293
  */
224
- export const PACKAGE_TYPES: ['world', 'system', 'module'];
294
+ export const PACKAGE_TYPES: readonly ['world', 'system', 'module'];
295
+ export type PACKAGE_TYPES = ValueOf<typeof PACKAGE_TYPES>;
225
296
 
226
297
  /**
227
298
  * Encode the reasons why a package may be available or unavailable for use
228
299
  */
229
- export const PACKAGE_AVAILABILITY_CODES: {
300
+ export const PACKAGE_AVAILABILITY_CODES: Readonly<{
230
301
  UNKNOWN: -1;
231
302
  REQUIRES_UPDATE: 0;
232
303
  AVAILABLE: 1;
233
304
  REQUIRES_SYSTEM: 2;
234
305
  REQUIRES_DEPENDENCY: 3;
235
306
  REQUIRES_CORE: 4;
236
- };
307
+ }>;
308
+ export type PACKAGE_AVAILABILITY_CODES = ValueOf<typeof PACKAGE_AVAILABILITY_CODES>;
237
309
 
238
310
  /**
239
311
  * A safe password string which can be displayed
@@ -243,22 +315,13 @@ export const PASSWORD_SAFE_STRING: '••••••••••••••
243
315
  /**
244
316
  * The allowed software update channels
245
317
  */
246
- export const SOFTWARE_UPDATE_CHANNELS: {
247
- /**
248
- * @defaultValue `'SETUP.UpdateAlpha'`
249
- */
250
- alpha: string;
251
-
252
- /**
253
- * @defaultValue `'SETUP.UpdateBeta'`
254
- */
255
- beta: string;
256
-
257
- /**
258
- * @defaultValue `'SETUP.UpdateBeta'`
259
- */
260
- release: string;
261
- };
318
+ export const SOFTWARE_UPDATE_CHANNELS: Readonly<{
319
+ stable: 'SETUP.UpdateStable';
320
+ testing: 'SETUP.UpdateTesting';
321
+ development: 'SETUP.UpdateDevelopment';
322
+ prototype: 'SETUP.UpdatePrototype';
323
+ }>;
324
+ export type SOFTWARE_UPDATE_CHANNELS = ValueOf<typeof SOFTWARE_UPDATE_CHANNELS>;
262
325
 
263
326
  /**
264
327
  * The default sorting density for manually ordering child objects within a parent
@@ -268,32 +331,44 @@ export const SORT_INTEGER_DENSITY: 100000;
268
331
  /**
269
332
  * The allowed types of a TableResult document
270
333
  */
271
- export const TABLE_RESULT_TYPES: {
334
+ declare const tableResultTypes: Readonly<{
272
335
  TEXT: 0;
273
- ENTITY: 1;
336
+ DOCUMENT: 1;
274
337
  COMPENDIUM: 2;
275
- };
338
+ /**
339
+ * @deprecated TABLE_RESULT_TYPES.ENTITY is deprecated. Please use TABLE_RESULT_TYPES.DOCUMENT instead.
340
+ */
341
+ get ENTITY(): 1;
342
+ }>;
343
+
344
+ /**
345
+ * The allowed types of a TableResult document
346
+ */
347
+ export const TABLE_RESULT_TYPES: typeof tableResultTypes;
348
+ export type TABLE_RESULT_TYPES = ValueOf<typeof TABLE_RESULT_TYPES>;
276
349
 
277
350
  /**
278
351
  * Define the valid anchor locations for a Tooltip displayed on a Placeable Object
279
352
  */
280
- export const TEXT_ANCHOR_POINTS: {
353
+ export const TEXT_ANCHOR_POINTS: Readonly<{
281
354
  CENTER: 0;
282
355
  BOTTOM: 1;
283
356
  TOP: 2;
284
357
  LEFT: 3;
285
358
  RIGHT: 4;
286
- };
359
+ }>;
360
+ export type TEXT_ANCHOR_POINTS = ValueOf<typeof TEXT_ANCHOR_POINTS>;
287
361
 
288
362
  /**
289
363
  * Define the valid occlusion modes which an overhead tile can use
290
364
  */
291
- export const TILE_OCCLUSION_MODES: {
365
+ export const TILE_OCCLUSION_MODES: Readonly<{
292
366
  NONE: 0;
293
367
  FADE: 1;
294
368
  ROOF: 2;
295
369
  RADIAL: 3;
296
- };
370
+ }>;
371
+ export type TILE_OCCLUSION_MODES = ValueOf<typeof TILE_OCCLUSION_MODES>;
297
372
 
298
373
  /**
299
374
  * Describe the various thresholds of token control upon which to show certain pieces of information
@@ -304,14 +379,15 @@ export const TILE_OCCLUSION_MODES: {
304
379
  * OWNER - always displayed for a GM or for a user who owns the actor
305
380
  * ALWAYS - always displayed for everyone
306
381
  */
307
- export const TOKEN_DISPLAY_MODES: {
382
+ export const TOKEN_DISPLAY_MODES: Readonly<{
308
383
  NONE: 0;
309
384
  CONTROL: 10;
310
385
  OWNER_HOVER: 20;
311
386
  HOVER: 30;
312
387
  OWNER: 40;
313
388
  ALWAYS: 50;
314
- };
389
+ }>;
390
+ export type TOKEN_DISPLAY_MODES = ValueOf<typeof TOKEN_DISPLAY_MODES>;
315
391
 
316
392
  /**
317
393
  * The allowed Token disposition types
@@ -319,68 +395,54 @@ export const TOKEN_DISPLAY_MODES: {
319
395
  * NEUTRAL - Displayed as neutral with a yellow border
320
396
  * FRIENDLY - Displayed as an ally with a cyan border
321
397
  */
322
- export const TOKEN_DISPOSITIONS: {
398
+ export const TOKEN_DISPOSITIONS: Readonly<{
323
399
  HOSTILE: -1;
324
400
  NEUTRAL: 0;
325
401
  FRIENDLY: 1;
326
- };
402
+ }>;
403
+ export type TOKEN_DISPOSITIONS = ValueOf<typeof TOKEN_DISPOSITIONS>;
327
404
 
328
405
  /**
329
406
  * Define the allowed User permission levels.
330
407
  * Each level is assigned a value in ascending order. Higher levels grant more permissions.
331
408
  */
332
- export const USER_ROLES: {
409
+ export const USER_ROLES: Readonly<{
333
410
  NONE: 0;
334
411
  PLAYER: 1;
335
412
  TRUSTED: 2;
336
413
  ASSISTANT: 3;
337
414
  GAMEMASTER: 4;
338
- };
415
+ }>;
416
+ export type USER_ROLES = ValueOf<typeof USER_ROLES>;
339
417
 
340
418
  /**
341
419
  * Invert the User Role mapping to recover role names from a role integer
342
420
  */
343
- export const USER_ROLE_NAMES: { [Key in keyof typeof USER_ROLES as typeof USER_ROLES[Key]]: Key };
421
+ export const USER_ROLE_NAMES: Readonly<{ [Key in keyof typeof USER_ROLES as typeof USER_ROLES[Key]]: Key }>;
422
+ export type USER_ROLE_NAMES = ValueOf<typeof USER_ROLE_NAMES>;
344
423
 
345
- export interface MeasuredTemplateTypes {
424
+ /**
425
+ * An enumeration of the allowed types for a MeasuredTemplate embedded document
426
+ */
427
+ export const MEASURED_TEMPLATE_TYPES: Readonly<{
346
428
  CIRCLE: 'circle';
347
429
  CONE: 'cone';
348
430
  RECTANGLE: 'rect';
349
431
  RAY: 'ray';
350
- }
351
-
352
- /**
353
- * An enumeration of the allowed types for a MeasuredTemplate embedded document
354
- */
355
- export const MEASURED_TEMPLATE_TYPES: MeasuredTemplateTypes;
356
-
357
- /**
358
- * A list of MIME types which are treated as uploaded "media", which are allowed to overwrite existing files.
359
- * Any non-media MIME type is not allowed to replace an existing file.
360
- * @defaultValue
361
- * ```typescript
362
- * [
363
- * "application/json", "application/ogg", "application/pdf",
364
- * "audio/wave", "audio/wav", "audio/webm", "audio/ogg", "audio/midi", "audio/mpeg", "audio/opus", "audio/aac",
365
- * "image/apng", "image/bmp", "image/gif", "image/jpeg", "image/png", "image/svg+xml", "image/tiff", "image/webp",
366
- * "text/plain", "text/markdown",
367
- * "video/mpeg", "video/mp4", "video/ogg"
368
- * ]
369
- * ```
370
- */
371
- export const MEDIA_MIME_TYPES: string[];
432
+ }>;
433
+ export type MEASURED_TEMPLATE_TYPES = ValueOf<typeof MEASURED_TEMPLATE_TYPES>;
372
434
 
373
435
  export interface UserCapability {
374
436
  disableGM: boolean;
375
437
  hint: string;
376
438
  label: string;
377
- defaultRole: UserRole;
439
+ defaultRole: USER_ROLES;
378
440
  }
379
441
 
380
442
  /**
381
443
  * Define the recognized User capabilities which individual Users or role levels may be permitted to perform
382
444
  */
383
- export const USER_PERMISSIONS: {
445
+ export const USER_PERMISSIONS: Readonly<{
384
446
  /**
385
447
  * @defaultValue
386
448
  * ```typescript
@@ -614,7 +676,7 @@ export const USER_PERMISSIONS: {
614
676
  * ```
615
677
  */
616
678
  WALL_DOORS: UserCapability;
617
- };
679
+ }>;
618
680
 
619
681
  /**
620
682
  * The allowed directions of effect that a Wall can have
@@ -622,11 +684,12 @@ export const USER_PERMISSIONS: {
622
684
  * LEFT: The wall collides only when a ray strikes its left side
623
685
  * RIGHT: The wall collides only when a ray strikes its right side
624
686
  */
625
- export const WALL_DIRECTIONS: {
687
+ export const WALL_DIRECTIONS: Readonly<{
626
688
  BOTH: 0;
627
689
  LEFT: 1;
628
690
  RIGHT: 2;
629
- };
691
+ }>;
692
+ export type WALL_DIRECTIONS = ValueOf<typeof WALL_DIRECTIONS>;
630
693
 
631
694
  /**
632
695
  * The allowed door types which a Wall may contain
@@ -634,11 +697,12 @@ export const WALL_DIRECTIONS: {
634
697
  * DOOR: The wall contains a regular door
635
698
  * SECRET: The wall contains a secret door
636
699
  */
637
- export const WALL_DOOR_TYPES: {
700
+ export const WALL_DOOR_TYPES: Readonly<{
638
701
  NONE: 0;
639
702
  DOOR: 1;
640
703
  SECRET: 2;
641
- };
704
+ }>;
705
+ export type WALL_DOOR_TYPES = ValueOf<typeof WALL_DOOR_TYPES>;
642
706
 
643
707
  /**
644
708
  * The allowed door states which may describe a Wall that contains a door
@@ -646,21 +710,18 @@ export const WALL_DOOR_TYPES: {
646
710
  * OPEN: The door is open
647
711
  * LOCKED: The door is closed and locked
648
712
  */
649
- export const WALL_DOOR_STATES: {
713
+ export const WALL_DOOR_STATES: Readonly<{
650
714
  CLOSED: 0;
651
715
  OPEN: 1;
652
716
  LOCKED: 2;
653
- };
717
+ }>;
718
+ export type WALL_DOOR_STATES = ValueOf<typeof WALL_DOOR_STATES>;
654
719
 
655
720
  /**
656
- * The types of movement collision which a Wall may impose
657
- * NONE: Movement does not collide with this wall
658
- * NORMAL: Movement collides with this wall
721
+ * The wall properties which restrict the way interaction occurs with a specific wall
659
722
  */
660
- export const WALL_MOVEMENT_TYPES: {
661
- NONE: 0;
662
- NORMAL: 1;
663
- };
723
+ export const WALL_RESTRICTION_TYPES: readonly ['light', 'sight', 'sound', 'move'];
724
+ export type WALL_RESTRICTION_TYPES = ValueOf<typeof WALL_RESTRICTION_TYPES>;
664
725
 
665
726
  /**
666
727
  * The types of sensory collision which a Wall may impose
@@ -668,82 +729,211 @@ export const WALL_MOVEMENT_TYPES: {
668
729
  * NORMAL: Senses collide with this wall
669
730
  * LIMITED: Senses collide with the second intersection, bypassing the first
670
731
  */
671
- export const WALL_SENSE_TYPES: {
732
+ export const WALL_SENSE_TYPES: Readonly<{
672
733
  NONE: 0;
734
+ LIMITED: 10;
735
+ NORMAL: 20;
736
+ }>;
737
+ export type WALL_SENSE_TYPES = ValueOf<typeof WALL_SENSE_TYPES>;
738
+
739
+ /**
740
+ * The types of movement collision which a Wall may impose
741
+ * NONE: Movement does not collide with this wall
742
+ * NORMAL: Movement collides with this wall
743
+ */
744
+ export const WALL_MOVEMENT_TYPES: Readonly<{
745
+ NONE: typeof WALL_SENSE_TYPES.NONE;
746
+ NORMAL: typeof WALL_SENSE_TYPES.NORMAL;
747
+ }>;
748
+ export type WALL_MOVEMENT_TYPES = ValueOf<typeof WALL_MOVEMENT_TYPES>;
749
+
750
+ /**
751
+ * The possible precedence values a Keybinding might run in
752
+ * PRIORITY: Runs in the first group along with other PRIORITY keybindings
753
+ * NORMAL: Runs after the PRIORITY group along with other NORMAL keybindings
754
+ * DEFERRED: Runs in the last group along with other DEFERRED keybindings
755
+ */
756
+ export const KEYBINDING_PRECEDENCE: Readonly<{
757
+ PRIORITY: 0;
673
758
  NORMAL: 1;
674
- LIMITED: 2;
675
- };
759
+ DEFERRED: 2;
760
+ }>;
761
+ export type KEYBINDING_PRECEDENCE = ValueOf<typeof KEYBINDING_PRECEDENCE>;
676
762
 
677
763
  /**
678
764
  * The allowed set of HTML template extensions
679
- * @defaultValue `["html", "handlebars", "hbs"]`
680
- */
681
- export const HTML_FILE_EXTENSIONS: string[];
682
-
683
- /**
684
- * The supported file extensions for image-type files
685
- * @defaultValue `["jpg", "jpeg", "png", "svg", "webp"]`
686
- */
687
- export const IMAGE_FILE_EXTENSIONS: string[];
688
-
689
- /**
690
- * The supported file extensions for video-type files
691
- * @defaultValue `["mp4", "ogg", "webm", "m4v"]`
692
- */
693
- export const VIDEO_FILE_EXTENSIONS: string[];
694
-
695
- /**
696
- * The supported file extensions for audio-type files
697
- * @defaultValue `["flac", "m4a", "mp3", "ogg", "opus", "wav", "webm"]`
698
- */
699
- export const AUDIO_FILE_EXTENSIONS: string[];
700
-
701
- /**
702
- * @deprecated since 0.8.0
703
- */
704
- export const DRAWING_DEFAULT_VALUES: {
705
- width: 0;
706
- height: 0;
707
- rotation: 0;
708
- z: 0;
709
- hidden: false;
710
- locked: false;
711
- fillType: typeof DRAWING_FILL_TYPES.NONE;
712
- fillAlpha: 0.5;
713
- bezierFactor: 0.0;
714
- strokeAlpha: 1.0;
715
- strokeWidth: 8;
716
- fontSize: 48;
717
- textAlpha: 1.0;
718
- textColor: '#FFFFFF';
719
- };
720
-
721
- export type ActiveEffectMode = ValueOf<typeof ACTIVE_EFFECT_MODES>;
722
- export type ChatMessageType = ValueOf<typeof CHAT_MESSAGE_TYPES>;
723
- export type DiceRollMode = ValueOf<typeof DICE_ROLL_MODES>;
724
- export type DrawingFillType = ValueOf<typeof DRAWING_FILL_TYPES>;
725
- export type DrawingType = ValueOf<typeof DRAWING_TYPES>;
726
- export type EntityPermission = ValueOf<typeof ENTITY_PERMISSIONS>;
727
- export type EntityType = ValueOf<typeof ENTITY_TYPES>;
728
- export type FolderEntityTypes = ValueOf<typeof FOLDER_ENTITY_TYPES>;
729
- export type CompendiumEntityType = ValueOf<typeof COMPENDIUM_ENTITY_TYPES>;
730
- export type GridType = ValueOf<typeof GRID_TYPES>;
731
- export type MacroTypes = ValueOf<typeof CONST.MACRO_TYPES>;
732
- export type MacroScopes = ValueOf<typeof CONST.MACRO_SCOPES>;
733
- export type PackageAvailabilityCode = ValueOf<typeof PACKAGE_AVAILABILITY_CODES>;
734
- export type PackageTypes = ValueOf<typeof PACKAGE_TYPES>;
735
- export type PlaylistMode = ValueOf<typeof PLAYLIST_MODES>;
736
- export type SoftwareUpdateChannel = ValueOf<typeof SOFTWARE_UPDATE_CHANNELS>;
737
- export type SourceType = ValueOf<typeof SOURCE_TYPES>;
738
- export type TableResultType = ValueOf<typeof TABLE_RESULT_TYPES>;
739
- export type TextAnchorPoint = ValueOf<typeof TEXT_ANCHOR_POINTS>;
740
- export type TileOcclusionModes = ValueOf<typeof TILE_OCCLUSION_MODES>;
741
- export type TokenDisplayMode = ValueOf<typeof TOKEN_DISPLAY_MODES>;
742
- export type TokenDisposition = ValueOf<typeof TOKEN_DISPOSITIONS>;
743
- export type UserRole = ValueOf<typeof USER_ROLES>;
744
- export type UserRoleName = ValueOf<typeof USER_ROLE_NAMES>;
745
- export type WallDirection = ValueOf<typeof WALL_DIRECTIONS>;
746
- export type WallDoorState = ValueOf<typeof WALL_DOOR_STATES>;
747
- export type WallDoorType = ValueOf<typeof WALL_DOOR_TYPES>;
748
- export type WallMovementType = ValueOf<typeof WALL_MOVEMENT_TYPES>;
749
- export type WallSenseType = ValueOf<typeof WALL_SENSE_TYPES>;
765
+ */
766
+ export const HTML_FILE_EXTENSIONS: readonly ['html', 'handlebars', 'hbs'];
767
+
768
+ /**
769
+ * The supported file extensions for image-type files, and their corresponding mime types.
770
+ */
771
+ export const IMAGE_FILE_EXTENSIONS: Readonly<{
772
+ apng: 'image/apng';
773
+ avif: 'image/avif';
774
+ bmp: 'image/bmp';
775
+ gif: 'image/gif';
776
+ jpg: 'image/jpeg';
777
+ jpeg: 'image/jpeg';
778
+ png: 'image/png';
779
+ svg: 'image/svg+xml';
780
+ tiff: 'image/tiff';
781
+ webp: 'image/webp';
782
+ }>;
783
+ export type IMAGE_FILE_EXTENSIONS = ValueOf<typeof IMAGE_FILE_EXTENSIONS>;
784
+
785
+ /**
786
+ * The supported file extensions for video-type files, and their corresponding mime types.
787
+ */
788
+ export const VIDEO_FILE_EXTENSIONS: Readonly<{
789
+ m4v: 'video/mp4';
790
+ mp4: 'video/mp4';
791
+ ogg: 'video/ogg';
792
+ webm: 'video/webm';
793
+ }>;
794
+ export type VIDEO_FILE_EXTENSIONS = ValueOf<typeof VIDEO_FILE_EXTENSIONS>;
795
+
796
+ /**
797
+ * The supported file extensions for audio-type files, and their corresponding mime types.
798
+ */
799
+ export const AUDIO_FILE_EXTENSIONS: Readonly<{
800
+ aac: 'audio/aac';
801
+ flac: 'audio/flac';
802
+ m4a: 'audio/mp4';
803
+ mid: 'audio/midi';
804
+ mp3: 'audio/mpeg';
805
+ ogg: 'audio/ogg';
806
+ opus: 'audio/opus';
807
+ wav: 'audio/wav';
808
+ webm: 'audio/webm';
809
+ }>;
810
+ export type AUDIO_FILE_EXTENSIONS = ValueOf<typeof AUDIO_FILE_EXTENSIONS>;
811
+
812
+ /**
813
+ * The supported file extensions for text files, and their corresponding mime types.
814
+ */
815
+ export const TEXT_FILE_EXTENSIONS: Readonly<{
816
+ json: 'application/json';
817
+ md: 'text/markdown';
818
+ pdf: 'application/pdf';
819
+ txt: 'text/plain';
820
+ }>;
821
+ export type TEXT_FILE_EXTENSIONS = ValueOf<typeof TEXT_FILE_EXTENSIONS>;
822
+
823
+ /**
824
+ * A list of MIME types which are treated as uploaded "media", which are allowed to overwrite existing files.
825
+ * Any non-media MIME type is not allowed to replace an existing file.
826
+ */
827
+ export const MEDIA_MIME_TYPES: readonly [
828
+ 'image/apng',
829
+ 'image/avif',
830
+ 'image/bmp',
831
+ 'image/gif',
832
+ 'image/jpeg',
833
+ 'image/jpeg',
834
+ 'image/png',
835
+ 'image/svg+xml',
836
+ 'image/tiff',
837
+ 'image/webp',
838
+ 'video/mp4',
839
+ 'video/mp4',
840
+ 'video/ogg',
841
+ 'video/webm',
842
+ 'audio/aac',
843
+ 'audio/flac',
844
+ 'audio/mp4',
845
+ 'audio/midi',
846
+ 'audio/mpeg',
847
+ 'audio/ogg',
848
+ 'audio/opus',
849
+ 'audio/wav',
850
+ 'audio/webm',
851
+ 'application/json',
852
+ 'text/markdown',
853
+ 'application/pdf',
854
+ 'text/plain'
855
+ ];
856
+
857
+ /**
858
+ * Stores shared commonly used timeouts, measured in MS
859
+ */
860
+ export const TIMEOUTS: Readonly<{
861
+ FOUNDRY_WEBSITE: 10000;
862
+ PACKAGE_REPOSITORY: 5000;
863
+ IP_DISCOVERY: 5000;
864
+ }>;
865
+ export type TIMEOUTS = ValueOf<typeof TIMEOUTS>;
866
+
867
+ /**
868
+ * Enumerate the source types which can be used for an AmbientLight placeable object
869
+ * @deprecated since v9
870
+ */
871
+ export const SOURCE_TYPES: Readonly<{
872
+ LOCAL: 'l';
873
+ GLOBAL: 'g';
874
+ UNIVERSAL: 'u';
875
+ }>;
876
+ /**
877
+ * Enumerate the source types which can be used for an AmbientLight placeable object
878
+ * @deprecated since v9
879
+ */
880
+ export type SOURCE_TYPES = ValueOf<typeof SOURCE_TYPES>;
881
+
882
+ /**
883
+ * Define the allowed Entity class types
884
+ * @deprecated since v9 - use CONST.DOCUMENT_TYPES instead.
885
+ */
886
+ export const ENTITY_TYPES: typeof DOCUMENT_TYPES;
887
+ /**
888
+ * Define the allowed Entity class types
889
+ * @deprecated since v9 - use CONST.DOCUMENT_TYPES instead.
890
+ */
891
+ export type ENTITY_TYPES = ValueOf<typeof ENTITY_TYPES>;
892
+
893
+ /**
894
+ * Define the allowed Document types which Folders may contain
895
+ * @deprecated since v9 - use CONST.FOLDER_DOCUMENT_TYPES instead.
896
+ */
897
+ export const FOLDER_ENTITY_TYPES: typeof FOLDER_DOCUMENT_TYPES;
898
+ /**
899
+ * Define the allowed Document types which Folders may contain
900
+ * @deprecated since v9 - use CONST.FOLDER_DOCUMENT_TYPES instead.
901
+ */
902
+ export type FOLDER_ENTITY_TYPES = ValueOf<typeof FOLDER_ENTITY_TYPES>;
903
+
904
+ /**
905
+ * Define the allowed permission levels for a non-user Entity.
906
+ * Each level is assigned a value in ascending order. Higher levels grant more permissions.
907
+ * @deprecated since v9 - use CONST.DOCUMENT_PERMISSION_LEVELS instead.
908
+ */
909
+ export const ENTITY_PERMISSIONS: typeof DOCUMENT_PERMISSION_LEVELS;
910
+ /**
911
+ * Define the allowed permission levels for a non-user Entity.
912
+ * Each level is assigned a value in ascending order. Higher levels grant more permissions.
913
+ * @deprecated since v9 - use CONST.DOCUMENT_PERMISSION_LEVELS instead.
914
+ */
915
+ export type ENTITY_PERMISSIONS = ValueOf<typeof ENTITY_PERMISSIONS>;
916
+
917
+ /**
918
+ * Define the allowed Entity types which may be dynamically linked in chat
919
+ * @deprecated since v9 - use CONST.DOCUMENT_LINK_TYPES instead.
920
+ */
921
+ export const ENTITY_LINK_TYPES: typeof DOCUMENT_LINK_TYPES;
922
+ /**
923
+ * Define the allowed Entity types which may be dynamically linked in chat
924
+ * @deprecated since v9 - use CONST.DOCUMENT_LINK_TYPES instead.
925
+ */
926
+ export type ENTITY_LINK_TYPES = ValueOf<typeof ENTITY_LINK_TYPES>;
927
+
928
+ /**
929
+ * The allowed Entity types which may exist within a Compendium pack
930
+ * This is a subset of ENTITY_TYPES
931
+ * @deprecated sinve v9 - use CONST.COMPENDIUM_DOCUMENT_TYPES instead.
932
+ */
933
+ export const COMPENDIUM_ENTITY_TYPES: typeof COMPENDIUM_DOCUMENT_TYPES;
934
+ /**
935
+ * The allowed Entity types which may exist within a Compendium pack
936
+ * This is a subset of ENTITY_TYPES
937
+ * @deprecated sinve v9 - use CONST.COMPENDIUM_DOCUMENT_TYPES instead.
938
+ */
939
+ export type COMPENDIUM_ENTITY_TYPES = ValueOf<typeof COMPENDIUM_ENTITY_TYPES>;