Skip to content
This repository was archived by the owner on Jan 6, 2025. It is now read-only.

Commit 771f2c9

Browse files
joshwienskara
authored andcommitted
fix(flexbox): add default display property to getDisplayStyle() (#301)
1 parent 0131103 commit 771f2c9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/flexbox/api/base.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export abstract class BaseFxDirective implements OnDestroy, OnChanges {
118118
protected _getDisplayStyle(source?: HTMLElement): string {
119119
let element: HTMLElement = source || this._elementRef.nativeElement;
120120
let value = (element.style as any)['display'] || getComputedStyle(element)['display'];
121-
return value.trim();
121+
return value ? value.trim() : 'block';
122122
}
123123

124124
protected _getFlowDirection(target: any, addIfMissing = false): string {

0 commit comments

Comments
 (0)