UNPKG

@carbon/icons-angular

Version:

Angular components for icons in digital and software products using the Carbon Design System

169 lines (166 loc) 15.6 kB
import { __decorate, __metadata } from 'tslib'; import { Input, Component, ElementRef, Directive, NgModule } from '@angular/core'; import { getAttributes } from '@carbon/icon-helpers'; var WorshipMuslimComponent = /** @class */ (function () { function WorshipMuslimComponent() { this.focusable = false; } __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimComponent.prototype, "ariaLabel", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimComponent.prototype, "ariaLabelledby", void 0); __decorate([ Input(), __metadata("design:type", Boolean) ], WorshipMuslimComponent.prototype, "ariaHidden", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimComponent.prototype, "title", void 0); __decorate([ Input(), __metadata("design:type", Boolean) ], WorshipMuslimComponent.prototype, "focusable", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimComponent.prototype, "innerClass", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimComponent.prototype, "size", void 0); WorshipMuslimComponent = __decorate([ Component({ selector: "ibm-icon-worship-muslim", template: "\n <svg\n ibmIconWorshipMuslim\n [size]=\"size\"\n [ariaLabel]=\"ariaLabel\"\n [ariaLabelledby]=\"ariaLabelledby\"\n [ariaHidden]=\"ariaHidden\"\n [title]=\"title\"\n [isFocusable]=\"focusable\"\n [attr.class]=\"innerClass\">\n </svg>\n " }) ], WorshipMuslimComponent); return WorshipMuslimComponent; }()); var WorshipMuslimDirective = /** @class */ (function () { function WorshipMuslimDirective(elementRef) { this.elementRef = elementRef; this.isFocusable = false; this.icons = { "32": { metadata: { "moduleName": "WorshipMuslim32", "filepath": "worship--muslim/32.js", "descriptor": { "elem": "svg", "attrs": { "xmlns": "http://www.w3.org/2000/svg", "viewBox": "0 0 32 32", "fill": "currentColor", "width": 32, "height": 32 }, "content": [{ "elem": "path", "attrs": { "d": "M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z" } }, { "elem": "path", "attrs": { "d": "M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z" } }], "name": "worship--muslim", "size": 32 }, "size": 32 }, svg: "<svg focusable=\"false\" preserveAspectRatio=\"xMidYMid meet\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"currentColor\" width=\"32\" height=\"32\" viewBox=\"0 0 32 32\" aria-hidden=\"true\"><path d=\"M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z\"></path><path d=\"M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z\"></path></svg>" }, "24": { metadata: { "moduleName": "WorshipMuslim24", "filepath": "worship--muslim/24.js", "descriptor": { "elem": "svg", "attrs": { "xmlns": "http://www.w3.org/2000/svg", "viewBox": "0 0 32 32", "fill": "currentColor", "width": 24, "height": 24 }, "content": [{ "elem": "path", "attrs": { "d": "M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z" } }, { "elem": "path", "attrs": { "d": "M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z" } }], "name": "worship--muslim", "size": 24 }, "size": 24 }, svg: "<svg focusable=\"false\" preserveAspectRatio=\"xMidYMid meet\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"currentColor\" width=\"24\" height=\"24\" viewBox=\"0 0 32 32\" aria-hidden=\"true\"><path d=\"M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z\"></path><path d=\"M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z\"></path></svg>" }, "20": { metadata: { "moduleName": "WorshipMuslim20", "filepath": "worship--muslim/20.js", "descriptor": { "elem": "svg", "attrs": { "xmlns": "http://www.w3.org/2000/svg", "viewBox": "0 0 32 32", "fill": "currentColor", "width": 20, "height": 20 }, "content": [{ "elem": "path", "attrs": { "d": "M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z" } }, { "elem": "path", "attrs": { "d": "M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z" } }], "name": "worship--muslim", "size": 20 }, "size": 20 }, svg: "<svg focusable=\"false\" preserveAspectRatio=\"xMidYMid meet\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"currentColor\" width=\"20\" height=\"20\" viewBox=\"0 0 32 32\" aria-hidden=\"true\"><path d=\"M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z\"></path><path d=\"M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z\"></path></svg>" }, "16": { metadata: { "moduleName": "WorshipMuslim16", "filepath": "worship--muslim/16.js", "descriptor": { "elem": "svg", "attrs": { "xmlns": "http://www.w3.org/2000/svg", "viewBox": "0 0 32 32", "fill": "currentColor", "width": 16, "height": 16 }, "content": [{ "elem": "path", "attrs": { "d": "M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z" } }, { "elem": "path", "attrs": { "d": "M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z" } }], "name": "worship--muslim", "size": 16 }, "size": 16 }, svg: "<svg focusable=\"false\" preserveAspectRatio=\"xMidYMid meet\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"currentColor\" width=\"16\" height=\"16\" viewBox=\"0 0 32 32\" aria-hidden=\"true\"><path d=\"M27,18a.9986.9986,0,0,1-.5415-.1594L22,14.9688l-4.4585,2.8718a1,1,0,0,1-1.5088-1.095l1.35-5.1318L14.3105,8.69a1,1,0,0,1,.5508-1.7146l4.3745-.6128,1.8663-3.8032A1.0008,1.0008,0,0,1,21.9878,2a1.0171,1.0171,0,0,1,.8989.5378L24.88,6.3625l4.2622.6133A1,1,0,0,1,29.69,8.69l-3.0723,2.9239,1.35,5.1318A1,1,0,0,1,27,18Zm-5-5.2207a.999.999,0,0,1,.5415.1594l2.8369,1.8272-.8457-3.2149a1.0006,1.0006,0,0,1,.2778-.9787l2.0074-1.91-2.73-.3929a.9994.9994,0,0,1-.7441-.5275L22.0269,5.2151,20.7979,7.72a1.0008,1.0008,0,0,1-.7593.55L17.19,8.6687l2,1.9036a1.0006,1.0006,0,0,1,.2778.9787l-.8457,3.2149,2.8369-1.8272A.999.999,0,0,1,22,12.7793Z\"></path><path d=\"M15.8169,30A13.8137,13.8137,0,0,1,9.0752,4.1277a1,1,0,0,1,1.3613,1.3611A11.8091,11.8091,0,0,0,26.5107,21.5635a1,1,0,0,1,1.3619,1.3611A13.8411,13.8411,0,0,1,15.8169,30ZM7.3271,7.9727a11.81,11.81,0,0,0,16.7,16.7,13.8086,13.8086,0,0,1-16.7-16.7Z\"></path></svg>" }, }; } WorshipMuslimDirective_1 = WorshipMuslimDirective; WorshipMuslimDirective.prototype.ngAfterViewInit = function () { var svg = this.elementRef.nativeElement; svg.setAttribute("xmlns", "http://www.w3.org/2000/svg"); var icon = this.icons[this.size]; var domParser = new DOMParser(); var rawSVG = icon.svg; var svgElement = domParser.parseFromString(rawSVG, "image/svg+xml").documentElement; var node = svgElement.firstChild; while (node) { // importNode makes a clone of the node // this ensures we keep looping over the nodes in the parsed document svg.appendChild(svg.ownerDocument.importNode(node, true)); node = node.nextSibling; } var attributes = getAttributes({ width: icon.metadata.descriptor.attrs.height, height: icon.metadata.descriptor.attrs.height, viewBox: icon.metadata.descriptor.attrs.viewBox, title: this.title, "aria-label": this.ariaLabel, "aria-labelledby": this.ariaLabelledby, "aria-hidden": this.ariaHidden, focusable: this.isFocusable.toString() }); var attrKeys = Object.keys(attributes); for (var i = 0; i < attrKeys.length; i++) { var key = attrKeys[i]; var value = attributes[key]; if (key === "title") { continue; } if (value) { svg.setAttribute(key, value); } } if (attributes.title) { var title = document.createElement("title"); title.textContent = attributes.title; WorshipMuslimDirective_1.titleIdCounter++; title.setAttribute("id", "worship-muslim-" + WorshipMuslimDirective_1.titleIdCounter); svg.appendChild(title); svg.setAttribute("aria-labelledby", "worship-muslim-" + WorshipMuslimDirective_1.titleIdCounter); } }; var WorshipMuslimDirective_1; WorshipMuslimDirective.titleIdCounter = 0; WorshipMuslimDirective.ctorParameters = function () { return [ { type: ElementRef } ]; }; __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimDirective.prototype, "ariaLabel", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimDirective.prototype, "ariaLabelledby", void 0); __decorate([ Input(), __metadata("design:type", Boolean) ], WorshipMuslimDirective.prototype, "ariaHidden", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimDirective.prototype, "title", void 0); __decorate([ Input(), __metadata("design:type", Boolean) ], WorshipMuslimDirective.prototype, "isFocusable", void 0); __decorate([ Input(), __metadata("design:type", String) ], WorshipMuslimDirective.prototype, "size", void 0); WorshipMuslimDirective = WorshipMuslimDirective_1 = __decorate([ Directive({ selector: "[ibmIconWorshipMuslim]" }), __metadata("design:paramtypes", [ElementRef]) ], WorshipMuslimDirective); return WorshipMuslimDirective; }()); var WorshipMuslimModule = /** @class */ (function () { function WorshipMuslimModule() { } WorshipMuslimModule = __decorate([ NgModule({ declarations: [ WorshipMuslimComponent, WorshipMuslimDirective, ], exports: [ WorshipMuslimComponent, WorshipMuslimDirective, ] }) ], WorshipMuslimModule); return WorshipMuslimModule; }()); export { WorshipMuslimComponent, WorshipMuslimDirective, WorshipMuslimModule };