@nativescript/core 9.0.0-next-09-24-2025-17985801416 → 9.0.0-next-10-06-2025-18277360121
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/inspector_modules.js +74 -47
- package/inspector_modules.js.map +1 -1
- package/package.json +1 -1
- package/platforms/android/include.gradle +51 -0
- package/platforms/android/java/org/nativescript/Process.java +59 -0
- package/platforms/android/java/org/nativescript/widgets/AbsoluteLayout.java +88 -0
- package/platforms/android/java/org/nativescript/widgets/AnimatorHelper.java +61 -0
- package/platforms/android/java/org/nativescript/widgets/Async.java +1356 -0
- package/platforms/android/java/org/nativescript/widgets/BorderDrawable.java +936 -0
- package/platforms/android/java/org/nativescript/widgets/BottomNavigationBar.java +308 -0
- package/platforms/android/java/org/nativescript/widgets/BoxShadowDrawable.java +175 -0
- package/platforms/android/java/org/nativescript/widgets/CSSValue.java +34 -0
- package/platforms/android/java/org/nativescript/widgets/CommonLayoutParams.java +456 -0
- package/platforms/android/java/org/nativescript/widgets/ContentLayout.java +85 -0
- package/platforms/android/java/org/nativescript/widgets/CustomTransition.java +135 -0
- package/platforms/android/java/org/nativescript/widgets/CustomTypefaceSpan.java +44 -0
- package/platforms/android/java/org/nativescript/widgets/Dock.java +15 -0
- package/platforms/android/java/org/nativescript/widgets/DockLayout.java +185 -0
- package/platforms/android/java/org/nativescript/widgets/FileHelper.java +815 -0
- package/platforms/android/java/org/nativescript/widgets/FlexLine.java +177 -0
- package/platforms/android/java/org/nativescript/widgets/FlexboxLayout.java +2769 -0
- package/platforms/android/java/org/nativescript/widgets/FragmentBase.java +14 -0
- package/platforms/android/java/org/nativescript/widgets/GridLayout.java +1172 -0
- package/platforms/android/java/org/nativescript/widgets/GridUnitType.java +10 -0
- package/platforms/android/java/org/nativescript/widgets/HorizontalScrollView.java +256 -0
- package/platforms/android/java/org/nativescript/widgets/ImageView.java +423 -0
- package/platforms/android/java/org/nativescript/widgets/ItemSpec.java +56 -0
- package/platforms/android/java/org/nativescript/widgets/LayoutBase.java +98 -0
- package/platforms/android/java/org/nativescript/widgets/LinearGradientDefinition.java +46 -0
- package/platforms/android/java/org/nativescript/widgets/Orientation.java +9 -0
- package/platforms/android/java/org/nativescript/widgets/OriginPoint.java +74 -0
- package/platforms/android/java/org/nativescript/widgets/ScrollSavedState.java +63 -0
- package/platforms/android/java/org/nativescript/widgets/SegmentedBarColorDrawable.java +27 -0
- package/platforms/android/java/org/nativescript/widgets/StackLayout.java +231 -0
- package/platforms/android/java/org/nativescript/widgets/StyleableTextView.java +50 -0
- package/platforms/android/java/org/nativescript/widgets/TabIconRenderingMode.java +6 -0
- package/platforms/android/java/org/nativescript/widgets/TabItemSpec.java +15 -0
- package/platforms/android/java/org/nativescript/widgets/TabLayout.java +451 -0
- package/platforms/android/java/org/nativescript/widgets/TabStrip.java +294 -0
- package/platforms/android/java/org/nativescript/widgets/TabViewPager.java +64 -0
- package/platforms/android/java/org/nativescript/widgets/TabsBar.java +443 -0
- package/platforms/android/java/org/nativescript/widgets/Utils.java +546 -0
- package/platforms/android/java/org/nativescript/widgets/VerticalScrollView.java +258 -0
- package/platforms/android/java/org/nativescript/widgets/ViewHelper.java +564 -0
- package/platforms/android/java/org/nativescript/widgets/WrapLayout.java +252 -0
- package/platforms/android/java/org/nativescript/widgets/image/AsyncTask.java +679 -0
- package/platforms/android/java/org/nativescript/widgets/image/BitmapOwner.java +17 -0
- package/platforms/android/java/org/nativescript/widgets/image/Cache.java +471 -0
- package/platforms/android/java/org/nativescript/widgets/image/DiskLruCache.java +970 -0
- package/platforms/android/java/org/nativescript/widgets/image/Fetcher.java +747 -0
- package/platforms/android/java/org/nativescript/widgets/image/Utils.java +58 -0
- package/platforms/android/java/org/nativescript/widgets/image/Worker.java +571 -0
- package/platforms/ios/src/TNSWidgets/Info.plist +26 -0
- package/platforms/ios/src/TNSWidgets/NSData+Async.m +42 -0
- package/platforms/ios/src/TNSWidgets/NSFileHandle+Async.m +82 -0
- package/platforms/ios/src/TNSWidgets/NSObject+Swizzling.m +68 -0
- package/platforms/ios/src/TNSWidgets/NSString+Async.m +51 -0
- package/platforms/ios/src/TNSWidgets/TNSLabel.m +42 -0
- package/platforms/ios/src/TNSWidgets/UIImage+TNSBlocks.m +77 -0
- package/platforms/ios/src/TNSWidgets/UIView+PassThroughParent.m +53 -0
- package/platforms/ios/src/TNSWidgets/UIView+PropertyBag.m +72 -0
- package/platforms/ios/src/module.modulemap +5 -0
- package/platforms/android/widgets-release.aar +0 -0
- package/platforms/ios/TNSWidgets.xcframework/Info.plist +0 -102
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Info.plist +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Info.plist +0 -20
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/DWARF/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/aarch64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Resources/Info.plist +0 -52
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/Resources/Info.plist +0 -52
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/A/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/Resources/Info.plist +0 -52
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/TNSWidgets.framework/Versions/Current/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/dSYMs/TNSWidgets.framework.dSYM/Contents/Info.plist +0 -20
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/DWARF/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/aarch64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-maccatalyst/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/x86_64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Info.plist +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/TNSWidgets.framework/_CodeSignature/CodeResources +0 -223
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Info.plist +0 -20
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/DWARF/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/aarch64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/ios-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/x86_64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Info.plist +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/TNSWidgets.framework/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Info.plist +0 -20
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/DWARF/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/aarch64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSCCrypto.h +0 -60
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSData+Async.h +0 -24
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSFileHandle+Async.h +0 -22
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/NSString+Async.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSLabel.h +0 -16
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSProcess.h +0 -29
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/TNSWidgets.h +0 -25
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIImage+TNSBlocks.h +0 -26
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Headers/UIView+PassThroughParent.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Info.plist +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/Modules/module.modulemap +0 -6
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/NSObject+Swizzling.h +0 -17
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/PrivateHeaders/UIView+PropertyBag.h +0 -18
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/TNSWidgets.framework/_CodeSignature/CodeResources +0 -223
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Info.plist +0 -20
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/DWARF/TNSWidgets +0 -0
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/aarch64/TNSWidgets.yml +0 -82
- package/platforms/ios/TNSWidgets.xcframework/xros-arm64_x86_64-simulator/dSYMs/TNSWidgets.framework.dSYM/Contents/Resources/Relocations/x86_64/TNSWidgets.yml +0 -82
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/NSData+Async.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/NSFileHandle+Async.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders → src/TNSWidgets}/NSObject+Swizzling.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/NSString+Async.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/TNSLabel.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/TNSWidgets.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/UIImage+TNSBlocks.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/Headers → src/TNSWidgets}/UIView+PassThroughParent.h +0 -0
- /package/platforms/ios/{TNSWidgets.xcframework/ios-arm64/TNSWidgets.framework/PrivateHeaders → src/TNSWidgets}/UIView+PropertyBag.h +0 -0
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2014 Google Inc. All rights reserved.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
package org.nativescript.widgets;
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
import android.content.Context;
|
|
21
|
+
import android.content.res.ColorStateList;
|
|
22
|
+
import android.graphics.Canvas;
|
|
23
|
+
import android.graphics.Color;
|
|
24
|
+
import android.graphics.Paint;
|
|
25
|
+
import android.util.AttributeSet;
|
|
26
|
+
import android.util.TypedValue;
|
|
27
|
+
import android.view.View;
|
|
28
|
+
import android.widget.ImageView;
|
|
29
|
+
import android.widget.LinearLayout;
|
|
30
|
+
import android.widget.TextView;
|
|
31
|
+
|
|
32
|
+
import androidx.core.widget.ImageViewCompat;
|
|
33
|
+
|
|
34
|
+
class TabStrip extends LinearLayout {
|
|
35
|
+
|
|
36
|
+
private static final int DEFAULT_BOTTOM_BORDER_THICKNESS_DIPS = 0;
|
|
37
|
+
private static final byte DEFAULT_BOTTOM_BORDER_COLOR_ALPHA = 0x26;
|
|
38
|
+
private static final int SELECTED_INDICATOR_THICKNESS_DIPS = 3;
|
|
39
|
+
private static final int DEFAULT_SELECTED_INDICATOR_COLOR = 0xFF33B5E5;
|
|
40
|
+
|
|
41
|
+
private final int mBottomBorderThickness;
|
|
42
|
+
private final Paint mBottomBorderPaint;
|
|
43
|
+
|
|
44
|
+
private final int mSelectedIndicatorThickness;
|
|
45
|
+
private final Paint mSelectedIndicatorPaint;
|
|
46
|
+
|
|
47
|
+
private final int mDefaultBottomBorderColor;
|
|
48
|
+
|
|
49
|
+
private int mSelectedPosition;
|
|
50
|
+
private float mSelectionOffset;
|
|
51
|
+
|
|
52
|
+
private TabLayout.TabColorizer mCustomTabColorizer;
|
|
53
|
+
private final SimpleTabColorizer mDefaultTabColorizer;
|
|
54
|
+
|
|
55
|
+
private int mTabTextColor;
|
|
56
|
+
private int mSelectedTabTextColor;
|
|
57
|
+
private float mTabTextFontSize;
|
|
58
|
+
private TabIconRenderingMode mIconRenderingMode;
|
|
59
|
+
|
|
60
|
+
private boolean mShouldUpdateTabsTextColor;
|
|
61
|
+
|
|
62
|
+
TabStrip(Context context) {
|
|
63
|
+
this(context, null);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
TabStrip(Context context, AttributeSet attrs) {
|
|
67
|
+
super(context, attrs);
|
|
68
|
+
|
|
69
|
+
setWillNotDraw(false);
|
|
70
|
+
|
|
71
|
+
final float density = getResources().getDisplayMetrics().density;
|
|
72
|
+
|
|
73
|
+
TypedValue outValue = new TypedValue();
|
|
74
|
+
context.getTheme().resolveAttribute(android.R.attr.colorForeground, outValue, true);
|
|
75
|
+
final int themeForegroundColor = outValue.data;
|
|
76
|
+
|
|
77
|
+
mDefaultBottomBorderColor = setColorAlpha(themeForegroundColor,
|
|
78
|
+
DEFAULT_BOTTOM_BORDER_COLOR_ALPHA);
|
|
79
|
+
|
|
80
|
+
mDefaultTabColorizer = new SimpleTabColorizer();
|
|
81
|
+
mDefaultTabColorizer.setIndicatorColors(DEFAULT_SELECTED_INDICATOR_COLOR);
|
|
82
|
+
|
|
83
|
+
mBottomBorderThickness = (int) (DEFAULT_BOTTOM_BORDER_THICKNESS_DIPS * density);
|
|
84
|
+
mBottomBorderPaint = new Paint();
|
|
85
|
+
mBottomBorderPaint.setColor(mDefaultBottomBorderColor);
|
|
86
|
+
|
|
87
|
+
mSelectedIndicatorThickness = (int) (SELECTED_INDICATOR_THICKNESS_DIPS * density);
|
|
88
|
+
mSelectedIndicatorPaint = new Paint();
|
|
89
|
+
|
|
90
|
+
TextView defaultTextView = new TextView(context);
|
|
91
|
+
mTabTextColor = defaultTextView.getTextColors().getDefaultColor();
|
|
92
|
+
mTabTextFontSize = defaultTextView.getTextSize();
|
|
93
|
+
|
|
94
|
+
// Default selected color is the same as mTabTextColor
|
|
95
|
+
mSelectedTabTextColor = mTabTextColor;
|
|
96
|
+
mIconRenderingMode = TabIconRenderingMode.original;
|
|
97
|
+
|
|
98
|
+
mShouldUpdateTabsTextColor = true;
|
|
99
|
+
|
|
100
|
+
setMeasureWithLargestChildEnabled(true);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
void setCustomTabColorizer(TabLayout.TabColorizer customTabColorizer) {
|
|
104
|
+
mCustomTabColorizer = customTabColorizer;
|
|
105
|
+
invalidate();
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
void setSelectedIndicatorColors(int... colors) {
|
|
109
|
+
// Make sure that the custom colorizer is removed
|
|
110
|
+
mCustomTabColorizer = null;
|
|
111
|
+
mDefaultTabColorizer.setIndicatorColors(colors);
|
|
112
|
+
invalidate();
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
void setIconRenderingMode(TabIconRenderingMode mode) {
|
|
116
|
+
mIconRenderingMode = mode;
|
|
117
|
+
updateTabsTextColor();
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
TabIconRenderingMode getIconRenderingMode() {
|
|
121
|
+
return mIconRenderingMode;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
void setTabTextColor(int color) {
|
|
125
|
+
mTabTextColor = color;
|
|
126
|
+
updateTabsTextColor();
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
int getTabTextColor() {
|
|
130
|
+
return mTabTextColor;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
void setSelectedTabTextColor(int color) {
|
|
134
|
+
mSelectedTabTextColor = color;
|
|
135
|
+
updateTabsTextColor();
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
int getSelectedTabTextColor() {
|
|
139
|
+
return mSelectedTabTextColor;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
void setShouldUpdateTabsTextColor(boolean value) {
|
|
143
|
+
mShouldUpdateTabsTextColor = value;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
private void updateTabsTextColor() {
|
|
147
|
+
if (mShouldUpdateTabsTextColor) {
|
|
148
|
+
final int childCount = getChildCount();
|
|
149
|
+
int greyColor = Color.parseColor("#A2A2A2");
|
|
150
|
+
for (int i = 0; i < childCount; i++) {
|
|
151
|
+
LinearLayout linearLayout = (LinearLayout) getChildAt(i);
|
|
152
|
+
ImageView imageView = (ImageView) linearLayout.getChildAt(0);
|
|
153
|
+
TextView textView = (TextView) linearLayout.getChildAt(1);
|
|
154
|
+
|
|
155
|
+
if (mIconRenderingMode == TabIconRenderingMode.template) {
|
|
156
|
+
ColorStateList tint;
|
|
157
|
+
if (i == mSelectedPosition) {
|
|
158
|
+
tint = ColorStateList.valueOf(mSelectedTabTextColor);
|
|
159
|
+
} else {
|
|
160
|
+
tint = ColorStateList.valueOf(greyColor);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
ImageViewCompat.setImageTintList(imageView, tint);
|
|
164
|
+
} else {
|
|
165
|
+
ImageViewCompat.setImageTintList(imageView, null);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
if (i == mSelectedPosition) {
|
|
169
|
+
textView.setTextColor(mSelectedTabTextColor);
|
|
170
|
+
} else {
|
|
171
|
+
textView.setTextColor(mTabTextColor);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
void setTabTextFontSize(float fontSize) {
|
|
178
|
+
mTabTextFontSize = fontSize;
|
|
179
|
+
updateTabsTextFontSize();
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
float getTabTextFontSize() {
|
|
183
|
+
return mTabTextFontSize;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
private void updateTabsTextFontSize() {
|
|
187
|
+
final int childCount = getChildCount();
|
|
188
|
+
for (int i = 0; i < childCount; i++) {
|
|
189
|
+
LinearLayout linearLayout = (LinearLayout) getChildAt(i);
|
|
190
|
+
TextView textView = (TextView) linearLayout.getChildAt(1);
|
|
191
|
+
textView.setTextSize(mTabTextFontSize);
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
// Used by TabLayout (the 'old' tab-view control)
|
|
196
|
+
void onViewPagerPageChanged(int position, float positionOffset) {
|
|
197
|
+
mSelectedPosition = position;
|
|
198
|
+
mSelectionOffset = positionOffset;
|
|
199
|
+
invalidate();
|
|
200
|
+
updateTabsTextColor();
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
// Used by TabsBar
|
|
204
|
+
void onTabsViewPagerPageChanged(int position, float positionOffset) {
|
|
205
|
+
mSelectedPosition = position;
|
|
206
|
+
mSelectionOffset = positionOffset;
|
|
207
|
+
invalidate();
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
int getSelectedPosition() {
|
|
211
|
+
return mSelectedPosition;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
void setSelectedPosition(int position) {
|
|
215
|
+
mSelectedPosition = position;
|
|
216
|
+
invalidate();
|
|
217
|
+
updateTabsTextColor();
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
@Override
|
|
221
|
+
protected void dispatchDraw(Canvas canvas) {
|
|
222
|
+
super.dispatchDraw(canvas);
|
|
223
|
+
|
|
224
|
+
final int height = getHeight();
|
|
225
|
+
final int childCount = getChildCount();
|
|
226
|
+
final TabLayout.TabColorizer tabColorizer = mCustomTabColorizer != null
|
|
227
|
+
? mCustomTabColorizer
|
|
228
|
+
: mDefaultTabColorizer;
|
|
229
|
+
|
|
230
|
+
// Thick colored underline below the current selection
|
|
231
|
+
if (childCount > 0 && mSelectedPosition < childCount) {
|
|
232
|
+
View selectedTitle = getChildAt(mSelectedPosition);
|
|
233
|
+
int left = selectedTitle.getLeft();
|
|
234
|
+
int right = selectedTitle.getRight();
|
|
235
|
+
int color = tabColorizer.getIndicatorColor(mSelectedPosition);
|
|
236
|
+
|
|
237
|
+
if (mSelectionOffset > 0f && mSelectedPosition < (getChildCount() - 1)) {
|
|
238
|
+
int nextColor = tabColorizer.getIndicatorColor(mSelectedPosition + 1);
|
|
239
|
+
if (color != nextColor) {
|
|
240
|
+
color = blendColors(nextColor, color, mSelectionOffset);
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
// Draw the selection partway between the tabs
|
|
244
|
+
View nextTitle = getChildAt(mSelectedPosition + 1);
|
|
245
|
+
left = (int) (mSelectionOffset * nextTitle.getLeft() +
|
|
246
|
+
(1.0f - mSelectionOffset) * left);
|
|
247
|
+
right = (int) (mSelectionOffset * nextTitle.getRight() +
|
|
248
|
+
(1.0f - mSelectionOffset) * right);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
mSelectedIndicatorPaint.setColor(color);
|
|
252
|
+
|
|
253
|
+
canvas.drawRect(left, height - mSelectedIndicatorThickness, right,
|
|
254
|
+
height, mSelectedIndicatorPaint);
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
// Thin underline along the entire bottom edge
|
|
258
|
+
canvas.drawRect(0, height - mBottomBorderThickness, getWidth(), height, mBottomBorderPaint);
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
/**
|
|
262
|
+
* Set the alpha value of the {@code color} to be the given {@code alpha} value.
|
|
263
|
+
*/
|
|
264
|
+
private static int setColorAlpha(int color, byte alpha) {
|
|
265
|
+
return Color.argb(alpha, Color.red(color), Color.green(color), Color.blue(color));
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
/**
|
|
269
|
+
* Blend {@code color1} and {@code color2} using the given ratio.
|
|
270
|
+
*
|
|
271
|
+
* @param ratio of which to blend. 1.0 will return {@code color1}, 0.5 will give an even blend,
|
|
272
|
+
* 0.0 will return {@code color2}.
|
|
273
|
+
*/
|
|
274
|
+
private static int blendColors(int color1, int color2, float ratio) {
|
|
275
|
+
final float inverseRation = 1f - ratio;
|
|
276
|
+
float r = (Color.red(color1) * ratio) + (Color.red(color2) * inverseRation);
|
|
277
|
+
float g = (Color.green(color1) * ratio) + (Color.green(color2) * inverseRation);
|
|
278
|
+
float b = (Color.blue(color1) * ratio) + (Color.blue(color2) * inverseRation);
|
|
279
|
+
return Color.rgb((int) r, (int) g, (int) b);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
private static class SimpleTabColorizer implements TabLayout.TabColorizer {
|
|
283
|
+
private int[] mIndicatorColors;
|
|
284
|
+
|
|
285
|
+
@Override
|
|
286
|
+
public final int getIndicatorColor(int position) {
|
|
287
|
+
return mIndicatorColors[position % mIndicatorColors.length];
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
void setIndicatorColors(int... colors) {
|
|
291
|
+
mIndicatorColors = colors;
|
|
292
|
+
}
|
|
293
|
+
}
|
|
294
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
package org.nativescript.widgets;
|
|
2
|
+
|
|
3
|
+
import android.content.Context;
|
|
4
|
+
import android.util.AttributeSet;
|
|
5
|
+
import android.view.KeyEvent;
|
|
6
|
+
import android.view.MotionEvent;
|
|
7
|
+
|
|
8
|
+
import androidx.annotation.NonNull;
|
|
9
|
+
import androidx.viewpager.widget.ViewPager;
|
|
10
|
+
|
|
11
|
+
// See this thread for more information https://stackoverflow.com/questions/9650265
|
|
12
|
+
public class TabViewPager extends ViewPager {
|
|
13
|
+
private boolean swipePageEnabled = true;
|
|
14
|
+
private boolean animationEnabled = true;
|
|
15
|
+
|
|
16
|
+
public TabViewPager(Context context) {
|
|
17
|
+
super(context);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
public TabViewPager(Context context, AttributeSet attrs) {
|
|
21
|
+
super(context, attrs);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
public void setSwipePageEnabled(boolean enabled) {
|
|
25
|
+
this.swipePageEnabled = enabled;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
public void setAnimationEnabled(boolean enabled) {
|
|
29
|
+
this.animationEnabled = enabled;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
@Override
|
|
33
|
+
public boolean onInterceptTouchEvent(MotionEvent event) {
|
|
34
|
+
if (this.swipePageEnabled) {
|
|
35
|
+
return super.onInterceptTouchEvent(event);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
return false;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
@Override
|
|
42
|
+
public boolean onTouchEvent(MotionEvent event) {
|
|
43
|
+
if (this.swipePageEnabled) {
|
|
44
|
+
return super.onTouchEvent(event);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
return false;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
@Override
|
|
51
|
+
public boolean executeKeyEvent(@NonNull KeyEvent event) {
|
|
52
|
+
if (this.swipePageEnabled) {
|
|
53
|
+
return super.executeKeyEvent(event);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
return false;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
@Override
|
|
60
|
+
public void setCurrentItem(int item) {
|
|
61
|
+
boolean smoothScroll = this.animationEnabled;
|
|
62
|
+
super.setCurrentItem(item, smoothScroll);
|
|
63
|
+
}
|
|
64
|
+
}
|