1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-15 07:43:35 +00:00

Add type=button to stories (#12930)

This commit is contained in:
Oscar Hinton
2025-01-17 14:57:31 +01:00
committed by GitHub
parent 2726b3a957
commit dafeb1492a
9 changed files with 46 additions and 22 deletions

View File

@@ -16,6 +16,7 @@ import { DialogModule } from "../../dialog.module";
<h2>{{ group.title }}</h2>
<div class="tw-mb-4 tw-flex tw-flex-row tw-gap-2">
<button
type="button"
*ngFor="let dialog of group.dialogs"
bitButton
(click)="openSimpleConfigurableDialog(dialog)"

View File

@@ -17,7 +17,7 @@ interface Animal {
}
@Component({
template: `<button bitButton (click)="openDialog()">Open Simple Dialog</button>`,
template: `<button type="button" bitButton (click)="openDialog()">Open Simple Dialog</button>`,
})
class StoryDialogComponent {
constructor(public dialogService: DialogService) {}
@@ -41,8 +41,10 @@ class StoryDialogComponent {
Animal: {{ animal }}
</span>
<ng-container bitDialogFooter>
<button bitButton buttonType="primary" (click)="dialogRef.close()">Save</button>
<button bitButton buttonType="secondary" bitDialogClose>Cancel</button>
<button type="button" bitButton buttonType="primary" (click)="dialogRef.close()">
Save
</button>
<button type="button" bitButton buttonType="secondary" bitDialogClose>Cancel</button>
</ng-container>
</bit-simple-dialog>
`,