Skip to content
Snippets Groups Projects
Commit 5bf10188 authored by OZGCloud's avatar OZGCloud
Browse files

Rename document to attachment

parent e15466db
No related branches found
No related tags found
No related merge requests found
export * from './lib/testbtn/testbtn.component';
export * from './lib/form/radio-button-card/radio-button-card.component';
export * from './lib/document/document.component';
export * from './lib/attachment/attachment.component';
export * from './lib/download-icon/download-icon.component';
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { DocumentComponent } from './document.component';
import { AttachmentComponent } from './attachment.component';
import { ReactiveFormsModule } from '@angular/forms';
xdescribe('DocumentComponent', () => {
let component: DocumentComponent;
let fixture: ComponentFixture<DocumentComponent>;
xdescribe('AttachmentComponent', () => {
let component: AttachmentComponent;
let fixture: ComponentFixture<AttachmentComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [ReactiveFormsModule],
}).compileComponents();
fixture = TestBed.createComponent(DocumentComponent);
fixture = TestBed.createComponent(AttachmentComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
......
......@@ -12,9 +12,9 @@ interface IconArgs {
selector: 'ozg-document',
standalone: true,
imports: [CommonModule, FileIconComponent],
templateUrl: './document.component.html',
templateUrl: './attachment.component.html',
})
export class DocumentComponent {
export class AttachmentComponent {
@Input() documentName!: string;
@Input() description = '';
@Input() alone: boolean = false;
......
import { argsToTemplate, type Meta, type StoryObj } from '@storybook/angular';
import { DocumentComponent } from './document.component';
import { AttachmentComponent } from './attachment.component';
import { DownloadIconComponent } from '../download-icon/download-icon.component';
const meta: Meta<DocumentComponent> = {
title: 'Document',
component: DocumentComponent,
const meta: Meta<AttachmentComponent> = {
title: 'Attachment',
component: AttachmentComponent,
subcomponents: { DownloadIconComponent },
excludeStories: /.*Data$/,
tags: ['autodocs'],
};
export default meta;
type Story = StoryObj<DocumentComponent>;
type Story = StoryObj<AttachmentComponent>;
export const Default: Story = {
name: 'File with pdf icon',
......@@ -65,7 +65,7 @@ export const ContentInside: Story = {
description: '573 kB',
iconArgs: { type: "doc" },
},
render: (args: DocumentComponent) => ({
render: (args: AttachmentComponent) => ({
props: args,
template: `<ozg-document ${argsToTemplate(args)}><p>Hello!</p></ozg-document>`,
}),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment