Skip to content

Commit 18e439b

Browse files
committed
Karakum 1.0.0-alpha.50. Update Electron declarations
1 parent 6a96f59 commit 18e439b

File tree

117 files changed

+695
-246
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

117 files changed

+695
-246
lines changed

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ kotlinx-html.version=0.11.0
1919
kotlinx-coroutines.version=1.10.1
2020

2121
# https://github.com/karakum-team/karakum/releases
22-
karakum.version=1.0.0-alpha.49
22+
karakum.version=1.0.0-alpha.50
2323

2424
# https://github.com/turansky/seskar/releases
2525
seskar.version=3.81.0

kotlin-electron/karakum.config.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
},
1717
"packageNameMapper": {
1818
"electron/([^/]+)\\.kt": "electron/core/$1.kt",
19-
"electron/crossprocessexports/(.+)\\.kt": "electron/$1.kt"
19+
"electron/crossprocessexports/(.+)\\.kt": "electron/$1.kt",
20+
"/([a-z][^/]+)\\.kt": "/$1.val.kt"
2021
},
2122
"importInjector": {
2223
"AddRepresentationOptions.kt": [
@@ -125,6 +126,9 @@
125126
"NetLog.kt": [
126127
"js.promise.Promise"
127128
],
129+
"NodeEventEmitter.kt": [
130+
"node.events.EventEmitter"
131+
],
128132
"Notification.kt": [
129133
"node.events.EventEmitter as NodeEventEmitter"
130134
],
@@ -210,9 +214,6 @@
210214
"js.promise.Promise",
211215
"js.typedarrays.Uint8Array",
212216
"web.html.HTMLElement"
213-
],
214-
"namespace.kt": [
215-
"node.events.EventEmitter"
216217
]
217218
},
218219
"namespaceStrategy": {

kotlin-electron/karakum/plugins/convertSkippedGenerics.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,15 @@ export default function (node, context, render) {
4040
return `${render(node.typeName)}<*>`
4141
}
4242

43+
if (
44+
ts.isTypeReferenceNode(node)
45+
&& ts.isIdentifier(node.typeName)
46+
&& node.typeName.text === "Buffer"
47+
&& !node.typeArguments
48+
) {
49+
return `${render(node.typeName)}<*>`
50+
}
51+
4352
if (
4453
ts.isExpressionWithTypeArguments(node)
4554
&& ts.isIdentifier(node.expression)
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron")
4+
5+
package electron
6+
7+
external val app: App
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron")
4+
5+
package electron
6+
7+
external val autoUpdater: AutoUpdater
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron")
4+
5+
package electron
6+
7+
external val clipboard: Clipboard
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron/common")
4+
5+
package electron.common
6+
7+
external val clipboard: Clipboard

kotlin-electron/src/jsMain/generated/electron/common/namespace.kt renamed to kotlin-electron/src/jsMain/generated/electron/common/crashReporter.val.kt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,4 @@
44

55
package electron.common
66

7-
external val clipboard: Clipboard
8-
97
external val crashReporter: CrashReporter
10-
11-
external val nativeImage: Any?
12-
13-
external val shell: Shell
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron/common")
4+
5+
package electron.common
6+
7+
external val nativeImage: Any /* typeof NativeImage */
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron/common")
4+
5+
package electron.common
6+
7+
external val shell: Shell
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron")
4+
5+
package electron
6+
7+
external val contentTracing: ContentTracing
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("electron")
4+
5+
package electron
6+
7+
external val contextBridge: ContextBridge

kotlin-electron/src/jsMain/generated/electron/core/BrowserWindow.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -681,7 +681,7 @@ open external class BrowserWindow : NodeEventEmitter {
681681
*
682682
* @platform win32
683683
*/
684-
fun hookWindowMessage(message: Double, callback: (wParam: Buffer<*>, lParam: Buffer<*>) -> Unit)
684+
fun hookWindowMessage(message: Double, callback: (wParam: Buffer<*>, lParam: Buffer<*>) -> Unit): Unit
685685

686686
/**
687687
* Invalidates the window shadow so that it is recomputed based on the current

kotlin-electron/src/jsMain/generated/electron/core/ClientRequest.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ external class ClientRequest : NodeEventEmitter {
171171
* the request headers to be issued on the wire. After the first write operation,
172172
* it is not allowed to add or remove a custom header.
173173
*/
174-
fun write(chunk: Buffer<*>, encoding: String = definedExternally, callback: () -> Unit = definedExternally)
174+
fun write(chunk: Buffer<*>, encoding: String = definedExternally, callback: () -> Unit = definedExternally): Unit
175175

176176
/**
177177
* A `boolean` specifying whether the request will use HTTP chunked transfer

kotlin-electron/src/jsMain/generated/electron/core/ClientRequestConstructorOptionsProtocol.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ package electron.core
55
sealed external interface ClientRequestConstructorOptionsProtocol {
66
companion object {
77
@seskar.js.JsValue("http:")
8-
val http: ClientRequestConstructorOptionsProtocol
8+
val `http:`: ClientRequestConstructorOptionsProtocol
99

1010
@seskar.js.JsValue("https:")
11-
val https: ClientRequestConstructorOptionsProtocol
11+
val `https:`: ClientRequestConstructorOptionsProtocol
1212
}
1313
}

kotlin-electron/src/jsMain/generated/electron/core/Clipboard.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ external interface Clipboard {
105105
*
106106
* @experimental
107107
*/
108-
fun writeBuffer(format: String, buffer: Buffer<*>, type: ClipboardWriteBufferType = definedExternally)
108+
fun writeBuffer(format: String, buffer: Buffer<*>, type: ClipboardWriteBufferType = definedExternally): Unit
109109

110110
/**
111111
* Writes the `text` into the find pasteboard (the pasteboard that holds

kotlin-electron/src/jsMain/generated/electron/core/ConfigMaxVersion.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ package electron.core
55
sealed external interface ConfigMaxVersion {
66
companion object {
77
@seskar.js.JsValue("tls1.2")
8-
val tls12: ConfigMaxVersion
8+
val `tls1.2`: ConfigMaxVersion
99

1010
@seskar.js.JsValue("tls1.3")
11-
val tls13: ConfigMaxVersion
11+
val `tls1.3`: ConfigMaxVersion
1212
}
1313
}

kotlin-electron/src/jsMain/generated/electron/core/ConfigMinVersion.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,12 @@ sealed external interface ConfigMinVersion {
88
val tls1: ConfigMinVersion
99

1010
@seskar.js.JsValue("tls1.1")
11-
val tls11: ConfigMinVersion
11+
val `tls1.1`: ConfigMinVersion
1212

1313
@seskar.js.JsValue("tls1.2")
14-
val tls12: ConfigMinVersion
14+
val `tls1.2`: ConfigMinVersion
1515

1616
@seskar.js.JsValue("tls1.3")
17-
val tls13: ConfigMinVersion
17+
val `tls1.3`: ConfigMinVersion
1818
}
1919
}

kotlin-electron/src/jsMain/generated/electron/core/CookieSameSite.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ sealed external interface CookieSameSite {
88
val unspecified: CookieSameSite
99

1010
@seskar.js.JsValue("no_restriction")
11-
val noRestriction: CookieSameSite
11+
val no_restriction: CookieSameSite
1212

1313
@seskar.js.JsValue("lax")
1414
val lax: CookieSameSite

kotlin-electron/src/jsMain/generated/electron/core/CookiesSetDetailsSameSite.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ sealed external interface CookiesSetDetailsSameSite {
88
val unspecified: CookiesSetDetailsSameSite
99

1010
@seskar.js.JsValue("no_restriction")
11-
val noRestriction: CookiesSetDetailsSameSite
11+
val no_restriction: CookiesSetDetailsSameSite
1212

1313
@seskar.js.JsValue("lax")
1414
val lax: CookiesSetDetailsSameSite

kotlin-electron/src/jsMain/generated/electron/core/DetailsType.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,16 @@ sealed external interface DetailsType {
1111
val Zygote: DetailsType
1212

1313
@seskar.js.JsValue("Sandbox helper")
14-
val SandboxHelper: DetailsType
14+
val `Sandbox helper`: DetailsType
1515

1616
@seskar.js.JsValue("GPU")
1717
val GPU: DetailsType
1818

1919
@seskar.js.JsValue("Pepper Plugin")
20-
val PepperPlugin: DetailsType
20+
val `Pepper Plugin`: DetailsType
2121

2222
@seskar.js.JsValue("Pepper Plugin Broker")
23-
val PepperPluginBroker: DetailsType
23+
val `Pepper Plugin Broker`: DetailsType
2424

2525
@seskar.js.JsValue("Unknown")
2626
val Unknown: DetailsType

kotlin-electron/src/jsMain/generated/electron/core/GPUFeatureStatus.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ external interface GPUFeatureStatus {
77
/**
88
* Canvas.
99
*/
10-
/* '2d_canvas': string; */
10+
var `2d_canvas`: String
11+
1112
/**
1213
* Flash.
1314
*/
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// Generated by Karakum - do not modify it manually!
2+
3+
@file:JsModule("INTERNAL_ENTITY")
4+
5+
package electron.core
6+
7+
import node.events.EventEmitter
8+
9+
external val NodeEventEmitter: /* import('events') */ EventEmitter

kotlin-electron/src/jsMain/generated/electron/core/ProcessMetricType.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ sealed external interface ProcessMetricType {
1717
val Zygote: ProcessMetricType
1818

1919
@seskar.js.JsValue("Sandbox helper")
20-
val SandboxHelper: ProcessMetricType
20+
val `Sandbox helper`: ProcessMetricType
2121

2222
@seskar.js.JsValue("GPU")
2323
val GPU: ProcessMetricType
2424

2525
@seskar.js.JsValue("Pepper Plugin")
26-
val PepperPlugin: ProcessMetricType
26+
val `Pepper Plugin`: ProcessMetricType
2727

2828
@seskar.js.JsValue("Pepper Plugin Broker")
29-
val PepperPluginBroker: ProcessMetricType
29+
val `Pepper Plugin Broker`: ProcessMetricType
3030

3131
@seskar.js.JsValue("Unknown")
3232
val Unknown: ProcessMetricType

kotlin-electron/src/jsMain/generated/electron/core/ProxyConfigMode.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ sealed external interface ProxyConfigMode {
88
val direct: ProxyConfigMode
99

1010
@seskar.js.JsValue("auto_detect")
11-
val autoDetect: ProxyConfigMode
11+
val auto_detect: ProxyConfigMode
1212

1313
@seskar.js.JsValue("pac_script")
14-
val pacScript: ProxyConfigMode
14+
val pac_script: ProxyConfigMode
1515

1616
@seskar.js.JsValue("fixed_servers")
17-
val fixedServers: ProxyConfigMode
17+
val fixed_servers: ProxyConfigMode
1818

1919
@seskar.js.JsValue("system")
2020
val system: ProxyConfigMode

kotlin-electron/src/jsMain/generated/electron/core/SafeStorageGetSelectedStorageBackendResult.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ package electron.core
55
sealed external interface SafeStorageGetSelectedStorageBackendResult {
66
companion object {
77
@seskar.js.JsValue("basic_text")
8-
val basicText: SafeStorageGetSelectedStorageBackendResult
8+
val basic_text: SafeStorageGetSelectedStorageBackendResult
99

1010
@seskar.js.JsValue("gnome_libsecret")
11-
val gnomeLibsecret: SafeStorageGetSelectedStorageBackendResult
11+
val gnome_libsecret: SafeStorageGetSelectedStorageBackendResult
1212

1313
@seskar.js.JsValue("kwallet")
1414
val kwallet: SafeStorageGetSelectedStorageBackendResult

kotlin-electron/src/jsMain/generated/electron/core/SystemPreferencesGetColorColor.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,19 +5,19 @@ package electron.core
55
sealed external interface SystemPreferencesGetColorColor {
66
companion object {
77
@seskar.js.JsValue("3d-dark-shadow")
8-
val _3dDarkShadow: SystemPreferencesGetColorColor
8+
val `3d-dark-shadow`: SystemPreferencesGetColorColor
99

1010
@seskar.js.JsValue("3d-face")
11-
val _3dFace: SystemPreferencesGetColorColor
11+
val `3d-face`: SystemPreferencesGetColorColor
1212

1313
@seskar.js.JsValue("3d-highlight")
14-
val _3dHighlight: SystemPreferencesGetColorColor
14+
val `3d-highlight`: SystemPreferencesGetColorColor
1515

1616
@seskar.js.JsValue("3d-light")
17-
val _3dLight: SystemPreferencesGetColorColor
17+
val `3d-light`: SystemPreferencesGetColorColor
1818

1919
@seskar.js.JsValue("3d-shadow")
20-
val _3dShadow: SystemPreferencesGetColorColor
20+
val `3d-shadow`: SystemPreferencesGetColorColor
2121

2222
@seskar.js.JsValue("active-border")
2323
val activeBorder: SystemPreferencesGetColorColor

kotlin-electron/src/jsMain/generated/electron/core/TouchBar.kt

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,53 +22,53 @@ open external class TouchBar {
2222
/**
2323
* A `typeof TouchBarButton` reference to the `TouchBarButton` class.
2424
*/
25-
var TouchBarButton: Any?
25+
var TouchBarButton: Any /* typeof TouchBarButton */
2626

2727
/**
2828
* A `typeof TouchBarColorPicker` reference to the `TouchBarColorPicker` class.
2929
*/
30-
var TouchBarColorPicker: Any?
30+
var TouchBarColorPicker: Any /* typeof TouchBarColorPicker */
3131

3232
/**
3333
* A `typeof TouchBarGroup` reference to the `TouchBarGroup` class.
3434
*/
35-
var TouchBarGroup: Any?
35+
var TouchBarGroup: Any /* typeof TouchBarGroup */
3636

3737
/**
3838
* A `typeof TouchBarLabel` reference to the `TouchBarLabel` class.
3939
*/
40-
var TouchBarLabel: Any?
40+
var TouchBarLabel: Any /* typeof TouchBarLabel */
4141

4242
/**
4343
* A `typeof TouchBarOtherItemsProxy` reference to the `TouchBarOtherItemsProxy`
4444
* class.
4545
*/
46-
var TouchBarOtherItemsProxy: Any?
46+
var TouchBarOtherItemsProxy: Any /* typeof TouchBarOtherItemsProxy */
4747

4848
/**
4949
* A `typeof TouchBarPopover` reference to the `TouchBarPopover` class.
5050
*/
51-
var TouchBarPopover: Any?
51+
var TouchBarPopover: Any /* typeof TouchBarPopover */
5252

5353
/**
5454
* A `typeof TouchBarScrubber` reference to the `TouchBarScrubber` class.
5555
*/
56-
var TouchBarScrubber: Any?
56+
var TouchBarScrubber: Any /* typeof TouchBarScrubber */
5757

5858
/**
5959
* A `typeof TouchBarSegmentedControl` reference to the `TouchBarSegmentedControl`
6060
* class.
6161
*/
62-
var TouchBarSegmentedControl: Any?
62+
var TouchBarSegmentedControl: Any /* typeof TouchBarSegmentedControl */
6363

6464
/**
6565
* A `typeof TouchBarSlider` reference to the `TouchBarSlider` class.
6666
*/
67-
var TouchBarSlider: Any?
67+
var TouchBarSlider: Any /* typeof TouchBarSlider */
6868

6969
/**
7070
* A `typeof TouchBarSpacer` reference to the `TouchBarSpacer` class.
7171
*/
72-
var TouchBarSpacer: Any?
72+
var TouchBarSpacer: Any /* typeof TouchBarSpacer */
7373
}
7474
}

0 commit comments

Comments
 (0)