Skip to content

Commit

Permalink
Merge branch 'dev' into allow-texture-as-view-options
Browse files Browse the repository at this point in the history
  • Loading branch information
CyberDex committed Nov 27, 2024
2 parents b5ca7c2 + 8aa92f7 commit 8782cf1
Show file tree
Hide file tree
Showing 8 changed files with 40 additions and 10 deletions.
5 changes: 4 additions & 1 deletion src/Input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,10 @@ export class Input extends Container {
this.options.TextClass = options.TextClass ?? Text;
const textStyle = { ...defaultTextStyle, ...options.textStyle };

this.inputField = new this.options.TextClass({ text: '', style: textStyle });
this.inputField = new this.options.TextClass({
text: '',
style: textStyle,
});

this._cursor = new Sprite(Texture.WHITE);

Expand Down
5 changes: 4 additions & 1 deletion src/stories/fancyButton/FancyButtonBitmapText.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,10 @@ export const UsingSpriteAndBitmapText: StoryFn<typeof args> = (
padding,
textOffset: { x: textOffsetX, y: textOffsetY },
defaultTextScale,
defaultTextAnchor: { x: defaultTextAnchorX, y: defaultTextAnchorY },
defaultTextAnchor: {
x: defaultTextAnchorX,
y: defaultTextAnchorY,
},
animations: {
hover: {
props: {
Expand Down
5 changes: 4 additions & 1 deletion src/stories/fancyButton/FancyButtonDynamicUpdate.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,10 @@ export const DynamicUpdate: StoryFn<typeof args> = (
const texts: string[] = ['🤙', '👌', '👍', '👏', '👋', '🤟', '🤘', '🤞'];
const text = randomItem(texts.filter((text) => text !== button.text)) as string;

button.textView = new Text({ text, style: { fontSize: 70 } });
button.textView = new Text({
text,
style: { fontSize: 70 },
});

icon = randomItem(avatars.filter((avatar) => avatar !== icon)) as string;

Expand Down
10 changes: 8 additions & 2 deletions src/stories/fancyButton/FancyButtonGraphics.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,14 @@ export const UseGraphics: StoryFn<typeof args> = (
},
defaultTextScale,
defaultIconScale,
defaultTextAnchor: { x: defaultTextAnchorX, y: defaultTextAnchorY },
defaultIconAnchor: { x: defaultIconAnchorX, y: defaultIconAnchorY },
defaultTextAnchor: {
x: defaultTextAnchorX,
y: defaultTextAnchorY,
},
defaultIconAnchor: {
x: defaultIconAnchorX,
y: defaultIconAnchorY,
},
animations: {
default: {
props: {
Expand Down
5 changes: 4 additions & 1 deletion src/stories/fancyButton/FancyButtonHTMLText.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,10 @@ export const UsingSpriteAndHTMLText: StoryFn<typeof args> = (
padding,
textOffset: { x: textOffsetX, y: textOffsetY },
defaultTextScale,
defaultTextAnchor: { x: defaultTextAnchorX, y: defaultTextAnchorY },
defaultTextAnchor: {
x: defaultTextAnchorX,
y: defaultTextAnchorY,
},
animations: {
hover: {
props: {
Expand Down
5 changes: 4 additions & 1 deletion src/stories/fancyButton/FancyButtonIcon.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,10 @@ export const UseIcon: StoryFn<typeof args> = (
y: iconOffsetY,
},
defaultIconScale,
defaultIconAnchor: { x: defaultIconAnchorX, y: defaultIconAnchorY },
defaultIconAnchor: {
x: defaultIconAnchorX,
y: defaultIconAnchorY,
},
animations: {
hover: {
props: {
Expand Down
10 changes: 8 additions & 2 deletions src/stories/fancyButton/FancyButtonNineSliceSprite.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,14 @@ export const UseNineSliceSprite: StoryFn<typeof args> = (
iconOffset: { x: -100, y: -7 },
defaultTextScale,
defaultIconScale,
defaultTextAnchor: { x: defaultTextAnchorX, y: defaultTextAnchorY },
defaultIconAnchor: { x: defaultIconAnchorX, y: defaultIconAnchorY },
defaultTextAnchor: {
x: defaultTextAnchorX,
y: defaultTextAnchorY,
},
defaultIconAnchor: {
x: defaultIconAnchorX,
y: defaultIconAnchorY,
},
animations: {
hover: {
props: {
Expand Down
5 changes: 4 additions & 1 deletion src/stories/fancyButton/FancyButtonSprite.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ export const UseSprite: StoryFn<typeof args> = (
padding,
textOffset: { x: textOffsetX, y: textOffsetY },
defaultTextScale,
defaultTextAnchor: { x: defaultTextAnchorX, y: defaultTextAnchorY },
defaultTextAnchor: {
x: defaultTextAnchorX,
y: defaultTextAnchorY,
},
animations: {
hover: {
props: {
Expand Down

0 comments on commit 8782cf1

Please sign in to comment.