1
1
import { VerticalTextAlignment , verticalTextAlignmentProperty } from '@nativescript-community/text' ;
2
2
import { themer } from '@nativescript-community/ui-material-core' ;
3
- import { getColorStateList , getFullColorStateList , getHorizontalGravity , getLayout , getVerticalGravity , inflateLayout } from '@nativescript-community/ui-material-core/android/utils' ;
3
+ import { getColorStateList , getFullColorStateList , getHorizontalGravity , getVerticalGravity , inflateLayout } from '@nativescript-community/ui-material-core/android/utils' ;
4
4
import {
5
5
counterMaxLengthProperty ,
6
6
errorColorProperty ,
@@ -19,21 +19,19 @@ import {
19
19
Color ,
20
20
CoreTypes ,
21
21
Font ,
22
- Length ,
23
22
Utils ,
24
23
backgroundInternalProperty ,
25
24
borderBottomLeftRadiusProperty ,
26
25
fontInternalProperty ,
27
26
hintProperty ,
28
- paddingBottomProperty ,
29
- paddingLeftProperty ,
30
- paddingRightProperty ,
31
- paddingTopProperty ,
32
27
placeholderColorProperty ,
33
28
textAlignmentProperty
34
29
} from '@nativescript/core' ;
35
30
import { TextViewBase } from './textview.common' ;
36
31
32
+ import { accessibilityIdentifierProperty } from '@nativescript/core/accessibility/accessibility-properties' ;
33
+ import { testIDProperty } from '@nativescript/core/ui/core/view/view-common' ;
34
+
37
35
let FrameLayoutLayoutParams : typeof android . widget . FrameLayout . LayoutParams ;
38
36
let filledId ;
39
37
let outlineId ;
@@ -307,5 +305,12 @@ export class TextView extends TextViewBase {
307
305
[ verticalTextAlignmentProperty . setNative ] ( value : VerticalTextAlignment ) {
308
306
this . nativeTextViewProtected . setGravity ( getHorizontalGravity ( this . textAlignment ) | getVerticalGravity ( value ) ) ;
309
307
}
308
+ [ testIDProperty . setNative ] ( value : string ) : void {
309
+ this . setAccessibilityIdentifier ( this . nativeTextViewProtected , value ) ;
310
+ }
311
+
312
+ [ accessibilityIdentifierProperty . setNative ] ( value : string ) : void {
313
+ this . setAccessibilityIdentifier ( this . nativeTextViewProtected , value ) ;
314
+ }
310
315
}
311
- //
316
+
0 commit comments