mirror of https://github.com/abpframework/abp.git
Browse Source
refactor: replace module imports with standalone components, directives, and pipes - Issue 23300pull/23161/merge
committed by
GitHub
50 changed files with 153 additions and 153 deletions
@ -1,9 +1,9 @@ |
|||||
import { Component } from '@angular/core'; |
import { Component } from '@angular/core'; |
||||
import { RouterModule } from '@angular/router'; |
import { RouterOutlet } from '@angular/router'; |
||||
|
|
||||
@Component({ |
@Component({ |
||||
selector: 'abp-router-outlet', |
selector: 'abp-router-outlet', |
||||
template: ` <router-outlet></router-outlet> `, |
template: ` <router-outlet></router-outlet> `, |
||||
imports: [RouterModule], |
imports: [RouterOutlet], |
||||
}) |
}) |
||||
export class RouterOutletComponent {} |
export class RouterOutletComponent {} |
||||
|
|||||
@ -1,15 +1,15 @@ |
|||||
import { AuthWrapperService } from '@abp/ng.account.core'; |
import { AuthWrapperService } from '@abp/ng.account.core'; |
||||
import { Component, inject } from '@angular/core'; |
import { Component, inject } from '@angular/core'; |
||||
import { CommonModule } from '@angular/common'; |
import { AsyncPipe } from '@angular/common'; |
||||
import { LocalizationPipe, ReplaceableTemplateDirective } from '@abp/ng.core'; |
import { LocalizationPipe, ReplaceableTemplateDirective } from '@abp/ng.core'; |
||||
import { TenantBoxComponent } from '../tenant-box/tenant-box.component'; |
import { TenantBoxComponent } from '../tenant-box/tenant-box.component'; |
||||
|
|
||||
@Component({ |
|
||||
selector: 'abp-auth-wrapper', |
|
||||
templateUrl: './auth-wrapper.component.html', |
|
||||
providers: [AuthWrapperService], |
|
||||
imports: [CommonModule, TenantBoxComponent, ReplaceableTemplateDirective, LocalizationPipe], |
|
||||
}) |
|
||||
export class AuthWrapperComponent {
service = inject(AuthWrapperService); |
|
||||
|
|
||||
} |
@Component({ |
||||
|
selector: 'abp-auth-wrapper', |
||||
|
templateUrl: './auth-wrapper.component.html', |
||||
|
providers: [AuthWrapperService], |
||||
|
imports: [AsyncPipe, TenantBoxComponent, ReplaceableTemplateDirective, LocalizationPipe], |
||||
|
}) |
||||
|
export class AuthWrapperComponent { |
||||
|
service = inject(AuthWrapperService); |
||||
|
} |
||||
@ -1,23 +1,23 @@ |
|||||
import { TenantBoxService } from '@abp/ng.account.core'; |
import { TenantBoxService } from '@abp/ng.account.core'; |
||||
import { Component, inject } from '@angular/core'; |
import { Component, inject } from '@angular/core'; |
||||
import { CommonModule } from '@angular/common'; |
import { AsyncPipe } from '@angular/common'; |
||||
import { LocalizationPipe } from '@abp/ng.core'; |
import { LocalizationPipe } from '@abp/ng.core'; |
||||
import { ButtonComponent, ModalCloseDirective, ModalComponent } from '@abp/ng.theme.shared'; |
import { ButtonComponent, ModalCloseDirective, ModalComponent } from '@abp/ng.theme.shared'; |
||||
import { FormsModule } from '@angular/forms'; |
import { FormsModule } from '@angular/forms'; |
||||
|
|
||||
@Component({ |
|
||||
selector: 'abp-tenant-box', |
|
||||
templateUrl: './tenant-box.component.html', |
|
||||
providers: [TenantBoxService], |
|
||||
imports: [ |
|
||||
CommonModule, |
|
||||
FormsModule, |
|
||||
ModalComponent, |
|
||||
LocalizationPipe, |
|
||||
ButtonComponent, |
|
||||
ModalCloseDirective, |
|
||||
], |
|
||||
}) |
|
||||
export class TenantBoxComponent {
service = inject(TenantBoxService); |
|
||||
|
|
||||
} |
@Component({ |
||||
|
selector: 'abp-tenant-box', |
||||
|
templateUrl: './tenant-box.component.html', |
||||
|
providers: [TenantBoxService], |
||||
|
imports: [ |
||||
|
AsyncPipe, |
||||
|
FormsModule, |
||||
|
ModalComponent, |
||||
|
LocalizationPipe, |
||||
|
ButtonComponent, |
||||
|
ModalCloseDirective, |
||||
|
], |
||||
|
}) |
||||
|
export class TenantBoxComponent { |
||||
|
service = inject(TenantBoxService); |
||||
|
} |
||||
|
|||||
@ -1,14 +1,14 @@ |
|||||
import { Component, ViewEncapsulation, inject } from '@angular/core'; |
import { Component, ViewEncapsulation, inject } from '@angular/core'; |
||||
import { PageAlertService } from '@abp/ng.theme.shared'; |
import { PageAlertService } from '@abp/ng.theme.shared'; |
||||
import { CommonModule } from '@angular/common'; |
import { NgClass, AsyncPipe } from '@angular/common'; |
||||
import { LocalizationPipe, SafeHtmlPipe } from '@abp/ng.core'; |
import { LocalizationPipe, SafeHtmlPipe } from '@abp/ng.core'; |
||||
|
|
||||
@Component({ |
|
||||
selector: 'abp-page-alert-container', |
|
||||
templateUrl: './page-alert-container.component.html', |
|
||||
encapsulation: ViewEncapsulation.None, |
|
||||
imports: [CommonModule, LocalizationPipe, SafeHtmlPipe], |
|
||||
}) |
|
||||
export class PageAlertContainerComponent {
service = inject(PageAlertService); |
|
||||
|
|
||||
} |
@Component({ |
||||
|
selector: 'abp-page-alert-container', |
||||
|
templateUrl: './page-alert-container.component.html', |
||||
|
encapsulation: ViewEncapsulation.None, |
||||
|
imports: [NgClass, AsyncPipe, LocalizationPipe, SafeHtmlPipe], |
||||
|
}) |
||||
|
export class PageAlertContainerComponent { |
||||
|
service = inject(PageAlertService); |
||||
|
} |
||||
|
|||||
Loading…
Reference in new issue