mirror of
https://github.com/photonstorm/phaser
synced 2024-11-17 18:28:57 +00:00
JSDoc changes to help TypeScript not get its knickers in a twist
This commit is contained in:
parent
27cbd688b8
commit
725e1d7ef7
8 changed files with 19 additions and 21 deletions
|
@ -22,10 +22,6 @@ var CONST = {
|
|||
*/
|
||||
VERSION: '3.17.0',
|
||||
|
||||
BlendModes: require('./renderer/BlendModes'),
|
||||
|
||||
ScaleModes: require('./renderer/ScaleModes'),
|
||||
|
||||
/**
|
||||
* AUTO Detect Renderer.
|
||||
*
|
||||
|
|
|
@ -13,17 +13,11 @@ var Extend = require('./utils/object/Extend');
|
|||
* @namespace Phaser
|
||||
*/
|
||||
|
||||
/**
|
||||
* The root types namespace.
|
||||
*
|
||||
* @namespace Phaser.Types
|
||||
* @since 3.17.0
|
||||
*/
|
||||
|
||||
var Phaser = {
|
||||
|
||||
Actions: require('./actions'),
|
||||
Animations: require('./animations'),
|
||||
BlendModes: require('./renderer/BlendModes'),
|
||||
Cache: require('./cache'),
|
||||
Cameras: require('./cameras'),
|
||||
Core: require('./core'),
|
||||
|
@ -44,6 +38,7 @@ var Phaser = {
|
|||
Plugins: require('./plugins'),
|
||||
Renderer: require('./renderer'),
|
||||
Scale: require('./scale'),
|
||||
ScaleModes: require('./renderer/ScaleModes'),
|
||||
Scene: require('./scene/Scene'),
|
||||
Scenes: require('./scene'),
|
||||
Structs: require('./structs'),
|
||||
|
@ -79,6 +74,13 @@ if (typeof PLUGIN_FBINSTANT)
|
|||
|
||||
Phaser = Extend(false, Phaser, CONST);
|
||||
|
||||
/**
|
||||
* The root types namespace.
|
||||
*
|
||||
* @namespace Phaser.Types
|
||||
* @since 3.17.0
|
||||
*/
|
||||
|
||||
// Export it
|
||||
|
||||
module.exports = Phaser;
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
* Phaser Blend Modes.
|
||||
*
|
||||
* @namespace Phaser.BlendModes
|
||||
* @memberof Phaser
|
||||
* @since 3.0.0
|
||||
*/
|
||||
|
||||
|
|
|
@ -8,18 +8,17 @@
|
|||
* Phaser Scale Modes.
|
||||
*
|
||||
* @namespace Phaser.ScaleModes
|
||||
* @memberof Phaser
|
||||
* @since 3.0.0
|
||||
*/
|
||||
|
||||
module.exports = {
|
||||
var ScaleModes = {
|
||||
|
||||
/**
|
||||
* Default Scale Mode (Linear).
|
||||
*
|
||||
* @name Phaser.ScaleModes.DEFAULT
|
||||
* @type {integer}
|
||||
* @const
|
||||
* @readonly
|
||||
* @since 3.0.0
|
||||
*/
|
||||
DEFAULT: 0,
|
||||
|
@ -29,7 +28,7 @@ module.exports = {
|
|||
*
|
||||
* @name Phaser.ScaleModes.LINEAR
|
||||
* @type {integer}
|
||||
* @const
|
||||
* @readonly
|
||||
* @since 3.0.0
|
||||
*/
|
||||
LINEAR: 0,
|
||||
|
@ -39,9 +38,11 @@ module.exports = {
|
|||
*
|
||||
* @name Phaser.ScaleModes.NEAREST
|
||||
* @type {integer}
|
||||
* @const
|
||||
* @readonly
|
||||
* @since 3.0.0
|
||||
*/
|
||||
NEAREST: 1
|
||||
|
||||
};
|
||||
|
||||
module.exports = ScaleModes;
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
*
|
||||
* To find out what each mode does please see [Phaser.Scale.Center]{@link Phaser.Scale.Center}.
|
||||
*
|
||||
* @typedef {(Phaser.Scale.Center.NO_CENTER|Phaser.Scale.Center.CENTER_BOTH|Phaser.Scale.Center.CENTER_HORIZONTALLY|Phaser.Scale.Center.CENTER_VERTICALLY)} Phaser.Scale.CenterType
|
||||
* @typedef {Phaser.Scale.Center} Phaser.Scale.CenterType
|
||||
* @memberof Phaser.Scale
|
||||
* @since 3.16.0
|
||||
*/
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
*
|
||||
* To find out what each mode does please see [Phaser.Scale.Orientation]{@link Phaser.Scale.Orientation}.
|
||||
*
|
||||
* @typedef {(Phaser.Scale.Orientation.LANDSCAPE|Phaser.Scale.Orientation.PORTRAIT)} Phaser.Scale.OrientationType
|
||||
* @typedef {Phaser.Scale.Orientation} Phaser.Scale.OrientationType
|
||||
* @memberof Phaser.Scale
|
||||
* @since 3.16.0
|
||||
*/
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
*
|
||||
* To find out what each mode does please see [Phaser.Scale.ScaleModes]{@link Phaser.Scale.ScaleModes}.
|
||||
*
|
||||
* @typedef {(Phaser.Scale.ScaleModes.NONE|Phaser.Scale.ScaleModes.WIDTH_CONTROLS_HEIGHT|Phaser.Scale.ScaleModes.HEIGHT_CONTROLS_WIDTH|Phaser.Scale.ScaleModes.FIT|Phaser.Scale.ScaleModes.ENVELOP|Phaser.Scale.ScaleModes.RESIZE)} Phaser.Scale.ScaleModeType
|
||||
* @typedef {Phaser.Scale.ScaleModes} Phaser.Scale.ScaleModeType
|
||||
* @memberof Phaser.Scale
|
||||
* @since 3.16.0
|
||||
*/
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
*
|
||||
* To find out what each mode does please see [Phaser.Scale.Zoom]{@link Phaser.Scale.Zoom}.
|
||||
*
|
||||
* @typedef {(Phaser.Scale.Zoom.NO_ZOOM|Phaser.Scale.Zoom.ZOOM_2X|Phaser.Scale.Zoom.ZOOM_4X|Phaser.Scale.Zoom.MAX_ZOOM)} Phaser.Scale.ZoomType
|
||||
* @typedef {Phaser.Scale.Zoom} Phaser.Scale.ZoomType
|
||||
* @memberof Phaser.Scale
|
||||
* @since 3.16.0
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue