Skip to content

Commit a525e43

Browse files
committed
Add TextConfig type for TextCreator
1 parent 42d6456 commit a525e43

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

src/gameobjects/text/static/TextCreator.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ var Text = require('./Text');
1717
* @method Phaser.GameObjects.GameObjectCreator#text
1818
* @since 3.0.0
1919
*
20-
* @param {object} config - The configuration object this Game Object will use to create itself.
20+
* @param {Phaser.Types.GameObjects.Text.TextConfig} config - The configuration object this Game Object will use to create itself.
2121
* @param {boolean} [addToScene] - Add this Game Object to the Scene after creating it? If set this argument overrides the `add` property in the config object.
2222
*
2323
* @return {Phaser.GameObjects.Text} The Game Object that was created.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/**
2+
* @typedef {object} Phaser.Types.GameObjects.Text.TextConfig
3+
* @extends Phaser.Types.GameObjects.GameObjectConfig
4+
* @since 3.0.0
5+
*
6+
* @property {(string|string[])} [text] - The text this Text object will display.
7+
* @property {Phaser.Types.GameObjects.Text.TextStyle} [style] - The Text style configuration object.
8+
* @property {Phaser.Types.GameObjects.Text.TextPadding} [padding] - A Text Padding object.
9+
*/

0 commit comments

Comments
 (0)