@league-of-foundry-developers/foundry-vtt-types 12.331.3-beta → 12.331.4-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 +17 -18
- package/package.json +74 -32
- package/src/configuration/configuration.d.mts +316 -0
- package/src/configuration/documents.d.mts +295 -0
- package/src/configuration/globals.d.mts +357 -0
- package/src/configuration/index.d.mts +5 -0
- package/src/foundry/client/apps/app.d.mts +129 -122
- package/src/foundry/client/apps/av/av-config.d.mts +12 -7
- package/src/foundry/client/apps/av/cameras.d.mts +12 -7
- package/src/foundry/client/apps/dice/dice-config.d.mts +59 -0
- package/src/foundry/client/apps/dice/index.d.mts +1 -0
- package/src/foundry/client/apps/form.d.mts +114 -86
- package/src/foundry/client/apps/forms/actor.d.mts +21 -11
- package/src/foundry/client/apps/forms/adventure-exporter.d.mts +12 -7
- package/src/foundry/client/apps/forms/adventure-importer.d.mts +14 -6
- package/src/foundry/client/apps/forms/base-sheet.d.mts +16 -8
- package/src/foundry/client/apps/forms/card-config.d.mts +16 -8
- package/src/foundry/client/apps/forms/cards-config.d.mts +15 -14
- package/src/foundry/client/apps/forms/combat-config.d.mts +7 -7
- package/src/foundry/client/apps/forms/combatant-config.d.mts +3 -3
- package/src/foundry/client/apps/forms/default-sheets-config.d.mts +1 -1
- package/src/foundry/client/apps/forms/effect-config.d.mts +7 -7
- package/src/foundry/client/apps/forms/folder-config.d.mts +5 -5
- package/src/foundry/client/apps/forms/fonts.d.mts +42 -35
- package/src/foundry/client/apps/forms/grid-config.d.mts +12 -13
- package/src/foundry/client/apps/forms/image-popout.d.mts +29 -23
- package/src/foundry/client/apps/forms/item.d.mts +9 -9
- package/src/foundry/client/apps/forms/journal-page-sheet.d.mts +16 -14
- package/src/foundry/client/apps/forms/journal-sheet.d.mts +48 -38
- package/src/foundry/client/apps/forms/macro-config.d.mts +7 -7
- package/src/foundry/client/apps/forms/measure-template.d.mts +10 -12
- package/src/foundry/client/apps/forms/ownership.d.mts +5 -5
- package/src/foundry/client/apps/forms/playlist-config.d.mts +8 -10
- package/src/foundry/client/apps/forms/playlist-sound-config.d.mts +7 -7
- package/src/foundry/client/apps/forms/roll-table-config.d.mts +11 -10
- package/src/foundry/client/apps/forms/scene-config.d.mts +40 -41
- package/src/foundry/client/apps/forms/sheet-config.d.mts +9 -21
- package/src/foundry/client/apps/forms/user-config.d.mts +13 -12
- package/src/foundry/client/apps/hud/chatbubble.d.mts +18 -6
- package/src/foundry/client/apps/hud/container.d.mts +4 -4
- package/src/foundry/client/apps/hud/controls.d.mts +126 -81
- package/src/foundry/client/apps/hud/hotbar.d.mts +17 -12
- package/src/foundry/client/apps/hud/hud.d.mts +5 -5
- package/src/foundry/client/apps/hud/menu.d.mts +10 -3
- package/src/foundry/client/apps/hud/navigation.d.mts +14 -9
- package/src/foundry/client/apps/hud/pause.d.mts +9 -4
- package/src/foundry/client/apps/hud/players.d.mts +14 -9
- package/src/foundry/client/apps/i18n.d.mts +31 -27
- package/src/foundry/client/apps/index.d.mts +1 -0
- package/src/foundry/client/apps/placeables/drawing-config.d.mts +41 -33
- package/src/foundry/client/apps/placeables/drawing-hud.d.mts +5 -5
- package/src/foundry/client/apps/placeables/index.d.mts +0 -2
- package/src/foundry/client/apps/placeables/note-config.d.mts +28 -18
- package/src/foundry/client/apps/placeables/tile-config.d.mts +23 -10
- package/src/foundry/client/apps/placeables/tile-hud.d.mts +10 -5
- package/src/foundry/client/apps/placeables/token-config.d.mts +91 -58
- package/src/foundry/client/apps/placeables/token-hud.d.mts +12 -7
- package/src/foundry/client/apps/placeables/wall-config.d.mts +21 -17
- package/src/foundry/client/apps/sidebar/apps/chat-popout.d.mts +5 -5
- package/src/foundry/client/apps/sidebar/apps/client-settings.d.mts +3 -3
- package/src/foundry/client/apps/sidebar/apps/compendium.d.mts +15 -13
- package/src/foundry/client/apps/sidebar/apps/invitation-links.d.mts +3 -3
- package/src/foundry/client/apps/sidebar/apps/keybindings-config.d.mts +3 -2
- package/src/foundry/client/apps/sidebar/apps/module-management.d.mts +6 -6
- package/src/foundry/client/apps/sidebar/apps/permission-config.d.mts +6 -6
- package/src/foundry/client/apps/sidebar/apps/support-details.d.mts +34 -29
- package/src/foundry/client/apps/sidebar/apps/tours-management.d.mts +2 -2
- package/src/foundry/client/apps/sidebar/apps/world-config.d.mts +13 -10
- package/src/foundry/client/apps/sidebar/directory-tab-mixin.d.mts +50 -35
- package/src/foundry/client/apps/sidebar/document-directory.d.mts +52 -38
- package/src/foundry/client/apps/sidebar/package-configuration.d.mts +4 -4
- package/src/foundry/client/apps/sidebar/sidebar-tab.d.mts +3 -3
- package/src/foundry/client/apps/sidebar/sidebar.d.mts +9 -4
- package/src/foundry/client/apps/sidebar/tabs/actors-directory.d.mts +11 -2
- package/src/foundry/client/apps/sidebar/tabs/cards-directory.d.mts +11 -2
- package/src/foundry/client/apps/sidebar/tabs/chat-log.d.mts +39 -27
- package/src/foundry/client/apps/sidebar/tabs/combat-tracker.d.mts +21 -12
- package/src/foundry/client/apps/sidebar/tabs/compendium-directory.d.mts +30 -15
- package/src/foundry/client/apps/sidebar/tabs/items-directory.d.mts +11 -2
- package/src/foundry/client/apps/sidebar/tabs/journal-directory.d.mts +11 -2
- package/src/foundry/client/apps/sidebar/tabs/macros-directory.d.mts +14 -5
- package/src/foundry/client/apps/sidebar/tabs/playlists-directory.d.mts +30 -22
- package/src/foundry/client/apps/sidebar/tabs/roll-table-directory.d.mts +11 -2
- package/src/foundry/client/apps/sidebar/tabs/scenes-directory.d.mts +14 -5
- package/src/foundry/client/apps/sidebar/tabs/settings.d.mts +23 -5
- package/src/foundry/client/apps/templates.d.mts +1 -1
- package/src/foundry/client/av/client.d.mts +1 -1
- package/src/foundry/client/av/clients/simplepeer.d.mts +11 -1
- package/src/foundry/client/av/master.d.mts +2 -2
- package/src/foundry/client/av/settings.d.mts +17 -15
- package/src/foundry/client/config.d.mts +444 -312
- package/src/foundry/client/core/document-index.d.mts +11 -3
- package/src/foundry/client/core/hooks.d.mts +2 -4
- package/src/foundry/client/core/image.d.mts +14 -13
- package/src/foundry/client/core/issues.d.mts +9 -4
- package/src/foundry/client/core/keybindings.d.mts +5 -5
- package/src/foundry/client/core/nue.d.mts +1 -1
- package/src/foundry/client/core/packages.d.mts +397 -61
- package/src/foundry/client/core/settings.d.mts +62 -38
- package/src/foundry/client/core/socket.d.mts +2 -2
- package/src/foundry/client/core/sorting.d.mts +6 -6
- package/src/foundry/client/core/time.d.mts +6 -3
- package/src/foundry/client/core/tooltip.d.mts +2 -2
- package/src/foundry/client/core/tour.d.mts +59 -50
- package/src/foundry/client/core/tours.d.mts +1 -1
- package/src/foundry/client/core/utils.d.mts +33 -10
- package/src/foundry/client/core/video.d.mts +1 -1
- package/src/foundry/client/core/workers.d.mts +24 -17
- package/src/foundry/client/data/abstract/canvas-document.d.mts +21 -16
- package/src/foundry/client/data/abstract/client-document.d.mts +153 -183
- package/src/foundry/client/data/abstract/directory-collection-mixin.d.mts +23 -39
- package/src/foundry/client/data/abstract/document-collection.d.mts +96 -68
- package/src/foundry/client/data/abstract/world-collection.d.mts +47 -55
- package/src/foundry/client/data/collections/actors.d.mts +30 -28
- package/src/foundry/client/data/collections/cards.d.mts +16 -3
- package/src/foundry/client/data/collections/combats.d.mts +18 -5
- package/src/foundry/client/data/collections/compendium-collection.d.mts +81 -99
- package/src/foundry/client/data/collections/compendium-folders.d.mts +6 -6
- package/src/foundry/client/data/collections/compendium-packs.d.mts +5 -5
- package/src/foundry/client/data/collections/fog.d.mts +16 -3
- package/src/foundry/client/data/collections/folder.d.mts +20 -6
- package/src/foundry/client/data/collections/items.d.mts +17 -4
- package/src/foundry/client/data/collections/journal.d.mts +22 -7
- package/src/foundry/client/data/collections/macros.d.mts +21 -19
- package/src/foundry/client/data/collections/messages.d.mts +19 -6
- package/src/foundry/client/data/collections/playlists.d.mts +17 -5
- package/src/foundry/client/data/collections/scenes.d.mts +24 -27
- package/src/foundry/client/data/collections/settings.d.mts +16 -3
- package/src/foundry/client/data/collections/tables.d.mts +18 -5
- package/src/foundry/client/data/collections/users.d.mts +19 -7
- package/src/foundry/client/data/documents/active-effect.d.mts +677 -85
- package/src/foundry/client/data/documents/actor-delta.d.mts +670 -27
- package/src/foundry/client/data/documents/actor.d.mts +718 -64
- package/src/foundry/client/data/documents/adventure.d.mts +480 -46
- package/src/foundry/client/data/documents/ambient-light.d.mts +423 -19
- package/src/foundry/client/data/documents/ambient-sound.d.mts +473 -14
- package/src/foundry/client/data/documents/card.d.mts +567 -36
- package/src/foundry/client/data/documents/cards.d.mts +744 -87
- package/src/foundry/client/data/documents/chat-message.d.mts +574 -42
- package/src/foundry/client/data/documents/combat.d.mts +699 -69
- package/src/foundry/client/data/documents/combatant.d.mts +504 -24
- package/src/foundry/client/data/documents/drawing.d.mts +540 -14
- package/src/foundry/client/data/documents/fog-exploration.d.mts +416 -21
- package/src/foundry/client/data/documents/folder.d.mts +468 -35
- package/src/foundry/client/data/documents/index.d.mts +2 -0
- package/src/foundry/client/data/documents/item.d.mts +677 -20
- package/src/foundry/client/data/documents/journal-entry-page.d.mts +585 -19
- package/src/foundry/client/data/documents/journal-entry.d.mts +619 -18
- package/src/foundry/client/data/documents/macro.d.mts +528 -25
- package/src/foundry/client/data/documents/measured-template.d.mts +478 -14
- package/src/foundry/client/data/documents/note.d.mts +491 -15
- package/src/foundry/client/data/documents/playlist-sound.d.mts +426 -24
- package/src/foundry/client/data/documents/playlist.d.mts +665 -74
- package/src/foundry/client/data/documents/region-behavior.d.mts +507 -0
- package/src/foundry/client/data/documents/region.d.mts +784 -0
- package/src/foundry/client/data/documents/scene.d.mts +983 -147
- package/src/foundry/client/data/documents/setting.d.mts +395 -13
- package/src/foundry/client/data/documents/table-result.d.mts +476 -14
- package/src/foundry/client/data/documents/table.d.mts +661 -78
- package/src/foundry/client/data/documents/tile.d.mts +499 -14
- package/src/foundry/client/data/documents/token.d.mts +1111 -94
- package/src/foundry/client/data/documents/user.d.mts +493 -25
- package/src/foundry/client/data/documents/wall.d.mts +548 -14
- package/src/foundry/client/game.d.mts +60 -92
- package/src/foundry/client/head.d.mts +9 -9
- package/src/foundry/client/hooks.d.mts +257 -237
- package/src/foundry/client/pixi/board.d.mts +106 -94
- package/src/foundry/client/pixi/core/containers/base-canvas-group.d.mts +97 -25
- package/src/foundry/client/pixi/core/containers/cached-container.d.mts +37 -19
- package/src/foundry/client/pixi/core/containers/full-canvas-container.d.mts +7 -10
- package/src/foundry/client/pixi/core/containers/point-source-mesh.d.mts +25 -15
- package/src/foundry/client/pixi/core/containers/quad-mesh.d.mts +16 -6
- package/src/foundry/client/pixi/core/containers/quadtree.d.mts +113 -54
- package/src/foundry/client/pixi/core/containers/sprite-mesh.d.mts +69 -26
- package/src/foundry/client/pixi/core/containers/unbound-container.d.mts +20 -2
- package/src/foundry/client/pixi/core/interaction/canvas-animation.d.mts +164 -99
- package/src/foundry/client/pixi/core/interaction/control-icon.d.mts +61 -22
- package/src/foundry/client/pixi/core/interaction/mouse-handler.d.mts +120 -53
- package/src/foundry/client/pixi/core/interaction/ping.d.mts +62 -31
- package/src/foundry/client/pixi/core/interaction/pings/chevron.d.mts +23 -10
- package/src/foundry/client/pixi/core/interaction/pings/pulse.d.mts +91 -34
- package/src/foundry/client/pixi/core/interaction/render-flags.d.mts +76 -30
- package/src/foundry/client/pixi/core/interaction/resize-handle.d.mts +35 -5
- package/src/foundry/client/pixi/core/interaction/targets.d.mts +21 -18
- package/src/foundry/client/pixi/core/loader.d.mts +86 -76
- package/src/foundry/client/pixi/core/shapes/limited-angle-polygon.d.mts +42 -17
- package/src/foundry/client/pixi/core/shapes/polygon-mesher.d.mts +92 -64
- package/src/foundry/client/pixi/core/shapes/precise-text.d.mts +28 -10
- package/src/foundry/client/pixi/core/shapes/ray.d.mts +47 -23
- package/src/foundry/client/pixi/core/shapes/source-polygon.d.mts +170 -75
- package/src/foundry/client/pixi/extensions/circle.d.mts +128 -125
- package/src/foundry/client/pixi/extensions/graphics.d.mts +3 -1
- package/src/foundry/client/pixi/extensions/observable-transform.d.mts +5 -4
- package/src/foundry/client/pixi/extensions/polygon.d.mts +154 -134
- package/src/foundry/client/pixi/extensions/rectangle.d.mts +242 -259
- package/src/foundry/client/pixi/groups/effects.d.mts +75 -24
- package/src/foundry/client/pixi/groups/environment.d.mts +68 -19
- package/src/foundry/client/pixi/groups/hidden.d.mts +27 -11
- package/src/foundry/client/pixi/groups/interface.d.mts +62 -38
- package/src/foundry/client/pixi/groups/overlay.d.mts +19 -7
- package/src/foundry/client/pixi/groups/primary.d.mts +66 -44
- package/src/foundry/client/pixi/groups/rendered.d.mts +19 -7
- package/src/foundry/client/pixi/layers/base/canvas-layer.d.mts +11 -15
- package/src/foundry/client/pixi/layers/base/interaction-layer.d.mts +29 -28
- package/src/foundry/client/pixi/layers/base/placeables-layer.d.mts +306 -272
- package/src/foundry/client/pixi/layers/controls/cursor.d.mts +18 -9
- package/src/foundry/client/pixi/layers/controls/door.d.mts +32 -11
- package/src/foundry/client/pixi/layers/controls/layer.d.mts +89 -77
- package/src/foundry/client/pixi/layers/controls/ruler.d.mts +121 -96
- package/src/foundry/client/pixi/layers/effects/background-effects.d.mts +9 -12
- package/src/foundry/client/pixi/layers/effects/coloration-effects.d.mts +9 -10
- package/src/foundry/client/pixi/layers/effects/darkness-effects.d.mts +8 -8
- package/src/foundry/client/pixi/layers/effects/illumination-effects.d.mts +22 -22
- package/src/foundry/client/pixi/layers/effects/visibility.d.mts +106 -86
- package/src/foundry/client/pixi/layers/effects/weather/particles/effect.d.mts +14 -5
- package/src/foundry/client/pixi/layers/effects/weather/particles/leaves.d.mts +31 -2
- package/src/foundry/client/pixi/layers/effects/weather-effects.d.mts +137 -65
- package/src/foundry/client/pixi/layers/grid/highlight.d.mts +14 -4
- package/src/foundry/client/pixi/layers/grid/layer.d.mts +92 -92
- package/src/foundry/client/pixi/layers/grid/mesh.d.mts +37 -16
- package/src/foundry/client/pixi/layers/masks/depth.d.mts +12 -7
- package/src/foundry/client/pixi/layers/masks/occlusion.d.mts +19 -12
- package/src/foundry/client/pixi/layers/masks/vision.d.mts +104 -18
- package/src/foundry/client/pixi/layers/placeables/drawings.d.mts +16 -15
- package/src/foundry/client/pixi/layers/placeables/index.d.mts +1 -0
- package/src/foundry/client/pixi/layers/placeables/lighting.d.mts +12 -14
- package/src/foundry/client/pixi/layers/placeables/notes.d.mts +49 -32
- package/src/foundry/client/pixi/layers/placeables/regions.d.mts +113 -0
- package/src/foundry/client/pixi/layers/placeables/sounds.d.mts +81 -67
- package/src/foundry/client/pixi/layers/placeables/templates.d.mts +11 -15
- package/src/foundry/client/pixi/layers/placeables/tiles.d.mts +30 -21
- package/src/foundry/client/pixi/layers/placeables/tokens.d.mts +66 -52
- package/src/foundry/client/pixi/layers/placeables/walls.d.mts +54 -57
- package/src/foundry/client/pixi/perception/clockwise-sweep.d.mts +62 -27
- package/src/foundry/client/pixi/perception/detection-mode.d.mts +121 -47
- package/src/foundry/client/pixi/perception/fog.d.mts +38 -15
- package/src/foundry/client/pixi/perception/perception-manager.d.mts +136 -136
- package/src/foundry/client/pixi/perception/vision-mode.d.mts +91 -64
- package/src/foundry/client/pixi/perception/weiler-atherton-clipping.d.mts +44 -16
- package/src/foundry/client/pixi/placeable.d.mts +238 -137
- package/src/foundry/client/pixi/placeables/drawing.d.mts +255 -133
- package/src/foundry/client/pixi/placeables/index.d.mts +1 -0
- package/src/foundry/client/pixi/placeables/light.d.mts +199 -64
- package/src/foundry/client/pixi/placeables/note.d.mts +145 -54
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-canvas-object.d.mts +30 -8
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-graphics.d.mts +41 -11
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-occludable-object.d.mts +59 -18
- package/src/foundry/client/pixi/placeables/primary-canvas-objects/primary-sprite-mesh.d.mts +120 -37
- package/src/foundry/client/pixi/placeables/region.d.mts +280 -0
- package/src/foundry/client/pixi/placeables/sound.d.mts +205 -66
- package/src/foundry/client/pixi/placeables/template.d.mts +181 -100
- package/src/foundry/client/pixi/placeables/tile.d.mts +206 -140
- package/src/foundry/client/pixi/placeables/token.d.mts +916 -449
- package/src/foundry/client/pixi/placeables/wall.d.mts +249 -129
- package/src/foundry/client/pixi/webgl/extensions/batch-renderer.d.mts +72 -33
- package/src/foundry/client/pixi/webgl/extensions/batch-shader-generator.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/helpers/{framebugger-snapshot.d.mts → framebuffer-snapshot.d.mts} +10 -9
- package/src/foundry/client/pixi/webgl/helpers/index.d.mts +1 -1
- package/src/foundry/client/pixi/webgl/helpers/smooth-noise.d.mts +38 -23
- package/src/foundry/client/pixi/webgl/helpers/texture-extractor.d.mts +82 -53
- package/src/foundry/client/pixi/webgl/shaders/base-shader-mixin.d.mts +12 -12
- package/src/foundry/client/pixi/webgl/shaders/base-shader.d.mts +45 -28
- package/src/foundry/client/pixi/webgl/shaders/filters/base-filter.d.mts +12 -11
- package/src/foundry/client/pixi/webgl/shaders/filters/base-mask-filter.d.mts +12 -10
- package/src/foundry/client/pixi/webgl/shaders/filters/blur.d.mts +22 -20
- package/src/foundry/client/pixi/webgl/shaders/filters/effects-masking.d.mts +36 -32
- package/src/foundry/client/pixi/webgl/shaders/filters/environment.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/filters/glow-overlay.d.mts +12 -11
- package/src/foundry/client/pixi/webgl/shaders/filters/invisibility.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/filters/outline-overlay.d.mts +12 -11
- package/src/foundry/client/pixi/webgl/shaders/filters/transition.d.mts +67 -60
- package/src/foundry/client/pixi/webgl/shaders/filters/visibility.d.mts +24 -17
- package/src/foundry/client/pixi/webgl/shaders/filters/vision-mask-filter.d.mts +13 -10
- package/src/foundry/client/pixi/webgl/shaders/filters/void.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/filters/weather-occlusion-masks.d.mts +11 -10
- package/src/foundry/client/pixi/webgl/shaders/fragment-channel-mixin.d.mts +20 -14
- package/src/foundry/client/pixi/webgl/shaders/grid/grid.d.mts +12 -11
- package/src/foundry/client/pixi/webgl/shaders/lighting/background-lighting.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/base-lighting.d.mts +33 -33
- package/src/foundry/client/pixi/webgl/shaders/lighting/coloration-lighting.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/darkness-lighting.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/bewitching-wave.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/black-hole.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/chroma.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/emanation.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/energy-field.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/fairy-light.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/flame.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/fog.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/force-grid.d.mts +10 -8
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/ghost-light.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/hexa-dome.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/light-dome.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/magical-gloom.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/pulse.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/radial-rainbow.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/revolving-light.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/roiling-mass.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/siren-light.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/smoke-patch.d.mts +20 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/star-light.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/sunburst.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/swirling-rainbow.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/torch.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/vortex.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/effects/wave.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/lighting/illumination-lighting.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/region/adjust-darkness-level.d.mts +71 -29
- package/src/foundry/client/pixi/webgl/shaders/region/base.d.mts +54 -10
- package/src/foundry/client/pixi/webgl/shaders/region/highlight.d.mts +69 -9
- package/src/foundry/client/pixi/webgl/shaders/samplers/base-sampler.d.mts +24 -25
- package/src/foundry/client/pixi/webgl/shaders/samplers/baseline-illumination.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/samplers/color-adjustment.d.mts +38 -29
- package/src/foundry/client/pixi/webgl/shaders/samplers/depth.d.mts +21 -17
- package/src/foundry/client/pixi/webgl/shaders/samplers/fog-of-war.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/samplers/occlusion.d.mts +20 -18
- package/src/foundry/client/pixi/webgl/shaders/samplers/primary.d.mts +11 -2
- package/src/foundry/client/pixi/webgl/shaders/samplers/token-ring.d.mts +28 -2
- package/src/foundry/client/pixi/webgl/shaders/vision/background-vision.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/vision/base-vision.d.mts +11 -9
- package/src/foundry/client/pixi/webgl/shaders/vision/coloration-vision.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/vision/effects/amplification.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/vision/effects/wave.d.mts +19 -17
- package/src/foundry/client/pixi/webgl/shaders/vision/illumination-vision.d.mts +10 -9
- package/src/foundry/client/pixi/webgl/shaders/weather/base-weather.d.mts +40 -36
- package/src/foundry/client/pixi/webgl/shaders/weather/effect.d.mts +27 -33
- package/src/foundry/client/pixi/webgl/shaders/weather/fog.d.mts +17 -16
- package/src/foundry/client/pixi/webgl/shaders/weather/rain.d.mts +19 -18
- package/src/foundry/client/pixi/webgl/shaders/weather/snow.d.mts +15 -14
- package/src/foundry/client/pixi/workers/texture-worker.d.mts +33 -53
- package/src/foundry/client/tours/setup-tour.d.mts +15 -10
- package/src/foundry/client/ui/context.d.mts +48 -40
- package/src/foundry/client/ui/dialog.d.mts +137 -126
- package/src/foundry/client/ui/drag.d.mts +1 -1
- package/src/foundry/client/ui/dragdrop.d.mts +34 -28
- package/src/foundry/client/ui/editor.d.mts +29 -21
- package/src/foundry/client/ui/filepicker.d.mts +43 -38
- package/src/foundry/client/ui/filter.d.mts +62 -50
- package/src/foundry/client/ui/forms.d.mts +22 -22
- package/src/foundry/client/ui/notifications.d.mts +10 -3
- package/src/foundry/client/ui/prosemirror.d.mts +15 -7
- package/src/foundry/client/ui/secrets.d.mts +42 -27
- package/src/foundry/client/ui/tabs.d.mts +40 -33
- package/src/foundry/client-esm/applications/_module.d.mts +3 -3
- package/src/foundry/client-esm/applications/_types.d.mts +0 -2
- package/src/foundry/client-esm/applications/api/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/api/application.d.mts +36 -19
- package/src/foundry/client-esm/applications/api/dialog.d.mts +20 -22
- package/src/foundry/client-esm/applications/api/document-sheet.d.mts +26 -12
- package/src/foundry/client-esm/applications/api/handlebars-application.d.mts +142 -126
- package/src/foundry/client-esm/applications/apps/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/apps/compendium-art-config.d.mts +10 -10
- package/src/foundry/client-esm/applications/apps/permission-config.d.mts +3 -3
- package/src/foundry/client-esm/applications/dice/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/dice/roll-resolver.d.mts +14 -2
- package/src/foundry/client-esm/applications/elements/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/elements/document-tags.d.mts +2 -0
- package/src/foundry/client-esm/applications/elements/file-picker.d.mts +1 -1
- package/src/foundry/client-esm/applications/elements/multi-select.d.mts +15 -5
- package/src/foundry/client-esm/applications/elements/string-tags.d.mts +1 -1
- package/src/foundry/client-esm/applications/forms/fields.d.mts +1 -1
- package/src/foundry/client-esm/applications/sheets/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/sheets/actor-sheet.d.mts +3 -3
- package/src/foundry/client-esm/applications/sheets/ambient-light-config.d.mts +10 -8
- package/src/foundry/client-esm/applications/sheets/ambient-sound-config.d.mts +9 -7
- package/src/foundry/client-esm/applications/sheets/item-sheet.d.mts +3 -3
- package/src/foundry/client-esm/applications/sheets/region-behavior-config.d.mts +30 -5
- package/src/foundry/client-esm/applications/sheets/region-config.d.mts +36 -5
- package/src/foundry/client-esm/applications/sheets/user-config.d.mts +8 -7
- package/src/foundry/client-esm/applications/ui/_module.d.mts +2 -2
- package/src/foundry/client-esm/applications/ui/region-legend.d.mts +45 -3
- package/src/foundry/client-esm/audio/_module.d.mts +2 -3
- package/src/foundry/client-esm/audio/_types.d.mts +2 -0
- package/src/foundry/client-esm/audio/biquad.d.mts +76 -26
- package/src/foundry/client-esm/audio/cache.d.mts +31 -20
- package/src/foundry/client-esm/audio/convolver.d.mts +47 -25
- package/src/foundry/client-esm/audio/helper.d.mts +124 -80
- package/src/foundry/client-esm/audio/sound.d.mts +230 -126
- package/src/foundry/client-esm/audio/timeout.d.mts +28 -12
- package/src/foundry/client-esm/canvas/_module.d.mts +2 -2
- package/src/foundry/client-esm/canvas/edges/_module.d.mts +2 -2
- package/src/foundry/client-esm/canvas/edges/collision.d.mts +69 -18
- package/src/foundry/client-esm/canvas/edges/edge.d.mts +110 -41
- package/src/foundry/client-esm/canvas/edges/edges.d.mts +10 -0
- package/src/foundry/client-esm/canvas/edges/vertex.d.mts +56 -26
- package/src/foundry/client-esm/canvas/regions/_module.d.mts +6 -11
- package/src/foundry/client-esm/canvas/regions/geometry.d.mts +38 -0
- package/src/foundry/client-esm/canvas/regions/mesh.d.mts +72 -0
- package/src/foundry/client-esm/canvas/regions/polygon-tree.d.mts +130 -0
- package/src/foundry/client-esm/canvas/regions/shape.d.mts +129 -0
- package/src/foundry/client-esm/canvas/scene-manager.d.mts +13 -3
- package/src/foundry/client-esm/canvas/smaa/blend.d.mts +14 -3
- package/src/foundry/client-esm/canvas/smaa/edges.d.mts +25 -3
- package/src/foundry/client-esm/canvas/smaa/smaa.d.mts +121 -23
- package/src/foundry/client-esm/canvas/smaa/weights.d.mts +26 -3
- package/src/foundry/client-esm/canvas/sources/_module.d.mts +2 -2
- package/src/foundry/client-esm/canvas/sources/base-effect-source.d.mts +84 -40
- package/src/foundry/client-esm/canvas/sources/base-light-source.d.mts +103 -39
- package/src/foundry/client-esm/canvas/sources/global-light-source.d.mts +89 -15
- package/src/foundry/client-esm/canvas/sources/point-darkness-source.d.mts +71 -27
- package/src/foundry/client-esm/canvas/sources/point-effect-source.d.mts +49 -20
- package/src/foundry/client-esm/canvas/sources/point-light-source.d.mts +57 -16
- package/src/foundry/client-esm/canvas/sources/point-movement-source.d.mts +31 -4
- package/src/foundry/client-esm/canvas/sources/point-sound-source.d.mts +45 -12
- package/src/foundry/client-esm/canvas/sources/point-vision-source.d.mts +98 -52
- package/src/foundry/client-esm/canvas/sources/rendered-effect-source.d.mts +180 -69
- package/src/foundry/client-esm/canvas/tokens/_module.d.mts +2 -3
- package/src/foundry/client-esm/canvas/tokens/ring-config.d.mts +175 -2
- package/src/foundry/client-esm/canvas/tokens/ring-data.d.mts +141 -2
- package/src/foundry/client-esm/canvas/tokens/ring.d.mts +284 -2
- package/src/foundry/client-esm/client.d.mts +47 -54
- package/src/foundry/client-esm/data/_module.d.mts +2 -2
- package/src/foundry/client-esm/data/client-backend.d.mts +22 -23
- package/src/foundry/client-esm/data/region-behaviors/_module.d.mts +11 -14
- package/src/foundry/client-esm/data/region-behaviors/adjust-darkness-level.d.mts +57 -0
- package/src/foundry/client-esm/data/region-behaviors/base.d.mts +59 -0
- package/src/foundry/client-esm/data/region-behaviors/display-scrolling-text.d.mts +64 -0
- package/src/foundry/client-esm/data/region-behaviors/execute-macro.d.mts +27 -0
- package/src/foundry/client-esm/data/region-behaviors/execute-script.d.mts +23 -0
- package/src/foundry/client-esm/data/region-behaviors/pause-game.d.mts +23 -0
- package/src/foundry/client-esm/data/region-behaviors/suppress-weather.d.mts +17 -0
- package/src/foundry/client-esm/data/region-behaviors/teleport-token.d.mts +32 -0
- package/src/foundry/client-esm/data/region-behaviors/toggle-behavior.d.mts +31 -0
- package/src/foundry/client-esm/dice/_module.d.mts +2 -3
- package/src/foundry/client-esm/dice/parser.d.mts +11 -25
- package/src/foundry/client-esm/dice/roll.d.mts +115 -89
- package/src/foundry/client-esm/dice/terms/_module.d.mts +2 -3
- package/src/foundry/client-esm/dice/terms/coin.d.mts +8 -5
- package/src/foundry/client-esm/dice/terms/dice.d.mts +93 -63
- package/src/foundry/client-esm/dice/terms/die.d.mts +11 -4
- package/src/foundry/client-esm/dice/terms/fate.d.mts +9 -2
- package/src/foundry/client-esm/dice/terms/function.d.mts +18 -18
- package/src/foundry/client-esm/dice/terms/numeric.d.mts +3 -5
- package/src/foundry/client-esm/dice/terms/operator.d.mts +2 -2
- package/src/foundry/client-esm/dice/terms/parenthetical.d.mts +9 -10
- package/src/foundry/client-esm/dice/terms/pool.d.mts +25 -31
- package/src/foundry/client-esm/dice/terms/string.d.mts +4 -4
- package/src/foundry/client-esm/dice/terms/term.d.mts +18 -4
- package/src/foundry/client-esm/dice/twister.d.mts +3 -3
- package/src/foundry/client-esm/helpers/_module.d.mts +2 -2
- package/src/foundry/client-esm/helpers/_types.d.mts +12 -46
- package/src/foundry/client-esm/helpers/compendium-art.d.mts +56 -4
- package/src/foundry/common/abstract/_types.d.mts +60 -54
- package/src/foundry/common/abstract/backend.d.mts +51 -45
- package/src/foundry/common/abstract/data.d.mts +132 -154
- package/src/foundry/common/abstract/document.d.mts +1306 -438
- package/src/foundry/common/abstract/embedded-collection-delta.d.mts +1 -1
- package/src/foundry/common/abstract/embedded-collection.d.mts +37 -7
- package/src/foundry/common/abstract/module.d.mts +3 -2
- package/src/foundry/common/abstract/singleton-collection.d.mts +1 -1
- package/src/foundry/common/abstract/socket.d.mts +1 -1
- package/src/foundry/common/abstract/type-data.d.mts +58 -55
- package/src/foundry/common/config.d.mts +5 -3
- package/src/foundry/common/constants.d.mts +261 -231
- package/src/foundry/common/data/data.d.mts +200 -94
- package/src/foundry/common/data/fields.d.mts +700 -644
- package/src/foundry/common/data/module.d.mts +2 -2
- package/src/foundry/common/data/validation-failure.d.mts +12 -9
- package/src/foundry/common/documents/_module.d.mts +4 -2
- package/src/foundry/common/documents/_types.d.mts +22 -50
- package/src/foundry/common/documents/active-effect.d.mts +280 -179
- package/src/foundry/common/documents/actor-delta.d.mts +318 -69
- package/src/foundry/common/documents/actor.d.mts +305 -117
- package/src/foundry/common/documents/adventure.d.mts +266 -141
- package/src/foundry/common/documents/ambient-light.d.mts +268 -75
- package/src/foundry/common/documents/ambient-sound.d.mts +268 -109
- package/src/foundry/common/documents/card.d.mts +267 -174
- package/src/foundry/common/documents/cards.d.mts +299 -126
- package/src/foundry/common/documents/chat-message.d.mts +276 -158
- package/src/foundry/common/documents/combat.d.mts +300 -89
- package/src/foundry/common/documents/combatant.d.mts +275 -88
- package/src/foundry/common/documents/drawing.d.mts +286 -206
- package/src/foundry/common/documents/fog-exploration.d.mts +258 -70
- package/src/foundry/common/documents/folder.d.mts +252 -81
- package/src/foundry/common/documents/item.d.mts +305 -99
- package/src/foundry/common/documents/journal-entry-page.d.mts +279 -189
- package/src/foundry/common/documents/journal-entry.d.mts +294 -68
- package/src/foundry/common/documents/macro.d.mts +254 -132
- package/src/foundry/common/documents/measured-template.d.mts +293 -139
- package/src/foundry/common/documents/note.d.mts +274 -149
- package/src/foundry/common/documents/playlist-sound.d.mts +260 -94
- package/src/foundry/common/documents/playlist.d.mts +279 -120
- package/src/foundry/common/documents/region-behavior.d.mts +329 -0
- package/src/foundry/common/documents/region.d.mts +327 -0
- package/src/foundry/common/documents/roll-table.d.mts +286 -102
- package/src/foundry/common/documents/scene.d.mts +276 -336
- package/src/foundry/common/documents/setting.d.mts +229 -54
- package/src/foundry/common/documents/table-result.d.mts +267 -94
- package/src/foundry/common/documents/tile.d.mts +301 -170
- package/src/foundry/common/documents/token.d.mts +351 -445
- package/src/foundry/common/documents/user.d.mts +256 -144
- package/src/foundry/common/documents/wall.d.mts +273 -156
- package/src/foundry/common/grid/_module.d.mts +3 -3
- package/src/foundry/common/grid/base.d.mts +66 -49
- package/src/foundry/common/grid/gridless.d.mts +2 -2
- package/src/foundry/common/grid/hexagonal.d.mts +35 -28
- package/src/foundry/common/grid/square.d.mts +3 -3
- package/src/foundry/common/packages/base-module.d.mts +6 -24
- package/src/foundry/common/packages/base-package.d.mts +23 -21
- package/src/foundry/common/packages/base-system.d.mts +6 -63
- package/src/foundry/common/packages/base-world.d.mts +8 -61
- package/src/foundry/common/packages/module.d.mts +7 -7
- package/src/foundry/common/packages/sub-types.d.mts +2 -2
- package/src/foundry/common/primitives/array.d.mts +4 -4
- package/src/foundry/common/primitives/math.d.mts +7 -1
- package/src/foundry/common/primitives/number.d.mts +2 -2
- package/src/foundry/common/primitives/set.d.mts +17 -14
- package/src/foundry/common/primitives/string.d.mts +1 -1
- package/src/foundry/common/prosemirror/_module.d.mts +15 -15
- package/src/foundry/common/prosemirror/dirty-plugin.d.mts +1 -1
- package/src/foundry/common/prosemirror/dom-parser.d.mts +2 -1
- package/src/foundry/common/prosemirror/dropdown.d.mts +1 -1
- package/src/foundry/common/prosemirror/highlight-matches-plugin.d.mts +2 -2
- package/src/foundry/common/prosemirror/image-plugin.d.mts +1 -1
- package/src/foundry/common/prosemirror/menu.d.mts +3 -3
- package/src/foundry/common/prosemirror/paste-transformer.d.mts +1 -1
- package/src/foundry/common/prosemirror/plugin.d.mts +2 -2
- package/src/foundry/common/prosemirror/schema/index.d.mts +0 -1
- package/src/foundry/common/prosemirror/schema/lists.d.mts +2 -0
- package/src/foundry/common/prosemirror/util.d.mts +1 -1
- package/src/foundry/common/types.d.mts +3 -3
- package/src/foundry/common/utils/bitmask.d.mts +23 -11
- package/src/foundry/common/utils/collection.d.mts +61 -38
- package/src/foundry/common/utils/color.d.mts +20 -2
- package/src/foundry/common/utils/event-emitter.d.mts +32 -17
- package/src/foundry/common/utils/helpers.d.mts +36 -26
- package/src/foundry/common/utils/http.d.mts +2 -2
- package/src/foundry/common/utils/module.d.mts +2 -2
- package/src/foundry/common/utils/string-tree.d.mts +45 -39
- package/src/foundry/common/utils/word-tree.d.mts +10 -23
- package/src/foundry/index.d.mts +0 -1
- package/src/foundry/{clipper → public/scripts/clipper}/clipper.d.mts +58 -16
- package/src/foundry/public/scripts/index.d.mts +1 -0
- package/src/foundry/public/scripts/workers/image-compressor.d.mts +23 -0
- package/src/foundry/public/scripts/workers/index.d.mts +1 -0
- package/{index-lenient.d.mts → src/index-lenient.d.mts} +2 -0
- package/src/index.d.mts +6 -0
- package/src/tsconfig.json +15 -0
- package/src/types/augments/particles.d.mts +29 -0
- package/src/types/augments/pixi.d.mts +1024 -21
- package/src/types/augments/smooth.d.mts +31 -0
- package/src/types/augments/tinyMCE.d.mts +1 -1
- package/src/types/config.d.mts +20 -312
- package/src/types/documentConfiguration.d.mts +286 -542
- package/src/types/index.d.mts +1 -1
- package/src/types/lib.d.mts +12 -0
- package/src/types/workers/image-compressor.d.mts +176 -0
- package/src/utils/index.d.mts +1279 -0
- package/tsconfig.json +29 -0
- package/tsconfig.main.json +8 -0
- package/tsconfig.miscellaneous.json +16 -0
- package/index.d.mts +0 -5
- package/src/foundry/client/apps/placeables/light-config.d.mts +0 -100
- package/src/foundry/client/apps/placeables/sound-config.d.mts +0 -43
- package/src/foundry/common/documents/module.d.mts +0 -35
- package/src/foundry/common/primitives/regex.d.mts +0 -12
- package/src/types/helperTypes.d.mts +0 -583
- package/src/types/utils.d.mts +0 -539
- /package/src/foundry/{clipper → public/scripts/clipper}/index.d.mts +0 -0
@@ -1,25 +1,26 @@
|
|
1
1
|
import type { EditorState, Plugin } from "prosemirror-state";
|
2
|
-
import type { DeepPartial, EmptyObject, ValueOf } from "
|
2
|
+
import type { DeepPartial, EmptyObject, ValueOf } from "fvtt-types/utils";
|
3
3
|
import type Document from "../common/abstract/document.d.mts";
|
4
|
-
import type { EffectChangeData } from "../common/documents/_types.d.mts";
|
5
4
|
import type { ProseMirrorDropDown } from "../common/prosemirror/menu.d.mts";
|
6
|
-
import type { DropData } from "./data/abstract/client-document.d.mts";
|
7
|
-
|
8
|
-
// eslint-disable-next-line import/no-named-as-default
|
9
5
|
import type ProseMirrorMenu from "../common/prosemirror/menu.d.mts";
|
10
6
|
import type PointVisionSource from "../client-esm/canvas/sources/point-vision-source.d.mts";
|
11
7
|
import type RenderedEffectSource from "../client-esm/canvas/sources/rendered-effect-source.d.mts";
|
12
|
-
import type {
|
8
|
+
import type {
|
9
|
+
DatabaseCreateOperation,
|
10
|
+
DatabaseDeleteOperation,
|
11
|
+
DatabaseUpdateOperation,
|
12
|
+
} from "../common/abstract/_types.d.mts";
|
13
|
+
import type CompendiumArt from "../client-esm/helpers/compendium-art.d.mts";
|
13
14
|
|
14
15
|
declare global {
|
15
16
|
/**
|
16
|
-
* This namespace contains typescript specific type definitions for the {@link Hooks} callback functions. It contains an
|
17
|
-
* interface ({@link Hooks.StaticCallbacks}) for callbacks with static names. There are more function types in the
|
17
|
+
* This namespace contains typescript specific type definitions for the {@link Hooks | `Hooks`} callback functions. It contains an
|
18
|
+
* interface ({@link Hooks.StaticCallbacks | `Hooks.StaticCallbacks`}) for callbacks with static names. There are more function types in the
|
18
19
|
* namespace for the dynamic hooks, whose names are generated at runtime. There is also a union of all of the dynamic
|
19
|
-
* hooks ({@link Hooks.DynamicCallbacks}).
|
20
|
+
* hooks ({@link Hooks.DynamicCallbacks | `Hooks.DynamicCallbacks`}).
|
20
21
|
*
|
21
|
-
* Callback types remarked to be called with {@link Hooks.callAll} do not care about the return value of the callback.
|
22
|
-
* Callback types remarked to be called with {@link Hooks.call} do care about the return value and will stop executing
|
22
|
+
* Callback types remarked to be called with {@link Hooks.callAll | `Hooks.callAll`} do not care about the return value of the callback.
|
23
|
+
* Callback types remarked to be called with {@link Hooks.call | `Hooks.call`} do care about the return value and will stop executing
|
23
24
|
* remaining callbacks if `false` is returned. If a callback type does not have such a remark, pay attention to the
|
24
25
|
* return value documentation.
|
25
26
|
*
|
@@ -56,20 +57,37 @@ declare global {
|
|
56
57
|
once?: boolean;
|
57
58
|
}
|
58
59
|
|
60
|
+
interface HotReloadData {
|
61
|
+
/** The type of package which was modified */
|
62
|
+
packageType: string;
|
63
|
+
|
64
|
+
/** The id of the package which was modified */
|
65
|
+
packageId: string;
|
66
|
+
|
67
|
+
/** The updated stringified file content */
|
68
|
+
content: string;
|
69
|
+
|
70
|
+
/** The relative file path which was modified */
|
71
|
+
path: string;
|
72
|
+
|
73
|
+
/** The file extension which was modified, e.g. "js", "css", "html" */
|
74
|
+
extension: string;
|
75
|
+
}
|
76
|
+
|
59
77
|
interface StaticCallbacks {
|
60
78
|
/** Core lifecycle */
|
61
79
|
|
62
80
|
/**
|
63
81
|
* A hook event that fires as Foundry is initializing, right before any initialization tasks have begun.
|
64
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
65
|
-
* @see {@link Game#initialize}
|
82
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
83
|
+
* @see {@link Game.initialize | `Game#initialize`}
|
66
84
|
*/
|
67
85
|
init: () => void;
|
68
86
|
|
69
87
|
/**
|
70
88
|
* A hook event that fires once Localization translations have been loaded and are ready for use.
|
71
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
72
|
-
* @see {@link Localization#initialize}
|
89
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
90
|
+
* @see {@link Localization.initialize | `Localization#initialize`}
|
73
91
|
*/
|
74
92
|
i18nInit: () => void;
|
75
93
|
|
@@ -77,15 +95,15 @@ declare global {
|
|
77
95
|
* A hook event that fires when Foundry has finished initializing but
|
78
96
|
* before the game state has been set up. Fires before any Documents, UI
|
79
97
|
* applications, or the Canvas have been initialized.
|
80
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
81
|
-
* @see {@link Game#setupGame}
|
98
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
99
|
+
* @see {@link Game.setupGame | `Game#setupGame`}
|
82
100
|
*/
|
83
101
|
setup: () => void;
|
84
102
|
|
85
103
|
/**
|
86
104
|
* A hook event that fires when the game is fully ready.
|
87
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
88
|
-
* @see {@link Game#setupGame}
|
105
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
106
|
+
* @see {@link Game.setupGame | `Game#setupGame`}
|
89
107
|
*/
|
90
108
|
ready: () => void;
|
91
109
|
|
@@ -96,8 +114,8 @@ declare global {
|
|
96
114
|
* @param err - The error.
|
97
115
|
* @param data - Additional data that might be provided, based on the nature of the error.
|
98
116
|
* (default: `{}`)
|
99
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
100
|
-
* @see {@link Hooks.onError}
|
117
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
118
|
+
* @see {@link Hooks.onError | `Hooks.onError`}
|
101
119
|
*/
|
102
120
|
error: (...args: ValueOf<ErrorCallbackParameters>) => void;
|
103
121
|
|
@@ -106,8 +124,8 @@ declare global {
|
|
106
124
|
/**
|
107
125
|
* A hook event that fires when the game is paused or un-paused.
|
108
126
|
* @param paused - Is the game now paused (true) or un-paused (false)
|
109
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
110
|
-
* @see {@link Game#togglePause}
|
127
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
128
|
+
* @see {@link Game.togglePause | `Game#togglePause`}
|
111
129
|
*/
|
112
130
|
pauseGame: (paused: boolean) => void;
|
113
131
|
|
@@ -115,8 +133,8 @@ declare global {
|
|
115
133
|
* A hook event that fires when the World time has been updated.
|
116
134
|
* @param worldTime - The new canonical World time
|
117
135
|
* @param delta - The time delta
|
118
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
119
|
-
* @see {@link GameTime#onUpdateWorldTime}
|
136
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
137
|
+
* @see {@link GameTime.onUpdateWorldTime | `GameTime#onUpdateWorldTime`}
|
120
138
|
*/
|
121
139
|
updateWorldTime: (worldTime: number, delta: number) => void;
|
122
140
|
|
@@ -125,15 +143,15 @@ declare global {
|
|
125
143
|
/**
|
126
144
|
* A hook event that fires immediately prior to PIXI Application construction with the configuration parameters.
|
127
145
|
* @param canvasConfig - Canvas configuration parameters that will be used to initialize the PIXI.Application
|
128
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
146
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
129
147
|
*/
|
130
148
|
canvasConfig: (canvasConfig: ConstructorParameters<typeof PIXI.Application>[0]) => void;
|
131
149
|
|
132
150
|
/**
|
133
151
|
* A hook event that fires when the Canvas is initialized.
|
134
152
|
* @param canvas - the Canvas instance being initialized
|
135
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
136
|
-
* @see {@link Canvas#draw}
|
153
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
154
|
+
* @see {@link Canvas.draw | `Canvas#draw`}
|
137
155
|
*/
|
138
156
|
canvasInit: (canvas: Canvas) => void;
|
139
157
|
|
@@ -142,31 +160,31 @@ declare global {
|
|
142
160
|
* @param canvas - The Canvas instance
|
143
161
|
* @param view - The applied camera position
|
144
162
|
* @remarks When called during animated panning, the callback is called on every tick.
|
145
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
146
|
-
* @see {@link Canvas#pan}
|
147
|
-
* @see {@link Canvas#animatePan}
|
163
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
164
|
+
* @see {@link Canvas.pan | `Canvas#pan`}
|
165
|
+
* @see {@link Canvas.animatePan | `Canvas#animatePan`}
|
148
166
|
*/
|
149
167
|
canvasPan: (canvas: Canvas, view: Canvas.ViewPosition) => void;
|
150
168
|
|
151
169
|
/**
|
152
170
|
* A hook event that fires when the Canvas is ready.
|
153
171
|
* @param canvas - The Canvas which is now ready for use
|
154
|
-
* @remarks This is called by {@link Hooks.call}.
|
155
|
-
* @see {@link Canvas#draw}
|
172
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
173
|
+
* @see {@link Canvas.draw | `Canvas#draw`}
|
156
174
|
*/
|
157
175
|
canvasReady: (canvas: Canvas) => boolean | void;
|
158
176
|
|
159
177
|
/**
|
160
178
|
* A hook event that fires when the Canvas is deactivated.
|
161
179
|
* @param canvas - The Canvas instance being deactivated
|
162
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
180
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
163
181
|
*/
|
164
182
|
canvasTearDown: (canvas: Canvas) => void;
|
165
183
|
|
166
184
|
/**
|
167
185
|
* A hook event that fires when the Canvas is beginning to draw the canvas groups.
|
168
186
|
* @param canvas - The Canvas instance being drawn
|
169
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
187
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
170
188
|
*/
|
171
189
|
canvasDraw: (canvas: Canvas) => void;
|
172
190
|
|
@@ -174,17 +192,20 @@ declare global {
|
|
174
192
|
* A hook event that fires when some useful data is dropped onto the Canvas.
|
175
193
|
* @param canvas - The Canvas
|
176
194
|
* @param data - The data that has been dropped onto the Canvas
|
177
|
-
* @remarks This is called by {@link Hooks.call}.
|
195
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
178
196
|
* @remarks An explicit return value of `false` prevents the Document being created.
|
179
|
-
* @see {@link Canvas#_onDrop}
|
197
|
+
* @see {@link Canvas._onDrop | `Canvas#_onDrop`}
|
180
198
|
*/
|
181
|
-
dropCanvasData: (
|
199
|
+
dropCanvasData: (
|
200
|
+
canvas: Canvas,
|
201
|
+
data: TokenLayer.DropData | NotesLayer.DropData | SoundsLayer.DropData | TilesLayer.DropData,
|
202
|
+
) => boolean | void;
|
182
203
|
|
183
204
|
/**
|
184
205
|
* A hook event that fires when objects are highlighted on the canvas.
|
185
206
|
* Callers may use this hook to apply their own modifications or enhancements to highlighted objects.
|
186
207
|
* @param active - Is the highlight state now active
|
187
|
-
* @see {@link Canvas#highlightObjects}
|
208
|
+
* @see {@link Canvas.highlightObjects | `Canvas#highlightObjects``}
|
188
209
|
*/
|
189
210
|
highlightObjects: (active: boolean) => void;
|
190
211
|
|
@@ -193,10 +214,10 @@ declare global {
|
|
193
214
|
/**
|
194
215
|
* A hook event that fires when the Scene controls are initialized.
|
195
216
|
* @param controls - The SceneControl configurations
|
196
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
197
|
-
* @see {@link SceneControls#_getControlButtons}
|
217
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
218
|
+
* @see {@link SceneControls._getControlButtons | `SceneControls#_getControlButtons`}
|
198
219
|
*/
|
199
|
-
getSceneControlButtons: (controls:
|
220
|
+
getSceneControlButtons: (controls: SceneControls.Control[]) => void;
|
200
221
|
|
201
222
|
/**
|
202
223
|
* A hook event that fires whenever data is dropped into a Hotbar slot.
|
@@ -205,19 +226,19 @@ declare global {
|
|
205
226
|
* @param hotbar - The Hotbar application instance
|
206
227
|
* @param data - The dropped data object
|
207
228
|
* @param slot - The target hotbar slot
|
208
|
-
* @remarks This is called by {@link Hooks.call}.
|
229
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
209
230
|
* @remarks An explicit return value of `false` prevents the Document being created.
|
210
|
-
* @see {@link Hotbar#_onDrop}
|
231
|
+
* @see {@link Hotbar._onDrop | `Hotbar#_onDrop`}
|
211
232
|
*/
|
212
|
-
hotbarDrop: (hotbar: Hotbar, data: DropData<Macro.
|
233
|
+
hotbarDrop: (hotbar: Hotbar, data: Document.DropData<Macro.Implementation>, slot: number) => boolean | void;
|
213
234
|
|
214
235
|
/**
|
215
236
|
* A hook event that fires when the SceneNavigation menu is expanded or collapsed.
|
216
237
|
* @param nav - The SceneNavigation application
|
217
238
|
* @param collapsed - Whether the navigation is now collapsed or not
|
218
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
219
|
-
* @see {@link SceneNavigation#expand}
|
220
|
-
* @see {@link SceneNavigation#collapse}
|
239
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
240
|
+
* @see {@link SceneNavigation.expand | `SceneNavigation#expand`}
|
241
|
+
* @see {@link SceneNavigation.collapse | `SceneNavigation#collapse`}
|
221
242
|
*/
|
222
243
|
collapseSceneNavigation: (nav: SceneNavigation, collapsed: boolean) => void;
|
223
244
|
|
@@ -225,17 +246,17 @@ declare global {
|
|
225
246
|
* A hook event that fires when the Sidebar is collapsed or expanded.
|
226
247
|
* @param sidebar - The Sidebar application
|
227
248
|
* @param collapsed - Whether the Sidebar is now collapsed or not
|
228
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
229
|
-
* @see {@link Sidebar#expand}
|
230
|
-
* @see {@link Sidebar#collapse}
|
249
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
250
|
+
* @see {@link Sidebar.expand | `Sidebar#expand`}
|
251
|
+
* @see {@link Sidebar.collapse | `Sidebar#collapse`}
|
231
252
|
*/
|
232
253
|
collapseSidebar: (sidebar: Sidebar, collapsed: boolean) => void;
|
233
254
|
|
234
255
|
/**
|
235
256
|
* A hook event that fires when the Sidebar tab is changed.
|
236
257
|
* @param app - The SidebarTab application which is now active
|
237
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
238
|
-
* @see {@link Sidebar#_onChangeTab}
|
258
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
259
|
+
* @see {@link Sidebar._onChangeTab | `Sidebar#_onChangeTab`}
|
239
260
|
*/
|
240
261
|
changeSidebarTab: (app: SidebarTab) => void;
|
241
262
|
|
@@ -245,10 +266,10 @@ declare global {
|
|
245
266
|
* A hook event that fires when a custom active effect is applied.
|
246
267
|
* @param actor - The actor the active effect is being applied to
|
247
268
|
* @param change - The change data being applied
|
248
|
-
* @remarks This is called by {@link Hooks.call}.
|
249
|
-
* @see {@link ActiveEffect#_applyCustom}
|
269
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
270
|
+
* @see {@link ActiveEffect._applyCustom | `ActiveEffect#_applyCustom`}
|
250
271
|
*/
|
251
|
-
applyActiveEffect: (actor: Actor.
|
272
|
+
applyActiveEffect: (actor: Actor.Implementation, change: ActiveEffect.EffectChangeData) => boolean | void;
|
252
273
|
|
253
274
|
/** Compendium */
|
254
275
|
|
@@ -260,25 +281,25 @@ declare global {
|
|
260
281
|
* @param documents - The locally-cached Documents which were modified in the operation
|
261
282
|
* @param options - Additional options which modified the modification request
|
262
283
|
* @param userId - The ID of the User who triggered the modification workflow
|
263
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
264
|
-
* @see {@link CompendiumCollection#_onModifyContents}
|
284
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
285
|
+
* @see {@link CompendiumCollection._onModifyContents | `CompendiumCollection#_onModifyContents`}
|
265
286
|
*/
|
266
287
|
updateCompendium: (
|
267
288
|
pack: CompendiumCollection.Any,
|
268
289
|
documents: Document.Any[],
|
269
|
-
options: Document.
|
290
|
+
options: Document.Database.UpdateOptions<DatabaseUpdateOperation>,
|
270
291
|
userId: string,
|
271
292
|
) => void;
|
272
293
|
|
273
294
|
/** Token */
|
274
295
|
|
275
296
|
/**
|
276
|
-
* A hook event that fires when a token {@link Token} should apply a specific status effect.
|
297
|
+
* A hook event that fires when a token {@link Token | `Token`} should apply a specific status effect.
|
277
298
|
* @param token - The token affected
|
278
299
|
* @param statusId - The status effect ID being applied, from CONFIG.specialStatusEffects.
|
279
300
|
* @param active - Is the special status effect now active?
|
280
301
|
*/
|
281
|
-
applyTokenStatusEffect: (token: Token.
|
302
|
+
applyTokenStatusEffect: (token: Token.Object, statusId: string, active: boolean) => void;
|
282
303
|
|
283
304
|
/**
|
284
305
|
* A hook event that fires when a chat bubble is initially configured.
|
@@ -286,13 +307,13 @@ declare global {
|
|
286
307
|
* @param html - The HTML for the chat bubble
|
287
308
|
* @param message - The spoken message text
|
288
309
|
* @param options - additional options
|
289
|
-
* @remarks This is called when creating a {@link ChatBubble}, but before displaying it.
|
290
|
-
* @remarks This is called by {@link Hooks.call}.
|
310
|
+
* @remarks This is called when creating a {@link ChatBubble | `ChatBubble`}, but before displaying it.
|
311
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
291
312
|
* @remarks An explicit return value of `false` prevents the chat bubble being shown.
|
292
|
-
* @see {@link ChatBubbles#say}
|
313
|
+
* @see {@link ChatBubbles.say | `ChatBubbles#say`}
|
293
314
|
*/
|
294
315
|
chatBubble: (
|
295
|
-
token: Token,
|
316
|
+
token: Token.Object,
|
296
317
|
html: JQuery,
|
297
318
|
message: string,
|
298
319
|
options: {
|
@@ -306,9 +327,9 @@ declare global {
|
|
306
327
|
* @param data - A object describing the modification
|
307
328
|
* @param updates - The update delta that will be applied to the Token's actor
|
308
329
|
* @returns whether the Actor should be updated
|
309
|
-
* @remarks This is called by {@link Hooks.call}.
|
310
|
-
* @see {@link Actor#modifyTokenAttribute}
|
311
|
-
* @see {@link Actor#update}
|
330
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
331
|
+
* @see {@link Actor.modifyTokenAttribute | `Actor#modifyTokenAttribute`}
|
332
|
+
* @see {@link Actor.update | `Actor#update`}
|
312
333
|
*/
|
313
334
|
modifyTokenAttribute: (
|
314
335
|
data: {
|
@@ -332,26 +353,22 @@ declare global {
|
|
332
353
|
* @param user - The User doing the targeting
|
333
354
|
* @param token - The targeted Token
|
334
355
|
* @param targeted - Whether the Token has been targeted or untargeted
|
335
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
336
|
-
* @see {@link UserTargets#_hook}
|
356
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
357
|
+
* @see {@link UserTargets._hook | `UserTargets#_hook`}
|
337
358
|
*/
|
338
|
-
targetToken: (
|
339
|
-
user: User.ConfiguredInstance,
|
340
|
-
token: Document.ConfiguredObjectClassForName<"Token">,
|
341
|
-
targeted: boolean,
|
342
|
-
) => void;
|
359
|
+
targetToken: (user: User.Implementation, token: Document.ObjectClassFor<"Token">, targeted: boolean) => void;
|
343
360
|
|
344
361
|
/** Note */
|
345
362
|
|
346
363
|
/**
|
347
364
|
* A hook event that fires whenever a map note is double-clicked.
|
348
|
-
* The hook provides the note placeable and the arguments passed to the associated {@link JournalSheet} render call.
|
365
|
+
* The hook provides the note placeable and the arguments passed to the associated {@link JournalSheet | `JournalSheet`} render call.
|
349
366
|
* Hooked functions may modify the render arguments or cancel the render by returning false.
|
350
367
|
* @param note - The note that was activated
|
351
|
-
* @param options - Options for rendering the associated {@link JournalSheet}
|
352
|
-
* @remarks This is called by {@link Hooks.call}.
|
368
|
+
* @param options - Options for rendering the associated {@link JournalSheet | `JournalSheet`}
|
369
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
353
370
|
*/
|
354
|
-
activateNote: (note: Note.
|
371
|
+
activateNote: (note: Note.Object, options: JournalSheet.RenderOptions) => true | false;
|
355
372
|
|
356
373
|
/** Cards */
|
357
374
|
|
@@ -360,12 +377,12 @@ declare global {
|
|
360
377
|
* @param origin - The origin Cards document
|
361
378
|
* @param destinations - An array of destination Cards documents
|
362
379
|
* @param context - Additional context which describes the operation
|
363
|
-
* @remarks This is called by {@link Hooks.call}.
|
380
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
364
381
|
* @remarks An explicit return value of `false` prevents the operation.
|
365
382
|
*/
|
366
383
|
dealCards: (
|
367
|
-
origin: Cards.
|
368
|
-
destinations: Cards.
|
384
|
+
origin: Cards.Implementation,
|
385
|
+
destinations: Cards.Implementation[],
|
369
386
|
context: Cards.DealContext,
|
370
387
|
) => boolean | void;
|
371
388
|
|
@@ -374,12 +391,12 @@ declare global {
|
|
374
391
|
* @param origin - The origin Cards document
|
375
392
|
* @param destination - The destination Cards document
|
376
393
|
* @param context - Additional context which describes the operation
|
377
|
-
* @remarks This is called by {@link Hooks.call}.
|
394
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
378
395
|
* @remarks An explicit return value of `false` prevents the operation.
|
379
396
|
*/
|
380
397
|
passCards: (
|
381
|
-
origin: Cards.
|
382
|
-
destination: Cards.
|
398
|
+
origin: Cards.Implementation,
|
399
|
+
destination: Cards.Implementation,
|
383
400
|
context: Cards.DealContext,
|
384
401
|
) => boolean | void;
|
385
402
|
|
@@ -390,8 +407,8 @@ declare global {
|
|
390
407
|
* @param context - Additional context which describes the operation.
|
391
408
|
*/
|
392
409
|
returnCards: (
|
393
|
-
origin: Cards.
|
394
|
-
returned: Card.
|
410
|
+
origin: Cards.Implementation,
|
411
|
+
returned: Card.Implementation[],
|
395
412
|
context: Cards.ReturnContext,
|
396
413
|
) => boolean | void;
|
397
414
|
|
@@ -405,13 +422,13 @@ declare global {
|
|
405
422
|
* @param art - The art being applied.
|
406
423
|
* @remarks Called as part of _initializeSource, after data migration, cleaning, and shims
|
407
424
|
* @remarks Currently only called by Actor but comments are more generic
|
408
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
425
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
409
426
|
*/
|
410
427
|
applyCompendiumArt: (
|
411
|
-
documentClass: Actor.
|
412
|
-
source: foundry.documents.BaseActor.
|
428
|
+
documentClass: Actor.ImplementationClass,
|
429
|
+
source: foundry.documents.BaseActor.CreateData,
|
413
430
|
pack: CompendiumCollection.Any,
|
414
|
-
art:
|
431
|
+
art: CompendiumArt.Info,
|
415
432
|
) => void;
|
416
433
|
|
417
434
|
/** ActorSheet */
|
@@ -421,37 +438,33 @@ declare global {
|
|
421
438
|
* @param actor - The Actor
|
422
439
|
* @param sheet - The ActorSheet application
|
423
440
|
* @param data - The data that has been dropped onto the sheet
|
424
|
-
* @remarks This is called by {@link Hooks.call}.
|
441
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
425
442
|
* @remarks An explicit return value of `false` prevents the Document being created.
|
426
|
-
* @see {@link ActorSheet#_onDrop}
|
443
|
+
* @see {@link ActorSheet._onDrop | `ActorSheet#_onDrop`}
|
427
444
|
*/
|
428
|
-
dropActorSheetData: (
|
429
|
-
actor: Actor.ConfiguredInstance,
|
430
|
-
sheet: ActorSheet,
|
431
|
-
data: ActorSheet.DropData,
|
432
|
-
) => boolean | void;
|
445
|
+
dropActorSheetData: (actor: Actor.Implementation, sheet: ActorSheet, data: ActorSheet.DropData) => boolean | void;
|
433
446
|
|
434
447
|
/** CanvasVisibility */
|
435
448
|
|
436
449
|
/**
|
437
450
|
* A hook event that fires when the set of vision sources are initialized.
|
438
451
|
* @param sources - The collection of current vision sources
|
439
|
-
* @remarks This is called by {@link Hooks.call}.
|
452
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
440
453
|
*/
|
441
454
|
initializeVisionSources: (sources: Collection<PointVisionSource.Any>) => void;
|
442
455
|
|
443
456
|
/**
|
444
457
|
* A hook event that fires when the LightingLayer is refreshed.
|
445
458
|
* @param layer - the LightingLayer
|
446
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
447
|
-
* @see {@link LightingLayer#refresh}
|
459
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
460
|
+
* @see {@link LightingLayer.refresh | `LightingLayer#refresh`}
|
448
461
|
*/
|
449
462
|
lightingRefresh: (layer: LightingLayer) => void;
|
450
463
|
|
451
464
|
/**
|
452
465
|
* A hook event that fires when visibility is refreshed.
|
453
466
|
* @param visibility - The CanvasVisibility instance
|
454
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
467
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
455
468
|
*/
|
456
469
|
visibilityRefresh: (visibility: CanvasVisibility) => void;
|
457
470
|
|
@@ -459,8 +472,8 @@ declare global {
|
|
459
472
|
* A hook event that fires during light source initialization.
|
460
473
|
* This hook can be used to add programmatic light sources to the Scene.
|
461
474
|
* @param source - The EffectsCanvasGroup where light sources are initialized
|
462
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
463
|
-
* @see {@link EffectsCanvasGroup#initializeLightSources}
|
475
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
476
|
+
* @see {@link EffectsCanvasGroup.initializeLightSources | `EffectsCanvasGroup#initializeLightSources`}
|
464
477
|
*/
|
465
478
|
initializeLightSources: (group: EffectsCanvasGroup) => void;
|
466
479
|
|
@@ -468,15 +481,15 @@ declare global {
|
|
468
481
|
* A hook event that fires during darkness source initialization.
|
469
482
|
* This hook can be used to add programmatic darkness sources to the Scene.
|
470
483
|
* @param group - The EffectsCanvasGroup where darkness sources are initialized
|
471
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
484
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
472
485
|
*/
|
473
486
|
initializeDarknessSources: (group: EffectsCanvasGroup) => void;
|
474
487
|
|
475
488
|
/**
|
476
489
|
* A hook event that fires when the CanvasVisibility layer has been refreshed.
|
477
490
|
* @param visibility - The CanvasVisibility layer
|
478
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
479
|
-
* @see {@link CanvasVisibility#restrictVisibility}
|
491
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
492
|
+
* @see {@link CanvasVisibility.restrictVisibility | `CanvasVisibility#restrictVisibility`}
|
480
493
|
*/
|
481
494
|
sightRefresh: (visibility: CanvasVisibility) => void;
|
482
495
|
|
@@ -486,11 +499,11 @@ declare global {
|
|
486
499
|
* Initialize the weather container from a weather config object.
|
487
500
|
* @param weatherEffect - The weather effects canvas layer
|
488
501
|
* @param weatherEffectsConfig - The weather effects config object
|
489
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
502
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
490
503
|
*/
|
491
504
|
initializeWeatherEffects: (
|
492
505
|
weatherEffect: WeatherEffects,
|
493
|
-
weatherEffectsConfig?: WeatherEffects.
|
506
|
+
weatherEffectsConfig?: WeatherEffects.EffectConfiguration | null,
|
494
507
|
) => void;
|
495
508
|
|
496
509
|
/** Adventure */
|
@@ -503,13 +516,13 @@ declare global {
|
|
503
516
|
* @param toCreate - Adventure data which needs to be created in the World
|
504
517
|
* @param toUpdate - Adventure data which needs to be updated in the World
|
505
518
|
* @returns False to prevent the core software from handling the import
|
506
|
-
* @remarks This is called by {@link Hooks.call}.
|
519
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
507
520
|
*/
|
508
521
|
preImportAdventure: (
|
509
|
-
adventure: Adventure.
|
522
|
+
adventure: Adventure.Implementation,
|
510
523
|
formData: object, // TODO: Improve this. Also relevant to `AdventureImporter#_updateObject`
|
511
|
-
toCreate:
|
512
|
-
toUpdate:
|
524
|
+
toCreate: Adventure.ImportData["toCreate"],
|
525
|
+
toUpdate: Adventure.ImportData["toUpdate"],
|
513
526
|
) => boolean | void;
|
514
527
|
|
515
528
|
/**
|
@@ -519,13 +532,13 @@ declare global {
|
|
519
532
|
* @param toCreate - Adventure data which needs to be created in the World
|
520
533
|
* @param toUpdate - Adventure data which needs to be updated in the World
|
521
534
|
* @returns False to prevent the core software from handling the import
|
522
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
535
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
523
536
|
*/
|
524
537
|
importAdventure: (
|
525
|
-
adventure: Adventure.
|
538
|
+
adventure: Adventure.Implementation,
|
526
539
|
formData: object, // TODO: Improve this. Also relevant to `AdventureImporter#_updateObject`
|
527
|
-
toCreate:
|
528
|
-
toUpdate:
|
540
|
+
toCreate: Adventure.ImportData["toCreate"],
|
541
|
+
toUpdate: Adventure.ImportData["toUpdate"],
|
529
542
|
) => void;
|
530
543
|
|
531
544
|
/** Socket */
|
@@ -534,9 +547,9 @@ declare global {
|
|
534
547
|
* A hook event that fires whenever some other User joins or leaves the game session.
|
535
548
|
* @param user - The User who connected or disconnected
|
536
549
|
* @param connected - Is the user now connected (true) or disconnected (false)
|
537
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
550
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
538
551
|
*/
|
539
|
-
userConnected: (user: User.
|
552
|
+
userConnected: (user: User.Implementation, connected: boolean) => void;
|
540
553
|
|
541
554
|
/** Combat */
|
542
555
|
|
@@ -546,13 +559,9 @@ declare global {
|
|
546
559
|
* @param combat - The Combat encounter for which the turn order has changed
|
547
560
|
* @param prior - The prior turn state
|
548
561
|
* @param current - The new turn state
|
549
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
562
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
550
563
|
*/
|
551
|
-
combatTurnChange: (
|
552
|
-
combat: Combat.ConfiguredInstance,
|
553
|
-
prior: Combat.HistoryData,
|
554
|
-
current: Combat.HistoryData,
|
555
|
-
) => void;
|
564
|
+
combatTurnChange: (combat: Combat.Implementation, prior: Combat.HistoryData, current: Combat.HistoryData) => void;
|
556
565
|
|
557
566
|
/**
|
558
567
|
* A hook event that fires when a Combat encounter is started.
|
@@ -561,7 +570,7 @@ declare global {
|
|
561
570
|
* @param updateData - An object which contains Combat properties that will be updated. Can be mutated.
|
562
571
|
*/
|
563
572
|
combatStart: (
|
564
|
-
combat: Combat.
|
573
|
+
combat: Combat.Implementation,
|
565
574
|
updateData: {
|
566
575
|
/** The initial round */
|
567
576
|
round: number;
|
@@ -578,7 +587,7 @@ declare global {
|
|
578
587
|
* @param updateOptions - An object which contains options provided to the update method. Can be mutated.
|
579
588
|
*/
|
580
589
|
combatTurn: (
|
581
|
-
combat: Combat.
|
590
|
+
combat: Combat.Implementation,
|
582
591
|
updateData: {
|
583
592
|
/** The current round of combat */
|
584
593
|
round: number;
|
@@ -600,7 +609,7 @@ declare global {
|
|
600
609
|
* @param updateOptions - An object which contains options provided to the update method. Can be mutated.
|
601
610
|
*/
|
602
611
|
combatRound: (
|
603
|
-
combat: Combat.
|
612
|
+
combat: Combat.Implementation,
|
604
613
|
updateData: {
|
605
614
|
/** The new round of combat */
|
606
615
|
round: number;
|
@@ -623,7 +632,7 @@ declare global {
|
|
623
632
|
* Hooked functions may append their own drop-downs or append entries to existing drop-downs.
|
624
633
|
* @param menu - The ProseMirrorMenu instance.
|
625
634
|
* @param config - The drop-down config.
|
626
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
635
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
627
636
|
*/
|
628
637
|
getProseMirrorMenuDropdowns: (
|
629
638
|
menu: ProseMirrorMenu,
|
@@ -639,7 +648,7 @@ declare global {
|
|
639
648
|
* Hooked functions may append their own buttons to the list.
|
640
649
|
* @param menu - The ProseMirrorMenu instance
|
641
650
|
* @param config - The button configuration objects
|
642
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
651
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
643
652
|
*/
|
644
653
|
// TODO: Having trouble finding the appropriate typing for the menu items? Also, where is this even called?
|
645
654
|
getProseMirrorMenuItems: (menu: ProseMirrorMenu, config: unknown[]) => void;
|
@@ -654,8 +663,8 @@ declare global {
|
|
654
663
|
* @param uuid - A UUID that uniquely identifies this ProseMirror instance.
|
655
664
|
* @param plugins - A list of plugins that will be loaded.
|
656
665
|
* @param options - The provisional EditorState and ProseMirrorMenuPlugin.
|
657
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
658
|
-
* @see {@link ProseMirrorEditor.create}
|
666
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
667
|
+
* @see {@link ProseMirrorEditor.create | `ProseMirrorEditor.create`}
|
659
668
|
*/
|
660
669
|
createProseMirrorEditor: (uuid: string, plugins: Record<string, Plugin>, options: { state: EditorState }) => void;
|
661
670
|
|
@@ -666,7 +675,7 @@ declare global {
|
|
666
675
|
* The hook provides the hot reload data related to the file change.
|
667
676
|
* Hooked functions may intercept the hot reload and prevent the core software from handling it by returning false.
|
668
677
|
* @param data - The hot reload data
|
669
|
-
* @remarks This is called by {@link Hooks.call}.
|
678
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
670
679
|
*/
|
671
680
|
hotReload: (data: HotReloadData) => boolean | void;
|
672
681
|
|
@@ -677,9 +686,9 @@ declare global {
|
|
677
686
|
* @param chatLog - The ChatLog instance
|
678
687
|
* @param message - The trimmed message content
|
679
688
|
* @param chatData - The basic chat data
|
680
|
-
* @remarks This is called by {@link Hooks.call}.
|
689
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
681
690
|
* @remarks An explicit return value of `false` prevents the chat message from being created.
|
682
|
-
* @see {@link ChatLog#processMessage}
|
691
|
+
* @see {@link ChatLog.processMessage | `ChatLog#processMessage`}
|
683
692
|
*/
|
684
693
|
chatMessage: (
|
685
694
|
chatLog: ChatLog,
|
@@ -688,8 +697,8 @@ declare global {
|
|
688
697
|
/** The id of the User sending the message */
|
689
698
|
user: string;
|
690
699
|
|
691
|
-
/** The identified speaker data, see {@link ChatMessage.getSpeaker} */
|
692
|
-
speaker: ReturnType<ChatMessage.
|
700
|
+
/** The identified speaker data, see {@link ChatMessage.getSpeaker | `ChatMessage.getSpeaker`} */
|
701
|
+
speaker: ReturnType<ChatMessage.ImplementationClass["getSpeaker"]>;
|
693
702
|
},
|
694
703
|
) => boolean | void;
|
695
704
|
|
@@ -699,17 +708,17 @@ declare global {
|
|
699
708
|
* @param message - The ChatMessage document being rendered
|
700
709
|
* @param html - The pending HTML as a jQuery object
|
701
710
|
* @param messageData - The input data provided for template rendering
|
702
|
-
* @remarks This is called by {@link Hooks.call}.
|
703
|
-
* @see {@link ChatMessage#render}
|
711
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
712
|
+
* @see {@link ChatMessage.render | `ChatMessage#render`}
|
704
713
|
*/
|
705
714
|
renderChatMessage: (
|
706
|
-
message: ChatMessage,
|
715
|
+
message: ChatMessage.Implementation,
|
707
716
|
html: JQuery,
|
708
717
|
messageData: {
|
709
|
-
message:
|
718
|
+
message: ChatMessage.Source;
|
710
719
|
user: Game["user"];
|
711
|
-
author:
|
712
|
-
alias:
|
720
|
+
author: User.Implementation | null;
|
721
|
+
alias: string;
|
713
722
|
cssClass: string;
|
714
723
|
isWhisper: boolean;
|
715
724
|
canDelete: boolean;
|
@@ -725,22 +734,22 @@ declare global {
|
|
725
734
|
/**
|
726
735
|
* A hook event that fires when the user modifies a global volume slider.
|
727
736
|
* @param volume - The new volume level
|
728
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
729
|
-
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
737
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
738
|
+
* @see {@link AudioHelper._onChangeGlobalVolume | `AudioHelper#_onChangeGlobalVolume`}
|
730
739
|
*/
|
731
740
|
globalAmbientVolumeChanged: (volume: number) => void;
|
732
741
|
/**
|
733
742
|
* A hook event that fires when the user modifies a global volume slider.
|
734
743
|
* @param volume - The new volume level
|
735
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
736
|
-
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
744
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
745
|
+
* @see {@link AudioHelper._onChangeGlobalVolume | `AudioHelper#_onChangeGlobalVolume`}
|
737
746
|
*/
|
738
747
|
globalInterfaceVolumeChanged: (volume: number) => void;
|
739
748
|
/**
|
740
749
|
* A hook event that fires when the user modifies a global volume slider.
|
741
750
|
* @param volume - The new volume level
|
742
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
743
|
-
* @see {@link AudioHelper#_onChangeGlobalVolume}
|
751
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
752
|
+
* @see {@link AudioHelper._onChangeGlobalVolume | `AudioHelper#_onChangeGlobalVolume`}
|
744
753
|
*/
|
745
754
|
globalPlaylistVolumeChanged: (volume: number) => void;
|
746
755
|
|
@@ -748,8 +757,8 @@ declare global {
|
|
748
757
|
* A hook event that fires when the AV settings are changed.
|
749
758
|
* @param settings - The AVSettings manager
|
750
759
|
* @param changed - The delta of the settings that have been changed
|
751
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
752
|
-
* @see {@link AVSettings#_onSettingsChanged}
|
760
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
761
|
+
* @see {@link AVSettings._onSettingsChanged | `AVSettings#_onSettingsChanged`}
|
753
762
|
*/
|
754
763
|
rtcSettingsChanged: (settings: AVSettings, changed: DeepPartial<AVSettings.Settings>) => void;
|
755
764
|
|
@@ -760,12 +769,12 @@ declare global {
|
|
760
769
|
* @param table - The RollTable
|
761
770
|
* @param config - The RollTableConfig application
|
762
771
|
* @param data - The data dropped onto the RollTableConfig
|
763
|
-
* @remarks This is called by {@link Hooks.call}.
|
772
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
764
773
|
* @remarks An explicit return value of `false` prevents the Document being created.
|
765
|
-
* @see {@link RollTableConfig#_onDrop}
|
774
|
+
* @see {@link RollTableConfig._onDrop | `RollTableConfig#_onDrop`}
|
766
775
|
*/
|
767
776
|
dropRollTableSheetData: (
|
768
|
-
table: RollTable.
|
777
|
+
table: RollTable.Implementation,
|
769
778
|
config: RollTableConfig,
|
770
779
|
data: object,
|
771
780
|
) => boolean | void;
|
@@ -773,7 +782,7 @@ declare global {
|
|
773
782
|
/**
|
774
783
|
* A hook event that allows to pass custom dynamic ring configurations.
|
775
784
|
* @param ringConfig - The ring configuration instance
|
776
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
785
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
777
786
|
*/
|
778
787
|
initializeDynamicTokenRingConfig: (ringConfig: foundry.canvas.tokens.TokenRingConfig) => void;
|
779
788
|
|
@@ -783,19 +792,19 @@ declare global {
|
|
783
792
|
* A hook event that fires when the context menu for a SceneNavigation entry is constructed.
|
784
793
|
* @param html - The HTML element to which the context options are attached
|
785
794
|
* @param entryOptions - The context menu entries
|
786
|
-
* @remarks This is called by {@link Hooks.call}.
|
787
|
-
* @see {@link SceneNavigation#activateListeners}
|
795
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
796
|
+
* @see {@link SceneNavigation.activateListeners | `SceneNavigation#activateListeners`}
|
788
797
|
*/
|
789
|
-
getSceneNavigationContext: (html: JQuery, entryOptions:
|
798
|
+
getSceneNavigationContext: (html: JQuery, entryOptions: ContextMenu.Entry[]) => boolean | void;
|
790
799
|
|
791
800
|
/**
|
792
801
|
* A hook event that fires when the context menu for a PlayersList entry is constructed.
|
793
802
|
* @param html - The HTML element to which the context options are attached
|
794
803
|
* @param entryOptions - The context menu entries
|
795
|
-
* @remarks This is called by {@link Hooks.call}.
|
796
|
-
* @see {@link PlayerList#activateListeners}
|
804
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
805
|
+
* @see {@link PlayerList.activateListeners | `PlayerList#activateListeners`}
|
797
806
|
*/
|
798
|
-
getUserContextOptions: (html: JQuery, entryOptions:
|
807
|
+
getUserContextOptions: (html: JQuery, entryOptions: ContextMenu.Entry[]) => boolean | void;
|
799
808
|
}
|
800
809
|
|
801
810
|
/** Application */
|
@@ -810,14 +819,14 @@ declare global {
|
|
810
819
|
* @param data - The object of data used when rendering the application
|
811
820
|
* @typeParam A - the type of the Application
|
812
821
|
* @remarks The name for this hook is dynamically created by joining "render" with the type name of the Application.
|
813
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
814
|
-
* @see {@link Application#_render}
|
822
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
823
|
+
* @see {@link Application._render | `Application#_render`}
|
815
824
|
*/
|
816
|
-
type RenderApplication<A extends Application = Application> = (
|
825
|
+
type RenderApplication<A extends Application.Any = Application.Any> = (
|
817
826
|
app: A,
|
818
827
|
html: JQuery,
|
819
828
|
data: ReturnType<A["getData"]> extends Promise<infer T> ? T : ReturnType<A["getData"]>,
|
820
|
-
) =>
|
829
|
+
) => void;
|
821
830
|
|
822
831
|
/**
|
823
832
|
* A hook event that fires whenever this Application is first rendered to add buttons to its header.
|
@@ -826,10 +835,10 @@ declare global {
|
|
826
835
|
* @typeParam A - the type of the Application
|
827
836
|
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the Application and
|
828
837
|
* "HeaderButtons".
|
829
|
-
* @remarks This is called by {@link Hooks.call}.
|
830
|
-
* @see {@link Application#_getHeaderButtons}
|
838
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
839
|
+
* @see {@link Application._getHeaderButtons | `Application#_getHeaderButtons`}
|
831
840
|
*/
|
832
|
-
type GetApplicationHeaderButtons<A extends Application = Application> = (
|
841
|
+
type GetApplicationHeaderButtons<A extends Application.Any = Application.Any> = (
|
833
842
|
app: A,
|
834
843
|
buttons: Application.HeaderButton[],
|
835
844
|
) => boolean | void;
|
@@ -840,35 +849,43 @@ declare global {
|
|
840
849
|
* @param html - The application HTML when it is closed
|
841
850
|
* @typeParam A - the type of the Application
|
842
851
|
* @remarks The name for this hook is dynamically created by joining "close" with the type name of the Application.
|
843
|
-
* @remarks This is called by {@link Hooks.
|
844
|
-
* @see {@link Application#close}
|
852
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
853
|
+
* @see {@link Application.close | `Application#close`}
|
845
854
|
*/
|
846
|
-
type CloseApplication<A extends Application = Application> = (app: A, html: JQuery) =>
|
855
|
+
type CloseApplication<A extends Application.Any = Application.Any> = (app: A, html: JQuery) => void;
|
856
|
+
|
857
|
+
/** ApplicationV2 */
|
858
|
+
|
859
|
+
// Not explicitly typed in Foundry v12 but still fires
|
860
|
+
type RenderApplicationV2<
|
861
|
+
A extends foundry.applications.api.ApplicationV2.Any = foundry.applications.api.ApplicationV2.Any,
|
862
|
+
> = (app: A, element: HTMLElement) => void;
|
863
|
+
|
864
|
+
// Not explicitly typed in Foundry v12 but still fires
|
865
|
+
type CloseApplicationV2<
|
866
|
+
A extends foundry.applications.api.ApplicationV2.Any = foundry.applications.api.ApplicationV2.Any,
|
867
|
+
> = (app: A) => void;
|
847
868
|
|
848
869
|
/** EffectsCanvasGroup */
|
849
870
|
|
850
871
|
/**
|
851
|
-
* A hook event that fires when a {@link CanvasGroup} is drawn.
|
872
|
+
* A hook event that fires when a {@link CanvasGroup | `CanvasGroup`} is drawn.
|
852
873
|
* The dispatched event name replaces "Group" with the named CanvasGroup subclass, i.e. "drawPrimaryCanvasGroup".
|
853
874
|
* @param group - The group being drawn
|
854
875
|
*/
|
855
|
-
type DrawGroup<
|
856
|
-
G extends ReturnType<typeof CanvasGroupMixin> = ReturnType<typeof CanvasGroupMixin<CanvasGroupMixin.BaseClass>>,
|
857
|
-
> = (group: G) => void;
|
876
|
+
type DrawGroup<G extends CanvasGroupMixin.AnyMixed = CanvasGroupMixin.AnyMixed> = (group: G) => void;
|
858
877
|
|
859
878
|
/**
|
860
|
-
* A hook event that fires when a {@link CanvasGroup} is deconstructed.
|
879
|
+
* A hook event that fires when a {@link CanvasGroup | `CanvasGroup`} is deconstructed.
|
861
880
|
* The dispatched event name replaces "Group" with the named CanvasGroup subclass, i.e. "tearDownPrimaryCanvasGroup".
|
862
881
|
* @param group - The group being deconstructed
|
863
882
|
*/
|
864
|
-
type TearDownGroup<
|
865
|
-
G extends ReturnType<typeof CanvasGroupMixin> = ReturnType<typeof CanvasGroupMixin<CanvasGroupMixin.BaseClass>>,
|
866
|
-
> = (group: G) => void;
|
883
|
+
type TearDownGroup<G extends CanvasGroupMixin.AnyMixed = CanvasGroupMixin.AnyMixed> = (group: G) => void;
|
867
884
|
|
868
885
|
/** CanvasLayer */
|
869
886
|
|
870
887
|
/**
|
871
|
-
* A hook event that fires when a {@link CanvasLayer} is initially drawn.
|
888
|
+
* A hook event that fires when a {@link CanvasLayer | `CanvasLayer`} is initially drawn.
|
872
889
|
* The dispatched event name replaces "Layer" with the named CanvasLayer subclass, i.e. "drawTokensLayer".
|
873
890
|
* @param layer - The layer being drawn
|
874
891
|
* @typeParam L - the type of the CanvasLayer
|
@@ -876,7 +893,7 @@ declare global {
|
|
876
893
|
type DrawLayer<L extends CanvasLayer = CanvasLayer> = (layer: L) => void;
|
877
894
|
|
878
895
|
/**
|
879
|
-
* A hook event that fires when a {@link CanvasLayer} is deconstructed.
|
896
|
+
* A hook event that fires when a {@link CanvasLayer | `CanvasLayer`} is deconstructed.
|
880
897
|
* The dispatched event name replaces "Layer" with the named CanvasLayer subclass, i.e. "tearDownTokensLayer".
|
881
898
|
* @param layer - The layer being deconstructed
|
882
899
|
* @typeParam L - the type of the CanvasLayer
|
@@ -892,8 +909,8 @@ declare global {
|
|
892
909
|
* @typeParam P - the type of the PlaceableObject
|
893
910
|
* @remarks The name for this hook is dynamically created by joining "paste" with the type name of the
|
894
911
|
* PlaceableObject.
|
895
|
-
* @remarks This is called by {@link Hooks.call}.
|
896
|
-
* @see {@link PlaceablesLayer#pasteObjects}
|
912
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
913
|
+
* @see {@link PlaceablesLayer.pasteObjects | `PlaceablesLayer#pasteObjects`}
|
897
914
|
*/
|
898
915
|
type PastePlaceableObject<P extends PlaceableObject = PlaceableObject> = (
|
899
916
|
copied: P[],
|
@@ -904,29 +921,29 @@ declare global {
|
|
904
921
|
/** PlaceableObject */
|
905
922
|
|
906
923
|
/**
|
907
|
-
* A hook event that fires when a {@link PlaceableObject} is initially drawn.
|
924
|
+
* A hook event that fires when a {@link PlaceableObject | `PlaceableObject`} is initially drawn.
|
908
925
|
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "drawToken".
|
909
926
|
* @param object - The object instance being drawn
|
910
927
|
* @typeParam P - the type of the PlaceableObject
|
911
|
-
* @remarks This is called by {@link Hooks.callAll}
|
928
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}
|
912
929
|
*/
|
913
930
|
type DrawObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
914
931
|
|
915
932
|
/**
|
916
|
-
* A hook event that fires when a {@link PlaceableObject} is incrementally refreshed.
|
933
|
+
* A hook event that fires when a {@link PlaceableObject | `PlaceableObject`} is incrementally refreshed.
|
917
934
|
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "refreshToken".
|
918
935
|
* @param object - The object instance being refreshed
|
919
936
|
* @typeParam P - the type of the PlaceableObject
|
920
|
-
* @remarks This is called by {@link Hooks.callAll}
|
937
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}
|
921
938
|
*/
|
922
939
|
type RefreshObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
923
940
|
|
924
941
|
/**
|
925
|
-
* A hook event that fires when a {@link PlaceableObject} is destroyed.
|
942
|
+
* A hook event that fires when a {@link PlaceableObject | `PlaceableObject`} is destroyed.
|
926
943
|
* The dispatched event name replaces "Object" with the named PlaceableObject subclass, i.e. "destroyToken".
|
927
944
|
* @param object - The object instance being destroyed
|
928
945
|
* @typeParam P - the type of the PlaceableObject
|
929
|
-
* @remarks This is called by {@link Hooks.callAll}
|
946
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}
|
930
947
|
*/
|
931
948
|
type DestroyObject<P extends PlaceableObject = PlaceableObject> = (object: P) => void;
|
932
949
|
|
@@ -939,9 +956,9 @@ declare global {
|
|
939
956
|
* @typeParam P - the type of the PlaceableObject
|
940
957
|
* @remarks The name for this hook is dynamically created by joining "control" and the type name of the
|
941
958
|
* PlaceableObject.
|
942
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
943
|
-
* @see {@link PlaceableObject#control}
|
944
|
-
* @see {@link PlaceableObject#release}
|
959
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
960
|
+
* @see {@link PlaceableObject.control | `PlaceableObject#control`}
|
961
|
+
* @see {@link PlaceableObject.release | `PlaceableObject#release`}
|
945
962
|
*/
|
946
963
|
type ControlObject<P extends PlaceableObject = PlaceableObject> = (object: P, controlled: boolean) => void;
|
947
964
|
|
@@ -953,9 +970,9 @@ declare global {
|
|
953
970
|
* @param hover - Whether the PlaceableObject is hovered over or not
|
954
971
|
* @typeParam P - the type of the PlaceableObject
|
955
972
|
* @remarks The name for this hook is dynamically created by joining "hover" and the type name of the PlaceableObject.
|
956
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
957
|
-
* @see {@link PlaceableObject#_onHoverIn}
|
958
|
-
* @see {@link PlaceableObject#_onHoverOut}
|
973
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
974
|
+
* @see {@link PlaceableObject._onHoverIn | `PlaceableObject#_onHoverIn`}
|
975
|
+
* @see {@link PlaceableObject._onHoverOut | `PlaceableObject#_onHoverOut`}
|
959
976
|
*/
|
960
977
|
type HoverObject<P extends PlaceableObject = PlaceableObject> = (object: P, hover: boolean) => void;
|
961
978
|
|
@@ -976,14 +993,14 @@ declare global {
|
|
976
993
|
* @typeParam D - the type of the Document constructor
|
977
994
|
* @returns Explicitly return false to prevent creation of this Document
|
978
995
|
* @remarks The name for this hook is dynamically created by joining "preCreate" with the name of the Document.
|
979
|
-
* @remarks This is called by {@link Hooks.call}.
|
980
|
-
* @see {@link ClientDatabaseBackend#_preCreateDocumentArray}
|
981
|
-
* @see {@link TokenDocument#_preUpdateTokenActor}
|
996
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
997
|
+
* @see {@link ClientDatabaseBackend._preCreateDocumentArray | `ClientDatabaseBackend#_preCreateDocumentArray`}
|
998
|
+
* @see {@link TokenDocument._preUpdateTokenActor | `TokenDocument#_preUpdateTokenActor`}
|
982
999
|
*/
|
983
1000
|
type PreCreateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
984
1001
|
document: Document.ToConfiguredInstance<D>,
|
985
1002
|
data: ConstructorParameters<D>[0],
|
986
|
-
options: Document.PreCreateOptions<
|
1003
|
+
options: Document.Database.PreCreateOptions<DatabaseCreateOperation>,
|
987
1004
|
userId: string,
|
988
1005
|
) => boolean | void;
|
989
1006
|
|
@@ -1002,14 +1019,16 @@ declare global {
|
|
1002
1019
|
* @typeParam D - the type of the Document constructor
|
1003
1020
|
* @returns Explicitly return false to prevent update of this Document
|
1004
1021
|
* @remarks The name for this hook is dynamically created by joining "preUpdate" with the type name of the Document.
|
1005
|
-
* @remarks This is called {@link Hooks.call}.
|
1006
|
-
* @see {@link ClientDatabaseBackend#_preUpdateDocumentArray}
|
1007
|
-
* @see {@link TokenDocument#_preUpdateTokenActor}
|
1022
|
+
* @remarks This is called {@link Hooks.call | `Hooks.call`}.
|
1023
|
+
* @see {@link ClientDatabaseBackend._preUpdateDocumentArray | `ClientDatabaseBackend#_preUpdateDocumentArray`}
|
1024
|
+
* @see {@link TokenDocument._preUpdateTokenActor | `TokenDocument#_preUpdateTokenActor`}
|
1008
1025
|
*/
|
1009
1026
|
type PreUpdateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1010
1027
|
document: Document.ToConfiguredInstance<D>,
|
1011
|
-
changed: DeepPartial<
|
1012
|
-
|
1028
|
+
changed: DeepPartial<
|
1029
|
+
D extends abstract new (arg0: infer Data extends object, ...args: infer _1) => unknown ? Data : never
|
1030
|
+
>,
|
1031
|
+
options: Document.Database.PreUpdateOptions<DatabaseUpdateOperation>,
|
1013
1032
|
userId: string,
|
1014
1033
|
) => boolean | void;
|
1015
1034
|
|
@@ -1027,13 +1046,13 @@ declare global {
|
|
1027
1046
|
* @typeParam D - the type of the Document constructor
|
1028
1047
|
* @returns Explicitly return false to prevent deletion of this Document
|
1029
1048
|
* @remarks The name for this hook is dynamically created by joining "preDelete" with the type name of the Document.
|
1030
|
-
* @remarks This is called by {@link Hooks.call}.
|
1031
|
-
* @see {@link ClientDatabaseBackend#_preDeleteDocumentArray}.
|
1032
|
-
* @see {@link TokenDocument#_preUpdateTokenActor}
|
1049
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
1050
|
+
* @see {@link ClientDatabaseBackend._preDeleteDocumentArray | `ClientDatabaseBackend#_preDeleteDocumentArray`}.
|
1051
|
+
* @see {@link TokenDocument._preUpdateTokenActor | `TokenDocument#_preUpdateTokenActor`}
|
1033
1052
|
*/
|
1034
1053
|
type PreDeleteDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1035
1054
|
document: Document.ToConfiguredInstance<D>,
|
1036
|
-
options: Document.
|
1055
|
+
options: Document.Database.PreDeleteOperationInstance<DatabaseDeleteOperation>,
|
1037
1056
|
userId: string,
|
1038
1057
|
) => boolean | void;
|
1039
1058
|
|
@@ -1047,13 +1066,13 @@ declare global {
|
|
1047
1066
|
* @param userId - The ID of the User who triggered the creation workflow
|
1048
1067
|
* @typeParam D - the type of the Document constructor
|
1049
1068
|
* @remarks The name for this hook is dynamically created by joining "create" and the type name of the Document.
|
1050
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1051
|
-
* @see {@link ClientDatabaseBackend#_postCreateDocumentCallbacks}
|
1052
|
-
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1069
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1070
|
+
* @see {@link ClientDatabaseBackend._postCreateDocumentCallbacks | `ClientDatabaseBackend#_postCreateDocumentCallbacks`}
|
1071
|
+
* @see {@link TokenDocument._onUpdateTokenActor | `TokenDocument#_onUpdateTokenActor`}
|
1053
1072
|
*/
|
1054
1073
|
type CreateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1055
1074
|
document: Document.ToConfiguredInstance<D>,
|
1056
|
-
options: Document.
|
1075
|
+
options: Document.Database.CreateOptions<DatabaseCreateOperation>,
|
1057
1076
|
userId: string,
|
1058
1077
|
) => void;
|
1059
1078
|
|
@@ -1068,14 +1087,16 @@ declare global {
|
|
1068
1087
|
* @param userId - The ID of the User who triggered the update workflow
|
1069
1088
|
* @typeParam D - the type of the Document constructor
|
1070
1089
|
* @remarks The name for this hook is dynamically created by joining "update" with the type name of the Document.
|
1071
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1072
|
-
* @see {@link ClientDatabaseBackend#_postUpdateDocumentCallbacks}
|
1073
|
-
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1090
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1091
|
+
* @see {@link ClientDatabaseBackend._postUpdateDocumentCallbacks | `ClientDatabaseBackend#_postUpdateDocumentCallbacks`}
|
1092
|
+
* @see {@link TokenDocument._onUpdateTokenActor | `TokenDocument#_onUpdateTokenActor`}
|
1074
1093
|
*/
|
1075
1094
|
type UpdateDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1076
1095
|
document: Document.ToConfiguredInstance<D>,
|
1077
|
-
change: DeepPartial<
|
1078
|
-
|
1096
|
+
change: DeepPartial<
|
1097
|
+
D extends abstract new (arg0: infer Data extends object, ...args: infer _1) => unknown ? Data : never
|
1098
|
+
>,
|
1099
|
+
options: Document.Database.UpdateOptions<DatabaseUpdateOperation>,
|
1079
1100
|
userId: string,
|
1080
1101
|
) => void;
|
1081
1102
|
|
@@ -1089,13 +1110,13 @@ declare global {
|
|
1089
1110
|
* @param userId - The ID of the User who triggered the deletion workflow
|
1090
1111
|
* @typeParam D - the type of the Document constructor
|
1091
1112
|
* @remarks The name for this hook is dynamically created by joining "delete" with the type name of the Document.
|
1092
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1093
|
-
* @see {@link ClientDatabaseBackend#_postDeleteDocumentCallbacks}
|
1094
|
-
* @see {@link TokenDocument#_onUpdateTokenActor}
|
1113
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1114
|
+
* @see {@link ClientDatabaseBackend._postDeleteDocumentCallbacks | `ClientDatabaseBackend#_postDeleteDocumentCallbacks`}
|
1115
|
+
* @see {@link TokenDocument._onUpdateTokenActor | `TokenDocument#_onUpdateTokenActor`}
|
1095
1116
|
*/
|
1096
1117
|
type DeleteDocument<D extends Document.AnyConstructor = Document.AnyConstructor> = (
|
1097
1118
|
document: Document.ToConfiguredInstance<D>,
|
1098
|
-
options: Document.
|
1119
|
+
options: Document.Database.DeleteOptions<DatabaseDeleteOperation>,
|
1099
1120
|
userId: string,
|
1100
1121
|
) => void;
|
1101
1122
|
|
@@ -1106,7 +1127,7 @@ declare global {
|
|
1106
1127
|
* @param source - The RenderedEffectSource instance being initialized
|
1107
1128
|
* @typeParam RPS - the type of the RenderedPointSource
|
1108
1129
|
* @remarks The name for this hook is dynamically created by wrapping the type name of the shader in `initialize` and `Shaders`.
|
1109
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1130
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1110
1131
|
*/
|
1111
1132
|
type InitializeRenderedEffectSourceShaders<RPS extends RenderedEffectSource.Any = RenderedEffectSource.Any> = (
|
1112
1133
|
source: RPS,
|
@@ -1115,18 +1136,18 @@ declare global {
|
|
1115
1136
|
/** InteractionLayer */
|
1116
1137
|
|
1117
1138
|
/**
|
1118
|
-
* A hook event that fires with a {@link InteractionLayer} becomes active.
|
1139
|
+
* A hook event that fires with a {@link InteractionLayer | `InteractionLayer`} becomes active.
|
1119
1140
|
* The dispatched event name replaces "Layer" with the named InteractionLayer subclass, i.e. "activateTokensLayer".
|
1120
1141
|
* @param layer - The layer becoming active
|
1121
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1142
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1122
1143
|
*/
|
1123
1144
|
type ActivateLayer<L extends InteractionLayer = InteractionLayer> = (layer: L) => void;
|
1124
1145
|
|
1125
1146
|
/**
|
1126
|
-
* A hook event that fires with a {@link InteractionLayer} becomes inactive.
|
1147
|
+
* A hook event that fires with a {@link InteractionLayer | `InteractionLayer`} becomes inactive.
|
1127
1148
|
* The dispatched event name replaces "Layer" with the named InteractionLayer subclass, i.e. "deactivateTokensLayer".
|
1128
1149
|
* @param layer - The layer becoming inactive
|
1129
|
-
* @remarks This is called by {@link Hooks.callAll}.
|
1150
|
+
* @remarks This is called by {@link Hooks.callAll | `Hooks.callAll`}.
|
1130
1151
|
*/
|
1131
1152
|
type DeactivateLayer<L extends InteractionLayer = InteractionLayer> = (layer: L) => void;
|
1132
1153
|
|
@@ -1136,10 +1157,10 @@ declare global {
|
|
1136
1157
|
* "getActorDirectoryEntryContext".
|
1137
1158
|
* @param html - The HTML element to which the context options are attached
|
1138
1159
|
* @param entryOptions - The context menu entries
|
1139
|
-
* @remarks This is called by {@link Hooks.call}.
|
1140
|
-
* @see {@link ContextMenu.create}
|
1160
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
1161
|
+
* @see {@link ContextMenu.create | `ContextMenu.create`}
|
1141
1162
|
*/
|
1142
|
-
type GetEntryContext = (html: JQuery, entryOptions:
|
1163
|
+
type GetEntryContext = (html: JQuery, entryOptions: ContextMenu.Entry[]) => boolean | void;
|
1143
1164
|
|
1144
1165
|
/**
|
1145
1166
|
* A hook event that fires when the context menu for a Sound in the PlaylistDirectory is constructed.
|
@@ -1147,10 +1168,10 @@ declare global {
|
|
1147
1168
|
* @param entryOptions - The context menu entries
|
1148
1169
|
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the PlaylistDirectory
|
1149
1170
|
* and "SoundContext".
|
1150
|
-
* @remarks This is called by {@link Hooks.call}.
|
1151
|
-
* @see {@link PlaylistDirectory#_contextMenu}
|
1171
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
1172
|
+
* @see {@link PlaylistDirectory._contextMenu | `PlaylistDirectory#_contextMenu`}
|
1152
1173
|
*/
|
1153
|
-
type GetPlaylistDirectorySoundContext = (html: JQuery, entryOptions:
|
1174
|
+
type GetPlaylistDirectorySoundContext = (html: JQuery, entryOptions: ContextMenu.Entry[]) => boolean | void;
|
1154
1175
|
|
1155
1176
|
/**
|
1156
1177
|
* A hook event that fires when the context menu for folders in a SidebarTab
|
@@ -1160,10 +1181,10 @@ declare global {
|
|
1160
1181
|
* @param entryOptions - The context menu entries
|
1161
1182
|
* @remarks The name for this hook is dynamically created by joining "get" with the type name of the SidebarDirectory
|
1162
1183
|
* and "FolderContext".
|
1163
|
-
* @remarks This is called by {@link Hooks.call}.
|
1164
|
-
* @see {@link SidebarDirectory#_contextMenu}
|
1184
|
+
* @remarks This is called by {@link Hooks.call | `Hooks.call`}.
|
1185
|
+
* @see {@link SidebarDirectory._contextMenu | `SidebarDirectory#_contextMenu`}
|
1165
1186
|
*/
|
1166
|
-
type GetSidebarDirectoryFolderContext = (html: JQuery, entryOptions:
|
1187
|
+
type GetSidebarDirectoryFolderContext = (html: JQuery, entryOptions: ContextMenu.Entry[]) => boolean | void;
|
1167
1188
|
|
1168
1189
|
type DynamicCallbacks =
|
1169
1190
|
| RenderApplication
|
@@ -1189,8 +1210,7 @@ declare global {
|
|
1189
1210
|
| DeactivateLayer
|
1190
1211
|
| GetEntryContext
|
1191
1212
|
| GetPlaylistDirectorySoundContext
|
1192
|
-
| GetSidebarDirectoryFolderContext
|
1193
|
-
| HoverObject;
|
1213
|
+
| GetSidebarDirectoryFolderContext;
|
1194
1214
|
|
1195
1215
|
interface ErrorCallbackParameters {
|
1196
1216
|
"Canvas#draw": [location: "Canvas#draw", err: Error, data: { layer: CanvasLayer }];
|