@nativescript/core 9.0.12-next.0 → 9.0.12-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +19 -0
- package/abortcontroller/abortsignal.d.ts +23 -0
- package/abortcontroller/abortsignal.js +57 -0
- package/abortcontroller/abortsignal.js.map +1 -0
- package/abortcontroller/index.d.ts +20 -0
- package/abortcontroller/index.js +52 -0
- package/abortcontroller/index.js.map +1 -0
- package/accessibility/accessibility-common.d.ts +282 -0
- package/accessibility/accessibility-common.js +416 -0
- package/accessibility/accessibility-common.js.map +1 -0
- package/accessibility/accessibility-properties.d.ts +24 -0
- package/accessibility/accessibility-properties.js +118 -0
- package/accessibility/accessibility-properties.js.map +1 -0
- package/accessibility/index.d.ts +1 -0
- package/accessibility/index.js +2 -0
- package/accessibility/index.js.map +1 -0
- package/animation-frame/animation-native.android.d.ts +1 -0
- package/animation-frame/animation-native.android.js +4 -0
- package/animation-frame/animation-native.android.js.map +1 -0
- package/animation-frame/animation-native.ios.d.ts +1 -0
- package/animation-frame/animation-native.ios.js +3 -0
- package/animation-frame/animation-native.ios.js.map +1 -0
- package/animation-frame/index.js +81 -0
- package/animation-frame/index.js.map +1 -0
- package/application/application-common.d.ts +247 -0
- package/application/application-common.js +578 -0
- package/application/application-common.js.map +1 -0
- package/application/application-interfaces.d.ts +220 -0
- package/application/application-interfaces.js +2 -0
- package/application/application-interfaces.js.map +1 -0
- package/application/application-shims.d.ts +378 -0
- package/application/application-shims.js +380 -0
- package/application/application-shims.js.map +1 -0
- package/application/application.android.d.ts +81 -0
- package/application/application.android.js +1233 -0
- package/application/application.android.js.map +1 -0
- package/application/application.ios.d.ts +145 -0
- package/application/application.ios.js +1481 -0
- package/application/application.ios.js.map +1 -0
- package/application/helpers-common.d.ts +50 -0
- package/application/helpers-common.js +153 -0
- package/application/helpers-common.js.map +1 -0
- package/application/helpers.android.d.ts +8 -0
- package/application/helpers.android.js +119 -0
- package/application/helpers.android.js.map +1 -0
- package/application/helpers.ios.d.ts +8 -0
- package/application/helpers.ios.js +24 -0
- package/application/helpers.ios.js.map +1 -0
- package/application/index.android.d.ts +2 -0
- package/application/index.android.js +3 -0
- package/application/index.android.js.map +1 -0
- package/application/index.ios.d.ts +2 -0
- package/application/index.ios.js +3 -0
- package/application/index.ios.js.map +1 -0
- package/application-settings/application-settings-common.d.ts +2 -0
- package/application-settings/application-settings-common.js +15 -0
- package/application-settings/application-settings-common.js.map +1 -0
- package/application-settings/index.android.d.ts +11 -0
- package/application-settings/index.android.js +124 -0
- package/application-settings/index.android.js.map +1 -0
- package/application-settings/index.ios.d.ts +11 -0
- package/application-settings/index.ios.js +81 -0
- package/application-settings/index.ios.js.map +1 -0
- package/bundle-entry-points.d.ts +1 -0
- package/bundle-entry-points.js +47 -0
- package/bundle-entry-points.js.map +1 -0
- package/color/color-common.d.ts +136 -0
- package/color/color-common.js +341 -0
- package/color/color-common.js.map +1 -0
- package/color/color-types.d.ts +49 -0
- package/color/color-types.js +3 -0
- package/color/color-types.js.map +1 -0
- package/color/color-utils.d.ts +38 -0
- package/color/color-utils.js +213 -0
- package/color/color-utils.js.map +1 -0
- package/color/index.android.d.ts +4 -0
- package/color/index.android.js +7 -0
- package/color/index.android.js.map +1 -0
- package/color/index.ios.d.ts +7 -0
- package/color/index.ios.js +19 -0
- package/color/index.ios.js.map +1 -0
- package/color/known-colors.d.ts +144 -0
- package/color/known-colors.js +165 -0
- package/color/known-colors.js.map +1 -0
- package/config/config.interface.d.ts +297 -0
- package/config/config.interface.js +2 -0
- package/config/config.interface.js.map +1 -0
- package/config/index.d.ts +1 -0
- package/config/index.js +2 -0
- package/config/index.js.map +1 -0
- package/connectivity/index.android.d.ts +11 -0
- package/connectivity/index.android.js +157 -0
- package/connectivity/index.android.js.map +1 -0
- package/connectivity/index.ios.d.ts +11 -0
- package/connectivity/index.ios.js +132 -0
- package/connectivity/index.ios.js.map +1 -0
- package/console/index.d.ts +14 -0
- package/console/index.js +33 -0
- package/console/index.js.map +1 -0
- package/core-types/animation-types.d.ts +11 -0
- package/core-types/animation-types.js +13 -0
- package/core-types/animation-types.js.map +1 -0
- package/core-types/index.d.ts +345 -0
- package/core-types/index.js +290 -0
- package/core-types/index.js.map +1 -0
- package/core-types/validators.d.ts +2 -0
- package/core-types/validators.js +27 -0
- package/core-types/validators.js.map +1 -0
- package/css/CSS3Parser.d.ts +184 -0
- package/css/CSS3Parser.js +534 -0
- package/css/CSS3Parser.js.map +1 -0
- package/css/CSSNativeScript.d.ts +14 -0
- package/css/CSSNativeScript.js +113 -0
- package/css/CSSNativeScript.js.map +1 -0
- package/css/css-tree-parser.d.ts +1 -0
- package/css/css-tree-parser.js +133 -0
- package/css/css-tree-parser.js.map +1 -0
- package/css/lib/parse/index.d.ts +1 -0
- package/css/lib/parse/index.js +500 -0
- package/css/lib/parse/index.js.map +1 -0
- package/css/parser.d.ts +70 -0
- package/css/parser.js +517 -0
- package/css/parser.js.map +1 -0
- package/css/reworkcss.d.ts +44 -0
- package/css/reworkcss.js +5 -0
- package/css/reworkcss.js.map +1 -0
- package/css/system-classes.d.ts +12 -0
- package/css/system-classes.js +47 -0
- package/css/system-classes.js.map +1 -0
- package/css-mediaquery/index.d.ts +27 -0
- package/css-mediaquery/index.js +118 -0
- package/css-mediaquery/index.js.map +1 -0
- package/css-value/reworkcss-value.d.ts +31 -0
- package/css-value/reworkcss-value.js +91 -0
- package/css-value/reworkcss-value.js.map +1 -0
- package/data/observable/index.d.ts +213 -0
- package/data/observable/index.js +452 -0
- package/data/observable/index.js.map +1 -0
- package/data/observable-array/index.d.ts +215 -0
- package/data/observable-array/index.js +325 -0
- package/data/observable-array/index.js.map +1 -0
- package/data/virtual-array/index.d.ts +72 -0
- package/data/virtual-array/index.js +133 -0
- package/data/virtual-array/index.js.map +1 -0
- package/debugger/InspectorBackendCommands.d.ts +1056 -0
- package/debugger/InspectorBackendCommands.js +578 -0
- package/debugger/InspectorBackendCommands.js.map +1 -0
- package/debugger/devtools-elements-interfaces.d.ts +16 -0
- package/debugger/devtools-elements-interfaces.js +2 -0
- package/debugger/devtools-elements-interfaces.js.map +1 -0
- package/debugger/devtools-elements.common.d.ts +7 -0
- package/debugger/devtools-elements.common.js +93 -0
- package/debugger/devtools-elements.common.js.map +1 -0
- package/debugger/devtools-elements.js +20 -0
- package/debugger/devtools-elements.js.map +1 -0
- package/debugger/dom-types.d.ts +24 -0
- package/debugger/dom-types.js +152 -0
- package/debugger/dom-types.js.map +1 -0
- package/debugger/index.d.ts +87 -0
- package/debugger/index.js +118 -0
- package/debugger/index.js.map +1 -0
- package/debugger/webinspector-css.d.ts +34 -0
- package/debugger/webinspector-css.js +72 -0
- package/debugger/webinspector-css.js.map +1 -0
- package/debugger/webinspector-dom.d.ts +33 -0
- package/debugger/webinspector-dom.js +75 -0
- package/debugger/webinspector-dom.js.map +1 -0
- package/debugger/webinspector-network.android.d.ts +79 -0
- package/debugger/webinspector-network.android.js +208 -0
- package/debugger/webinspector-network.android.js.map +1 -0
- package/debugger/webinspector-network.ios.d.ts +79 -0
- package/debugger/webinspector-network.ios.js +204 -0
- package/debugger/webinspector-network.ios.js.map +1 -0
- package/fetch/index.d.ts +72 -0
- package/fetch/index.js +529 -0
- package/fetch/index.js.map +1 -0
- package/file-system/file-system-access.android.d.ts +151 -0
- package/file-system/file-system-access.android.js +1162 -0
- package/file-system/file-system-access.android.js.map +1 -0
- package/file-system/file-system-access.ios.d.ts +85 -0
- package/file-system/file-system-access.ios.js +622 -0
- package/file-system/file-system-access.ios.js.map +1 -0
- package/file-system/index.js +873 -0
- package/file-system/index.js.map +1 -0
- package/fps-meter/fps-native.android.d.ts +11 -0
- package/fps-meter/fps-native.android.js +62 -0
- package/fps-meter/fps-native.android.js.map +1 -0
- package/fps-meter/fps-native.ios.d.ts +10 -0
- package/fps-meter/fps-native.ios.js +56 -0
- package/fps-meter/fps-native.ios.js.map +1 -0
- package/fps-meter/index.js +77 -0
- package/fps-meter/index.js.map +1 -0
- package/globals/global-utils.d.ts +27 -0
- package/globals/global-utils.js +67 -0
- package/globals/global-utils.js.map +1 -0
- package/globals/index.d.ts +3 -0
- package/globals/index.js +313 -0
- package/globals/index.js.map +1 -0
- package/http/http-interfaces.d.ts +84 -0
- package/http/http-interfaces.js +6 -0
- package/http/http-interfaces.js.map +1 -0
- package/http/http-request/http-request-common.d.ts +1 -0
- package/http/http-request/http-request-common.js +15 -0
- package/http/http-request/http-request-common.js.map +1 -0
- package/http/http-request/index.android.d.ts +3 -0
- package/http/http-request/index.android.js +274 -0
- package/http/http-request/index.android.js.map +1 -0
- package/http/http-request/index.ios.d.ts +3 -0
- package/http/http-request/index.ios.js +221 -0
- package/http/http-request/index.ios.js.map +1 -0
- package/http/http-shared.d.ts +3 -0
- package/http/http-shared.js +2 -0
- package/http/http-shared.js.map +1 -0
- package/http/index.js +70 -0
- package/http/index.js.map +1 -0
- package/image-asset/image-asset-common.d.ts +25 -0
- package/image-asset/image-asset-common.js +74 -0
- package/image-asset/image-asset-common.js.map +1 -0
- package/image-asset/index.android.d.ts +9 -0
- package/image-asset/index.android.js +33 -0
- package/image-asset/index.android.js.map +1 -0
- package/image-asset/index.ios.d.ts +10 -0
- package/image-asset/index.ios.js +57 -0
- package/image-asset/index.ios.js.map +1 -0
- package/image-source/image-source-common.d.ts +4 -0
- package/image-source/image-source-common.js +21 -0
- package/image-source/image-source-common.js.map +1 -0
- package/image-source/index.android.d.ts +58 -0
- package/image-source/index.android.js +371 -0
- package/image-source/index.android.js.map +1 -0
- package/image-source/index.ios.d.ts +59 -0
- package/image-source/index.ios.js +454 -0
- package/image-source/index.ios.js.map +1 -0
- package/index.js +38 -0
- package/index.js.map +1 -0
- package/inspector_modules.d.ts +7 -0
- package/inspector_modules.js +233 -0
- package/inspector_modules.js.map +1 -0
- package/matrix/index.js +45 -0
- package/matrix/index.js.map +1 -0
- package/media-query-list/index.d.ts +21 -0
- package/media-query-list/index.js +159 -0
- package/media-query-list/index.js.map +1 -0
- package/module-name-resolver/helpers.d.ts +14 -0
- package/module-name-resolver/helpers.js +27 -0
- package/module-name-resolver/helpers.js.map +1 -0
- package/module-name-resolver/index.d.ts +14 -0
- package/module-name-resolver/index.js +67 -0
- package/module-name-resolver/index.js.map +1 -0
- package/module-name-resolver/non-bundle-workflow-compat.d.ts +6 -0
- package/module-name-resolver/non-bundle-workflow-compat.js +128 -0
- package/module-name-resolver/non-bundle-workflow-compat.js.map +1 -0
- package/module-name-resolver/qualifier-matcher/index.d.ts +11 -0
- package/module-name-resolver/qualifier-matcher/index.js +141 -0
- package/module-name-resolver/qualifier-matcher/index.js.map +1 -0
- package/package.json +86 -86
- package/platform/common.d.ts +10 -0
- package/platform/common.js +14 -0
- package/platform/common.js.map +1 -0
- package/platform/device/index.android.d.ts +20 -0
- package/platform/device/index.android.js +78 -0
- package/platform/device/index.android.js.map +1 -0
- package/platform/device/index.ios.d.ts +19 -0
- package/platform/device/index.ios.js +69 -0
- package/platform/device/index.ios.js.map +1 -0
- package/platform/index.js +4 -0
- package/platform/index.js.map +1 -0
- package/platform/screen/index.android.d.ts +16 -0
- package/platform/screen/index.android.js +41 -0
- package/platform/screen/index.android.js.map +1 -0
- package/platform/screen/index.ios.d.ts +15 -0
- package/platform/screen/index.ios.js +35 -0
- package/platform/screen/index.ios.js.map +1 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSCCrypto.h +79 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSCWinterTC.h +20 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Headers/NSString+WinterTC.h +21 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Modules/module.modulemap +6 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Resources/Info.plist +52 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSCCrypto.h +79 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSCWinterTC.h +20 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Headers/NSString+WinterTC.h +21 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Modules/module.modulemap +6 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/NSCWinterTC +0 -0
- package/platforms/ios/NSCWinterTC.xcframework/ios-arm64_x86_64-maccatalyst/NSCWinterTC.framework/Versions/Current/Resources/Info.plist +52 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSCCrypto.h +60 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSData+Async.h +24 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSFileHandle+Async.h +22 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSString+Async.h +25 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSLabel.h +16 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSProcess.h +29 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSWidgets.h +25 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +26 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +17 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Modules/module.modulemap +6 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +17 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +18 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Resources/Info.plist +52 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSCCrypto.h +60 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSData+Async.h +24 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSFileHandle+Async.h +22 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSString+Async.h +25 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSLabel.h +16 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSProcess.h +29 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSWidgets.h +25 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIImage+TNSBlocks.h +26 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIView+PassThroughParent.h +17 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Modules/module.modulemap +6 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/NSObject+Swizzling.h +17 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/UIView+PropertyBag.h +18 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Resources/Info.plist +52 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/TNSWidgets +0 -0
- package/profiling/index.js +273 -0
- package/profiling/index.js.map +1 -0
- package/text/formatted-string.js +2 -0
- package/text/formatted-string.js.map +1 -0
- package/text/index.android.d.ts +9 -0
- package/text/index.android.js +11 -0
- package/text/index.android.js.map +1 -0
- package/text/index.ios.d.ts +9 -0
- package/text/index.ios.js +11 -0
- package/text/index.ios.js.map +1 -0
- package/text/span.js +2 -0
- package/text/span.js.map +1 -0
- package/text/text-common.d.ts +12 -0
- package/text/text-common.js +111 -0
- package/text/text-common.js.map +1 -0
- package/timer/index.android.d.ts +4 -0
- package/timer/index.android.js +83 -0
- package/timer/index.android.js.map +1 -0
- package/timer/index.ios.d.ts +4 -0
- package/timer/index.ios.js +68 -0
- package/timer/index.ios.js.map +1 -0
- package/trace/index.js +255 -0
- package/trace/index.js.map +1 -0
- package/ui/action-bar/action-bar-common.d.ts +85 -0
- package/ui/action-bar/action-bar-common.js +381 -0
- package/ui/action-bar/action-bar-common.js.map +1 -0
- package/ui/action-bar/index.android.d.ts +55 -0
- package/ui/action-bar/index.android.js +502 -0
- package/ui/action-bar/index.android.js.map +1 -0
- package/ui/action-bar/index.ios.d.ts +64 -0
- package/ui/action-bar/index.ios.js +614 -0
- package/ui/action-bar/index.ios.js.map +1 -0
- package/ui/activity-indicator/activity-indicator-common.d.ts +9 -0
- package/ui/activity-indicator/activity-indicator-common.js +22 -0
- package/ui/activity-indicator/activity-indicator-common.js.map +1 -0
- package/ui/activity-indicator/index.android.d.ts +15 -0
- package/ui/activity-indicator/index.android.js +54 -0
- package/ui/activity-indicator/index.android.js.map +1 -0
- package/ui/activity-indicator/index.ios.d.ts +16 -0
- package/ui/activity-indicator/index.ios.js +54 -0
- package/ui/activity-indicator/index.ios.js.map +1 -0
- package/ui/animation/animation-common.d.ts +30 -0
- package/ui/animation/animation-common.js +239 -0
- package/ui/animation/animation-common.js.map +1 -0
- package/ui/animation/animation-shared.d.ts +84 -0
- package/ui/animation/animation-shared.js +4 -0
- package/ui/animation/animation-shared.js.map +1 -0
- package/ui/animation/animation-types.d.ts +1 -0
- package/ui/animation/animation-types.js +3 -0
- package/ui/animation/animation-types.js.map +1 -0
- package/ui/animation/index.android.d.ts +23 -0
- package/ui/animation/index.android.js +432 -0
- package/ui/animation/index.android.js.map +1 -0
- package/ui/animation/index.ios.d.ts +28 -0
- package/ui/animation/index.ios.js +808 -0
- package/ui/animation/index.ios.js.map +1 -0
- package/ui/animation/keyframe-animation.d.ts +76 -0
- package/ui/animation/keyframe-animation.js +238 -0
- package/ui/animation/keyframe-animation.js.map +1 -0
- package/ui/builder/binding-builder.d.ts +13 -0
- package/ui/builder/binding-builder.js +171 -0
- package/ui/builder/binding-builder.js.map +1 -0
- package/ui/builder/component-builder/index.d.ts +7 -0
- package/ui/builder/component-builder/index.js +219 -0
- package/ui/builder/component-builder/index.js.map +1 -0
- package/ui/builder/index.d.ts +193 -0
- package/ui/builder/index.js +643 -0
- package/ui/builder/index.js.map +1 -0
- package/ui/button/button-common.d.ts +9 -0
- package/ui/button/button-common.js +26 -0
- package/ui/button/button-common.js.map +1 -0
- package/ui/button/index.android.d.ts +29 -0
- package/ui/button/index.android.js +166 -0
- package/ui/button/index.android.js.map +1 -0
- package/ui/button/index.ios.d.ts +37 -0
- package/ui/button/index.ios.js +316 -0
- package/ui/button/index.ios.js.map +1 -0
- package/ui/content-view/index.js +87 -0
- package/ui/content-view/index.js.map +1 -0
- package/ui/core/bindable/bindable-expressions.d.ts +7 -0
- package/ui/core/bindable/bindable-expressions.js +255 -0
- package/ui/core/bindable/bindable-expressions.js.map +1 -0
- package/ui/core/bindable/bindable-resources.d.ts +2 -0
- package/ui/core/bindable/bindable-resources.js +8 -0
- package/ui/core/bindable/bindable-resources.js.map +1 -0
- package/ui/core/bindable/bindable-types.d.ts +37 -0
- package/ui/core/bindable/bindable-types.js +3 -0
- package/ui/core/bindable/bindable-types.js.map +1 -0
- package/ui/core/bindable/index.d.ts +53 -0
- package/ui/core/bindable/index.js +555 -0
- package/ui/core/bindable/index.js.map +1 -0
- package/ui/core/control-state-change/index.android.d.ts +6 -0
- package/ui/core/control-state-change/index.android.js +8 -0
- package/ui/core/control-state-change/index.android.js.map +1 -0
- package/ui/core/control-state-change/index.ios.d.ts +10 -0
- package/ui/core/control-state-change/index.ios.js +43 -0
- package/ui/core/control-state-change/index.ios.js.map +1 -0
- package/ui/core/properties/index.d.ts +114 -0
- package/ui/core/properties/index.js +1290 -0
- package/ui/core/properties/index.js.map +1 -0
- package/ui/core/properties/property-shared.d.ts +35 -0
- package/ui/core/properties/property-shared.js +16 -0
- package/ui/core/properties/property-shared.js.map +1 -0
- package/ui/core/view/index.android.d.ts +144 -0
- package/ui/core/view/index.android.js +1576 -0
- package/ui/core/view/index.android.js.map +1 -0
- package/ui/core/view/index.ios.d.ts +151 -0
- package/ui/core/view/index.ios.js +1091 -0
- package/ui/core/view/index.ios.js.map +1 -0
- package/ui/core/view/view-common.d.ts +349 -0
- package/ui/core/view/view-common.js +1147 -0
- package/ui/core/view/view-common.js.map +1 -0
- package/ui/core/view/view-helper/index.android.d.ts +9 -0
- package/ui/core/view/view-helper/index.android.js +56 -0
- package/ui/core/view/view-helper/index.android.js.map +1 -0
- package/ui/core/view/view-helper/index.ios.d.ts +67 -0
- package/ui/core/view/view-helper/index.ios.js +414 -0
- package/ui/core/view/view-helper/index.ios.js.map +1 -0
- package/ui/core/view/view-helper/view-helper-common.d.ts +11 -0
- package/ui/core/view/view-helper/view-helper-common.js +166 -0
- package/ui/core/view/view-helper/view-helper-common.js.map +1 -0
- package/ui/core/view/view-helper/view-helper-shared.d.ts +5 -0
- package/ui/core/view/view-helper/view-helper-shared.js +6 -0
- package/ui/core/view/view-helper/view-helper-shared.js.map +1 -0
- package/ui/core/view/view-interfaces.d.ts +76 -0
- package/ui/core/view/view-interfaces.js +2 -0
- package/ui/core/view/view-interfaces.js.map +1 -0
- package/ui/core/view-base/index.d.ts +597 -0
- package/ui/core/view-base/index.js +1154 -0
- package/ui/core/view-base/index.js.map +1 -0
- package/ui/core/view-base/utils.d.ts +1 -0
- package/ui/core/view-base/utils.js +9 -0
- package/ui/core/view-base/utils.js.map +1 -0
- package/ui/core/weak-event-listener/index.js +123 -0
- package/ui/core/weak-event-listener/index.js.map +1 -0
- package/ui/date-picker/date-picker-common.d.ts +28 -0
- package/ui/date-picker/date-picker-common.js +82 -0
- package/ui/date-picker/date-picker-common.js.map +1 -0
- package/ui/date-picker/index.android.d.ts +19 -0
- package/ui/date-picker/index.android.js +131 -0
- package/ui/date-picker/index.android.js.map +1 -0
- package/ui/date-picker/index.ios.d.ts +27 -0
- package/ui/date-picker/index.ios.js +165 -0
- package/ui/date-picker/index.ios.js.map +1 -0
- package/ui/dialogs/dialogs-common.d.ts +211 -0
- package/ui/dialogs/dialogs-common.js +167 -0
- package/ui/dialogs/dialogs-common.js.map +1 -0
- package/ui/dialogs/index.android.d.ts +20 -0
- package/ui/dialogs/index.android.js +330 -0
- package/ui/dialogs/index.android.js.map +1 -0
- package/ui/dialogs/index.ios.d.ts +17 -0
- package/ui/dialogs/index.ios.js +293 -0
- package/ui/dialogs/index.ios.js.map +1 -0
- package/ui/editable-text-base/editable-text-base-common.d.ts +36 -0
- package/ui/editable-text-base/editable-text-base-common.js +91 -0
- package/ui/editable-text-base/editable-text-base-common.js.map +1 -0
- package/ui/editable-text-base/index.android.d.ts +48 -0
- package/ui/editable-text-base/index.android.js +497 -0
- package/ui/editable-text-base/index.android.js.map +1 -0
- package/ui/editable-text-base/index.ios.d.ts +20 -0
- package/ui/editable-text-base/index.ios.js +255 -0
- package/ui/editable-text-base/index.ios.js.map +1 -0
- package/ui/embedding/index.android.d.ts +4 -0
- package/ui/embedding/index.android.js +14 -0
- package/ui/embedding/index.android.js.map +1 -0
- package/ui/embedding/index.ios.d.ts +1 -0
- package/ui/embedding/index.ios.js +4 -0
- package/ui/embedding/index.ios.js.map +1 -0
- package/ui/enums/enums.js +6 -0
- package/ui/enums/enums.js.map +1 -0
- package/ui/enums/index.js +6 -0
- package/ui/enums/index.js.map +1 -0
- package/ui/frame/activity.android.d.ts +1 -0
- package/ui/frame/activity.android.js +110 -0
- package/ui/frame/activity.android.js.map +1 -0
- package/ui/frame/fragment.android.d.ts +3 -0
- package/ui/frame/fragment.android.js +90 -0
- package/ui/frame/fragment.android.js.map +1 -0
- package/ui/frame/fragment.ios.d.ts +3 -0
- package/ui/frame/fragment.ios.js +4 -0
- package/ui/frame/fragment.ios.js.map +1 -0
- package/ui/frame/fragment.transitions.android.d.ts +40 -0
- package/ui/frame/fragment.transitions.android.js +679 -0
- package/ui/frame/fragment.transitions.android.js.map +1 -0
- package/ui/frame/fragment.transitions.types.d.ts +6 -0
- package/ui/frame/fragment.transitions.types.js +2 -0
- package/ui/frame/fragment.transitions.types.js.map +1 -0
- package/ui/frame/frame-common.d.ts +101 -0
- package/ui/frame/frame-common.js +688 -0
- package/ui/frame/frame-common.js.map +1 -0
- package/ui/frame/frame-helper-for-android.d.ts +37 -0
- package/ui/frame/frame-helper-for-android.js +337 -0
- package/ui/frame/frame-helper-for-android.js.map +1 -0
- package/ui/frame/frame-helpers.d.ts +16 -0
- package/ui/frame/frame-helpers.js +19 -0
- package/ui/frame/frame-helpers.js.map +1 -0
- package/ui/frame/frame-interfaces.d.ts +130 -0
- package/ui/frame/frame-interfaces.js +7 -0
- package/ui/frame/frame-interfaces.js.map +1 -0
- package/ui/frame/frame-stack.d.ts +7 -0
- package/ui/frame/frame-stack.js +41 -0
- package/ui/frame/frame-stack.js.map +1 -0
- package/ui/frame/index.android.d.ts +93 -0
- package/ui/frame/index.android.js +977 -0
- package/ui/frame/index.android.js.map +1 -0
- package/ui/frame/index.ios.d.ts +61 -0
- package/ui/frame/index.ios.js +728 -0
- package/ui/frame/index.ios.js.map +1 -0
- package/ui/gestures/gestures-common.d.ts +32 -0
- package/ui/gestures/gestures-common.js +78 -0
- package/ui/gestures/gestures-common.js.map +1 -0
- package/ui/gestures/gestures-types.d.ts +108 -0
- package/ui/gestures/gestures-types.js +40 -0
- package/ui/gestures/gestures-types.js.map +1 -0
- package/ui/gestures/index.android.d.ts +49 -0
- package/ui/gestures/index.android.js +596 -0
- package/ui/gestures/index.android.js.map +1 -0
- package/ui/gestures/index.ios.d.ts +70 -0
- package/ui/gestures/index.ios.js +510 -0
- package/ui/gestures/index.ios.js.map +1 -0
- package/ui/gestures/touch-manager.d.ts +82 -0
- package/ui/gestures/touch-manager.js +268 -0
- package/ui/gestures/touch-manager.js.map +1 -0
- package/ui/html-view/html-view-common.d.ts +12 -0
- package/ui/html-view/html-view-common.js +31 -0
- package/ui/html-view/html-view-common.js.map +1 -0
- package/ui/html-view/index.android.d.ts +27 -0
- package/ui/html-view/index.android.js +90 -0
- package/ui/html-view/index.android.js.map +1 -0
- package/ui/html-view/index.ios.d.ts +22 -0
- package/ui/html-view/index.ios.js +101 -0
- package/ui/html-view/index.ios.js.map +1 -0
- package/ui/image/image-common.d.ts +45 -0
- package/ui/image/image-common.js +195 -0
- package/ui/image/image-common.js.map +1 -0
- package/ui/image/index.android.d.ts +23 -0
- package/ui/image/index.android.js +171 -0
- package/ui/image/index.android.js.map +1 -0
- package/ui/image/index.ios.d.ts +26 -0
- package/ui/image/index.ios.js +186 -0
- package/ui/image/index.ios.js.map +1 -0
- package/ui/image/symbol-effects-common.d.ts +36 -0
- package/ui/image/symbol-effects-common.js +35 -0
- package/ui/image/symbol-effects-common.js.map +1 -0
- package/ui/image/symbol-effects.android.d.ts +5 -0
- package/ui/image/symbol-effects.android.js +8 -0
- package/ui/image/symbol-effects.android.js.map +1 -0
- package/ui/image/symbol-effects.ios.d.ts +6 -0
- package/ui/image/symbol-effects.ios.js +79 -0
- package/ui/image/symbol-effects.ios.js.map +1 -0
- package/ui/image-cache/image-cache-common.d.ts +40 -0
- package/ui/image-cache/image-cache-common.js +176 -0
- package/ui/image-cache/image-cache-common.js.map +1 -0
- package/ui/image-cache/index.android.d.ts +11 -0
- package/ui/image-cache/index.android.js +74 -0
- package/ui/image-cache/index.android.js.map +1 -0
- package/ui/image-cache/index.ios.d.ts +11 -0
- package/ui/image-cache/index.ios.js +78 -0
- package/ui/image-cache/index.ios.js.map +1 -0
- package/ui/index.d.ts +92 -0
- package/ui/index.js +80 -0
- package/ui/index.js.map +1 -0
- package/ui/label/index.android.d.ts +13 -0
- package/ui/label/index.android.js +47 -0
- package/ui/label/index.android.js.map +1 -0
- package/ui/label/index.ios.d.ts +31 -0
- package/ui/label/index.ios.js +234 -0
- package/ui/label/index.ios.js.map +1 -0
- package/ui/layouts/absolute-layout/absolute-layout-common.d.ts +16 -0
- package/ui/layouts/absolute-layout/absolute-layout-common.js +72 -0
- package/ui/layouts/absolute-layout/absolute-layout-common.js.map +1 -0
- package/ui/layouts/absolute-layout/index.android.d.ts +6 -0
- package/ui/layouts/absolute-layout/index.android.js +26 -0
- package/ui/layouts/absolute-layout/index.android.js.map +1 -0
- package/ui/layouts/absolute-layout/index.ios.d.ts +10 -0
- package/ui/layouts/absolute-layout/index.ios.js +48 -0
- package/ui/layouts/absolute-layout/index.ios.js.map +1 -0
- package/ui/layouts/dock-layout/dock-layout-common.d.ts +14 -0
- package/ui/layouts/dock-layout/dock-layout-common.js +51 -0
- package/ui/layouts/dock-layout/dock-layout-common.js.map +1 -0
- package/ui/layouts/dock-layout/index.android.d.ts +8 -0
- package/ui/layouts/dock-layout/index.android.js +38 -0
- package/ui/layouts/dock-layout/index.android.js.map +1 -0
- package/ui/layouts/dock-layout/index.ios.d.ts +8 -0
- package/ui/layouts/dock-layout/index.ios.js +115 -0
- package/ui/layouts/dock-layout/index.ios.js.map +1 -0
- package/ui/layouts/flexbox-layout/flexbox-layout-common.d.ts +126 -0
- package/ui/layouts/flexbox-layout/flexbox-layout-common.js +403 -0
- package/ui/layouts/flexbox-layout/flexbox-layout-common.js.map +1 -0
- package/ui/layouts/flexbox-layout/index.android.d.ts +23 -0
- package/ui/layouts/flexbox-layout/index.android.js +152 -0
- package/ui/layouts/flexbox-layout/index.android.js.map +1 -0
- package/ui/layouts/flexbox-layout/index.ios.d.ts +44 -0
- package/ui/layouts/flexbox-layout/index.ios.js +1241 -0
- package/ui/layouts/flexbox-layout/index.ios.js.map +1 -0
- package/ui/layouts/grid-layout/grid-layout-common.d.ts +72 -0
- package/ui/layouts/grid-layout/grid-layout-common.js +358 -0
- package/ui/layouts/grid-layout/grid-layout-common.js.map +1 -0
- package/ui/layouts/grid-layout/index.android.d.ts +23 -0
- package/ui/layouts/grid-layout/index.android.js +122 -0
- package/ui/layouts/grid-layout/index.android.js.map +1 -0
- package/ui/layouts/grid-layout/index.ios.d.ts +28 -0
- package/ui/layouts/grid-layout/index.ios.js +778 -0
- package/ui/layouts/grid-layout/index.ios.js.map +1 -0
- package/ui/layouts/index.d.ts +12 -0
- package/ui/layouts/index.js +11 -0
- package/ui/layouts/index.js.map +1 -0
- package/ui/layouts/layout-base-common.d.ts +36 -0
- package/ui/layouts/layout-base-common.js +141 -0
- package/ui/layouts/layout-base-common.js.map +1 -0
- package/ui/layouts/layout-base.android.d.ts +17 -0
- package/ui/layouts/layout-base.android.js +50 -0
- package/ui/layouts/layout-base.android.js.map +1 -0
- package/ui/layouts/layout-base.ios.d.ts +13 -0
- package/ui/layouts/layout-base.ios.js +40 -0
- package/ui/layouts/layout-base.ios.js.map +1 -0
- package/ui/layouts/liquid-glass/index.android.d.ts +5 -0
- package/ui/layouts/liquid-glass/index.android.js +8 -0
- package/ui/layouts/liquid-glass/index.android.js.map +1 -0
- package/ui/layouts/liquid-glass/index.ios.d.ts +10 -0
- package/ui/layouts/liquid-glass/index.ios.js +59 -0
- package/ui/layouts/liquid-glass/index.ios.js.map +1 -0
- package/ui/layouts/liquid-glass/liquid-glass-common.d.ts +3 -0
- package/ui/layouts/liquid-glass/liquid-glass-common.js +4 -0
- package/ui/layouts/liquid-glass/liquid-glass-common.js.map +1 -0
- package/ui/layouts/liquid-glass-container/index.android.d.ts +3 -0
- package/ui/layouts/liquid-glass-container/index.android.js +4 -0
- package/ui/layouts/liquid-glass-container/index.android.js.map +1 -0
- package/ui/layouts/liquid-glass-container/index.ios.d.ts +14 -0
- package/ui/layouts/liquid-glass-container/index.ios.js +121 -0
- package/ui/layouts/liquid-glass-container/index.ios.js.map +1 -0
- package/ui/layouts/liquid-glass-container/liquid-glass-container-common.d.ts +4 -0
- package/ui/layouts/liquid-glass-container/liquid-glass-container-common.js +5 -0
- package/ui/layouts/liquid-glass-container/liquid-glass-container-common.js.map +1 -0
- package/ui/layouts/root-layout/index.android.d.ts +15 -0
- package/ui/layouts/root-layout/index.android.js +126 -0
- package/ui/layouts/root-layout/index.android.js.map +1 -0
- package/ui/layouts/root-layout/index.ios.d.ts +17 -0
- package/ui/layouts/root-layout/index.ios.js +101 -0
- package/ui/layouts/root-layout/index.ios.js.map +1 -0
- package/ui/layouts/root-layout/root-layout-common.d.ts +61 -0
- package/ui/layouts/root-layout/root-layout-common.js +425 -0
- package/ui/layouts/root-layout/root-layout-common.js.map +1 -0
- package/ui/layouts/root-layout/root-layout-stack.d.ts +5 -0
- package/ui/layouts/root-layout/root-layout-stack.js +19 -0
- package/ui/layouts/root-layout/root-layout-stack.js.map +1 -0
- package/ui/layouts/stack-layout/index.android.d.ts +7 -0
- package/ui/layouts/stack-layout/index.android.js +11 -0
- package/ui/layouts/stack-layout/index.android.js.map +1 -0
- package/ui/layouts/stack-layout/index.ios.d.ts +10 -0
- package/ui/layouts/stack-layout/index.ios.js +155 -0
- package/ui/layouts/stack-layout/index.ios.js.map +1 -0
- package/ui/layouts/stack-layout/stack-layout-common.d.ts +8 -0
- package/ui/layouts/stack-layout/stack-layout-common.js +19 -0
- package/ui/layouts/stack-layout/stack-layout-common.js.map +1 -0
- package/ui/layouts/wrap-layout/index.android.d.ts +10 -0
- package/ui/layouts/wrap-layout/index.android.js +18 -0
- package/ui/layouts/wrap-layout/index.android.js.map +1 -0
- package/ui/layouts/wrap-layout/index.ios.d.ts +8 -0
- package/ui/layouts/wrap-layout/index.ios.js +170 -0
- package/ui/layouts/wrap-layout/index.ios.js.map +1 -0
- package/ui/layouts/wrap-layout/wrap-layout-common.d.ts +15 -0
- package/ui/layouts/wrap-layout/wrap-layout-common.js +40 -0
- package/ui/layouts/wrap-layout/wrap-layout-common.js.map +1 -0
- package/ui/list-picker/index.android.d.ts +18 -0
- package/ui/list-picker/index.android.js +177 -0
- package/ui/list-picker/index.android.js.map +1 -0
- package/ui/list-picker/index.ios.d.ts +19 -0
- package/ui/list-picker/index.ios.js +99 -0
- package/ui/list-picker/index.ios.js.map +1 -0
- package/ui/list-picker/list-picker-common.d.ts +23 -0
- package/ui/list-picker/list-picker-common.js +78 -0
- package/ui/list-picker/list-picker-common.js.map +1 -0
- package/ui/list-view/index.android.d.ts +68 -0
- package/ui/list-view/index.android.js +1005 -0
- package/ui/list-view/index.android.js.map +1 -0
- package/ui/list-view/index.ios.d.ts +84 -0
- package/ui/list-view/index.ios.js +996 -0
- package/ui/list-view/index.ios.js.map +1 -0
- package/ui/list-view/list-view-common.d.ts +87 -0
- package/ui/list-view/list-view-common.js +296 -0
- package/ui/list-view/list-view-common.js.map +1 -0
- package/ui/page/events.d.ts +6 -0
- package/ui/page/events.js +7 -0
- package/ui/page/events.js.map +1 -0
- package/ui/page/index.android.d.ts +16 -0
- package/ui/page/index.android.js +106 -0
- package/ui/page/index.android.js.map +1 -0
- package/ui/page/index.ios.d.ts +52 -0
- package/ui/page/index.ios.js +515 -0
- package/ui/page/index.ios.js.map +1 -0
- package/ui/page/page-common.d.ts +73 -0
- package/ui/page/page-common.js +191 -0
- package/ui/page/page-common.js.map +1 -0
- package/ui/placeholder/index.android.d.ts +12 -0
- package/ui/placeholder/index.android.js +21 -0
- package/ui/placeholder/index.android.js.map +1 -0
- package/ui/placeholder/index.js +16 -0
- package/ui/placeholder/index.js.map +1 -0
- package/ui/placeholder/placeholder-common.d.ts +11 -0
- package/ui/placeholder/placeholder-common.js +2 -0
- package/ui/placeholder/placeholder-common.js.map +1 -0
- package/ui/progress/index.android.d.ts +18 -0
- package/ui/progress/index.android.js +65 -0
- package/ui/progress/index.android.js.map +1 -0
- package/ui/progress/index.ios.d.ts +19 -0
- package/ui/progress/index.ios.js +45 -0
- package/ui/progress/index.ios.js.map +1 -0
- package/ui/progress/progress-common.d.ts +15 -0
- package/ui/progress/progress-common.js +34 -0
- package/ui/progress/progress-common.js.map +1 -0
- package/ui/proxy-view-container/index.d.ts +33 -0
- package/ui/proxy-view-container/index.js +247 -0
- package/ui/proxy-view-container/index.js.map +1 -0
- package/ui/repeater/index.d.ts +67 -0
- package/ui/repeater/index.js +225 -0
- package/ui/repeater/index.js.map +1 -0
- package/ui/scroll-view/index.android.d.ts +27 -0
- package/ui/scroll-view/index.android.js +157 -0
- package/ui/scroll-view/index.android.js.map +1 -0
- package/ui/scroll-view/index.ios.d.ts +29 -0
- package/ui/scroll-view/index.ios.js +193 -0
- package/ui/scroll-view/index.ios.js.map +1 -0
- package/ui/scroll-view/scroll-view-common.d.ts +27 -0
- package/ui/scroll-view/scroll-view-common.js +93 -0
- package/ui/scroll-view/scroll-view-common.js.map +1 -0
- package/ui/search-bar/index.android.d.ts +44 -0
- package/ui/search-bar/index.android.js +260 -0
- package/ui/search-bar/index.android.js.map +1 -0
- package/ui/search-bar/index.ios.d.ts +36 -0
- package/ui/search-bar/index.ios.js +203 -0
- package/ui/search-bar/index.ios.js.map +1 -0
- package/ui/search-bar/search-bar-common.d.ts +19 -0
- package/ui/search-bar/search-bar-common.js +43 -0
- package/ui/search-bar/search-bar-common.js.map +1 -0
- package/ui/segmented-bar/index.android.d.ts +42 -0
- package/ui/segmented-bar/index.android.js +280 -0
- package/ui/segmented-bar/index.android.js.map +1 -0
- package/ui/segmented-bar/index.ios.d.ts +28 -0
- package/ui/segmented-bar/index.ios.js +141 -0
- package/ui/segmented-bar/index.ios.js.map +1 -0
- package/ui/segmented-bar/segmented-bar-common.d.ts +37 -0
- package/ui/segmented-bar/segmented-bar-common.js +146 -0
- package/ui/segmented-bar/segmented-bar-common.js.map +1 -0
- package/ui/slider/index.android.d.ts +32 -0
- package/ui/slider/index.android.js +123 -0
- package/ui/slider/index.android.js.map +1 -0
- package/ui/slider/index.ios.d.ts +34 -0
- package/ui/slider/index.ios.js +145 -0
- package/ui/slider/index.ios.js.map +1 -0
- package/ui/slider/slider-common.d.ts +27 -0
- package/ui/slider/slider-common.js +69 -0
- package/ui/slider/slider-common.js.map +1 -0
- package/ui/split-view/index.android.d.ts +3 -0
- package/ui/split-view/index.android.js +4 -0
- package/ui/split-view/index.android.js.map +1 -0
- package/ui/split-view/index.ios.d.ts +51 -0
- package/ui/split-view/index.ios.js +567 -0
- package/ui/split-view/index.ios.js.map +1 -0
- package/ui/split-view/split-view-common.d.ts +59 -0
- package/ui/split-view/split-view-common.js +127 -0
- package/ui/split-view/split-view-common.js.map +1 -0
- package/ui/styling/background-common.d.ts +78 -0
- package/ui/styling/background-common.js +241 -0
- package/ui/styling/background-common.js.map +1 -0
- package/ui/styling/background.android.d.ts +3 -0
- package/ui/styling/background.android.js +82 -0
- package/ui/styling/background.android.js.map +1 -0
- package/ui/styling/background.ios.d.ts +21 -0
- package/ui/styling/background.ios.js +1105 -0
- package/ui/styling/background.ios.js.map +1 -0
- package/ui/styling/box-shadow.d.ts +9 -0
- package/ui/styling/box-shadow.js +3 -0
- package/ui/styling/box-shadow.js.map +1 -0
- package/ui/styling/clip-path-function.d.ts +16 -0
- package/ui/styling/clip-path-function.js +25 -0
- package/ui/styling/clip-path-function.js.map +1 -0
- package/ui/styling/converters.d.ts +2 -0
- package/ui/styling/converters.js +41 -0
- package/ui/styling/converters.js.map +1 -0
- package/ui/styling/css-animation-parser.d.ts +14 -0
- package/ui/styling/css-animation-parser.js +187 -0
- package/ui/styling/css-animation-parser.js.map +1 -0
- package/ui/styling/css-selector.d.ts +270 -0
- package/ui/styling/css-selector.js +934 -0
- package/ui/styling/css-selector.js.map +1 -0
- package/ui/styling/css-shadow.d.ts +19 -0
- package/ui/styling/css-shadow.js +26 -0
- package/ui/styling/css-shadow.js.map +1 -0
- package/ui/styling/css-stroke.d.ts +12 -0
- package/ui/styling/css-stroke.js +19 -0
- package/ui/styling/css-stroke.js.map +1 -0
- package/ui/styling/css-transform.d.ts +2 -0
- package/ui/styling/css-transform.js +110 -0
- package/ui/styling/css-transform.js.map +1 -0
- package/ui/styling/css-utils.d.ts +8 -0
- package/ui/styling/css-utils.js +73 -0
- package/ui/styling/css-utils.js.map +1 -0
- package/ui/styling/font-common.d.ts +62 -0
- package/ui/styling/font-common.js +195 -0
- package/ui/styling/font-common.js.map +1 -0
- package/ui/styling/font-interfaces.d.ts +16 -0
- package/ui/styling/font-interfaces.js +2 -0
- package/ui/styling/font-interfaces.js.map +1 -0
- package/ui/styling/font.android.d.ts +15 -0
- package/ui/styling/font.android.js +226 -0
- package/ui/styling/font.android.js.map +1 -0
- package/ui/styling/font.ios.d.ts +18 -0
- package/ui/styling/font.ios.js +159 -0
- package/ui/styling/font.ios.js.map +1 -0
- package/ui/styling/length-shared.d.ts +52 -0
- package/ui/styling/length-shared.js +173 -0
- package/ui/styling/length-shared.js.map +1 -0
- package/ui/styling/linear-gradient.d.ts +13 -0
- package/ui/styling/linear-gradient.js +48 -0
- package/ui/styling/linear-gradient.js.map +1 -0
- package/ui/styling/style/index.d.ts +166 -0
- package/ui/styling/style/index.js +67 -0
- package/ui/styling/style/index.js.map +1 -0
- package/ui/styling/style-properties.d.ts +63 -0
- package/ui/styling/style-properties.js +1151 -0
- package/ui/styling/style-properties.js.map +1 -0
- package/ui/styling/style-scope.d.ts +87 -0
- package/ui/styling/style-scope.js +1020 -0
- package/ui/styling/style-scope.js.map +1 -0
- package/ui/styling/styling-profile.d.ts +1 -0
- package/ui/styling/styling-profile.js +4 -0
- package/ui/styling/styling-profile.js.map +1 -0
- package/ui/styling/styling-shared.d.ts +3 -0
- package/ui/styling/styling-shared.js +6 -0
- package/ui/styling/styling-shared.js.map +1 -0
- package/ui/switch/index.android.d.ts +23 -0
- package/ui/switch/index.android.js +111 -0
- package/ui/switch/index.android.js.map +1 -0
- package/ui/switch/index.ios.d.ts +26 -0
- package/ui/switch/index.ios.js +185 -0
- package/ui/switch/index.ios.js.map +1 -0
- package/ui/switch/switch-common.d.ts +12 -0
- package/ui/switch/switch-common.js +37 -0
- package/ui/switch/switch-common.js.map +1 -0
- package/ui/tab-view/index.android.d.ts +73 -0
- package/ui/tab-view/index.android.js +646 -0
- package/ui/tab-view/index.android.js.map +1 -0
- package/ui/tab-view/index.ios.d.ts +80 -0
- package/ui/tab-view/index.ios.js +877 -0
- package/ui/tab-view/index.ios.js.map +1 -0
- package/ui/tab-view/tab-view-common.d.ts +86 -0
- package/ui/tab-view/tab-view-common.js +277 -0
- package/ui/tab-view/tab-view-common.js.map +1 -0
- package/ui/text-base/formatted-string.js +163 -0
- package/ui/text-base/formatted-string.js.map +1 -0
- package/ui/text-base/index.android.d.ts +79 -0
- package/ui/text-base/index.android.js +589 -0
- package/ui/text-base/index.android.js.map +1 -0
- package/ui/text-base/index.ios.d.ts +53 -0
- package/ui/text-base/index.ios.js +452 -0
- package/ui/text-base/index.ios.js.map +1 -0
- package/ui/text-base/span.js +113 -0
- package/ui/text-base/span.js.map +1 -0
- package/ui/text-base/text-base-common.d.ts +99 -0
- package/ui/text-base/text-base-common.js +324 -0
- package/ui/text-base/text-base-common.js.map +1 -0
- package/ui/text-field/index.android.d.ts +10 -0
- package/ui/text-field/index.android.js +92 -0
- package/ui/text-field/index.android.js.map +1 -0
- package/ui/text-field/index.ios.d.ts +56 -0
- package/ui/text-field/index.ios.js +315 -0
- package/ui/text-field/index.ios.js.map +1 -0
- package/ui/text-field/text-field-common.d.ts +11 -0
- package/ui/text-field/text-field-common.js +25 -0
- package/ui/text-field/text-field-common.js.map +1 -0
- package/ui/text-view/index.android.d.ts +8 -0
- package/ui/text-view/index.android.js +24 -0
- package/ui/text-view/index.android.js.map +1 -0
- package/ui/text-view/index.ios.d.ts +59 -0
- package/ui/text-view/index.ios.js +432 -0
- package/ui/text-view/index.ios.js.map +1 -0
- package/ui/text-view/text-view-common.d.ts +32 -0
- package/ui/text-view/text-view-common.js +39 -0
- package/ui/text-view/text-view-common.js.map +1 -0
- package/ui/time-picker/index.android.d.ts +10 -0
- package/ui/time-picker/index.android.js +79 -0
- package/ui/time-picker/index.android.js.map +1 -0
- package/ui/time-picker/index.ios.d.ts +31 -0
- package/ui/time-picker/index.ios.js +138 -0
- package/ui/time-picker/index.ios.js.map +1 -0
- package/ui/time-picker/time-picker-common.d.ts +31 -0
- package/ui/time-picker/time-picker-common.js +176 -0
- package/ui/time-picker/time-picker-common.js.map +1 -0
- package/ui/transition/fade-transition.android.d.ts +4 -0
- package/ui/transition/fade-transition.android.js +28 -0
- package/ui/transition/fade-transition.android.js.map +1 -0
- package/ui/transition/fade-transition.ios.d.ts +17 -0
- package/ui/transition/fade-transition.ios.js +64 -0
- package/ui/transition/fade-transition.ios.js.map +1 -0
- package/ui/transition/flip-transition.android.d.ts +6 -0
- package/ui/transition/flip-transition.android.js +90 -0
- package/ui/transition/flip-transition.android.js.map +1 -0
- package/ui/transition/index.android.d.ts +19 -0
- package/ui/transition/index.android.js +37 -0
- package/ui/transition/index.android.js.map +1 -0
- package/ui/transition/index.ios.d.ts +14 -0
- package/ui/transition/index.ios.js +30 -0
- package/ui/transition/index.ios.js.map +1 -0
- package/ui/transition/modal-transition.android.d.ts +5 -0
- package/ui/transition/modal-transition.android.js +7 -0
- package/ui/transition/modal-transition.android.js.map +1 -0
- package/ui/transition/modal-transition.ios.d.ts +34 -0
- package/ui/transition/modal-transition.ios.js +175 -0
- package/ui/transition/modal-transition.ios.js.map +1 -0
- package/ui/transition/page-transition.android.d.ts +9 -0
- package/ui/transition/page-transition.android.js +284 -0
- package/ui/transition/page-transition.android.js.map +1 -0
- package/ui/transition/page-transition.ios.d.ts +35 -0
- package/ui/transition/page-transition.ios.js +193 -0
- package/ui/transition/page-transition.ios.js.map +1 -0
- package/ui/transition/shared-transition-helper.android.d.ts +9 -0
- package/ui/transition/shared-transition-helper.android.js +10 -0
- package/ui/transition/shared-transition-helper.android.js.map +1 -0
- package/ui/transition/shared-transition-helper.ios.d.ts +14 -0
- package/ui/transition/shared-transition-helper.ios.js +539 -0
- package/ui/transition/shared-transition-helper.ios.js.map +1 -0
- package/ui/transition/shared-transition.d.ts +271 -0
- package/ui/transition/shared-transition.js +215 -0
- package/ui/transition/shared-transition.js.map +1 -0
- package/ui/transition/slide-transition.android.d.ts +7 -0
- package/ui/transition/slide-transition.android.js +116 -0
- package/ui/transition/slide-transition.android.js.map +1 -0
- package/ui/transition/slide-transition.ios.d.ts +19 -0
- package/ui/transition/slide-transition.ios.js +94 -0
- package/ui/transition/slide-transition.ios.js.map +1 -0
- package/ui/utils.android.d.ts +5 -0
- package/ui/utils.android.js +16 -0
- package/ui/utils.android.js.map +1 -0
- package/ui/utils.ios.d.ts +11 -0
- package/ui/utils.ios.js +66 -0
- package/ui/utils.ios.js.map +1 -0
- package/ui/web-view/index.android.d.ts +18 -0
- package/ui/web-view/index.android.js +173 -0
- package/ui/web-view/index.android.js.map +1 -0
- package/ui/web-view/index.ios.d.ts +27 -0
- package/ui/web-view/index.ios.js +246 -0
- package/ui/web-view/index.ios.js.map +1 -0
- package/ui/web-view/web-view-common.d.ts +30 -0
- package/ui/web-view/web-view-common.js +74 -0
- package/ui/web-view/web-view-common.js.map +1 -0
- package/ui/web-view/web-view-interfaces.d.ts +11 -0
- package/ui/web-view/web-view-interfaces.js +2 -0
- package/ui/web-view/web-view-interfaces.js.map +1 -0
- package/utils/animation-helpers.d.ts +27 -0
- package/utils/animation-helpers.js +48 -0
- package/utils/animation-helpers.js.map +1 -0
- package/utils/common.d.ts +28 -0
- package/utils/common.js +158 -0
- package/utils/common.js.map +1 -0
- package/utils/constants.android.d.ts +2 -0
- package/utils/constants.android.js +5 -0
- package/utils/constants.android.js.map +1 -0
- package/utils/constants.ios.d.ts +2 -0
- package/utils/constants.ios.js +5 -0
- package/utils/constants.ios.js.map +1 -0
- package/utils/debug-source.d.ts +19 -0
- package/utils/debug-source.js +78 -0
- package/utils/debug-source.js.map +1 -0
- package/utils/debug.js +3 -0
- package/utils/debug.js.map +1 -0
- package/utils/index.android.d.ts +26 -0
- package/utils/index.android.js +205 -0
- package/utils/index.android.js.map +1 -0
- package/utils/index.ios.d.ts +22 -0
- package/utils/index.ios.js +113 -0
- package/utils/index.ios.js.map +1 -0
- package/utils/layout-helper/index.android.d.ts +25 -0
- package/utils/layout-helper/index.android.js +86 -0
- package/utils/layout-helper/index.android.js.map +1 -0
- package/utils/layout-helper/index.ios.d.ts +25 -0
- package/utils/layout-helper/index.ios.js +68 -0
- package/utils/layout-helper/index.ios.js.map +1 -0
- package/utils/layout-helper/layout-helper-common.d.ts +5 -0
- package/utils/layout-helper/layout-helper-common.js +49 -0
- package/utils/layout-helper/layout-helper-common.js.map +1 -0
- package/utils/layout-helper/layout-helper-shared.d.ts +9 -0
- package/utils/layout-helper/layout-helper-shared.js +13 -0
- package/utils/layout-helper/layout-helper-shared.js.map +1 -0
- package/utils/lazy.js +5 -0
- package/utils/lazy.js.map +1 -0
- package/utils/macrotask-scheduler.js +26 -0
- package/utils/macrotask-scheduler.js.map +1 -0
- package/utils/mainthread-helper.android.d.ts +3 -0
- package/utils/mainthread-helper.android.js +28 -0
- package/utils/mainthread-helper.android.js.map +1 -0
- package/utils/mainthread-helper.ios.d.ts +3 -0
- package/utils/mainthread-helper.ios.js +17 -0
- package/utils/mainthread-helper.ios.js.map +1 -0
- package/utils/module-merge.d.ts +1 -0
- package/utils/module-merge.js +8 -0
- package/utils/module-merge.js.map +1 -0
- package/utils/native-helper-for-android.d.ts +45 -0
- package/utils/native-helper-for-android.js +376 -0
- package/utils/native-helper-for-android.js.map +1 -0
- package/utils/native-helper.android.d.ts +42 -0
- package/utils/native-helper.android.js +30 -0
- package/utils/native-helper.android.js.map +1 -0
- package/utils/native-helper.ios.d.ts +79 -0
- package/utils/native-helper.ios.js +339 -0
- package/utils/native-helper.ios.js.map +1 -0
- package/utils/number-utils.d.ts +19 -0
- package/utils/number-utils.js +37 -0
- package/utils/number-utils.js.map +1 -0
- package/utils/platform-check.d.ts +4 -0
- package/utils/platform-check.js +21 -0
- package/utils/platform-check.js.map +1 -0
- package/utils/shared.d.ts +17 -0
- package/utils/shared.js +40 -0
- package/utils/shared.js.map +1 -0
- package/utils/types.js +104 -0
- package/utils/types.js.map +1 -0
- package/utils/utils-shared.d.ts +1 -0
- package/utils/utils-shared.js +8 -0
- package/utils/utils-shared.js.map +1 -0
- package/wgc/atob.d.ts +1 -0
- package/wgc/atob.js +9 -0
- package/wgc/atob.js.map +1 -0
- package/wgc/btoa.d.ts +1 -0
- package/wgc/btoa.js +9 -0
- package/wgc/btoa.js.map +1 -0
- package/wgc/crypto/SubtleCrypto.d.ts +63 -0
- package/wgc/crypto/SubtleCrypto.js +551 -0
- package/wgc/crypto/SubtleCrypto.js.map +1 -0
- package/wgc/crypto/index.d.ts +8 -0
- package/wgc/crypto/index.js +32 -0
- package/wgc/crypto/index.js.map +1 -0
- package/wgc/index.d.ts +2 -0
- package/wgc/index.js +3 -0
- package/wgc/index.js.map +1 -0
- package/xhr/index.d.ts +113 -0
- package/xhr/index.js +486 -0
- package/xhr/index.js.map +1 -0
- package/xml/index.d.ts +108 -0
- package/xml/index.js +574 -0
- package/xml/index.js.map +1 -0
- package/css/package.json +0 -36
- package/css-value/package.json +0 -23
|
@@ -0,0 +1,1151 @@
|
|
|
1
|
+
import { CssProperty, CssAnimationProperty, ShorthandProperty, InheritedCssProperty } from '../core/properties';
|
|
2
|
+
import { unsetValue, isCssWideKeyword } from '../core/properties/property-shared';
|
|
3
|
+
import { Style } from './style';
|
|
4
|
+
import { Color } from '../../color';
|
|
5
|
+
import { Font, parseFont, FontStyle, FontWeight, FontVariationSettings } from './font';
|
|
6
|
+
import { Background } from './background';
|
|
7
|
+
import { layout } from '../../utils';
|
|
8
|
+
import { Trace } from '../../trace';
|
|
9
|
+
import { CoreTypes } from '../../core-types';
|
|
10
|
+
import { Length, FixedLength, PercentLength } from './length-shared';
|
|
11
|
+
import { parseBackground } from '../../css/parser';
|
|
12
|
+
import { LinearGradient } from './linear-gradient';
|
|
13
|
+
import { parseCSSShadow } from './css-shadow';
|
|
14
|
+
import { transformConverter } from './css-transform';
|
|
15
|
+
import { ClipPathFunction } from './clip-path-function';
|
|
16
|
+
import { parseCSSCommaSeparatedListOfValues } from './css-utils';
|
|
17
|
+
function equalsCommon(a, b) {
|
|
18
|
+
if (a == 'auto' || isCssWideKeyword(a)) {
|
|
19
|
+
return b == 'auto' || isCssWideKeyword(b);
|
|
20
|
+
}
|
|
21
|
+
if (b == 'auto' || isCssWideKeyword(b)) {
|
|
22
|
+
return false;
|
|
23
|
+
}
|
|
24
|
+
if (typeof a === 'number') {
|
|
25
|
+
if (typeof b === 'number') {
|
|
26
|
+
return a == b;
|
|
27
|
+
}
|
|
28
|
+
if (!b) {
|
|
29
|
+
return false;
|
|
30
|
+
}
|
|
31
|
+
return b.unit == 'dip' && a == b.value;
|
|
32
|
+
}
|
|
33
|
+
if (typeof b === 'number') {
|
|
34
|
+
return a ? a.unit == 'dip' && a.value == b : false;
|
|
35
|
+
}
|
|
36
|
+
if (!a || !b) {
|
|
37
|
+
return false;
|
|
38
|
+
}
|
|
39
|
+
return a.value == b.value && a.unit == b.unit;
|
|
40
|
+
}
|
|
41
|
+
function convertToStringCommon(length) {
|
|
42
|
+
if (length == 'auto' || isCssWideKeyword(length)) {
|
|
43
|
+
return 'auto';
|
|
44
|
+
}
|
|
45
|
+
if (typeof length === 'number') {
|
|
46
|
+
return length.toString();
|
|
47
|
+
}
|
|
48
|
+
let val = length.value;
|
|
49
|
+
if (length.unit === '%') {
|
|
50
|
+
val *= 100;
|
|
51
|
+
}
|
|
52
|
+
return val + length.unit;
|
|
53
|
+
}
|
|
54
|
+
function toDevicePixelsCommon(length, auto = Number.NaN, parentAvailableWidth = Number.NaN) {
|
|
55
|
+
if (length == 'auto' || isCssWideKeyword(length)) {
|
|
56
|
+
return auto;
|
|
57
|
+
}
|
|
58
|
+
if (typeof length === 'number') {
|
|
59
|
+
return layout.round(layout.toDevicePixels(length));
|
|
60
|
+
}
|
|
61
|
+
if (!length) {
|
|
62
|
+
return auto;
|
|
63
|
+
}
|
|
64
|
+
// @ts-ignore
|
|
65
|
+
switch (length.unit) {
|
|
66
|
+
case 'px':
|
|
67
|
+
// @ts-ignore
|
|
68
|
+
return layout.round(length.value);
|
|
69
|
+
case '%':
|
|
70
|
+
// @ts-ignore
|
|
71
|
+
return layout.round(parentAvailableWidth * length.value);
|
|
72
|
+
case 'dip':
|
|
73
|
+
default:
|
|
74
|
+
// @ts-ignore
|
|
75
|
+
return layout.round(layout.toDevicePixels(length.value));
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
function isNonNegativeFiniteNumber(value) {
|
|
79
|
+
return isFinite(value) && !isNaN(value) && value >= 0;
|
|
80
|
+
}
|
|
81
|
+
function parseClipPath(value) {
|
|
82
|
+
const funcStartIndex = value.indexOf('(');
|
|
83
|
+
const funcEndIndex = value.lastIndexOf(')');
|
|
84
|
+
if (funcStartIndex > -1 && funcEndIndex > -1) {
|
|
85
|
+
const functionName = value.substring(0, funcStartIndex).trim();
|
|
86
|
+
switch (functionName) {
|
|
87
|
+
case 'rect':
|
|
88
|
+
case 'circle':
|
|
89
|
+
case 'ellipse':
|
|
90
|
+
case 'polygon':
|
|
91
|
+
case 'inset': {
|
|
92
|
+
return new ClipPathFunction(functionName, value.substring(funcStartIndex + 1, funcEndIndex));
|
|
93
|
+
}
|
|
94
|
+
default:
|
|
95
|
+
throw new Error(`Clip-path function ${functionName} is not valid.`);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
else {
|
|
99
|
+
if (value === 'none') {
|
|
100
|
+
return null;
|
|
101
|
+
}
|
|
102
|
+
// Only shape functions and none are supported for now
|
|
103
|
+
throw new Error(`Clip-path value ${value} is not valid.`);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
function parseShorthandPositioning(value) {
|
|
107
|
+
const arr = value.split(/[ ,]+/);
|
|
108
|
+
let top;
|
|
109
|
+
let right;
|
|
110
|
+
let bottom;
|
|
111
|
+
let left;
|
|
112
|
+
if (arr.length === 1) {
|
|
113
|
+
top = arr[0];
|
|
114
|
+
right = arr[0];
|
|
115
|
+
bottom = arr[0];
|
|
116
|
+
left = arr[0];
|
|
117
|
+
}
|
|
118
|
+
else if (arr.length === 2) {
|
|
119
|
+
top = arr[0];
|
|
120
|
+
bottom = arr[0];
|
|
121
|
+
right = arr[1];
|
|
122
|
+
left = arr[1];
|
|
123
|
+
}
|
|
124
|
+
else if (arr.length === 3) {
|
|
125
|
+
top = arr[0];
|
|
126
|
+
right = arr[1];
|
|
127
|
+
left = arr[1];
|
|
128
|
+
bottom = arr[2];
|
|
129
|
+
}
|
|
130
|
+
else if (arr.length === 4) {
|
|
131
|
+
top = arr[0];
|
|
132
|
+
right = arr[1];
|
|
133
|
+
bottom = arr[2];
|
|
134
|
+
left = arr[3];
|
|
135
|
+
}
|
|
136
|
+
else {
|
|
137
|
+
throw new Error('Expected 1, 2, 3 or 4 parameters. Actual: ' + value);
|
|
138
|
+
}
|
|
139
|
+
return {
|
|
140
|
+
top: top,
|
|
141
|
+
right: right,
|
|
142
|
+
bottom: bottom,
|
|
143
|
+
left: left,
|
|
144
|
+
};
|
|
145
|
+
}
|
|
146
|
+
function parseBorderColorPositioning(value) {
|
|
147
|
+
if (value.indexOf('rgb') === 0 || value.indexOf('hsl') === 0) {
|
|
148
|
+
return {
|
|
149
|
+
top: value,
|
|
150
|
+
right: value,
|
|
151
|
+
bottom: value,
|
|
152
|
+
left: value,
|
|
153
|
+
};
|
|
154
|
+
}
|
|
155
|
+
return parseShorthandPositioning(value);
|
|
156
|
+
}
|
|
157
|
+
function convertToBackgrounds(value) {
|
|
158
|
+
if (typeof value === 'string') {
|
|
159
|
+
const backgrounds = parseBackground(value).value;
|
|
160
|
+
let backgroundColor = unsetValue;
|
|
161
|
+
if (backgrounds.color) {
|
|
162
|
+
backgroundColor = backgrounds.color instanceof Color ? backgrounds.color : new Color(backgrounds.color);
|
|
163
|
+
}
|
|
164
|
+
let backgroundImage;
|
|
165
|
+
if (typeof backgrounds.image === 'object' && backgrounds.image) {
|
|
166
|
+
backgroundImage = LinearGradient.parse(backgrounds.image);
|
|
167
|
+
}
|
|
168
|
+
else {
|
|
169
|
+
backgroundImage = backgrounds.image || unsetValue;
|
|
170
|
+
}
|
|
171
|
+
const backgroundRepeat = backgrounds.repeat || unsetValue;
|
|
172
|
+
const backgroundPosition = backgrounds.position ? backgrounds.position.text : unsetValue;
|
|
173
|
+
return [
|
|
174
|
+
[backgroundColorProperty, backgroundColor],
|
|
175
|
+
[backgroundImageProperty, backgroundImage],
|
|
176
|
+
[backgroundRepeatProperty, backgroundRepeat],
|
|
177
|
+
[backgroundPositionProperty, backgroundPosition],
|
|
178
|
+
];
|
|
179
|
+
}
|
|
180
|
+
else {
|
|
181
|
+
return [
|
|
182
|
+
[backgroundColorProperty, unsetValue],
|
|
183
|
+
[backgroundImageProperty, unsetValue],
|
|
184
|
+
[backgroundRepeatProperty, unsetValue],
|
|
185
|
+
[backgroundPositionProperty, unsetValue],
|
|
186
|
+
];
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
function convertToMargins(value) {
|
|
190
|
+
if (typeof value === 'string' && value !== 'auto') {
|
|
191
|
+
const thickness = parseShorthandPositioning(value);
|
|
192
|
+
return [
|
|
193
|
+
[marginTopProperty, PercentLength.parse(thickness.top)],
|
|
194
|
+
[marginRightProperty, PercentLength.parse(thickness.right)],
|
|
195
|
+
[marginBottomProperty, PercentLength.parse(thickness.bottom)],
|
|
196
|
+
[marginLeftProperty, PercentLength.parse(thickness.left)],
|
|
197
|
+
];
|
|
198
|
+
}
|
|
199
|
+
else {
|
|
200
|
+
return [
|
|
201
|
+
[marginTopProperty, value],
|
|
202
|
+
[marginRightProperty, value],
|
|
203
|
+
[marginBottomProperty, value],
|
|
204
|
+
[marginLeftProperty, value],
|
|
205
|
+
];
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
function convertToPaddings(value) {
|
|
209
|
+
if (typeof value === 'string' && value !== 'auto') {
|
|
210
|
+
const thickness = parseShorthandPositioning(value);
|
|
211
|
+
return [
|
|
212
|
+
[paddingTopProperty, Length.parse(thickness.top)],
|
|
213
|
+
[paddingRightProperty, Length.parse(thickness.right)],
|
|
214
|
+
[paddingBottomProperty, Length.parse(thickness.bottom)],
|
|
215
|
+
[paddingLeftProperty, Length.parse(thickness.left)],
|
|
216
|
+
];
|
|
217
|
+
}
|
|
218
|
+
else {
|
|
219
|
+
return [
|
|
220
|
+
[paddingTopProperty, value],
|
|
221
|
+
[paddingRightProperty, value],
|
|
222
|
+
[paddingBottomProperty, value],
|
|
223
|
+
[paddingLeftProperty, value],
|
|
224
|
+
];
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
function convertToTransform(value) {
|
|
228
|
+
if (value === unsetValue) {
|
|
229
|
+
value = 'none';
|
|
230
|
+
}
|
|
231
|
+
const { translate, rotate, scale } = transformConverter(value);
|
|
232
|
+
return [
|
|
233
|
+
[translateXProperty, translate.x],
|
|
234
|
+
[translateYProperty, translate.y],
|
|
235
|
+
[scaleXProperty, scale.x],
|
|
236
|
+
[scaleYProperty, scale.y],
|
|
237
|
+
[rotateProperty, rotate.z],
|
|
238
|
+
[rotateXProperty, rotate.x],
|
|
239
|
+
[rotateYProperty, rotate.y],
|
|
240
|
+
];
|
|
241
|
+
}
|
|
242
|
+
export const minWidthProperty = new CssProperty({
|
|
243
|
+
name: 'minWidth',
|
|
244
|
+
cssName: 'min-width',
|
|
245
|
+
defaultValue: CoreTypes.zeroLength,
|
|
246
|
+
affectsLayout: global.isIOS,
|
|
247
|
+
equalityComparer: Length.equals,
|
|
248
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
249
|
+
const view = target.viewRef.get();
|
|
250
|
+
if (view) {
|
|
251
|
+
view.effectiveMinWidth = Length.toDevicePixels(newValue, 0);
|
|
252
|
+
}
|
|
253
|
+
else {
|
|
254
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
255
|
+
}
|
|
256
|
+
},
|
|
257
|
+
valueConverter: Length.parse,
|
|
258
|
+
});
|
|
259
|
+
minWidthProperty.register(Style);
|
|
260
|
+
export const minHeightProperty = new CssProperty({
|
|
261
|
+
name: 'minHeight',
|
|
262
|
+
cssName: 'min-height',
|
|
263
|
+
defaultValue: CoreTypes.zeroLength,
|
|
264
|
+
affectsLayout: global.isIOS,
|
|
265
|
+
equalityComparer: Length.equals,
|
|
266
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
267
|
+
const view = target.viewRef.get();
|
|
268
|
+
if (view) {
|
|
269
|
+
view.effectiveMinHeight = Length.toDevicePixels(newValue, 0);
|
|
270
|
+
}
|
|
271
|
+
else {
|
|
272
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
273
|
+
}
|
|
274
|
+
},
|
|
275
|
+
valueConverter: Length.parse,
|
|
276
|
+
});
|
|
277
|
+
minHeightProperty.register(Style);
|
|
278
|
+
export const widthProperty = new CssAnimationProperty({
|
|
279
|
+
name: 'width',
|
|
280
|
+
cssName: 'width',
|
|
281
|
+
defaultValue: 'auto',
|
|
282
|
+
equalityComparer: Length.equals,
|
|
283
|
+
// TODO: CSSAnimationProperty was needed for keyframe (copying other impls), but `affectsLayout` does not exist
|
|
284
|
+
// on the animation property, so fake it here. x_x
|
|
285
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
286
|
+
if (global.isIOS) {
|
|
287
|
+
const view = target.viewRef.get();
|
|
288
|
+
if (view) {
|
|
289
|
+
view.requestLayout();
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
},
|
|
293
|
+
valueConverter: PercentLength.parse,
|
|
294
|
+
});
|
|
295
|
+
widthProperty.register(Style);
|
|
296
|
+
export const heightProperty = new CssAnimationProperty({
|
|
297
|
+
name: 'height',
|
|
298
|
+
cssName: 'height',
|
|
299
|
+
defaultValue: 'auto',
|
|
300
|
+
equalityComparer: Length.equals,
|
|
301
|
+
// TODO: CSSAnimationProperty was needed for keyframe (copying other impls), but `affectsLayout` does not exist
|
|
302
|
+
// on the animation property, so fake it here. -_-
|
|
303
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
304
|
+
if (global.isIOS) {
|
|
305
|
+
const view = target.viewRef.get();
|
|
306
|
+
if (view) {
|
|
307
|
+
view.requestLayout();
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
valueConverter: PercentLength.parse,
|
|
312
|
+
});
|
|
313
|
+
heightProperty.register(Style);
|
|
314
|
+
const marginProperty = new ShorthandProperty({
|
|
315
|
+
name: 'margin',
|
|
316
|
+
cssName: 'margin',
|
|
317
|
+
getter: function () {
|
|
318
|
+
if (PercentLength.equals(this.marginTop, this.marginRight) && PercentLength.equals(this.marginTop, this.marginBottom) && PercentLength.equals(this.marginTop, this.marginLeft)) {
|
|
319
|
+
return this.marginTop;
|
|
320
|
+
}
|
|
321
|
+
return `${PercentLength.convertToString(this.marginTop)} ${PercentLength.convertToString(this.marginRight)} ${PercentLength.convertToString(this.marginBottom)} ${PercentLength.convertToString(this.marginLeft)}`;
|
|
322
|
+
},
|
|
323
|
+
converter: convertToMargins,
|
|
324
|
+
});
|
|
325
|
+
marginProperty.register(Style);
|
|
326
|
+
export const marginLeftProperty = new CssProperty({
|
|
327
|
+
name: 'marginLeft',
|
|
328
|
+
cssName: 'margin-left',
|
|
329
|
+
defaultValue: CoreTypes.zeroLength,
|
|
330
|
+
affectsLayout: global.isIOS,
|
|
331
|
+
equalityComparer: Length.equals,
|
|
332
|
+
valueConverter: PercentLength.parse,
|
|
333
|
+
});
|
|
334
|
+
marginLeftProperty.register(Style);
|
|
335
|
+
export const marginRightProperty = new CssProperty({
|
|
336
|
+
name: 'marginRight',
|
|
337
|
+
cssName: 'margin-right',
|
|
338
|
+
defaultValue: CoreTypes.zeroLength,
|
|
339
|
+
affectsLayout: global.isIOS,
|
|
340
|
+
equalityComparer: Length.equals,
|
|
341
|
+
valueConverter: PercentLength.parse,
|
|
342
|
+
});
|
|
343
|
+
marginRightProperty.register(Style);
|
|
344
|
+
export const marginTopProperty = new CssProperty({
|
|
345
|
+
name: 'marginTop',
|
|
346
|
+
cssName: 'margin-top',
|
|
347
|
+
defaultValue: CoreTypes.zeroLength,
|
|
348
|
+
affectsLayout: global.isIOS,
|
|
349
|
+
equalityComparer: Length.equals,
|
|
350
|
+
valueConverter: PercentLength.parse,
|
|
351
|
+
});
|
|
352
|
+
marginTopProperty.register(Style);
|
|
353
|
+
export const marginBottomProperty = new CssProperty({
|
|
354
|
+
name: 'marginBottom',
|
|
355
|
+
cssName: 'margin-bottom',
|
|
356
|
+
defaultValue: CoreTypes.zeroLength,
|
|
357
|
+
affectsLayout: global.isIOS,
|
|
358
|
+
equalityComparer: Length.equals,
|
|
359
|
+
valueConverter: PercentLength.parse,
|
|
360
|
+
});
|
|
361
|
+
marginBottomProperty.register(Style);
|
|
362
|
+
const paddingProperty = new ShorthandProperty({
|
|
363
|
+
name: 'padding',
|
|
364
|
+
cssName: 'padding',
|
|
365
|
+
getter: function () {
|
|
366
|
+
if (Length.equals(this.paddingTop, this.paddingRight) && Length.equals(this.paddingTop, this.paddingBottom) && Length.equals(this.paddingTop, this.paddingLeft)) {
|
|
367
|
+
return this.paddingTop;
|
|
368
|
+
}
|
|
369
|
+
return `${Length.convertToString(this.paddingTop)} ${Length.convertToString(this.paddingRight)} ${Length.convertToString(this.paddingBottom)} ${Length.convertToString(this.paddingLeft)}`;
|
|
370
|
+
},
|
|
371
|
+
converter: convertToPaddings,
|
|
372
|
+
});
|
|
373
|
+
paddingProperty.register(Style);
|
|
374
|
+
export const paddingLeftProperty = new CssProperty({
|
|
375
|
+
name: 'paddingLeft',
|
|
376
|
+
cssName: 'padding-left',
|
|
377
|
+
defaultValue: CoreTypes.zeroLength,
|
|
378
|
+
affectsLayout: global.isIOS,
|
|
379
|
+
equalityComparer: Length.equals,
|
|
380
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
381
|
+
const view = target.viewRef.get();
|
|
382
|
+
if (view) {
|
|
383
|
+
view.effectivePaddingLeft = Length.toDevicePixels(newValue, 0);
|
|
384
|
+
}
|
|
385
|
+
else {
|
|
386
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
valueConverter: Length.parse,
|
|
390
|
+
});
|
|
391
|
+
paddingLeftProperty.register(Style);
|
|
392
|
+
export const paddingRightProperty = new CssProperty({
|
|
393
|
+
name: 'paddingRight',
|
|
394
|
+
cssName: 'padding-right',
|
|
395
|
+
defaultValue: CoreTypes.zeroLength,
|
|
396
|
+
affectsLayout: global.isIOS,
|
|
397
|
+
equalityComparer: Length.equals,
|
|
398
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
399
|
+
const view = target.viewRef.get();
|
|
400
|
+
if (view) {
|
|
401
|
+
view.effectivePaddingRight = Length.toDevicePixels(newValue, 0);
|
|
402
|
+
}
|
|
403
|
+
else {
|
|
404
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
405
|
+
}
|
|
406
|
+
},
|
|
407
|
+
valueConverter: Length.parse,
|
|
408
|
+
});
|
|
409
|
+
paddingRightProperty.register(Style);
|
|
410
|
+
export const paddingTopProperty = new CssProperty({
|
|
411
|
+
name: 'paddingTop',
|
|
412
|
+
cssName: 'padding-top',
|
|
413
|
+
defaultValue: CoreTypes.zeroLength,
|
|
414
|
+
affectsLayout: global.isIOS,
|
|
415
|
+
equalityComparer: Length.equals,
|
|
416
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
417
|
+
const view = target.viewRef.get();
|
|
418
|
+
if (view) {
|
|
419
|
+
view.effectivePaddingTop = Length.toDevicePixels(newValue, 0);
|
|
420
|
+
}
|
|
421
|
+
else {
|
|
422
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
423
|
+
}
|
|
424
|
+
},
|
|
425
|
+
valueConverter: Length.parse,
|
|
426
|
+
});
|
|
427
|
+
paddingTopProperty.register(Style);
|
|
428
|
+
export const paddingBottomProperty = new CssProperty({
|
|
429
|
+
name: 'paddingBottom',
|
|
430
|
+
cssName: 'padding-bottom',
|
|
431
|
+
defaultValue: CoreTypes.zeroLength,
|
|
432
|
+
affectsLayout: global.isIOS,
|
|
433
|
+
equalityComparer: Length.equals,
|
|
434
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
435
|
+
const view = target.viewRef.get();
|
|
436
|
+
if (view) {
|
|
437
|
+
view.effectivePaddingBottom = Length.toDevicePixels(newValue, 0);
|
|
438
|
+
}
|
|
439
|
+
else {
|
|
440
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
441
|
+
}
|
|
442
|
+
},
|
|
443
|
+
valueConverter: Length.parse,
|
|
444
|
+
});
|
|
445
|
+
paddingBottomProperty.register(Style);
|
|
446
|
+
export const horizontalAlignmentProperty = new CssProperty({
|
|
447
|
+
name: 'horizontalAlignment',
|
|
448
|
+
cssName: 'horizontal-align',
|
|
449
|
+
defaultValue: CoreTypes.HorizontalAlignment.stretch,
|
|
450
|
+
affectsLayout: global.isIOS,
|
|
451
|
+
valueConverter: CoreTypes.HorizontalAlignment.parse,
|
|
452
|
+
});
|
|
453
|
+
horizontalAlignmentProperty.register(Style);
|
|
454
|
+
export const verticalAlignmentProperty = new CssProperty({
|
|
455
|
+
name: 'verticalAlignment',
|
|
456
|
+
cssName: 'vertical-align',
|
|
457
|
+
defaultValue: CoreTypes.VerticalAlignmentText.stretch,
|
|
458
|
+
affectsLayout: global.isIOS,
|
|
459
|
+
valueConverter: CoreTypes.VerticalAlignmentText.parse,
|
|
460
|
+
});
|
|
461
|
+
verticalAlignmentProperty.register(Style);
|
|
462
|
+
export const rotateProperty = new CssAnimationProperty({
|
|
463
|
+
name: 'rotate',
|
|
464
|
+
cssName: 'rotate',
|
|
465
|
+
defaultValue: 0,
|
|
466
|
+
valueConverter: parseFloat,
|
|
467
|
+
});
|
|
468
|
+
rotateProperty.register(Style);
|
|
469
|
+
export const rotateXProperty = new CssAnimationProperty({
|
|
470
|
+
name: 'rotateX',
|
|
471
|
+
cssName: 'rotatex',
|
|
472
|
+
defaultValue: 0,
|
|
473
|
+
valueConverter: parseFloat,
|
|
474
|
+
});
|
|
475
|
+
rotateXProperty.register(Style);
|
|
476
|
+
export const rotateYProperty = new CssAnimationProperty({
|
|
477
|
+
name: 'rotateY',
|
|
478
|
+
cssName: 'rotatey',
|
|
479
|
+
defaultValue: 0,
|
|
480
|
+
valueConverter: parseFloat,
|
|
481
|
+
});
|
|
482
|
+
rotateYProperty.register(Style);
|
|
483
|
+
export const perspectiveProperty = new CssAnimationProperty({
|
|
484
|
+
name: 'perspective',
|
|
485
|
+
cssName: 'perspective',
|
|
486
|
+
defaultValue: 1000,
|
|
487
|
+
valueConverter: parseFloat,
|
|
488
|
+
});
|
|
489
|
+
perspectiveProperty.register(Style);
|
|
490
|
+
export const scaleXProperty = new CssAnimationProperty({
|
|
491
|
+
name: 'scaleX',
|
|
492
|
+
cssName: 'scaleX',
|
|
493
|
+
defaultValue: 1,
|
|
494
|
+
valueConverter: parseFloat,
|
|
495
|
+
});
|
|
496
|
+
scaleXProperty.register(Style);
|
|
497
|
+
export const scaleYProperty = new CssAnimationProperty({
|
|
498
|
+
name: 'scaleY',
|
|
499
|
+
cssName: 'scaleY',
|
|
500
|
+
defaultValue: 1,
|
|
501
|
+
valueConverter: parseFloat,
|
|
502
|
+
});
|
|
503
|
+
scaleYProperty.register(Style);
|
|
504
|
+
export const translateXProperty = new CssAnimationProperty({
|
|
505
|
+
name: 'translateX',
|
|
506
|
+
cssName: 'translateX',
|
|
507
|
+
defaultValue: 0,
|
|
508
|
+
equalityComparer: FixedLength.equals,
|
|
509
|
+
valueConverter: FixedLength.parse,
|
|
510
|
+
});
|
|
511
|
+
translateXProperty.register(Style);
|
|
512
|
+
export const translateYProperty = new CssAnimationProperty({
|
|
513
|
+
name: 'translateY',
|
|
514
|
+
cssName: 'translateY',
|
|
515
|
+
defaultValue: 0,
|
|
516
|
+
equalityComparer: FixedLength.equals,
|
|
517
|
+
valueConverter: FixedLength.parse,
|
|
518
|
+
});
|
|
519
|
+
translateYProperty.register(Style);
|
|
520
|
+
const transformProperty = new ShorthandProperty({
|
|
521
|
+
name: 'transform',
|
|
522
|
+
cssName: 'transform',
|
|
523
|
+
getter: function () {
|
|
524
|
+
const scaleX = this.scaleX;
|
|
525
|
+
const scaleY = this.scaleY;
|
|
526
|
+
const translateX = this.translateX;
|
|
527
|
+
const translateY = this.translateY;
|
|
528
|
+
const rotate = this.rotate;
|
|
529
|
+
const rotateX = this.rotateX;
|
|
530
|
+
const rotateY = this.rotateY;
|
|
531
|
+
let result = '';
|
|
532
|
+
if (translateX !== 0 || translateY !== 0) {
|
|
533
|
+
result += `translate(${translateX}, ${translateY}) `;
|
|
534
|
+
}
|
|
535
|
+
if (scaleX !== 1 || scaleY !== 1) {
|
|
536
|
+
result += `scale(${scaleX}, ${scaleY}) `;
|
|
537
|
+
}
|
|
538
|
+
if (rotateX !== 0 || rotateY !== 0 || rotate !== 0) {
|
|
539
|
+
result += `rotate(${rotateX}, ${rotateY}, ${rotate}) `;
|
|
540
|
+
result += `rotate (${rotate})`;
|
|
541
|
+
}
|
|
542
|
+
return result.trim();
|
|
543
|
+
},
|
|
544
|
+
converter: convertToTransform,
|
|
545
|
+
});
|
|
546
|
+
transformProperty.register(Style);
|
|
547
|
+
// Background properties.
|
|
548
|
+
const backgroundProperty = new ShorthandProperty({
|
|
549
|
+
name: 'background',
|
|
550
|
+
cssName: 'background',
|
|
551
|
+
getter: function () {
|
|
552
|
+
return `${this.backgroundColor} ${this.backgroundImage} ${this.backgroundRepeat} ${this.backgroundPosition}`;
|
|
553
|
+
},
|
|
554
|
+
converter: convertToBackgrounds,
|
|
555
|
+
});
|
|
556
|
+
backgroundProperty.register(Style);
|
|
557
|
+
export const backgroundInternalProperty = new CssProperty({
|
|
558
|
+
name: 'backgroundInternal',
|
|
559
|
+
cssName: '_backgroundInternal',
|
|
560
|
+
defaultValue: Background.default,
|
|
561
|
+
});
|
|
562
|
+
backgroundInternalProperty.register(Style);
|
|
563
|
+
export const backgroundImageProperty = new CssProperty({
|
|
564
|
+
name: 'backgroundImage',
|
|
565
|
+
cssName: 'background-image',
|
|
566
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
567
|
+
target.backgroundInternal = target.backgroundInternal.withImage(newValue);
|
|
568
|
+
},
|
|
569
|
+
equalityComparer: (value1, value2) => {
|
|
570
|
+
if (value1 instanceof LinearGradient && value2 instanceof LinearGradient) {
|
|
571
|
+
return LinearGradient.equals(value1, value2);
|
|
572
|
+
}
|
|
573
|
+
else {
|
|
574
|
+
return value1 === value2;
|
|
575
|
+
}
|
|
576
|
+
},
|
|
577
|
+
valueConverter: (value) => {
|
|
578
|
+
if (typeof value === 'string') {
|
|
579
|
+
const parsed = parseBackground(value);
|
|
580
|
+
if (parsed) {
|
|
581
|
+
value = typeof parsed.value.image === 'object' ? LinearGradient.parse(parsed.value.image) : value;
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
return value;
|
|
585
|
+
},
|
|
586
|
+
});
|
|
587
|
+
backgroundImageProperty.register(Style);
|
|
588
|
+
export const backgroundColorProperty = new CssAnimationProperty({
|
|
589
|
+
name: 'backgroundColor',
|
|
590
|
+
cssName: 'background-color',
|
|
591
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
592
|
+
target.backgroundInternal = target.backgroundInternal.withColor(newValue);
|
|
593
|
+
},
|
|
594
|
+
equalityComparer: Color.equals,
|
|
595
|
+
valueConverter: (value) => new Color(value),
|
|
596
|
+
});
|
|
597
|
+
backgroundColorProperty.register(Style);
|
|
598
|
+
export const backgroundRepeatProperty = new CssProperty({
|
|
599
|
+
name: 'backgroundRepeat',
|
|
600
|
+
cssName: 'background-repeat',
|
|
601
|
+
valueConverter: CoreTypes.BackgroundRepeat.parse,
|
|
602
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
603
|
+
target.backgroundInternal = target.backgroundInternal.withRepeat(newValue);
|
|
604
|
+
},
|
|
605
|
+
});
|
|
606
|
+
backgroundRepeatProperty.register(Style);
|
|
607
|
+
export const backgroundSizeProperty = new CssProperty({
|
|
608
|
+
name: 'backgroundSize',
|
|
609
|
+
cssName: 'background-size',
|
|
610
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
611
|
+
target.backgroundInternal = target.backgroundInternal.withSize(newValue);
|
|
612
|
+
},
|
|
613
|
+
});
|
|
614
|
+
backgroundSizeProperty.register(Style);
|
|
615
|
+
export const backgroundPositionProperty = new CssProperty({
|
|
616
|
+
name: 'backgroundPosition',
|
|
617
|
+
cssName: 'background-position',
|
|
618
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
619
|
+
target.backgroundInternal = target.backgroundInternal.withPosition(newValue);
|
|
620
|
+
},
|
|
621
|
+
});
|
|
622
|
+
backgroundPositionProperty.register(Style);
|
|
623
|
+
// Border Color properties.
|
|
624
|
+
const borderColorProperty = new ShorthandProperty({
|
|
625
|
+
name: 'borderColor',
|
|
626
|
+
cssName: 'border-color',
|
|
627
|
+
getter: function () {
|
|
628
|
+
if (Color.equals(this.borderTopColor, this.borderRightColor) && Color.equals(this.borderTopColor, this.borderBottomColor) && Color.equals(this.borderTopColor, this.borderLeftColor)) {
|
|
629
|
+
return this.borderTopColor;
|
|
630
|
+
}
|
|
631
|
+
else {
|
|
632
|
+
return `${this.borderTopColor} ${this.borderRightColor} ${this.borderBottomColor} ${this.borderLeftColor}`;
|
|
633
|
+
}
|
|
634
|
+
},
|
|
635
|
+
converter: function (value) {
|
|
636
|
+
if (typeof value === 'string') {
|
|
637
|
+
const colors = parseBorderColorPositioning(value);
|
|
638
|
+
return [
|
|
639
|
+
[borderTopColorProperty, new Color(colors.top)],
|
|
640
|
+
[borderRightColorProperty, new Color(colors.right)],
|
|
641
|
+
[borderBottomColorProperty, new Color(colors.bottom)],
|
|
642
|
+
[borderLeftColorProperty, new Color(colors.left)],
|
|
643
|
+
];
|
|
644
|
+
}
|
|
645
|
+
else {
|
|
646
|
+
return [
|
|
647
|
+
[borderTopColorProperty, value],
|
|
648
|
+
[borderRightColorProperty, value],
|
|
649
|
+
[borderBottomColorProperty, value],
|
|
650
|
+
[borderLeftColorProperty, value],
|
|
651
|
+
];
|
|
652
|
+
}
|
|
653
|
+
},
|
|
654
|
+
});
|
|
655
|
+
borderColorProperty.register(Style);
|
|
656
|
+
export const borderTopColorProperty = new CssProperty({
|
|
657
|
+
name: 'borderTopColor',
|
|
658
|
+
cssName: 'border-top-color',
|
|
659
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
660
|
+
target.backgroundInternal = target.backgroundInternal.withBorderTopColor(newValue);
|
|
661
|
+
},
|
|
662
|
+
equalityComparer: Color.equals,
|
|
663
|
+
valueConverter: (value) => new Color(value),
|
|
664
|
+
});
|
|
665
|
+
borderTopColorProperty.register(Style);
|
|
666
|
+
export const borderRightColorProperty = new CssProperty({
|
|
667
|
+
name: 'borderRightColor',
|
|
668
|
+
cssName: 'border-right-color',
|
|
669
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
670
|
+
target.backgroundInternal = target.backgroundInternal.withBorderRightColor(newValue);
|
|
671
|
+
},
|
|
672
|
+
equalityComparer: Color.equals,
|
|
673
|
+
valueConverter: (value) => new Color(value),
|
|
674
|
+
});
|
|
675
|
+
borderRightColorProperty.register(Style);
|
|
676
|
+
export const borderBottomColorProperty = new CssProperty({
|
|
677
|
+
name: 'borderBottomColor',
|
|
678
|
+
cssName: 'border-bottom-color',
|
|
679
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
680
|
+
target.backgroundInternal = target.backgroundInternal.withBorderBottomColor(newValue);
|
|
681
|
+
},
|
|
682
|
+
equalityComparer: Color.equals,
|
|
683
|
+
valueConverter: (value) => new Color(value),
|
|
684
|
+
});
|
|
685
|
+
borderBottomColorProperty.register(Style);
|
|
686
|
+
export const borderLeftColorProperty = new CssProperty({
|
|
687
|
+
name: 'borderLeftColor',
|
|
688
|
+
cssName: 'border-left-color',
|
|
689
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
690
|
+
target.backgroundInternal = target.backgroundInternal.withBorderLeftColor(newValue);
|
|
691
|
+
},
|
|
692
|
+
equalityComparer: Color.equals,
|
|
693
|
+
valueConverter: (value) => new Color(value),
|
|
694
|
+
});
|
|
695
|
+
borderLeftColorProperty.register(Style);
|
|
696
|
+
// Border Width properties.
|
|
697
|
+
const borderWidthProperty = new ShorthandProperty({
|
|
698
|
+
name: 'borderWidth',
|
|
699
|
+
cssName: 'border-width',
|
|
700
|
+
getter: function () {
|
|
701
|
+
if (Length.equals(this.borderTopWidth, this.borderRightWidth) && Length.equals(this.borderTopWidth, this.borderBottomWidth) && Length.equals(this.borderTopWidth, this.borderLeftWidth)) {
|
|
702
|
+
return this.borderTopWidth;
|
|
703
|
+
}
|
|
704
|
+
else {
|
|
705
|
+
return `${Length.convertToString(this.borderTopWidth)} ${Length.convertToString(this.borderRightWidth)} ${Length.convertToString(this.borderBottomWidth)} ${Length.convertToString(this.borderLeftWidth)}`;
|
|
706
|
+
}
|
|
707
|
+
},
|
|
708
|
+
converter: function (value) {
|
|
709
|
+
if (typeof value === 'string' && value !== 'auto') {
|
|
710
|
+
const borderWidths = parseShorthandPositioning(value);
|
|
711
|
+
return [
|
|
712
|
+
[borderTopWidthProperty, Length.parse(borderWidths.top)],
|
|
713
|
+
[borderRightWidthProperty, Length.parse(borderWidths.right)],
|
|
714
|
+
[borderBottomWidthProperty, Length.parse(borderWidths.bottom)],
|
|
715
|
+
[borderLeftWidthProperty, Length.parse(borderWidths.left)],
|
|
716
|
+
];
|
|
717
|
+
}
|
|
718
|
+
else {
|
|
719
|
+
return [
|
|
720
|
+
[borderTopWidthProperty, value],
|
|
721
|
+
[borderRightWidthProperty, value],
|
|
722
|
+
[borderBottomWidthProperty, value],
|
|
723
|
+
[borderLeftWidthProperty, value],
|
|
724
|
+
];
|
|
725
|
+
}
|
|
726
|
+
},
|
|
727
|
+
});
|
|
728
|
+
borderWidthProperty.register(Style);
|
|
729
|
+
export const borderTopWidthProperty = new CssProperty({
|
|
730
|
+
name: 'borderTopWidth',
|
|
731
|
+
cssName: 'border-top-width',
|
|
732
|
+
defaultValue: CoreTypes.zeroLength,
|
|
733
|
+
affectsLayout: global.isIOS,
|
|
734
|
+
equalityComparer: Length.equals,
|
|
735
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
736
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
737
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
738
|
+
throw new Error(`border-top-width should be Non-Negative Finite number. Value: ${value}`);
|
|
739
|
+
}
|
|
740
|
+
const view = target.viewRef.get();
|
|
741
|
+
if (view) {
|
|
742
|
+
view.effectiveBorderTopWidth = value;
|
|
743
|
+
}
|
|
744
|
+
else {
|
|
745
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
746
|
+
}
|
|
747
|
+
target.backgroundInternal = target.backgroundInternal.withBorderTopWidth(value);
|
|
748
|
+
},
|
|
749
|
+
valueConverter: Length.parse,
|
|
750
|
+
});
|
|
751
|
+
borderTopWidthProperty.register(Style);
|
|
752
|
+
export const borderRightWidthProperty = new CssProperty({
|
|
753
|
+
name: 'borderRightWidth',
|
|
754
|
+
cssName: 'border-right-width',
|
|
755
|
+
defaultValue: CoreTypes.zeroLength,
|
|
756
|
+
affectsLayout: global.isIOS,
|
|
757
|
+
equalityComparer: Length.equals,
|
|
758
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
759
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
760
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
761
|
+
throw new Error(`border-right-width should be Non-Negative Finite number. Value: ${value}`);
|
|
762
|
+
}
|
|
763
|
+
const view = target.viewRef.get();
|
|
764
|
+
if (view) {
|
|
765
|
+
view.effectiveBorderRightWidth = value;
|
|
766
|
+
}
|
|
767
|
+
else {
|
|
768
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
769
|
+
}
|
|
770
|
+
target.backgroundInternal = target.backgroundInternal.withBorderRightWidth(value);
|
|
771
|
+
},
|
|
772
|
+
valueConverter: Length.parse,
|
|
773
|
+
});
|
|
774
|
+
borderRightWidthProperty.register(Style);
|
|
775
|
+
export const borderBottomWidthProperty = new CssProperty({
|
|
776
|
+
name: 'borderBottomWidth',
|
|
777
|
+
cssName: 'border-bottom-width',
|
|
778
|
+
defaultValue: CoreTypes.zeroLength,
|
|
779
|
+
affectsLayout: global.isIOS,
|
|
780
|
+
equalityComparer: Length.equals,
|
|
781
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
782
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
783
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
784
|
+
throw new Error(`border-bottom-width should be Non-Negative Finite number. Value: ${value}`);
|
|
785
|
+
}
|
|
786
|
+
const view = target.viewRef.get();
|
|
787
|
+
if (view) {
|
|
788
|
+
view.effectiveBorderBottomWidth = value;
|
|
789
|
+
}
|
|
790
|
+
else {
|
|
791
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
792
|
+
}
|
|
793
|
+
target.backgroundInternal = target.backgroundInternal.withBorderBottomWidth(value);
|
|
794
|
+
},
|
|
795
|
+
valueConverter: Length.parse,
|
|
796
|
+
});
|
|
797
|
+
borderBottomWidthProperty.register(Style);
|
|
798
|
+
export const borderLeftWidthProperty = new CssProperty({
|
|
799
|
+
name: 'borderLeftWidth',
|
|
800
|
+
cssName: 'border-left-width',
|
|
801
|
+
defaultValue: CoreTypes.zeroLength,
|
|
802
|
+
affectsLayout: global.isIOS,
|
|
803
|
+
equalityComparer: Length.equals,
|
|
804
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
805
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
806
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
807
|
+
throw new Error(`border-left-width should be Non-Negative Finite number. Value: ${value}`);
|
|
808
|
+
}
|
|
809
|
+
const view = target.viewRef.get();
|
|
810
|
+
if (view) {
|
|
811
|
+
view.effectiveBorderLeftWidth = value;
|
|
812
|
+
}
|
|
813
|
+
else {
|
|
814
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
815
|
+
}
|
|
816
|
+
target.backgroundInternal = target.backgroundInternal.withBorderLeftWidth(value);
|
|
817
|
+
},
|
|
818
|
+
valueConverter: Length.parse,
|
|
819
|
+
});
|
|
820
|
+
borderLeftWidthProperty.register(Style);
|
|
821
|
+
// Border Radius properties.
|
|
822
|
+
const borderRadiusProperty = new ShorthandProperty({
|
|
823
|
+
name: 'borderRadius',
|
|
824
|
+
cssName: 'border-radius',
|
|
825
|
+
getter: function () {
|
|
826
|
+
if (Length.equals(this.borderTopLeftRadius, this.borderTopRightRadius) && Length.equals(this.borderTopLeftRadius, this.borderBottomRightRadius) && Length.equals(this.borderTopLeftRadius, this.borderBottomLeftRadius)) {
|
|
827
|
+
return this.borderTopLeftRadius;
|
|
828
|
+
}
|
|
829
|
+
return `${Length.convertToString(this.borderTopLeftRadius)} ${Length.convertToString(this.borderTopRightRadius)} ${Length.convertToString(this.borderBottomRightRadius)} ${Length.convertToString(this.borderBottomLeftRadius)}`;
|
|
830
|
+
},
|
|
831
|
+
converter: function (value) {
|
|
832
|
+
if (typeof value === 'string') {
|
|
833
|
+
const borderRadius = parseShorthandPositioning(value);
|
|
834
|
+
return [
|
|
835
|
+
[borderTopLeftRadiusProperty, Length.parse(borderRadius.top)],
|
|
836
|
+
[borderTopRightRadiusProperty, Length.parse(borderRadius.right)],
|
|
837
|
+
[borderBottomRightRadiusProperty, Length.parse(borderRadius.bottom)],
|
|
838
|
+
[borderBottomLeftRadiusProperty, Length.parse(borderRadius.left)],
|
|
839
|
+
];
|
|
840
|
+
}
|
|
841
|
+
else {
|
|
842
|
+
return [
|
|
843
|
+
[borderTopLeftRadiusProperty, value],
|
|
844
|
+
[borderTopRightRadiusProperty, value],
|
|
845
|
+
[borderBottomRightRadiusProperty, value],
|
|
846
|
+
[borderBottomLeftRadiusProperty, value],
|
|
847
|
+
];
|
|
848
|
+
}
|
|
849
|
+
},
|
|
850
|
+
});
|
|
851
|
+
borderRadiusProperty.register(Style);
|
|
852
|
+
export const borderTopLeftRadiusProperty = new CssProperty({
|
|
853
|
+
name: 'borderTopLeftRadius',
|
|
854
|
+
cssName: 'border-top-left-radius',
|
|
855
|
+
defaultValue: 0,
|
|
856
|
+
affectsLayout: global.isIOS,
|
|
857
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
858
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
859
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
860
|
+
throw new Error(`border-top-left-radius should be Non-Negative Finite number. Value: ${value}`);
|
|
861
|
+
}
|
|
862
|
+
target.backgroundInternal = target.backgroundInternal.withBorderTopLeftRadius(value);
|
|
863
|
+
},
|
|
864
|
+
valueConverter: Length.parse,
|
|
865
|
+
equalityComparer: Length.equals,
|
|
866
|
+
});
|
|
867
|
+
borderTopLeftRadiusProperty.register(Style);
|
|
868
|
+
export const borderTopRightRadiusProperty = new CssProperty({
|
|
869
|
+
name: 'borderTopRightRadius',
|
|
870
|
+
cssName: 'border-top-right-radius',
|
|
871
|
+
defaultValue: 0,
|
|
872
|
+
affectsLayout: global.isIOS,
|
|
873
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
874
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
875
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
876
|
+
throw new Error(`border-top-right-radius should be Non-Negative Finite number. Value: ${value}`);
|
|
877
|
+
}
|
|
878
|
+
target.backgroundInternal = target.backgroundInternal.withBorderTopRightRadius(value);
|
|
879
|
+
},
|
|
880
|
+
valueConverter: Length.parse,
|
|
881
|
+
equalityComparer: Length.equals,
|
|
882
|
+
});
|
|
883
|
+
borderTopRightRadiusProperty.register(Style);
|
|
884
|
+
export const borderBottomRightRadiusProperty = new CssProperty({
|
|
885
|
+
name: 'borderBottomRightRadius',
|
|
886
|
+
cssName: 'border-bottom-right-radius',
|
|
887
|
+
defaultValue: 0,
|
|
888
|
+
affectsLayout: global.isIOS,
|
|
889
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
890
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
891
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
892
|
+
throw new Error(`border-bottom-right-radius should be Non-Negative Finite number. Value: ${value}`);
|
|
893
|
+
}
|
|
894
|
+
target.backgroundInternal = target.backgroundInternal.withBorderBottomRightRadius(value);
|
|
895
|
+
},
|
|
896
|
+
valueConverter: Length.parse,
|
|
897
|
+
equalityComparer: Length.equals,
|
|
898
|
+
});
|
|
899
|
+
borderBottomRightRadiusProperty.register(Style);
|
|
900
|
+
export const borderBottomLeftRadiusProperty = new CssProperty({
|
|
901
|
+
name: 'borderBottomLeftRadius',
|
|
902
|
+
cssName: 'border-bottom-left-radius',
|
|
903
|
+
defaultValue: 0,
|
|
904
|
+
affectsLayout: global.isIOS,
|
|
905
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
906
|
+
const value = Length.toDevicePixels(newValue, 0);
|
|
907
|
+
if (!isNonNegativeFiniteNumber(value)) {
|
|
908
|
+
throw new Error(`border-bottom-left-radius should be Non-Negative Finite number. Value: ${value}`);
|
|
909
|
+
}
|
|
910
|
+
target.backgroundInternal = target.backgroundInternal.withBorderBottomLeftRadius(value);
|
|
911
|
+
},
|
|
912
|
+
valueConverter: Length.parse,
|
|
913
|
+
equalityComparer: Length.equals,
|
|
914
|
+
});
|
|
915
|
+
borderBottomLeftRadiusProperty.register(Style);
|
|
916
|
+
const boxShadowProperty = new CssProperty({
|
|
917
|
+
name: 'boxShadow',
|
|
918
|
+
cssName: 'box-shadow',
|
|
919
|
+
valueChanged: (target, _oldValue, newValue) => {
|
|
920
|
+
target.backgroundInternal = target.backgroundInternal.withBoxShadows(newValue?.length
|
|
921
|
+
? newValue.map((v) => {
|
|
922
|
+
return {
|
|
923
|
+
inset: v.inset,
|
|
924
|
+
offsetX: Length.toDevicePixels(v.offsetX, 0),
|
|
925
|
+
offsetY: Length.toDevicePixels(v.offsetY, 0),
|
|
926
|
+
blurRadius: Length.toDevicePixels(v.blurRadius, 0),
|
|
927
|
+
spreadRadius: Length.toDevicePixels(v.spreadRadius, 0),
|
|
928
|
+
color: v.color,
|
|
929
|
+
};
|
|
930
|
+
})
|
|
931
|
+
: null);
|
|
932
|
+
},
|
|
933
|
+
valueConverter: (value) => {
|
|
934
|
+
const values = parseCSSCommaSeparatedListOfValues(value);
|
|
935
|
+
const result = [];
|
|
936
|
+
// The first layer specified is drawn as if it is closest to the user
|
|
937
|
+
for (let i = values.length - 1; i >= 0; i--) {
|
|
938
|
+
const shadowVal = parseCSSShadow(values[i]);
|
|
939
|
+
if (shadowVal) {
|
|
940
|
+
result.push(shadowVal);
|
|
941
|
+
}
|
|
942
|
+
}
|
|
943
|
+
return result;
|
|
944
|
+
},
|
|
945
|
+
});
|
|
946
|
+
boxShadowProperty.register(Style);
|
|
947
|
+
export const clipPathProperty = new CssProperty({
|
|
948
|
+
name: 'clipPath',
|
|
949
|
+
cssName: 'clip-path',
|
|
950
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
951
|
+
target.backgroundInternal = target.backgroundInternal.withClipPath(newValue);
|
|
952
|
+
},
|
|
953
|
+
equalityComparer: (value1, value2) => {
|
|
954
|
+
if (value1 instanceof ClipPathFunction && value2 instanceof ClipPathFunction) {
|
|
955
|
+
return ClipPathFunction.equals(value1, value2);
|
|
956
|
+
}
|
|
957
|
+
return value1 === value2;
|
|
958
|
+
},
|
|
959
|
+
valueConverter(value) {
|
|
960
|
+
if (typeof value === 'string') {
|
|
961
|
+
return parseClipPath(value);
|
|
962
|
+
}
|
|
963
|
+
return value;
|
|
964
|
+
},
|
|
965
|
+
});
|
|
966
|
+
clipPathProperty.register(Style);
|
|
967
|
+
export const directionProperty = new InheritedCssProperty({
|
|
968
|
+
defaultValue: null,
|
|
969
|
+
name: 'direction',
|
|
970
|
+
cssName: 'direction',
|
|
971
|
+
affectsLayout: __APPLE__,
|
|
972
|
+
});
|
|
973
|
+
directionProperty.register(Style);
|
|
974
|
+
export const zIndexProperty = new CssProperty({
|
|
975
|
+
name: 'zIndex',
|
|
976
|
+
cssName: 'z-index',
|
|
977
|
+
valueConverter: (value) => {
|
|
978
|
+
const newValue = parseFloat(value);
|
|
979
|
+
if (isNaN(newValue)) {
|
|
980
|
+
throw new Error(`Invalid value: ${newValue}`);
|
|
981
|
+
}
|
|
982
|
+
return newValue;
|
|
983
|
+
},
|
|
984
|
+
});
|
|
985
|
+
zIndexProperty.register(Style);
|
|
986
|
+
export const opacityProperty = new CssAnimationProperty({
|
|
987
|
+
name: 'opacity',
|
|
988
|
+
cssName: 'opacity',
|
|
989
|
+
defaultValue: 1,
|
|
990
|
+
valueConverter: (value) => {
|
|
991
|
+
const newValue = parseFloat(value);
|
|
992
|
+
if (!isNonNegativeFiniteNumber(newValue) || newValue > 1) {
|
|
993
|
+
throw new Error(`Opacity should be between [0, 1]. Value: ${newValue}`);
|
|
994
|
+
}
|
|
995
|
+
return newValue;
|
|
996
|
+
},
|
|
997
|
+
});
|
|
998
|
+
opacityProperty.register(Style);
|
|
999
|
+
export const colorProperty = new InheritedCssProperty({
|
|
1000
|
+
name: 'color',
|
|
1001
|
+
cssName: 'color',
|
|
1002
|
+
equalityComparer: Color.equals,
|
|
1003
|
+
valueConverter: (v) => new Color(v),
|
|
1004
|
+
});
|
|
1005
|
+
colorProperty.register(Style);
|
|
1006
|
+
export const fontInternalProperty = new CssProperty({
|
|
1007
|
+
name: 'fontInternal',
|
|
1008
|
+
cssName: '_fontInternal',
|
|
1009
|
+
});
|
|
1010
|
+
fontInternalProperty.register(Style);
|
|
1011
|
+
export const fontFamilyProperty = new InheritedCssProperty({
|
|
1012
|
+
name: 'fontFamily',
|
|
1013
|
+
cssName: 'font-family',
|
|
1014
|
+
affectsLayout: global.isIOS,
|
|
1015
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1016
|
+
const currentFont = target.fontInternal || Font.default;
|
|
1017
|
+
if (currentFont.fontFamily !== newValue) {
|
|
1018
|
+
const newFont = currentFont.withFontFamily(newValue);
|
|
1019
|
+
target.fontInternal = Font.equals(Font.default, newFont) ? unsetValue : newFont;
|
|
1020
|
+
}
|
|
1021
|
+
},
|
|
1022
|
+
});
|
|
1023
|
+
fontFamilyProperty.register(Style);
|
|
1024
|
+
export const fontScaleInternalProperty = new InheritedCssProperty({
|
|
1025
|
+
name: 'fontScaleInternal',
|
|
1026
|
+
cssName: '_fontScaleInternal',
|
|
1027
|
+
defaultValue: 1.0,
|
|
1028
|
+
valueConverter: (v) => parseFloat(v),
|
|
1029
|
+
});
|
|
1030
|
+
fontScaleInternalProperty.register(Style);
|
|
1031
|
+
export const fontSizeProperty = new InheritedCssProperty({
|
|
1032
|
+
name: 'fontSize',
|
|
1033
|
+
cssName: 'font-size',
|
|
1034
|
+
affectsLayout: global.isIOS,
|
|
1035
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1036
|
+
if (target.viewRef['handleFontSize'] === true) {
|
|
1037
|
+
return;
|
|
1038
|
+
}
|
|
1039
|
+
const currentFont = target.fontInternal || Font.default;
|
|
1040
|
+
if (currentFont.fontSize !== newValue) {
|
|
1041
|
+
const newFont = currentFont.withFontSize(newValue);
|
|
1042
|
+
target.fontInternal = Font.equals(Font.default, newFont) ? unsetValue : newFont;
|
|
1043
|
+
}
|
|
1044
|
+
},
|
|
1045
|
+
valueConverter: (v) => parseFloat(v),
|
|
1046
|
+
});
|
|
1047
|
+
fontSizeProperty.register(Style);
|
|
1048
|
+
export const fontStyleProperty = new InheritedCssProperty({
|
|
1049
|
+
name: 'fontStyle',
|
|
1050
|
+
cssName: 'font-style',
|
|
1051
|
+
affectsLayout: global.isIOS,
|
|
1052
|
+
defaultValue: FontStyle.NORMAL,
|
|
1053
|
+
valueConverter: FontStyle.parse,
|
|
1054
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1055
|
+
const currentFont = target.fontInternal || Font.default;
|
|
1056
|
+
if (currentFont.fontStyle !== newValue) {
|
|
1057
|
+
const newFont = currentFont.withFontStyle(newValue);
|
|
1058
|
+
target.fontInternal = Font.equals(Font.default, newFont) ? unsetValue : newFont;
|
|
1059
|
+
}
|
|
1060
|
+
},
|
|
1061
|
+
});
|
|
1062
|
+
fontStyleProperty.register(Style);
|
|
1063
|
+
export const fontWeightProperty = new InheritedCssProperty({
|
|
1064
|
+
name: 'fontWeight',
|
|
1065
|
+
cssName: 'font-weight',
|
|
1066
|
+
affectsLayout: global.isIOS,
|
|
1067
|
+
defaultValue: FontWeight.NORMAL,
|
|
1068
|
+
valueConverter: FontWeight.parse,
|
|
1069
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1070
|
+
const currentFont = target.fontInternal || Font.default;
|
|
1071
|
+
if (currentFont.fontWeight !== newValue) {
|
|
1072
|
+
const newFont = currentFont.withFontWeight(newValue);
|
|
1073
|
+
target.fontInternal = Font.equals(Font.default, newFont) ? unsetValue : newFont;
|
|
1074
|
+
}
|
|
1075
|
+
},
|
|
1076
|
+
});
|
|
1077
|
+
fontWeightProperty.register(Style);
|
|
1078
|
+
const fontProperty = new ShorthandProperty({
|
|
1079
|
+
name: 'font',
|
|
1080
|
+
cssName: 'font',
|
|
1081
|
+
getter: function () {
|
|
1082
|
+
return `${this.fontStyle} ${this.fontWeight} ${this.fontSize} ${this.fontFamily}`;
|
|
1083
|
+
},
|
|
1084
|
+
converter: function (value) {
|
|
1085
|
+
if (value === unsetValue) {
|
|
1086
|
+
return [
|
|
1087
|
+
[fontStyleProperty, unsetValue],
|
|
1088
|
+
[fontWeightProperty, unsetValue],
|
|
1089
|
+
[fontSizeProperty, unsetValue],
|
|
1090
|
+
[fontFamilyProperty, unsetValue],
|
|
1091
|
+
];
|
|
1092
|
+
}
|
|
1093
|
+
else {
|
|
1094
|
+
const font = parseFont(value);
|
|
1095
|
+
const fontSize = parseFloat(font.fontSize);
|
|
1096
|
+
return [
|
|
1097
|
+
[fontStyleProperty, font.fontStyle],
|
|
1098
|
+
[fontWeightProperty, font.fontWeight],
|
|
1099
|
+
[fontSizeProperty, fontSize],
|
|
1100
|
+
[fontFamilyProperty, font.fontFamily],
|
|
1101
|
+
];
|
|
1102
|
+
}
|
|
1103
|
+
},
|
|
1104
|
+
});
|
|
1105
|
+
fontProperty.register(Style);
|
|
1106
|
+
export const fontVariationSettingsProperty = new InheritedCssProperty({
|
|
1107
|
+
name: 'fontVariationSettings',
|
|
1108
|
+
cssName: 'font-variation-settings',
|
|
1109
|
+
affectsLayout: global.isIOS,
|
|
1110
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1111
|
+
const currentFont = target.fontInternal || Font.default;
|
|
1112
|
+
if (currentFont.fontVariationSettings !== newValue) {
|
|
1113
|
+
const newFont = currentFont.withFontVariationSettings(newValue);
|
|
1114
|
+
target.fontInternal = Font.equals(Font.default, newFont) ? unsetValue : newFont;
|
|
1115
|
+
}
|
|
1116
|
+
},
|
|
1117
|
+
valueConverter: (value) => {
|
|
1118
|
+
return FontVariationSettings.parse(value);
|
|
1119
|
+
},
|
|
1120
|
+
});
|
|
1121
|
+
fontVariationSettingsProperty.register(Style);
|
|
1122
|
+
export const visibilityProperty = new CssProperty({
|
|
1123
|
+
name: 'visibility',
|
|
1124
|
+
cssName: 'visibility',
|
|
1125
|
+
defaultValue: CoreTypes.Visibility.visible,
|
|
1126
|
+
affectsLayout: global.isIOS,
|
|
1127
|
+
valueConverter: CoreTypes.Visibility.parse,
|
|
1128
|
+
valueChanged: (target, oldValue, newValue) => {
|
|
1129
|
+
const view = target.viewRef.get();
|
|
1130
|
+
if (view) {
|
|
1131
|
+
view.isCollapsed = newValue === CoreTypes.Visibility.collapse;
|
|
1132
|
+
}
|
|
1133
|
+
else {
|
|
1134
|
+
Trace.write(`${newValue} not set to view's property because ".viewRef" is cleared`, Trace.categories.Style, Trace.messageType.warn);
|
|
1135
|
+
}
|
|
1136
|
+
},
|
|
1137
|
+
});
|
|
1138
|
+
visibilityProperty.register(Style);
|
|
1139
|
+
export const androidElevationProperty = new CssProperty({
|
|
1140
|
+
name: 'androidElevation',
|
|
1141
|
+
cssName: 'android-elevation',
|
|
1142
|
+
valueConverter: parseFloat,
|
|
1143
|
+
});
|
|
1144
|
+
androidElevationProperty.register(Style);
|
|
1145
|
+
export const androidDynamicElevationOffsetProperty = new CssProperty({
|
|
1146
|
+
name: 'androidDynamicElevationOffset',
|
|
1147
|
+
cssName: 'android-dynamic-elevation-offset',
|
|
1148
|
+
valueConverter: parseFloat,
|
|
1149
|
+
});
|
|
1150
|
+
androidDynamicElevationOffsetProperty.register(Style);
|
|
1151
|
+
//# sourceMappingURL=style-properties.js.map
|