diff --git a/lib/tsc.js b/lib/tsc.js index 74488a79674570fbadd46aad993d7e1ae60eda36..ffeb2136c89c5413ad7216e25db86b2c4666c571 100644 --- a/lib/tsc.js +++ b/lib/tsc.js @@ -39581,8 +39581,8 @@ function getKitJsonObject(name, sdkPath, compilerOptions) { if (kitJsonCache == null ? void 0 : kitJsonCache.has(name)) { return kitJsonCache.get(name); } - const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; - const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; + const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/dynamic/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; + const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/dynamic/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); let fileInfo = sys.fileExists(ohosJsonPath) ? sys.readFile(ohosJsonPath, "utf-8") : sys.fileExists(hmsJsonPath) ? sys.readFile(hmsJsonPath, "utf-8") : void 0; @@ -39598,7 +39598,7 @@ function isMixedCompilerSDKPath(compilerOptions) { if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith("ets1.1/build-tools/ets-loader")) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith("dynamic/build-tools/ets-loader")) { return true; } return false; @@ -48864,7 +48864,7 @@ function createTypeChecker(host, isTypeCheckerForLinter = false) { } } } - if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/ets1.1/api/global/resource")) { + if (specifier.endsWith("/openharmony/ets/dynamic/api/global/resource")) { const lastSymbol = chain[chain.length - 1]; if (lastSymbol.escapedName === "Resource") { const entityName2 = createAccessFromSymbolChain([lastSymbol], 0, 0); diff --git a/lib/tsserver.js b/lib/tsserver.js index 7c26db87da046095c3af459a304e34f2b5da44f4..68314f4027b624c6d7e0b2fe8a3b12b64a40bc7f 100644 --- a/lib/tsserver.js +++ b/lib/tsserver.js @@ -42278,8 +42278,8 @@ function getKitJsonObject(name, sdkPath, compilerOptions) { if (kitJsonCache == null ? void 0 : kitJsonCache.has(name)) { return kitJsonCache.get(name); } - const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; - const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; + const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/dynamic/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; + const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/dynamic/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); let fileInfo = sys.fileExists(ohosJsonPath) ? sys.readFile(ohosJsonPath, "utf-8") : sys.fileExists(hmsJsonPath) ? sys.readFile(hmsJsonPath, "utf-8") : void 0; @@ -42295,7 +42295,7 @@ function isMixedCompilerSDKPath(compilerOptions) { if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith("ets1.1/build-tools/ets-loader")) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith("dynamic/build-tools/ets-loader")) { return true; } return false; @@ -51418,7 +51418,7 @@ function createTypeChecker(host, isTypeCheckerForLinter = false) { } } } - if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/ets1.1/api/global/resource")) { + if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/dynamic/api/global/resource")) { const lastSymbol = chain[chain.length - 1]; if (lastSymbol.escapedName === "Resource") { const entityName2 = createAccessFromSymbolChain([lastSymbol], 0, 0); diff --git a/lib/tsserverlibrary.js b/lib/tsserverlibrary.js index 3d8a7b5f644d3b12aec64a212d01239950e7e76e..2b643ffcc916550cfb0da3c1caab7c30116308be 100644 --- a/lib/tsserverlibrary.js +++ b/lib/tsserverlibrary.js @@ -42180,8 +42180,8 @@ function getKitJsonObject(name, sdkPath, compilerOptions) { if (kitJsonCache == null ? void 0 : kitJsonCache.has(name)) { return kitJsonCache.get(name); } - const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; - const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; + const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/dynamic/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; + const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/dynamic/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); let fileInfo = sys.fileExists(ohosJsonPath) ? sys.readFile(ohosJsonPath, "utf-8") : sys.fileExists(hmsJsonPath) ? sys.readFile(hmsJsonPath, "utf-8") : void 0; @@ -42197,7 +42197,7 @@ function isMixedCompilerSDKPath(compilerOptions) { if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith("ets1.1/build-tools/ets-loader")) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith("dynamic/build-tools/ets-loader")) { return true; } return false; @@ -51320,7 +51320,7 @@ function createTypeChecker(host, isTypeCheckerForLinter = false) { } } } - if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/ets1.1/api/global/resource")) { + if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/dynamic/api/global/resource")) { const lastSymbol = chain[chain.length - 1]; if (lastSymbol.escapedName === "Resource") { const entityName2 = createAccessFromSymbolChain([lastSymbol], 0, 0); diff --git a/lib/typescript.js b/lib/typescript.js index baaa5fb2b5ce094c6d7a5e7b33e64f5447cb31b5..b08bda2184ed20573969b5c5f26cb5d699ee8721 100644 --- a/lib/typescript.js +++ b/lib/typescript.js @@ -42195,8 +42195,8 @@ function getKitJsonObject(name, sdkPath, compilerOptions) { if (kitJsonCache == null ? void 0 : kitJsonCache.has(name)) { return kitJsonCache.get(name); } - const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; - const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; + const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/dynamic/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; + const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/dynamic/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); let fileInfo = sys.fileExists(ohosJsonPath) ? sys.readFile(ohosJsonPath, "utf-8") : sys.fileExists(hmsJsonPath) ? sys.readFile(hmsJsonPath, "utf-8") : void 0; @@ -42212,7 +42212,7 @@ function isMixedCompilerSDKPath(compilerOptions) { if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith("ets1.1/build-tools/ets-loader")) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith("dynamic/build-tools/ets-loader")) { return true; } return false; @@ -51478,7 +51478,7 @@ function createTypeChecker(host, isTypeCheckerForLinter = false) { } } } - if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/ets1.1/api/global/resource")) { + if (specifier.endsWith("/ets/api/global/resource") || specifier.endsWith("/ets/dynamic/api/global/resource")) { const lastSymbol = chain[chain.length - 1]; if (lastSymbol.escapedName === "Resource") { const entityName2 = createAccessFromSymbolChain([lastSymbol], 0, 0); diff --git a/lib/typingsInstaller.js b/lib/typingsInstaller.js index 33eba1f310c59ed47990ab32773068a5906bf0b6..2c9f580c3bfab5c18ad2715ff139ac1eb3e37fd5 100644 --- a/lib/typingsInstaller.js +++ b/lib/typingsInstaller.js @@ -29394,8 +29394,8 @@ function getKitJsonObject(name, sdkPath, compilerOptions) { if (kitJsonCache == null ? void 0 : kitJsonCache.has(name)) { return kitJsonCache.get(name); } - const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; - const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/ets1.1/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; + const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./openharmony/ets/dynamic/build-tools/ets-loader/kit_configs" : "./openharmony/ets/build-tools/ets-loader/kit_configs"; + const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? "./hms/ets/dynamic/build-tools/ets-loader/kit_configs" : "./hms/ets/build-tools/ets-loader/kit_configs"; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); let fileInfo = sys.fileExists(ohosJsonPath) ? sys.readFile(ohosJsonPath, "utf-8") : sys.fileExists(hmsJsonPath) ? sys.readFile(hmsJsonPath, "utf-8") : void 0; @@ -29411,7 +29411,7 @@ function isMixedCompilerSDKPath(compilerOptions) { if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith("ets1.1/build-tools/ets-loader")) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith("dynamic/build-tools/ets-loader")) { return true; } return false; diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index facaca20fa837ff07ad734d791a50710f877f437..88a5eddd7bdb7bccf02c0b429254642b11e92262 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -8087,7 +8087,7 @@ export function createTypeChecker(host: TypeCheckerHost, isTypeCheckerForLinter: } // Only for Resource type in openharmony SDK if (specifier.endsWith('/ets/api/global/resource') || - specifier.endsWith('/ets/ets1.1/api/global/resource') + specifier.endsWith('/ets/dynamic/api/global/resource') ) { const lastSymbol = chain[chain.length - 1]; // Create typeReferenceNode if is Resource type diff --git a/src/compiler/ohApi.ts b/src/compiler/ohApi.ts index 7f0c87b11c5d8e1418b038b7c0b2001a3da50772..b9a23b16c3f08413e94d287e53b07c0935a31998 100644 --- a/src/compiler/ohApi.ts +++ b/src/compiler/ohApi.ts @@ -1181,10 +1181,10 @@ function getKitJsonObject(name: string, sdkPath: string, compilerOptions: Compil return kitJsonCache.get(name); } const OHOS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? - './openharmony/ets/ets1.1/build-tools/ets-loader/kit_configs' : + './openharmony/ets/dynamic/build-tools/ets-loader/kit_configs' : './openharmony/ets/build-tools/ets-loader/kit_configs'; const HMS_KIT_CONFIG_PATH = isMixedCompilerSDKPath(compilerOptions) ? - './hms/ets/ets1.1/build-tools/ets-loader/kit_configs' : + './hms/ets/dynamic/build-tools/ets-loader/kit_configs' : './hms/ets/build-tools/ets-loader/kit_configs'; const ohosJsonPath = resolvePath(sdkPath, OHOS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); const hmsJsonPath = resolvePath(sdkPath, HMS_KIT_CONFIG_PATH, `./${name}${JSON_SUFFIX}`); @@ -1209,7 +1209,7 @@ export function isMixedCompilerSDKPath(compilerOptions: CompilerOptions): boolea if (!compilerOptions.etsLoaderPath) { return false; } - if (normalizePath(compilerOptions.etsLoaderPath).endsWith('ets1.1/build-tools/ets-loader')) { + if (normalizePath(compilerOptions.etsLoaderPath).endsWith('dynamic/build-tools/ets-loader')) { return true; } return false;