update intellisense

This commit is contained in:
Jacob Overgaard
2024-02-13 14:04:24 +01:00
parent cc2b6e8156
commit 70f9574c42

View File

@@ -38,19 +38,38 @@ export interface UmbracoPackage {
* @description This is used to define the imports and the scopes for the package to be used in the browser. It will be combined with the global importmap.
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap
*/
importmap?: {
/**
* @title The imports for the package
* @required
* @minProperties 1
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap#imports
*/
imports: Record<string, string>;
/**
* @title The scopes for the package
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap#scopes
*/
scopes?: Record<string, Record<string, string>>;
};
importmap?: UmbracoPackageImportmap;
}
export interface UmbracoPackageImportmap {
/**
* @title A module specifier with a path for the importmap
* @description This is used to define the module specifiers and their respective paths for the package to be used in the browser.
* @examples [{
* "library": "./path/to/library.js",
* "library/*": "./path/to/library/*"
* }]
* @required
* @minProperties 1
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap#imports
*/
imports: UmbracoPackageImportmapValue;
/**
* @title The importmap scopes for the package
* @description This is used to define the scopes for the package to be used in the browser. It has to specify a path and a value that is an object with module specifiers and their respective paths.
* @examples [{
* "/path/to/library": { "library": "./path/to/some/other/library.js" }
* }]
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script/type/importmap#scopes
*/
scopes?: UmbracoPackageImportmapScopes;
}
export interface UmbracoPackageImportmapScopes {
[key: string]: UmbracoPackageImportmapValue;
}
export interface UmbracoPackageImportmapValue {
[key: string]: string;
}