import { Component, inject } from '@angular/core';

import { NzButtonModule } from 'ng-zorro-antd/button';
import { NzMessageService } from 'ng-zorro-antd/message';

@Component({
  selector: '<%= selector %>',
  imports: [NzButtonModule],
  <% if(inlineTemplate) { %>template: `<button nz-button nzType="primary" (click)="createNotification()">Open the notification box</button>`<% } else { %>templateUrl: './<%= dasherize(name) %>.component.html'<% } %>
})
export class <%= classify(name) %>Component {
  readonly #messageService = inject(NzMessageService);

  createNotification(): void {
    this.#messageService.success('This is the content of the notification', {
      nzStyle: {
        'margin-top': '20vh'
      },
      nzClass: 'custom-class'
    });
  }
}
