opticore-webapp-core 1.0.5 → 1.0.6

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/index.cjs CHANGED
@@ -1149,13 +1149,13 @@ var PathModuleVerifier = class {
1149
1149
 
1150
1150
  // src/core/config/loaders/translateLanguage.loader.ts
1151
1151
  var import_path3 = __toESM(require("path"), 1);
1152
+ var import_module = require("module");
1152
1153
  var import_opticore_translator11 = require("opticore-translator");
1153
1154
  var import_opticore_env_access4 = require("opticore-env-access");
1154
- var import_url = require("url");
1155
1155
  var translateWebAppCoreLanguageLoader = () => {
1156
- const __filename2 = (0, import_url.fileURLToPath)(importMetaUrl);
1157
- const __dirname = import_path3.default.dirname(__filename2);
1158
- const translateMsgJsonFilePath = import_path3.default.join(__dirname, "../../../../", "dist", "utils", "translations");
1156
+ const require2 = (0, import_module.createRequire)(importMetaUrl);
1157
+ const packagePath = import_path3.default.dirname(require2.resolve("opticore-webapp-core"));
1158
+ const translateMsgJsonFilePath = import_path3.default.join(packagePath, "utils", "translations");
1159
1159
  import_opticore_translator11.TranslationLoader.loadTranslations(translateMsgJsonFilePath, import_opticore_env_access4.getEnvVariable.defaultLocal);
1160
1160
  };
1161
1161
 
package/dist/index.js CHANGED
@@ -1098,13 +1098,13 @@ var PathModuleVerifier = class {
1098
1098
 
1099
1099
  // src/core/config/loaders/translateLanguage.loader.ts
1100
1100
  import path2 from "path";
1101
+ import { createRequire } from "module";
1101
1102
  import { TranslationLoader as TranslationLoader11 } from "opticore-translator";
1102
1103
  import { getEnvVariable as getEnvVariable4 } from "opticore-env-access";
1103
- import { fileURLToPath } from "url";
1104
1104
  var translateWebAppCoreLanguageLoader = () => {
1105
- const __filename2 = fileURLToPath(import.meta.url);
1106
- const __dirname2 = path2.dirname(__filename2);
1107
- const translateMsgJsonFilePath = path2.join(__dirname2, "../../../../", "dist", "utils", "translations");
1105
+ const require2 = createRequire(import.meta.url);
1106
+ const packagePath = path2.dirname(require2.resolve("opticore-webapp-core"));
1107
+ const translateMsgJsonFilePath = path2.join(packagePath, "utils", "translations");
1108
1108
  TranslationLoader11.loadTranslations(translateMsgJsonFilePath, getEnvVariable4.defaultLocal);
1109
1109
  };
1110
1110
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opticore-webapp-core",
3
- "version": "1.0.5",
3
+ "version": "1.0.6",
4
4
  "description": "opticore Web Application core module",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",