Skip to content
Snippets Groups Projects
Commit 5e4c61eb authored by Alexander Reifschneider's avatar Alexander Reifschneider
Browse files

OZG-7510 OZG-7738 Add delete icon

parent ddb7bf96
No related branches found
No related tags found
1 merge request!63Ozg 7510 statistic edit delete fields
...@@ -52,6 +52,7 @@ export * from './lib/icons/bescheid-upload-icon/bescheid-upload-icon.component'; ...@@ -52,6 +52,7 @@ export * from './lib/icons/bescheid-upload-icon/bescheid-upload-icon.component';
export * from './lib/icons/check-circle-icon/check-circle-icon.component'; export * from './lib/icons/check-circle-icon/check-circle-icon.component';
export * from './lib/icons/check-icon/check-icon.component'; export * from './lib/icons/check-icon/check-icon.component';
export * from './lib/icons/close-icon/close-icon.component'; export * from './lib/icons/close-icon/close-icon.component';
export * from './lib/icons/delete-icon/delete-icon.component';
export * from './lib/icons/delete-vorgang-finally-icon/delete-vorgang-finally-icon.component'; export * from './lib/icons/delete-vorgang-finally-icon/delete-vorgang-finally-icon.component';
export * from './lib/icons/discard-vorgang-icon/discard-vorgang-icon.component'; export * from './lib/icons/discard-vorgang-icon/discard-vorgang-icon.component';
export * from './lib/icons/edit-icon/edit-icon.component'; export * from './lib/icons/edit-icon/edit-icon.component';
......
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { DeleteIconComponent } from './delete-icon.component';
describe('DeleteIconComponent', () => {
let component: DeleteIconComponent;
let fixture: ComponentFixture<DeleteIconComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [DeleteIconComponent],
}).compileComponents();
fixture = TestBed.createComponent(DeleteIconComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});
import { CommonModule } from '@angular/common';
import { Component, Input } from '@angular/core';
import { twMerge } from 'tailwind-merge';
import { IconVariants, iconVariants } from '../iconVariants';
@Component({
selector: 'ods-delete-icon',
standalone: true,
imports: [CommonModule],
template: `<svg
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
[ngClass]="[twMerge(iconVariants({ size }), 'fill-primary', class)]"
aria-hidden="true"
>
<path
d="M6.75 19C6.75 20.1 7.65 21 8.75 21H16.75C17.85 21 18.75 20.1 18.75 19V7H6.75V19ZM8.75 9H16.75V19H8.75V9ZM16.25 4L15.25 3H10.25L9.25 4H5.75V6H19.75V4H16.25Z"
/>
</svg> `,
})
export class DeleteIconComponent {
@Input() size: IconVariants['size'] = 'medium';
@Input() class: string = '';
readonly iconVariants = iconVariants;
readonly twMerge = twMerge;
}
import type { Meta, StoryObj } from '@storybook/angular';
import { DeleteIconComponent } from './delete-icon.component';
const meta: Meta<DeleteIconComponent> = {
title: 'Icons/Delete icon',
component: DeleteIconComponent,
excludeStories: /.*Data$/,
tags: ['autodocs'],
};
export default meta;
type Story = StoryObj<DeleteIconComponent>;
export const Default: Story = {
args: { size: 'large' },
argTypes: {
size: {
control: 'select',
options: ['small', 'medium', 'large', 'extra-large', 'full'],
description: 'Size of icon. Property "full" means 100%',
table: {
defaultValue: { summary: 'medium' },
},
},
},
};
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment