@digipair/skill-vespa 0.15.4 → 0.16.1
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/index.cjs.js +2 -1
- package/index.esm.js +2 -1
- package/package.json +1 -1
package/index.cjs.js
CHANGED
@@ -71960,6 +71960,7 @@ const _config = globalInstance.__DIGIPAIR_CONFIG__ = (_globalInstance___DIGIPAIR
|
|
71960
71960
|
LIBRARIES: {},
|
71961
71961
|
BASE_URL: 'https://cdn.jsdelivr.net/npm'
|
71962
71962
|
};
|
71963
|
+
const isRemoteVersion = /^https?:\/\/[^\s/$.?#].[^\s]*$/;
|
71963
71964
|
const isPinsSettings = (value)=>{
|
71964
71965
|
return typeof value === 'object' && value !== null && typeof value.element === 'string' && typeof value.library === 'string';
|
71965
71966
|
};
|
@@ -72016,7 +72017,7 @@ const executePins = async (settingsOrigin, context = {})=>{
|
|
72016
72017
|
return results;
|
72017
72018
|
}
|
72018
72019
|
const version = context.config.VERSIONS[settings.library] || 'latest';
|
72019
|
-
const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await (function (t) { return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(t)); }); })(`${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
|
72020
|
+
const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await (function (t) { return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require(t)); }); })(isRemoteVersion.test(version) ? `${version}` : `${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
|
72020
72021
|
const pins = library == null ? void 0 : library[settings.element];
|
72021
72022
|
if (!pins) {
|
72022
72023
|
throw new Error(`Element ${settings.element} not found in library ${settings.library}`);
|
package/index.esm.js
CHANGED
@@ -71938,6 +71938,7 @@ const _config = globalInstance.__DIGIPAIR_CONFIG__ = (_globalInstance___DIGIPAIR
|
|
71938
71938
|
LIBRARIES: {},
|
71939
71939
|
BASE_URL: 'https://cdn.jsdelivr.net/npm'
|
71940
71940
|
};
|
71941
|
+
const isRemoteVersion = /^https?:\/\/[^\s/$.?#].[^\s]*$/;
|
71941
71942
|
const isPinsSettings = (value)=>{
|
71942
71943
|
return typeof value === 'object' && value !== null && typeof value.element === 'string' && typeof value.library === 'string';
|
71943
71944
|
};
|
@@ -71994,7 +71995,7 @@ const executePins = async (settingsOrigin, context = {})=>{
|
|
71994
71995
|
return results;
|
71995
71996
|
}
|
71996
71997
|
const version = context.config.VERSIONS[settings.library] || 'latest';
|
71997
|
-
const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await import(`${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
|
71998
|
+
const library = _config.LIBRARIES[settings.library] || (typeof window === 'undefined' ? require(settings.library) : await import(isRemoteVersion.test(version) ? `${version}` : `${_config.BASE_URL}/${settings.library}@${version}/index.esm.js`));
|
71998
71999
|
const pins = library == null ? void 0 : library[settings.element];
|
71999
72000
|
if (!pins) {
|
72000
72001
|
throw new Error(`Element ${settings.element} not found in library ${settings.library}`);
|