@@ -78,8 +78,9 @@ export class SpeedDialItemButton extends Button {
7878 constructor ( ) {
7979 super ( ) ;
8080 this . verticalAlignment = 'middle' ;
81- this . style [ 'css:font-size' ] = 26 ;
81+ this . style [ 'css:font-size' ] = 24 ;
8282 this . style [ 'css:elevation' ] = 6 ;
83+ this . style [ 'css:padding' ] = 2 ;
8384 // this.style['css:dynamic-elevation-offset'] = 6;
8485 }
8586 getDefaultElevation ( ) : number {
@@ -127,6 +128,10 @@ export class SpeedDialItem extends SpeedDialItemBase {
127128 this . addChild ( this . titleView ) ;
128129 this . addChild ( this . button ) ;
129130 }
131+ updateAlignment ( ) {
132+ ( this as any ) . columns = this . fabColumns ;
133+ this . button . col = this . fabButtonCol ;
134+ }
130135 initNativeView ( ) {
131136 super . initNativeView ( ) ;
132137 this . titleView . on ( 'tap' , this . onButtonTap , this ) ;
@@ -226,12 +231,10 @@ export class SpeedDialItem extends SpeedDialItemBase {
226231
227232 //@ts -ignore
228233 get backgroundImage ( ) {
229- return this . button && this . button . backgroundImage ;
234+ return this . button . backgroundImage ;
230235 }
231236 set backgroundImage ( value : string | LinearGradient ) {
232- if ( this . button ) {
233- this . button . backgroundImage = value ;
234- }
237+ this . button . backgroundImage = value ;
235238 }
236239 //@ts -ignore
237240 get color ( ) {
@@ -266,7 +269,6 @@ export class SpeedDial extends SpeedDialItemBase {
266269 private _fabsHolder : FlexboxLayout ;
267270 rows : string ;
268271 columns : string ;
269- rPosition = 'left' ;
270272 orientation = 'vertical' ;
271273 isActive = false ;
272274 actualActive = false ;
@@ -281,7 +283,7 @@ export class SpeedDial extends SpeedDialItemBase {
281283 this . style [ 'css:padding-right' ] = 8 ;
282284 this . _fabsHolder = new FlexboxLayout ( ) ;
283285 this . _fabsHolder . row = 2 ;
284- this . _fabsHolder . horizontalAlignment = this . rPosition as HorizontalAlignment ;
286+ this . _fabsHolder . horizontalAlignment = this . horizontalAlignment ;
285287 this . isPassThroughParentEnabled = true ;
286288 if ( global . isIOS ) {
287289 this . _fabsHolder . isPassThroughParentEnabled = true ;
@@ -358,10 +360,10 @@ export class SpeedDial extends SpeedDialItemBase {
358360 // }
359361 // }
360362 get isLeft ( ) {
361- return this . rPosition === 'left' ;
363+ return this . horizontalAlignment === 'left' ;
362364 }
363365 get isRight ( ) {
364- return this . rPosition === 'right' ;
366+ return this . horizontalAlignment === 'right' ;
365367 }
366368 onButtonTap ( args ) {
367369 this . active = ! this . active ;
@@ -517,6 +519,7 @@ export class SpeedDial extends SpeedDialItemBase {
517519 }
518520 set icon ( value : string | ImageSource ) {
519521 this . _fabMainButton . icon = value ;
522+ this . _fabMainButton . padding = 0 ;
520523 }
521524 get buttonClass ( ) {
522525 return this . _fabMainButton . buttonClass ;
@@ -556,6 +559,13 @@ export class SpeedDial extends SpeedDialItemBase {
556559 }
557560 set horizontalAlignment ( value ) {
558561 this . _fabsHolder . horizontalAlignment = value ;
562+ this . _fabMainButton . updateAlignment ( ) ;
563+ this . _fabsHolder . eachChild ( ( c ) => {
564+ if ( c instanceof SpeedDialItem ) {
565+ c . updateAlignment ( ) ;
566+ }
567+ return true ;
568+ } ) ;
559569 }
560570 //@ts -ignore
561571 // get backgroundColor() {
0 commit comments