1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-01-02 18:17:46 +01:00

[CL-62] Add missing modules to Dialog Service story

The IconButtonModule and SharedModule need to be available for the service to properly open the dialog.

Also fix type error for dialogSize attribute
This commit is contained in:
Shane Melton 2022-11-01 10:58:33 -07:00
parent 7c4f3ac5e9
commit 197e0b7d5a
No known key found for this signature in database

View File

@ -1,10 +1,12 @@
import { DialogModule, DialogRef, DIALOG_DATA } from "@angular/cdk/dialog";
import { DIALOG_DATA, DialogModule, DialogRef } from "@angular/cdk/dialog";
import { Component, Inject } from "@angular/core";
import { Meta, moduleMetadata, Story } from "@storybook/angular";
import { I18nService } from "@bitwarden/common/abstractions/i18n.service";
import { ButtonModule } from "../button";
import { IconButtonModule } from "../icon-button";
import { SharedModule } from "../shared";
import { I18nMockService } from "../utils/i18n-mock.service";
import { DialogService } from "./dialog.service";
@ -35,7 +37,7 @@ class StoryDialogComponent {
@Component({
selector: "story-dialog-content",
template: `
<bit-dialog [dialogSize]="large">
<bit-dialog dialogSize="large">
<span bitDialogTitle>Dialog Title</span>
<span bitDialogContent>
Dialog body text goes here.
@ -68,7 +70,7 @@ export default {
DialogTitleContainerDirective,
StoryDialogContentComponent,
],
imports: [ButtonModule, DialogModule],
imports: [SharedModule, ButtonModule, DialogModule, IconButtonModule],
providers: [
DialogService,
{