mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
fix(core): type collisions with namespace (#8809)
This commit is contained in:
@@ -4,7 +4,7 @@ import { TextViewBase as TextViewBaseCommon, maxLinesProperty } from './text-vie
|
||||
import { editableProperty, hintProperty, placeholderColorProperty, _updateCharactersInRangeReplacementString } from '../editable-text-base';
|
||||
import { CSSType } from '../core/view';
|
||||
import { Color } from '../../color';
|
||||
import { colorProperty, borderTopWidthProperty, borderRightWidthProperty, borderBottomWidthProperty, borderLeftWidthProperty, paddingTopProperty, paddingRightProperty, paddingBottomProperty, paddingLeftProperty, Length } from '../styling/style-properties';
|
||||
import { colorProperty, borderTopWidthProperty, borderRightWidthProperty, borderBottomWidthProperty, borderLeftWidthProperty, paddingTopProperty, paddingRightProperty, paddingBottomProperty, paddingLeftProperty, Length, LengthType } from '../styling/style-properties';
|
||||
import { iOSNativeHelper, layout } from '../../utils';
|
||||
|
||||
import { profile } from '../../profiling';
|
||||
@@ -269,13 +269,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
this._refreshColor();
|
||||
}
|
||||
|
||||
[borderTopWidthProperty.getDefault](): Length {
|
||||
[borderTopWidthProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.top,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[borderTopWidthProperty.setNative](value: Length) {
|
||||
[borderTopWidthProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const top = layout.toDeviceIndependentPixels(this.effectivePaddingTop + this.effectiveBorderTopWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -286,13 +286,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[borderRightWidthProperty.getDefault](): Length {
|
||||
[borderRightWidthProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.right,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[borderRightWidthProperty.setNative](value: Length) {
|
||||
[borderRightWidthProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const right = layout.toDeviceIndependentPixels(this.effectivePaddingRight + this.effectiveBorderRightWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -303,13 +303,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[borderBottomWidthProperty.getDefault](): Length {
|
||||
[borderBottomWidthProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.bottom,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[borderBottomWidthProperty.setNative](value: Length) {
|
||||
[borderBottomWidthProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const bottom = layout.toDeviceIndependentPixels(this.effectivePaddingBottom + this.effectiveBorderBottomWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -320,13 +320,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[borderLeftWidthProperty.getDefault](): Length {
|
||||
[borderLeftWidthProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.left,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[borderLeftWidthProperty.setNative](value: Length) {
|
||||
[borderLeftWidthProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const left = layout.toDeviceIndependentPixels(this.effectivePaddingLeft + this.effectiveBorderLeftWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -337,13 +337,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[paddingTopProperty.getDefault](): Length {
|
||||
[paddingTopProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.top,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[paddingTopProperty.setNative](value: Length) {
|
||||
[paddingTopProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const top = layout.toDeviceIndependentPixels(this.effectivePaddingTop + this.effectiveBorderTopWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -354,13 +354,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[paddingRightProperty.getDefault](): Length {
|
||||
[paddingRightProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.right,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[paddingRightProperty.setNative](value: Length) {
|
||||
[paddingRightProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const right = layout.toDeviceIndependentPixels(this.effectivePaddingRight + this.effectiveBorderRightWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -371,13 +371,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
};
|
||||
}
|
||||
|
||||
[paddingBottomProperty.getDefault](): Length {
|
||||
[paddingBottomProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.bottom,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[paddingBottomProperty.setNative](value: Length) {
|
||||
[paddingBottomProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const bottom = layout.toDeviceIndependentPixels(this.effectivePaddingBottom + this.effectiveBorderBottomWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
@@ -387,13 +387,13 @@ export class TextView extends TextViewBaseCommon {
|
||||
right: inset.right,
|
||||
};
|
||||
}
|
||||
[paddingLeftProperty.getDefault](): Length {
|
||||
[paddingLeftProperty.getDefault](): LengthType {
|
||||
return {
|
||||
value: this.nativeTextViewProtected.textContainerInset.left,
|
||||
unit: 'px',
|
||||
};
|
||||
}
|
||||
[paddingLeftProperty.setNative](value: Length) {
|
||||
[paddingLeftProperty.setNative](value: LengthType) {
|
||||
const inset = this.nativeTextViewProtected.textContainerInset;
|
||||
const left = layout.toDeviceIndependentPixels(this.effectivePaddingLeft + this.effectiveBorderLeftWidth);
|
||||
this.nativeTextViewProtected.textContainerInset = {
|
||||
|
||||
Reference in New Issue
Block a user