Skip to content

Commit

Permalink
fix: review
Browse files Browse the repository at this point in the history
  • Loading branch information
dauriamarco committed Jan 11, 2024
1 parent 8d9c014 commit cfa06fb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/notification/notification.ts
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ export class SbbNotificationElement extends LitElement {

public override connectedCallback(): void {
super.connectedCallback();
this.role = this.role ?? 'status';

This comment has been minimized.

Copy link
@jeripeierSBB

jeripeierSBB Jan 11, 2024

Contributor

Does the new solution really works? can you overwrite and can you overwrite at any time?

this._handlerRepository.connect();
this._setInlineLinks();
}
Expand Down Expand Up @@ -202,7 +203,7 @@ export class SbbNotificationElement extends LitElement {
protected override render(): TemplateResult {
const hasTitle = !!this.titleContent || this._namedSlots['title'];

setAttribute(this, 'role', 'status');
setAttribute(this, 'role', this.role);
setAttribute(this, 'data-state', this._state);
setAttribute(this, 'data-has-title', hasTitle);

Expand Down

0 comments on commit cfa06fb

Please sign in to comment.