@basthon/kernel-base 0.36.2 → 0.36.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/lib/kernel.d.ts +1 -1
- package/lib/kernel.js +7 -4
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +2 -2
package/lib/kernel.d.ts
CHANGED
|
@@ -57,7 +57,7 @@ export declare class KernelBase {
|
|
|
57
57
|
* Root for kernel files. This is always the versnion number
|
|
58
58
|
* directory inside the kernel directory.
|
|
59
59
|
*/
|
|
60
|
-
basthonRoot(): string;
|
|
60
|
+
basthonRoot(absolute?: boolean): string;
|
|
61
61
|
/**
|
|
62
62
|
* Downloading data (bytes array) as filename
|
|
63
63
|
* (opening browser dialog).
|
package/lib/kernel.js
CHANGED
|
@@ -113,7 +113,6 @@ export class KernelBase {
|
|
|
113
113
|
this.addEventListener("eval.request", this.evalFromEvent.bind(this));
|
|
114
114
|
this._loaded.resolve();
|
|
115
115
|
}
|
|
116
|
-
;
|
|
117
116
|
/**
|
|
118
117
|
* Promise that resolve when the kernel is loaded.
|
|
119
118
|
*/
|
|
@@ -122,10 +121,14 @@ export class KernelBase {
|
|
|
122
121
|
* Root for kernel files. This is always the versnion number
|
|
123
122
|
* directory inside the kernel directory.
|
|
124
123
|
*/
|
|
125
|
-
basthonRoot() {
|
|
126
|
-
|
|
124
|
+
basthonRoot(absolute = false) {
|
|
125
|
+
let url = this._rootPath + "/" + this.version();
|
|
126
|
+
if (absolute && !url.startsWith("http")) {
|
|
127
|
+
const base = window.location.origin + window.location.pathname;
|
|
128
|
+
url = base.substring(0, base.lastIndexOf('/')) + "/" + url;
|
|
129
|
+
}
|
|
130
|
+
return url;
|
|
127
131
|
}
|
|
128
|
-
;
|
|
129
132
|
/**
|
|
130
133
|
* Downloading data (bytes array) as filename
|
|
131
134
|
* (opening browser dialog).
|
package/lib/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "0.36.
|
|
1
|
+
export declare const VERSION = "0.36.6";
|
package/lib/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = "0.36.
|
|
1
|
+
export const VERSION = "0.36.6";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@basthon/kernel-base",
|
|
3
|
-
"version": "0.36.
|
|
3
|
+
"version": "0.36.6",
|
|
4
4
|
"description": "Basthon - Base Kernel",
|
|
5
5
|
"homepage": "https://basthon.fr",
|
|
6
6
|
"bugs": {
|
|
@@ -36,5 +36,5 @@
|
|
|
36
36
|
"publishConfig": {
|
|
37
37
|
"access": "public"
|
|
38
38
|
},
|
|
39
|
-
"gitHead": "
|
|
39
|
+
"gitHead": "fb7ba80accf982becc0fd5f5d64e09b4e4c2096c"
|
|
40
40
|
}
|