clickgo-native 1.0.2 → 1.0.4

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.
Files changed (2) hide show
  1. package/dist/index.js +2 -2
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -463,7 +463,7 @@ export class AbstractBoot {
463
463
  * @param p 要加载的相对路径,如 ./index.html
464
464
  */
465
465
  export function path(importUrl, p) {
466
- const url = importUrl.replace('file:///', '');
466
+ const url = decodeURIComponent(importUrl).replace('file://', '').replace(/^\/(\w:)/, '$1');
467
467
  return nodePath.join(url.slice(0, url.lastIndexOf('/') + 1), p);
468
468
  }
469
469
  export function showMainForm(path, opt = {}) {
@@ -535,7 +535,7 @@ export function verifyToken(t) {
535
535
  * @param p 窗体网页路径
536
536
  */
537
537
  function createForm(p, opt = {}) {
538
- const url = import.meta.url.replace('file:///', '');
538
+ const url = decodeURIComponent(import.meta.url).replace('file://', '').replace(/^\/(\w:)/, '$1');
539
539
  let pre = nodePath.join(url.slice(0, url.lastIndexOf('/') + 1), './pre.js');
540
540
  const op = {
541
541
  'webPreferences': {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clickgo-native",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "description": "The software developed with ClickGo will run in Windows, Mac OS, Linux.",
5
5
  "type": "module",
6
6
  "keywords": [