@nstudio/nativescript-compiler 9.2.0-alpha.10 → 9.2.0-alpha.12
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/dist/api/ir.js +7 -1
- package/dist/cli/runtime.cjs +7 -1
- package/dist/css/css.js +30 -6
- package/dist/driver/cli.js +2 -0
- package/dist/driver/compile.js +23 -10
- package/dist/driver/paths.js +7 -0
- package/dist/driver/unimplemented.js +15 -0
- package/dist/kotlin/access.js +23 -5
- package/dist/kotlin/arguments.js +5 -0
- package/dist/kotlin/builtins.js +0 -4
- package/dist/kotlin/calls.js +6 -2
- package/dist/kotlin/class-methods.js +9 -3
- package/dist/kotlin/components.js +13 -8
- package/dist/kotlin/conversion.js +17 -5
- package/dist/kotlin/core-api.js +2 -13
- package/dist/kotlin/declarations.js +2 -0
- package/dist/kotlin/expression-statements.js +5 -4
- package/dist/kotlin/expressions.js +8 -3
- package/dist/kotlin/functions.js +13 -4
- package/dist/kotlin/global-calls.js +11 -0
- package/dist/kotlin/literals.js +58 -14
- package/dist/kotlin/names.js +2 -2
- package/dist/kotlin/native/api.js +9 -1
- package/dist/kotlin/native/calls.js +84 -3
- package/dist/kotlin/native/subclasses.js +4 -3
- package/dist/kotlin/native/types.js +8 -5
- package/dist/kotlin/operators.js +4 -1
- package/dist/kotlin/overrides.js +7 -5
- package/dist/kotlin/placement.js +3 -1
- package/dist/kotlin/prototype-calls.js +5 -0
- package/dist/kotlin/render.js +62 -0
- package/dist/kotlin/statements.js +9 -0
- package/dist/kotlin/static-calls.js +10 -7
- package/dist/kotlin/translator.js +31 -11
- package/dist/kotlin/type-facts.js +10 -2
- package/dist/kotlin/types.js +6 -6
- package/dist/plugins/native-android.js +37 -5
- package/dist/plugins/native-ios.js +2 -0
- package/dist/plugins/source.js +73 -23
- package/dist/program/app-modules.js +91 -16
- package/dist/program/app-paths.js +80 -12
- package/dist/program/class-mixins.js +463 -0
- package/dist/program/core-facts.js +7 -0
- package/dist/program/glob.js +274 -0
- package/dist/program/platform.js +32 -4
- package/dist/program/program.js +239 -38
- package/dist/program/source-lines.js +4 -1
- package/dist/program/vite-plugins.js +144 -0
- package/dist/semantics/apis/globals.js +2 -2
- package/dist/semantics/apis/object.js +1 -0
- package/dist/semantics/apis/statics.js +6 -0
- package/dist/semantics/ast.js +20 -2
- package/dist/semantics/classes.js +36 -1
- package/dist/semantics/facts.js +28 -1
- package/dist/semantics/globals.js +3 -0
- package/dist/semantics/lang.js +13 -1
- package/dist/semantics/nullish.js +29 -11
- package/dist/semantics/refuse-receivers.js +3 -3
- package/dist/semantics/refuse-scope.js +2 -7
- package/dist/semantics/runtime.js +1 -0
- package/dist/semantics/shapes.js +21 -1
- package/dist/semantics/states/value-states.js +1 -1
- package/dist/semantics/throws.js +1 -0
- package/dist/semantics/translator-methods.js +1 -1
- package/dist/semantics/types.js +21 -1
- package/dist/swift/access.js +25 -10
- package/dist/swift/arguments.js +10 -2
- package/dist/swift/assignment.js +12 -1
- package/dist/swift/builtins.js +0 -4
- package/dist/swift/calls.js +6 -2
- package/dist/swift/class-methods.js +3 -3
- package/dist/swift/components.js +28 -8
- package/dist/swift/construction.js +4 -0
- package/dist/swift/conversion.js +1 -1
- package/dist/swift/core-api.js +9 -12
- package/dist/swift/from-any.js +2 -2
- package/dist/swift/functions.js +13 -2
- package/dist/swift/generics.js +5 -1
- package/dist/swift/global-calls.js +2 -0
- package/dist/swift/literals.js +57 -10
- package/dist/swift/modules.js +1 -1
- package/dist/swift/names.js +1 -1
- package/dist/swift/native/sdk-tables.js +52 -4
- package/dist/swift/native/sdk.js +9 -1
- package/dist/swift/operators.js +4 -1
- package/dist/swift/parameters.js +5 -2
- package/dist/swift/placement.js +44 -4
- package/dist/swift/prototype-calls.js +17 -2
- package/dist/swift/render.js +64 -0
- package/dist/swift/results.js +1 -1
- package/dist/swift/statements.js +9 -0
- package/dist/swift/static-calls.js +13 -6
- package/dist/swift/types.js +9 -9
- package/dist/targets/android/build.js +18 -12
- package/dist/targets/ios/build.js +11 -10
- package/dist/targets/ios/dependencies.js +12 -0
- package/dist/targets/resources.js +15 -1
- package/dist/template/plan.js +105 -8
- package/dist/types/adapter-api.d.ts +13 -0
- package/dist/types/ir.d.ts +47 -0
- package/kit-android/generated/kotlin/org/nativescript/kit/__Objects.kt +102 -7485
- package/kit-android/generated/kotlin/org/nativescript/kit/application_application.kt +4 -4
- package/kit-android/generated/kotlin/org/nativescript/kit/image_source_index.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_animation_common.kt +7 -3
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_animation_index.kt +3 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_base_index.kt +2 -4
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_index.kt +5 -6
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_core_view_view_common.kt +1 -3
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_dialogs_index.kt +11 -6
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_fragment_transitions.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_common.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_frame_helper_for_android.kt +7 -5
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_frame_index.kt +6 -3
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_gestures_touch_manager.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_layouts_flexbox_layout_index.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_search_bar_index.kt +4 -3
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_segmented_bar_index.kt +2 -2
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_formatted_string.kt +1 -3
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_text_base_index.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_fade_transition.kt +1 -1
- package/kit-android/generated/kotlin/org/nativescript/kit/ui_transition_flip_transition.kt +8 -8
- package/kit-android/generated/kotlin/org/nativescript/kit/utils_index.kt +1 -1
- package/kit-android/generated/source-lines.json +1 -1
- package/kit-android/gradlew.bat +94 -0
- package/kit-android/src/fromcore/kotlin/org/nativescript/kit/CoreBridge.kt +67 -1
- package/kit-android/src/main/kotlin/org/nativescript/kit/Signals.kt +15 -2
- package/kit-android/src/main/kotlin/org/nativescript/kit/runtime/Prototypes.kt +26 -0
- package/kit-apple/Overlays/xml-free/Core/ui.core.bindable.index.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity1.swift +26 -161
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity2.swift +9 -284
- package/kit-apple/Sources/NativeScriptKit/Core/FunctionCells.Arity3Plus.swift +11 -7
- package/kit-apple/Sources/NativeScriptKit/Core/Object_callback_thisArg_once.swift +1 -1
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_index_section_view_ios_android.swift +7 -5
- package/kit-apple/Sources/NativeScriptKit/Core/Object_eventName_object_oldIndex_newIndex.swift +4 -2
- package/kit-apple/Sources/NativeScriptKit/Core/{Object_iterator_prototype_for_keyFor_hasInstance_isConcatSpreadable_and_19_more_91b5f3.swift → Object_iterator_prototype_for_keyFor_hasInstance_isConcatSpreadable_and_19_more_fa18e1.swift} +28 -103
- package/kit-apple/Sources/NativeScriptKit/Core/__Namespace.Utils.swift +17 -15
- package/kit-apple/Sources/NativeScriptKit/Core/application-settings.index.ios.swift +8 -8
- package/kit-apple/Sources/NativeScriptKit/Core/application.application-common.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/color.color-common.swift +7 -7
- package/kit-apple/Sources/NativeScriptKit/Core/data.observable.index.swift +3 -3
- package/kit-apple/Sources/NativeScriptKit/Core/http.http-request-internal.index.ios.swift +2 -1
- package/kit-apple/Sources/NativeScriptKit/Core/image-source.index.ios.swift +1 -1
- package/kit-apple/Sources/NativeScriptKit/Core/kit-index.json +40 -246
- package/kit-apple/Sources/NativeScriptKit/Core/manifest.json +1 -2
- package/kit-apple/Sources/NativeScriptKit/Core/ui.action-bar.index.ios.swift +3 -3
- package/kit-apple/Sources/NativeScriptKit/Core/ui.button.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.content-view.index.swift +8 -8
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.bindable.index.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.index.ios.swift +8 -8
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-common.swift +1 -3
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.view.view-helper.view-helper-common.swift +7 -7
- package/kit-apple/Sources/NativeScriptKit/Core/ui.core.weak-event-listener.index.swift +3 -3
- package/kit-apple/Sources/NativeScriptKit/Core/ui.frame.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.gestures.index.ios.swift +2 -2
- package/kit-apple/Sources/NativeScriptKit/Core/ui.html-view.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.image-common.swift +2 -2
- package/kit-apple/Sources/NativeScriptKit/Core/ui.image.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.label.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.absolute-layout.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.dock-layout.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.flexbox-layout.index.ios.swift +3 -3
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.grid-layout.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.stack-layout.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.layouts.wrap-layout.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.list-view.index.ios.swift +3 -3
- package/kit-apple/Sources/NativeScriptKit/Core/ui.page.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.repeater.index.swift +10 -6
- package/kit-apple/Sources/NativeScriptKit/Core/ui.scroll-view.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.split-view.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.styling.background.ios.swift +1 -1
- package/kit-apple/Sources/NativeScriptKit/Core/ui.tab-view.index.ios.swift +4 -4
- package/kit-apple/Sources/NativeScriptKit/Core/ui.text-base.formatted-string.swift +2 -1
- package/kit-apple/Sources/NativeScriptKit/Core/utils.common.swift +9 -9
- package/kit-apple/Sources/NativeScriptKit/Core/utils.layout-helper.index.ios.swift +10 -10
- package/kit-apple/Sources/NativeScriptKit/CoreBridge.swift +67 -1
- package/kit-apple/Sources/NativeScriptKit/Runtime/Lowering.swift +4 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/Prototypes.swift +25 -0
- package/kit-apple/Sources/NativeScriptKit/Runtime/RegExp.swift +6 -0
- package/kit-apple/Sources/NativeScriptKit/Signals.swift +20 -2
- package/package.json +2 -1
- package/kit-apple/Sources/NativeScriptKit/Core/Object_toString_charAt_charCodeAt_concat_indexOf_lastIndexOf_and_44_more_fc25df.swift +0 -481
|
@@ -26,8 +26,8 @@ extension Utils {
|
|
|
26
26
|
public static func escapeRegexSymbols(_ source: String) throws -> String {
|
|
27
27
|
return try NativeScriptKit.Core_utils_common.escapeRegexSymbols(source)
|
|
28
28
|
}
|
|
29
|
-
public static func convertString(_ value: Any?) -> Any? {
|
|
30
|
-
return NativeScriptKit.Core_utils_common.convertString(value)
|
|
29
|
+
public static func convertString(_ value: Any?) throws -> Any? {
|
|
30
|
+
return try NativeScriptKit.Core_utils_common.convertString(value)
|
|
31
31
|
}
|
|
32
32
|
public static func getModuleName(_ path: String) throws -> String {
|
|
33
33
|
return try NativeScriptKit.Core_utils_common.getModuleName(path)
|
|
@@ -35,13 +35,15 @@ extension Utils {
|
|
|
35
35
|
public static func sanitizeModuleName(_ moduleName: String, _ removeExtension: Bool = true) throws -> String {
|
|
36
36
|
return try NativeScriptKit.Core_utils_common.sanitizeModuleName(moduleName, removeExtension)
|
|
37
37
|
}
|
|
38
|
-
public static func isFileOrResourcePath(_ path: String) -> Bool {
|
|
39
|
-
return NativeScriptKit.Core_utils_common.isFileOrResourcePath(path)
|
|
38
|
+
public static func isFileOrResourcePath(_ path: String) throws -> Bool {
|
|
39
|
+
return try NativeScriptKit.Core_utils_common.isFileOrResourcePath(path)
|
|
40
40
|
}
|
|
41
|
-
public static func isFontIconURI(_ uri: String) -> Bool {
|
|
42
|
-
return NativeScriptKit.Core_utils_common.isFontIconURI(uri)
|
|
41
|
+
public static func isFontIconURI(_ uri: String) throws -> Bool {
|
|
42
|
+
return try NativeScriptKit.Core_utils_common.isFontIconURI(uri)
|
|
43
|
+
}
|
|
44
|
+
public static func isSystemURI(_ uri: String) throws -> Bool {
|
|
45
|
+
return try NativeScriptKit.Core_utils_common.isSystemURI(uri)
|
|
43
46
|
}
|
|
44
|
-
public static func isSystemURI(_ uri: String) -> Bool { return NativeScriptKit.Core_utils_common.isSystemURI(uri) }
|
|
45
47
|
public static func isDataURI(_ uri: String) throws -> Bool {
|
|
46
48
|
return try NativeScriptKit.Core_utils_common.isDataURI(uri)
|
|
47
49
|
}
|
|
@@ -93,12 +95,12 @@ extension Utils {
|
|
|
93
95
|
}
|
|
94
96
|
public static var debug: Bool { NativeScriptKit.Core_utils_debug.debug }
|
|
95
97
|
public enum layout {
|
|
96
|
-
public static func getMode(_ mode: Double) -> String { return NativeScriptKit.layout.getMode(mode) }
|
|
97
|
-
public static func getMeasureSpecMode(_ spec: Double) -> Double {
|
|
98
|
-
return NativeScriptKit.layout.getMeasureSpecMode(spec)
|
|
98
|
+
public static func getMode(_ mode: Double) throws -> String { return try NativeScriptKit.layout.getMode(mode) }
|
|
99
|
+
public static func getMeasureSpecMode(_ spec: Double) throws -> Double {
|
|
100
|
+
return try NativeScriptKit.layout.getMeasureSpecMode(spec)
|
|
99
101
|
}
|
|
100
|
-
public static func getMeasureSpecSize(_ spec: Double) -> Double {
|
|
101
|
-
return NativeScriptKit.layout.getMeasureSpecSize(spec)
|
|
102
|
+
public static func getMeasureSpecSize(_ spec: Double) throws -> Double {
|
|
103
|
+
return try NativeScriptKit.layout.getMeasureSpecSize(spec)
|
|
102
104
|
}
|
|
103
105
|
public static func makeMeasureSpec(_ size: Double, _ mode: Double) -> Double {
|
|
104
106
|
return NativeScriptKit.layout.makeMeasureSpec(size, mode)
|
|
@@ -113,14 +115,14 @@ extension Utils {
|
|
|
113
115
|
public static func toDeviceIndependentPixels(_ value: Double) throws -> Double {
|
|
114
116
|
return try NativeScriptKit.layout.toDeviceIndependentPixels(value)
|
|
115
117
|
}
|
|
116
|
-
public static func round(_ value: Double) -> Double { return NativeScriptKit.layout.round(value) }
|
|
118
|
+
public static func round(_ value: Double) throws -> Double { return try NativeScriptKit.layout.round(value) }
|
|
117
119
|
public static func measureNativeView(
|
|
118
120
|
_ nativeView: Any?, _ width: Double, _ widthMode: Double, _ height: Double, _ heightMode: Double
|
|
119
121
|
) throws -> Any? {
|
|
120
122
|
return try NativeScriptKit.layout.measureNativeView(nativeView, width, widthMode, height, heightMode)
|
|
121
123
|
}
|
|
122
|
-
public static func measureSpecToString(_ measureSpec: Double) -> String {
|
|
123
|
-
return NativeScriptKit.layout.measureSpecToString(measureSpec)
|
|
124
|
+
public static func measureSpecToString(_ measureSpec: Double) throws -> String {
|
|
125
|
+
return try NativeScriptKit.layout.measureSpecToString(measureSpec)
|
|
124
126
|
}
|
|
125
127
|
public static var MODE_SHIFT: Double { NativeScriptKit.layout.MODE_SHIFT }
|
|
126
128
|
public static var MODE_MASK: Double { NativeScriptKit.layout.MODE_MASK }
|
|
@@ -19,7 +19,7 @@ public enum ApplicationSettings {
|
|
|
19
19
|
public static var userDefaults: UserDefaults?
|
|
20
20
|
public static func hasKey(_ key: String) throws -> Bool? {
|
|
21
21
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:8)
|
|
22
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
22
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
23
23
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:9)
|
|
24
24
|
return nil
|
|
25
25
|
}
|
|
@@ -29,7 +29,7 @@ public enum ApplicationSettings {
|
|
|
29
29
|
#sourceLocation()
|
|
30
30
|
public static func getBoolean(_ key: String, _ defaultValue: Bool? = nil) throws -> Bool? {
|
|
31
31
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:17)
|
|
32
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
32
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
33
33
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:18)
|
|
34
34
|
return nil
|
|
35
35
|
}
|
|
@@ -44,7 +44,7 @@ public enum ApplicationSettings {
|
|
|
44
44
|
#sourceLocation()
|
|
45
45
|
public static func getString(_ key: String, _ defaultValue: String? = nil) throws -> String? {
|
|
46
46
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:28)
|
|
47
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
47
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
48
48
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:29)
|
|
49
49
|
return nil
|
|
50
50
|
}
|
|
@@ -59,7 +59,7 @@ public enum ApplicationSettings {
|
|
|
59
59
|
#sourceLocation()
|
|
60
60
|
public static func getNumber(_ key: String, _ defaultValue: Double? = nil) throws -> Double? {
|
|
61
61
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:39)
|
|
62
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
62
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
63
63
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:40)
|
|
64
64
|
return nil
|
|
65
65
|
}
|
|
@@ -74,7 +74,7 @@ public enum ApplicationSettings {
|
|
|
74
74
|
#sourceLocation()
|
|
75
75
|
public static func setBoolean(_ key: String, _ value: Bool) throws {
|
|
76
76
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:51)
|
|
77
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
77
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
78
78
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:52)
|
|
79
79
|
return
|
|
80
80
|
}
|
|
@@ -89,7 +89,7 @@ public enum ApplicationSettings {
|
|
|
89
89
|
#sourceLocation()
|
|
90
90
|
public static func setString(_ key: String, _ value: String) throws {
|
|
91
91
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:61)
|
|
92
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
92
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
93
93
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:62)
|
|
94
94
|
return
|
|
95
95
|
}
|
|
@@ -104,7 +104,7 @@ public enum ApplicationSettings {
|
|
|
104
104
|
#sourceLocation()
|
|
105
105
|
public static func setNumber(_ key: String, _ value: Double) throws {
|
|
106
106
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:71)
|
|
107
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
107
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
108
108
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:72)
|
|
109
109
|
return
|
|
110
110
|
}
|
|
@@ -119,7 +119,7 @@ public enum ApplicationSettings {
|
|
|
119
119
|
#sourceLocation()
|
|
120
120
|
public static func remove(_ key: String) throws {
|
|
121
121
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:81)
|
|
122
|
-
if !Core_application_settings_application_settings_common.checkKey(key) {
|
|
122
|
+
if try !Core_application_settings_application_settings_common.checkKey(key) {
|
|
123
123
|
#sourceLocation(file:"@nativescript/core/application-settings.index.ios.ts",line:82)
|
|
124
124
|
return
|
|
125
125
|
}
|
|
@@ -1061,15 +1061,15 @@ open class ApplicationCommon: JSDynamic, JSExpando, JSKeysMade, JSStaticKeyed {
|
|
|
1061
1061
|
}
|
|
1062
1062
|
#sourceLocation()
|
|
1063
1063
|
/// Get application level static resources.
|
|
1064
|
-
open func getResources() -> Any? {
|
|
1064
|
+
open func getResources() throws -> Any? {
|
|
1065
1065
|
#sourceLocation(file:"@nativescript/core/application.application-common.ts",line:893)
|
|
1066
|
-
return Core_ui_core_bindable_bindable_resources.get()
|
|
1066
|
+
return try Core_ui_core_bindable_bindable_resources.get()
|
|
1067
1067
|
}
|
|
1068
1068
|
#sourceLocation()
|
|
1069
1069
|
/// Set application level static resources.
|
|
1070
|
-
open func setResources(_ res: Any?) {
|
|
1070
|
+
open func setResources(_ res: Any?) throws {
|
|
1071
1071
|
#sourceLocation(file:"@nativescript/core/application.application-common.ts",line:900)
|
|
1072
|
-
Core_ui_core_bindable_bindable_resources.set(res)
|
|
1072
|
+
try Core_ui_core_bindable_bindable_resources.set(res)
|
|
1073
1073
|
}
|
|
1074
1074
|
#sourceLocation()
|
|
1075
1075
|
/// Sets css file name for the application.
|
|
@@ -29,7 +29,7 @@ open class ColorBase: JSDynamic, JSStringConvertible, JSExpando, JSKeysMade, JSS
|
|
|
29
29
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:15)
|
|
30
30
|
let arg: Any? = try ((jsUnwrap(args, "0").element(0) ?? nil) as Any?)
|
|
31
31
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:16)
|
|
32
|
-
if Core_utils_types.isString(arg) {
|
|
32
|
+
if try Core_utils_types.isString(arg) {
|
|
33
33
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:17)
|
|
34
34
|
let lowered: String = jsLenientString(arg).lowercased()
|
|
35
35
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:18)
|
|
@@ -47,9 +47,9 @@ open class ColorBase: JSDynamic, JSStringConvertible, JSExpando, JSKeysMade, JSS
|
|
|
47
47
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:23)
|
|
48
48
|
self._argb = try Core_color_color_utils.argbFromHsvOrHsva(lowered)
|
|
49
49
|
if jsMadeBits0 & (1 << 0) == 0 { jsMadeNote(&jsMadeBits0, &jsMade, 1 << 0, "_argb") }
|
|
50
|
-
} else if jsTruthy(Core_color_known_colors.isKnownName(lowered) as Any?) {
|
|
50
|
+
} else if try jsTruthy(Core_color_known_colors.isKnownName(lowered) as Any?) {
|
|
51
51
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:26)
|
|
52
|
-
let argb: Double? = Core_color_known_colors.getKnownColor(lowered)
|
|
52
|
+
let argb: Double? = try Core_color_known_colors.getKnownColor(lowered)
|
|
53
53
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:27)
|
|
54
54
|
self._name = jsLenientString(arg)
|
|
55
55
|
if jsMadeBits0 & (1 << 1) == 0 { jsMadeNote(&jsMadeBits0, &jsMade, 1 << 1, "_name") }
|
|
@@ -93,7 +93,7 @@ open class ColorBase: JSDynamic, JSStringConvertible, JSExpando, JSKeysMade, JSS
|
|
|
93
93
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:47)
|
|
94
94
|
throw JSException(value: JSError("Invalid color: " + jsLenientString(arg)))
|
|
95
95
|
}
|
|
96
|
-
} else if Core_utils_types.isNumber(arg) {
|
|
96
|
+
} else if try Core_utils_types.isNumber(arg) {
|
|
97
97
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:52)
|
|
98
98
|
self._argb = jsShiftRightUnsigned(jsLenientNumber(arg), 0)
|
|
99
99
|
if jsMadeBits0 & (1 << 0) == 0 { jsMadeNote(&jsMadeBits0, &jsMade, 1 << 0, "_argb") }
|
|
@@ -260,21 +260,21 @@ open class ColorBase: JSDynamic, JSStringConvertible, JSExpando, JSKeysMade, JSS
|
|
|
260
260
|
return try jsLenientBool(jsCallMethod(value1, "equals", value2))
|
|
261
261
|
}
|
|
262
262
|
#sourceLocation()
|
|
263
|
-
open class func isValid(_ value: Any?) -> Bool {
|
|
263
|
+
open class func isValid(_ value: Any?) throws -> Bool {
|
|
264
264
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:143)
|
|
265
265
|
if value is ColorBase {
|
|
266
266
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:144)
|
|
267
267
|
return true
|
|
268
268
|
}
|
|
269
269
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:147)
|
|
270
|
-
if !Core_utils_types.isString(value) {
|
|
270
|
+
if try !Core_utils_types.isString(value) {
|
|
271
271
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:148)
|
|
272
272
|
return false
|
|
273
273
|
}
|
|
274
274
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:150)
|
|
275
275
|
let lowered: String = jsLenientString(value).lowercased()
|
|
276
276
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:152)
|
|
277
|
-
if jsTruthy(Core_color_known_colors.isKnownName(lowered) as Any?) {
|
|
277
|
+
if try jsTruthy(Core_color_known_colors.isKnownName(lowered) as Any?) {
|
|
278
278
|
#sourceLocation(file:"@nativescript/core/color.color-common.ts",line:153)
|
|
279
279
|
return true
|
|
280
280
|
}
|
|
@@ -352,7 +352,7 @@ open class Observable: JSDynamic, JSExpando, JSConstructibleType, JSKeysMade, JS
|
|
|
352
352
|
#sourceLocation(file:"@nativescript/core/data.observable.index.ts",line:246)
|
|
353
353
|
_ = try jsUnwrap(list, "push").push(
|
|
354
354
|
JSObject([
|
|
355
|
-
("callback", FunctionCell_EventDataOpt_to_Void.
|
|
355
|
+
("callback", FunctionCell_EventDataOpt_to_Void.scriptOrNil("", 1, callback) as Any?),
|
|
356
356
|
("thisArg", thisArg as Any?), ("once", (once as Any?) as Any?),
|
|
357
357
|
]))
|
|
358
358
|
}
|
|
@@ -390,7 +390,7 @@ open class Observable: JSDynamic, JSExpando, JSConstructibleType, JSKeysMade, JS
|
|
|
390
390
|
#sourceLocation(file:"@nativescript/core/data.observable.index.ts",line:246)
|
|
391
391
|
_ = try jsUnwrap(list, "push").push(
|
|
392
392
|
JSObject([
|
|
393
|
-
("callback", FunctionCell_EventDataOpt_to_Void.
|
|
393
|
+
("callback", FunctionCell_EventDataOpt_to_Void.scriptOrNil("", 1, callback) as Any?),
|
|
394
394
|
("thisArg", thisArg as Any?), ("once", (once as Any?) as Any?),
|
|
395
395
|
]))
|
|
396
396
|
}
|
|
@@ -647,7 +647,7 @@ open class Observable: JSDynamic, JSExpando, JSConstructibleType, JSKeysMade, JS
|
|
|
647
647
|
jsUnwrap(Core_data_observable_index._globalEventHandlers[eventClass], "eventName")[eventName], "push"
|
|
648
648
|
).push(
|
|
649
649
|
JSObject([
|
|
650
|
-
("callback", FunctionCell_EventDataOpt_to_Void.
|
|
650
|
+
("callback", FunctionCell_EventDataOpt_to_Void.scriptOrNil("", 1, callback) as Any?),
|
|
651
651
|
("thisArg", thisArg as Any?), ("once", (once as Any?) as Any?),
|
|
652
652
|
]))
|
|
653
653
|
#sourceLocation(file:"@nativescript/core/data.observable.index.ts",line:412)
|
|
@@ -331,7 +331,8 @@ public enum Core_http_http_request_internal_index {
|
|
|
331
331
|
),
|
|
332
332
|
])
|
|
333
333
|
#sourceLocation(file:"@nativescript/core/http.http-request-internal.index.ios.ts",line:173)
|
|
334
|
-
if !jsIsNullish(contentHandler)
|
|
334
|
+
if try !jsIsNullish(contentHandler)
|
|
335
|
+
&& Core_utils_types.isObject(contentHandler)
|
|
335
336
|
&& !(JSArray<Any?>.isArray(contentHandler))
|
|
336
337
|
{
|
|
337
338
|
#sourceLocation(file:"@nativescript/core/http.http-request-internal.index.ios.ts",line:174)
|
|
@@ -296,7 +296,7 @@ open class ImageSource: JSDynamic, JSExpando, JSKeysMade, JSStaticKeyed {
|
|
|
296
296
|
#sourceLocation()
|
|
297
297
|
open class func fromFileOrResourceSync(_ path: String) throws -> ImageSource? {
|
|
298
298
|
#sourceLocation(file:"@nativescript/core/image-source.index.ios.ts",line:159)
|
|
299
|
-
if !Core_utils_common.isFileOrResourcePath(path) {
|
|
299
|
+
if try !Core_utils_common.isFileOrResourcePath(path) {
|
|
300
300
|
#sourceLocation(file:"@nativescript/core/image-source.index.ios.ts",line:160)
|
|
301
301
|
if NativeScriptKit.Trace.isEnabled() {
|
|
302
302
|
#sourceLocation(file:"@nativescript/core/image-source.index.ios.ts",line:161)
|