chore: format

This commit is contained in:
Nathan Walker
2020-07-05 14:57:06 -07:00
parent 8f2900ad0b
commit da3c0b973d
379 changed files with 71587 additions and 54582 deletions

View File

@@ -1,55 +1,61 @@
import {
ProgressBase, valueProperty, maxValueProperty
ProgressBase,
valueProperty,
maxValueProperty,
} from "./progress-common";
import { Color } from "../../color";
import { colorProperty, backgroundColorProperty, backgroundInternalProperty } from "../styling/style-properties";
import {
colorProperty,
backgroundColorProperty,
backgroundInternalProperty,
} from "../styling/style-properties";
export * from "./progress-common";
export class Progress extends ProgressBase {
nativeViewProtected: UIProgressView;
nativeViewProtected: UIProgressView;
createNativeView() {
return UIProgressView.new();
}
createNativeView() {
return UIProgressView.new();
}
get ios() {
return this.nativeViewProtected;
}
get ios() {
return this.nativeViewProtected;
}
[valueProperty.getDefault](): number {
return 0;
}
[valueProperty.setNative](value: number) {
this.ios.progress = value / this.maxValue;
}
[valueProperty.getDefault](): number {
return 0;
}
[valueProperty.setNative](value: number) {
this.ios.progress = value / this.maxValue;
}
[maxValueProperty.getDefault](): number {
return 100;
}
[maxValueProperty.setNative](value: number) {
this.ios.progress = this.value / value;
}
[maxValueProperty.getDefault](): number {
return 100;
}
[maxValueProperty.setNative](value: number) {
this.ios.progress = this.value / value;
}
[colorProperty.getDefault](): UIColor {
return this.ios.progressTintColor;
}
[colorProperty.setNative](value: Color | UIColor) {
this.ios.progressTintColor = value instanceof Color ? value.ios : value;
}
[colorProperty.getDefault](): UIColor {
return this.ios.progressTintColor;
}
[colorProperty.setNative](value: Color | UIColor) {
this.ios.progressTintColor = value instanceof Color ? value.ios : value;
}
[backgroundColorProperty.getDefault](): UIColor {
return this.ios.trackTintColor;
}
[backgroundColorProperty.setNative](value: UIColor | Color) {
let color = value instanceof Color ? value.ios : value;
this.ios.trackTintColor = color;
}
[backgroundColorProperty.getDefault](): UIColor {
return this.ios.trackTintColor;
}
[backgroundColorProperty.setNative](value: UIColor | Color) {
let color = value instanceof Color ? value.ios : value;
this.ios.trackTintColor = color;
}
[backgroundInternalProperty.getDefault](): UIColor {
return null;
}
[backgroundInternalProperty.setNative](value: Color) {
//
}
[backgroundInternalProperty.getDefault](): UIColor {
return null;
}
[backgroundInternalProperty.setNative](value: Color) {
//
}
}