@ngxi/vscode-icons 0.12.0-beta.11 → 0.12.0-beta.3
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.js +25 -24
- package/dist/index.js.map +1 -1
- package/dist/lib/vscode-icons.d.ts +0 -5
- package/package.json +30 -31
package/dist/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { inject,
|
|
2
|
+
import { inject, input, computed, Directive } from "@angular/core";
|
|
3
|
+
import { DomSanitizer } from "@angular/platform-browser";
|
|
3
4
|
const vscodeIconsDefaultFile = {
|
|
4
5
|
"body": '<path fill="#c5c5c5" d="M20.414 2H5v28h22V8.586ZM7 28V4h12v6h6v18Z"/>',
|
|
5
6
|
"width": 32,
|
|
@@ -8358,10 +8359,19 @@ const vscodeIconsFileTypeMakefile = {
|
|
|
8358
8359
|
"height": 32,
|
|
8359
8360
|
"viewBox": "0 0 32 32"
|
|
8360
8361
|
};
|
|
8362
|
+
function __decorate(decorators, target, key, desc) {
|
|
8363
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
8364
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
8365
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
8366
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
8367
|
+
}
|
|
8368
|
+
typeof SuppressedError === "function" ? SuppressedError : function(error, suppressed, message) {
|
|
8369
|
+
var e = new Error(message);
|
|
8370
|
+
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
8371
|
+
};
|
|
8361
8372
|
class Ngxi {
|
|
8362
8373
|
constructor() {
|
|
8363
|
-
this.
|
|
8364
|
-
this.renderer = inject(Renderer2);
|
|
8374
|
+
this.sanitizer = inject(DomSanitizer);
|
|
8365
8375
|
this.icon = input(null);
|
|
8366
8376
|
this.width = input();
|
|
8367
8377
|
this.height = input();
|
|
@@ -8369,19 +8379,16 @@ class Ngxi {
|
|
|
8369
8379
|
this.resolvedWidth = computed(() => this.width() ?? this.icon()?.width);
|
|
8370
8380
|
this.resolvedHeight = computed(() => this.height() ?? this.icon()?.height);
|
|
8371
8381
|
this.resolvedViewBox = computed(() => this.viewBox() ?? this.icon()?.viewBox);
|
|
8372
|
-
this.
|
|
8373
|
-
const icon = this.icon();
|
|
8374
|
-
this.renderer.setProperty(this.el.nativeElement, "innerHTML", icon?.body ?? "");
|
|
8375
|
-
});
|
|
8382
|
+
this.resolvedBody = computed(() => this.sanitizer.bypassSecurityTrustHtml(this.icon()?.body ?? ""));
|
|
8376
8383
|
}
|
|
8377
8384
|
static {
|
|
8378
|
-
this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
8385
|
+
this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: Ngxi, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
8379
8386
|
}
|
|
8380
8387
|
static {
|
|
8381
|
-
this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
8388
|
+
this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.0.4", type: Ngxi, isStandalone: true, selector: "svg[ngxi]", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, height: { classPropertyName: "height", publicName: "height", isSignal: true, isRequired: false, transformFunction: null }, viewBox: { classPropertyName: "viewBox", publicName: "viewBox", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "img" }, properties: { "attr.width": "resolvedWidth()", "attr.height": "resolvedHeight()", "attr.viewBox": "resolvedViewBox()", "innerHTML": "resolvedBody()" } }, ngImport: i0 });
|
|
8382
8389
|
}
|
|
8383
8390
|
}
|
|
8384
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
8391
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.4", ngImport: i0, type: Ngxi, decorators: [{
|
|
8385
8392
|
type: Directive,
|
|
8386
8393
|
args: [{
|
|
8387
8394
|
standalone: true,
|
|
@@ -8390,24 +8397,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
8390
8397
|
"role": "img",
|
|
8391
8398
|
"[attr.width]": "resolvedWidth()",
|
|
8392
8399
|
"[attr.height]": "resolvedHeight()",
|
|
8393
|
-
"[attr.viewBox]": "resolvedViewBox()"
|
|
8400
|
+
"[attr.viewBox]": "resolvedViewBox()",
|
|
8401
|
+
"[innerHTML]": "resolvedBody()"
|
|
8394
8402
|
}
|
|
8395
8403
|
}]
|
|
8396
8404
|
}] });
|
|
8397
|
-
|
|
8405
|
+
let NgxiVscodeIcons = class NgxiVscodeIcons2 {
|
|
8398
8406
|
constructor() {
|
|
8399
8407
|
this.ngxiVscodeIcons = input.required();
|
|
8400
8408
|
}
|
|
8401
|
-
|
|
8402
|
-
|
|
8403
|
-
|
|
8404
|
-
static {
|
|
8405
|
-
this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "18.2.13", type: NgxiVscodeIcons, isStandalone: true, selector: "svg[ngxiVscodeIcons]", inputs: { ngxiVscodeIcons: { classPropertyName: "ngxiVscodeIcons", publicName: "ngxiVscodeIcons", isSignal: true, isRequired: true, transformFunction: null } }, hostDirectives: [{ directive: Ngxi, inputs: ["icon", "ngxiVscodeIcons", "width", "width", "height", "height", "viewBox", "viewBox"] }], ngImport: i0 });
|
|
8406
|
-
}
|
|
8407
|
-
}
|
|
8408
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: NgxiVscodeIcons, decorators: [{
|
|
8409
|
-
type: Directive,
|
|
8410
|
-
args: [{
|
|
8409
|
+
};
|
|
8410
|
+
NgxiVscodeIcons = __decorate([
|
|
8411
|
+
Directive({
|
|
8411
8412
|
standalone: true,
|
|
8412
8413
|
selector: "svg[ngxiVscodeIcons]",
|
|
8413
8414
|
hostDirectives: [
|
|
@@ -8416,8 +8417,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
|
8416
8417
|
inputs: ["icon:ngxiVscodeIcons", "width", "height", "viewBox"]
|
|
8417
8418
|
}
|
|
8418
8419
|
]
|
|
8419
|
-
}
|
|
8420
|
-
|
|
8420
|
+
})
|
|
8421
|
+
], NgxiVscodeIcons);
|
|
8421
8422
|
export {
|
|
8422
8423
|
NgxiVscodeIcons,
|
|
8423
8424
|
vscodeIconsDefaultFile,
|