Skip to content

Commit d137493

Browse files
committed
chore: properties typings
1 parent e0ccc86 commit d137493

File tree

3 files changed

+51
-2
lines changed

3 files changed

+51
-2
lines changed

src/button/button-common.ts

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,42 @@ import { VerticalTextAlignment } from '@nativescript-community/text';
55
@CSSType('MDButton')
66
export abstract class ButtonBase extends Button {
77
public variant = 'contained';
8+
9+
/**
10+
* Gets or sets the elevation of the button.
11+
*/
812
@cssProperty elevation: number;
13+
14+
/**
15+
* Gets or sets the dynamic elevation offset of the button.
16+
*/
917
@cssProperty dynamicElevationOffset: number;
10-
@cssProperty rippleColor: Color;
18+
19+
/**
20+
* Gets or sets the ripple-color of the button.
21+
*/
22+
@cssProperty rippleColor: Color | string;
23+
24+
/**
25+
* Gets or sets the {@link VerticalTextAlignment|vertical text alignment} of the button.
26+
*/
1127
@cssProperty verticalTextAlignment: VerticalTextAlignment;
28+
29+
/**
30+
* Gets or sets the shape of the button.
31+
*/
1232
@cssProperty shape: string;
1333

34+
/**
35+
* Gets or sets the icon imageSource of the button.
36+
*/
1437
public imageSource: ImageSource;
38+
39+
/**
40+
* Gets or sets the icon src of the button.
41+
*/
1542
public src: string | ImageSource;
43+
1644
public isLoading: boolean;
1745
/**
1846
* @internal //copied from image common

src/button/button.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
* @module @nativescript-community/ui-material-button
44
*/
55

6-
import { ButtonBase } from './button-common';
6+
import { ButtonBase } from './button-common';
77

88
export class Button extends ButtonBase {}

src/core/index.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,27 @@ declare module '@nativescript/core/ui/core/view' {
1010
_getRootFragmentManager(): androidx.fragment.app.FragmentManager;
1111
clearFocus(): void;
1212
requestFocus(): void;
13+
14+
/**
15+
* @nativescript-community/ui-material-core {@link installMixins}.
16+
*
17+
* Gets or sets the elevation of the view.
18+
*/
19+
elevation: number;
20+
21+
/**
22+
* @nativescript-community/ui-material-core {@link installMixins}.
23+
*
24+
* Gets or sets the dynamic elevation offset of the view.
25+
*/
26+
dynamicElevationOffset: number;
27+
28+
/**
29+
* @nativescript-community/ui-material-core {@link installMixins}.
30+
*
31+
* Gets or sets the ripple-color of the view.
32+
*/
33+
rippleColor: Color | string;
1334
}
1435
}
1536

0 commit comments

Comments
 (0)