mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 16:23:44 +00:00
[PM-28231] Enable component-class-suffix (#17384)
* Enable component-class-suffix * Rename file
This commit is contained in:
@@ -11,19 +11,19 @@ import { RadioButtonComponent } from "./radio-button.component";
|
||||
import { RadioButtonModule } from "./radio-button.module";
|
||||
|
||||
describe("RadioGroupComponent", () => {
|
||||
let fixture: ComponentFixture<TestApp>;
|
||||
let testAppComponent: TestApp;
|
||||
let fixture: ComponentFixture<TestAppComponent>;
|
||||
let testAppComponent: TestAppComponent;
|
||||
let buttonElements: RadioButtonComponent[];
|
||||
let radioButtons: HTMLInputElement[];
|
||||
|
||||
beforeEach(async () => {
|
||||
TestBed.configureTestingModule({
|
||||
imports: [TestApp],
|
||||
imports: [TestAppComponent],
|
||||
providers: [{ provide: I18nService, useValue: new I18nMockService({}) }],
|
||||
});
|
||||
|
||||
await TestBed.compileComponents();
|
||||
fixture = TestBed.createComponent(TestApp);
|
||||
fixture = TestBed.createComponent(TestAppComponent);
|
||||
fixture.detectChanges();
|
||||
testAppComponent = fixture.debugElement.componentInstance;
|
||||
buttonElements = fixture.debugElement
|
||||
@@ -76,6 +76,6 @@ describe("RadioGroupComponent", () => {
|
||||
`,
|
||||
imports: [FormsModule, RadioButtonModule],
|
||||
})
|
||||
class TestApp {
|
||||
class TestAppComponent {
|
||||
selected?: string;
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@ import { ControlValueAccessor, NgControl, Validators } from "@angular/forms";
|
||||
|
||||
import { I18nPipe } from "@bitwarden/ui-common";
|
||||
|
||||
import { BitLabel } from "../form-control/label.component";
|
||||
import { BitLabelComponent } from "../form-control/label.component";
|
||||
|
||||
let nextId = 0;
|
||||
|
||||
@@ -32,7 +32,7 @@ export class RadioGroupComponent implements ControlValueAccessor {
|
||||
readonly id = input(`bit-radio-group-${nextId++}`);
|
||||
@HostBinding("class") classList = ["tw-block", "tw-mb-4"];
|
||||
|
||||
protected readonly label = contentChild(BitLabel);
|
||||
protected readonly label = contentChild(BitLabelComponent);
|
||||
|
||||
constructor(@Optional() @Self() private ngControl?: NgControl) {
|
||||
if (ngControl != null) {
|
||||
|
||||
Reference in New Issue
Block a user