@league-of-foundry-developers/foundry-vtt-types 9.280.0 → 12.331.1-beta
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.
- package/README.md +21 -18
- package/index-lenient.d.mts +7 -0
- package/index.d.mts +5 -0
- package/package.json +67 -39
- package/src/foundry/client/apps/app.d.mts +595 -0
- package/src/foundry/client/apps/av/av-config.d.mts +93 -0
- package/src/foundry/client/apps/av/cameras.d.mts +189 -0
- package/src/foundry/client/apps/av/index.d.mts +3 -0
- package/src/foundry/client/apps/dialogs/folder-export.d.mts +16 -0
- package/src/foundry/client/apps/dialogs/index.d.mts +1 -0
- package/src/foundry/client/apps/form.d.mts +469 -0
- package/src/foundry/client/apps/forms/actor.d.mts +176 -0
- package/src/foundry/client/apps/forms/adventure-exporter.d.mts +132 -0
- package/src/foundry/client/apps/forms/adventure-importer.d.mts +85 -0
- package/src/foundry/client/apps/forms/base-sheet.d.mts +45 -0
- package/src/foundry/client/apps/forms/card-config.d.mts +48 -0
- package/src/foundry/client/apps/forms/cards-config.d.mts +141 -0
- package/src/foundry/client/apps/forms/combat-config.d.mts +51 -0
- package/src/foundry/client/apps/forms/combatant-config.d.mts +45 -0
- package/src/foundry/client/apps/forms/default-sheets-config.d.mts +46 -0
- package/src/foundry/client/apps/forms/effect-config.d.mts +77 -0
- package/src/foundry/client/apps/forms/folder-config.d.mts +60 -0
- package/src/foundry/client/apps/forms/fonts.d.mts +168 -0
- package/src/foundry/client/apps/forms/grid-config.d.mts +144 -0
- package/src/foundry/client/apps/forms/image-popout.d.mts +179 -0
- package/src/foundry/client/apps/forms/index.d.mts +26 -0
- package/src/foundry/client/apps/forms/item.d.mts +58 -0
- package/src/foundry/client/apps/forms/journal-page-sheet.d.mts +313 -0
- package/src/foundry/client/apps/forms/journal-sheet.d.mts +312 -0
- package/src/foundry/client/apps/forms/macro-config.d.mts +59 -0
- package/src/foundry/client/apps/forms/measure-template.d.mts +59 -0
- package/src/foundry/client/apps/forms/ownership.d.mts +66 -0
- package/src/foundry/client/apps/forms/playlist-config.d.mts +46 -0
- package/src/foundry/client/apps/forms/playlist-sound-config.d.mts +63 -0
- package/src/foundry/client/apps/forms/roll-table-config.d.mts +160 -0
- package/src/foundry/client/apps/forms/scene-config.d.mts +157 -0
- package/src/foundry/client/apps/forms/sheet-config.d.mts +202 -0
- package/src/foundry/client/apps/forms/user-config.d.mts +71 -0
- package/src/foundry/client/apps/hud/chatbubble.d.mts +113 -0
- package/src/foundry/client/apps/hud/container.d.mts +54 -0
- package/src/foundry/client/apps/hud/controls.d.mts +166 -0
- package/src/foundry/client/apps/hud/hotbar.d.mts +169 -0
- package/src/foundry/client/apps/hud/hud.d.mts +87 -0
- package/src/foundry/client/apps/hud/index.d.mts +9 -0
- package/src/foundry/client/apps/hud/menu.d.mts +77 -0
- package/src/foundry/client/apps/hud/navigation.d.mts +116 -0
- package/src/foundry/client/apps/hud/pause.d.mts +32 -0
- package/src/foundry/client/apps/hud/players.d.mts +82 -0
- package/src/foundry/client/apps/i18n.d.mts +162 -0
- package/src/foundry/client/apps/index.d.mts +10 -0
- package/src/foundry/client/apps/placeables/drawing-config.d.mts +80 -0
- package/src/foundry/client/apps/placeables/drawing-hud.d.mts +31 -0
- package/src/foundry/client/apps/placeables/index.d.mts +10 -0
- package/src/foundry/client/apps/placeables/light-config.d.mts +100 -0
- package/src/foundry/client/apps/placeables/note-config.d.mts +65 -0
- package/src/foundry/client/apps/placeables/sound-config.d.mts +43 -0
- package/src/foundry/client/apps/placeables/tile-config.d.mts +54 -0
- package/src/foundry/client/apps/placeables/tile-hud.d.mts +37 -0
- package/src/foundry/client/apps/placeables/token-config.d.mts +244 -0
- package/src/foundry/client/apps/placeables/token-hud.d.mts +134 -0
- package/src/foundry/client/apps/placeables/wall-config.d.mts +63 -0
- package/src/foundry/client/apps/sidebar/apps/chat-popout.d.mts +39 -0
- package/src/foundry/client/apps/sidebar/apps/client-settings.d.mts +98 -0
- package/src/foundry/client/apps/sidebar/apps/compendium.d.mts +93 -0
- package/src/foundry/client/apps/sidebar/apps/index.d.mts +10 -0
- package/src/foundry/client/apps/sidebar/apps/invitation-links.d.mts +32 -0
- package/src/foundry/client/apps/sidebar/apps/keybindings-config.d.mts +180 -0
- package/src/foundry/client/apps/sidebar/apps/module-management.d.mts +135 -0
- package/src/foundry/client/apps/sidebar/apps/permission-config.d.mts +72 -0
- package/src/foundry/client/apps/sidebar/apps/support-details.d.mts +121 -0
- package/src/foundry/client/apps/sidebar/apps/tours-management.d.mts +54 -0
- package/src/foundry/client/apps/sidebar/apps/world-config.d.mts +57 -0
- package/src/foundry/client/apps/sidebar/directory-tab-mixin.d.mts +276 -0
- package/src/foundry/client/apps/sidebar/document-directory.d.mts +164 -0
- package/src/foundry/client/apps/sidebar/index.d.mts +7 -0
- package/src/foundry/client/apps/sidebar/package-configuration.d.mts +86 -0
- package/src/foundry/client/apps/sidebar/sidebar-tab.d.mts +80 -0
- package/src/foundry/client/apps/sidebar/sidebar.d.mts +95 -0
- package/src/foundry/client/apps/sidebar/tabs/actors-directory.d.mts +20 -0
- package/src/foundry/client/apps/sidebar/tabs/cards-directory.d.mts +12 -0
- package/src/foundry/client/apps/sidebar/tabs/chat-log.d.mts +364 -0
- package/src/foundry/client/apps/sidebar/tabs/combat-tracker.d.mts +156 -0
- package/src/foundry/client/apps/sidebar/tabs/compendium-directory.d.mts +105 -0
- package/src/foundry/client/apps/sidebar/tabs/index.d.mts +12 -0
- package/src/foundry/client/apps/sidebar/tabs/items-directory.d.mts +14 -0
- package/src/foundry/client/apps/sidebar/tabs/journal-directory.d.mts +13 -0
- package/src/foundry/client/apps/sidebar/tabs/macros-directory.d.mts +16 -0
- package/src/foundry/client/apps/sidebar/tabs/playlists-directory.d.mts +275 -0
- package/src/foundry/client/apps/sidebar/tabs/roll-table-directory.d.mts +13 -0
- package/src/foundry/client/apps/sidebar/tabs/scenes-directory.d.mts +34 -0
- package/src/foundry/client/apps/sidebar/tabs/settings.d.mts +72 -0
- package/src/foundry/client/apps/templates.d.mts +546 -0
- package/src/foundry/client/audio/audio.d.mts +390 -0
- package/src/foundry/client/audio/container.d.mts +176 -0
- package/src/foundry/client/audio/index.d.mts +3 -0
- package/src/foundry/client/audio/sound.d.mts +307 -0
- package/src/foundry/client/av/client.d.mts +162 -0
- package/src/foundry/client/av/clients/index.d.mts +1 -0
- package/src/foundry/client/av/clients/simplepeer.d.mts +155 -0
- package/src/foundry/client/av/index.d.mts +4 -0
- package/src/foundry/client/av/master.d.mts +191 -0
- package/src/foundry/client/av/settings.d.mts +315 -0
- package/src/foundry/client/config.d.mts +2856 -0
- package/src/foundry/client/core/clipboard.d.mts +20 -0
- package/src/foundry/client/core/document-index.d.mts +118 -0
- package/src/foundry/client/core/gamepad.d.mts +62 -0
- package/src/foundry/client/core/hooks.d.mts +132 -0
- package/src/foundry/client/core/image.d.mts +190 -0
- package/src/foundry/client/core/index.d.mts +20 -0
- package/src/foundry/client/core/issues.d.mts +102 -0
- package/src/foundry/client/core/keybindings.d.mts +312 -0
- package/src/foundry/client/core/keyboard.d.mts +224 -0
- package/src/foundry/client/core/mouse.d.mts +28 -0
- package/src/foundry/client/core/nue.d.mts +38 -0
- package/src/foundry/client/core/packages.d.mts +185 -0
- package/src/foundry/client/core/settings.d.mts +260 -0
- package/src/foundry/client/core/socket.d.mts +16 -0
- package/src/foundry/client/core/sorting.d.mts +76 -0
- package/src/foundry/client/core/time.d.mts +73 -0
- package/src/foundry/client/core/tooltip.d.mts +198 -0
- package/src/foundry/client/core/tour.d.mts +279 -0
- package/src/foundry/client/core/tours.d.mts +22 -0
- package/src/foundry/client/core/utils.d.mts +71 -0
- package/src/foundry/client/core/video.d.mts +161 -0
- package/src/foundry/client/core/workers.d.mts +128 -0
- package/src/foundry/client/data/abstract/canvas-document.d.mts +63 -0
- package/src/foundry/client/data/abstract/client-document.d.mts +717 -0
- package/src/foundry/client/data/abstract/directory-collection-mixin.d.mts +135 -0
- package/src/foundry/client/data/abstract/document-collection.d.mts +204 -0
- package/src/foundry/client/data/abstract/index.d.mts +5 -0
- package/src/foundry/client/data/abstract/world-collection.d.mts +171 -0
- package/src/foundry/client/data/collections/actors.d.mts +41 -0
- package/src/foundry/client/data/collections/cards.d.mts +12 -0
- package/src/foundry/client/data/collections/combats.d.mts +43 -0
- package/src/foundry/client/data/collections/compendium-collection.d.mts +504 -0
- package/src/foundry/client/data/collections/compendium-folders.d.mts +13 -0
- package/src/foundry/client/data/collections/compendium-packs.d.mts +27 -0
- package/src/foundry/client/data/collections/fog.d.mts +17 -0
- package/src/foundry/client/data/collections/folder.d.mts +27 -0
- package/src/foundry/client/data/collections/index.d.mts +17 -0
- package/src/foundry/client/data/collections/items.d.mts +14 -0
- package/src/foundry/client/data/collections/journal.d.mts +62 -0
- package/src/foundry/client/data/collections/macros.d.mts +32 -0
- package/src/foundry/client/data/collections/messages.d.mts +35 -0
- package/src/foundry/client/data/collections/playlists.d.mts +34 -0
- package/src/foundry/client/data/collections/scenes.d.mts +68 -0
- package/src/foundry/client/data/collections/settings.d.mts +29 -0
- package/src/foundry/client/data/collections/tables.d.mts +21 -0
- package/src/foundry/client/data/collections/users.d.mts +50 -0
- package/src/foundry/client/data/documents/active-effect.d.mts +348 -0
- package/src/foundry/client/data/documents/actor-delta.d.mts +88 -0
- package/src/foundry/client/data/documents/actor.d.mts +301 -0
- package/src/foundry/client/data/documents/adventure.d.mts +94 -0
- package/src/foundry/client/data/documents/ambient-light.d.mts +32 -0
- package/src/foundry/client/data/documents/ambient-sound.d.mts +19 -0
- package/src/foundry/client/data/documents/card.d.mts +115 -0
- package/src/foundry/client/data/documents/cards.d.mts +342 -0
- package/src/foundry/client/data/documents/chat-message.d.mts +218 -0
- package/src/foundry/client/data/documents/combat.d.mts +315 -0
- package/src/foundry/client/data/documents/combatant.d.mts +90 -0
- package/src/foundry/client/data/documents/drawing.d.mts +24 -0
- package/src/foundry/client/data/documents/fog-exploration.d.mts +51 -0
- package/src/foundry/client/data/documents/folder.d.mts +123 -0
- package/src/foundry/client/data/documents/index.d.mts +30 -0
- package/src/foundry/client/data/documents/item.d.mts +55 -0
- package/src/foundry/client/data/documents/journal-entry-page.d.mts +219 -0
- package/src/foundry/client/data/documents/journal-entry.d.mts +71 -0
- package/src/foundry/client/data/documents/macro.d.mts +73 -0
- package/src/foundry/client/data/documents/measured-template.d.mts +29 -0
- package/src/foundry/client/data/documents/note.d.mts +35 -0
- package/src/foundry/client/data/documents/playlist-sound.d.mts +114 -0
- package/src/foundry/client/data/documents/playlist.d.mts +196 -0
- package/src/foundry/client/data/documents/scene.d.mts +228 -0
- package/src/foundry/client/data/documents/setting.d.mts +43 -0
- package/src/foundry/client/data/documents/table-result.d.mts +29 -0
- package/src/foundry/client/data/documents/table.d.mts +310 -0
- package/src/foundry/client/data/documents/tile.d.mts +21 -0
- package/src/foundry/client/data/documents/token.d.mts +342 -0
- package/src/foundry/client/data/documents/user.d.mts +153 -0
- package/src/foundry/client/data/documents/wall.d.mts +19 -0
- package/src/foundry/client/data/index.d.mts +3 -0
- package/src/foundry/client/game.d.mts +702 -0
- package/src/foundry/client/head.d.mts +87 -0
- package/src/foundry/client/hooks.d.mts +1184 -0
- package/src/foundry/client/index.d.mts +13 -0
- package/src/foundry/client/pixi/board.d.mts +927 -0
- package/src/foundry/client/pixi/core/containers/base-canvas-group.d.mts +83 -0
- package/src/foundry/client/pixi/core/containers/cached-container.d.mts +116 -0
- package/src/foundry/client/pixi/core/containers/full-canvas-container.d.mts +35 -0
- package/src/foundry/client/pixi/core/containers/index.d.mts +8 -0
- package/src/foundry/client/pixi/core/containers/point-source-mesh.d.mts +62 -0
- package/src/foundry/client/pixi/core/containers/quad-mesh.d.mts +43 -0
- package/src/foundry/client/pixi/core/containers/quadtree.d.mts +199 -0
- package/src/foundry/client/pixi/core/containers/sprite-mesh.d.mts +326 -0
- package/src/foundry/client/pixi/core/containers/unbound-container.d.mts +21 -0
- package/src/foundry/client/pixi/core/index.d.mts +4 -0
- package/src/foundry/client/pixi/core/interaction/canvas-animation.d.mts +160 -0
- package/src/foundry/client/pixi/core/interaction/control-icon.d.mts +80 -0
- package/src/foundry/client/pixi/core/interaction/index.d.mts +8 -0
- package/src/foundry/client/pixi/core/interaction/mouse-handler.d.mts +264 -0
- package/src/foundry/client/pixi/core/interaction/ping.d.mts +58 -0
- package/src/foundry/client/pixi/core/interaction/pings/chevron.d.mts +73 -0
- package/src/foundry/client/pixi/core/interaction/pings/index.d.mts +2 -0
- package/src/foundry/client/pixi/core/interaction/pings/pulse.d.mts +115 -0
- package/src/foundry/client/pixi/core/interaction/render-flags.d.mts +103 -0
- package/src/foundry/client/pixi/core/interaction/resize-handle.d.mts +52 -0
- package/src/foundry/client/pixi/core/interaction/targets.d.mts +45 -0
- package/src/foundry/client/pixi/core/loader.d.mts +206 -0
- package/src/foundry/client/pixi/core/shapes/index.d.mts +6 -0
- package/src/foundry/client/pixi/core/shapes/limited-angle-polygon.d.mts +119 -0
- package/src/foundry/client/pixi/core/shapes/polygon-helpers.d.mts +31 -0
- package/src/foundry/client/pixi/core/shapes/polygon-mesher.d.mts +110 -0
- package/src/foundry/client/pixi/core/shapes/precise-text.d.mts +27 -0
- package/src/foundry/client/pixi/core/shapes/ray.d.mts +165 -0
- package/src/foundry/client/pixi/core/shapes/source-polygon.d.mts +251 -0
- package/src/foundry/client/pixi/extensions/circle.d.mts +130 -0
- package/src/foundry/client/pixi/extensions/index.d.mts +3 -0
- package/src/foundry/client/pixi/extensions/polygon.d.mts +152 -0
- package/src/foundry/client/pixi/extensions/rectangle.d.mts +226 -0
- package/src/foundry/client/pixi/groups/effects.d.mts +189 -0
- package/src/foundry/client/pixi/groups/environment.d.mts +80 -0
- package/src/foundry/client/pixi/groups/hidden.d.mts +40 -0
- package/src/foundry/client/pixi/groups/index.d.mts +7 -0
- package/src/foundry/client/pixi/groups/interface.d.mts +74 -0
- package/src/foundry/client/pixi/groups/overlay.d.mts +18 -0
- package/src/foundry/client/pixi/groups/primary.d.mts +207 -0
- package/src/foundry/client/pixi/groups/rendered.d.mts +18 -0
- package/src/foundry/client/pixi/index.d.mts +10 -0
- package/src/foundry/client/pixi/layers/base/canvas-layer.d.mts +79 -0
- package/src/foundry/client/pixi/layers/base/index.d.mts +3 -0
- package/src/foundry/client/pixi/layers/base/interaction-layer.d.mts +139 -0
- package/src/foundry/client/pixi/layers/base/placeables-layer.d.mts +598 -0
- package/src/foundry/client/pixi/layers/controls/cursor.d.mts +27 -0
- package/src/foundry/client/pixi/layers/controls/door.d.mts +70 -0
- package/src/foundry/client/pixi/layers/controls/hud.d.mts +114 -0
- package/src/foundry/client/pixi/layers/controls/index.d.mts +5 -0
- package/src/foundry/client/pixi/layers/controls/layer.d.mts +229 -0
- package/src/foundry/client/pixi/layers/controls/ruler.d.mts +316 -0
- package/src/foundry/client/pixi/layers/effects/background-effects.d.mts +34 -0
- package/src/foundry/client/pixi/layers/effects/coloration-effects.d.mts +27 -0
- package/src/foundry/client/pixi/layers/effects/illumination-effects.d.mts +74 -0
- package/src/foundry/client/pixi/layers/effects/index.d.mts +6 -0
- package/src/foundry/client/pixi/layers/effects/visibility.d.mts +194 -0
- package/src/foundry/client/pixi/layers/effects/weather/particles/effect.d.mts +47 -0
- package/src/foundry/client/pixi/layers/effects/weather/particles/index.d.mts +2 -0
- package/src/foundry/client/pixi/layers/effects/weather/particles/leaves.d.mts +20 -0
- package/src/foundry/client/pixi/layers/effects/weather-effects.d.mts +172 -0
- package/src/foundry/client/pixi/layers/grid/highlight.d.mts +32 -0
- package/src/foundry/client/pixi/layers/grid/index.d.mts +2 -0
- package/src/foundry/client/pixi/layers/grid/layer.d.mts +225 -0
- package/src/foundry/client/pixi/layers/index.d.mts +6 -0
- package/src/foundry/client/pixi/layers/masks/depth.d.mts +37 -0
- package/src/foundry/client/pixi/layers/masks/index.d.mts +3 -0
- package/src/foundry/client/pixi/layers/masks/occlusion.d.mts +55 -0
- package/src/foundry/client/pixi/layers/masks/vision.d.mts +85 -0
- package/src/foundry/client/pixi/layers/placeables/drawings.d.mts +92 -0
- package/src/foundry/client/pixi/layers/placeables/index.d.mts +8 -0
- package/src/foundry/client/pixi/layers/placeables/lighting.d.mts +137 -0
- package/src/foundry/client/pixi/layers/placeables/notes.d.mts +99 -0
- package/src/foundry/client/pixi/layers/placeables/sounds.d.mts +129 -0
- package/src/foundry/client/pixi/layers/placeables/templates.d.mts +60 -0
- package/src/foundry/client/pixi/layers/placeables/tiles.d.mts +114 -0
- package/src/foundry/client/pixi/layers/placeables/tokens.d.mts +180 -0
- package/src/foundry/client/pixi/layers/placeables/walls.d.mts +210 -0
- package/src/foundry/client/pixi/perception/clockwise-sweep.d.mts +169 -0
- package/src/foundry/client/pixi/perception/color-manager.d.mts +86 -0
- package/src/foundry/client/pixi/perception/detection-mode.d.mts +196 -0
- package/src/foundry/client/pixi/perception/fog.d.mts +102 -0
- package/src/foundry/client/pixi/perception/index.d.mts +7 -0
- package/src/foundry/client/pixi/perception/perception-manager.d.mts +166 -0
- package/src/foundry/client/pixi/perception/vision-mode.d.mts +197 -0
- package/src/foundry/client/pixi/perception/weiler-atherton-clipping.d.mts +152 -0
- package/src/foundry/client/pixi/placeable.d.mts +586 -0
- package/src/foundry/client/pixi/placeables/drawing.d.mts +292 -0
- package/src/foundry/client/pixi/placeables/index.d.mts +9 -0
- package/src/foundry/client/pixi/placeables/light.d.mts +140 -0
- package/src/foundry/client/pixi/placeables/note.d.mts +114 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/drawing-shape.d.mts +143 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/index.d.mts +5 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/occludable-object.d.mts +175 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-canvas-object.d.mts +159 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/tile-mesh.d.mts +52 -0
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/token-mesh.d.mts +62 -0
- package/src/foundry/client/pixi/placeables/sound.d.mts +133 -0
- package/src/foundry/client/pixi/placeables/template.d.mts +211 -0
- package/src/foundry/client/pixi/placeables/tile.d.mts +284 -0
- package/src/foundry/client/pixi/placeables/token.d.mts +825 -0
- package/src/foundry/client/pixi/placeables/wall.d.mts +275 -0
- package/src/foundry/client/pixi/webgl/extensions/batch-renderer.d.mts +60 -0
- package/src/foundry/client/pixi/webgl/extensions/batch-shader-generator.d.mts +21 -0
- package/src/foundry/client/pixi/webgl/extensions/blend-modes.d.mts +53 -0
- package/src/foundry/client/pixi/webgl/extensions/index.d.mts +3 -0
- package/src/foundry/client/pixi/webgl/helpers/framebugger-snapshot.d.mts +22 -0
- package/src/foundry/client/pixi/webgl/helpers/index.d.mts +3 -0
- package/src/foundry/client/pixi/webgl/helpers/smooth-noise.d.mts +61 -0
- package/src/foundry/client/pixi/webgl/helpers/texture-extractor.d.mts +80 -0
- package/src/foundry/client/pixi/webgl/index.d.mts +3 -0
- package/src/foundry/client/pixi/webgl/shaders/base.d.mts +691 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/index.d.mts +3 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/lighting.d.mts +642 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/vision.d.mts +216 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/base.d.mts +102 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/effect.d.mts +38 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/fog.d.mts +34 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/index.d.mts +5 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/rain.d.mts +24 -0
- package/src/foundry/client/pixi/webgl/shaders/effects/weather/snow.d.mts +20 -0
- package/src/foundry/client/pixi/webgl/shaders/filters/blur.d.mts +163 -0
- package/src/foundry/client/pixi/webgl/shaders/filters/filters.d.mts +462 -0
- package/src/foundry/client/pixi/webgl/shaders/filters/fxaa.d.mts +74 -0
- package/src/foundry/client/pixi/webgl/shaders/filters/index.d.mts +3 -0
- package/src/foundry/client/pixi/webgl/shaders/index.d.mts +4 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/color-adjustment.d.mts +101 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/fog-of-war.d.mts +16 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/index.d.mts +6 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/inverse-occlusion.d.mts +47 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/invisibility.d.mts +28 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/monochromatic.d.mts +30 -0
- package/src/foundry/client/pixi/webgl/shaders/samplers/occlusion.d.mts +69 -0
- package/src/foundry/client/pixi/workers/index.d.mts +1 -0
- package/src/foundry/client/pixi/workers/texture-worker.d.mts +125 -0
- package/src/foundry/client/tours/canvas-tour.d.mts +9 -0
- package/src/foundry/client/tours/index.d.mts +3 -0
- package/src/foundry/client/tours/setup-tour.d.mts +26 -0
- package/src/foundry/client/tours/sidebar-tour.d.mts +9 -0
- package/src/foundry/client/ui/context.d.mts +213 -0
- package/src/foundry/client/ui/dialog.d.mts +326 -0
- package/src/foundry/client/ui/drag.d.mts +128 -0
- package/src/foundry/client/ui/dragdrop.d.mts +124 -0
- package/src/foundry/client/ui/editor.d.mts +546 -0
- package/src/foundry/client/ui/filepicker.d.mts +477 -0
- package/src/foundry/client/ui/filter.d.mts +148 -0
- package/src/foundry/client/ui/forms.d.mts +85 -0
- package/src/foundry/client/ui/index.d.mts +12 -0
- package/src/foundry/client/ui/notifications.d.mts +136 -0
- package/src/foundry/client/ui/prosemirror.d.mts +171 -0
- package/src/foundry/client/ui/secrets.d.mts +75 -0
- package/src/foundry/client/ui/tabs.d.mts +117 -0
- package/src/foundry/client-esm/applications/_module.d.mts +25 -0
- package/src/foundry/client-esm/applications/_types.d.mts +38 -0
- package/src/foundry/client-esm/applications/api/_module.d.mts +9 -0
- package/src/foundry/client-esm/applications/api/application.d.mts +705 -0
- package/src/foundry/client-esm/applications/api/dialog.d.mts +268 -0
- package/src/foundry/client-esm/applications/api/document-sheet.d.mts +119 -0
- package/src/foundry/client-esm/applications/api/handlebars-application.d.mts +180 -0
- package/src/foundry/client-esm/applications/apps/_module.d.mts +7 -0
- package/src/foundry/client-esm/applications/apps/compendium-art-config.d.mts +53 -0
- package/src/foundry/client-esm/applications/apps/permission-config.d.mts +60 -0
- package/src/foundry/client-esm/applications/dice/_module.d.mts +6 -0
- package/src/foundry/client-esm/applications/dice/roll-resolver.d.mts +98 -0
- package/src/foundry/client-esm/applications/elements/_module.d.mts +16 -0
- package/src/foundry/client-esm/applications/elements/color-picker.d.mts +26 -0
- package/src/foundry/client-esm/applications/elements/document-tags.d.mts +90 -0
- package/src/foundry/client-esm/applications/elements/file-picker.d.mts +62 -0
- package/src/foundry/client-esm/applications/elements/form-element.d.mts +106 -0
- package/src/foundry/client-esm/applications/elements/hue-slider.d.mts +20 -0
- package/src/foundry/client-esm/applications/elements/multi-select.d.mts +95 -0
- package/src/foundry/client-esm/applications/elements/prosemirror-editor.d.mts +53 -0
- package/src/foundry/client-esm/applications/elements/range-picker.d.mts +41 -0
- package/src/foundry/client-esm/applications/elements/string-tags.d.mts +73 -0
- package/src/foundry/client-esm/applications/forms/fields.d.mts +219 -0
- package/src/foundry/client-esm/applications/sheets/_module.d.mts +12 -0
- package/src/foundry/client-esm/applications/sheets/actor-sheet.d.mts +31 -0
- package/src/foundry/client-esm/applications/sheets/ambient-light-config.d.mts +18 -0
- package/src/foundry/client-esm/applications/sheets/ambient-sound-config.d.mts +18 -0
- package/src/foundry/client-esm/applications/sheets/item-sheet.d.mts +22 -0
- package/src/foundry/client-esm/applications/sheets/region-behavior-config.d.mts +13 -0
- package/src/foundry/client-esm/applications/sheets/region-config.d.mts +13 -0
- package/src/foundry/client-esm/applications/sheets/user-config.d.mts +18 -0
- package/src/foundry/client-esm/applications/ui/_module.d.mts +6 -0
- package/src/foundry/client-esm/applications/ui/region-legend.d.mts +12 -0
- package/src/foundry/client-esm/audio/_module.d.mts +13 -0
- package/src/foundry/client-esm/audio/_types.d.mts +1 -0
- package/src/foundry/client-esm/canvas/_module.d.mts +11 -0
- package/src/foundry/client-esm/canvas/edges/_module.d.mts +9 -0
- package/src/foundry/client-esm/canvas/edges/collision.d.mts +93 -0
- package/src/foundry/client-esm/canvas/edges/edge.d.mts +184 -0
- package/src/foundry/client-esm/canvas/edges/edges.d.mts +23 -0
- package/src/foundry/client-esm/canvas/edges/vertex.d.mts +134 -0
- package/src/foundry/client-esm/canvas/regions/_module.d.mts +10 -0
- package/src/foundry/client-esm/canvas/scene-manager.d.mts +1 -0
- package/src/foundry/client-esm/canvas/smaa/blend.d.mts +6 -0
- package/src/foundry/client-esm/canvas/smaa/edges.d.mts +6 -0
- package/src/foundry/client-esm/canvas/smaa/smaa.d.mts +56 -0
- package/src/foundry/client-esm/canvas/smaa/weights.d.mts +6 -0
- package/src/foundry/client-esm/canvas/sources/_module.d.mts +15 -0
- package/src/foundry/client-esm/canvas/sources/base-effect-source.d.mts +243 -0
- package/src/foundry/client-esm/canvas/sources/base-light-source.d.mts +162 -0
- package/src/foundry/client-esm/canvas/sources/global-light-source.d.mts +47 -0
- package/src/foundry/client-esm/canvas/sources/point-darkness-source.d.mts +77 -0
- package/src/foundry/client-esm/canvas/sources/point-effect-source.d.mts +91 -0
- package/src/foundry/client-esm/canvas/sources/point-light-source.d.mts +43 -0
- package/src/foundry/client-esm/canvas/sources/point-movement-source.d.mts +15 -0
- package/src/foundry/client-esm/canvas/sources/point-sound-source.d.mts +29 -0
- package/src/foundry/client-esm/canvas/sources/point-vision-source.d.mts +206 -0
- package/src/foundry/client-esm/canvas/sources/rendered-effect-source.d.mts +328 -0
- package/src/foundry/client-esm/canvas/tokens/_module.d.mts +7 -0
- package/src/foundry/client-esm/client.d.mts +291 -0
- package/src/foundry/client-esm/data/_module.d.mts +8 -0
- package/src/foundry/client-esm/data/client-backend.d.mts +52 -0
- package/src/foundry/client-esm/data/region-behaviors/_module.d.mts +14 -0
- package/src/foundry/client-esm/dice/_module.d.mts +13 -0
- package/src/foundry/client-esm/dice/_types.d.mts +61 -0
- package/src/foundry/client-esm/dice/parser.d.mts +205 -0
- package/src/foundry/client-esm/dice/roll.d.mts +645 -0
- package/src/foundry/client-esm/dice/terms/_module.d.mts +17 -0
- package/src/foundry/client-esm/dice/terms/coin.d.mts +68 -0
- package/src/foundry/client-esm/dice/terms/dice.d.mts +381 -0
- package/src/foundry/client-esm/dice/terms/die.d.mts +241 -0
- package/src/foundry/client-esm/dice/terms/fate.d.mts +50 -0
- package/src/foundry/client-esm/dice/terms/function.d.mts +104 -0
- package/src/foundry/client-esm/dice/terms/numeric.d.mts +56 -0
- package/src/foundry/client-esm/dice/terms/operator.d.mts +55 -0
- package/src/foundry/client-esm/dice/terms/parenthetical.d.mts +105 -0
- package/src/foundry/client-esm/dice/terms/pool.d.mts +278 -0
- package/src/foundry/client-esm/dice/terms/string.d.mts +34 -0
- package/src/foundry/client-esm/dice/terms/term.d.mts +160 -0
- package/src/foundry/client-esm/dice/twister.d.mts +134 -0
- package/src/foundry/client-esm/helpers/_module.d.mts +8 -0
- package/src/foundry/client-esm/helpers/_types.d.mts +51 -0
- package/src/foundry/client-esm/helpers/compendium-art.d.mts +47 -0
- package/src/foundry/clipper/clipper.d.mts +927 -0
- package/src/foundry/clipper/index.d.mts +1 -0
- package/src/foundry/common/abstract/_types.d.mts +274 -0
- package/src/foundry/common/abstract/backend.d.mts +190 -0
- package/src/foundry/common/abstract/data.d.mts +457 -0
- package/src/foundry/common/abstract/document.d.mts +1372 -0
- package/src/foundry/common/abstract/embedded-collection-delta.d.mts +96 -0
- package/src/foundry/common/abstract/embedded-collection.d.mts +252 -0
- package/src/foundry/common/abstract/module.d.mts +13 -0
- package/src/foundry/common/abstract/singleton-collection.d.mts +19 -0
- package/src/foundry/common/abstract/socket.d.mts +36 -0
- package/src/foundry/common/abstract/type-data.d.mts +337 -0
- package/src/foundry/common/config.d.mts +302 -0
- package/src/foundry/common/constants.d.mts +2054 -0
- package/src/foundry/common/data/data.d.mts +667 -0
- package/src/foundry/common/data/fields.d.mts +3388 -0
- package/src/foundry/common/data/module.d.mts +9 -0
- package/src/foundry/common/data/validation-failure.d.mts +174 -0
- package/src/foundry/common/data/validators.d.mts +30 -0
- package/src/foundry/common/documents/_module.d.mts +35 -0
- package/src/foundry/common/documents/_types.d.mts +143 -0
- package/src/foundry/common/documents/active-effect.d.mts +229 -0
- package/src/foundry/common/documents/actor-delta.d.mts +132 -0
- package/src/foundry/common/documents/actor.d.mts +209 -0
- package/src/foundry/common/documents/adventure.d.mts +212 -0
- package/src/foundry/common/documents/ambient-light.d.mts +107 -0
- package/src/foundry/common/documents/ambient-sound.d.mts +142 -0
- package/src/foundry/common/documents/card.d.mts +254 -0
- package/src/foundry/common/documents/cards.d.mts +191 -0
- package/src/foundry/common/documents/chat-message.d.mts +208 -0
- package/src/foundry/common/documents/combat.d.mts +124 -0
- package/src/foundry/common/documents/combatant.d.mts +127 -0
- package/src/foundry/common/documents/drawing.d.mts +255 -0
- package/src/foundry/common/documents/fog-exploration.d.mts +110 -0
- package/src/foundry/common/documents/folder.d.mts +130 -0
- package/src/foundry/common/documents/item.d.mts +181 -0
- package/src/foundry/common/documents/journal-entry-page.d.mts +229 -0
- package/src/foundry/common/documents/journal-entry.d.mts +133 -0
- package/src/foundry/common/documents/macro.d.mts +190 -0
- package/src/foundry/common/documents/measured-template.d.mts +183 -0
- package/src/foundry/common/documents/module.d.mts +35 -0
- package/src/foundry/common/documents/note.d.mts +195 -0
- package/src/foundry/common/documents/playlist-sound.d.mts +131 -0
- package/src/foundry/common/documents/playlist.d.mts +160 -0
- package/src/foundry/common/documents/roll-table.d.mts +153 -0
- package/src/foundry/common/documents/scene.d.mts +395 -0
- package/src/foundry/common/documents/setting.d.mts +88 -0
- package/src/foundry/common/documents/table-result.d.mts +157 -0
- package/src/foundry/common/documents/tile.d.mts +204 -0
- package/src/foundry/common/documents/token.d.mts +515 -0
- package/src/foundry/common/documents/user.d.mts +247 -0
- package/src/foundry/common/documents/wall.d.mts +196 -0
- package/src/foundry/common/grid/_module.d.mts +10 -0
- package/src/foundry/common/grid/base.d.mts +640 -0
- package/src/foundry/common/grid/grid-hex.d.mts +55 -0
- package/src/foundry/common/grid/gridless.d.mts +71 -0
- package/src/foundry/common/grid/hexagonal.d.mts +391 -0
- package/src/foundry/common/grid/square.d.mts +100 -0
- package/src/foundry/common/packages/base-module.d.mts +46 -0
- package/src/foundry/common/packages/base-package.d.mts +677 -0
- package/src/foundry/common/packages/base-system.d.mts +90 -0
- package/src/foundry/common/packages/base-world.d.mts +116 -0
- package/src/foundry/common/packages/module.d.mts +28 -0
- package/src/foundry/common/packages/sub-types.d.mts +42 -0
- package/src/foundry/common/primitives/array.d.mts +56 -0
- package/src/foundry/common/primitives/date.d.mts +24 -0
- package/src/foundry/common/primitives/math.d.mts +103 -0
- package/src/foundry/common/primitives/module.d.mts +8 -0
- package/src/foundry/common/primitives/number.d.mts +91 -0
- package/src/foundry/common/primitives/regex.d.mts +12 -0
- package/src/foundry/common/primitives/regexp.d.mts +12 -0
- package/src/foundry/common/primitives/set.d.mts +105 -0
- package/src/foundry/common/primitives/string.d.mts +58 -0
- package/src/foundry/common/primitives/url.d.mts +18 -0
- package/src/foundry/common/prosemirror/_module.d.mts +82 -0
- package/src/foundry/common/prosemirror/click-handler.d.mts +34 -0
- package/src/foundry/common/prosemirror/content-link-plugin.d.mts +47 -0
- package/src/foundry/common/prosemirror/dirty-plugin.d.mts +13 -0
- package/src/foundry/common/prosemirror/dom-parser.d.mts +9 -0
- package/src/foundry/common/prosemirror/dropdown.d.mts +65 -0
- package/src/foundry/common/prosemirror/extensions.d.mts +12 -0
- package/src/foundry/common/prosemirror/highlight-matches-plugin.d.mts +82 -0
- package/src/foundry/common/prosemirror/image-plugin.d.mts +82 -0
- package/src/foundry/common/prosemirror/index.d.mts +22 -0
- package/src/foundry/common/prosemirror/input-rules.d.mts +34 -0
- package/src/foundry/common/prosemirror/keymaps.d.mts +47 -0
- package/src/foundry/common/prosemirror/menu.d.mts +255 -0
- package/src/foundry/common/prosemirror/paste-transformer.d.mts +22 -0
- package/src/foundry/common/prosemirror/plugin.d.mts +24 -0
- package/src/foundry/common/prosemirror/schema/attribute-capture.d.mts +39 -0
- package/src/foundry/common/prosemirror/schema/core.d.mts +51 -0
- package/src/foundry/common/prosemirror/schema/image-link-node.d.mts +29 -0
- package/src/foundry/common/prosemirror/schema/image-node.d.mts +19 -0
- package/src/foundry/common/prosemirror/schema/index.d.mts +12 -0
- package/src/foundry/common/prosemirror/schema/link-mark.d.mts +30 -0
- package/src/foundry/common/prosemirror/schema/lists.d.mts +55 -0
- package/src/foundry/common/prosemirror/schema/marks.d.mts +44 -0
- package/src/foundry/common/prosemirror/schema/other.d.mts +149 -0
- package/src/foundry/common/prosemirror/schema/schema-definition.d.mts +39 -0
- package/src/foundry/common/prosemirror/schema/secret-node.d.mts +27 -0
- package/src/foundry/common/prosemirror/schema/tables.d.mts +106 -0
- package/src/foundry/common/prosemirror/schema/utils.d.mts +37 -0
- package/src/foundry/common/prosemirror/schema.d.mts +138 -0
- package/src/foundry/common/prosemirror/string-serializer.d.mts +120 -0
- package/src/foundry/common/prosemirror/util.d.mts +43 -0
- package/src/foundry/common/types.d.mts +332 -0
- package/src/foundry/common/utils/bitmask.d.mts +110 -0
- package/src/foundry/common/utils/collection.d.mts +176 -0
- package/src/foundry/common/utils/color.d.mts +291 -0
- package/src/foundry/common/utils/event-emitter.d.mts +62 -0
- package/src/foundry/common/utils/geometry.d.mts +198 -0
- package/src/foundry/common/utils/helpers.d.mts +752 -0
- package/src/foundry/common/utils/http.d.mts +52 -0
- package/src/foundry/common/utils/iterable-weak-map.d.mts +80 -0
- package/src/foundry/common/utils/iterable-weak-set.d.mts +47 -0
- package/src/foundry/common/utils/logging.d.mts +42 -0
- package/src/foundry/common/utils/module.d.mts +18 -0
- package/src/foundry/common/utils/semaphore.d.mts +82 -0
- package/src/foundry/common/utils/string-tree.d.mts +95 -0
- package/src/foundry/common/utils/word-tree.d.mts +66 -0
- package/src/foundry/index.d.mts +5 -0
- package/src/foundry/public/index.d.mts +1 -0
- package/src/foundry/public/scripts/earcut-edges/earcut-edges.d.mts +11 -0
- package/src/foundry/public/scripts/earcut-edges/index.d.mts +1 -0
- package/src/foundry/public/scripts/index.d.mts +1 -0
- package/src/index.d.mts +2 -0
- package/src/types/augments/index.d.mts +4 -0
- package/src/types/augments/pixi.d.mts +38 -0
- package/src/types/augments/simple-peer.d.mts +13 -0
- package/src/types/augments/socket.io-client.d.mts +12 -0
- package/src/types/augments/tinyMCE.d.mts +72 -0
- package/src/types/config.d.mts +331 -0
- package/src/types/configuredDocuments.d.mts +103 -0
- package/src/types/helperTypes.d.mts +261 -0
- package/src/types/index.d.mts +4 -0
- package/src/types/utils.d.mts +406 -0
- package/index-lenient.d.ts +0 -10
- package/index.d.ts +0 -4
- package/src/foundry/client/apps/app.d.ts +0 -560
- package/src/foundry/client/apps/av/av-config.d.ts +0 -85
- package/src/foundry/client/apps/av/cameras.d.ts +0 -174
- package/src/foundry/client/apps/av/index.d.ts +0 -3
- package/src/foundry/client/apps/form.d.ts +0 -384
- package/src/foundry/client/apps/forms/actor.d.ts +0 -192
- package/src/foundry/client/apps/forms/card-config.d.ts +0 -51
- package/src/foundry/client/apps/forms/cards-config.d.ts +0 -128
- package/src/foundry/client/apps/forms/combat-config.d.ts +0 -41
- package/src/foundry/client/apps/forms/combatant-config.d.ts +0 -49
- package/src/foundry/client/apps/forms/effect-config.d.ts +0 -65
- package/src/foundry/client/apps/forms/folder-config.d.ts +0 -63
- package/src/foundry/client/apps/forms/grid-config.d.ts +0 -151
- package/src/foundry/client/apps/forms/image-popout.d.ts +0 -166
- package/src/foundry/client/apps/forms/index.d.ts +0 -20
- package/src/foundry/client/apps/forms/item.d.ts +0 -71
- package/src/foundry/client/apps/forms/journal-sheet.d.ts +0 -107
- package/src/foundry/client/apps/forms/macro-config.d.ts +0 -71
- package/src/foundry/client/apps/forms/measure-template.d.ts +0 -53
- package/src/foundry/client/apps/forms/permission.d.ts +0 -58
- package/src/foundry/client/apps/forms/playlist-config.d.ts +0 -43
- package/src/foundry/client/apps/forms/playlist-sound-config.d.ts +0 -61
- package/src/foundry/client/apps/forms/roll-table-config.d.ts +0 -175
- package/src/foundry/client/apps/forms/scene-config.d.ts +0 -148
- package/src/foundry/client/apps/forms/sheet-config.d.ts +0 -184
- package/src/foundry/client/apps/forms/user-config.d.ts +0 -74
- package/src/foundry/client/apps/hud/chatbubble.d.ts +0 -89
- package/src/foundry/client/apps/hud/container.d.ts +0 -46
- package/src/foundry/client/apps/hud/controls.d.ts +0 -156
- package/src/foundry/client/apps/hud/hotbar.d.ts +0 -143
- package/src/foundry/client/apps/hud/hud.d.ts +0 -84
- package/src/foundry/client/apps/hud/index.d.ts +0 -9
- package/src/foundry/client/apps/hud/menu.d.ts +0 -71
- package/src/foundry/client/apps/hud/navigation.d.ts +0 -110
- package/src/foundry/client/apps/hud/pause.d.ts +0 -20
- package/src/foundry/client/apps/hud/players.d.ts +0 -55
- package/src/foundry/client/apps/i18n.d.ts +0 -136
- package/src/foundry/client/apps/index.d.ts +0 -9
- package/src/foundry/client/apps/placeables/drawing-config.d.ts +0 -99
- package/src/foundry/client/apps/placeables/drawing-hud.d.ts +0 -32
- package/src/foundry/client/apps/placeables/index.d.ts +0 -10
- package/src/foundry/client/apps/placeables/light-config.d.ts +0 -95
- package/src/foundry/client/apps/placeables/note-config.d.ts +0 -57
- package/src/foundry/client/apps/placeables/sound-config.d.ts +0 -47
- package/src/foundry/client/apps/placeables/tile-config.d.ts +0 -55
- package/src/foundry/client/apps/placeables/tile-hud.d.ts +0 -37
- package/src/foundry/client/apps/placeables/token-config.d.ts +0 -226
- package/src/foundry/client/apps/placeables/token-hud.d.ts +0 -140
- package/src/foundry/client/apps/placeables/wall-config.d.ts +0 -75
- package/src/foundry/client/apps/sidebar/apps/chat-popout.d.ts +0 -34
- package/src/foundry/client/apps/sidebar/apps/client-settings.d.ts +0 -116
- package/src/foundry/client/apps/sidebar/apps/compendium.d.ts +0 -86
- package/src/foundry/client/apps/sidebar/apps/controls-reference.d.ts +0 -30
- package/src/foundry/client/apps/sidebar/apps/index.d.ts +0 -10
- package/src/foundry/client/apps/sidebar/apps/invitation-links.d.ts +0 -37
- package/src/foundry/client/apps/sidebar/apps/keybindings-config.d.ts +0 -247
- package/src/foundry/client/apps/sidebar/apps/module-management.d.ts +0 -120
- package/src/foundry/client/apps/sidebar/apps/permission-config.d.ts +0 -64
- package/src/foundry/client/apps/sidebar/apps/support-details.d.ts +0 -76
- package/src/foundry/client/apps/sidebar/apps/world-config.d.ts +0 -77
- package/src/foundry/client/apps/sidebar/index.d.ts +0 -5
- package/src/foundry/client/apps/sidebar/sidebar.d.ts +0 -102
- package/src/foundry/client/apps/sidebar/tab-base.d.ts +0 -68
- package/src/foundry/client/apps/sidebar/tab-directory.d.ts +0 -236
- package/src/foundry/client/apps/sidebar/tabs/actors-directory.d.ts +0 -16
- package/src/foundry/client/apps/sidebar/tabs/cards-directory.d.ts +0 -6
- package/src/foundry/client/apps/sidebar/tabs/chat-log.d.ts +0 -351
- package/src/foundry/client/apps/sidebar/tabs/combat-tracker.d.ts +0 -205
- package/src/foundry/client/apps/sidebar/tabs/compendium-directory.d.ts +0 -77
- package/src/foundry/client/apps/sidebar/tabs/index.d.ts +0 -12
- package/src/foundry/client/apps/sidebar/tabs/items-directory.d.ts +0 -10
- package/src/foundry/client/apps/sidebar/tabs/journal-directory.d.ts +0 -11
- package/src/foundry/client/apps/sidebar/tabs/macros-directory.d.ts +0 -12
- package/src/foundry/client/apps/sidebar/tabs/playlists-directory.d.ts +0 -306
- package/src/foundry/client/apps/sidebar/tabs/roll-table-directory.d.ts +0 -9
- package/src/foundry/client/apps/sidebar/tabs/scenes-directory.d.ts +0 -18
- package/src/foundry/client/apps/sidebar/tabs/settings.d.ts +0 -88
- package/src/foundry/client/apps/templates.d.ts +0 -425
- package/src/foundry/client/audio/audio.d.ts +0 -343
- package/src/foundry/client/audio/container.d.ts +0 -175
- package/src/foundry/client/audio/index.d.ts +0 -3
- package/src/foundry/client/audio/sound.d.ts +0 -303
- package/src/foundry/client/av/client.d.ts +0 -158
- package/src/foundry/client/av/clients/index.d.ts +0 -1
- package/src/foundry/client/av/clients/simplepeer.d.ts +0 -151
- package/src/foundry/client/av/index.d.ts +0 -4
- package/src/foundry/client/av/master.d.ts +0 -187
- package/src/foundry/client/av/settings.d.ts +0 -236
- package/src/foundry/client/config.d.ts +0 -1425
- package/src/foundry/client/core/gamepad.d.ts +0 -53
- package/src/foundry/client/core/hooks.d.ts +0 -967
- package/src/foundry/client/core/image.d.ts +0 -129
- package/src/foundry/client/core/index.d.ts +0 -13
- package/src/foundry/client/core/keybindings.d.ts +0 -298
- package/src/foundry/client/core/keyboard.d.ts +0 -247
- package/src/foundry/client/core/mouse.d.ts +0 -18
- package/src/foundry/client/core/nue.d.ts +0 -34
- package/src/foundry/client/core/settings.d.ts +0 -222
- package/src/foundry/client/core/socket.d.ts +0 -46
- package/src/foundry/client/core/sorting.d.ts +0 -78
- package/src/foundry/client/core/time.d.ts +0 -67
- package/src/foundry/client/core/utils.d.ts +0 -33
- package/src/foundry/client/core/video.d.ts +0 -65
- package/src/foundry/client/data/abstract/canvas-document.d.ts +0 -70
- package/src/foundry/client/data/abstract/client-backend.d.ts +0 -206
- package/src/foundry/client/data/abstract/client-document.d.ts +0 -439
- package/src/foundry/client/data/abstract/document-collection.d.ts +0 -192
- package/src/foundry/client/data/abstract/index.d.ts +0 -5
- package/src/foundry/client/data/abstract/world-collection.d.ts +0 -167
- package/src/foundry/client/data/collections/actors.d.ts +0 -35
- package/src/foundry/client/data/collections/cards.d.ts +0 -8
- package/src/foundry/client/data/collections/combats.d.ts +0 -43
- package/src/foundry/client/data/collections/compendium.d.ts +0 -321
- package/src/foundry/client/data/collections/fog.d.ts +0 -7
- package/src/foundry/client/data/collections/folder.d.ts +0 -27
- package/src/foundry/client/data/collections/index.d.ts +0 -15
- package/src/foundry/client/data/collections/items.d.ts +0 -10
- package/src/foundry/client/data/collections/journal.d.ts +0 -26
- package/src/foundry/client/data/collections/macros.d.ts +0 -26
- package/src/foundry/client/data/collections/messages.d.ts +0 -39
- package/src/foundry/client/data/collections/playlists.d.ts +0 -41
- package/src/foundry/client/data/collections/scenes.d.ts +0 -62
- package/src/foundry/client/data/collections/settings.d.ts +0 -25
- package/src/foundry/client/data/collections/tables.d.ts +0 -17
- package/src/foundry/client/data/collections/users.d.ts +0 -43
- package/src/foundry/client/data/documents/active-effect.d.ts +0 -172
- package/src/foundry/client/data/documents/actor.d.ts +0 -231
- package/src/foundry/client/data/documents/ambient-light.d.ts +0 -18
- package/src/foundry/client/data/documents/ambient-sound.d.ts +0 -9
- package/src/foundry/client/data/documents/card.d.ts +0 -133
- package/src/foundry/client/data/documents/cards.d.ts +0 -376
- package/src/foundry/client/data/documents/chat-message.d.ts +0 -267
- package/src/foundry/client/data/documents/combat.d.ts +0 -227
- package/src/foundry/client/data/documents/combatant.d.ts +0 -104
- package/src/foundry/client/data/documents/drawing.d.ts +0 -19
- package/src/foundry/client/data/documents/fog-exploration.d.ts +0 -64
- package/src/foundry/client/data/documents/folder.d.ts +0 -115
- package/src/foundry/client/data/documents/index.d.ts +0 -27
- package/src/foundry/client/data/documents/item.d.ts +0 -59
- package/src/foundry/client/data/documents/journal-entry.d.ts +0 -71
- package/src/foundry/client/data/documents/macro.d.ts +0 -60
- package/src/foundry/client/data/documents/measured-template.d.ts +0 -21
- package/src/foundry/client/data/documents/note.d.ts +0 -19
- package/src/foundry/client/data/documents/playlist-sound.d.ts +0 -117
- package/src/foundry/client/data/documents/playlist.d.ts +0 -192
- package/src/foundry/client/data/documents/scene.d.ts +0 -465
- package/src/foundry/client/data/documents/setting.d.ts +0 -35
- package/src/foundry/client/data/documents/table-result.d.ts +0 -30
- package/src/foundry/client/data/documents/table.d.ts +0 -220
- package/src/foundry/client/data/documents/tile.d.ts +0 -13
- package/src/foundry/client/data/documents/token.d.ts +0 -281
- package/src/foundry/client/data/documents/user.d.ts +0 -155
- package/src/foundry/client/data/documents/wall.d.ts +0 -9
- package/src/foundry/client/data/index.d.ts +0 -3
- package/src/foundry/client/dice/dice/coin.d.ts +0 -49
- package/src/foundry/client/dice/dice/die.d.ts +0 -230
- package/src/foundry/client/dice/dice/fate.d.ts +0 -37
- package/src/foundry/client/dice/dice/index.d.ts +0 -3
- package/src/foundry/client/dice/index.d.ts +0 -5
- package/src/foundry/client/dice/roll.d.ts +0 -495
- package/src/foundry/client/dice/term.d.ts +0 -123
- package/src/foundry/client/dice/terms/dice.d.ts +0 -277
- package/src/foundry/client/dice/terms/index.d.ts +0 -7
- package/src/foundry/client/dice/terms/math.d.ts +0 -69
- package/src/foundry/client/dice/terms/numeric.d.ts +0 -53
- package/src/foundry/client/dice/terms/operator.d.ts +0 -18
- package/src/foundry/client/dice/terms/parenthetical.d.ts +0 -51
- package/src/foundry/client/dice/terms/pool.d.ts +0 -235
- package/src/foundry/client/dice/terms/string.d.ts +0 -31
- package/src/foundry/client/dice/twister.d.ts +0 -134
- package/src/foundry/client/game.d.ts +0 -682
- package/src/foundry/client/head.d.ts +0 -44
- package/src/foundry/client/index.d.ts +0 -12
- package/src/foundry/client/pixi/board.d.ts +0 -626
- package/src/foundry/client/pixi/core/containers/cached-container.d.ts +0 -64
- package/src/foundry/client/pixi/core/containers/index.d.ts +0 -3
- package/src/foundry/client/pixi/core/containers/quadtree.d.ts +0 -166
- package/src/foundry/client/pixi/core/containers/sampler-mesh.d.ts +0 -22
- package/src/foundry/client/pixi/core/culling.d.ts +0 -37
- package/src/foundry/client/pixi/core/index.d.ts +0 -5
- package/src/foundry/client/pixi/core/interaction/canvas-animation.d.ts +0 -148
- package/src/foundry/client/pixi/core/interaction/control-icon.d.ts +0 -58
- package/src/foundry/client/pixi/core/interaction/index.d.ts +0 -5
- package/src/foundry/client/pixi/core/interaction/mouse-handler.d.ts +0 -323
- package/src/foundry/client/pixi/core/interaction/resize-handle.d.ts +0 -48
- package/src/foundry/client/pixi/core/interaction/targets.d.ts +0 -51
- package/src/foundry/client/pixi/core/loader.d.ts +0 -157
- package/src/foundry/client/pixi/core/shapes/index.d.ts +0 -5
- package/src/foundry/client/pixi/core/shapes/normalized-rectangle.d.ts +0 -31
- package/src/foundry/client/pixi/core/shapes/polygon-helpers.d.ts +0 -263
- package/src/foundry/client/pixi/core/shapes/precise-text.d.ts +0 -18
- package/src/foundry/client/pixi/core/shapes/ray.d.ts +0 -200
- package/src/foundry/client/pixi/core/shapes/source-polygon.d.ts +0 -110
- package/src/foundry/client/pixi/groups/effects.d.ts +0 -29
- package/src/foundry/client/pixi/groups/index.d.ts +0 -3
- package/src/foundry/client/pixi/groups/interface.d.ts +0 -27
- package/src/foundry/client/pixi/groups/primary.d.ts +0 -40
- package/src/foundry/client/pixi/index.d.ts +0 -10
- package/src/foundry/client/pixi/layer.d.ts +0 -105
- package/src/foundry/client/pixi/layers/controls/cursor.d.ts +0 -27
- package/src/foundry/client/pixi/layers/controls/door.d.ts +0 -67
- package/src/foundry/client/pixi/layers/controls/hud.d.ts +0 -117
- package/src/foundry/client/pixi/layers/controls/index.d.ts +0 -4
- package/src/foundry/client/pixi/layers/controls/ruler.d.ts +0 -207
- package/src/foundry/client/pixi/layers/controls.d.ts +0 -144
- package/src/foundry/client/pixi/layers/drawings.d.ts +0 -116
- package/src/foundry/client/pixi/layers/effects/effect.d.ts +0 -133
- package/src/foundry/client/pixi/layers/effects/index.d.ts +0 -4
- package/src/foundry/client/pixi/layers/effects/leaves.d.ts +0 -79
- package/src/foundry/client/pixi/layers/effects/rain.d.ts +0 -107
- package/src/foundry/client/pixi/layers/effects/snow.d.ts +0 -62
- package/src/foundry/client/pixi/layers/effects.d.ts +0 -61
- package/src/foundry/client/pixi/layers/grid/grid.d.ts +0 -171
- package/src/foundry/client/pixi/layers/grid/hex.d.ts +0 -118
- package/src/foundry/client/pixi/layers/grid/highlight.d.ts +0 -28
- package/src/foundry/client/pixi/layers/grid/index.d.ts +0 -4
- package/src/foundry/client/pixi/layers/grid/square.d.ts +0 -48
- package/src/foundry/client/pixi/layers/grid.d.ts +0 -204
- package/src/foundry/client/pixi/layers/index.d.ts +0 -15
- package/src/foundry/client/pixi/layers/lighting.d.ts +0 -229
- package/src/foundry/client/pixi/layers/map.d.ts +0 -263
- package/src/foundry/client/pixi/layers/notes.d.ts +0 -64
- package/src/foundry/client/pixi/layers/sight.d.ts +0 -313
- package/src/foundry/client/pixi/layers/sounds.d.ts +0 -112
- package/src/foundry/client/pixi/layers/templates.d.ts +0 -51
- package/src/foundry/client/pixi/layers/tokens.d.ts +0 -169
- package/src/foundry/client/pixi/layers/walls.d.ts +0 -321
- package/src/foundry/client/pixi/perception/clockwise-sweep.d.ts +0 -406
- package/src/foundry/client/pixi/perception/index.d.ts +0 -2
- package/src/foundry/client/pixi/perception/perception-manager.d.ts +0 -107
- package/src/foundry/client/pixi/placeable.d.ts +0 -414
- package/src/foundry/client/pixi/placeables/drawing.d.ts +0 -289
- package/src/foundry/client/pixi/placeables/index.d.ts +0 -8
- package/src/foundry/client/pixi/placeables/light.d.ts +0 -126
- package/src/foundry/client/pixi/placeables/note.d.ts +0 -67
- package/src/foundry/client/pixi/placeables/sound.d.ts +0 -131
- package/src/foundry/client/pixi/placeables/template.d.ts +0 -153
- package/src/foundry/client/pixi/placeables/tile.d.ts +0 -315
- package/src/foundry/client/pixi/placeables/token.d.ts +0 -722
- package/src/foundry/client/pixi/placeables/wall.d.ts +0 -268
- package/src/foundry/client/pixi/placeables.d.ts +0 -520
- package/src/foundry/client/pixi/sources/base-source.d.ts +0 -145
- package/src/foundry/client/pixi/sources/index.d.ts +0 -4
- package/src/foundry/client/pixi/sources/light-source.d.ts +0 -413
- package/src/foundry/client/pixi/sources/sound-source.d.ts +0 -45
- package/src/foundry/client/pixi/sources/vision-source.d.ts +0 -123
- package/src/foundry/client/pixi/webgl/base.d.ts +0 -69
- package/src/foundry/client/pixi/webgl/blend_modes.d.ts +0 -33
- package/src/foundry/client/pixi/webgl/filters.d.ts +0 -182
- package/src/foundry/client/pixi/webgl/index.d.ts +0 -5
- package/src/foundry/client/pixi/webgl/lighting.d.ts +0 -480
- package/src/foundry/client/pixi/webgl/sampler.d.ts +0 -19
- package/src/foundry/client/ui/context.d.ts +0 -136
- package/src/foundry/client/ui/dialog.d.ts +0 -286
- package/src/foundry/client/ui/drag.d.ts +0 -105
- package/src/foundry/client/ui/dragdrop.d.ts +0 -118
- package/src/foundry/client/ui/editor.d.ts +0 -321
- package/src/foundry/client/ui/filepicker.d.ts +0 -510
- package/src/foundry/client/ui/filter.d.ts +0 -106
- package/src/foundry/client/ui/forms.d.ts +0 -47
- package/src/foundry/client/ui/index.d.ts +0 -10
- package/src/foundry/client/ui/notifications.d.ts +0 -110
- package/src/foundry/client/ui/tabs.d.ts +0 -103
- package/src/foundry/common/abstract/backend.mjs.d.ts +0 -253
- package/src/foundry/common/abstract/data.mjs.d.ts +0 -316
- package/src/foundry/common/abstract/document.mjs.d.ts +0 -838
- package/src/foundry/common/abstract/embedded-collection.mjs.d.ts +0 -79
- package/src/foundry/common/abstract/module.mjs.d.ts +0 -6
- package/src/foundry/common/config.mjs/index.d.ts +0 -1
- package/src/foundry/common/config.mjs/releaseData.d.ts +0 -100
- package/src/foundry/common/constants.mjs.d.ts +0 -940
- package/src/foundry/common/data/data.mjs/activeEffectData.d.ts +0 -168
- package/src/foundry/common/data/data.mjs/actorData.d.ts +0 -219
- package/src/foundry/common/data/data.mjs/adventureData.d.ts +0 -166
- package/src/foundry/common/data/data.mjs/ambientLightData.d.ts +0 -154
- package/src/foundry/common/data/data.mjs/ambientSoundData.d.ts +0 -195
- package/src/foundry/common/data/data.mjs/animationData.d.ts +0 -91
- package/src/foundry/common/data/data.mjs/cardData.d.ts +0 -264
- package/src/foundry/common/data/data.mjs/cardFaceData.d.ts +0 -67
- package/src/foundry/common/data/data.mjs/cardsData.d.ts +0 -237
- package/src/foundry/common/data/data.mjs/chatMessageData.d.ts +0 -220
- package/src/foundry/common/data/data.mjs/chatSpeakerData.d.ts +0 -80
- package/src/foundry/common/data/data.mjs/combatData.d.ts +0 -149
- package/src/foundry/common/data/data.mjs/combatantData.d.ts +0 -136
- package/src/foundry/common/data/data.mjs/darknessActivation.d.ts +0 -55
- package/src/foundry/common/data/data.mjs/drawingData.d.ts +0 -407
- package/src/foundry/common/data/data.mjs/effectChangeData.d.ts +0 -80
- package/src/foundry/common/data/data.mjs/effectDurationData.d.ts +0 -109
- package/src/foundry/common/data/data.mjs/fogExplorationData.d.ts +0 -115
- package/src/foundry/common/data/data.mjs/folderData.d.ts +0 -155
- package/src/foundry/common/data/data.mjs/index.d.ts +0 -31
- package/src/foundry/common/data/data.mjs/itemData.d.ts +0 -184
- package/src/foundry/common/data/data.mjs/journalEntryData.d.ts +0 -132
- package/src/foundry/common/data/data.mjs/lightData.d.ts +0 -227
- package/src/foundry/common/data/data.mjs/macroData.d.ts +0 -199
- package/src/foundry/common/data/data.mjs/measuredTemplateData.d.ts +0 -212
- package/src/foundry/common/data/data.mjs/noteData.d.ts +0 -233
- package/src/foundry/common/data/data.mjs/playlistData.d.ts +0 -201
- package/src/foundry/common/data/data.mjs/playlistSoundData.d.ts +0 -159
- package/src/foundry/common/data/data.mjs/prototypeTokenData.d.ts +0 -75
- package/src/foundry/common/data/data.mjs/rollTableData.d.ts +0 -189
- package/src/foundry/common/data/data.mjs/sceneData.d.ts +0 -665
- package/src/foundry/common/data/data.mjs/settingData.d.ts +0 -86
- package/src/foundry/common/data/data.mjs/tableResultData.d.ts +0 -167
- package/src/foundry/common/data/data.mjs/tileData.d.ts +0 -246
- package/src/foundry/common/data/data.mjs/tileOcclusion.d.ts +0 -62
- package/src/foundry/common/data/data.mjs/tokenBarData.d.ts +0 -47
- package/src/foundry/common/data/data.mjs/tokenData.d.ts +0 -505
- package/src/foundry/common/data/data.mjs/userData.d.ts +0 -177
- package/src/foundry/common/data/data.mjs/videoData.d.ts +0 -70
- package/src/foundry/common/data/data.mjs/wallData.d.ts +0 -222
- package/src/foundry/common/data/fields.mjs.d.ts +0 -526
- package/src/foundry/common/data/module.mjs.d.ts +0 -3
- package/src/foundry/common/data/validators.mjs.d.ts +0 -56
- package/src/foundry/common/documents.mjs/baseActiveEffect.d.ts +0 -44
- package/src/foundry/common/documents.mjs/baseActor.d.ts +0 -68
- package/src/foundry/common/documents.mjs/baseAdventure.d.ts +0 -38
- package/src/foundry/common/documents.mjs/baseAmbientLight.d.ts +0 -31
- package/src/foundry/common/documents.mjs/baseAmbientSound.d.ts +0 -29
- package/src/foundry/common/documents.mjs/baseCard.d.ts +0 -58
- package/src/foundry/common/documents.mjs/baseCards.d.ts +0 -39
- package/src/foundry/common/documents.mjs/baseChatMessage.d.ts +0 -49
- package/src/foundry/common/documents.mjs/baseCombat.d.ts +0 -40
- package/src/foundry/common/documents.mjs/baseCombatant.d.ts +0 -48
- package/src/foundry/common/documents.mjs/baseDrawing.d.ts +0 -54
- package/src/foundry/common/documents.mjs/baseFogExploration.d.ts +0 -41
- package/src/foundry/common/documents.mjs/baseFolder.d.ts +0 -30
- package/src/foundry/common/documents.mjs/baseItem.d.ts +0 -57
- package/src/foundry/common/documents.mjs/baseJournalEntry.d.ts +0 -26
- package/src/foundry/common/documents.mjs/baseMacro.d.ts +0 -42
- package/src/foundry/common/documents.mjs/baseMeasuredTemplate.d.ts +0 -66
- package/src/foundry/common/documents.mjs/baseNote.d.ts +0 -39
- package/src/foundry/common/documents.mjs/basePlaylist.d.ts +0 -32
- package/src/foundry/common/documents.mjs/basePlaylistSound.d.ts +0 -37
- package/src/foundry/common/documents.mjs/baseRollTable.d.ts +0 -31
- package/src/foundry/common/documents.mjs/baseScene.d.ts +0 -120
- package/src/foundry/common/documents.mjs/baseSetting.d.ts +0 -38
- package/src/foundry/common/documents.mjs/baseTableResult.d.ts +0 -52
- package/src/foundry/common/documents.mjs/baseTile.d.ts +0 -29
- package/src/foundry/common/documents.mjs/baseToken.d.ts +0 -44
- package/src/foundry/common/documents.mjs/baseUser.d.ts +0 -102
- package/src/foundry/common/documents.mjs/baseWall.d.ts +0 -43
- package/src/foundry/common/documents.mjs/index.d.ts +0 -28
- package/src/foundry/common/module.mjs.d.ts +0 -114
- package/src/foundry/common/packages.mjs/index.d.ts +0 -8
- package/src/foundry/common/packages.mjs/moduleData.d.ts +0 -55
- package/src/foundry/common/packages.mjs/packageAuthorData.d.ts +0 -58
- package/src/foundry/common/packages.mjs/packageCompendiumData.d.ts +0 -88
- package/src/foundry/common/packages.mjs/packageData.d.ts +0 -319
- package/src/foundry/common/packages.mjs/packageDependencyData.d.ts +0 -69
- package/src/foundry/common/packages.mjs/packageLanguageData.d.ts +0 -75
- package/src/foundry/common/packages.mjs/systemData.d.ts +0 -58
- package/src/foundry/common/packages.mjs/tagPackageAvailability.d.ts +0 -9
- package/src/foundry/common/packages.mjs/worldData.d.ts +0 -76
- package/src/foundry/common/types.mjs.d.ts +0 -299
- package/src/foundry/common/utils/collection.mjs.d.ts +0 -151
- package/src/foundry/common/utils/geometry.mjs.d.ts +0 -148
- package/src/foundry/common/utils/helpers.mjs.d.ts +0 -498
- package/src/foundry/common/utils/http.mjs.d.ts +0 -52
- package/src/foundry/common/utils/module.mjs.d.ts +0 -5
- package/src/foundry/common/utils/primitives.mjs.d.ts +0 -287
- package/src/foundry/common/utils/semaphore.mjs.d.ts +0 -83
- package/src/foundry/index.d.ts +0 -3
- package/src/foundry/templates/index.d.ts +0 -1
- package/src/foundry/templates/views/layouts/main.hbs.d.ts +0 -11
- package/src/index.d.ts +0 -2
- package/src/types/augments/index.d.ts +0 -6
- package/src/types/augments/pixiGraphicsSmooth.d.ts +0 -7
- package/src/types/augments/pixiLegacyGraphics.d.ts +0 -7
- package/src/types/augments/pixiParticles.d.ts +0 -7
- package/src/types/augments/simple-peer.d.ts +0 -13
- package/src/types/augments/socket.io-client.d.ts +0 -12
- package/src/types/augments/tinyMCE.d.ts +0 -82
- package/src/types/config.d.ts +0 -183
- package/src/types/helperTypes.d.ts +0 -151
- package/src/types/index.d.ts +0 -3
- package/src/types/utils.d.ts +0 -143
- /package/src/foundry/client/apps/av/{camera-popout.d.ts → camera-popout.d.mts} +0 -0
- /package/src/foundry/client/{tail.d.ts → tail.d.mts} +0 -0
@@ -0,0 +1,1184 @@
|
|
1
|
+
import type { EditorState } from "prosemirror-state";
|
2
|
+
import type { DeepPartial, EmptyObject, ValueOf } from "../../types/utils.d.mts";
|
3
|
+
import type Document from "../common/abstract/document.d.mts";
|
4
|
+
import type { EffectChangeData } from "../common/documents/_types.d.mts";
|
5
|
+
import type { ProseMirrorDropDown } from "../common/prosemirror/menu.d.mts";
|
6
|
+
import type { DropData } from "./data/abstract/client-document.d.mts";
|
7
|
+
import type { OccludableObject } from "./pixi/placeables/primary-canvas-objects/occludable-object.d.mts";
|
8
|
+
|
9
|
+
// eslint-disable-next-line import/no-named-as-default
|
10
|
+
import type ProseMirrorMenu from "../common/prosemirror/menu.d.mts";
|
11
|
+
|
12
|
+
declare global {
|
13
|
+
/**
|
14
|
+
* This namespace contains typescript specific type definitions for the {@link Hooks} callback functions. It contains an
|
15
|
+
* interface ({@link Hooks.StaticCallbacks}) for callbacks with static names. There are more function types in the
|
16
|
+
* namespace for the dynamic hooks, whose names are generated at runtime. There is also a union of all of the dynamic
|
17
|
+
* hooks ({@link Hooks.DynamicCallbacks}).
|
18
|
+
*
|
19
|
+
* Callback types remarked to be called with {@link Hooks.callAll} do not care about the return value of the callback.
|
20
|
+
* Callback types remarked to be called with {@link Hooks.call} do care about the return value and will stop executing
|
21
|
+
* remaining callbacks if `false` is returned. If a callback type does not have such a remark, pay attention to the
|
22
|
+
* return value documentation.
|
23
|
+
*
|
24
|
+
* @example Using a callback type with a static name
|
25
|
+
* ```typescript
|
26
|
+
* Hooks.on("updateWorldTime", (worldTime, dt) => {
|
27
|
+
* worldTime; // number
|
28
|
+
* dt; // number
|
29
|
+
* // [...]
|
30
|
+
* })
|
31
|
+
* ```
|
32
|
+
*
|
33
|
+
* @example Using a callback with a dynamic name and generic parameter
|
34
|
+
* ```typescript
|
35
|
+
* Hooks.on<Hooks.CloseApplication<FormApplication>>("closeFormApplication", (app, jq) => {
|
36
|
+
* app; // FormApplication
|
37
|
+
* jq; // JQuery
|
38
|
+
* // [...]
|
39
|
+
* })
|
40
|
+
* ```
|
41
|
+
*
|
42
|
+
* @example Using the `error` callback type
|
43
|
+
* ```typescript
|
44
|
+
* Hooks.on("error", (...args) => {
|
45
|
+
* if (args[0] === "Canvas#draw")
|
46
|
+
* args[2].layer // CanvasLayer
|
47
|
+
* // [...]
|
48
|
+
* })
|
49
|
+
* ```
|
50
|
+
*/
|
51
|
+
namespace Hooks {
|
52
|
+
interface OnOptions {
|
53
|
+
/** Only trigger the hooked function once */
|
54
|
+
once?: boolean;
|
55
|
+
}
|
56
|
+
|
57
|
+
interface StaticCallbacks {
|
58
|
+
/** Core lifecycle */
|
59
|
+
|
60
|
+
/**
|
61
|
+
* A hook event that fires as Foundry is initializing, right before any initialization tasks have begun.
|
62
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
63
|
+
* @see {@link Game#initialize}
|
64
|
+
*/
|
65
|
+
init: () => void;
|
66
|
+
|
67
|
+
/**
|
68
|
+
* A hook event that fires once Localization translations have been loaded and are ready for use.
|
69
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
70
|
+
* @see {@link Localization#initialize}
|
71
|
+
*/
|
72
|
+
i18nInit: () => void;
|
73
|
+
|
74
|
+
/**
|
75
|
+
* A hook event that fires when Foundry has finished initializing but
|
76
|
+
* before the game state has been set up. Fires before any Documents, UI
|
77
|
+
* applications, or the Canvas have been initialized.
|
78
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
79
|
+
* @see {@link Game#setupGame}
|
80
|
+
*/
|
81
|
+
setup: () => void;
|
82
|
+
|
83
|
+
/**
|
84
|
+
* A hook event that fires when the game is fully ready.
|
85
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
86
|
+
* @see {@link Game#setupGame}
|
87
|
+
*/
|
88
|
+
ready: () => void;
|
89
|
+
|
90
|
+
/**
|
91
|
+
* A hook event that fires whenever foundry experiences an error.
|
92
|
+
*
|
93
|
+
* @param location - The method where the error was caught.
|
94
|
+
* @param err - The error.
|
95
|
+
* @param data - Additional data that might be provided, based on the nature of the error.
|
96
|
+
* (default: `{}`)
|
97
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
98
|
+
* @see {@link Hooks.onError}
|
99
|
+
*/
|
100
|
+
error: (...args: ValueOf<ErrorCallbackParameters>) => void;
|
101
|
+
|
102
|
+
/** Game */
|
103
|
+
|
104
|
+
/**
|
105
|
+
* A hook event that fires when the game is paused or un-paused.
|
106
|
+
* @param paused - Is the game now paused (true) or un-paused (false)
|
107
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
108
|
+
* @see {@link Game#togglePause}
|
109
|
+
*/
|
110
|
+
pauseGame: (paused: boolean) => void;
|
111
|
+
|
112
|
+
/**
|
113
|
+
* A hook event that fires when the World time has been updated.
|
114
|
+
* @param worldTime - The new canonical World time
|
115
|
+
* @param delta - The time delta
|
116
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
117
|
+
* @see {@link GameTime#onUpdateWorldTime}
|
118
|
+
*/
|
119
|
+
// Note: Double-listed in the official docs, possible this moves to under Socket
|
120
|
+
updateWorldTime: (worldTime: number, delta: number) => void;
|
121
|
+
|
122
|
+
/** CanvasLifecycle */
|
123
|
+
|
124
|
+
/**
|
125
|
+
* A hook event that fires immediately prior to PIXI Application construction with the configuration parameters.
|
126
|
+
* @param canvasConfig - Canvas configuration parameters that will be used to initialize the PIXI.Application
|
127
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
128
|
+
*/
|
129
|
+
canvasConfig: (canvasConfig: ConstructorParameters<typeof PIXI.Application>[0]) => void;
|
130
|
+
|
131
|
+
/**
|
132
|
+
* A hook event that fires when the Canvas is initialized.
|
133
|
+
* @param canvas - the Canvas instance being initialized
|
134
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
135
|
+
* @see {@link Canvas#draw}
|
136
|
+
*/
|
137
|
+
canvasInit: (canvas: Canvas) => void;
|
138
|
+
|
139
|
+
/**
|
140
|
+
* A hook event that fires when the Canvas is panned.
|
141
|
+
* @param canvas - The Canvas instance
|
142
|
+
* @param view - The applied camera position
|
143
|
+
* @remarks When called during animated panning, the callback is called on every tick.
|
144
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
145
|
+
* @see {@link Canvas#pan}
|
146
|
+
* @see {@link Canvas#animatePan}
|
147
|
+
*/
|
148
|
+
canvasPan: (canvas: Canvas, view: CanvasViewPosition) => void;
|
149
|
+
|
150
|
+
/**
|
151
|
+
* A hook event that fires when the Canvas is ready.
|
152
|
+
* @param canvas - The Canvas which is now ready for use
|
153
|
+
* @remarks This is called by {@link Hooks.call}.
|
154
|
+
* @see {@link Canvas#draw}
|
155
|
+
*/
|
156
|
+
canvasReady: (canvas: Canvas) => boolean | void;
|
157
|
+
|
158
|
+
/**
|
159
|
+
* A hook event that fires when the Canvas is deactivated.
|
160
|
+
* @param canvas - The Canvas instance being deactivated
|
161
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
162
|
+
*/
|
163
|
+
canvasTearDown: (canvas: Canvas) => void;
|
164
|
+
|
165
|
+
/**
|
166
|
+
* A hook event that fires when the Canvas is beginning to draw the canvas groups.
|
167
|
+
* @param canvas - The Canvas instance being drawn
|
168
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
169
|
+
*/
|
170
|
+
canvasDraw: (canvas: Canvas) => void;
|
171
|
+
|
172
|
+
/**
|
173
|
+
* A hook event that fires when some useful data is dropped onto the Canvas.
|
174
|
+
* @param canvas - The Canvas
|
175
|
+
* @param data - The data that has been dropped onto the Canvas
|
176
|
+
* @remarks This is called by {@link Hooks.call}.
|
177
|
+
* @remarks An explicit return value of `false` prevents the Document being created.
|
178
|
+
* @see {@link Canvas#_onDrop}
|
179
|
+
*/
|
180
|
+
dropCanvasData: (canvas: Canvas, data: TokenLayer.DropData | NotesLayer.DropData) => boolean | void;
|
181
|
+
|
182
|
+
/**
|
183
|
+
* A hook event that fires when objects are highlighted on the canvas.
|
184
|
+
* Callers may use this hook to apply their own modifications or enhancements to highlighted objects.
|
185
|
+
* @param active - Is the highlight state now active
|
186
|
+
* @see {@link Canvas#highlightObjects}
|
187
|
+
*/
|
188
|
+
highlightObjects: (active: boolean) => void;
|
189
|
+
|
190
|
+
/** Application */
|
191
|
+
|
192
|
+
/**
|
193
|
+
* A hook event that fires when the Scene controls are initialized.
|
194
|
+
* @param controls - The SceneControl configurations
|
195
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
196
|
+
* @see {@link SceneControls#_getControlButtons}
|
197
|
+
*/
|
198
|
+
getSceneControlButtons: (controls: SceneControl[]) => void;
|
199
|
+
|
200
|
+
/**
|
201
|
+
* A hook event that fires whenever data is dropped into a Hotbar slot.
|
202
|
+
* The hook provides a reference to the Hotbar application, the dropped data, and the target slot.
|
203
|
+
* Default handling of the drop event can be prevented by returning false within the hooked function.
|
204
|
+
* @param hotbar - The Hotbar application instance
|
205
|
+
* @param data - The dropped data object
|
206
|
+
* @param slot - The target hotbar slot
|
207
|
+
* @remarks This is called by {@link Hooks.call}.
|
208
|
+
* @remarks An explicit return value of `false` prevents the Document being created.
|
209
|
+
* @see {@link Hotbar#_onDrop}
|
210
|
+
*/
|
211
|
+
hotbarDrop: (hotbar: Hotbar, data: DropData<Macro.ConfiguredInstance>, slot: number) => boolean | void;
|
212
|
+
|
213
|
+
/**
|
214
|
+
* A hook event that fires when the SceneNavigation menu is expanded or collapsed.
|
215
|
+
* @param nav - The SceneNavigation application
|
216
|
+
* @param collapsed - Whether the navigation is now collapsed or not
|
217
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
218
|
+
* @see {@link SceneNavigation#expand}
|
219
|
+
* @see {@link SceneNavigation#collapse}
|
220
|
+
*/
|
221
|
+
collapseSceneNavigation: (nav: SceneNavigation, collapsed: boolean) => void;
|
222
|
+
|
223
|
+
/**
|
224
|
+
* A hook event that fires when the Sidebar is collapsed or expanded.
|
225
|
+
* @param sidebar - The Sidebar application
|
226
|
+
* @param collapsed - Whether the Sidebar is now collapsed or not
|
227
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
228
|
+
* @see {@link Sidebar#expand}
|
229
|
+
* @see {@link Sidebar#collapse}
|
230
|
+
*/
|
231
|
+
collapseSidebar: (sidebar: Sidebar, collapsed: boolean) => void;
|
232
|
+
|
233
|
+
/**
|
234
|
+
* A hook event that fires when the Sidebar tab is changed.
|
235
|
+
* @param app - The SidebarTab application which is now active
|
236
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
237
|
+
* @see {@link Sidebar#_onChangeTab}
|
238
|
+
*/
|
239
|
+
changeSidebarTab: (app: SidebarTab) => void;
|
240
|
+
|
241
|
+
/** EffectsCanvasGroup */
|
242
|
+
|
243
|
+
/**
|
244
|
+
* A hook event that fires in the {@link EffectsCanvasGroup} #createLayers private method.
|
245
|
+
* @param group - The EffectsCanvasGroup instance
|
246
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
247
|
+
*/
|
248
|
+
createEffectsCanvasGroup: (group: EffectsCanvasGroup) => void;
|
249
|
+
|
250
|
+
/**
|
251
|
+
* A hook event that fires in the {@link EffectsCanvasGroup} draw method.
|
252
|
+
* @param group - The EffectsCanvasGroup instance
|
253
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
254
|
+
*/
|
255
|
+
drawEffectsCanvasGroup: (group: EffectsCanvasGroup) => void;
|
256
|
+
|
257
|
+
/**
|
258
|
+
* A hook event that fires in the {@link EffectsCanvasGroup} tearDown method.
|
259
|
+
* @param group - The EffectsCanvasGroup instance
|
260
|
+
*/
|
261
|
+
tearDownEffectsCanvasGroup: (group: EffectsCanvasGroup) => void;
|
262
|
+
|
263
|
+
/** Active Effects */
|
264
|
+
|
265
|
+
/**
|
266
|
+
* A hook event that fires when a custom active effect is applied.
|
267
|
+
* @param actor - The actor the active effect is being applied to
|
268
|
+
* @param change - The change data being applied
|
269
|
+
* @remarks This is called by {@link Hooks.call}.
|
270
|
+
* @see {@link ActiveEffect#_applyCustom}
|
271
|
+
*/
|
272
|
+
applyActiveEffect: (actor: Actor.ConfiguredInstance, change: EffectChangeData) => boolean | void;
|
273
|
+
|
274
|
+
/** Compendium */
|
275
|
+
|
276
|
+
/**
|
277
|
+
* A hook event that fires whenever the contents of a Compendium pack were modified.
|
278
|
+
* This hook fires for all connected clients after the update has been processed.
|
279
|
+
*
|
280
|
+
* @param pack - The Compendium pack being modified
|
281
|
+
* @param documents - The locally-cached Documents which were modified in the operation
|
282
|
+
* @param options - Additional options which modified the modification request
|
283
|
+
* @param userId - The ID of the User who triggered the modification workflow
|
284
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
285
|
+
* @see {@link CompendiumCollection#_onModifyContents}
|
286
|
+
*/
|
287
|
+
updateCompendium: (
|
288
|
+
pack: CompendiumCollection.Any,
|
289
|
+
documents: Document.Any[],
|
290
|
+
options: Document.OnUpdateOptions<Document.Any["documentName"]>,
|
291
|
+
userId: string,
|
292
|
+
) => void;
|
293
|
+
|
294
|
+
/** Token */
|
295
|
+
|
296
|
+
/**
|
297
|
+
* A hook event that fires when a token {@link Token} should apply a specific status effect.
|
298
|
+
* @param token - The token affected
|
299
|
+
* @param statusId - The status effect ID being applied, from CONFIG.specialStatusEffects.
|
300
|
+
* @param active - Is the special status effect now active?
|
301
|
+
*/
|
302
|
+
applyTokenStatusEffect: (token: Token.ConfiguredInstance, statusId: string, active: boolean) => void;
|
303
|
+
|
304
|
+
/**
|
305
|
+
* A hook event that fires when a chat bubble is rendered.
|
306
|
+
* @param token - The speaking token
|
307
|
+
* @param html - The HTML for the chat bubble
|
308
|
+
* @param message - The spoken message text
|
309
|
+
* @param options - additional options
|
310
|
+
* @remarks This is called when creating a {@link ChatBubble}, but before displaying it.
|
311
|
+
* @remarks This is called by {@link Hooks.call}.
|
312
|
+
* @remarks An explicit return value of `false` prevents the chat bubble being shown.
|
313
|
+
* @see {@link ChatBubbles#say}
|
314
|
+
*/
|
315
|
+
chatBubble: (
|
316
|
+
token: Token,
|
317
|
+
html: JQuery,
|
318
|
+
message: string,
|
319
|
+
options: {
|
320
|
+
/** Whether to style the speech bubble as an emote */
|
321
|
+
emote: boolean;
|
322
|
+
},
|
323
|
+
) => boolean | void;
|
324
|
+
|
325
|
+
/**
|
326
|
+
* A hook event that fires when a token's resource bar attribute has been modified.
|
327
|
+
* @param data - A object describing the modification
|
328
|
+
* @param updates - The update delta that will be applied to the Token's actor
|
329
|
+
* @returns whether the Actor should be updated
|
330
|
+
* @remarks This is called by {@link Hooks.call}.
|
331
|
+
* @see {@link Actor#modifyTokenAttribute}
|
332
|
+
* @see {@link Actor#update}
|
333
|
+
*/
|
334
|
+
modifyTokenAttribute: (
|
335
|
+
data: {
|
336
|
+
/** The attribute path */
|
337
|
+
attribute: string;
|
338
|
+
|
339
|
+
/** The target attribute value */
|
340
|
+
value: number;
|
341
|
+
|
342
|
+
/** Whether the number represents a relative change (true) or an absolute change (false) */
|
343
|
+
isDelta: boolean;
|
344
|
+
|
345
|
+
/** Whether the new value is part of an attribute bar, or just a direct value */
|
346
|
+
isBar: boolean;
|
347
|
+
},
|
348
|
+
updates: Record<string, number>,
|
349
|
+
) => boolean;
|
350
|
+
|
351
|
+
/**
|
352
|
+
* A hook event that fires when a token is targeted or un-targeted.
|
353
|
+
* @param user - The User doing the targeting
|
354
|
+
* @param token - The targeted Token
|
355
|
+
* @param targeted - Whether the Token has been targeted or untargeted
|
356
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
357
|
+
* @see {@link UserTargets#_hook}
|
358
|
+
*/
|
359
|
+
targetToken: (
|
360
|
+
user: User.ConfiguredInstance,
|
361
|
+
token: Document.ConfiguredObjectClassForName<"Token">,
|
362
|
+
targeted: boolean,
|
363
|
+
) => void;
|
364
|
+
|
365
|
+
/** Note */
|
366
|
+
|
367
|
+
/**
|
368
|
+
* A hook event that fires whenever a map note is double-clicked.
|
369
|
+
* The hook provides the note placeable and the arguments passed to the associated {@link JournalSheet} render call.
|
370
|
+
* Hooked functions may modify the render arguments or cancel the render by returning false.
|
371
|
+
* @param note - The note that was activated
|
372
|
+
* @param options - Options for rendering the associated {@link JournalSheet}
|
373
|
+
* @remarks This is called by {@link Hooks.call}.
|
374
|
+
*/
|
375
|
+
activateNote: (note: Note.ConfiguredInstance, options: JournalSheet.RenderOptions) => boolean | false;
|
376
|
+
|
377
|
+
/** Cards */
|
378
|
+
|
379
|
+
/**
|
380
|
+
* A hook event that fires when Cards are dealt from a deck to other hands
|
381
|
+
* @param origin - The origin Cards document
|
382
|
+
* @param destinations - An array of destination Cards documents
|
383
|
+
* @param context - Additional context which describes the operation
|
384
|
+
* @remarks This is called by {@link Hooks.call}.
|
385
|
+
* @remarks An explicit return value of `false` prevents the operation.
|
386
|
+
*/
|
387
|
+
dealCards: (
|
388
|
+
origin: Cards.ConfiguredInstance,
|
389
|
+
destinations: Cards.ConfiguredInstance[],
|
390
|
+
context: Cards.DealContext,
|
391
|
+
) => boolean | void;
|
392
|
+
|
393
|
+
/**
|
394
|
+
* A hook event that fires when Cards are passed from one stack to another
|
395
|
+
* @param origin - The origin Cards document
|
396
|
+
* @param destination - The destination Cards document
|
397
|
+
* @param context - Additional context which describes the operation
|
398
|
+
* @remarks This is called by {@link Hooks.call}.
|
399
|
+
* @remarks An explicit return value of `false` prevents the operation.
|
400
|
+
*/
|
401
|
+
passCards: (
|
402
|
+
origin: Cards.ConfiguredInstance,
|
403
|
+
destination: Cards.ConfiguredInstance,
|
404
|
+
context: Cards.DealContext,
|
405
|
+
) => boolean | void;
|
406
|
+
|
407
|
+
/**
|
408
|
+
* A hook event that fires when a stack of Cards are returned to the decks they originally came from.
|
409
|
+
* @param origin - The origin Cards document.
|
410
|
+
* @param returned - The cards being returned.
|
411
|
+
* @param context - Additional context which describes the operation.
|
412
|
+
*/
|
413
|
+
returnCards: (
|
414
|
+
origin: Cards.ConfiguredInstance,
|
415
|
+
returned: Card.ConfiguredInstance[],
|
416
|
+
context: Cards.ReturnContext,
|
417
|
+
) => boolean | void;
|
418
|
+
|
419
|
+
/** ActorSheet */
|
420
|
+
|
421
|
+
/**
|
422
|
+
* A hook event that fires when some useful data is dropped onto an ActorSheet.
|
423
|
+
* @param actor - The Actor
|
424
|
+
* @param sheet - The ActorSheet application
|
425
|
+
* @param data - The data that has been dropped onto the sheet
|
426
|
+
* @remarks This is called by {@link Hooks.call}.
|
427
|
+
* @remarks An explicit return value of `false` prevents the Document being created.
|
428
|
+
* @see {@link ActorSheet#_onDrop}
|
429
|
+
*/
|
430
|
+
dropActorSheetData: (
|
431
|
+
actor: Actor.ConfiguredInstance,
|
432
|
+
sheet: ActorSheet,
|
433
|
+
data: ActorSheet.DropData,
|
434
|
+
) => boolean | void;
|
435
|
+
|
436
|
+
/** CanvasVisibility */
|
437
|
+
|
438
|
+
/**
|
439
|
+
* A hook event that fires when the set of vision sources are initialized.
|
440
|
+
* @param sources - The collection of current vision sources
|
441
|
+
* @remarks This is called by {@link Hooks.call}.
|
442
|
+
*/
|
443
|
+
initializeVisionSources: (sources: Collection<VisionSource>) => void;
|
444
|
+
|
445
|
+
/**
|
446
|
+
* A hook event that fires when the LightingLayer is refreshed.
|
447
|
+
* @param layer - the LightingLayer
|
448
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
449
|
+
* @see {@link LightingLayer#refresh}
|
450
|
+
*/
|
451
|
+
lightingRefresh: (layer: LightingLayer) => void;
|
452
|
+
|
453
|
+
/**
|
454
|
+
* A hook event that fires during light source initialization.
|
455
|
+
* This hook can be used to add programmatic light sources to the Scene.
|
456
|
+
* @param source - The EffectsCanvasGroup where light sources are initialized
|
457
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
458
|
+
* @see {@link EffectsCanvasGroup#initializeLightSources}
|
459
|
+
*/
|
460
|
+
initializeLightSources: (group: EffectsCanvasGroup) => void;
|
461
|
+
|
462
|
+
/**
|
463
|
+
* A hook event that fires when the CanvasVisibility layer has been refreshed.
|
464
|
+
* @param visibility - The CanvasVisibility layer
|
465
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
466
|
+
* @see {@link CanvasVisibility#restrictVisibility}
|
467
|
+
*/
|
468
|
+
sightRefresh: (visibility: CanvasVisibility) => void;
|
469
|
+
|
470
|
+
/** Weather */
|
471
|
+
|
472
|
+
/**
|
473
|
+
* Initialize the weather container from a weather config object.
|
474
|
+
* @param weatherEffect - The weather effects canvas layer
|
475
|
+
* @param weatherEffectsConfig - The weather effects config object
|
476
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
477
|
+
*/
|
478
|
+
initializeWeatherEffects: (
|
479
|
+
weatherEffect: WeatherEffects,
|
480
|
+
weatherEffectsConfig?: WeatherLayer.WeatherEffectsConfig | null,
|
481
|
+
) => void;
|
482
|
+
|
483
|
+
/** Adventure */
|
484
|
+
|
485
|
+
/**
|
486
|
+
* A hook event that fires when Adventure data is being prepared for import.
|
487
|
+
* Modules may return false from this hook to take over handling of the import workflow.
|
488
|
+
* @param adventure - The Adventure document from which content is being imported
|
489
|
+
* @param formData - Processed data from the importer form
|
490
|
+
* @param toCreate - Adventure data which needs to be created in the World
|
491
|
+
* @param toUpdate - Adventure data which needs to be updated in the World
|
492
|
+
* @returns False to prevent the core software from handling the import
|
493
|
+
* @remarks This is called by {@link Hooks.call}.
|
494
|
+
*/
|
495
|
+
preImportAdventure: (
|
496
|
+
adventure: Adventure.ConfiguredInstance,
|
497
|
+
formData: object, // TODO: Improve this. Also relevant to `AdventureImporter#_updateObject`
|
498
|
+
toCreate: AdventureImportData["toCreate"],
|
499
|
+
toUpdate: AdventureImportData["toUpdate"],
|
500
|
+
) => boolean | void;
|
501
|
+
|
502
|
+
/**
|
503
|
+
* A hook event that fires after an Adventure has been imported into the World.
|
504
|
+
* @param adventure - The Adventure document from which content is being imported
|
505
|
+
* @param formData - Processed data from the importer form
|
506
|
+
* @param toCreate - Adventure data which needs to be created in the World
|
507
|
+
* @param toUpdate - Adventure data which needs to be updated in the World
|
508
|
+
* @returns False to prevent the core software from handling the import
|
509
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
510
|
+
*/
|
511
|
+
importAdventure: (
|
512
|
+
adventure: Adventure.ConfiguredInstance,
|
513
|
+
formData: object, // TODO: Improve this. Also relevant to `AdventureImporter#_updateObject`
|
514
|
+
toCreate: AdventureImportData["toCreate"],
|
515
|
+
toUpdate: AdventureImportData["toUpdate"],
|
516
|
+
) => void;
|
517
|
+
|
518
|
+
/** Socket */
|
519
|
+
|
520
|
+
/**
|
521
|
+
* A hook event that fires whenever some other User joins or leaves the game session.
|
522
|
+
* @param user - The User who connected or disconnected
|
523
|
+
* @param connected - Is the user now connected (true) or disconnected (false)
|
524
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
525
|
+
*/
|
526
|
+
userConnected: (user: User.ConfiguredInstance, connected: boolean) => void;
|
527
|
+
|
528
|
+
/** Combat */
|
529
|
+
|
530
|
+
/**
|
531
|
+
* A hook event that fires when a Combat encounter is started.
|
532
|
+
* @param combat - The Combat encounter which is starting
|
533
|
+
* @param updateData - An object which contains Combat properties that will be updated. Can be mutated.
|
534
|
+
*/
|
535
|
+
combatStart: (
|
536
|
+
combat: Combat.ConfiguredInstance,
|
537
|
+
updateData: {
|
538
|
+
/** The initial round */
|
539
|
+
round: number;
|
540
|
+
/** The initial turn */
|
541
|
+
turn: number;
|
542
|
+
},
|
543
|
+
) => void;
|
544
|
+
|
545
|
+
/**
|
546
|
+
* A hook event that fires when the turn of the Combat encounter changes.
|
547
|
+
* @param combat - The Combat encounter which is advancing or rewinding its turn
|
548
|
+
* @param updateData - An object which contains Combat properties that will be updated. Can be mutated.
|
549
|
+
* @param updateOptions - An object which contains options provided to the update method. Can be mutated.
|
550
|
+
*/
|
551
|
+
combatTurn: (
|
552
|
+
combat: Combat.ConfiguredInstance,
|
553
|
+
updateData: {
|
554
|
+
/** The current round of combat */
|
555
|
+
round: number;
|
556
|
+
/** The new turn number */
|
557
|
+
turn: number;
|
558
|
+
},
|
559
|
+
updateOptions: {
|
560
|
+
/** The amount of time in seconds that time is being advanced */
|
561
|
+
advanceTime: number;
|
562
|
+
/** A signed integer for whether the turn order is advancing or rewinding */
|
563
|
+
direction: number;
|
564
|
+
},
|
565
|
+
) => void;
|
566
|
+
|
567
|
+
/**
|
568
|
+
* A hook event that fires when the round of the Combat encounter changes.
|
569
|
+
* @param combat - The Combat encounter which is advancing or rewinding its round
|
570
|
+
* @param updateData - An object which contains Combat properties that will be updated. Can be mutated.
|
571
|
+
* @param updateOptions - An object which contains options provided to the update method. Can be mutated.
|
572
|
+
*/
|
573
|
+
combatRound: (
|
574
|
+
combat: Combat.ConfiguredInstance,
|
575
|
+
updateData: {
|
576
|
+
/** The new round of combat */
|
577
|
+
round: number;
|
578
|
+
/** The new turn number */
|
579
|
+
turn: number;
|
580
|
+
},
|
581
|
+
updateOptions: {
|
582
|
+
/** The amount of time in seconds that time is being advanced */
|
583
|
+
advanceTime: number;
|
584
|
+
/** A signed integer for whether the turn order is advancing or rewinding */
|
585
|
+
direction: number;
|
586
|
+
},
|
587
|
+
) => void;
|
588
|
+
|
589
|
+
/** ProseMirror */
|
590
|
+
|
591
|
+
/**
|
592
|
+
* A hook even that fires when a ProseMirrorMenu's drop-downs are initialized.
|
593
|
+
* The hook provides the ProseMirrorMenu instance and an object of drop-down configuration data.
|
594
|
+
* Hooked functions may append their own drop-downs or append entries to existing drop-downs.
|
595
|
+
* @param menu - The ProseMirrorMenu instance.
|
596
|
+
* @param config - The drop-down config.
|
597
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
598
|
+
*/
|
599
|
+
getProseMirrorMenuDropdowns: (
|
600
|
+
menu: ProseMirrorMenu,
|
601
|
+
config: {
|
602
|
+
format: ProseMirrorDropDown.Config;
|
603
|
+
fonts: ProseMirrorDropDown.Config;
|
604
|
+
},
|
605
|
+
) => void;
|
606
|
+
|
607
|
+
/**
|
608
|
+
* A hook even that fires when a ProseMirrorMenu's buttons are initialized.
|
609
|
+
* The hook provides the ProseMirrorMenu instance and an array of button configuration data.
|
610
|
+
* Hooked functions may append their own buttons to the list.
|
611
|
+
* @param menu - The ProseMirrorMenu instance
|
612
|
+
* @param config - The button configuration objects
|
613
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
614
|
+
*/
|
615
|
+
// TODO: Having trouble finding the appropriate typing for the menu items? Also, where is this even called?
|
616
|
+
getProseMirrorMenuItems: (menu: ProseMirrorMenu, config: unknown[]) => void;
|
617
|
+
|
618
|
+
/**
|
619
|
+
* A hook event that fires whenever a ProseMirror editor is created.
|
620
|
+
* The hook provides the ProseMirror instance UUID, a list of plugins, and an object containing the provisional
|
621
|
+
* editor state, and a reference to the menu plugin.
|
622
|
+
* Hooked functions may append their own plugins or replace the state or menu plugin by replacing their references
|
623
|
+
* in the final argument.
|
624
|
+
*
|
625
|
+
* @param uuid - A UUID that uniquely identifies this ProseMirror instance.
|
626
|
+
* @param plugins - A list of plugins that will be loaded.
|
627
|
+
* @param options - The provisional EditorState and ProseMirrorMenuPlugin.
|
628
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
629
|
+
* @see {@link ProseMirrorEditor.create}
|
630
|
+
*/
|
631
|
+
createProseMirrorEditor: (uuid: string, plugins: Record<string, Plugin>, options: { state: EditorState }) => void;
|
632
|
+
|
633
|
+
/** HotReload */
|
634
|
+
|
635
|
+
/**
|
636
|
+
* A hook event that fires when a package that is being watched by the hot reload system has a file changed.
|
637
|
+
* The hook provides the hot reload data related to the file change.
|
638
|
+
* Hooked functions may intercept the hot reload and prevent the core software from handling it by returning false.
|
639
|
+
* @param data - The hot reload data
|
640
|
+
* @remarks This is called by {@link Hooks.call}.
|
641
|
+
*/
|
642
|
+
hotReload: (data: HotReloadData) => boolean | void;
|
643
|
+
|
644
|
+
/** Chat */
|
645
|
+
|
646
|
+
/**
|
647
|
+
* A hook event that fires when a user sends a message through the ChatLog.
|
648
|
+
* @param chatLog - The ChatLog instance
|
649
|
+
* @param message - The trimmed message content
|
650
|
+
* @param chatData - The basic chat data
|
651
|
+
* @remarks This is called by {@link Hooks.call}.
|
652
|
+
* @remarks An explicit return value of `false` prevents the chat message from being created.
|
653
|
+
* @see {@link ChatLog#processMessage}
|
654
|
+
*/
|
655
|
+
chatMessage: (
|
656
|
+
chatLog: ChatLog,
|
657
|
+
message: string,
|
658
|
+
chatData: {
|
659
|
+
/** The User sending the message */
|
660
|
+
user: string;
|
661
|
+
|
662
|
+
/** The identified speaker data, see {@link ChatMessage.getSpeaker} */
|
663
|
+
speaker: ReturnType<Document.ToConfiguredClass<typeof ChatMessage>["getSpeaker"]>;
|
664
|
+
},
|
665
|
+
) => boolean | void;
|
666
|
+
|
667
|
+
/**
|
668
|
+
* A hook event that fires for each ChatMessage which is rendered for addition to the ChatLog.
|
669
|
+
* This hook allows for final customization of the message HTML before it is added to the log.
|
670
|
+
* @param message - The ChatMessage document being rendered
|
671
|
+
* @param html - The pending HTML as a jQuery object
|
672
|
+
* @param messageData - The input data provided for template rendering
|
673
|
+
* @remarks This is called by {@link Hooks.call}.
|
674
|
+
* @see {@link ChatMessage#render}
|
675
|
+
*/
|
676
|
+
renderChatMessage: (
|
677
|
+
message: ChatMessage,
|
678
|
+
html: JQuery,
|
679
|
+
messageData: {
|
680
|
+
message: Document.ToObjectFalseType<ChatMessage.ConfiguredInstance>;
|
681
|
+
user: Game["user"];
|
682
|
+
author: ChatMessage.ConfiguredInstance["user"];
|
683
|
+
alias: ChatMessage.ConfiguredInstance["alias"];
|
684
|
+
cssClass: string;
|
685
|
+
isWhisper: boolean;
|
686
|
+
canDelete: boolean;
|
687
|
+
whisperTo: string;
|
688
|
+
borderColor?: string;
|
689
|
+
},
|
690
|
+
) => boolean | void;
|
691
|
+
|
692
|
+
/** Audio-Video */
|
693
|
+
|
694
|
+
// Individually implemented all three options for globalVolumeChanged
|
695
|
+
|
696
|
+
/**
|
697
|
+
* A hook event that fires when the user modifies a global volume slider.
|
698
|
+
* @param volume - The new volume level
|
699
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
700
|
+
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
701
|
+
*/
|
702
|
+
globalAmbientVolumeChanged: (volume: number) => void;
|
703
|
+
/**
|
704
|
+
* A hook event that fires when the user modifies a global volume slider.
|
705
|
+
* @param volume - The new volume level
|
706
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
707
|
+
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
708
|
+
*/
|
709
|
+
globalInterfaceVolumeChanged: (volume: number) => void;
|
710
|
+
/**
|
711
|
+
* A hook event that fires when the user modifies a global volume slider.
|
712
|
+
* @param volume - The new volume level
|
713
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
714
|
+
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
715
|
+
*/
|
716
|
+
globalPlaylistVolumeChanged: (volume: number) => void;
|
717
|
+
|
718
|
+
/**
|
719
|
+
* A hook event that fires when the AV settings are changed.
|
720
|
+
* @param settings - The AVSettings manager
|
721
|
+
* @param changed - The delta of the settings that have been changed
|
722
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
723
|
+
* @see {@link AVSettings#_onSettingsChanged}
|
724
|
+
*/
|
725
|
+
rtcSettingsChanged: (settings: AVSettings, changed: DeepPartial<AVSettings.Settings>) => void;
|
726
|
+
|
727
|
+
/** RollTableConfig */
|
728
|
+
|
729
|
+
/**
|
730
|
+
* A hook event that fires when some useful data is dropped onto a RollTableConfig.
|
731
|
+
* @param table - The RollTable
|
732
|
+
* @param config - The RollTableConfig application
|
733
|
+
* @param data - The data dropped onto the RollTableConfig
|
734
|
+
* @remarks This is called by {@link Hooks.call}.
|
735
|
+
* @remarks An explicit return value of `false` prevents the Document being created.
|
736
|
+
* @see {@link RollTableConfig#_onDrop}
|
737
|
+
*/
|
738
|
+
dropRollTableSheetData: (
|
739
|
+
table: RollTable.ConfiguredInstance,
|
740
|
+
config: RollTableConfig,
|
741
|
+
data: object,
|
742
|
+
) => boolean | void;
|
743
|
+
|
744
|
+
/** PrimaryCanvasObject */
|
745
|
+
|
746
|
+
/**
|
747
|
+
* A hook event that fires when the occlusion of an OccludableObject refreshed.
|
748
|
+
* @param object - The boject whose occlusion is refreshed
|
749
|
+
*/
|
750
|
+
refreshOcclusion: (object: OccludableObject) => void;
|
751
|
+
|
752
|
+
/** Specific implementations of GetEntryContext */
|
753
|
+
|
754
|
+
/**
|
755
|
+
* A hook event that fires when the context menu for a SceneNavigation entry is constructed.
|
756
|
+
* @param html - The HTML element to which the context options are attached
|
757
|
+
* @param entryOptions - The context menu entries
|
758
|
+
* @remarks This is called by {@link Hooks.call}.
|
759
|
+
* @see {@link SceneNavigation#activateListeners}
|
760
|
+
*/
|
761
|
+
getSceneNavigationContext: (html: JQuery, entryOptions: ContextMenuEntry[]) => boolean | void;
|
762
|
+
|
763
|
+
/**
|
764
|
+
* A hook event that fires when the context menu for a PlayersList entry is constructed.
|
765
|
+
* @param html - The HTML element to which the context options are attached
|
766
|
+
* @param entryOptions - The context menu entries
|
767
|
+
* @remarks This is called by {@link Hooks.call}.
|
768
|
+
* @see {@link PlayerList#activateListeners}
|
769
|
+
*/
|
770
|
+
getUserContextOptions: (html: JQuery, entryOptions: ContextMenuEntry[]) => boolean | void;
|
771
|
+
}
|
772
|
+
|
773
|
+
/** Application */
|
774
|
+
|
775
|
+
/**
|
776
|
+
* A hook event that fires whenever this Application is rendered.
|
777
|
+
* The hook provides the pending application HTML which will be added to the DOM.
|
778
|
+
* Hooked functions may modify that HTML or attach interactive listeners to it.
|
779
|
+
*
|
780
|
+
* @param app - The Application instance being rendered
|
781
|
+
* @param html - The inner HTML of the document that will be displayed and may be modified
|
782
|
+
* @param data - The object of data used when rendering the application
|
783
|
+
* @typeParam A - the type of the Application
|
784
|
+
* @remarks The name for this hook is dynamically created by joining "render" with the type name of the Application.
|
785
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
786
|
+
* @see {@link Application#_render}
|
787
|
+
*/
|
788
|
+
type RenderApplication<A extends Application = Application> = (
|
789
|
+
app: A,
|
790
|
+
html: JQuery,
|
791
|
+
data: ReturnType<A["getData"]> extends Promise<infer T> ? T : ReturnType<A["getData"]>,
|
792
|
+
) => boolean | void;
|
793
|
+
|
794
|
+
/**
|
795
|
+
* A hook event that fires whenever this Application is first rendered to add buttons to its header.
|
796
|
+
* @param app - The Application instance being rendered
|
797
|
+
* @param buttons - The array of header buttons which will be displayed
|
798
|
+
* @typeParam A - the type of the Application
|
799
|
+
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the Application and
|
800
|
+
* "HeaderButtons".
|
801
|
+
* @remarks This is called by {@link Hooks.call}.
|
802
|
+
* @see {@link Application#_getHeaderButtons}
|
803
|
+
*/
|
804
|
+
type GetApplicationHeaderButtons<A extends Application = Application> = (
|
805
|
+
app: A,
|
806
|
+
buttons: Application.HeaderButton[],
|
807
|
+
) => boolean | void;
|
808
|
+
|
809
|
+
/**
|
810
|
+
* A hook event that fires whenever this Application is closed.
|
811
|
+
* @param app - The Application instance being closed
|
812
|
+
* @param html - The application HTML when it is closed
|
813
|
+
* @typeParam A - the type of the Application
|
814
|
+
* @remarks The name for this hook is dynamically created by joining "close" with the type name of the Application.
|
815
|
+
* @remarks This is called by {@link Hooks.call}.
|
816
|
+
* @see {@link Application#close}
|
817
|
+
*/
|
818
|
+
type CloseApplication<A extends Application = Application> = (app: A, html: JQuery) => boolean | void;
|
819
|
+
|
820
|
+
/** CanvasLayer */
|
821
|
+
|
822
|
+
/**
|
823
|
+
* A hook event that fires with a {@link CanvasLayer} is initially drawn.
|
824
|
+
* The dispatched event name replaces "Layer" with the named CanvasLayer subclass, i.e. "drawTokensLayer".
|
825
|
+
* @param layer - The layer being drawn
|
826
|
+
* @typeParam L - the type of the CanvasLayer
|
827
|
+
*/
|
828
|
+
type DrawLayer<L extends CanvasLayer = CanvasLayer> = (layer: L) => void;
|
829
|
+
|
830
|
+
/**
|
831
|
+
* A hook event that fires with a {@link CanvasLayer} is deconstructed.
|
832
|
+
* The dispatched event name replaces "Layer" with the named CanvasLayer subclass, i.e. "tearDownTokensLayer".
|
833
|
+
* @param layer - The layer being deconstructed
|
834
|
+
* @typeParam L - the type of the CanvasLayer
|
835
|
+
*/
|
836
|
+
type TearDownLayer<L extends CanvasLayer = CanvasLayer> = (layer: L) => void;
|
837
|
+
|
838
|
+
/**
|
839
|
+
* A hook event that fires when any PlaceableObject is pasted onto the
|
840
|
+
* Scene. Substitute the PlaceableObject name in the hook event to target a
|
841
|
+
* specific PlaceableObject type, for example "pasteToken".
|
842
|
+
* @param copied - The PlaceableObjects that were copied
|
843
|
+
* @param createData - The new objects that will be added to the Scene
|
844
|
+
* @typeParam P - the type of the PlaceableObject
|
845
|
+
* @remarks The name for this hook is dynamically created by joining "paste" with the type name of the
|
846
|
+
* PlaceableObject.
|
847
|
+
* @remarks This is called by {@link Hooks.call}.
|
848
|
+
* @see {@link PlaceablesLayer#pasteObjects}
|
849
|
+
*/
|
850
|
+
type PastePlaceableObject<P extends PlaceableObject = PlaceableObject> = (
|
851
|
+
copied: P[],
|
852
|
+
createData: Array<P["document"]["_source"]>,
|
853
|
+
) => boolean | void;
|
854
|
+
/** */
|
855
|
+
|
856
|
+
/** PlaceableObject */
|
857
|
+
|
858
|
+
/**
|
859
|
+
* A hook event that fires when a {@link PlaceableObject} is initially drawn.
|
860
|
+
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "drawToken".
|
861
|
+
* @param object - The object instance being drawn
|
862
|
+
* @typeParam P - the type of the PlaceableObject
|
863
|
+
* @remarks This is called by {@link Hooks.callAll}
|
864
|
+
*/
|
865
|
+
type DrawObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
866
|
+
|
867
|
+
/**
|
868
|
+
* A hook event that fires when a {@link PlaceableObject} is incrementally refreshed.
|
869
|
+
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "refreshToken".
|
870
|
+
* @param object - The object instance being refreshed
|
871
|
+
* @typeParam P - the type of the PlaceableObject
|
872
|
+
* @remarks This is called by {@link Hooks.callAll}
|
873
|
+
*/
|
874
|
+
type RefreshObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
875
|
+
|
876
|
+
/**
|
877
|
+
* A hook event that fires when a {@link PlaceableObject} is destroyed.
|
878
|
+
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "destroyToken".
|
879
|
+
* @param object - The object instance being destroyed
|
880
|
+
* @typeParam P - the type of the PlaceableObject
|
881
|
+
* @remarks This is called by {@link Hooks.callAll}
|
882
|
+
*/
|
883
|
+
type DestroyObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
884
|
+
|
885
|
+
/**
|
886
|
+
* A hook event that fires when any PlaceableObject is selected or
|
887
|
+
* deselected. Substitute the PlaceableObject name in the hook event to
|
888
|
+
* target a specific PlaceableObject type, for example "controlToken".
|
889
|
+
* @param object - The PlaceableObject
|
890
|
+
* @param controlled - Whether the PlaceableObject is selected or not
|
891
|
+
* @typeParam P - the type of the PlaceableObject
|
892
|
+
* @remarks The name for this hook is dynamically created by joining "control" and the type name of the
|
893
|
+
* PlaceableObject.
|
894
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
895
|
+
* @see {@link PlaceableObject#control}
|
896
|
+
* @see {@link PlaceableObject#release}
|
897
|
+
*/
|
898
|
+
type ControlObject<P extends PlaceableObject = PlaceableObject> = (object: P, controlled: boolean) => void;
|
899
|
+
|
900
|
+
/**
|
901
|
+
* A hook event that fires when any PlaceableObject is hovered over or out.
|
902
|
+
* Substitute the PlaceableObject name in the hook event to target a specific
|
903
|
+
* PlaceableObject type, for example "hoverToken".
|
904
|
+
* @param object - The PlaceableObject
|
905
|
+
* @param hover - Whether the PlaceableObject is hovered over or not
|
906
|
+
* @typeParam P - the type of the PlaceableObject
|
907
|
+
* @remarks The name for this hook is dynamically created by joining "hover" and the type name of the PlaceableObject.
|
908
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
909
|
+
* @see {@link PlaceableObject#_onHoverIn}
|
910
|
+
* @see {@link PlaceableObject#_onHoverOut}
|
911
|
+
*/
|
912
|
+
type HoverObject<P extends PlaceableObject = PlaceableObject> = (object: P, hover: boolean) => void;
|
913
|
+
|
914
|
+
/** Document */
|
915
|
+
|
916
|
+
/**
|
917
|
+
* A hook event that fires for every Document type before execution of a creation workflow. Substitute the
|
918
|
+
* Document name in the hook event to target a specific Document type, for example "preCreateActor". This hook
|
919
|
+
* only fires for the client who is initiating the creation request.
|
920
|
+
*
|
921
|
+
* The hook provides the pending document instance which will be used for the Document creation. Hooked functions
|
922
|
+
* may modify that data or prevent the workflow entirely by explicitly returning false.
|
923
|
+
*
|
924
|
+
* @param document - The pending document which is requested for creation
|
925
|
+
* @param data - The initial data object provided to the document creation request
|
926
|
+
* @param options - Additional options which modify the creation request
|
927
|
+
* @param userId - The ID of the requesting user, always game.user.id
|
928
|
+
* @typeParam D - the type of the Document constructor
|
929
|
+
* @returns Explicitly return false to prevent creation of this Document
|
930
|
+
* @remarks The name for this hook is dynamically created by joining "preCreate" with the name of the Document.
|
931
|
+
* @remarks This is called by {@link Hooks.call}.
|
932
|
+
* @see {@link ClientDatabaseBackend#_preCreateDocumentArray}
|
933
|
+
* @see {@link TokenDocument#_preUpdateTokenActor}
|
934
|
+
*/
|
935
|
+
type PreCreateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
936
|
+
document: Document.ToConfiguredInstance<D>,
|
937
|
+
data: ConstructorParameters<D>[0],
|
938
|
+
options: Document.PreCreateOptions<InstanceType<D>["documentName"]>,
|
939
|
+
userId: string,
|
940
|
+
) => boolean | void;
|
941
|
+
|
942
|
+
/**
|
943
|
+
* A hook event that fires for every Document type before execution of an update workflow. Substitute the Document
|
944
|
+
* name in the hook event to target a specific Document type, for example "preUpdateActor". This hook only fires
|
945
|
+
* for the client who is initiating the update request.
|
946
|
+
*
|
947
|
+
* The hook provides the differential data which will be used to update the Document. Hooked functions may modify
|
948
|
+
* that data or prevent the workflow entirely by explicitly returning false.
|
949
|
+
*
|
950
|
+
* @param document - The Document instance being updated
|
951
|
+
* @param change - Differential data that will be used to update the document
|
952
|
+
* @param options - Additional options which modify the update request
|
953
|
+
* @param userId - The ID of the requesting user, always game.user.id
|
954
|
+
* @typeParam D - the type of the Document constructor
|
955
|
+
* @returns Explicitly return false to prevent update of this Document
|
956
|
+
* @remarks The name for this hook is dynamically created by joining "preUpdate" with the type name of the Document.
|
957
|
+
* @remarks This is called {@link Hooks.call}.
|
958
|
+
* @see {@link ClientDatabaseBackend#_preUpdateDocumentArray}
|
959
|
+
* @see {@link TokenDocument#_preUpdateTokenActor}
|
960
|
+
*/
|
961
|
+
type PreUpdateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
962
|
+
document: Document.ToConfiguredInstance<D>,
|
963
|
+
change: DeepPartial<ConstructorParameters<D>[0]>,
|
964
|
+
options: Document.PreUpdateOptions<InstanceType<D>["documentName"]>,
|
965
|
+
userId: string,
|
966
|
+
) => boolean | void;
|
967
|
+
|
968
|
+
/**
|
969
|
+
* A hook event that fires for every Document type before execution of a deletion workflow. Substitute the
|
970
|
+
* Document name in the hook event to target a specific Document type, for example "preDeleteActor". This hook
|
971
|
+
* only fires for the client who is initiating the update request.
|
972
|
+
*
|
973
|
+
* The hook provides the Document instance which is requested for deletion. Hooked functions may prevent the
|
974
|
+
* workflow entirely by explicitly returning false.
|
975
|
+
*
|
976
|
+
* @param document - The Document instance being deleted
|
977
|
+
* @param options - Additional options which modify the deletion request
|
978
|
+
* @param userId - The ID of the requesting user, always game.user.id
|
979
|
+
* @typeParam D - the type of the Document constructor
|
980
|
+
* @returns Explicitly return false to prevent deletion of this Document
|
981
|
+
* @remarks The name for this hook is dynamically created by joining "preDelete" with the type name of the Document.
|
982
|
+
* @remarks This is called by {@link Hooks.call}.
|
983
|
+
* @see {@link ClientDatabaseBackend#_preDeleteDocumentArray}.
|
984
|
+
* @see {@link TokenDocument#_preUpdateTokenActor}
|
985
|
+
*/
|
986
|
+
type PreDeleteDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
987
|
+
document: Document.ToConfiguredInstance<D>,
|
988
|
+
options: Document.PreDeleteOptions<InstanceType<D>["documentName"]>,
|
989
|
+
userId: string,
|
990
|
+
) => boolean | void;
|
991
|
+
|
992
|
+
/**
|
993
|
+
* A hook event that fires for every embedded Document type after conclusion of a creation workflow.
|
994
|
+
* Substitute the Document name in the hook event to target a specific type, for example "createToken".
|
995
|
+
* This hook fires for all connected clients after the creation has been processed.
|
996
|
+
*
|
997
|
+
* @param document - The new Document instance which has been created
|
998
|
+
* @param options - Additional options which modified the creation request
|
999
|
+
* @param userId - The ID of the User who triggered the creation workflow
|
1000
|
+
* @typeParam D - the type of the Document constructor
|
1001
|
+
* @remarks The name for this hook is dynamically created by joining "create" and the type name of the Document.
|
1002
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1003
|
+
* @see {@link ClientDatabaseBackend#_postCreateDocumentCallbacks}
|
1004
|
+
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1005
|
+
*/
|
1006
|
+
type CreateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1007
|
+
document: Document.ToConfiguredInstance<D>,
|
1008
|
+
options: Document.OnCreateOptions<InstanceType<D>["documentName"]>,
|
1009
|
+
userId: string,
|
1010
|
+
) => void;
|
1011
|
+
|
1012
|
+
/**
|
1013
|
+
* A hook event that fires for every Document type after conclusion of an update workflow.
|
1014
|
+
* Substitute the Document name in the hook event to target a specific Document type, for example "updateActor".
|
1015
|
+
* This hook fires for all connected clients after the update has been processed.
|
1016
|
+
*
|
1017
|
+
* @param document - The existing Document which was updated
|
1018
|
+
* @param change - Differential data that was used used to update the document
|
1019
|
+
* @param options - Additional options which modified the update request
|
1020
|
+
* @param userId - The ID of the User who triggered the update workflow
|
1021
|
+
* @typeParam D - the type of the Document constructor
|
1022
|
+
* @remarks The name for this hook is dynamically created by joining "update" with the type name of the Document.
|
1023
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1024
|
+
* @see {@link ClientDatabaseBackend#_postUpdateDocumentCallbacks}
|
1025
|
+
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1026
|
+
*/
|
1027
|
+
type UpdateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1028
|
+
document: Document.ToConfiguredInstance<D>,
|
1029
|
+
change: DeepPartial<ConstructorParameters<D>[0]>,
|
1030
|
+
options: Document.OnUpdateOptions<InstanceType<D>["documentName"]>,
|
1031
|
+
userId: string,
|
1032
|
+
) => void;
|
1033
|
+
|
1034
|
+
/**
|
1035
|
+
* A hook event that fires for every Document type after conclusion of an deletion workflow.
|
1036
|
+
* Substitute the Document name in the hook event to target a specific Document type, for example "deleteActor".
|
1037
|
+
* This hook fires for all connected clients after the deletion has been processed.
|
1038
|
+
*
|
1039
|
+
* @param document - The existing Document which was deleted
|
1040
|
+
* @param options - Additional options which modified the deletion request
|
1041
|
+
* @param userId - The ID of the User who triggered the deletion workflow
|
1042
|
+
* @typeParam D - the type of the Document constructor
|
1043
|
+
* @remarks The name for this hook is dynamically created by joining "delete" with the type name of the Document.
|
1044
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1045
|
+
* @see {@link ClientDatabaseBackend#_postDeleteDocumentCallbacks}
|
1046
|
+
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1047
|
+
*/
|
1048
|
+
type DeleteDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1049
|
+
document: Document.ToConfiguredInstance<D>,
|
1050
|
+
options: Document.OnDeleteOptions<InstanceType<D>["documentName"]>,
|
1051
|
+
userId: string,
|
1052
|
+
) => void;
|
1053
|
+
|
1054
|
+
/** PointSource */
|
1055
|
+
|
1056
|
+
/**
|
1057
|
+
* A hook event that fires after RenderedPointSource shaders have initialized.
|
1058
|
+
* @param source - The RenderedPointSource being initialized.
|
1059
|
+
* @typeParam RPS - the type of the RenderedPointSource
|
1060
|
+
* @remarks The name for this hook is dynamically created by wrapping the type name of the shader in `initialize` and `Shaders`.
|
1061
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1062
|
+
*/
|
1063
|
+
type InitializeRenderedPointSourceShaders<RPS extends RenderedPointSource = RenderedPointSource> = (
|
1064
|
+
source: RPS,
|
1065
|
+
) => void;
|
1066
|
+
|
1067
|
+
/** InteractionLayer */
|
1068
|
+
|
1069
|
+
/**
|
1070
|
+
* A hook event that fires with a {@link InteractionLayer} becomes active.
|
1071
|
+
* The dispatched event name replaces "Layer" with the named InteractionLayer subclass, i.e. "activateTokensLayer".
|
1072
|
+
* @param layer - The layer becoming active
|
1073
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1074
|
+
*/
|
1075
|
+
type ActivateLayer<L extends InteractionLayer = InteractionLayer> = (layer: L) => void;
|
1076
|
+
|
1077
|
+
/**
|
1078
|
+
* A hook event that fires with a {@link InteractionLayer} becomes inactive.
|
1079
|
+
* The dispatched event name replaces "Layer" with the named InteractionLayer subclass, i.e. "deactivateTokensLayer".
|
1080
|
+
* @param layer - The layer becoming inactive
|
1081
|
+
* @remarks This is called by {@link Hooks.callAll}.
|
1082
|
+
*/
|
1083
|
+
type DeactivateLayer<L extends InteractionLayer = InteractionLayer> = (layer: L) => void;
|
1084
|
+
|
1085
|
+
/**
|
1086
|
+
* A hook event that fires when the context menu for entries in an Application is constructed. Substitute the
|
1087
|
+
* Application name in the hook event to target a specific Application, for example
|
1088
|
+
* "getActorDirectoryEntryContext".
|
1089
|
+
* @param html - The HTML element to which the context options are attached
|
1090
|
+
* @param entryOptions - The context menu entries
|
1091
|
+
* @remarks This is called by {@link Hooks.call}.
|
1092
|
+
* @see {@link ContextMenu.create}
|
1093
|
+
*/
|
1094
|
+
type GetEntryContext = (html: JQuery, entryOptions: ContextMenuEntry[]) => boolean | void;
|
1095
|
+
|
1096
|
+
/**
|
1097
|
+
* A hook event that fires when the context menu for a Sound in the PlaylistDirectory is constructed.
|
1098
|
+
* @param html - The HTML element to which the context options are attached
|
1099
|
+
* @param entryOptions - The context menu entries
|
1100
|
+
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the PlaylistDirectory
|
1101
|
+
* and "SoundContext".
|
1102
|
+
* @remarks This is called by {@link Hooks.call}.
|
1103
|
+
* @see {@link PlaylistDirectory#_contextMenu}
|
1104
|
+
*/
|
1105
|
+
type GetPlaylistDirectorySoundContext = (html: JQuery, entryOptions: ContextMenuEntry[]) => boolean | void;
|
1106
|
+
|
1107
|
+
/**
|
1108
|
+
* A hook event that fires when the context menu for folders in a SidebarTab
|
1109
|
+
* is constructed. Substitute the SidebarTab name in the hook event to target
|
1110
|
+
* a specific SidebarTab, for example "getActorDirectoryFolderContext".
|
1111
|
+
* @param html - The HTML element to which the context options are attached
|
1112
|
+
* @param entryOptions - The context menu entries
|
1113
|
+
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the SidebarDirectory
|
1114
|
+
* and "FolderContext".
|
1115
|
+
* @remarks This is called by {@link Hooks.call}.
|
1116
|
+
* @see {@link SidebarDirectory#_contextMenu}
|
1117
|
+
*/
|
1118
|
+
type GetSidebarDirectoryFolderContext = (html: JQuery, entryOptions: ContextMenuEntry[]) => boolean | void;
|
1119
|
+
|
1120
|
+
type DynamicCallbacks =
|
1121
|
+
| RenderApplication
|
1122
|
+
| GetApplicationHeaderButtons
|
1123
|
+
| CloseApplication
|
1124
|
+
| DrawLayer
|
1125
|
+
| TearDownLayer
|
1126
|
+
| PastePlaceableObject
|
1127
|
+
| DrawObject
|
1128
|
+
| ControlObject
|
1129
|
+
| DestroyObject
|
1130
|
+
| HoverObject
|
1131
|
+
| PreCreateDocument
|
1132
|
+
| PreUpdateDocument
|
1133
|
+
| PreDeleteDocument
|
1134
|
+
| CreateDocument
|
1135
|
+
| UpdateDocument
|
1136
|
+
| DeleteDocument
|
1137
|
+
| InitializeRenderedPointSourceShaders
|
1138
|
+
| ActivateLayer
|
1139
|
+
| DeactivateLayer
|
1140
|
+
| GetEntryContext
|
1141
|
+
| GetPlaylistDirectorySoundContext
|
1142
|
+
| GetSidebarDirectoryFolderContext
|
1143
|
+
| HoverObject;
|
1144
|
+
|
1145
|
+
interface ErrorCallbackParameters {
|
1146
|
+
"Canvas#draw": [location: "Canvas#draw", err: Error, data: { layer: CanvasLayer }];
|
1147
|
+
"Application#render": [location: "Application#render", err: Error, data: Application.RenderOptions];
|
1148
|
+
"Localization#_loadTranslationFile": [
|
1149
|
+
location: "Localization#_loadTranslationFile",
|
1150
|
+
err: Error,
|
1151
|
+
data: { src: string },
|
1152
|
+
];
|
1153
|
+
"ClientDatabaseBackend#_preCreateDocumentArray": [
|
1154
|
+
location: "ClientDatabaseBackend#_preCreateDocumentArray",
|
1155
|
+
err: Error,
|
1156
|
+
data: { id: string },
|
1157
|
+
];
|
1158
|
+
"ClientDatabaseBackend#_preUpdateDocumentArray": [
|
1159
|
+
location: "ClientDatabaseBackend#_preUpdateDocumentArray",
|
1160
|
+
err: Error,
|
1161
|
+
data: { id: string },
|
1162
|
+
];
|
1163
|
+
"WorldCollection#_initialize": [location: "WorldCollection#_initialize", err: Error, data: { id: string }];
|
1164
|
+
"ClientDocumentMixin#_initialize": [
|
1165
|
+
location: "ClientDocumentMixin#_initialize",
|
1166
|
+
err: Error,
|
1167
|
+
data: { id: string },
|
1168
|
+
];
|
1169
|
+
"Actor#getTokenImages": [location: "Actor#getTokenImages", err: Error, data: EmptyObject];
|
1170
|
+
"Macro#executeChat": [location: "Macro#executeChat", err: Error, data: { command: string }];
|
1171
|
+
"ChatMessage#roll": [location: "ChatMessage#roll", err: Error, data: { command: string }];
|
1172
|
+
"DefaultTokenConfig#_updateObject": [location: "DefaultTokenConfig#_updateObject", err: Error, data: EmptyObject];
|
1173
|
+
"SceneConfig#_updateObject": [location: "SceneConfig#_updateObject", err: Error, data: { scene: string }];
|
1174
|
+
"SidebarDirectory.setupFolders": [location: "SidebarDirectory.setupFolders", err: Error, data: EmptyObject];
|
1175
|
+
"Sidebar#_render": [location: "Sidebar#_render", err: Error, data: { name: string }];
|
1176
|
+
"Game#initializeCanvas": [location: "Game#initializeCanvas", err: Error, data: EmptyObject];
|
1177
|
+
"EmbeddedCollection#_initialize": [
|
1178
|
+
location: "EmbeddedCollection#_initialize",
|
1179
|
+
err: Error,
|
1180
|
+
data: { id: string; documentName: string },
|
1181
|
+
];
|
1182
|
+
}
|
1183
|
+
}
|
1184
|
+
}
|