Reorganize client shared modules

This commit is contained in:
Chocobozzz 2020-06-23 14:10:17 +02:00 committed by Chocobozzz
parent 0c4bacbff5
commit 67ed6552b8
510 changed files with 2321 additions and 2251 deletions

View File

@ -1,10 +1,8 @@
import { Component, OnInit } from '@angular/core'
import { FollowService } from '@app/shared/instance/follow.service'
import { ComponentPagination, hasMoreItems } from '@app/shared/rest/component-pagination.model'
import { Notifier } from '@app/core'
import { RestService } from '@app/shared'
import { SortMeta } from 'primeng/api'
import { Subject } from 'rxjs'
import { Component, OnInit } from '@angular/core'
import { ComponentPagination, hasMoreItems, Notifier, RestService } from '@app/core'
import { InstanceFollowService } from '@app/shared/shared-instance'
@Component({
selector: 'my-about-follows',
@ -38,7 +36,7 @@ export class AboutFollowsComponent implements OnInit {
constructor (
private restService: RestService,
private notifier: Notifier,
private followService: FollowService
private followService: InstanceFollowService
) { }
ngOnInit () {

View File

@ -1,11 +1,11 @@
import { Component, OnInit, ViewChild, AfterViewChecked } from '@angular/core'
import { Notifier, ServerService } from '@app/core'
import { ContactAdminModalComponent } from '@app/+about/about-instance/contact-admin-modal.component'
import { InstanceService } from '@app/shared/instance/instance.service'
import { ServerConfig } from '@shared/models'
import { ActivatedRoute } from '@angular/router'
import { ResolverData } from './about-instance.resolver'
import { ViewportScroller } from '@angular/common'
import { AfterViewChecked, Component, OnInit, ViewChild } from '@angular/core'
import { ActivatedRoute } from '@angular/router'
import { ContactAdminModalComponent } from '@app/+about/about-instance/contact-admin-modal.component'
import { ServerService } from '@app/core'
import { InstanceService } from '@app/shared/shared-instance'
import { ServerConfig } from '@shared/models'
import { ResolverData } from './about-instance.resolver'
@Component({
selector: 'my-about-instance',

View File

@ -1,17 +1,16 @@
import { forkJoin } from 'rxjs'
import { map, switchMap } from 'rxjs/operators'
import { Injectable } from '@angular/core'
import { ActivatedRouteSnapshot, Resolve } from '@angular/router'
import { map, switchMap } from 'rxjs/operators'
import { forkJoin } from 'rxjs'
import { InstanceService } from '@app/shared/instance/instance.service'
import { InstanceService } from '@app/shared/shared-instance'
import { About } from '@shared/models/server'
export type ResolverData = { about: About, languages: string[], categories: string[] }
@Injectable()
export class AboutInstanceResolver implements Resolve<any> {
constructor (
private instanceService: InstanceService
) {}
constructor (private instanceService: InstanceService) {}
resolve (route: ActivatedRouteSnapshot) {
return this.instanceService.getAbout()

View File

@ -1,11 +1,10 @@
import { Component, OnInit, ViewChild } from '@angular/core'
import { Notifier, ServerService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { FormReactive, FormValidatorService, InstanceValidatorsService } from '@app/shared/shared-forms'
import { InstanceService } from '@app/shared/shared-instance'
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
import { FormReactive, InstanceValidatorsService } from '@app/shared'
import { InstanceService } from '@app/shared/instance/instance.service'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ServerConfig } from '@shared/models'
@Component({

View File

@ -1,5 +1,5 @@
import { Component, OnInit } from '@angular/core'
import { MarkdownService } from '@app/shared/renderer'
import { MarkdownService } from '@app/core'
@Component({
selector: 'my-about-peertube-contributors',

View File

@ -1,18 +1,25 @@
import { NgModule } from '@angular/core'
import { AboutFollowsComponent } from '@app/+about/about-follows/about-follows.component'
import { AboutInstanceComponent } from '@app/+about/about-instance/about-instance.component'
import { AboutInstanceResolver } from '@app/+about/about-instance/about-instance.resolver'
import { ContactAdminModalComponent } from '@app/+about/about-instance/contact-admin-modal.component'
import { AboutPeertubeContributorsComponent } from '@app/+about/about-peertube/about-peertube-contributors.component'
import { AboutPeertubeComponent } from '@app/+about/about-peertube/about-peertube.component'
import { SharedFormModule } from '@app/shared/shared-forms'
import { SharedGlobalIconModule } from '@app/shared/shared-icons'
import { SharedInstanceModule } from '@app/shared/shared-instance'
import { SharedMainModule } from '@app/shared/shared-main'
import { AboutRoutingModule } from './about-routing.module'
import { AboutComponent } from './about.component'
import { SharedModule } from '../shared'
import { AboutInstanceComponent } from '@app/+about/about-instance/about-instance.component'
import { AboutPeertubeComponent } from '@app/+about/about-peertube/about-peertube.component'
import { ContactAdminModalComponent } from '@app/+about/about-instance/contact-admin-modal.component'
import { AboutFollowsComponent } from '@app/+about/about-follows/about-follows.component'
import { AboutPeertubeContributorsComponent } from '@app/+about/about-peertube/about-peertube-contributors.component'
import { AboutInstanceResolver } from '@app/+about/about-instance/about-instance.resolver'
@NgModule({
imports: [
AboutRoutingModule,
SharedModule
SharedMainModule,
SharedFormModule,
SharedInstanceModule,
SharedGlobalIconModule
],
declarations: [

View File

@ -1,9 +1,8 @@
import { Component, OnDestroy, OnInit } from '@angular/core'
import { Account } from '@app/shared/account/account.model'
import { AccountService } from '@app/shared/account/account.service'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { Subscription } from 'rxjs'
import { MarkdownService } from '@app/shared/renderer'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { MarkdownService } from '@app/core'
import { Account, AccountService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
@Component({
selector: 'my-account-about',

View File

@ -1,16 +1,9 @@
import { from, Subject, Subscription } from 'rxjs'
import { concatMap, map, switchMap, tap } from 'rxjs/operators'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { User, UserService } from '@app/shared'
import { Account } from '@app/shared/account/account.model'
import { AccountService } from '@app/shared/account/account.service'
import { ScreenService } from '@app/shared/misc/screen.service'
import { ComponentPagination, hasMoreItems } from '@app/shared/rest/component-pagination.model'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { VideoSortField } from '@app/shared/video/sort-field.type'
import { Video } from '@app/shared/video/video.model'
import { VideoService } from '@app/shared/video/video.service'
import { ComponentPagination, hasMoreItems, ScreenService, User, UserService } from '@app/core'
import { Account, AccountService, Video, VideoChannel, VideoChannelService, VideoService } from '@app/shared/shared-main'
import { VideoSortField } from '@shared/models'
@Component({
selector: 'my-account-video-channels',

View File

@ -1,25 +1,18 @@
import { Subscription } from 'rxjs'
import { first, tap } from 'rxjs/operators'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { immutableAssign } from '@app/shared/misc/utils'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { AbstractVideoList } from '../../shared/video/abstract-video-list'
import { VideoService } from '../../shared/video/video.service'
import { Account } from '@app/shared/account/account.model'
import { AccountService } from '@app/shared/account/account.service'
import { first, tap } from 'rxjs/operators'
import { AuthService, ConfirmService, LocalStorageService, Notifier, ScreenService, ServerService, UserService } from '@app/core'
import { immutableAssign } from '@app/helpers'
import { Account, AccountService, VideoService } from '@app/shared/shared-main'
import { AbstractVideoList } from '@app/shared/shared-video-miniature'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { Subscription } from 'rxjs'
import { ScreenService } from '@app/shared/misc/screen.service'
import { Notifier, ServerService } from '@app/core'
import { UserService } from '@app/shared'
import { LocalStorageService } from '@app/shared/misc/storage.service'
@Component({
selector: 'my-account-videos',
templateUrl: '../../shared/video/abstract-video-list.html',
templateUrl: '../../shared/shared-video-miniature/abstract-video-list.html',
styleUrls: [
'../../shared/video/abstract-video-list.scss',
'../../shared/shared-video-miniature/abstract-video-list.scss',
'./account-videos.component.scss'
]
})

View File

@ -1,17 +1,11 @@
import { Subscription } from 'rxjs'
import { catchError, distinctUntilChanged, map, switchMap, tap } from 'rxjs/operators'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute } from '@angular/router'
import { AccountService } from '@app/shared/account/account.service'
import { Account } from '@app/shared/account/account.model'
import { RestExtractor, UserService } from '@app/shared'
import { catchError, distinctUntilChanged, map, switchMap, tap } from 'rxjs/operators'
import { Subscription } from 'rxjs'
import { AuthService, Notifier, RedirectService } from '@app/core'
import { User, UserRight } from '../../../../shared'
import { AuthService, Notifier, RedirectService, RestExtractor, ScreenService, UserService } from '@app/core'
import { Account, AccountService, ListOverflowItem, VideoChannel, VideoChannelService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { ListOverflowItem } from '@app/shared/misc/list-overflow.component'
import { ScreenService } from '@app/shared/misc/screen.service'
import { User, UserRight } from '@shared/models'
@Component({
templateUrl: './accounts.component.html',

View File

@ -1,15 +1,26 @@
import { NgModule } from '@angular/core'
import { SharedModule } from '../shared'
import { AccountsRoutingModule } from './accounts-routing.module'
import { AccountsComponent } from './accounts.component'
import { AccountVideosComponent } from './account-videos/account-videos.component'
import { SharedFormModule } from '@app/shared/shared-forms'
import { SharedGlobalIconModule } from '@app/shared/shared-icons'
import { SharedMainModule } from '@app/shared/shared-main'
import { SharedModerationModule } from '@app/shared/shared-moderation'
import { SharedUserSubscriptionModule } from '@app/shared/shared-user-subscription'
import { SharedVideoMiniatureModule } from '@app/shared/shared-video-miniature'
import { AccountAboutComponent } from './account-about/account-about.component'
import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
import { AccountVideosComponent } from './account-videos/account-videos.component'
import { AccountsRoutingModule } from './accounts-routing.module'
import { AccountsComponent } from './accounts.component'
@NgModule({
imports: [
AccountsRoutingModule,
SharedModule
SharedMainModule,
SharedFormModule,
SharedUserSubscriptionModule,
SharedModerationModule,
SharedVideoMiniatureModule,
SharedGlobalIconModule
],
declarations: [

View File

@ -1,15 +1,13 @@
import { NgModule } from '@angular/core'
import { RouterModule, Routes } from '@angular/router'
import { ConfigRoutes } from '@app/+admin/config'
import { ModerationRoutes } from '@app/+admin/moderation/moderation.routes'
import { PluginsRoutes } from '@app/+admin/plugins/plugins.routes'
import { SystemRoutes } from '@app/+admin/system'
import { MetaGuard } from '@ngx-meta/core'
import { AdminComponent } from './admin.component'
import { FollowsRoutes } from './follows'
import { UsersRoutes } from './users'
import { ModerationRoutes } from '@app/+admin/moderation/moderation.routes'
import { SystemRoutes } from '@app/+admin/system'
import { PluginsRoutes } from '@app/+admin/plugins/plugins.routes'
const adminRoutes: Routes = [
{

View File

@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core'
import { UserRight } from '../../../../shared'
import { AuthService } from '../core/auth/auth.service'
import { ListOverflowItem } from '@app/shared/misc/list-overflow.component'
import { AuthService } from '@app/core'
import { ListOverflowItem } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { UserRight } from '@shared/models'
@Component({
templateUrl: './admin.component.html'

View File

@ -1,39 +1,41 @@
import { NgModule } from '@angular/core'
import { ConfigComponent, EditCustomConfigComponent } from '@app/+admin/config'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { ChartModule } from 'primeng/chart'
import { SelectButtonModule } from 'primeng/selectbutton'
import { TableModule } from 'primeng/table'
import { SharedModule } from '../shared'
import { NgModule } from '@angular/core'
import { SharedFormModule } from '@app/shared/shared-forms'
import { SharedGlobalIconModule } from '@app/shared/shared-icons'
import { SharedMainModule } from '@app/shared/shared-main'
import { SharedModerationModule } from '@app/shared/shared-moderation'
import { AdminRoutingModule } from './admin-routing.module'
import { AdminComponent } from './admin.component'
import { ConfigComponent, EditCustomConfigComponent } from './config'
import { ConfigService } from './config/shared/config.service'
import { FollowersListComponent, FollowsComponent, VideoRedundanciesListComponent } from './follows'
import { FollowingListComponent } from './follows/following-list/following-list.component'
import { UserCreateComponent, UserListComponent, UserPasswordComponent, UsersComponent, UserUpdateComponent } from './users'
import {
ModerationCommentModalComponent,
VideoAbuseListComponent,
VideoBlockListComponent
} from './moderation'
import { ModerationComponent } from '@app/+admin/moderation/moderation.component'
import { RedundancyCheckboxComponent } from '@app/+admin/follows/shared/redundancy-checkbox.component'
import { InstanceAccountBlocklistComponent, InstanceServerBlocklistComponent } from '@app/+admin/moderation/instance-blocklist'
import { JobsComponent } from '@app/+admin/system/jobs/jobs.component'
import { JobService, LogsComponent, LogsService, SystemComponent } from '@app/+admin/system'
import { DebugComponent, DebugService } from '@app/+admin/system/debug'
import { PluginsComponent } from '@app/+admin/plugins/plugins.component'
import { PluginListInstalledComponent } from '@app/+admin/plugins/plugin-list-installed/plugin-list-installed.component'
import { PluginSearchComponent } from '@app/+admin/plugins/plugin-search/plugin-search.component'
import { PluginShowInstalledComponent } from '@app/+admin/plugins/plugin-show-installed/plugin-show-installed.component'
import { SelectButtonModule } from 'primeng/selectbutton'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { VideoRedundancyInformationComponent } from '@app/+admin/follows/video-redundancies-list/video-redundancy-information.component'
import { ChartModule } from 'primeng/chart'
import { RedundancyCheckboxComponent } from './follows/shared/redundancy-checkbox.component'
import { VideoRedundancyInformationComponent } from './follows/video-redundancies-list/video-redundancy-information.component'
import { ModerationCommentModalComponent, VideoAbuseListComponent, VideoBlockListComponent } from './moderation'
import { InstanceAccountBlocklistComponent, InstanceServerBlocklistComponent } from './moderation/instance-blocklist'
import { ModerationComponent } from './moderation/moderation.component'
import { VideoAbuseDetailsComponent } from './moderation/video-abuse-list/video-abuse-details.component'
import { PluginListInstalledComponent } from './plugins/plugin-list-installed/plugin-list-installed.component'
import { PluginSearchComponent } from './plugins/plugin-search/plugin-search.component'
import { PluginShowInstalledComponent } from './plugins/plugin-show-installed/plugin-show-installed.component'
import { PluginsComponent } from './plugins/plugins.component'
import { PluginApiService } from './plugins/shared/plugin-api.service'
import { JobService, LogsComponent, LogsService, SystemComponent } from './system'
import { DebugComponent, DebugService } from './system/debug'
import { JobsComponent } from './system/jobs/jobs.component'
import { UserCreateComponent, UserListComponent, UserPasswordComponent, UsersComponent, UserUpdateComponent } from './users'
@NgModule({
imports: [
AdminRoutingModule,
SharedModule,
SharedMainModule,
SharedFormModule,
SharedModerationModule,
SharedGlobalIconModule,
TableModule,
SelectButtonModule,

View File

@ -1,7 +1,7 @@
import { Routes } from '@angular/router'
import { EditCustomConfigComponent } from '@app/+admin/config/edit-custom-config'
import { UserRightGuard } from '@app/core'
import { UserRight } from '../../../../../shared/models/users'
import { UserRight } from '@shared/models'
import { ConfigComponent } from './config.component'
export const ConfigRoutes: Routes = [

View File

@ -1,16 +1,14 @@
import { AfterViewChecked, Component, OnInit, ViewChild } from '@angular/core'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { ServerService } from '@app/core/server/server.service'
import { CustomConfigValidatorsService, FormReactive, UserValidatorsService } from '@app/shared'
import { Notifier } from '@app/core'
import { CustomConfig } from '../../../../../../shared/models/server/custom-config.model'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { SelectItem } from 'primeng/api'
import { forkJoin } from 'rxjs'
import { ServerConfig } from '@shared/models'
import { ViewportScroller } from '@angular/common'
import { AfterViewChecked, Component, OnInit, ViewChild } from '@angular/core'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { Notifier } from '@app/core'
import { ServerService } from '@app/core/server/server.service'
import { CustomConfigValidatorsService, FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { NgbNav } from '@ng-bootstrap/ng-bootstrap'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { CustomConfig, ServerConfig } from '@shared/models'
@Component({
selector: 'my-edit-custom-config',

View File

@ -1,10 +1,10 @@
import { catchError } from 'rxjs/operators'
import { HttpClient } from '@angular/common/http'
import { Injectable } from '@angular/core'
import { CustomConfig } from '../../../../../../shared/models/server/custom-config.model'
import { environment } from '../../../../environments/environment'
import { RestExtractor } from '../../../shared'
import { RestExtractor } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { CustomConfig } from '@shared/models'
import { environment } from '../../../../environments/environment'
@Injectable()
export class ConfigService {

View File

@ -1,10 +1,9 @@
import { Component, OnInit } from '@angular/core'
import { ConfirmService, Notifier } from '@app/core'
import { SortMeta } from 'primeng/api'
import { ActorFollow } from '../../../../../../shared/models/actors/follow.model'
import { RestPagination, RestTable } from '../../../shared'
import { FollowService } from '@app/shared/instance/follow.service'
import { Component, OnInit } from '@angular/core'
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
import { InstanceFollowService } from '@app/shared/shared-instance'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ActorFollow } from '@shared/models'
@Component({
selector: 'my-followers-list',
@ -21,7 +20,7 @@ export class FollowersListComponent extends RestTable implements OnInit {
private confirmService: ConfirmService,
private notifier: Notifier,
private i18n: I18n,
private followService: FollowService
private followService: InstanceFollowService
) {
super()
}

View File

@ -1,12 +1,10 @@
import { Component, OnInit, ViewChild } from '@angular/core'
import { Notifier } from '@app/core'
import { SortMeta } from 'primeng/api'
import { ActorFollow } from '../../../../../../shared/models/actors/follow.model'
import { ConfirmService } from '../../../core/confirm/confirm.service'
import { RestPagination, RestTable } from '../../../shared'
import { FollowService } from '@app/shared/instance/follow.service'
import { Component, OnInit, ViewChild } from '@angular/core'
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
import { InstanceFollowService } from '@app/shared/shared-instance'
import { BatchDomainsModalComponent } from '@app/shared/shared-moderation'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { BatchDomainsModalComponent } from '@app/+admin/config/shared/batch-domains-modal.component'
import { ActorFollow } from '@shared/models'
@Component({
selector: 'my-followers-list',
@ -24,7 +22,7 @@ export class FollowingListComponent extends RestTable implements OnInit {
constructor (
private notifier: Notifier,
private confirmService: ConfirmService,
private followService: FollowService,
private followService: InstanceFollowService,
private i18n: I18n
) {
super()

View File

@ -1,11 +1,10 @@
import { Routes } from '@angular/router'
import { UserRightGuard } from '../../core'
import { FollowsComponent } from './follows.component'
import { FollowersListComponent } from './followers-list'
import { UserRight } from '../../../../../shared'
import { FollowingListComponent } from './following-list/following-list.component'
import { VideoRedundanciesListComponent } from '@app/+admin/follows/video-redundancies-list'
import { UserRightGuard } from '@app/core'
import { UserRight } from '@shared/models'
import { FollowersListComponent } from './followers-list'
import { FollowingListComponent } from './following-list/following-list.component'
import { FollowsComponent } from './follows.component'
export const FollowsRoutes: Routes = [
{

View File

@ -1,7 +1,7 @@
import { Component, Input } from '@angular/core'
import { Notifier } from '@app/core'
import { RedundancyService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { RedundancyService } from '@app/shared/video/redundancy.service'
@Component({
selector: 'my-redundancy-checkbox',

View File

@ -1 +1,2 @@
export * from './video-redundancies-list.component'
export * from './video-redundancy-information.component'

View File

@ -1,14 +1,12 @@
import { Component, OnInit } from '@angular/core'
import { Notifier, ServerService } from '@app/core'
import { BytesPipe } from 'ngx-pipes'
import { SortMeta } from 'primeng/api'
import { ConfirmService } from '../../../core/confirm/confirm.service'
import { RestPagination, RestTable } from '../../../shared'
import { Component, OnInit } from '@angular/core'
import { ConfirmService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
import { peertubeLocalStorage } from '@app/helpers/peertube-web-storage'
import { RedundancyService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoRedundanciesTarget, VideoRedundancy } from '@shared/models'
import { peertubeLocalStorage } from '@app/shared/misc/peertube-web-storage'
import { VideosRedundancyStats } from '@shared/models/server'
import { BytesPipe } from 'ngx-pipes'
import { RedundancyService } from '@app/shared/video/redundancy.service'
@Component({
selector: 'my-video-redundancies-list',

View File

@ -1,3 +1,4 @@
export * from './instance-blocklist'
export * from './video-abuse-list'
export * from './video-block-list'
export * from './moderation.component'

View File

@ -1,10 +1,10 @@
import { Component } from '@angular/core'
import { GenericAccountBlocklistComponent, BlocklistComponentType } from '@app/shared/blocklist'
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
@Component({
selector: 'my-instance-account-blocklist',
styleUrls: [ '../moderation.component.scss', '../../../shared/blocklist/account-blocklist.component.scss' ],
templateUrl: '../../../shared/blocklist/account-blocklist.component.html'
styleUrls: [ '../moderation.component.scss', '../../../shared/shared-moderation/account-blocklist.component.scss' ],
templateUrl: '../../../shared/shared-moderation/account-blocklist.component.html'
})
export class InstanceAccountBlocklistComponent extends GenericAccountBlocklistComponent {
mode = BlocklistComponentType.Instance

View File

@ -1,10 +1,10 @@
import { Component } from '@angular/core'
import { GenericServerBlocklistComponent, BlocklistComponentType } from '@app/shared/blocklist'
import { GenericServerBlocklistComponent, BlocklistComponentType } from '@app/shared/shared-moderation'
@Component({
selector: 'my-instance-server-blocklist',
styleUrls: [ '../../../shared/blocklist/server-blocklist.component.scss' ],
templateUrl: '../../../shared/blocklist/server-blocklist.component.html'
styleUrls: [ '../../../shared/shared-moderation/server-blocklist.component.scss' ],
templateUrl: '../../../shared/shared-moderation/server-blocklist.component.html'
})
export class InstanceServerBlocklistComponent extends GenericServerBlocklistComponent {
mode = BlocklistComponentType.Instance

View File

@ -1,6 +1,6 @@
import { Component, OnInit } from '@angular/core'
import { UserRight } from '../../../../../shared'
import { AuthService, ServerService } from '@app/core'
import { UserRight } from '@shared/models'
@Component({
templateUrl: './moderation.component.html',

View File

@ -1,10 +1,10 @@
import { Routes } from '@angular/router'
import { UserRight } from '../../../../../shared'
import { UserRightGuard } from '@app/core'
import { InstanceAccountBlocklistComponent, InstanceServerBlocklistComponent } from '@app/+admin/moderation/instance-blocklist'
import { ModerationComponent } from '@app/+admin/moderation/moderation.component'
import { VideoAbuseListComponent } from '@app/+admin/moderation/video-abuse-list'
import { VideoBlockListComponent } from '@app/+admin/moderation/video-block-list'
import { ModerationComponent } from '@app/+admin/moderation/moderation.component'
import { InstanceAccountBlocklistComponent, InstanceServerBlocklistComponent } from '@app/+admin/moderation/instance-blocklist'
import { UserRightGuard } from '@app/core'
import { UserRight } from '@shared/models'
export const ModerationRoutes: Routes = [
{

View File

@ -1,11 +1,11 @@
import { Component, EventEmitter, OnInit, Output, ViewChild } from '@angular/core'
import { Notifier } from '@app/core'
import { FormReactive, VideoAbuseService, VideoAbuseValidatorsService } from '../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormReactive, FormValidatorService, VideoAbuseValidatorsService } from '@app/shared/shared-forms'
import { VideoAbuseService } from '@app/shared/shared-moderation'
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
import { FormValidatorService } from '../../../shared/forms/form-validators/form-validator.service'
import { VideoAbuse } from '../../../../../../shared/models/videos'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoAbuse } from '@shared/models'
@Component({
selector: 'my-moderation-comment-modal',

View File

@ -1,9 +1,8 @@
import { Component, Input } from '@angular/core'
import { Actor } from '@app/shared/actor/actor.model'
import { Actor } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoAbusePredefinedReasonsString } from '../../../../../../shared/models/videos/abuse/video-abuse-reason.model'
import { ProcessedVideoAbuse } from './video-abuse-list.component'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { durationToString } from '@app/shared/misc/utils'
@Component({
selector: 'my-video-abuse-details',

View File

@ -1,23 +1,16 @@
import { Component, OnInit, ViewChild, AfterViewInit } from '@angular/core'
import { Account } from '@app/shared/account/account.model'
import { Notifier } from '@app/core'
import { SortMeta } from 'primeng/api'
import { VideoAbuse, VideoAbuseState } from '../../../../../../shared'
import { RestPagination, RestTable, VideoAbuseService, VideoBlockService } from '../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { DropdownAction } from '../../../shared/buttons/action-dropdown.component'
import { ConfirmService } from '../../../core/index'
import { ModerationCommentModalComponent } from './moderation-comment-modal.component'
import { Video } from '../../../shared/video/video.model'
import { MarkdownService } from '@app/shared/renderer'
import { Actor } from '@app/shared/actor/actor.model'
import { buildVideoEmbed, buildVideoLink } from 'src/assets/player/utils'
import { DomSanitizer } from '@angular/platform-browser'
import { BlocklistService } from '@app/shared/blocklist'
import { VideoService } from '@app/shared/video/video.service'
import { ActivatedRoute, Params, Router } from '@angular/router'
import { filter } from 'rxjs/operators'
import { buildVideoEmbed, buildVideoLink } from 'src/assets/player/utils'
import { environment } from 'src/environments/environment'
import { AfterViewInit, Component, OnInit, ViewChild } from '@angular/core'
import { DomSanitizer } from '@angular/platform-browser'
import { ActivatedRoute, Params, Router } from '@angular/router'
import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable } from '@app/core'
import { Account, Actor, DropdownAction, Video, VideoService } from '@app/shared/shared-main'
import { BlocklistService, VideoAbuseService, VideoBlockService } from '@app/shared/shared-moderation'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoAbuse, VideoAbuseState } from '@shared/models'
import { ModerationCommentModalComponent } from './moderation-comment-modal.component'
export type ProcessedVideoAbuse = VideoAbuse & {
moderationCommentHtml?: string,

View File

@ -1,16 +1,12 @@
import { Component, OnInit, AfterViewInit } from '@angular/core'
import { SortMeta } from 'primeng/api'
import { Notifier, ServerService } from '@app/core'
import { ConfirmService } from '../../../core'
import { RestPagination, RestTable, VideoBlockService } from '../../../shared'
import { VideoBlacklist, VideoBlacklistType } from '../../../../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { DropdownAction } from '../../../shared/buttons/action-dropdown.component'
import { Video } from '../../../shared/video/video.model'
import { MarkdownService } from '@app/shared/renderer'
import { Params, ActivatedRoute, Router } from '@angular/router'
import { filter, switchMap } from 'rxjs/operators'
import { VideoService } from '@app/shared/video/video.service'
import { AfterViewInit, Component, OnInit } from '@angular/core'
import { ActivatedRoute, Params, Router } from '@angular/router'
import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
import { DropdownAction, Video, VideoService } from '@app/shared/shared-main'
import { VideoBlockService } from '@app/shared/shared-moderation'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoBlacklist, VideoBlacklistType } from '@shared/models'
@Component({
selector: 'my-video-block-list',

View File

@ -1,14 +1,13 @@
import { Component, OnInit } from '@angular/core'
import { PluginType } from '@shared/models/plugins/plugin.type'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { ComponentPagination, hasMoreItems } from '@app/shared/rest/component-pagination.model'
import { ConfirmService, Notifier } from '@app/core'
import { PeerTubePlugin } from '@shared/models/plugins/peertube-plugin.model'
import { ActivatedRoute, Router } from '@angular/router'
import { compareSemVer } from '@shared/core-utils/miscs/miscs'
import { PluginService } from '@app/core/plugins/plugin.service'
import { Subject } from 'rxjs'
import { Component, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { ComponentPagination, ConfirmService, hasMoreItems, Notifier } from '@app/core'
import { PluginService } from '@app/core/plugins/plugin.service'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { compareSemVer } from '@shared/core-utils/miscs/miscs'
import { PeerTubePlugin } from '@shared/models/plugins/peertube-plugin.model'
import { PluginType } from '@shared/models/plugins/plugin.type'
@Component({
selector: 'my-plugin-list-installed',

View File

@ -1,14 +1,12 @@
import { Component, OnInit } from '@angular/core'
import { Notifier, ServerService } from '@app/core'
import { ConfirmService } from '../../../core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PluginType } from '@shared/models/plugins/plugin.type'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { ComponentPagination, hasMoreItems } from '@app/shared/rest/component-pagination.model'
import { ActivatedRoute, Router } from '@angular/router'
import { PeerTubePluginIndex } from '@shared/models/plugins/peertube-plugin-index.model'
import { Subject } from 'rxjs'
import { debounceTime, distinctUntilChanged } from 'rxjs/operators'
import { Component, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { ComponentPagination, ConfirmService, hasMoreItems, Notifier, ServerService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PeerTubePluginIndex } from '@shared/models/plugins/peertube-plugin-index.model'
import { PluginType } from '@shared/models/plugins/plugin.type'
@Component({
selector: 'my-plugin-search',

View File

@ -1,13 +1,12 @@
import { Component, OnDestroy, OnInit } from '@angular/core'
import { PeerTubePlugin } from '@shared/models/plugins/peertube-plugin.model'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
import { Notifier } from '@app/core'
import { ActivatedRoute } from '@angular/router'
import { Subscription } from 'rxjs'
import { map, switchMap } from 'rxjs/operators'
import { BuildFormArgument, FormReactive, FormValidatorService } from '@app/shared'
import { RegisterServerSettingOptions } from '@shared/models/plugins/register-server-setting.model'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute } from '@angular/router'
import { Notifier } from '@app/core'
import { BuildFormArgument, FormReactive, FormValidatorService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PeerTubePlugin, RegisterServerSettingOptions } from '@shared/models'
import { PluginApiService } from '../shared/plugin-api.service'
@Component({
selector: 'my-plugin-show-installed',

View File

@ -1,19 +1,21 @@
import { Observable } from 'rxjs'
import { catchError, map, switchMap } from 'rxjs/operators'
import { HttpClient, HttpParams } from '@angular/common/http'
import { Injectable } from '@angular/core'
import { environment } from '../../../../environments/environment'
import { RestExtractor, RestService } from '../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { PluginType } from '@shared/models/plugins/plugin.type'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { peertubeTranslate, ResultList } from '@shared/models'
import { PeerTubePlugin } from '@shared/models/plugins/peertube-plugin.model'
import { ManagePlugin } from '@shared/models/plugins/manage-plugin.model'
import { InstallOrUpdatePlugin } from '@shared/models/plugins/install-plugin.model'
import { PeerTubePluginIndex } from '@shared/models/plugins/peertube-plugin-index.model'
import { RegisteredServerSettings, RegisterServerSettingOptions } from '@shared/models/plugins/register-server-setting.model'
import { ComponentPagination, RestExtractor, RestService } from '@app/core'
import { PluginService } from '@app/core/plugins/plugin.service'
import { Observable } from 'rxjs'
import { I18n } from '@ngx-translate/i18n-polyfill'
import {
InstallOrUpdatePlugin,
ManagePlugin,
PeerTubePlugin,
PeerTubePluginIndex,
peertubeTranslate,
PluginType,
RegisteredServerSettings,
ResultList
} from '@shared/models'
import { environment } from '../../../../environments/environment'
@Injectable()
export class PluginApiService {

View File

@ -1,7 +1,7 @@
import { Component, OnInit } from '@angular/core'
import { Notifier } from '@app/core'
import { Debug } from '@shared/models/server'
import { DebugService } from '@app/+admin/system/debug/debug.service'
import { Debug } from '@shared/models'
import { DebugService } from './debug.service'
@Component({
templateUrl: './debug.component.html',

View File

@ -1,10 +1,10 @@
import { Observable } from 'rxjs'
import { catchError } from 'rxjs/operators'
import { HttpClient } from '@angular/common/http'
import { Injectable } from '@angular/core'
import { Observable } from 'rxjs'
import { RestExtractor } from '@app/core'
import { Debug } from '@shared/models'
import { environment } from '../../../../environments/environment'
import { RestExtractor, RestService } from '../../../shared'
import { Debug } from '@shared/models/server'
@Injectable()
export class DebugService {
@ -12,7 +12,6 @@ export class DebugService {
constructor (
private authHttp: HttpClient,
private restService: RestService,
private restExtractor: RestExtractor
) {}

View File

@ -1,3 +1,4 @@
export * from './debug'
export * from './jobs'
export * from './logs'
export * from './system.component'

View File

@ -1,12 +1,11 @@
import { SortMeta } from 'primeng/api'
import { Observable } from 'rxjs'
import { catchError, map } from 'rxjs/operators'
import { HttpClient, HttpParams } from '@angular/common/http'
import { Injectable } from '@angular/core'
import { SortMeta } from 'primeng/api'
import { Observable } from 'rxjs'
import { ResultList } from '../../../../../../shared'
import { Job } from '../../../../../../shared/models/server/job.model'
import { RestExtractor, RestPagination, RestService } from '@app/core'
import { Job, ResultList } from '@shared/models'
import { environment } from '../../../../environments/environment'
import { RestExtractor, RestPagination, RestService } from '../../../shared'
import { JobStateClient } from '../../../../types/job-state-client.type'
import { JobTypeClient } from '../../../../types/job-type-client.type'

View File

@ -1,14 +1,12 @@
import { Component, OnInit } from '@angular/core'
import { peertubeLocalStorage } from '@app/shared/misc/peertube-web-storage'
import { Notifier } from '@app/core'
import { SortMeta } from 'primeng/api'
import { Job, JobType } from '../../../../../../shared/index'
import { JobState } from '../../../../../../shared/models'
import { RestPagination, RestTable } from '../../../shared'
import { JobService } from './job.service'
import { Component, OnInit } from '@angular/core'
import { Notifier, RestPagination, RestTable } from '@app/core'
import { peertubeLocalStorage } from '@app/helpers/peertube-web-storage'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { Job, JobState, JobType } from '@shared/models'
import { JobStateClient } from '../../../../types/job-state-client.type'
import { JobTypeClient } from '../../../../types/job-type-client.type'
import { JobService } from './job.service'
@Component({
selector: 'my-jobs',

View File

@ -1,4 +1,4 @@
import { LogLevel } from '@shared/models/server/log-level.type'
import { LogLevel } from '@shared/models'
import omit from 'lodash-es/omit'
export class LogRow {

View File

@ -1,9 +1,9 @@
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core'
import { LogsService } from '@app/+admin/system/logs/logs.service'
import { Notifier } from '@app/core'
import { LogRow } from '@app/+admin/system/logs/log-row.model'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { LogLevel } from '@shared/models/server/log-level.type'
import { LogLevel } from '@shared/models'
import { LogRow } from './log-row.model'
import { LogsService } from './logs.service'
@Component({
templateUrl: './logs.component.html',

View File

@ -1,11 +1,11 @@
import { Observable } from 'rxjs'
import { catchError, map } from 'rxjs/operators'
import { HttpClient, HttpParams } from '@angular/common/http'
import { Injectable } from '@angular/core'
import { Observable } from 'rxjs'
import { RestExtractor } from '@app/core'
import { LogLevel } from '@shared/models'
import { environment } from '../../../../environments/environment'
import { RestExtractor, RestService } from '../../../shared'
import { LogRow } from '@app/+admin/system/logs/log-row.model'
import { LogLevel } from '@shared/models/server/log-level.type'
import { LogRow } from './log-row.model'
@Injectable()
export class LogsService {
@ -14,7 +14,6 @@ export class LogsService {
constructor (
private authHttp: HttpClient,
private restService: RestService,
private restExtractor: RestExtractor
) {}

View File

@ -1,10 +1,10 @@
import { Routes } from '@angular/router'
import { UserRightGuard } from '../../core'
import { UserRight } from '../../../../../shared'
import { JobsComponent } from '@app/+admin/system/jobs/jobs.component'
import { LogsComponent } from '@app/+admin/system/logs'
import { SystemComponent } from '@app/+admin/system/system.component'
import { DebugComponent } from '@app/+admin/system/debug'
import { UserRightGuard } from '@app/core'
import { UserRight } from '@shared/models'
import { DebugComponent } from './debug'
import { JobsComponent } from './jobs/jobs.component'
import { LogsComponent } from './logs'
import { SystemComponent } from './system.component'
export const SystemRoutes: Routes = [
{

View File

@ -1,14 +1,11 @@
import { Component, OnInit } from '@angular/core'
import { Router, ActivatedRoute } from '@angular/router'
import { AuthService, Notifier, ServerService } from '@app/core'
import { UserCreate, UserRole } from '../../../../../../shared'
import { UserEdit } from './user-edit'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { ActivatedRoute, Router } from '@angular/router'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { UserService } from '@app/shared'
import { ScreenService } from '@app/shared/misc/screen.service'
import { AuthService, Notifier, ScreenService, ServerService, UserService } from '@app/core'
import { FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { UserCreate, UserRole } from '@shared/models'
import { UserEdit } from './user-edit'
@Component({
selector: 'my-user-create',

View File

@ -1,11 +1,8 @@
import { AuthService, ServerService } from '../../../core'
import { FormReactive } from '../../../shared'
import { ServerConfig, USER_ROLE_LABELS, UserRole, VideoResolution } from '../../../../../../shared'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { UserAdminFlag } from '@shared/models/users/user-flag.model'
import { OnInit } from '@angular/core'
import { User } from '@app/shared/users/user.model'
import { ScreenService } from '@app/shared/misc/screen.service'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { AuthService, ScreenService, ServerService, User } from '@app/core'
import { FormReactive } from '@app/shared/shared-forms'
import { ServerConfig, USER_ROLE_LABELS, UserAdminFlag, UserRole, VideoResolution } from '@shared/models'
export abstract class UserEdit extends FormReactive implements OnInit {
videoQuotaOptions: { value: string, label: string, disabled?: boolean }[] = []

View File

@ -1,12 +1,8 @@
import { Component, Input, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { UserService } from '@app/shared/users/user.service'
import { Notifier } from '../../../core'
import { User, UserUpdate } from '../../../../../../shared'
import { Notifier, UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { FormReactive } from '../../../shared'
import { UserUpdate } from '@shared/models'
@Component({
selector: 'my-user-password',

View File

@ -1,18 +1,12 @@
import { Subscription } from 'rxjs'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { Subscription } from 'rxjs'
import { AuthService, Notifier } from '@app/core'
import { ServerService } from '../../../core'
import { UserEdit } from './user-edit'
import { User as UserType, UserUpdate, UserRole } from '../../../../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { ConfigService } from '@app/+admin/config/shared/config.service'
import { UserService } from '@app/shared'
import { UserAdminFlag } from '@shared/models/users/user-flag.model'
import { User } from '@app/shared/users/user.model'
import { ScreenService } from '@app/shared/misc/screen.service'
import { AuthService, Notifier, ScreenService, ServerService, User, UserService } from '@app/core'
import { FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { User as UserType, UserAdminFlag, UserRole, UserUpdate } from '@shared/models'
import { UserEdit } from './user-edit'
@Component({
selector: 'my-user-update',

View File

@ -1,13 +1,10 @@
import { Component, OnInit, ViewChild } from '@angular/core'
import { AuthService, Notifier } from '@app/core'
import { SortMeta } from 'primeng/api'
import { ConfirmService, ServerService } from '../../../core'
import { RestPagination, RestTable, UserService } from '../../../shared'
import { Component, OnInit, ViewChild } from '@angular/core'
import { AuthService, ConfirmService, Notifier, RestPagination, RestTable, ServerService, UserService } from '@app/core'
import { Actor, DropdownAction } from '@app/shared/shared-main'
import { UserBanModalComponent } from '@app/shared/shared-moderation'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ServerConfig, User } from '../../../../../../shared'
import { UserBanModalComponent } from '@app/shared/moderation'
import { DropdownAction } from '@app/shared/buttons/action-dropdown.component'
import { Actor } from '@app/shared/actor/actor.model'
import { ServerConfig, User } from '@shared/models'
@Component({
selector: 'my-user-list',

View File

@ -1,11 +1,9 @@
import { Routes } from '@angular/router'
import { UserRightGuard } from '../../core'
import { UserRight } from '../../../../../shared'
import { UsersComponent } from './users.component'
import { ServerConfigResolver, UserRightGuard } from '@app/core'
import { UserRight } from '@shared/models'
import { UserCreateComponent, UserUpdateComponent } from './user-edit'
import { UserListComponent } from './user-list'
import { ServerConfigResolver } from '@app/core/routing/server-config-resolver.service'
import { UsersComponent } from './users.component'
export const UsersRoutes: Routes = [
{

View File

@ -1,12 +1,11 @@
import { Component, OnInit } from '@angular/core'
import { Router } from '@angular/router'
import { AuthService, Notifier } from '@app/core'
import { MyAccountVideoChannelEdit } from './my-account-video-channel-edit'
import { VideoChannelCreate } from '../../../../../shared/models/videos'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { FormValidatorService, VideoChannelValidatorsService } from '@app/shared/shared-forms'
import { VideoChannelService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { VideoChannelValidatorsService } from '@app/shared/forms/form-validators/video-channel-validators.service'
import { VideoChannelCreate } from '@shared/models'
import { MyAccountVideoChannelEdit } from './my-account-video-channel-edit'
@Component({
selector: 'my-account-video-channel-create',

View File

@ -1,5 +1,5 @@
import { FormReactive } from '@app/shared'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { FormReactive } from '@app/shared/shared-forms'
import { VideoChannel } from '@app/shared/shared-main'
export abstract class MyAccountVideoChannelEdit extends FormReactive {
// We need it even in the create component because it's used in the edit template

View File

@ -1,15 +1,12 @@
import { Subscription } from 'rxjs'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { AuthService, Notifier, ServerService } from '@app/core'
import { MyAccountVideoChannelEdit } from './my-account-video-channel-edit'
import { VideoChannelUpdate } from '../../../../../shared/models/videos'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { Subscription } from 'rxjs'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { FormValidatorService, VideoChannelValidatorsService } from '@app/shared/shared-forms'
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { VideoChannelValidatorsService } from '@app/shared/forms/form-validators/video-channel-validators.service'
import { ServerConfig } from '@shared/models'
import { ServerConfig, VideoChannelUpdate } from '@shared/models'
import { MyAccountVideoChannelEdit } from './my-account-video-channel-edit'
@Component({
selector: 'my-account-video-channel-update',

View File

@ -1,15 +1,10 @@
import { Component, OnInit } from '@angular/core'
import { Notifier } from '@app/core'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { ScreenService } from '@app/shared/misc/screen.service'
import { User } from '@app/shared'
import { flatMap } from 'rxjs/operators'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { min, minBy, max, maxBy } from 'lodash-es'
import { ChartData } from 'chart.js'
import { max, maxBy, min, minBy } from 'lodash-es'
import { flatMap } from 'rxjs/operators'
import { Component, OnInit } from '@angular/core'
import { AuthService, ConfirmService, Notifier, ScreenService, User } from '@app/core'
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
@Component({
selector: 'my-account-video-channels',

View File

@ -1,16 +1,22 @@
import { NgModule } from '@angular/core'
import { ChartModule } from 'primeng/chart'
import { MyAccountVideoChannelsRoutingModule } from './my-account-video-channels-routing.module'
import { MyAccountVideoChannelsComponent } from './my-account-video-channels.component'
import { NgModule } from '@angular/core'
import { SharedFormModule } from '@app/shared/shared-forms'
import { SharedGlobalIconModule } from '@app/shared/shared-icons'
import { SharedMainModule } from '@app/shared/shared-main'
import { MyAccountVideoChannelCreateComponent } from './my-account-video-channel-create.component'
import { MyAccountVideoChannelUpdateComponent } from './my-account-video-channel-update.component'
import { SharedModule } from '@app/shared'
import { MyAccountVideoChannelsRoutingModule } from './my-account-video-channels-routing.module'
import { MyAccountVideoChannelsComponent } from './my-account-video-channels.component'
@NgModule({
imports: [
MyAccountVideoChannelsRoutingModule,
SharedModule,
ChartModule
ChartModule,
SharedMainModule,
SharedFormModule,
SharedGlobalIconModule
],
declarations: [

View File

@ -1,10 +1,10 @@
import { Component } from '@angular/core'
import { GenericAccountBlocklistComponent, BlocklistComponentType } from '@app/shared/blocklist'
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
@Component({
selector: 'my-account-blocklist',
styleUrls: [ '../../shared/blocklist/account-blocklist.component.scss' ],
templateUrl: '../../shared/blocklist/account-blocklist.component.html'
styleUrls: [ '../../shared/shared-moderation/account-blocklist.component.scss' ],
templateUrl: '../../shared/shared-moderation/account-blocklist.component.html'
})
export class MyAccountBlocklistComponent extends GenericAccountBlocklistComponent {
mode = BlocklistComponentType.Account

View File

@ -1,10 +1,10 @@
import { Component } from '@angular/core'
import { GenericServerBlocklistComponent, BlocklistComponentType } from '@app/shared/blocklist'
import { BlocklistComponentType, GenericServerBlocklistComponent } from '@app/shared/shared-moderation'
@Component({
selector: 'my-account-server-blocklist',
styleUrls: [ '../../+admin/moderation/moderation.component.scss', '../../shared/blocklist/server-blocklist.component.scss' ],
templateUrl: '../../shared/blocklist/server-blocklist.component.html'
styleUrls: [ '../../+admin/moderation/moderation.component.scss', '../../shared/shared-moderation/server-blocklist.component.scss' ],
templateUrl: '../../shared/shared-moderation/server-blocklist.component.html'
})
export class MyAccountServerBlocklistComponent extends GenericServerBlocklistComponent {
mode = BlocklistComponentType.Account

View File

@ -1,17 +1,19 @@
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { immutableAssign } from '@app/shared/misc/utils'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { AbstractVideoList } from '../../shared/video/abstract-video-list'
import { VideoService } from '../../shared/video/video.service'
import {
AuthService,
ComponentPagination,
ConfirmService,
LocalStorageService,
Notifier,
ScreenService,
ServerService,
UserService
} from '@app/core'
import { immutableAssign } from '@app/helpers'
import { UserHistoryService } from '@app/shared/shared-main'
import { AbstractVideoList } from '@app/shared/shared-video-miniature'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ScreenService } from '@app/shared/misc/screen.service'
import { UserHistoryService } from '@app/shared/users/user-history.service'
import { UserService } from '@app/shared'
import { Notifier, ServerService } from '@app/core'
import { LocalStorageService } from '@app/shared/misc/storage.service'
@Component({
selector: 'my-account-history',
@ -38,7 +40,6 @@ export class MyAccountHistoryComponent extends AbstractVideoList implements OnIn
protected screenService: ScreenService,
protected storageService: LocalStorageService,
private confirmService: ConfirmService,
private videoService: VideoService,
private userHistoryService: UserHistoryService
) {
super()

View File

@ -1,5 +1,5 @@
import { Component, ViewChild } from '@angular/core'
import { UserNotificationsComponent } from '@app/shared'
import { UserNotificationsComponent } from '@app/shared/shared-main'
@Component({
templateUrl: './my-account-notifications.component.html',

View File

@ -1,14 +1,10 @@
import { Component, ElementRef, EventEmitter, OnInit, Output, ViewChild } from '@angular/core'
import { AuthService, Notifier } from '@app/core'
import { FormReactive } from '@app/shared'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { VideoOwnershipService } from '@app/shared/video-ownership'
import { VideoChangeOwnership } from '../../../../../../shared/models/videos'
import { VideoAcceptOwnershipValidatorsService } from '@app/shared/forms/form-validators'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { VideoChannelService } from '@app/shared/video-channel/video-channel.service'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormReactive, FormValidatorService, VideoAcceptOwnershipValidatorsService } from '@app/shared/shared-forms'
import { VideoChannelService, VideoOwnershipService } from '@app/shared/shared-main'
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoChangeOwnership, VideoChannel } from '@shared/models'
@Component({
selector: 'my-account-accept-ownership',

View File

@ -1,10 +1,8 @@
import { Component, OnInit, ViewChild } from '@angular/core'
import { Notifier } from '@app/core'
import { RestPagination, RestTable } from '@app/shared'
import { SortMeta } from 'primeng/api'
import { VideoChangeOwnership } from '../../../../../shared'
import { VideoOwnershipService } from '@app/shared/video-ownership'
import { Account } from '@app/shared/account/account.model'
import { Component, OnInit, ViewChild } from '@angular/core'
import { Notifier, RestPagination, RestTable } from '@app/core'
import { Account, VideoOwnershipService } from '@app/shared/shared-main'
import { VideoChangeOwnership } from '@shared/models'
import { MyAccountAcceptOwnershipComponent } from './my-account-accept-ownership/my-account-accept-ownership.component'
@Component({

View File

@ -2,26 +2,20 @@ import { NgModule } from '@angular/core'
import { RouterModule, Routes } from '@angular/router'
import { MetaGuard } from '@ngx-meta/core'
import { LoginGuard } from '../core'
import { MyAccountComponent } from './my-account.component'
import { MyAccountBlocklistComponent } from './my-account-blocklist/my-account-blocklist.component'
import { MyAccountServerBlocklistComponent } from './my-account-blocklist/my-account-server-blocklist.component'
import { MyAccountHistoryComponent } from './my-account-history/my-account-history.component'
import { MyAccountNotificationsComponent } from './my-account-notifications/my-account-notifications.component'
import { MyAccountOwnershipComponent } from './my-account-ownership/my-account-ownership.component'
import { MyAccountSettingsComponent } from './my-account-settings/my-account-settings.component'
import { MyAccountSubscriptionsComponent } from './my-account-subscriptions/my-account-subscriptions.component'
import { MyAccountVideoImportsComponent } from './my-account-video-imports/my-account-video-imports.component'
import { MyAccountVideoPlaylistCreateComponent } from './my-account-video-playlists/my-account-video-playlist-create.component'
import { MyAccountVideoPlaylistElementsComponent } from './my-account-video-playlists/my-account-video-playlist-elements.component'
import { MyAccountVideoPlaylistUpdateComponent } from './my-account-video-playlists/my-account-video-playlist-update.component'
import { MyAccountVideoPlaylistsComponent } from './my-account-video-playlists/my-account-video-playlists.component'
import { MyAccountVideosComponent } from './my-account-videos/my-account-videos.component'
import { MyAccountVideoImportsComponent } from '@app/+my-account/my-account-video-imports/my-account-video-imports.component'
import { MyAccountSubscriptionsComponent } from '@app/+my-account/my-account-subscriptions/my-account-subscriptions.component'
import { MyAccountOwnershipComponent } from '@app/+my-account/my-account-ownership/my-account-ownership.component'
import { MyAccountBlocklistComponent } from '@app/+my-account/my-account-blocklist/my-account-blocklist.component'
import { MyAccountServerBlocklistComponent } from '@app/+my-account/my-account-blocklist/my-account-server-blocklist.component'
import { MyAccountHistoryComponent } from '@app/+my-account/my-account-history/my-account-history.component'
import { MyAccountNotificationsComponent } from '@app/+my-account/my-account-notifications/my-account-notifications.component'
import { MyAccountVideoPlaylistsComponent } from '@app/+my-account/my-account-video-playlists/my-account-video-playlists.component'
import {
MyAccountVideoPlaylistCreateComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-create.component'
import {
MyAccountVideoPlaylistUpdateComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-update.component'
import {
MyAccountVideoPlaylistElementsComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component'
import { MyAccountComponent } from './my-account.component'
const myAccountRoutes: Routes = [
{
@ -46,7 +40,10 @@ const myAccountRoutes: Routes = [
{
path: 'video-channels',
loadChildren: () => import('./my-account-video-channels/my-account-video-channels.module').then(m => m.MyAccountVideoChannelsModule)
loadChildren: () => {
return import('./+my-account-video-channels/my-account-video-channels.module')
.then(m => m.MyAccountVideoChannelsModule)
}
},
{

View File

@ -1,12 +1,10 @@
import { Component, OnInit } from '@angular/core'
import { AuthService, Notifier, ServerService } from '@app/core'
import { FormReactive, UserService } from '../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { User } from '../../../../../../shared'
import { tap } from 'rxjs/operators'
import { forkJoin } from 'rxjs'
import { tap } from 'rxjs/operators'
import { Component, OnInit } from '@angular/core'
import { AuthService, ServerService, UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { User } from '@shared/models'
@Component({
selector: 'my-account-change-email',
@ -21,7 +19,6 @@ export class MyAccountChangeEmailComponent extends FormReactive implements OnIni
constructor (
protected formValidatorService: FormValidatorService,
private userValidatorsService: UserValidatorsService,
private notifier: Notifier,
private authService: AuthService,
private userService: UserService,
private serverService: ServerService,

View File

@ -1,11 +1,9 @@
import { Component, OnInit } from '@angular/core'
import { AuthService, Notifier } from '@app/core'
import { FormReactive, UserService } from '../../../shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { filter } from 'rxjs/operators'
import { User } from '../../../../../../shared'
import { Component, OnInit } from '@angular/core'
import { AuthService, Notifier, UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { User } from '@shared/models'
@Component({
selector: 'my-account-change-password',

View File

@ -1,9 +1,6 @@
import { Component, Input } from '@angular/core'
import { Notifier } from '@app/core'
import { AuthService, ConfirmService, RedirectService } from '../../../core'
import { UserService } from '../../../shared'
import { AuthService, ConfirmService, Notifier, RedirectService, User, UserService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { User } from '@app/shared'
@Component({
selector: 'my-account-danger-zone',

View File

@ -1 +0,0 @@
export * from './my-account-interface-settings.component'

View File

@ -1,11 +1,10 @@
import { Component, Input, OnInit } from '@angular/core'
import { User } from '@app/shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { Subject } from 'rxjs'
import { UserNotificationSetting, UserNotificationSettingValue, UserRight } from '../../../../../../shared'
import { Notifier, ServerService } from '@app/core'
import { debounce } from 'lodash-es'
import { UserNotificationService } from '@app/shared/users/user-notification.service'
import { Subject } from 'rxjs'
import { Component, Input, OnInit } from '@angular/core'
import { Notifier, ServerService, User } from '@app/core'
import { UserNotificationService } from '@app/shared/shared-main'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { UserNotificationSetting, UserNotificationSettingValue, UserRight } from '@shared/models'
@Component({
selector: 'my-account-notification-preferences',

View File

@ -1,11 +1,8 @@
import { Component, Input, OnInit } from '@angular/core'
import { Notifier } from '@app/core'
import { FormReactive, UserService } from '../../../shared'
import { User } from '@app/shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { Subject } from 'rxjs'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { Component, Input, OnInit } from '@angular/core'
import { Notifier, User, UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
@Component({
selector: 'my-account-profile',

View File

@ -34,7 +34,7 @@
</div>
<div class="form-group form-group-right col-12 col-lg-8 col-xl-9">
<my-account-video-settings [user]="user" [userInformationLoaded]="userInformationLoaded"></my-account-video-settings>
<my-user-video-settings [user]="user" [userInformationLoaded]="userInformationLoaded"></my-user-video-settings>
</div>
</div>
@ -55,7 +55,7 @@
</div>
<div class="form-group form-group-right col-12 col-lg-8 col-xl-9">
<my-account-interface-settings [user]="user" [userInformationLoaded]="userInformationLoaded"></my-account-interface-settings>
<my-user-interface-settings [user]="user" [userInformationLoaded]="userInformationLoaded"></my-user-interface-settings>
</div>
</div>

View File

@ -1,11 +1,8 @@
import { Component, OnInit, AfterViewChecked } from '@angular/core'
import { Notifier } from '@app/core'
import { BytesPipe } from 'ngx-pipes'
import { AuthService } from '../../core'
import { User } from '../../shared'
import { UserService } from '../../shared/users'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ViewportScroller } from '@angular/common'
import { AfterViewChecked, Component, OnInit } from '@angular/core'
import { AuthService, Notifier, User, UserService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
@Component({
selector: 'my-account-settings',

View File

@ -1 +0,0 @@
export * from './my-account-video-settings.component'

View File

@ -1,9 +1,8 @@
import { Component, OnInit } from '@angular/core'
import { Notifier } from '@app/core'
import { VideoChannel } from '@app/shared/video-channel/video-channel.model'
import { UserSubscriptionService } from '@app/shared/user-subscription'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { Subject } from 'rxjs'
import { Component, OnInit } from '@angular/core'
import { ComponentPagination, Notifier } from '@app/core'
import { VideoChannel } from '@app/shared/shared-main'
import { UserSubscriptionService } from '@app/shared/shared-user-subscription'
@Component({
selector: 'my-account-subscriptions',

View File

@ -1,9 +1,8 @@
import { Component, OnInit } from '@angular/core'
import { RestPagination, RestTable } from '@app/shared'
import { SortMeta } from 'primeng/api'
import { Notifier } from '@app/core'
import { VideoImport, VideoImportState } from '../../../../../shared/models/videos'
import { VideoImportService } from '@app/shared/video-import'
import { Component, OnInit } from '@angular/core'
import { Notifier, RestPagination, RestTable } from '@app/core'
import { VideoImportService } from '@app/shared/shared-main'
import { VideoImport, VideoImportState } from '@shared/models'
@Component({
selector: 'my-account-video-imports',

View File

@ -1,14 +1,13 @@
import { Component, OnInit } from '@angular/core'
import { Router } from '@angular/router'
import { AuthService, Notifier, ServerService } from '@app/core'
import { MyAccountVideoPlaylistEdit } from './my-account-video-playlist-edit'
import { FormValidatorService, VideoPlaylistValidatorsService } from '@app/shared/shared-forms'
import { VideoPlaylistService } from '@app/shared/shared-video-playlist'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { VideoPlaylistValidatorsService } from '@app/shared'
import { VideoPlaylistCreate } from '@shared/models/videos/playlist/video-playlist-create.model'
import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service'
import { VideoPlaylistPrivacy } from '@shared/models/videos/playlist/video-playlist-privacy.model'
import { populateAsyncUserVideoChannels } from '@app/shared/misc/utils'
import { MyAccountVideoPlaylistEdit } from './my-account-video-playlist-edit'
import { populateAsyncUserVideoChannels } from '@app/helpers'
@Component({
selector: 'my-account-video-playlist-create',

View File

@ -1,6 +1,6 @@
import { FormReactive } from '@app/shared'
import { VideoPlaylist } from '@shared/models/videos/playlist/video-playlist.model'
import { FormReactive } from '@app/shared/shared-forms'
import { VideoConstant, VideoPlaylistPrivacy } from '@shared/models'
import { VideoPlaylist } from '@shared/models/videos/playlist/video-playlist.model'
export abstract class MyAccountVideoPlaylistEdit extends FormReactive {
// Declare it here to avoid errors in create template

View File

@ -1,16 +1,9 @@
import { Component, OnDestroy, OnInit } from '@angular/core'
import { Notifier, ServerService } from '@app/core'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { Subject, Subscription } from 'rxjs'
import { ActivatedRoute } from '@angular/router'
import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service'
import { VideoPlaylist } from '@app/shared/video-playlist/video-playlist.model'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ScreenService } from '@app/shared/misc/screen.service'
import { CdkDragDrop } from '@angular/cdk/drag-drop'
import { VideoPlaylistElement } from '@app/shared/video-playlist/video-playlist-element.model'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute } from '@angular/router'
import { ComponentPagination, Notifier, ScreenService } from '@app/core'
import { VideoPlaylist, VideoPlaylistElement, VideoPlaylistService } from '@app/shared/shared-video-playlist'
@Component({
selector: 'my-account-video-playlist-elements',
@ -33,12 +26,8 @@ export class MyAccountVideoPlaylistElementsComponent implements OnInit, OnDestro
private paramsSub: Subscription
constructor (
private authService: AuthService,
private serverService: ServerService,
private notifier: Notifier,
private confirmService: ConfirmService,
private route: ActivatedRoute,
private i18n: I18n,
private screenService: ScreenService,
private videoPlaylistService: VideoPlaylistService
) {}

View File

@ -1,16 +1,14 @@
import { forkJoin, Subscription } from 'rxjs'
import { map, switchMap } from 'rxjs/operators'
import { Component, OnDestroy, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { AuthService, Notifier, ServerService } from '@app/core'
import { forkJoin, Subscription } from 'rxjs'
import { populateAsyncUserVideoChannels } from '@app/helpers'
import { FormValidatorService, VideoPlaylistValidatorsService } from '@app/shared/shared-forms'
import { VideoPlaylist, VideoPlaylistService } from '@app/shared/shared-video-playlist'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { MyAccountVideoPlaylistEdit } from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-edit'
import { populateAsyncUserVideoChannels } from '@app/shared/misc/utils'
import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service'
import { VideoPlaylistValidatorsService } from '@app/shared'
import { VideoPlaylistUpdate } from '@shared/models/videos/playlist/video-playlist-update.model'
import { VideoPlaylist } from '@app/shared/video-playlist/video-playlist.model'
import { delayWhen, map, switchMap } from 'rxjs/operators'
import { VideoPlaylistUpdate } from '@shared/models'
import { MyAccountVideoPlaylistEdit } from './my-account-video-playlist-edit'
@Component({
selector: 'my-account-video-playlist-update',

View File

@ -1,15 +1,10 @@
import { Component, OnInit } from '@angular/core'
import { Notifier } from '@app/core'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { User } from '@app/shared'
import { flatMap, debounceTime } from 'rxjs/operators'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoPlaylist } from '@app/shared/video-playlist/video-playlist.model'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { VideoPlaylistService } from '@app/shared/video-playlist/video-playlist.service'
import { VideoPlaylistType } from '@shared/models'
import { Subject } from 'rxjs'
import { debounceTime, flatMap } from 'rxjs/operators'
import { Component, OnInit } from '@angular/core'
import { AuthService, ComponentPagination, ConfirmService, Notifier, User } from '@app/core'
import { VideoPlaylist, VideoPlaylistService } from '@app/shared/shared-video-playlist'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoPlaylistType } from '@shared/models'
@Component({
selector: 'my-account-video-playlists',

View File

@ -1,21 +1,15 @@
import { concat, Observable, Subject } from 'rxjs'
import { tap, toArray, debounceTime } from 'rxjs/operators'
import { Component, ViewChild, OnInit } from '@angular/core'
import { debounceTime, tap, toArray } from 'rxjs/operators'
import { Component, OnInit, ViewChild } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { immutableAssign } from '@app/shared/misc/utils'
import { ComponentPagination } from '@app/shared/rest/component-pagination.model'
import { Notifier, ServerService } from '@app/core'
import { AuthService } from '../../core/auth'
import { ConfirmService } from '../../core/confirm'
import { Video } from '../../shared/video/video.model'
import { VideoService } from '../../shared/video/video.service'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { ScreenService } from '@app/shared/misc/screen.service'
import { VideoChangeOwnershipComponent } from './video-change-ownership/video-change-ownership.component'
import { MiniatureDisplayOptions, OwnerDisplayType } from '@app/shared/video/video-miniature.component'
import { SelectionType, VideosSelectionComponent } from '@app/shared/video/videos-selection.component'
import { VideoSortField } from '@app/shared/video/sort-field.type'
import { AuthService, ComponentPagination, ConfirmService, Notifier, ScreenService, ServerService } from '@app/core'
import { DisableForReuseHook } from '@app/core/routing/disable-for-reuse-hook'
import { immutableAssign } from '@app/helpers'
import { Video, VideoService } from '@app/shared/shared-main'
import { MiniatureDisplayOptions, OwnerDisplayType, SelectionType, VideosSelectionComponent } from '@app/shared/shared-video-miniature'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { VideoSortField } from '@shared/models'
import { VideoChangeOwnershipComponent } from './video-change-ownership/video-change-ownership.component'
@Component({
selector: 'my-account-videos',

View File

@ -1,11 +1,9 @@
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core'
import { Notifier } from '@app/core'
import { Notifier, UserService } from '@app/core'
import { FormReactive, FormValidatorService, VideoChangeOwnershipValidatorsService } from '@app/shared/shared-forms'
import { Video, VideoOwnershipService } from '@app/shared/shared-main'
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
import { FormReactive, UserService } from '../../../shared/index'
import { Video } from '@app/shared/video/video.model'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { FormValidatorService, VideoChangeOwnershipValidatorsService } from '@app/shared'
import { VideoOwnershipService } from '@app/shared/video-ownership'
@Component({
selector: 'my-video-change-ownership',

View File

@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core'
import { ServerService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { TopMenuDropdownParam } from '@app/shared/menu/top-menu-dropdown.component'
import { ServerConfig } from '@shared/models'
import { TopMenuDropdownParam } from './top-menu-dropdown.component'
@Component({
selector: 'my-my-account',

View File

@ -1,47 +1,55 @@
import { NgModule } from '@angular/core'
import { TableModule } from 'primeng/table'
import { AutoCompleteModule } from 'primeng/autocomplete'
import { InputSwitchModule } from 'primeng/inputswitch'
import { SharedModule } from '../shared'
import { TableModule } from 'primeng/table'
import { DragDropModule } from '@angular/cdk/drag-drop'
import { NgModule } from '@angular/core'
import { SharedGlobalIconModule } from '@app/shared/shared-icons'
import { SharedMainModule } from '@app/shared/shared-main'
import { SharedModerationModule } from '@app/shared/shared-moderation'
import { SharedUserInterfaceSettingsModule } from '@app/shared/shared-user-settings'
import { SharedUserSubscriptionModule } from '@app/shared/shared-user-subscription/shared-user-subscription.module'
import { SharedVideoMiniatureModule } from '@app/shared/shared-video-miniature'
import { SharedVideoPlaylistModule } from '@app/shared/shared-video-playlist/shared-video-playlist.module'
import { MyAccountBlocklistComponent } from './my-account-blocklist/my-account-blocklist.component'
import { MyAccountServerBlocklistComponent } from './my-account-blocklist/my-account-server-blocklist.component'
import { MyAccountHistoryComponent } from './my-account-history/my-account-history.component'
import { MyAccountNotificationsComponent } from './my-account-notifications/my-account-notifications.component'
import { MyAccountAcceptOwnershipComponent } from './my-account-ownership/my-account-accept-ownership/my-account-accept-ownership.component'
import { MyAccountOwnershipComponent } from './my-account-ownership/my-account-ownership.component'
import { MyAccountRoutingModule } from './my-account-routing.module'
import { MyAccountChangeEmailComponent } from './my-account-settings/my-account-change-email'
import { MyAccountChangePasswordComponent } from './my-account-settings/my-account-change-password/my-account-change-password.component'
import { MyAccountDangerZoneComponent } from './my-account-settings/my-account-danger-zone'
import { MyAccountNotificationPreferencesComponent } from './my-account-settings/my-account-notification-preferences'
import { MyAccountProfileComponent } from './my-account-settings/my-account-profile/my-account-profile.component'
import { MyAccountSettingsComponent } from './my-account-settings/my-account-settings.component'
import { MyAccountComponent } from './my-account.component'
import { MyAccountSubscriptionsComponent } from './my-account-subscriptions/my-account-subscriptions.component'
import { MyAccountVideoImportsComponent } from './my-account-video-imports/my-account-video-imports.component'
import { MyAccountVideoPlaylistCreateComponent } from './my-account-video-playlists/my-account-video-playlist-create.component'
import { MyAccountVideoPlaylistElementsComponent } from './my-account-video-playlists/my-account-video-playlist-elements.component'
import { MyAccountVideoPlaylistUpdateComponent } from './my-account-video-playlists/my-account-video-playlist-update.component'
import { MyAccountVideoPlaylistsComponent } from './my-account-video-playlists/my-account-video-playlists.component'
import { MyAccountVideosComponent } from './my-account-videos/my-account-videos.component'
import { VideoChangeOwnershipComponent } from './my-account-videos/video-change-ownership/video-change-ownership.component'
import { MyAccountOwnershipComponent } from './my-account-ownership/my-account-ownership.component'
import { MyAccountAcceptOwnershipComponent } from './my-account-ownership/my-account-accept-ownership/my-account-accept-ownership.component'
import { MyAccountProfileComponent } from '@app/+my-account/my-account-settings/my-account-profile/my-account-profile.component'
import { MyAccountVideoImportsComponent } from '@app/+my-account/my-account-video-imports/my-account-video-imports.component'
import { MyAccountDangerZoneComponent } from '@app/+my-account/my-account-settings/my-account-danger-zone'
import { MyAccountSubscriptionsComponent } from '@app/+my-account/my-account-subscriptions/my-account-subscriptions.component'
import { MyAccountBlocklistComponent } from '@app/+my-account/my-account-blocklist/my-account-blocklist.component'
import { MyAccountServerBlocklistComponent } from '@app/+my-account/my-account-blocklist/my-account-server-blocklist.component'
import { MyAccountHistoryComponent } from '@app/+my-account/my-account-history/my-account-history.component'
import { MyAccountNotificationsComponent } from '@app/+my-account/my-account-notifications/my-account-notifications.component'
import { MyAccountNotificationPreferencesComponent } from '@app/+my-account/my-account-settings/my-account-notification-preferences'
import {
MyAccountVideoPlaylistCreateComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-create.component'
import {
MyAccountVideoPlaylistUpdateComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-update.component'
import { MyAccountVideoPlaylistsComponent } from '@app/+my-account/my-account-video-playlists/my-account-video-playlists.component'
import {
MyAccountVideoPlaylistElementsComponent
} from '@app/+my-account/my-account-video-playlists/my-account-video-playlist-elements.component'
import { DragDropModule } from '@angular/cdk/drag-drop'
import { MyAccountChangeEmailComponent } from '@app/+my-account/my-account-settings/my-account-change-email'
import { MyAccountComponent } from './my-account.component'
import { TopMenuDropdownComponent } from './top-menu-dropdown.component'
@NgModule({
imports: [
TableModule,
MyAccountRoutingModule,
AutoCompleteModule,
SharedModule,
TableModule,
InputSwitchModule,
DragDropModule
DragDropModule,
SharedMainModule,
SharedModerationModule,
SharedVideoMiniatureModule,
SharedUserSubscriptionModule,
SharedVideoPlaylistModule,
SharedUserInterfaceSettingsModule,
SharedGlobalIconModule
],
declarations: [
@ -68,7 +76,9 @@ import { MyAccountChangeEmailComponent } from '@app/+my-account/my-account-setti
MyAccountVideoPlaylistCreateComponent,
MyAccountVideoPlaylistUpdateComponent,
MyAccountVideoPlaylistsComponent,
MyAccountVideoPlaylistElementsComponent
MyAccountVideoPlaylistElementsComponent,
TopMenuDropdownComponent
],
exports: [

View File

@ -1,17 +1,10 @@
import {
Component,
Input,
OnDestroy,
OnInit,
ViewChild
} from '@angular/core'
import { filter, take } from 'rxjs/operators'
import { NavigationEnd, Router } from '@angular/router'
import { Subscription } from 'rxjs'
import { filter, take } from 'rxjs/operators'
import { Component, Input, OnDestroy, OnInit, ViewChild } from '@angular/core'
import { NavigationEnd, Router } from '@angular/router'
import { MenuService, ScreenService } from '@app/core'
import { GlobalIconName } from '@app/shared/shared-icons'
import { NgbDropdown, NgbModal } from '@ng-bootstrap/ng-bootstrap'
import { GlobalIconName } from '@app/shared/images/global-icon.component'
import { ScreenService } from '@app/shared/misc/screen.service'
import { MenuService } from '@app/core/menu'
export type TopMenuDropdownParam = {
label: string

View File

@ -1,12 +1,13 @@
import { CommonModule } from '@angular/common'
import { NgModule } from '@angular/core'
import { SharedModule } from '../shared'
import { PageNotFoundComponent } from '@app/+page-not-found/page-not-found.component'
import { PageNotFoundRoutingModule } from '@app/+page-not-found/page-not-found-routing.module'
import { PageNotFoundRoutingModule } from './page-not-found-routing.module'
import { PageNotFoundComponent } from './page-not-found.component'
@NgModule({
imports: [
PageNotFoundRoutingModule,
SharedModule
CommonModule,
PageNotFoundRoutingModule
],
declarations: [

View File

@ -1,9 +1,8 @@
import { NgModule } from '@angular/core'
import { RouterModule, Routes } from '@angular/router'
import { ServerConfigResolver, UnloggedGuard } from '@app/core'
import { MetaGuard } from '@ngx-meta/core'
import { RegisterComponent } from './register.component'
import { ServerConfigResolver } from '@app/core/routing/server-config-resolver.service'
import { UnloggedGuard } from '@app/core/routing/unlogged-guard.service'
const registerRoutes: Routes = [
{

View File

@ -1,10 +1,9 @@
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
import { AuthService } from '@app/core'
import { FormReactive, UserService, VideoChannelValidatorsService } from '@app/shared'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { FormGroup } from '@angular/forms'
import { pairwise } from 'rxjs/operators'
import { concat, of } from 'rxjs'
import { pairwise } from 'rxjs/operators'
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
import { FormGroup } from '@angular/forms'
import { UserService } from '@app/core'
import { FormReactive, FormValidatorService, VideoChannelValidatorsService } from '@app/shared/shared-forms'
@Component({
selector: 'my-register-step-channel',
@ -17,7 +16,6 @@ export class RegisterStepChannelComponent extends FormReactive implements OnInit
constructor (
protected formValidatorService: FormValidatorService,
private authService: AuthService,
private userService: UserService,
private videoChannelValidatorsService: VideoChannelValidatorsService
) {

View File

@ -1,10 +1,9 @@
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
import { AuthService } from '@app/core'
import { FormReactive, UserService, UserValidatorsService } from '@app/shared'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { FormGroup } from '@angular/forms'
import { pairwise } from 'rxjs/operators'
import { concat, of } from 'rxjs'
import { pairwise } from 'rxjs/operators'
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core'
import { FormGroup } from '@angular/forms'
import { UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
@Component({
selector: 'my-register-step-user',
@ -20,7 +19,6 @@ export class RegisterStepUserComponent extends FormReactive implements OnInit {
constructor (
protected formValidatorService: FormValidatorService,
private authService: AuthService,
private userService: UserService,
private userValidatorsService: UserValidatorsService
) {

View File

@ -1,14 +1,13 @@
import { Component, OnInit, ViewChild } from '@angular/core'
import { AuthService, Notifier, RedirectService, ServerService } from '@app/core'
import { UserService, UserValidatorsService } from '@app/shared'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { UserRegister } from '@shared/models/users/user-register.model'
import { FormGroup } from '@angular/forms'
import { About, ServerConfig } from '@shared/models/server'
import { InstanceService } from '@app/shared/instance/instance.service'
import { HooksService } from '@app/core/plugins/hooks.service'
import { NgbAccordion } from '@ng-bootstrap/ng-bootstrap'
import { ActivatedRoute } from '@angular/router'
import { AuthService, Notifier, UserService } from '@app/core'
import { HooksService } from '@app/core/plugins/hooks.service'
import { InstanceService } from '@app/shared/shared-instance'
import { NgbAccordion } from '@ng-bootstrap/ng-bootstrap'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { UserRegister } from '@shared/models'
import { About, ServerConfig } from '@shared/models/server'
@Component({
selector: 'my-register',
@ -40,11 +39,8 @@ export class RegisterComponent implements OnInit {
constructor (
private route: ActivatedRoute,
private authService: AuthService,
private userValidatorsService: UserValidatorsService,
private notifier: Notifier,
private userService: UserService,
private serverService: ServerService,
private redirectService: RedirectService,
private instanceService: InstanceService,
private hooks: HooksService,
private i18n: I18n

View File

@ -1,21 +1,24 @@
import { NgModule } from '@angular/core'
import { RegisterRoutingModule } from './register-routing.module'
import { RegisterComponent } from './register.component'
import { SharedModule } from '@app/shared'
import { CdkStepperModule } from '@angular/cdk/stepper'
import { NgModule } from '@angular/core'
import { SignupSharedModule } from '@app/+signup/shared/signup-shared.module'
import { SharedInstanceModule } from '@app/shared/shared-instance'
import { NgbAccordionModule } from '@ng-bootstrap/ng-bootstrap'
import { CustomStepperComponent } from './custom-stepper.component'
import { RegisterRoutingModule } from './register-routing.module'
import { RegisterStepChannelComponent } from './register-step-channel.component'
import { RegisterStepUserComponent } from './register-step-user.component'
import { CustomStepperComponent } from './custom-stepper.component'
import { SignupSharedModule } from '@app/+signup/shared/signup-shared.module'
import { NgbAccordionModule } from '@ng-bootstrap/ng-bootstrap'
import { RegisterComponent } from './register.component'
@NgModule({
imports: [
RegisterRoutingModule,
SharedModule,
CdkStepperModule,
NgbAccordionModule,
SignupSharedModule,
NgbAccordionModule
SharedInstanceModule
],
declarations: [

View File

@ -1,10 +1,7 @@
import { Component, OnInit } from '@angular/core'
import { Notifier, RedirectService, ServerService, UserService } from '@app/core'
import { FormReactive, FormValidatorService, UserValidatorsService } from '@app/shared/shared-forms'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { Notifier, RedirectService } from '@app/core'
import { ServerService } from '@app/core/server'
import { FormReactive, UserService } from '@app/shared'
import { FormValidatorService } from '@app/shared/forms/form-validators/form-validator.service'
import { UserValidatorsService } from '@app/shared/forms/form-validators/user-validators.service'
import { ServerConfig } from '@shared/models'
@Component({

View File

@ -1,8 +1,7 @@
import { Component, OnInit } from '@angular/core'
import { ActivatedRoute, Router } from '@angular/router'
import { ActivatedRoute } from '@angular/router'
import { AuthService, Notifier, UserService } from '@app/core'
import { I18n } from '@ngx-translate/i18n-polyfill'
import { AuthService, Notifier } from '@app/core'
import { UserService } from '@app/shared'
@Component({
selector: 'my-verify-account-email',
@ -21,7 +20,6 @@ export class VerifyAccountEmailComponent implements OnInit {
private userService: UserService,
private authService: AuthService,
private notifier: Notifier,
private router: Router,
private route: ActivatedRoute,
private i18n: I18n
) {

View File

@ -1,14 +1,13 @@
import { NgModule } from '@angular/core'
import { VerifyAccountRoutingModule } from './verify-account-routing.module'
import { VerifyAccountEmailComponent } from './verify-account-email/verify-account-email.component'
import { SignupSharedModule } from '../shared/signup-shared.module'
import { VerifyAccountAskSendEmailComponent } from './verify-account-ask-send-email/verify-account-ask-send-email.component'
import { SharedModule } from '@app/shared'
import { SignupSharedModule } from '@app/+signup/shared/signup-shared.module'
import { VerifyAccountEmailComponent } from './verify-account-email/verify-account-email.component'
import { VerifyAccountRoutingModule } from './verify-account-routing.module'
@NgModule({
imports: [
VerifyAccountRoutingModule,
SharedModule,
SignupSharedModule
],

Some files were not shown because too many files have changed in this diff Show More