// DO NOT EDIT MANUALLY!
// Generated by org/jetbrains/kotlin/generators/arguments/GenerateGradleOptions.kt
// To regenerate run 'generateGradleOptions' task
@file:Suppress("RemoveRedundantQualifierName", "Deprecation", "Deprecation_Error", "DuplicatedCode")

package org.jetbrains.kotlin.gradle.dsl

/**
 * Compiler options for Kotlin/JS.
 */
@OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
@Deprecated(
    message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
    level = DeprecationLevel.ERROR,
)
interface KotlinJsOptions : org.jetbrains.kotlin.gradle.dsl.KotlinCommonOptions {

    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.ERROR,
    )
    /**
     * @suppress
     */
    override val options: org.jetbrains.kotlin.gradle.dsl.KotlinJsCompilerOptions

    /**
     * Disable internal declaration export.
     *
     * Default value: false
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var friendModulesDisabled: kotlin.Boolean
        get() = options.friendModulesDisabled.get()
        set(value) = options.friendModulesDisabled.set(value)

    private val kotlin.String.mainCompilerOption get() = org.jetbrains.kotlin.gradle.dsl.JsMainFunctionExecutionMode.fromMode(this)

    private val org.jetbrains.kotlin.gradle.dsl.JsMainFunctionExecutionMode.mainKotlinOption get() = this.mode

    /**
     * Specify whether the 'main' function should be called upon execution.
     *
     * Possible values: "call", "noCall"
     *
     * Default value: JsMainFunctionExecutionMode.CALL
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var main: kotlin.String
        get() = options.main.get().mainKotlinOption
        set(value) = options.main.set(value.mainCompilerOption)

    private val kotlin.String?.moduleKindCompilerOption get() = this?.let { org.jetbrains.kotlin.gradle.dsl.JsModuleKind.fromKind(it) }

    private val org.jetbrains.kotlin.gradle.dsl.JsModuleKind?.moduleKindKotlinOption get() = this?.kind

    /**
     * The kind of JS module generated by the compiler. ES modules are enabled by default in case of ES2015 target usage
     *
     * Possible values: "plain", "amd", "commonjs", "umd"
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var moduleKind: kotlin.String?
        get() = options.moduleKind.orNull.moduleKindKotlinOption
        set(value) = options.moduleKind.set(value.moduleKindCompilerOption)

    /**
     * Base name of generated files.
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var moduleName: kotlin.String?
        get() = options.moduleName.orNull
        set(value) = options.moduleName.set(value)

    /**
     * Generate a source map.
     *
     * Default value: false
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var sourceMap: kotlin.Boolean
        get() = options.sourceMap.get()
        set(value) = options.sourceMap.set(value)

    private val kotlin.String?.sourceMapEmbedSourcesCompilerOption get() = this?.let { org.jetbrains.kotlin.gradle.dsl.JsSourceMapEmbedMode.fromMode(it) }

    private val org.jetbrains.kotlin.gradle.dsl.JsSourceMapEmbedMode?.sourceMapEmbedSourcesKotlinOption get() = this?.mode

    /**
     * Embed source files into the source map.
     *
     * Possible values: "never", "always", "inlining"
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var sourceMapEmbedSources: kotlin.String?
        get() = options.sourceMapEmbedSources.orNull.sourceMapEmbedSourcesKotlinOption
        set(value) = options.sourceMapEmbedSources.set(value.sourceMapEmbedSourcesCompilerOption)

    private val kotlin.String?.sourceMapNamesPolicyCompilerOption get() = this?.let { org.jetbrains.kotlin.gradle.dsl.JsSourceMapNamesPolicy.fromPolicy(it) }

    private val org.jetbrains.kotlin.gradle.dsl.JsSourceMapNamesPolicy?.sourceMapNamesPolicyKotlinOption get() = this?.policy

    /**
     * Mode for mapping generated names to original names.
     *
     * Possible values: "no", "simple-names", "fully-qualified-names"
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var sourceMapNamesPolicy: kotlin.String?
        get() = options.sourceMapNamesPolicy.orNull.sourceMapNamesPolicyKotlinOption
        set(value) = options.sourceMapNamesPolicy.set(value.sourceMapNamesPolicyCompilerOption)

    /**
     * Add the specified prefix to the paths in the source map.
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var sourceMapPrefix: kotlin.String?
        get() = options.sourceMapPrefix.orNull
        set(value) = options.sourceMapPrefix.set(value)

    /**
     * Generate JS files for the specified ECMA version.
     *
     * Possible values: "es5", "es2015"
     *
     * Default value: "es5"
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var target: kotlin.String
        get() = options.target.get()
        set(value) = options.target.set(value)

    /**
     * This option does nothing and is left for compatibility with the legacy backend.
     * It is deprecated and will be removed in a future release.
     *
     * Default value: false
     */
    @Deprecated(message = "Only for legacy backend.", level = DeprecationLevel.ERROR)
    var typedArrays: kotlin.Boolean
        get() = options.typedArrays.get()
        set(value) = options.typedArrays.set(value)

    /**
     * Let generated JavaScript code use ES2015 classes. Enabled by default in case of ES2015 target usage
     *
     * Default value: null
     */
    @OptIn(org.jetbrains.kotlin.gradle.InternalKotlinGradlePluginApi::class)
    @Deprecated(
        message = org.jetbrains.kotlin.gradle.dsl.KOTLIN_OPTIONS_DEPRECATION_MESSAGE,
        level = DeprecationLevel.WARNING,
    )
    var useEsClasses: kotlin.Boolean?
        get() = options.useEsClasses.orNull
        set(value) = options.useEsClasses.set(value)
}
