js: padding currently only support group or text,input

This commit is contained in:
pengfei.zhou
2022-08-25 10:42:56 +08:00
committed by osborn
parent 02259823da
commit 3937a3f4d3
16 changed files with 129 additions and 48 deletions

View File

@@ -104,6 +104,14 @@ export class Input extends View {
replacement: string,
}) => boolean
@Property
padding?: {
left?: number,
right?: number,
top?: number,
bottom?: number,
}
getText(context: BridgeContext) {
return this.nativeChannel(context, 'getText')() as Promise<string>
}

View File

@@ -69,6 +69,14 @@ export class Text extends View implements JSX.ElementChildrenAttribute {
@Property
truncateAt?: TruncateAt
@Property
padding?: {
left?: number,
right?: number,
top?: number,
bottom?: number,
}
set innerElement(e: string) {
this.text = e
}