feat: svg atom

This commit is contained in:
2025-08-10 22:39:20 -03:00
parent 97fe1575dc
commit f38c1edc4c
3 changed files with 41 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
<svg [attr.width]="width()" [attr.height]="height()" [attr.fill]="color()">
<use [attr.href]="'/assets/fonts/remixicon.symbol.svg#'+symbol()"></use>
</svg>

After

Width:  |  Height:  |  Size: 157 B

View File

@@ -0,0 +1,23 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { SvgComponent } from './svg.component';
describe('SvgComponent', () => {
let component: SvgComponent;
let fixture: ComponentFixture<SvgComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [SvgComponent]
})
.compileComponents();
fixture = TestBed.createComponent(SvgComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

View File

@@ -0,0 +1,15 @@
import { Component, input } from '@angular/core';
@Component({
selector: 'mw-svg',
standalone: true,
imports: [],
templateUrl: './svg.component.html',
styles: ``
})
export class SvgComponent {
width = input("24px");
height = input("24px");
color = input("#000000");
symbol = input("");
}