mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-02-25 18:55:32 -06:00
Migrate to standalone components
This commit is contained in:
parent
62cc9b1752
commit
5e041ff7c2
@ -3,11 +3,14 @@ import { Component, OnInit } from '@angular/core'
|
|||||||
import { ComponentPagination, hasMoreItems, Notifier, RestService, ServerService } from '@app/core'
|
import { ComponentPagination, hasMoreItems, Notifier, RestService, ServerService } from '@app/core'
|
||||||
import { InstanceFollowService } from '@app/shared/shared-instance'
|
import { InstanceFollowService } from '@app/shared/shared-instance'
|
||||||
import { Actor } from '@peertube/peertube-models'
|
import { Actor } from '@peertube/peertube-models'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-about-follows',
|
selector: 'my-about-follows',
|
||||||
templateUrl: './about-follows.component.html',
|
templateUrl: './about-follows.component.html',
|
||||||
styleUrls: [ './about-follows.component.scss' ]
|
styleUrls: [ './about-follows.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, NgFor ]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class AboutFollowsComponent implements OnInit {
|
export class AboutFollowsComponent implements OnInit {
|
||||||
|
@ -1,17 +1,32 @@
|
|||||||
import { ViewportScroller } from '@angular/common'
|
import { ViewportScroller, NgIf, NgFor } from '@angular/common'
|
||||||
import { AfterViewChecked, Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
import { AfterViewChecked, Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute } from '@angular/router'
|
import { ActivatedRoute, RouterLink } from '@angular/router'
|
||||||
import { Notifier, ServerService } from '@app/core'
|
import { Notifier, ServerService } from '@app/core'
|
||||||
import { AboutHTML } from '@app/shared/shared-instance'
|
|
||||||
import { HTMLServerConfig, ServerStats } from '@peertube/peertube-models'
|
import { HTMLServerConfig, ServerStats } from '@peertube/peertube-models'
|
||||||
import { copyToClipboard } from '@root-helpers/utils'
|
import { copyToClipboard } from '@root-helpers/utils'
|
||||||
import { ResolverData } from './about-instance.resolver'
|
import { ResolverData } from './about-instance.resolver'
|
||||||
import { ContactAdminModalComponent } from './contact-admin-modal.component'
|
import { ContactAdminModalComponent } from './contact-admin-modal.component'
|
||||||
|
import { InstanceStatisticsComponent } from './instance-statistics.component'
|
||||||
|
import { InstanceFeaturesTableComponent } from '../../shared/shared-instance/instance-features-table.component'
|
||||||
|
import { PluginSelectorDirective } from '../../shared/shared-main/plugins/plugin-selector.directive'
|
||||||
|
import { CustomMarkupContainerComponent } from '../../shared/shared-custom-markup/custom-markup-container.component'
|
||||||
|
import { AboutHTML } from '@app/shared/shared-main'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-about-instance',
|
selector: 'my-about-instance',
|
||||||
templateUrl: './about-instance.component.html',
|
templateUrl: './about-instance.component.html',
|
||||||
styleUrls: [ './about-instance.component.scss' ]
|
styleUrls: [ './about-instance.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
RouterLink,
|
||||||
|
NgFor,
|
||||||
|
CustomMarkupContainerComponent,
|
||||||
|
PluginSelectorDirective,
|
||||||
|
InstanceFeaturesTableComponent,
|
||||||
|
InstanceStatisticsComponent,
|
||||||
|
ContactAdminModalComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class AboutInstanceComponent implements OnInit, AfterViewChecked {
|
export class AboutInstanceComponent implements OnInit, AfterViewChecked {
|
||||||
@ViewChild('descriptionWrapper') descriptionWrapper: ElementRef<HTMLInputElement>
|
@ViewChild('descriptionWrapper') descriptionWrapper: ElementRef<HTMLInputElement>
|
||||||
|
@ -3,8 +3,8 @@ import { map, switchMap } from 'rxjs/operators'
|
|||||||
import { Injectable } from '@angular/core'
|
import { Injectable } from '@angular/core'
|
||||||
import { ServerService } from '@app/core'
|
import { ServerService } from '@app/core'
|
||||||
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
||||||
import { AboutHTML, InstanceService } from '@app/shared/shared-instance'
|
|
||||||
import { About, ServerStats } from '@peertube/peertube-models'
|
import { About, ServerStats } from '@peertube/peertube-models'
|
||||||
|
import { InstanceService, AboutHTML } from '@app/shared/shared-main'
|
||||||
|
|
||||||
export type ResolverData = {
|
export type ResolverData = {
|
||||||
serverStats: ServerStats
|
serverStats: ServerStats
|
||||||
|
@ -8,10 +8,13 @@ import {
|
|||||||
SUBJECT_VALIDATOR
|
SUBJECT_VALIDATOR
|
||||||
} from '@app/shared/form-validators/instance-validators'
|
} from '@app/shared/form-validators/instance-validators'
|
||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { InstanceService } from '@app/shared/shared-instance'
|
import { InstanceService } from '@app/shared/shared-main'
|
||||||
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
|
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
|
||||||
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
|
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
|
||||||
import { HTMLServerConfig, HttpStatusCode } from '@peertube/peertube-models'
|
import { HTMLServerConfig, HttpStatusCode } from '@peertube/peertube-models'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
type Prefill = {
|
type Prefill = {
|
||||||
subject?: string
|
subject?: string
|
||||||
@ -21,7 +24,9 @@ type Prefill = {
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'my-contact-admin-modal',
|
selector: 'my-contact-admin-modal',
|
||||||
templateUrl: './contact-admin-modal.component.html',
|
templateUrl: './contact-admin-modal.component.html',
|
||||||
styleUrls: [ './contact-admin-modal.component.scss' ]
|
styleUrls: [ './contact-admin-modal.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, NgIf, FormsModule, ReactiveFormsModule, NgClass ]
|
||||||
})
|
})
|
||||||
export class ContactAdminModalComponent extends FormReactive implements OnInit {
|
export class ContactAdminModalComponent extends FormReactive implements OnInit {
|
||||||
@ViewChild('modal', { static: true }) modal: NgbModal
|
@ViewChild('modal', { static: true }) modal: NgbModal
|
||||||
|
@ -1,10 +1,15 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { ServerStats } from '@peertube/peertube-models'
|
import { ServerStats } from '@peertube/peertube-models'
|
||||||
|
import { BytesPipe } from '../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
import { NgIf, DecimalPipe } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-instance-statistics',
|
selector: 'my-instance-statistics',
|
||||||
templateUrl: './instance-statistics.component.html',
|
templateUrl: './instance-statistics.component.html',
|
||||||
styleUrls: [ './instance-statistics.component.scss' ]
|
styleUrls: [ './instance-statistics.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, GlobalIconComponent, DecimalPipe, BytesPipe ]
|
||||||
})
|
})
|
||||||
export class InstanceStatisticsComponent {
|
export class InstanceStatisticsComponent {
|
||||||
@Input() serverStats: ServerStats
|
@Input() serverStats: ServerStats
|
||||||
|
@ -4,7 +4,8 @@ import { ViewportScroller } from '@angular/common'
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'my-about-peertube',
|
selector: 'my-about-peertube',
|
||||||
templateUrl: './about-peertube.component.html',
|
templateUrl: './about-peertube.component.html',
|
||||||
styleUrls: [ './about-peertube.component.scss' ]
|
styleUrls: [ './about-peertube.component.scss' ],
|
||||||
|
standalone: true
|
||||||
})
|
})
|
||||||
|
|
||||||
export class AboutPeertubeComponent implements AfterViewChecked {
|
export class AboutPeertubeComponent implements AfterViewChecked {
|
||||||
|
@ -1,9 +1,14 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
import { ScreenService } from '@app/core'
|
import { ScreenService } from '@app/core'
|
||||||
|
import { RouterLink, RouterLinkActive, RouterOutlet } from '@angular/router'
|
||||||
|
import { PluginSelectorDirective } from '../shared/shared-main/plugins/plugin-selector.directive'
|
||||||
|
import { NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-about',
|
selector: 'my-about',
|
||||||
templateUrl: './about.component.html'
|
templateUrl: './about.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgClass, PluginSelectorDirective, RouterLink, RouterLinkActive, RouterOutlet ]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class AboutComponent {
|
export class AboutComponent {
|
||||||
|
@ -1,46 +0,0 @@
|
|||||||
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 { InstanceStatisticsComponent } from '@app/+about/about-instance/instance-statistics.component'
|
|
||||||
import { AboutPeertubeComponent } from '@app/+about/about-peertube/about-peertube.component'
|
|
||||||
import { SharedCustomMarkupModule } from '@app/shared/shared-custom-markup'
|
|
||||||
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'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
AboutRoutingModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedInstanceModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedCustomMarkupModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
AboutComponent,
|
|
||||||
|
|
||||||
AboutInstanceComponent,
|
|
||||||
ContactAdminModalComponent,
|
|
||||||
InstanceStatisticsComponent,
|
|
||||||
|
|
||||||
AboutPeertubeComponent,
|
|
||||||
AboutFollowsComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
AboutComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: [
|
|
||||||
AboutInstanceResolver
|
|
||||||
]
|
|
||||||
})
|
|
||||||
export class AboutModule { }
|
|
@ -1,3 +0,0 @@
|
|||||||
export * from './about-routing.module'
|
|
||||||
export * from './about.component'
|
|
||||||
export * from './about.module'
|
|
@ -1,15 +1,22 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { AboutFollowsComponent } from '@app/+about/about-follows/about-follows.component'
|
import { AboutFollowsComponent } from '@app/+about/about-follows/about-follows.component'
|
||||||
import { AboutInstanceComponent } from '@app/+about/about-instance/about-instance.component'
|
import { AboutInstanceComponent } from '@app/+about/about-instance/about-instance.component'
|
||||||
import { AboutInstanceResolver } from '@app/+about/about-instance/about-instance.resolver'
|
import { AboutInstanceResolver } from '@app/+about/about-instance/about-instance.resolver'
|
||||||
import { AboutPeertubeComponent } from '@app/+about/about-peertube/about-peertube.component'
|
import { AboutPeertubeComponent } from '@app/+about/about-peertube/about-peertube.component'
|
||||||
import { AboutComponent } from './about.component'
|
import { AboutComponent } from './about.component'
|
||||||
|
import { InstanceFollowService } from '@app/shared/shared-instance'
|
||||||
|
import { CustomMarkupService, DynamicElementService } from '@app/shared/shared-custom-markup'
|
||||||
|
|
||||||
const aboutRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
component: AboutComponent,
|
component: AboutComponent,
|
||||||
|
providers: [
|
||||||
|
AboutInstanceResolver,
|
||||||
|
InstanceFollowService,
|
||||||
|
CustomMarkupService,
|
||||||
|
DynamicElementService
|
||||||
|
],
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
@ -61,10 +68,4 @@ const aboutRoutes: Routes = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(aboutRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class AboutRoutingModule {}
|
|
@ -6,11 +6,19 @@ import { SimpleMemoize } from '@app/helpers'
|
|||||||
import { Account, AccountService, Video, VideoChannel, VideoChannelService, VideoService } from '@app/shared/shared-main'
|
import { Account, AccountService, Video, VideoChannel, VideoChannelService, VideoService } from '@app/shared/shared-main'
|
||||||
import { MiniatureDisplayOptions } from '@app/shared/shared-video-miniature'
|
import { MiniatureDisplayOptions } from '@app/shared/shared-video-miniature'
|
||||||
import { NSFWPolicyType, VideoSortField } from '@peertube/peertube-models'
|
import { NSFWPolicyType, VideoSortField } from '@peertube/peertube-models'
|
||||||
|
import { VideoMiniatureComponent } from '../../shared/shared-video-miniature/video-miniature.component'
|
||||||
|
import { SubscribeButtonComponent } from '../../shared/shared-user-subscription/subscribe-button.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { ActorAvatarComponent } from '../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { InfiniteScrollerDirective } from '../../shared/shared-main/angular/infinite-scroller.directive'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-video-channels',
|
selector: 'my-account-video-channels',
|
||||||
templateUrl: './account-video-channels.component.html',
|
templateUrl: './account-video-channels.component.html',
|
||||||
styleUrls: [ './account-video-channels.component.scss' ]
|
styleUrls: [ './account-video-channels.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, InfiniteScrollerDirective, NgFor, ActorAvatarComponent, RouterLink, SubscribeButtonComponent, VideoMiniatureComponent ]
|
||||||
})
|
})
|
||||||
export class AccountVideoChannelsComponent implements OnInit, OnDestroy {
|
export class AccountVideoChannelsComponent implements OnInit, OnDestroy {
|
||||||
account: Account
|
account: Account
|
||||||
|
@ -5,10 +5,14 @@ import { ComponentPaginationLight, DisableForReuseHook, ScreenService } from '@a
|
|||||||
import { Account, AccountService, VideoService } from '@app/shared/shared-main'
|
import { Account, AccountService, VideoService } from '@app/shared/shared-main'
|
||||||
import { VideoFilters } from '@app/shared/shared-video-miniature'
|
import { VideoFilters } from '@app/shared/shared-video-miniature'
|
||||||
import { VideoSortField } from '@peertube/peertube-models'
|
import { VideoSortField } from '@peertube/peertube-models'
|
||||||
|
import { VideosListComponent } from '../../shared/shared-video-miniature/videos-list.component'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-videos',
|
selector: 'my-account-videos',
|
||||||
templateUrl: './account-videos.component.html'
|
templateUrl: './account-videos.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, VideosListComponent ]
|
||||||
})
|
})
|
||||||
export class AccountVideosComponent implements OnInit, OnDestroy, DisableForReuseHook {
|
export class AccountVideosComponent implements OnInit, OnDestroy, DisableForReuseHook {
|
||||||
getVideosObservableFunction = this.getVideosObservable.bind(this)
|
getVideosObservableFunction = this.getVideosObservable.bind(this)
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { Subscription } from 'rxjs'
|
import { Subscription } from 'rxjs'
|
||||||
import { catchError, distinctUntilChanged, map, switchMap, tap } from 'rxjs/operators'
|
import { catchError, distinctUntilChanged, map, switchMap, tap } from 'rxjs/operators'
|
||||||
import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core'
|
import { Component, OnDestroy, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router, RouterLink, RouterLinkActive, RouterOutlet } from '@angular/router'
|
||||||
import { AuthService, MarkdownService, Notifier, RedirectService, RestExtractor, ScreenService, UserService } from '@app/core'
|
import { AuthService, MarkdownService, Notifier, RedirectService, RestExtractor, ScreenService, UserService } from '@app/core'
|
||||||
import {
|
import {
|
||||||
Account,
|
Account,
|
||||||
@ -14,10 +14,37 @@ import {
|
|||||||
} from '@app/shared/shared-main'
|
} from '@app/shared/shared-main'
|
||||||
import { AccountReportComponent, BlocklistService } from '@app/shared/shared-moderation'
|
import { AccountReportComponent, BlocklistService } from '@app/shared/shared-moderation'
|
||||||
import { HttpStatusCode, User, UserRight } from '@peertube/peertube-models'
|
import { HttpStatusCode, User, UserRight } from '@peertube/peertube-models'
|
||||||
|
import { SimpleSearchInputComponent } from '../shared/shared-main/misc/simple-search-input.component'
|
||||||
|
import { ListOverflowComponent } from '../shared/shared-main/misc/list-overflow.component'
|
||||||
|
import { SubscribeButtonComponent } from '../shared/shared-user-subscription/subscribe-button.component'
|
||||||
|
import { CopyButtonComponent } from '../shared/shared-main/buttons/copy-button.component'
|
||||||
|
import { AccountBlockBadgesComponent } from '../shared/shared-moderation/account-block-badges.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { UserModerationDropdownComponent } from '../shared/shared-moderation/user-moderation-dropdown.component'
|
||||||
|
import { ActorAvatarComponent } from '../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './accounts.component.html',
|
templateUrl: './accounts.component.html',
|
||||||
styleUrls: [ './accounts.component.scss' ]
|
styleUrls: [ './accounts.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
UserModerationDropdownComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
AccountBlockBadgesComponent,
|
||||||
|
CopyButtonComponent,
|
||||||
|
NgClass,
|
||||||
|
RouterLink,
|
||||||
|
SubscribeButtonComponent,
|
||||||
|
RouterLinkActive,
|
||||||
|
ListOverflowComponent,
|
||||||
|
SimpleSearchInputComponent,
|
||||||
|
RouterOutlet,
|
||||||
|
AccountReportComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class AccountsComponent implements OnInit, OnDestroy {
|
export class AccountsComponent implements OnInit, OnDestroy {
|
||||||
@ViewChild('accountReportModal') accountReportModal: AccountReportComponent
|
@ViewChild('accountReportModal') accountReportModal: AccountReportComponent
|
||||||
|
@ -1,39 +0,0 @@
|
|||||||
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 { SharedUserSubscriptionModule } from '@app/shared/shared-user-subscription'
|
|
||||||
import { SharedVideoMiniatureModule } from '@app/shared/shared-video-miniature'
|
|
||||||
import { SharedActorImageModule } from '../shared/shared-actor-image/shared-actor-image.module'
|
|
||||||
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,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedUserSubscriptionModule,
|
|
||||||
SharedModerationModule,
|
|
||||||
SharedVideoMiniatureModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedActorImageModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
AccountsComponent,
|
|
||||||
AccountVideosComponent,
|
|
||||||
AccountVideoChannelsComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
AccountsComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: []
|
|
||||||
})
|
|
||||||
export class AccountsModule { }
|
|
@ -1,3 +0,0 @@
|
|||||||
export * from './accounts-routing.module'
|
|
||||||
export * from './accounts.component'
|
|
||||||
export * from './accounts.module'
|
|
@ -1,10 +1,12 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
|
import { AccountVideoChannelsComponent } from './account-video-channels/account-video-channels.component'
|
||||||
import { AccountVideosComponent } from './account-videos/account-videos.component'
|
import { AccountVideosComponent } from './account-videos/account-videos.component'
|
||||||
import { AccountsComponent } from './accounts.component'
|
import { AccountsComponent } from './accounts.component'
|
||||||
|
import { UserSubscriptionService } from '@app/shared/shared-user-subscription'
|
||||||
|
import { BlocklistService, VideoBlockService } from '@app/shared/shared-moderation'
|
||||||
|
import { VideoPlaylistService } from '@app/shared/shared-video-playlist'
|
||||||
|
|
||||||
const accountsRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: 'peertube',
|
path: 'peertube',
|
||||||
redirectTo: '/videos/local'
|
redirectTo: '/videos/local'
|
||||||
@ -12,6 +14,12 @@ const accountsRoutes: Routes = [
|
|||||||
{
|
{
|
||||||
path: ':accountId',
|
path: ':accountId',
|
||||||
component: AccountsComponent,
|
component: AccountsComponent,
|
||||||
|
providers: [
|
||||||
|
UserSubscriptionService,
|
||||||
|
BlocklistService,
|
||||||
|
VideoPlaylistService,
|
||||||
|
VideoBlockService
|
||||||
|
],
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
@ -48,10 +56,4 @@ const accountsRoutes: Routes = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(accountsRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class AccountsRoutingModule {}
|
|
@ -1,36 +0,0 @@
|
|||||||
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 { AdminComponent } from './admin.component'
|
|
||||||
import { FollowsRoutes } from './follows'
|
|
||||||
import { OverviewRoutes } from './overview'
|
|
||||||
|
|
||||||
const adminRoutes: Routes = [
|
|
||||||
{
|
|
||||||
path: '',
|
|
||||||
component: AdminComponent,
|
|
||||||
children: [
|
|
||||||
{
|
|
||||||
path: '',
|
|
||||||
redirectTo: 'users',
|
|
||||||
pathMatch: 'full'
|
|
||||||
},
|
|
||||||
|
|
||||||
...FollowsRoutes,
|
|
||||||
...OverviewRoutes,
|
|
||||||
...ModerationRoutes,
|
|
||||||
...SystemRoutes,
|
|
||||||
...ConfigRoutes,
|
|
||||||
...PluginsRoutes
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(adminRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class AdminRoutingModule {}
|
|
@ -3,10 +3,15 @@ import { AuthService, ScreenService, ServerService } from '@app/core'
|
|||||||
import { ListOverflowItem } from '@app/shared/shared-main'
|
import { ListOverflowItem } from '@app/shared/shared-main'
|
||||||
import { TopMenuDropdownParam } from '@app/shared/shared-main/misc/top-menu-dropdown.component'
|
import { TopMenuDropdownParam } from '@app/shared/shared-main/misc/top-menu-dropdown.component'
|
||||||
import { UserRight } from '@peertube/peertube-models'
|
import { UserRight } from '@peertube/peertube-models'
|
||||||
|
import { RouterOutlet } from '@angular/router'
|
||||||
|
import { NgClass } from '@angular/common'
|
||||||
|
import { TopMenuDropdownComponent } from '../shared/shared-main/misc/top-menu-dropdown.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './admin.component.html',
|
templateUrl: './admin.component.html',
|
||||||
styleUrls: [ './admin.component.scss' ]
|
styleUrls: [ './admin.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ TopMenuDropdownComponent, NgClass, RouterOutlet ]
|
||||||
})
|
})
|
||||||
export class AdminComponent implements OnInit {
|
export class AdminComponent implements OnInit {
|
||||||
items: ListOverflowItem[] = []
|
items: ListOverflowItem[] = []
|
||||||
|
@ -1,159 +0,0 @@
|
|||||||
import { ChartModule } from 'primeng/chart'
|
|
||||||
import { TableModule } from 'primeng/table'
|
|
||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { SharedAbuseListModule } from '@app/shared/shared-abuse-list'
|
|
||||||
import { SharedActorImageEditModule } from '@app/shared/shared-actor-image-edit'
|
|
||||||
import { SharedActorImageModule } from '@app/shared/shared-actor-image/shared-actor-image.module'
|
|
||||||
import { SharedCustomMarkupModule } from '@app/shared/shared-custom-markup'
|
|
||||||
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 { SharedTablesModule } from '@app/shared/shared-tables'
|
|
||||||
import { SharedUsersModule } from '@app/shared/shared-users'
|
|
||||||
import { SharedVideoCommentModule } from '@app/shared/shared-video-comment'
|
|
||||||
import { SharedVideoMiniatureModule } from '@app/shared/shared-video-miniature'
|
|
||||||
import { AdminRoutingModule } from './admin-routing.module'
|
|
||||||
import { AdminComponent } from './admin.component'
|
|
||||||
import {
|
|
||||||
EditAdvancedConfigurationComponent,
|
|
||||||
EditBasicConfigurationComponent,
|
|
||||||
EditConfigurationService,
|
|
||||||
EditCustomConfigComponent,
|
|
||||||
EditHomepageComponent,
|
|
||||||
EditInstanceInformationComponent,
|
|
||||||
EditLiveConfigurationComponent,
|
|
||||||
EditVODTranscodingComponent
|
|
||||||
} from './config'
|
|
||||||
import { ConfigService } from './config/shared/config.service'
|
|
||||||
import { FollowersListComponent, FollowModalComponent, VideoRedundanciesListComponent } from './follows'
|
|
||||||
import { FollowingListComponent } from './follows/following-list/following-list.component'
|
|
||||||
import { RedundancyCheckboxComponent } from './follows/shared/redundancy-checkbox.component'
|
|
||||||
import { VideoRedundancyInformationComponent } from './follows/video-redundancies-list/video-redundancy-information.component'
|
|
||||||
import {
|
|
||||||
AbuseListComponent,
|
|
||||||
AdminRegistrationService,
|
|
||||||
ProcessRegistrationModalComponent,
|
|
||||||
RegistrationListComponent,
|
|
||||||
VideoBlockListComponent
|
|
||||||
} from './moderation'
|
|
||||||
import { InstanceAccountBlocklistComponent, InstanceServerBlocklistComponent } from './moderation/instance-blocklist'
|
|
||||||
import {
|
|
||||||
UserCreateComponent,
|
|
||||||
UserListComponent,
|
|
||||||
UserPasswordComponent,
|
|
||||||
UserUpdateComponent,
|
|
||||||
VideoAdminService,
|
|
||||||
VideoCommentListComponent,
|
|
||||||
VideoListComponent
|
|
||||||
} from './overview'
|
|
||||||
import {
|
|
||||||
PluginApiService,
|
|
||||||
PluginCardComponent,
|
|
||||||
PluginListInstalledComponent,
|
|
||||||
PluginNavigationComponent,
|
|
||||||
PluginSearchComponent,
|
|
||||||
PluginShowInstalledComponent
|
|
||||||
} from './plugins'
|
|
||||||
import { SharedAdminModule } from './shared'
|
|
||||||
import {
|
|
||||||
JobService,
|
|
||||||
LogsComponent,
|
|
||||||
LogsService,
|
|
||||||
RunnerJobListComponent,
|
|
||||||
RunnerListComponent,
|
|
||||||
RunnerRegistrationTokenListComponent,
|
|
||||||
RunnerService
|
|
||||||
} from './system'
|
|
||||||
import { DebugComponent, DebugService } from './system/debug'
|
|
||||||
import { JobsComponent } from './system/jobs'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
AdminRoutingModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedModerationModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedAbuseListModule,
|
|
||||||
SharedVideoCommentModule,
|
|
||||||
SharedActorImageModule,
|
|
||||||
SharedActorImageEditModule,
|
|
||||||
SharedCustomMarkupModule,
|
|
||||||
SharedVideoMiniatureModule,
|
|
||||||
SharedTablesModule,
|
|
||||||
SharedUsersModule,
|
|
||||||
SharedAdminModule,
|
|
||||||
|
|
||||||
TableModule,
|
|
||||||
ChartModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
AdminComponent,
|
|
||||||
|
|
||||||
VideoListComponent,
|
|
||||||
|
|
||||||
FollowersListComponent,
|
|
||||||
FollowingListComponent,
|
|
||||||
FollowModalComponent,
|
|
||||||
RedundancyCheckboxComponent,
|
|
||||||
VideoRedundanciesListComponent,
|
|
||||||
VideoRedundancyInformationComponent,
|
|
||||||
|
|
||||||
UserCreateComponent,
|
|
||||||
UserUpdateComponent,
|
|
||||||
UserPasswordComponent,
|
|
||||||
UserListComponent,
|
|
||||||
|
|
||||||
VideoBlockListComponent,
|
|
||||||
AbuseListComponent,
|
|
||||||
VideoCommentListComponent,
|
|
||||||
|
|
||||||
InstanceServerBlocklistComponent,
|
|
||||||
InstanceAccountBlocklistComponent,
|
|
||||||
|
|
||||||
PluginListInstalledComponent,
|
|
||||||
PluginSearchComponent,
|
|
||||||
PluginShowInstalledComponent,
|
|
||||||
PluginCardComponent,
|
|
||||||
PluginNavigationComponent,
|
|
||||||
|
|
||||||
JobsComponent,
|
|
||||||
LogsComponent,
|
|
||||||
DebugComponent,
|
|
||||||
|
|
||||||
EditCustomConfigComponent,
|
|
||||||
EditBasicConfigurationComponent,
|
|
||||||
EditVODTranscodingComponent,
|
|
||||||
EditLiveConfigurationComponent,
|
|
||||||
EditAdvancedConfigurationComponent,
|
|
||||||
EditInstanceInformationComponent,
|
|
||||||
EditHomepageComponent,
|
|
||||||
|
|
||||||
RegistrationListComponent,
|
|
||||||
ProcessRegistrationModalComponent,
|
|
||||||
|
|
||||||
RunnerRegistrationTokenListComponent,
|
|
||||||
RunnerListComponent,
|
|
||||||
RunnerJobListComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
AdminComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: [
|
|
||||||
JobService,
|
|
||||||
LogsService,
|
|
||||||
DebugService,
|
|
||||||
ConfigService,
|
|
||||||
PluginApiService,
|
|
||||||
EditConfigurationService,
|
|
||||||
VideoAdminService,
|
|
||||||
AdminRegistrationService,
|
|
||||||
RunnerService
|
|
||||||
]
|
|
||||||
})
|
|
||||||
export class AdminModule { }
|
|
@ -1,10 +1,15 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { HelpComponent } from '../../../shared/shared-main/misc/help.component'
|
||||||
|
import { NgClass, NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-advanced-configuration',
|
selector: 'my-edit-advanced-configuration',
|
||||||
templateUrl: './edit-advanced-configuration.component.html',
|
templateUrl: './edit-advanced-configuration.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ FormsModule, ReactiveFormsModule, NgClass, NgIf, HelpComponent, PeerTubeTemplateDirective ]
|
||||||
})
|
})
|
||||||
export class EditAdvancedConfigurationComponent {
|
export class EditAdvancedConfigurationComponent {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -90,7 +90,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- broadcast grid -->
|
<div class="pt-two-cols mt-4"> <!-- broadcast grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>BROADCAST MESSAGE</h2>
|
<h2 i18n>BROADCAST MESSAGE</h2>
|
||||||
<div i18n class="inner-form-description">
|
<div i18n class="inner-form-description">
|
||||||
@ -146,7 +146,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- new users grid -->
|
<div class="pt-two-cols mt-4"> <!-- new users grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>NEW USERS</h2>
|
<h2 i18n>NEW USERS</h2>
|
||||||
<div i18n class="inner-form-description">
|
<div i18n class="inner-form-description">
|
||||||
@ -263,7 +263,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- videos grid -->
|
<div class="pt-two-cols mt-4"> <!-- videos grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>VIDEOS</h2>
|
<h2 i18n>VIDEOS</h2>
|
||||||
</div>
|
</div>
|
||||||
@ -375,7 +375,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- video channels grid -->
|
<div class="pt-two-cols mt-4"> <!-- video channels grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>VIDEO CHANNELS</h2>
|
<h2 i18n>VIDEO CHANNELS</h2>
|
||||||
</div>
|
</div>
|
||||||
@ -397,7 +397,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- search grid -->
|
<div class="pt-two-cols mt-4"> <!-- search grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>SEARCH</h2>
|
<h2 i18n>SEARCH</h2>
|
||||||
</div>
|
</div>
|
||||||
@ -486,7 +486,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- import/export grid -->
|
<div class="pt-two-cols mt-4"> <!-- import/export grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>USER IMPORT/EXPORT</h2>
|
<h2 i18n>USER IMPORT/EXPORT</h2>
|
||||||
</div>
|
</div>
|
||||||
@ -562,7 +562,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- federation grid -->
|
<div class="pt-two-cols mt-4"> <!-- federation grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>FEDERATION</h2>
|
<h2 i18n>FEDERATION</h2>
|
||||||
<div i18n class="inner-form-description">
|
<div i18n class="inner-form-description">
|
||||||
@ -641,7 +641,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- administrators grid -->
|
<div class="pt-two-cols mt-4"> <!-- administrators grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>ADMINISTRATORS</h2>
|
<h2 i18n>ADMINISTRATORS</h2>
|
||||||
</div>
|
</div>
|
||||||
@ -669,7 +669,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row mt-4"> <!-- Twitter grid -->
|
<div class="pt-two-cols mt-4"> <!-- Twitter grid -->
|
||||||
<div class="title-col">
|
<div class="title-col">
|
||||||
<h2 i18n>TWITTER</h2>
|
<h2 i18n>TWITTER</h2>
|
||||||
<div i18n class="inner-form-description">
|
<div i18n class="inner-form-description">
|
||||||
|
@ -1,15 +1,40 @@
|
|||||||
import { pairwise } from 'rxjs/operators'
|
import { pairwise } from 'rxjs/operators'
|
||||||
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
||||||
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { MenuService, ThemeService } from '@app/core'
|
import { MenuService, ThemeService } from '@app/core'
|
||||||
import { HTMLServerConfig } from '@peertube/peertube-models'
|
import { HTMLServerConfig } from '@peertube/peertube-models'
|
||||||
import { ConfigService } from '../shared/config.service'
|
import { ConfigService } from '../shared/config.service'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { SelectOptionsComponent } from '../../../shared/shared-forms/select/select-options.component'
|
||||||
|
import { UserRealQuotaInfoComponent } from '../../shared/user-real-quota-info.component'
|
||||||
|
import { MarkdownTextareaComponent } from '../../../shared/shared-forms/markdown-textarea.component'
|
||||||
|
import { HelpComponent } from '../../../shared/shared-main/misc/help.component'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { SelectCustomValueComponent } from '../../../shared/shared-forms/select/select-custom-value.component'
|
||||||
|
import { NgFor, NgIf, NgClass } from '@angular/common'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-basic-configuration',
|
selector: 'my-edit-basic-configuration',
|
||||||
templateUrl: './edit-basic-configuration.component.html',
|
templateUrl: './edit-basic-configuration.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
RouterLink,
|
||||||
|
NgFor,
|
||||||
|
SelectCustomValueComponent,
|
||||||
|
NgIf,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
HelpComponent,
|
||||||
|
MarkdownTextareaComponent,
|
||||||
|
NgClass,
|
||||||
|
UserRealQuotaInfoComponent,
|
||||||
|
SelectOptionsComponent,
|
||||||
|
PeerTubeTemplateDirective
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class EditBasicConfigurationComponent implements OnInit, OnChanges {
|
export class EditBasicConfigurationComponent implements OnInit, OnChanges {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -30,6 +30,15 @@ import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
|||||||
import { CustomPageService } from '@app/shared/shared-main/custom-page'
|
import { CustomPageService } from '@app/shared/shared-main/custom-page'
|
||||||
import { CustomConfig, CustomPage, HTMLServerConfig } from '@peertube/peertube-models'
|
import { CustomConfig, CustomPage, HTMLServerConfig } from '@peertube/peertube-models'
|
||||||
import { EditConfigurationService } from './edit-configuration.service'
|
import { EditConfigurationService } from './edit-configuration.service'
|
||||||
|
import { EditAdvancedConfigurationComponent } from './edit-advanced-configuration.component'
|
||||||
|
import { EditLiveConfigurationComponent } from './edit-live-configuration.component'
|
||||||
|
import { EditVODTranscodingComponent } from './edit-vod-transcoding.component'
|
||||||
|
import { EditBasicConfigurationComponent } from './edit-basic-configuration.component'
|
||||||
|
import { EditInstanceInformationComponent } from './edit-instance-information.component'
|
||||||
|
import { EditHomepageComponent } from './edit-homepage.component'
|
||||||
|
import { NgbNav, NgbNavItem, NgbNavLink, NgbNavLinkBase, NgbNavContent, NgbNavOutlet } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
|
||||||
type ComponentCustomConfig = CustomConfig & {
|
type ComponentCustomConfig = CustomConfig & {
|
||||||
instanceCustomHomepage: CustomPage
|
instanceCustomHomepage: CustomPage
|
||||||
@ -38,7 +47,26 @@ type ComponentCustomConfig = CustomConfig & {
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-custom-config',
|
selector: 'my-edit-custom-config',
|
||||||
templateUrl: './edit-custom-config.component.html',
|
templateUrl: './edit-custom-config.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
NgbNav,
|
||||||
|
NgbNavItem,
|
||||||
|
NgbNavLink,
|
||||||
|
NgbNavLinkBase,
|
||||||
|
NgbNavContent,
|
||||||
|
EditHomepageComponent,
|
||||||
|
EditInstanceInformationComponent,
|
||||||
|
EditBasicConfigurationComponent,
|
||||||
|
EditVODTranscodingComponent,
|
||||||
|
EditLiveConfigurationComponent,
|
||||||
|
EditAdvancedConfigurationComponent,
|
||||||
|
NgbNavOutlet,
|
||||||
|
NgFor
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class EditCustomConfigComponent extends FormReactive implements OnInit {
|
export class EditCustomConfigComponent extends FormReactive implements OnInit {
|
||||||
activeNav: string
|
activeNav: string
|
||||||
|
@ -1,11 +1,16 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
import { MarkdownTextareaComponent } from '../../../shared/shared-forms/markdown-textarea.component'
|
||||||
|
import { CustomMarkupHelpComponent } from '../../../shared/shared-custom-markup/custom-markup-help.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-homepage',
|
selector: 'my-edit-homepage',
|
||||||
templateUrl: './edit-homepage.component.html',
|
templateUrl: './edit-homepage.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ FormsModule, ReactiveFormsModule, CustomMarkupHelpComponent, MarkdownTextareaComponent, NgIf ]
|
||||||
})
|
})
|
||||||
export class EditHomepageComponent {
|
export class EditHomepageComponent {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -1,17 +1,43 @@
|
|||||||
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
||||||
import { Component, Input, OnInit } from '@angular/core'
|
import { Component, Input, OnInit } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
import { CustomMarkupService } from '@app/shared/shared-custom-markup'
|
||||||
import { Notifier, ServerService } from '@app/core'
|
import { Notifier, ServerService } from '@app/core'
|
||||||
import { HttpErrorResponse } from '@angular/common/http'
|
import { HttpErrorResponse } from '@angular/common/http'
|
||||||
import { genericUploadErrorHandler } from '@app/helpers'
|
import { genericUploadErrorHandler } from '@app/helpers'
|
||||||
import { InstanceService } from '@app/shared/shared-instance'
|
import { InstanceService } from '@app/shared/shared-main'
|
||||||
import { ActorImage, HTMLServerConfig } from '@peertube/peertube-models'
|
import { ActorImage, HTMLServerConfig } from '@peertube/peertube-models'
|
||||||
|
import { HelpComponent } from '../../../shared/shared-main/misc/help.component'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { SelectCheckboxComponent } from '../../../shared/shared-forms/select/select-checkbox.component'
|
||||||
|
import { MarkdownTextareaComponent } from '../../../shared/shared-forms/markdown-textarea.component'
|
||||||
|
import { CustomMarkupHelpComponent } from '../../../shared/shared-custom-markup/custom-markup-help.component'
|
||||||
|
import { NgClass, NgIf } from '@angular/common'
|
||||||
|
import { ActorBannerEditComponent } from '../../../shared/shared-actor-image-edit/actor-banner-edit.component'
|
||||||
|
import { ActorAvatarEditComponent } from '../../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-instance-information',
|
selector: 'my-edit-instance-information',
|
||||||
templateUrl: './edit-instance-information.component.html',
|
templateUrl: './edit-instance-information.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
ActorBannerEditComponent,
|
||||||
|
NgClass,
|
||||||
|
NgIf,
|
||||||
|
CustomMarkupHelpComponent,
|
||||||
|
MarkdownTextareaComponent,
|
||||||
|
SelectCheckboxComponent,
|
||||||
|
RouterLink,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
PeerTubeTemplateDirective,
|
||||||
|
HelpComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class EditInstanceInformationComponent implements OnInit {
|
export class EditInstanceInformationComponent implements OnInit {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -1,14 +1,33 @@
|
|||||||
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
||||||
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { HTMLServerConfig } from '@peertube/peertube-models'
|
import { HTMLServerConfig } from '@peertube/peertube-models'
|
||||||
import { ConfigService } from '../shared/config.service'
|
import { ConfigService } from '../shared/config.service'
|
||||||
import { EditConfigurationService, ResolutionOption } from './edit-configuration.service'
|
import { EditConfigurationService, ResolutionOption } from './edit-configuration.service'
|
||||||
|
import { SelectCustomValueComponent } from '../../../shared/shared-forms/select/select-custom-value.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { SelectOptionsComponent } from '../../../shared/shared-forms/select/select-options.component'
|
||||||
|
import { NgClass, NgIf, NgFor } from '@angular/common'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-live-configuration',
|
selector: 'my-edit-live-configuration',
|
||||||
templateUrl: './edit-live-configuration.component.html',
|
templateUrl: './edit-live-configuration.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
PeerTubeTemplateDirective,
|
||||||
|
NgClass,
|
||||||
|
NgIf,
|
||||||
|
SelectOptionsComponent,
|
||||||
|
NgFor,
|
||||||
|
RouterLink,
|
||||||
|
SelectCustomValueComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class EditLiveConfigurationComponent implements OnInit, OnChanges {
|
export class EditLiveConfigurationComponent implements OnInit, OnChanges {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -1,14 +1,33 @@
|
|||||||
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
import { SelectOptionsItem } from 'src/types/select-options-item.model'
|
||||||
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { HTMLServerConfig } from '@peertube/peertube-models'
|
import { HTMLServerConfig } from '@peertube/peertube-models'
|
||||||
import { ConfigService } from '../shared/config.service'
|
import { ConfigService } from '../shared/config.service'
|
||||||
import { EditConfigurationService, ResolutionOption } from './edit-configuration.service'
|
import { EditConfigurationService, ResolutionOption } from './edit-configuration.service'
|
||||||
|
import { SelectOptionsComponent } from '../../../shared/shared-forms/select/select-options.component'
|
||||||
|
import { SelectCustomValueComponent } from '../../../shared/shared-forms/select/select-custom-value.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { NgClass, NgFor, NgIf } from '@angular/common'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-edit-vod-transcoding',
|
selector: 'my-edit-vod-transcoding',
|
||||||
templateUrl: './edit-vod-transcoding.component.html',
|
templateUrl: './edit-vod-transcoding.component.html',
|
||||||
styleUrls: [ './edit-custom-config.component.scss' ]
|
styleUrls: [ './edit-custom-config.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
PeerTubeTemplateDirective,
|
||||||
|
NgClass,
|
||||||
|
NgFor,
|
||||||
|
NgIf,
|
||||||
|
RouterLink,
|
||||||
|
SelectCustomValueComponent,
|
||||||
|
SelectOptionsComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class EditVODTranscodingComponent implements OnInit, OnChanges {
|
export class EditVODTranscodingComponent implements OnInit, OnChanges {
|
||||||
@Input() form: FormGroup
|
@Input() form: FormGroup
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { formatICU } from '@app/helpers'
|
import { formatICU } from '@app/helpers'
|
||||||
@ -6,11 +6,34 @@ import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
|||||||
import { InstanceFollowService } from '@app/shared/shared-instance'
|
import { InstanceFollowService } from '@app/shared/shared-instance'
|
||||||
import { DropdownAction } from '@app/shared/shared-main'
|
import { DropdownAction } from '@app/shared/shared-main'
|
||||||
import { ActorFollow } from '@peertube/peertube-models'
|
import { ActorFollow } from '@peertube/peertube-models'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { DeleteButtonComponent } from '../../../shared/shared-main/buttons/delete-button.component'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-followers-list',
|
selector: 'my-followers-list',
|
||||||
templateUrl: './followers-list.component.html',
|
templateUrl: './followers-list.component.html',
|
||||||
styleUrls: [ './followers-list.component.scss' ]
|
styleUrls: [ './followers-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
ButtonComponent,
|
||||||
|
DeleteButtonComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class FollowersListComponent extends RestTable <ActorFollow> implements OnInit {
|
export class FollowersListComponent extends RestTable <ActorFollow> implements OnInit {
|
||||||
followers: ActorFollow[] = []
|
followers: ActorFollow[] = []
|
||||||
|
@ -6,11 +6,16 @@ import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
|||||||
import { InstanceFollowService } from '@app/shared/shared-instance'
|
import { InstanceFollowService } from '@app/shared/shared-instance'
|
||||||
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
|
import { NgbModal } from '@ng-bootstrap/ng-bootstrap'
|
||||||
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
|
import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
|
||||||
|
import { NgClass, NgIf } from '@angular/common'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-follow-modal',
|
selector: 'my-follow-modal',
|
||||||
templateUrl: './follow-modal.component.html',
|
templateUrl: './follow-modal.component.html',
|
||||||
styleUrls: [ './follow-modal.component.scss' ]
|
styleUrls: [ './follow-modal.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, FormsModule, ReactiveFormsModule, NgClass, NgIf ]
|
||||||
})
|
})
|
||||||
export class FollowModalComponent extends FormReactive implements OnInit {
|
export class FollowModalComponent extends FormReactive implements OnInit {
|
||||||
@ViewChild('modal', { static: true }) modal: NgbModal
|
@ViewChild('modal', { static: true }) modal: NgbModal
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit, ViewChild } from '@angular/core'
|
import { Component, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
||||||
@ -7,10 +7,32 @@ import { ActorFollow } from '@peertube/peertube-models'
|
|||||||
import { FollowModalComponent } from './follow-modal.component'
|
import { FollowModalComponent } from './follow-modal.component'
|
||||||
import { DropdownAction } from '@app/shared/shared-main'
|
import { DropdownAction } from '@app/shared/shared-main'
|
||||||
import { formatICU } from '@app/helpers'
|
import { formatICU } from '@app/helpers'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { RedundancyCheckboxComponent } from '../shared/redundancy-checkbox.component'
|
||||||
|
import { DeleteButtonComponent } from '../../../shared/shared-main/buttons/delete-button.component'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './following-list.component.html',
|
templateUrl: './following-list.component.html',
|
||||||
styleUrls: [ './following-list.component.scss' ]
|
styleUrls: [ './following-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
DeleteButtonComponent,
|
||||||
|
RedundancyCheckboxComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
FollowModalComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class FollowingListComponent extends RestTable <ActorFollow> implements OnInit {
|
export class FollowingListComponent extends RestTable <ActorFollow> implements OnInit {
|
||||||
@ViewChild('followModal') followModal: FollowModalComponent
|
@ViewChild('followModal') followModal: FollowModalComponent
|
||||||
|
@ -1,10 +1,14 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { Notifier } from '@app/core'
|
import { Notifier } from '@app/core'
|
||||||
import { RedundancyService } from '@app/shared/shared-main'
|
import { RedundancyService } from '@app/shared/shared-main'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-redundancy-checkbox',
|
selector: 'my-redundancy-checkbox',
|
||||||
templateUrl: './redundancy-checkbox.component.html'
|
templateUrl: './redundancy-checkbox.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ PeertubeCheckboxComponent, FormsModule ]
|
||||||
})
|
})
|
||||||
export class RedundancyCheckboxComponent {
|
export class RedundancyCheckboxComponent {
|
||||||
@Input() redundancyAllowed: boolean
|
@Input() redundancyAllowed: boolean
|
||||||
|
@ -1,15 +1,41 @@
|
|||||||
import { ChartData, ChartOptions, TooltipItem } from 'chart.js'
|
import { ChartData, ChartOptions, TooltipItem } from 'chart.js'
|
||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
||||||
import { BytesPipe, RedundancyService } from '@app/shared/shared-main'
|
import { BytesPipe, RedundancyService } from '@app/shared/shared-main'
|
||||||
import { VideoRedundanciesTarget, VideoRedundancy, VideosRedundancyStats } from '@peertube/peertube-models'
|
import { VideoRedundanciesTarget, VideoRedundancy, VideosRedundancyStats } from '@peertube/peertube-models'
|
||||||
import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
|
import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
|
||||||
|
import { ChartModule } from 'primeng/chart'
|
||||||
|
import { VideoRedundancyInformationComponent } from './video-redundancy-information.component'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { DeleteButtonComponent } from '../../../shared/shared-main/buttons/delete-button.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-redundancies-list',
|
selector: 'my-video-redundancies-list',
|
||||||
templateUrl: './video-redundancies-list.component.html',
|
templateUrl: './video-redundancies-list.component.html',
|
||||||
styleUrls: [ './video-redundancies-list.component.scss' ]
|
styleUrls: [ './video-redundancies-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
FormsModule,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
NgbTooltip,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
DeleteButtonComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgFor,
|
||||||
|
VideoRedundancyInformationComponent,
|
||||||
|
ChartModule,
|
||||||
|
BytesPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoRedundanciesListComponent extends RestTable implements OnInit {
|
export class VideoRedundanciesListComponent extends RestTable implements OnInit {
|
||||||
private static LOCAL_STORAGE_DISPLAY_TYPE = 'video-redundancies-list-display-type'
|
private static LOCAL_STORAGE_DISPLAY_TYPE = 'video-redundancies-list-display-type'
|
||||||
|
@ -1,10 +1,14 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { FileRedundancyInformation, StreamingPlaylistRedundancyInformation } from '@peertube/peertube-models'
|
import { FileRedundancyInformation, StreamingPlaylistRedundancyInformation } from '@peertube/peertube-models'
|
||||||
|
import { BytesPipe } from '../../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { DatePipe } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-redundancy-information',
|
selector: 'my-video-redundancy-information',
|
||||||
templateUrl: './video-redundancy-information.component.html',
|
templateUrl: './video-redundancy-information.component.html',
|
||||||
styleUrls: [ './video-redundancy-information.component.scss' ]
|
styleUrls: [ './video-redundancy-information.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ DatePipe, BytesPipe ]
|
||||||
})
|
})
|
||||||
export class VideoRedundancyInformationComponent {
|
export class VideoRedundancyInformationComponent {
|
||||||
@Input() redundancyElement: FileRedundancyInformation | StreamingPlaylistRedundancyInformation
|
@Input() redundancyElement: FileRedundancyInformation | StreamingPlaylistRedundancyInformation
|
||||||
|
@ -1,9 +1,13 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
|
import { AbuseListTableComponent } from '../../../shared/shared-abuse-list/abuse-list-table.component'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-abuse-list',
|
selector: 'my-abuse-list',
|
||||||
templateUrl: './abuse-list.component.html',
|
templateUrl: './abuse-list.component.html',
|
||||||
styleUrls: [ ]
|
styleUrls: [],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, AbuseListTableComponent ]
|
||||||
})
|
})
|
||||||
export class AbuseListComponent {
|
export class AbuseListComponent {
|
||||||
|
|
||||||
|
@ -1,10 +1,30 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
|
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { ActorAvatarComponent } from '../../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { SharedModule } from 'primeng/api'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-instance-account-blocklist',
|
selector: 'my-instance-account-blocklist',
|
||||||
styleUrls: [ '../../../shared/shared-moderation/moderation.scss' ],
|
styleUrls: [ '../../../shared/shared-moderation/moderation.scss' ],
|
||||||
templateUrl: '../../../shared/shared-moderation/account-blocklist.component.html'
|
templateUrl: '../../../shared/shared-moderation/account-blocklist.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgIf,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class InstanceAccountBlocklistComponent extends GenericAccountBlocklistComponent {
|
export class InstanceAccountBlocklistComponent extends GenericAccountBlocklistComponent {
|
||||||
mode = BlocklistComponentType.Instance
|
mode = BlocklistComponentType.Instance
|
||||||
|
@ -1,10 +1,30 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
import { GenericServerBlocklistComponent, BlocklistComponentType } from '@app/shared/shared-moderation'
|
import { GenericServerBlocklistComponent, BlocklistComponentType } from '@app/shared/shared-moderation'
|
||||||
|
import { BatchDomainsModalComponent } from '../../../shared/shared-moderation/batch-domains-modal.component'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { SharedModule } from 'primeng/api'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-instance-server-blocklist',
|
selector: 'my-instance-server-blocklist',
|
||||||
styleUrls: [ '../../../shared/shared-moderation/server-blocklist.component.scss' ],
|
styleUrls: [ '../../../shared/shared-moderation/server-blocklist.component.scss' ],
|
||||||
templateUrl: '../../../shared/shared-moderation/server-blocklist.component.html'
|
templateUrl: '../../../shared/shared-moderation/server-blocklist.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgIf,
|
||||||
|
BatchDomainsModalComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class InstanceServerBlocklistComponent extends GenericServerBlocklistComponent {
|
export class InstanceServerBlocklistComponent extends GenericServerBlocklistComponent {
|
||||||
mode = BlocklistComponentType.Instance
|
mode = BlocklistComponentType.Instance
|
||||||
|
@ -6,10 +6,16 @@ import { NgbModalRef } from '@ng-bootstrap/ng-bootstrap/modal/modal-ref'
|
|||||||
import { UserRegistration } from '@peertube/peertube-models'
|
import { UserRegistration } from '@peertube/peertube-models'
|
||||||
import { AdminRegistrationService } from './admin-registration.service'
|
import { AdminRegistrationService } from './admin-registration.service'
|
||||||
import { REGISTRATION_MODERATION_RESPONSE_VALIDATOR } from './process-registration-validators'
|
import { REGISTRATION_MODERATION_RESPONSE_VALIDATOR } from './process-registration-validators'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-process-registration-modal',
|
selector: 'my-process-registration-modal',
|
||||||
templateUrl: './process-registration-modal.component.html'
|
templateUrl: './process-registration-modal.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, GlobalIconComponent, FormsModule, ReactiveFormsModule, NgClass, PeertubeCheckboxComponent ]
|
||||||
})
|
})
|
||||||
export class ProcessRegistrationModalComponent extends FormReactive implements OnInit {
|
export class ProcessRegistrationModalComponent extends FormReactive implements OnInit {
|
||||||
@ViewChild('modal', { static: true }) modal: NgbModal
|
@ViewChild('modal', { static: true }) modal: NgbModal
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit, ViewChild } from '@angular/core'
|
import { Component, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router } from '@angular/router'
|
||||||
import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
||||||
@ -8,11 +8,36 @@ import { DropdownAction } from '@app/shared/shared-main'
|
|||||||
import { UserRegistration, UserRegistrationState } from '@peertube/peertube-models'
|
import { UserRegistration, UserRegistrationState } from '@peertube/peertube-models'
|
||||||
import { AdminRegistrationService } from './admin-registration.service'
|
import { AdminRegistrationService } from './admin-registration.service'
|
||||||
import { ProcessRegistrationModalComponent } from './process-registration-modal.component'
|
import { ProcessRegistrationModalComponent } from './process-registration-modal.component'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { UserEmailInfoComponent } from '../../shared/user-email-info.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-registration-list',
|
selector: 'my-registration-list',
|
||||||
templateUrl: './registration-list.component.html',
|
templateUrl: './registration-list.component.html',
|
||||||
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './registration-list.component.scss' ]
|
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './registration-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
NgClass,
|
||||||
|
UserEmailInfoComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
ProcessRegistrationModalComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class RegistrationListComponent extends RestTable <UserRegistration> implements OnInit {
|
export class RegistrationListComponent extends RestTable <UserRegistration> implements OnInit {
|
||||||
@ViewChild('processRegistrationModal', { static: true }) processRegistrationModal: ProcessRegistrationModalComponent
|
@ViewChild('processRegistrationModal', { static: true }) processRegistrationModal: ProcessRegistrationModalComponent
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { switchMap } from 'rxjs/operators'
|
import { switchMap } from 'rxjs/operators'
|
||||||
import { environment } from 'src/environments/environment'
|
import { environment } from 'src/environments/environment'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
@ -10,11 +10,37 @@ import { VideoBlockService } from '@app/shared/shared-moderation'
|
|||||||
import { buildVideoEmbedLink, decorateVideoLink } from '@peertube/peertube-core-utils'
|
import { buildVideoEmbedLink, decorateVideoLink } from '@peertube/peertube-core-utils'
|
||||||
import { VideoBlacklist, VideoBlacklistType, VideoBlacklistType_Type } from '@peertube/peertube-models'
|
import { VideoBlacklist, VideoBlacklistType, VideoBlacklistType_Type } from '@peertube/peertube-models'
|
||||||
import { buildVideoOrPlaylistEmbed } from '@root-helpers/video'
|
import { buildVideoOrPlaylistEmbed } from '@root-helpers/video'
|
||||||
|
import { EmbedComponent } from '../../../shared/shared-main/video/embed.component'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { VideoCellComponent } from '../../../shared/shared-tables/video-cell.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-block-list',
|
selector: 'my-video-block-list',
|
||||||
templateUrl: './video-block-list.component.html',
|
templateUrl: './video-block-list.component.html',
|
||||||
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './video-block-list.component.scss' ]
|
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './video-block-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
NgIf,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
NgClass,
|
||||||
|
VideoCellComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
EmbedComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoBlockListComponent extends RestTable implements OnInit {
|
export class VideoBlockListComponent extends RestTable implements OnInit {
|
||||||
blocklist: (VideoBlacklist & { reasonHtml?: string })[] = []
|
blocklist: (VideoBlacklist & { reasonHtml?: string })[] = []
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router } from '@angular/router'
|
||||||
import { AuthService, ConfirmService, MarkdownService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { AuthService, ConfirmService, MarkdownService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
@ -8,11 +8,39 @@ import { BulkService } from '@app/shared/shared-moderation'
|
|||||||
import { VideoCommentAdmin, VideoCommentService } from '@app/shared/shared-video-comment'
|
import { VideoCommentAdmin, VideoCommentService } from '@app/shared/shared-video-comment'
|
||||||
import { FeedFormat, UserRight } from '@peertube/peertube-models'
|
import { FeedFormat, UserRight } from '@peertube/peertube-models'
|
||||||
import { formatICU } from '@app/helpers'
|
import { formatICU } from '@app/helpers'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { ActorAvatarComponent } from '../../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { FeedComponent } from '../../../shared/shared-main/feeds/feed.component'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-comment-list',
|
selector: 'my-video-comment-list',
|
||||||
templateUrl: './video-comment-list.component.html',
|
templateUrl: './video-comment-list.component.html',
|
||||||
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './video-comment-list.component.scss' ]
|
styleUrls: [ '../../../shared/shared-moderation/moderation.scss', './video-comment-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
FeedComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
ButtonComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
NgClass,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoCommentListComponent extends RestTable <VideoCommentAdmin> implements OnInit {
|
export class VideoCommentListComponent extends RestTable <VideoCommentAdmin> implements OnInit {
|
||||||
comments: VideoCommentAdmin[]
|
comments: VideoCommentAdmin[]
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { Router } from '@angular/router'
|
import { Router, RouterLink } from '@angular/router'
|
||||||
import { ConfigService } from '@app/+admin/config/shared/config.service'
|
import { ConfigService } from '@app/+admin/config/shared/config.service'
|
||||||
import { AuthService, Notifier, ScreenService, ServerService } from '@app/core'
|
import { AuthService, Notifier, ScreenService, ServerService } from '@app/core'
|
||||||
import {
|
import {
|
||||||
@ -16,11 +16,41 @@ import { FormReactiveService } from '@app/shared/shared-forms'
|
|||||||
import { UserAdminService } from '@app/shared/shared-users'
|
import { UserAdminService } from '@app/shared/shared-users'
|
||||||
import { UserCreate, UserRole } from '@peertube/peertube-models'
|
import { UserCreate, UserRole } from '@peertube/peertube-models'
|
||||||
import { UserEdit } from './user-edit'
|
import { UserEdit } from './user-edit'
|
||||||
|
import { BytesPipe } from '../../../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { UserPasswordComponent } from './user-password.component'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { UserRealQuotaInfoComponent } from '../../../shared/user-real-quota-info.component'
|
||||||
|
import { SelectCustomValueComponent } from '../../../../shared/shared-forms/select/select-custom-value.component'
|
||||||
|
import { InputTextComponent } from '../../../../shared/shared-forms/input-text.component'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { HelpComponent } from '../../../../shared/shared-main/misc/help.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { ActorAvatarEditComponent } from '../../../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
import { NgIf, NgTemplateOutlet, NgClass, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-create',
|
selector: 'my-user-create',
|
||||||
templateUrl: './user-edit.component.html',
|
templateUrl: './user-edit.component.html',
|
||||||
styleUrls: [ './user-edit.component.scss' ]
|
styleUrls: [ './user-edit.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
RouterLink,
|
||||||
|
NgIf,
|
||||||
|
NgTemplateOutlet,
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
NgClass,
|
||||||
|
HelpComponent,
|
||||||
|
PeerTubeTemplateDirective,
|
||||||
|
InputTextComponent,
|
||||||
|
NgFor,
|
||||||
|
SelectCustomValueComponent,
|
||||||
|
UserRealQuotaInfoComponent,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
UserPasswordComponent,
|
||||||
|
BytesPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class UserCreateComponent extends UserEdit implements OnInit {
|
export class UserCreateComponent extends UserEdit implements OnInit {
|
||||||
error: string
|
error: string
|
||||||
|
@ -4,11 +4,15 @@ import { USER_PASSWORD_VALIDATOR } from '@app/shared/form-validators/user-valida
|
|||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { UserAdminService } from '@app/shared/shared-users'
|
import { UserAdminService } from '@app/shared/shared-users'
|
||||||
import { UserUpdate } from '@peertube/peertube-models'
|
import { UserUpdate } from '@peertube/peertube-models'
|
||||||
|
import { NgClass, NgIf } from '@angular/common'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-password',
|
selector: 'my-user-password',
|
||||||
templateUrl: './user-password.component.html',
|
templateUrl: './user-password.component.html',
|
||||||
styleUrls: [ './user-password.component.scss' ]
|
styleUrls: [ './user-password.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ FormsModule, ReactiveFormsModule, NgClass, NgIf ]
|
||||||
})
|
})
|
||||||
export class UserPasswordComponent extends FormReactive implements OnInit {
|
export class UserPasswordComponent extends FormReactive implements OnInit {
|
||||||
@Input() userId: number
|
@Input() userId: number
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { Subscription } from 'rxjs'
|
import { Subscription } from 'rxjs'
|
||||||
import { Component, OnDestroy, OnInit } from '@angular/core'
|
import { Component, OnDestroy, OnInit } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router, RouterLink } from '@angular/router'
|
||||||
import { ConfigService } from '@app/+admin/config/shared/config.service'
|
import { ConfigService } from '@app/+admin/config/shared/config.service'
|
||||||
import { AuthService, Notifier, ScreenService, ServerService, User, UserService } from '@app/core'
|
import { AuthService, Notifier, ScreenService, ServerService, User, UserService } from '@app/core'
|
||||||
import {
|
import {
|
||||||
@ -13,11 +13,41 @@ import { FormReactiveService } from '@app/shared/shared-forms'
|
|||||||
import { TwoFactorService, UserAdminService } from '@app/shared/shared-users'
|
import { TwoFactorService, UserAdminService } from '@app/shared/shared-users'
|
||||||
import { User as UserType, UserAdminFlag, UserRole, UserUpdate } from '@peertube/peertube-models'
|
import { User as UserType, UserAdminFlag, UserRole, UserUpdate } from '@peertube/peertube-models'
|
||||||
import { UserEdit } from './user-edit'
|
import { UserEdit } from './user-edit'
|
||||||
|
import { BytesPipe } from '../../../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { UserPasswordComponent } from './user-password.component'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { UserRealQuotaInfoComponent } from '../../../shared/user-real-quota-info.component'
|
||||||
|
import { SelectCustomValueComponent } from '../../../../shared/shared-forms/select/select-custom-value.component'
|
||||||
|
import { InputTextComponent } from '../../../../shared/shared-forms/input-text.component'
|
||||||
|
import { PeerTubeTemplateDirective } from '../../../../shared/shared-main/angular/peertube-template.directive'
|
||||||
|
import { HelpComponent } from '../../../../shared/shared-main/misc/help.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { ActorAvatarEditComponent } from '../../../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
import { NgIf, NgTemplateOutlet, NgClass, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-update',
|
selector: 'my-user-update',
|
||||||
templateUrl: './user-edit.component.html',
|
templateUrl: './user-edit.component.html',
|
||||||
styleUrls: [ './user-edit.component.scss' ]
|
styleUrls: [ './user-edit.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
RouterLink,
|
||||||
|
NgIf,
|
||||||
|
NgTemplateOutlet,
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
NgClass,
|
||||||
|
HelpComponent,
|
||||||
|
PeerTubeTemplateDirective,
|
||||||
|
InputTextComponent,
|
||||||
|
NgFor,
|
||||||
|
SelectCustomValueComponent,
|
||||||
|
UserRealQuotaInfoComponent,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
UserPasswordComponent,
|
||||||
|
BytesPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class UserUpdateComponent extends UserEdit implements OnInit, OnDestroy {
|
export class UserUpdateComponent extends UserEdit implements OnInit, OnDestroy {
|
||||||
error: string
|
error: string
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit, ViewChild } from '@angular/core'
|
import { Component, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router, RouterLink } from '@angular/router'
|
||||||
import { AuthService, ConfirmService, LocalStorageService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
import { AuthService, ConfirmService, LocalStorageService, Notifier, RestPagination, RestTable, ServerService } from '@app/core'
|
||||||
import { formatICU, getAPIHost } from '@app/helpers'
|
import { formatICU, getAPIHost } from '@app/helpers'
|
||||||
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
||||||
@ -9,6 +9,21 @@ import { AccountMutedStatus, BlocklistService, UserBanModalComponent, UserModera
|
|||||||
import { UserAdminService } from '@app/shared/shared-users'
|
import { UserAdminService } from '@app/shared/shared-users'
|
||||||
import { User, UserRole, UserRoleType } from '@peertube/peertube-models'
|
import { User, UserRole, UserRoleType } from '@peertube/peertube-models'
|
||||||
import { logger } from '@root-helpers/logger'
|
import { logger } from '@root-helpers/logger'
|
||||||
|
import { BytesPipe } from '../../../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { AutoColspanDirective } from '../../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { UserEmailInfoComponent } from '../../../shared/user-email-info.component'
|
||||||
|
import { ActorAvatarComponent } from '../../../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { UserModerationDropdownComponent } from '../../../../shared/shared-moderation/user-moderation-dropdown.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { SelectCheckboxComponent } from '../../../../shared/shared-forms/select/select-checkbox.component'
|
||||||
|
import { NgbDropdown, NgbDropdownToggle, NgbDropdownMenu, NgbDropdownItem, NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
type UserForList = User & {
|
type UserForList = User & {
|
||||||
rawVideoQuota: number
|
rawVideoQuota: number
|
||||||
@ -20,7 +35,34 @@ type UserForList = User & {
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-list',
|
selector: 'my-user-list',
|
||||||
templateUrl: './user-list.component.html',
|
templateUrl: './user-list.component.html',
|
||||||
styleUrls: [ './user-list.component.scss' ]
|
styleUrls: [ './user-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
RouterLink,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbDropdown,
|
||||||
|
NgbDropdownToggle,
|
||||||
|
NgbDropdownMenu,
|
||||||
|
NgbDropdownItem,
|
||||||
|
SelectCheckboxComponent,
|
||||||
|
FormsModule,
|
||||||
|
PeertubeCheckboxComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
NgClass,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
UserModerationDropdownComponent,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
UserEmailInfoComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
UserBanModalComponent,
|
||||||
|
DatePipe,
|
||||||
|
BytesPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class UserListComponent extends RestTable <User> implements OnInit {
|
export class UserListComponent extends RestTable <User> implements OnInit {
|
||||||
private static readonly LOCAL_STORAGE_SELECTED_COLUMNS_KEY = 'admin-user-list-selected-columns'
|
private static readonly LOCAL_STORAGE_SELECTED_COLUMNS_KEY = 'admin-user-list-selected-columns'
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { finalize } from 'rxjs/operators'
|
import { finalize } from 'rxjs/operators'
|
||||||
import { Component, OnInit, ViewChild } from '@angular/core'
|
import { Component, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router } from '@angular/router'
|
||||||
@ -11,11 +11,45 @@ import { VideoActionsDisplayType } from '@app/shared/shared-video-miniature'
|
|||||||
import { getAllFiles } from '@peertube/peertube-core-utils'
|
import { getAllFiles } from '@peertube/peertube-core-utils'
|
||||||
import { UserRight, VideoFile, VideoPrivacy, VideoState, VideoStreamingPlaylistType } from '@peertube/peertube-models'
|
import { UserRight, VideoFile, VideoPrivacy, VideoState, VideoStreamingPlaylistType } from '@peertube/peertube-models'
|
||||||
import { VideoAdminService } from './video-admin.service'
|
import { VideoAdminService } from './video-admin.service'
|
||||||
|
import { BytesPipe } from '../../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { EmbedComponent } from '../../../shared/shared-main/video/embed.component'
|
||||||
|
import { AutoColspanDirective } from '../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { VideoCellComponent } from '../../../shared/shared-tables/video-cell.component'
|
||||||
|
import { VideoActionsDropdownComponent } from '../../../shared/shared-video-miniature/video-actions-dropdown.component'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgClass, NgIf, NgFor, DatePipe } from '@angular/common'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-list',
|
selector: 'my-video-list',
|
||||||
templateUrl: './video-list.component.html',
|
templateUrl: './video-list.component.html',
|
||||||
styleUrls: [ './video-list.component.scss' ]
|
styleUrls: [ './video-list.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
NgClass,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
ButtonComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
VideoActionsDropdownComponent,
|
||||||
|
VideoCellComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgFor,
|
||||||
|
EmbedComponent,
|
||||||
|
VideoBlockComponent,
|
||||||
|
DatePipe,
|
||||||
|
BytesPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoListComponent extends RestTable <Video> implements OnInit {
|
export class VideoListComponent extends RestTable <Video> implements OnInit {
|
||||||
@ViewChild('videoBlockModal') videoBlockModal: VideoBlockComponent
|
@ViewChild('videoBlockModal') videoBlockModal: VideoBlockComponent
|
||||||
|
@ -6,11 +6,29 @@ import { ComponentPagination, ConfirmService, hasMoreItems, Notifier } from '@ap
|
|||||||
import { PluginService } from '@app/core/plugins/plugin.service'
|
import { PluginService } from '@app/core/plugins/plugin.service'
|
||||||
import { compareSemVer } from '@peertube/peertube-core-utils'
|
import { compareSemVer } from '@peertube/peertube-core-utils'
|
||||||
import { PeerTubePlugin, PluginType, PluginType_Type } from '@peertube/peertube-models'
|
import { PeerTubePlugin, PluginType, PluginType_Type } from '@peertube/peertube-models'
|
||||||
|
import { DeleteButtonComponent } from '../../../shared/shared-main/buttons/delete-button.component'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { EditButtonComponent } from '../../../shared/shared-main/buttons/edit-button.component'
|
||||||
|
import { PluginCardComponent } from '../shared/plugin-card.component'
|
||||||
|
import { InfiniteScrollerDirective } from '../../../shared/shared-main/angular/infinite-scroller.directive'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
import { PluginNavigationComponent } from '../shared/plugin-navigation.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-plugin-list-installed',
|
selector: 'my-plugin-list-installed',
|
||||||
templateUrl: './plugin-list-installed.component.html',
|
templateUrl: './plugin-list-installed.component.html',
|
||||||
styleUrls: [ './plugin-list-installed.component.scss' ]
|
styleUrls: [ './plugin-list-installed.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
PluginNavigationComponent,
|
||||||
|
NgIf,
|
||||||
|
InfiniteScrollerDirective,
|
||||||
|
NgFor,
|
||||||
|
PluginCardComponent,
|
||||||
|
EditButtonComponent,
|
||||||
|
ButtonComponent,
|
||||||
|
DeleteButtonComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class PluginListInstalledComponent implements OnInit {
|
export class PluginListInstalledComponent implements OnInit {
|
||||||
pluginType: PluginType_Type
|
pluginType: PluginType_Type
|
||||||
|
@ -6,11 +6,31 @@ import { PluginApiService } from '@app/+admin/plugins/shared/plugin-api.service'
|
|||||||
import { ComponentPagination, ConfirmService, hasMoreItems, Notifier, PluginService } from '@app/core'
|
import { ComponentPagination, ConfirmService, hasMoreItems, Notifier, PluginService } from '@app/core'
|
||||||
import { PeerTubePluginIndex, PluginType, PluginType_Type } from '@peertube/peertube-models'
|
import { PeerTubePluginIndex, PluginType, PluginType_Type } from '@peertube/peertube-models'
|
||||||
import { logger } from '@root-helpers/logger'
|
import { logger } from '@root-helpers/logger'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { EditButtonComponent } from '../../../shared/shared-main/buttons/edit-button.component'
|
||||||
|
import { PluginCardComponent } from '../shared/plugin-card.component'
|
||||||
|
import { InfiniteScrollerDirective } from '../../../shared/shared-main/angular/infinite-scroller.directive'
|
||||||
|
import { AutofocusDirective } from '../../../shared/shared-main/angular/autofocus.directive'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
import { PluginNavigationComponent } from '../shared/plugin-navigation.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-plugin-search',
|
selector: 'my-plugin-search',
|
||||||
templateUrl: './plugin-search.component.html',
|
templateUrl: './plugin-search.component.html',
|
||||||
styleUrls: [ './plugin-search.component.scss' ]
|
styleUrls: [ './plugin-search.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
PluginNavigationComponent,
|
||||||
|
NgIf,
|
||||||
|
GlobalIconComponent,
|
||||||
|
AutofocusDirective,
|
||||||
|
InfiniteScrollerDirective,
|
||||||
|
NgFor,
|
||||||
|
PluginCardComponent,
|
||||||
|
EditButtonComponent,
|
||||||
|
ButtonComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class PluginSearchComponent implements OnInit {
|
export class PluginSearchComponent implements OnInit {
|
||||||
pluginType: PluginType_Type
|
pluginType: PluginType_Type
|
||||||
|
@ -7,11 +7,16 @@ import { BuildFormArgument } from '@app/shared/form-validators'
|
|||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { PeerTubePlugin, RegisterServerSettingOptions } from '@peertube/peertube-models'
|
import { PeerTubePlugin, RegisterServerSettingOptions } from '@peertube/peertube-models'
|
||||||
import { PluginApiService } from '../shared/plugin-api.service'
|
import { PluginApiService } from '../shared/plugin-api.service'
|
||||||
|
import { DynamicFormFieldComponent } from '../../../shared/shared-forms/dynamic-form-field.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-plugin-show-installed',
|
selector: 'my-plugin-show-installed',
|
||||||
templateUrl: './plugin-show-installed.component.html',
|
templateUrl: './plugin-show-installed.component.html',
|
||||||
styleUrls: [ './plugin-show-installed.component.scss' ]
|
styleUrls: [ './plugin-show-installed.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, FormsModule, ReactiveFormsModule, NgFor, DynamicFormFieldComponent ]
|
||||||
})
|
})
|
||||||
export class PluginShowInstalledComponent extends FormReactive implements OnInit, OnDestroy {
|
export class PluginShowInstalledComponent extends FormReactive implements OnInit, OnDestroy {
|
||||||
plugin: PeerTubePlugin
|
plugin: PeerTubePlugin
|
||||||
|
@ -1,11 +1,14 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { PeerTubePlugin, PeerTubePluginIndex, PluginType_Type } from '@peertube/peertube-models'
|
import { PeerTubePlugin, PeerTubePluginIndex, PluginType_Type } from '@peertube/peertube-models'
|
||||||
import { PluginApiService } from './plugin-api.service'
|
import { PluginApiService } from './plugin-api.service'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-plugin-card',
|
selector: 'my-plugin-card',
|
||||||
templateUrl: './plugin-card.component.html',
|
templateUrl: './plugin-card.component.html',
|
||||||
styleUrls: [ './plugin-card.component.scss' ]
|
styleUrls: [ './plugin-card.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent ]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class PluginCardComponent {
|
export class PluginCardComponent {
|
||||||
|
@ -1,10 +1,14 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { PluginType_Type } from '@peertube/peertube-models'
|
import { PluginType_Type } from '@peertube/peertube-models'
|
||||||
|
import { NgClass } from '@angular/common'
|
||||||
|
import { RouterLink, RouterLinkActive } from '@angular/router'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-plugin-navigation',
|
selector: 'my-plugin-navigation',
|
||||||
templateUrl: './plugin-navigation.component.html',
|
templateUrl: './plugin-navigation.component.html',
|
||||||
styleUrls: [ './plugin-navigation.component.scss' ]
|
styleUrls: [ './plugin-navigation.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ RouterLink, RouterLinkActive, NgClass ]
|
||||||
})
|
})
|
||||||
export class PluginNavigationComponent {
|
export class PluginNavigationComponent {
|
||||||
@Input() pluginType: PluginType_Type
|
@Input() pluginType: PluginType_Type
|
||||||
|
66
client/src/app/+admin/routes.ts
Normal file
66
client/src/app/+admin/routes.ts
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
import { Routes } from '@angular/router'
|
||||||
|
import { ConfigRoutes, EditConfigurationService } from '@app/+admin/config'
|
||||||
|
import { ModerationRoutes } from '@app/+admin/moderation/moderation.routes'
|
||||||
|
import { PluginsRoutes } from '@app/+admin/plugins/plugins.routes'
|
||||||
|
import { DebugService, JobService, LogsService, RunnerService, SystemRoutes } from '@app/+admin/system'
|
||||||
|
import { AdminComponent } from './admin.component'
|
||||||
|
import { FollowsRoutes } from './follows'
|
||||||
|
import { OverviewRoutes, VideoAdminService } from './overview'
|
||||||
|
import { TwoFactorService, UserAdminService } from '@app/shared/shared-users'
|
||||||
|
import { AbuseService, BlocklistService, BulkService, VideoBlockService } from '@app/shared/shared-moderation'
|
||||||
|
import { CustomMarkupService, DynamicElementService } from '@app/shared/shared-custom-markup'
|
||||||
|
import { InstanceFollowService } from '@app/shared/shared-instance'
|
||||||
|
import { CustomPageService } from '@app/shared/shared-main/custom-page'
|
||||||
|
import { VideoCommentService } from '@app/shared/shared-video-comment'
|
||||||
|
import { AdminRegistrationService } from './moderation/registration-list'
|
||||||
|
import { PluginApiService } from './plugins/shared/plugin-api.service'
|
||||||
|
import { ConfigService } from './config/shared/config.service'
|
||||||
|
import { FindInBulkService, SearchService } from '@app/shared/shared-search'
|
||||||
|
import { VideoPlaylistService } from '@app/shared/shared-video-playlist'
|
||||||
|
|
||||||
|
export default [
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: AdminComponent,
|
||||||
|
providers: [
|
||||||
|
BlocklistService,
|
||||||
|
UserAdminService,
|
||||||
|
BulkService,
|
||||||
|
AdminRegistrationService,
|
||||||
|
CustomMarkupService,
|
||||||
|
CustomPageService,
|
||||||
|
DebugService,
|
||||||
|
EditConfigurationService,
|
||||||
|
InstanceFollowService,
|
||||||
|
JobService,
|
||||||
|
LogsService,
|
||||||
|
PluginApiService,
|
||||||
|
RunnerService,
|
||||||
|
TwoFactorService,
|
||||||
|
UserAdminService,
|
||||||
|
VideoAdminService,
|
||||||
|
VideoBlockService,
|
||||||
|
VideoCommentService,
|
||||||
|
ConfigService,
|
||||||
|
AbuseService,
|
||||||
|
DynamicElementService,
|
||||||
|
FindInBulkService,
|
||||||
|
SearchService,
|
||||||
|
VideoPlaylistService
|
||||||
|
],
|
||||||
|
children: [
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
redirectTo: 'users',
|
||||||
|
pathMatch: 'full'
|
||||||
|
},
|
||||||
|
|
||||||
|
...FollowsRoutes,
|
||||||
|
...OverviewRoutes,
|
||||||
|
...ModerationRoutes,
|
||||||
|
...SystemRoutes,
|
||||||
|
...ConfigRoutes,
|
||||||
|
...PluginsRoutes
|
||||||
|
]
|
||||||
|
}
|
||||||
|
] satisfies Routes
|
@ -1,3 +1,2 @@
|
|||||||
|
export * from './user-email-info.component'
|
||||||
export * from './user-real-quota-info.component'
|
export * from './user-real-quota-info.component'
|
||||||
|
|
||||||
export * from './shared-admin.module'
|
|
||||||
|
@ -1,23 +0,0 @@
|
|||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { SharedMainModule } from '../../shared/shared-main/shared-main.module'
|
|
||||||
import { UserEmailInfoComponent } from './user-email-info.component'
|
|
||||||
import { UserRealQuotaInfoComponent } from './user-real-quota-info.component'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
SharedMainModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
UserRealQuotaInfoComponent,
|
|
||||||
UserEmailInfoComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
UserRealQuotaInfoComponent,
|
|
||||||
UserEmailInfoComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: []
|
|
||||||
})
|
|
||||||
export class SharedAdminModule { }
|
|
@ -1,10 +1,13 @@
|
|||||||
import { Component, Input } from '@angular/core'
|
import { Component, Input } from '@angular/core'
|
||||||
import { User, UserRegistration } from '@peertube/peertube-models'
|
import { User, UserRegistration } from '@peertube/peertube-models'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-email-info',
|
selector: 'my-user-email-info',
|
||||||
templateUrl: './user-email-info.component.html',
|
templateUrl: './user-email-info.component.html',
|
||||||
styleUrls: [ './user-email-info.component.scss' ]
|
styleUrls: [ './user-email-info.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf ]
|
||||||
})
|
})
|
||||||
export class UserEmailInfoComponent {
|
export class UserEmailInfoComponent {
|
||||||
@Input() entry: User | UserRegistration
|
@Input() entry: User | UserRegistration
|
||||||
|
@ -1,10 +1,14 @@
|
|||||||
import { Component, Input, OnInit } from '@angular/core'
|
import { Component, Input, OnInit } from '@angular/core'
|
||||||
import { ServerService } from '@app/core'
|
import { ServerService } from '@app/core'
|
||||||
import { HTMLServerConfig, VideoResolution } from '@peertube/peertube-models'
|
import { HTMLServerConfig, VideoResolution } from '@peertube/peertube-models'
|
||||||
|
import { BytesPipe } from '../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-user-real-quota-info',
|
selector: 'my-user-real-quota-info',
|
||||||
templateUrl: './user-real-quota-info.component.html'
|
templateUrl: './user-real-quota-info.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, BytesPipe ]
|
||||||
})
|
})
|
||||||
export class UserRealQuotaInfoComponent implements OnInit {
|
export class UserRealQuotaInfoComponent implements OnInit {
|
||||||
@Input() videoQuota: number | string
|
@Input() videoQuota: number | string
|
||||||
|
@ -5,7 +5,8 @@ import { DebugService } from './debug.service'
|
|||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './debug.component.html',
|
templateUrl: './debug.component.html',
|
||||||
styleUrls: [ './debug.component.scss' ]
|
styleUrls: [ './debug.component.scss' ],
|
||||||
|
standalone: true
|
||||||
})
|
})
|
||||||
export class DebugComponent implements OnInit {
|
export class DebugComponent implements OnInit {
|
||||||
debug: Debug
|
debug: Debug
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { Notifier, RestPagination, RestTable } from '@app/core'
|
import { Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { escapeHTML } from '@peertube/peertube-core-utils'
|
import { escapeHTML } from '@peertube/peertube-core-utils'
|
||||||
@ -7,11 +7,31 @@ import { peertubeLocalStorage } from '@root-helpers/peertube-web-storage'
|
|||||||
import { JobStateClient } from '../../../../types/job-state-client.type'
|
import { JobStateClient } from '../../../../types/job-state-client.type'
|
||||||
import { JobTypeClient } from '../../../../types/job-type-client.type'
|
import { JobTypeClient } from '../../../../types/job-type-client.type'
|
||||||
import { JobService } from './job.service'
|
import { JobService } from './job.service'
|
||||||
|
import { TableExpanderIconComponent } from '../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { NgSelectModule } from '@ng-select/ng-select'
|
||||||
|
import { NgFor, NgClass, NgIf } from '@angular/common'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-jobs',
|
selector: 'my-jobs',
|
||||||
templateUrl: './jobs.component.html',
|
templateUrl: './jobs.component.html',
|
||||||
styleUrls: [ './jobs.component.scss' ]
|
styleUrls: [ './jobs.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
FormsModule,
|
||||||
|
NgFor,
|
||||||
|
NgSelectModule,
|
||||||
|
NgClass,
|
||||||
|
ButtonComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgIf,
|
||||||
|
NgbTooltip,
|
||||||
|
TableExpanderIconComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class JobsComponent extends RestTable implements OnInit {
|
export class JobsComponent extends RestTable implements OnInit {
|
||||||
private static LOCAL_STORAGE_STATE = 'jobs-list-state'
|
private static LOCAL_STORAGE_STATE = 'jobs-list-state'
|
||||||
|
@ -3,10 +3,17 @@ import { LocalStorageService, Notifier } from '@app/core'
|
|||||||
import { ServerLogLevel } from '@peertube/peertube-models'
|
import { ServerLogLevel } from '@peertube/peertube-models'
|
||||||
import { LogRow } from './log-row.model'
|
import { LogRow } from './log-row.model'
|
||||||
import { LogsService } from './logs.service'
|
import { LogsService } from './logs.service'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { SelectTagsComponent } from '../../../shared/shared-forms/select/select-tags.component'
|
||||||
|
import { NgSelectModule } from '@ng-select/ng-select'
|
||||||
|
import { NgFor, NgIf, NgClass, DatePipe } from '@angular/common'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './logs.component.html',
|
templateUrl: './logs.component.html',
|
||||||
styleUrls: [ './logs.component.scss' ]
|
styleUrls: [ './logs.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ FormsModule, NgFor, NgSelectModule, NgIf, NgClass, SelectTagsComponent, ButtonComponent, DatePipe ]
|
||||||
})
|
})
|
||||||
export class LogsComponent implements OnInit {
|
export class LogsComponent implements OnInit {
|
||||||
private static LOCAL_STORAGE_LOG_TYPE_CHOICE_KEY = 'admin-logs-log-type-choice'
|
private static LOCAL_STORAGE_LOG_TYPE_CHOICE_KEY = 'admin-logs-log-type-choice'
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { formatICU } from '@app/helpers'
|
import { formatICU } from '@app/helpers'
|
||||||
@ -6,10 +6,35 @@ import { DropdownAction } from '@app/shared/shared-main'
|
|||||||
import { RunnerJob, RunnerJobState } from '@peertube/peertube-models'
|
import { RunnerJob, RunnerJobState } from '@peertube/peertube-models'
|
||||||
import { RunnerJobFormatted, RunnerService } from '../runner.service'
|
import { RunnerJobFormatted, RunnerService } from '../runner.service'
|
||||||
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
import { AdvancedInputFilter } from '@app/shared/shared-forms'
|
||||||
|
import { AutoColspanDirective } from '../../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { TableExpanderIconComponent } from '../../../../shared/shared-tables/table-expander-icon.component'
|
||||||
|
import { ButtonComponent } from '../../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { GlobalIconComponent } from '../../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-runner-job-list',
|
selector: 'my-runner-job-list',
|
||||||
templateUrl: './runner-job-list.component.html'
|
templateUrl: './runner-job-list.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
RouterLink,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgbTooltip,
|
||||||
|
NgIf,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
ButtonComponent,
|
||||||
|
TableExpanderIconComponent,
|
||||||
|
NgClass,
|
||||||
|
AutoColspanDirective
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class RunnerJobListComponent extends RestTable <RunnerJob> implements OnInit {
|
export class RunnerJobListComponent extends RestTable <RunnerJob> implements OnInit {
|
||||||
runnerJobs: RunnerJobFormatted[] = []
|
runnerJobs: RunnerJobFormatted[] = []
|
||||||
|
@ -1,13 +1,31 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { DropdownAction } from '@app/shared/shared-main'
|
import { DropdownAction } from '@app/shared/shared-main'
|
||||||
import { Runner } from '@peertube/peertube-models'
|
import { Runner } from '@peertube/peertube-models'
|
||||||
import { RunnerService } from '../runner.service'
|
import { RunnerService } from '../runner.service'
|
||||||
|
import { DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { ActionDropdownComponent } from '../../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { GlobalIconComponent } from '../../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-runner-list',
|
selector: 'my-runner-list',
|
||||||
templateUrl: './runner-list.component.html'
|
templateUrl: './runner-list.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
RouterLink,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgbTooltip,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class RunnerListComponent extends RestTable <Runner> implements OnInit {
|
export class RunnerListComponent extends RestTable <Runner> implements OnInit {
|
||||||
runners: Runner[] = []
|
runners: Runner[] = []
|
||||||
|
@ -1,14 +1,36 @@
|
|||||||
import { SortMeta } from 'primeng/api'
|
import { SortMeta, SharedModule } from 'primeng/api'
|
||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
import { ConfirmService, Notifier, RestPagination, RestTable } from '@app/core'
|
||||||
import { DropdownAction } from '@app/shared/shared-main'
|
import { DropdownAction } from '@app/shared/shared-main'
|
||||||
import { RunnerRegistrationToken } from '@peertube/peertube-models'
|
import { RunnerRegistrationToken } from '@peertube/peertube-models'
|
||||||
import { RunnerService } from '../runner.service'
|
import { RunnerService } from '../runner.service'
|
||||||
|
import { DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { CopyButtonComponent } from '../../../../shared/shared-main/buttons/copy-button.component'
|
||||||
|
import { ActionDropdownComponent } from '../../../../shared/shared-main/buttons/action-dropdown.component'
|
||||||
|
import { ButtonComponent } from '../../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { GlobalIconComponent } from '../../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-runner-registration-token-list',
|
selector: 'my-runner-registration-token-list',
|
||||||
styleUrls: [ './runner-registration-token-list.component.scss' ],
|
styleUrls: [ './runner-registration-token-list.component.scss' ],
|
||||||
templateUrl: './runner-registration-token-list.component.html'
|
templateUrl: './runner-registration-token-list.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
RouterLink,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
NgbTooltip,
|
||||||
|
ButtonComponent,
|
||||||
|
ActionDropdownComponent,
|
||||||
|
CopyButtonComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class RunnerRegistrationTokenListComponent extends RestTable <RunnerRegistrationToken> implements OnInit {
|
export class RunnerRegistrationTokenListComponent extends RestTable <RunnerRegistrationToken> implements OnInit {
|
||||||
registrationTokens: RunnerRegistrationToken[] = []
|
registrationTokens: RunnerRegistrationToken[] = []
|
||||||
|
@ -2,11 +2,15 @@ import { Component, OnInit } from '@angular/core'
|
|||||||
import { Title } from '@angular/platform-browser'
|
import { Title } from '@angular/platform-browser'
|
||||||
import { Router } from '@angular/router'
|
import { Router } from '@angular/router'
|
||||||
import { HttpStatusCode, HttpStatusCodeType } from '@peertube/peertube-models'
|
import { HttpStatusCode, HttpStatusCodeType } from '@peertube/peertube-models'
|
||||||
|
import { LoginLinkComponent } from '../shared/shared-main/angular/login-link.component'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-error-page',
|
selector: 'my-error-page',
|
||||||
templateUrl: './error-page.component.html',
|
templateUrl: './error-page.component.html',
|
||||||
styleUrls: [ './error-page.component.scss' ]
|
styleUrls: [ './error-page.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, LoginLinkComponent ]
|
||||||
})
|
})
|
||||||
export class ErrorPageComponent implements OnInit {
|
export class ErrorPageComponent implements OnInit {
|
||||||
status: HttpStatusCodeType = HttpStatusCode.NOT_FOUND_404
|
status: HttpStatusCodeType = HttpStatusCode.NOT_FOUND_404
|
||||||
|
@ -1,25 +0,0 @@
|
|||||||
import { CommonModule } from '@angular/common'
|
|
||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { SharedMainModule } from '@app/shared/shared-main'
|
|
||||||
import { ErrorPageRoutingModule } from './error-page-routing.module'
|
|
||||||
import { ErrorPageComponent } from './error-page.component'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
CommonModule,
|
|
||||||
SharedMainModule,
|
|
||||||
|
|
||||||
ErrorPageRoutingModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
ErrorPageComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
ErrorPageComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: []
|
|
||||||
})
|
|
||||||
export class ErrorPageModule { }
|
|
@ -1,9 +1,8 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { ErrorPageComponent } from './error-page.component'
|
import { ErrorPageComponent } from './error-page.component'
|
||||||
import { MenuGuards } from '@app/core'
|
import { MenuGuards } from '@app/core'
|
||||||
|
|
||||||
const errorPageRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
component: ErrorPageComponent,
|
component: ErrorPageComponent,
|
||||||
@ -15,10 +14,4 @@ const errorPageRoutes: Routes = [
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(errorPageRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class ErrorPageRoutingModule {}
|
|
@ -1,21 +0,0 @@
|
|||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { HomeComponent } from './home.component'
|
|
||||||
|
|
||||||
const homeRoutes: Routes = [
|
|
||||||
{
|
|
||||||
path: '',
|
|
||||||
component: HomeComponent,
|
|
||||||
data: {
|
|
||||||
meta: {
|
|
||||||
title: $localize`Homepage`
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(homeRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class HomeRoutingModule {}
|
|
@ -1,9 +1,12 @@
|
|||||||
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
import { Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
||||||
import { CustomPageService } from '@app/shared/shared-main/custom-page'
|
import { CustomPageService } from '@app/shared/shared-main/custom-page'
|
||||||
|
import { CustomMarkupContainerComponent } from '../shared/shared-custom-markup/custom-markup-container.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './home.component.html',
|
templateUrl: './home.component.html',
|
||||||
styleUrls: [ './home.component.scss' ]
|
styleUrls: [ './home.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ CustomMarkupContainerComponent ]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class HomeComponent implements OnInit {
|
export class HomeComponent implements OnInit {
|
||||||
|
@ -1,25 +0,0 @@
|
|||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { SharedCustomMarkupModule } from '@app/shared/shared-custom-markup'
|
|
||||||
import { SharedMainModule } from '@app/shared/shared-main'
|
|
||||||
import { HomeRoutingModule } from './home-routing.module'
|
|
||||||
import { HomeComponent } from './home.component'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
HomeRoutingModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedCustomMarkupModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
HomeComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
HomeComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: [ ]
|
|
||||||
})
|
|
||||||
export class HomeModule { }
|
|
@ -1,3 +0,0 @@
|
|||||||
export * from './home-routing.module'
|
|
||||||
export * from './home.component'
|
|
||||||
export * from './home.module'
|
|
29
client/src/app/+home/routes.ts
Normal file
29
client/src/app/+home/routes.ts
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
import { Routes } from '@angular/router'
|
||||||
|
import { HomeComponent } from './home.component'
|
||||||
|
import { CustomPageService } from '../shared/shared-main/custom-page'
|
||||||
|
import { CustomMarkupService, DynamicElementService } from '@app/shared/shared-custom-markup'
|
||||||
|
import { FindInBulkService, SearchService } from '@app/shared/shared-search'
|
||||||
|
import { VideoPlaylistService } from '@app/shared/shared-video-playlist'
|
||||||
|
import { BlocklistService, VideoBlockService } from '@app/shared/shared-moderation'
|
||||||
|
|
||||||
|
export default [
|
||||||
|
{
|
||||||
|
path: '',
|
||||||
|
component: HomeComponent,
|
||||||
|
providers: [
|
||||||
|
CustomPageService,
|
||||||
|
FindInBulkService,
|
||||||
|
SearchService,
|
||||||
|
VideoPlaylistService,
|
||||||
|
CustomMarkupService,
|
||||||
|
DynamicElementService,
|
||||||
|
BlocklistService,
|
||||||
|
VideoBlockService
|
||||||
|
],
|
||||||
|
data: {
|
||||||
|
meta: {
|
||||||
|
title: $localize`Homepage`
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
] satisfies Routes
|
@ -1,6 +1,6 @@
|
|||||||
import { environment } from 'src/environments/environment'
|
import { environment } from 'src/environments/environment'
|
||||||
import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core'
|
||||||
import { ActivatedRoute, Router } from '@angular/router'
|
import { ActivatedRoute, Router, RouterLink } from '@angular/router'
|
||||||
import { AuthService, Notifier, RedirectService, SessionStorageService, UserService } from '@app/core'
|
import { AuthService, Notifier, RedirectService, SessionStorageService, UserService } from '@app/core'
|
||||||
import { HooksService } from '@app/core/plugins/hooks.service'
|
import { HooksService } from '@app/core/plugins/hooks.service'
|
||||||
import { LOGIN_PASSWORD_VALIDATOR, LOGIN_USERNAME_VALIDATOR } from '@app/shared/form-validators/login-validators'
|
import { LOGIN_PASSWORD_VALIDATOR, LOGIN_USERNAME_VALIDATOR } from '@app/shared/form-validators/login-validators'
|
||||||
@ -10,11 +10,33 @@ import { InstanceAboutAccordionComponent } from '@app/shared/shared-instance'
|
|||||||
import { NgbAccordionDirective, NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
|
import { NgbAccordionDirective, NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
|
||||||
import { getExternalAuthHref } from '@peertube/peertube-core-utils'
|
import { getExternalAuthHref } from '@peertube/peertube-core-utils'
|
||||||
import { RegisteredExternalAuthConfig, ServerConfig, ServerErrorCode } from '@peertube/peertube-models'
|
import { RegisteredExternalAuthConfig, ServerConfig, ServerErrorCode } from '@peertube/peertube-models'
|
||||||
|
import { GlobalIconComponent } from '../shared/shared-icons/global-icon.component'
|
||||||
|
import { InstanceBannerComponent } from '../shared/shared-instance/instance-banner.component'
|
||||||
|
import { AutofocusDirective } from '../shared/shared-main/angular/autofocus.directive'
|
||||||
|
import { PluginSelectorDirective } from '../shared/shared-main/plugins/plugin-selector.directive'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass, NgTemplateOutlet, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-login',
|
selector: 'my-login',
|
||||||
templateUrl: './login.component.html',
|
templateUrl: './login.component.html',
|
||||||
styleUrls: [ './login.component.scss' ]
|
styleUrls: [ './login.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
RouterLink,
|
||||||
|
FormsModule,
|
||||||
|
PluginSelectorDirective,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
AutofocusDirective,
|
||||||
|
NgClass,
|
||||||
|
NgTemplateOutlet,
|
||||||
|
InputTextComponent,
|
||||||
|
NgFor,
|
||||||
|
InstanceBannerComponent,
|
||||||
|
InstanceAboutAccordionComponent,
|
||||||
|
GlobalIconComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
|
|
||||||
export class LoginComponent extends FormReactive implements OnInit, AfterViewInit {
|
export class LoginComponent extends FormReactive implements OnInit, AfterViewInit {
|
||||||
|
@ -1,31 +0,0 @@
|
|||||||
import { NgModule } from '@angular/core'
|
|
||||||
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 { LoginRoutingModule } from './login-routing.module'
|
|
||||||
import { LoginComponent } from './login.component'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
LoginRoutingModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
|
|
||||||
SharedInstanceModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
LoginComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
LoginComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: [
|
|
||||||
]
|
|
||||||
})
|
|
||||||
export class LoginModule { }
|
|
@ -1,9 +1,8 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { ServerConfigResolver } from '@app/core/routing/server-config-resolver.service'
|
import { ServerConfigResolver } from '@app/core/routing/server-config-resolver.service'
|
||||||
import { LoginComponent } from './login.component'
|
import { LoginComponent } from './login.component'
|
||||||
|
|
||||||
const loginRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
component: LoginComponent,
|
component: LoginComponent,
|
||||||
@ -12,14 +11,9 @@ const loginRoutes: Routes = [
|
|||||||
title: $localize`Login`
|
title: $localize`Login`
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
providers: [ ServerConfigResolver ],
|
||||||
resolve: {
|
resolve: {
|
||||||
serverConfig: ServerConfigResolver
|
serverConfig: ServerConfigResolver
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(loginRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class LoginRoutingModule {}
|
|
@ -1,31 +0,0 @@
|
|||||||
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 { SharedActorImageModule } from '../shared/shared-actor-image/shared-actor-image.module'
|
|
||||||
import { SharedActorImageEditModule } from '@app/shared/shared-actor-image-edit'
|
|
||||||
import { VideoChannelCreateComponent } from './video-channel-edit/video-channel-create.component'
|
|
||||||
import { VideoChannelUpdateComponent } from './video-channel-edit/video-channel-update.component'
|
|
||||||
import { ManageRoutingModule } from './manage-routing.module'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
ManageRoutingModule,
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedActorImageModule,
|
|
||||||
SharedActorImageEditModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
VideoChannelCreateComponent,
|
|
||||||
VideoChannelUpdateComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: []
|
|
||||||
})
|
|
||||||
export class ManageModule { }
|
|
@ -1,9 +1,8 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { VideoChannelCreateComponent } from './video-channel-edit/video-channel-create.component'
|
import { VideoChannelCreateComponent } from './video-channel-edit/video-channel-create.component'
|
||||||
import { VideoChannelUpdateComponent } from './video-channel-edit/video-channel-update.component'
|
import { VideoChannelUpdateComponent } from './video-channel-edit/video-channel-update.component'
|
||||||
|
|
||||||
const manageRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: 'create',
|
path: 'create',
|
||||||
component: VideoChannelCreateComponent,
|
component: VideoChannelCreateComponent,
|
||||||
@ -22,10 +21,4 @@ const manageRoutes: Routes = [
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(manageRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class ManageRoutingModule {}
|
|
@ -13,10 +13,29 @@ import { FormReactiveService } from '@app/shared/shared-forms'
|
|||||||
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
|
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
|
||||||
import { HttpStatusCode, VideoChannelCreate } from '@peertube/peertube-models'
|
import { HttpStatusCode, VideoChannelCreate } from '@peertube/peertube-models'
|
||||||
import { VideoChannelEdit } from './video-channel-edit'
|
import { VideoChannelEdit } from './video-channel-edit'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { MarkdownTextareaComponent } from '../../shared/shared-forms/markdown-textarea.component'
|
||||||
|
import { HelpComponent } from '../../shared/shared-main/misc/help.component'
|
||||||
|
import { ActorAvatarEditComponent } from '../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
import { ActorBannerEditComponent } from '../../shared/shared-actor-image-edit/actor-banner-edit.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './video-channel-edit.component.html',
|
templateUrl: './video-channel-edit.component.html',
|
||||||
styleUrls: [ './video-channel-edit.component.scss' ]
|
styleUrls: [ './video-channel-edit.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
ActorBannerEditComponent,
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
NgClass,
|
||||||
|
HelpComponent,
|
||||||
|
MarkdownTextareaComponent,
|
||||||
|
PeertubeCheckboxComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoChannelCreateComponent extends VideoChannelEdit implements OnInit, AfterViewInit {
|
export class VideoChannelCreateComponent extends VideoChannelEdit implements OnInit, AfterViewInit {
|
||||||
error: string
|
error: string
|
||||||
|
@ -14,11 +14,30 @@ import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
|
|||||||
import { VideoChannelUpdate } from '@peertube/peertube-models'
|
import { VideoChannelUpdate } from '@peertube/peertube-models'
|
||||||
import { VideoChannelEdit } from './video-channel-edit'
|
import { VideoChannelEdit } from './video-channel-edit'
|
||||||
import { shallowCopy } from '@peertube/peertube-core-utils'
|
import { shallowCopy } from '@peertube/peertube-core-utils'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { MarkdownTextareaComponent } from '../../shared/shared-forms/markdown-textarea.component'
|
||||||
|
import { HelpComponent } from '../../shared/shared-main/misc/help.component'
|
||||||
|
import { ActorAvatarEditComponent } from '../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
import { ActorBannerEditComponent } from '../../shared/shared-actor-image-edit/actor-banner-edit.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-video-channel-update',
|
selector: 'my-video-channel-update',
|
||||||
templateUrl: './video-channel-edit.component.html',
|
templateUrl: './video-channel-edit.component.html',
|
||||||
styleUrls: [ './video-channel-edit.component.scss' ]
|
styleUrls: [ './video-channel-edit.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
NgIf,
|
||||||
|
FormsModule,
|
||||||
|
ReactiveFormsModule,
|
||||||
|
ActorBannerEditComponent,
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
NgClass,
|
||||||
|
HelpComponent,
|
||||||
|
MarkdownTextareaComponent,
|
||||||
|
PeertubeCheckboxComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class VideoChannelUpdateComponent extends VideoChannelEdit implements OnInit, AfterViewInit, OnDestroy {
|
export class VideoChannelUpdateComponent extends VideoChannelEdit implements OnInit, AfterViewInit, OnDestroy {
|
||||||
error: string
|
error: string
|
||||||
@ -179,7 +198,7 @@ export class VideoChannelUpdateComponent extends VideoChannelEdit implements OnI
|
|||||||
}
|
}
|
||||||
|
|
||||||
getFormButtonTitle () {
|
getFormButtonTitle () {
|
||||||
return $localize`Update ${this.videoChannel.name}`
|
return $localize`Update ${this.videoChannel?.name}`
|
||||||
}
|
}
|
||||||
|
|
||||||
isBulkUpdateVideosDisplayed () {
|
isBulkUpdateVideosDisplayed () {
|
||||||
|
@ -1,3 +0,0 @@
|
|||||||
export * from './my-account-routing.module'
|
|
||||||
export * from './my-account.component'
|
|
||||||
export * from './my-account.module'
|
|
@ -1,9 +1,13 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
|
import { AbuseListTableComponent } from '../../shared/shared-abuse-list/abuse-list-table.component'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-abuses-list',
|
selector: 'my-account-abuses-list',
|
||||||
templateUrl: './my-account-abuses-list.component.html',
|
templateUrl: './my-account-abuses-list.component.html',
|
||||||
styleUrls: [ ]
|
styleUrls: [],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, AbuseListTableComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountAbusesListComponent {
|
export class MyAccountAbusesListComponent {
|
||||||
|
|
||||||
|
@ -3,11 +3,15 @@ import { AuthService, ConfirmService, Notifier, ScopedTokensService } from '@app
|
|||||||
import { VideoService } from '@app/shared/shared-main'
|
import { VideoService } from '@app/shared/shared-main'
|
||||||
import { FeedFormat, ScopedToken } from '@peertube/peertube-models'
|
import { FeedFormat, ScopedToken } from '@peertube/peertube-models'
|
||||||
import { environment } from '../../../environments/environment'
|
import { environment } from '../../../environments/environment'
|
||||||
|
import { InputTextComponent } from '../../shared/shared-forms/input-text.component'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-applications',
|
selector: 'my-account-applications',
|
||||||
templateUrl: './my-account-applications.component.html',
|
templateUrl: './my-account-applications.component.html',
|
||||||
styleUrls: [ './my-account-applications.component.scss' ]
|
styleUrls: [ './my-account-applications.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, InputTextComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountApplicationsComponent implements OnInit {
|
export class MyAccountApplicationsComponent implements OnInit {
|
||||||
feedUrl: string
|
feedUrl: string
|
||||||
|
@ -1,9 +1,29 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
|
import { BlocklistComponentType, GenericAccountBlocklistComponent } from '@app/shared/shared-moderation'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { ActorAvatarComponent } from '../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { SharedModule } from 'primeng/api'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-blocklist',
|
selector: 'my-account-blocklist',
|
||||||
templateUrl: '../../shared/shared-moderation/account-blocklist.component.html'
|
templateUrl: '../../shared/shared-moderation/account-blocklist.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgIf,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class MyAccountBlocklistComponent extends GenericAccountBlocklistComponent {
|
export class MyAccountBlocklistComponent extends GenericAccountBlocklistComponent {
|
||||||
mode = BlocklistComponentType.Account
|
mode = BlocklistComponentType.Account
|
||||||
|
@ -1,10 +1,30 @@
|
|||||||
import { Component } from '@angular/core'
|
import { Component } from '@angular/core'
|
||||||
import { BlocklistComponentType, GenericServerBlocklistComponent } from '@app/shared/shared-moderation'
|
import { BlocklistComponentType, GenericServerBlocklistComponent } from '@app/shared/shared-moderation'
|
||||||
|
import { BatchDomainsModalComponent } from '../../shared/shared-moderation/batch-domains-modal.component'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
import { AutoColspanDirective } from '../../shared/shared-main/angular/auto-colspan.directive'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { SharedModule } from 'primeng/api'
|
||||||
|
import { TableModule } from 'primeng/table'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-server-blocklist',
|
selector: 'my-account-server-blocklist',
|
||||||
styleUrls: [ '../../shared/shared-moderation/moderation.scss', '../../shared/shared-moderation/server-blocklist.component.scss' ],
|
styleUrls: [ '../../shared/shared-moderation/moderation.scss', '../../shared/shared-moderation/server-blocklist.component.scss' ],
|
||||||
templateUrl: '../../shared/shared-moderation/server-blocklist.component.html'
|
templateUrl: '../../shared/shared-moderation/server-blocklist.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
TableModule,
|
||||||
|
SharedModule,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
NgbTooltip,
|
||||||
|
AutoColspanDirective,
|
||||||
|
NgIf,
|
||||||
|
BatchDomainsModalComponent,
|
||||||
|
DatePipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class MyAccountServerBlocklistComponent extends GenericServerBlocklistComponent {
|
export class MyAccountServerBlocklistComponent extends GenericServerBlocklistComponent {
|
||||||
mode = BlocklistComponentType.Account
|
mode = BlocklistComponentType.Account
|
||||||
|
@ -4,11 +4,18 @@ import { PeerTubeProblemDocument, ServerErrorCode, UserExport, UserExportState }
|
|||||||
import { UserImportExportService } from './user-import-export.service'
|
import { UserImportExportService } from './user-import-export.service'
|
||||||
import { concatMap, first, from, of, switchMap, toArray } from 'rxjs'
|
import { concatMap, first, from, of, switchMap, toArray } from 'rxjs'
|
||||||
import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
|
import { NgbModal, NgbModalRef } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { BytesPipe } from '../../shared/shared-main/angular/bytes.pipe'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
import { NgIf, NgFor, DatePipe } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-export',
|
selector: 'my-account-export',
|
||||||
templateUrl: './my-account-export.component.html',
|
templateUrl: './my-account-export.component.html',
|
||||||
styleUrls: [ './my-account-export.component.scss' ]
|
styleUrls: [ './my-account-export.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, NgFor, GlobalIconComponent, PeertubeCheckboxComponent, FormsModule, DatePipe, BytesPipe ]
|
||||||
})
|
})
|
||||||
export class MyAccountExportComponent implements OnInit {
|
export class MyAccountExportComponent implements OnInit {
|
||||||
@ViewChild('exportModal', { static: true }) exportModal: NgbModal
|
@ViewChild('exportModal', { static: true }) exportModal: NgbModal
|
||||||
|
@ -2,10 +2,14 @@ import { Component, OnInit, ViewChild } from '@angular/core'
|
|||||||
import { AuthService, CanComponentDeactivate, UserService } from '@app/core'
|
import { AuthService, CanComponentDeactivate, UserService } from '@app/core'
|
||||||
import { MyAccountImportComponent } from './my-account-import.component'
|
import { MyAccountImportComponent } from './my-account-import.component'
|
||||||
import { first } from 'rxjs'
|
import { first } from 'rxjs'
|
||||||
|
import { MyAccountExportComponent } from './my-account-export.component'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-import-export',
|
selector: 'my-account-import-export',
|
||||||
templateUrl: './my-account-import-export.component.html'
|
templateUrl: './my-account-import-export.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, MyAccountImportComponent, MyAccountExportComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountImportExportComponent implements OnInit, CanComponentDeactivate {
|
export class MyAccountImportExportComponent implements OnInit, CanComponentDeactivate {
|
||||||
@ViewChild('accountImport') accountImport: MyAccountImportComponent
|
@ViewChild('accountImport') accountImport: MyAccountImportComponent
|
||||||
|
@ -7,11 +7,16 @@ import { buildHTTPErrorResponse, genericUploadErrorHandler, getUploadXRetryConfi
|
|||||||
import { HttpStatusCode, UserImport, UserImportState } from '@peertube/peertube-models'
|
import { HttpStatusCode, UserImport, UserImportState } from '@peertube/peertube-models'
|
||||||
import { UploadxService, UploadState, UploaderX } from 'ngx-uploadx'
|
import { UploadxService, UploadState, UploaderX } from 'ngx-uploadx'
|
||||||
import { BytesPipe } from '@app/shared/shared-main'
|
import { BytesPipe } from '@app/shared/shared-main'
|
||||||
|
import { NgbTooltip } from '@ng-bootstrap/ng-bootstrap'
|
||||||
|
import { UploadProgressComponent } from '../../shared/standalone-upload/upload-progress.component'
|
||||||
|
import { NgIf, DatePipe } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-import',
|
selector: 'my-account-import',
|
||||||
templateUrl: './my-account-import.component.html',
|
templateUrl: './my-account-import.component.html',
|
||||||
styleUrls: [ './my-account-import.component.scss' ]
|
styleUrls: [ './my-account-import.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, UploadProgressComponent, NgbTooltip, DatePipe ]
|
||||||
})
|
})
|
||||||
export class MyAccountImportComponent implements OnInit, OnDestroy, CanComponentDeactivate {
|
export class MyAccountImportComponent implements OnInit, OnDestroy, CanComponentDeactivate {
|
||||||
@Input() videoQuotaUsed: number
|
@Input() videoQuotaUsed: number
|
||||||
|
@ -1,11 +1,17 @@
|
|||||||
import { Component, ViewChild } from '@angular/core'
|
import { Component, ViewChild } from '@angular/core'
|
||||||
import { UserNotificationsComponent } from '@app/shared/standalone-notifications/user-notifications.component'
|
import { UserNotificationsComponent } from '@app/shared/standalone-notifications/user-notifications.component'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
|
||||||
type NotificationSortType = 'createdAt' | 'read'
|
type NotificationSortType = 'createdAt' | 'read'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './my-account-notifications.component.html',
|
templateUrl: './my-account-notifications.component.html',
|
||||||
styleUrls: [ './my-account-notifications.component.scss' ]
|
styleUrls: [ './my-account-notifications.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ RouterLink, GlobalIconComponent, FormsModule, NgIf, UserNotificationsComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountNotificationsComponent {
|
export class MyAccountNotificationsComponent {
|
||||||
@ViewChild('userNotification', { static: true }) userNotification: UserNotificationsComponent
|
@ViewChild('userNotification', { static: true }) userNotification: UserNotificationsComponent
|
||||||
|
@ -5,11 +5,16 @@ import { AuthService, Notifier, ServerService, UserService } from '@app/core'
|
|||||||
import { USER_EMAIL_VALIDATOR, USER_PASSWORD_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
import { USER_EMAIL_VALIDATOR, USER_PASSWORD_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { HttpStatusCode, User } from '@peertube/peertube-models'
|
import { HttpStatusCode, User } from '@peertube/peertube-models'
|
||||||
|
import { InputTextComponent } from '../../../shared/shared-forms/input-text.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-change-email',
|
selector: 'my-account-change-email',
|
||||||
templateUrl: './my-account-change-email.component.html',
|
templateUrl: './my-account-change-email.component.html',
|
||||||
styleUrls: [ './my-account-change-email.component.scss' ]
|
styleUrls: [ './my-account-change-email.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, FormsModule, ReactiveFormsModule, NgClass, InputTextComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountChangeEmailComponent extends FormReactive implements OnInit {
|
export class MyAccountChangeEmailComponent extends FormReactive implements OnInit {
|
||||||
error: string = null
|
error: string = null
|
||||||
|
@ -8,11 +8,16 @@ import {
|
|||||||
} from '@app/shared/form-validators/user-validators'
|
} from '@app/shared/form-validators/user-validators'
|
||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { HttpStatusCode, User } from '@peertube/peertube-models'
|
import { HttpStatusCode, User } from '@peertube/peertube-models'
|
||||||
|
import { InputTextComponent } from '../../../shared/shared-forms/input-text.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-change-password',
|
selector: 'my-account-change-password',
|
||||||
templateUrl: './my-account-change-password.component.html',
|
templateUrl: './my-account-change-password.component.html',
|
||||||
styleUrls: [ './my-account-change-password.component.scss' ]
|
styleUrls: [ './my-account-change-password.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, FormsModule, ReactiveFormsModule, InputTextComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountChangePasswordComponent extends FormReactive implements OnInit {
|
export class MyAccountChangePasswordComponent extends FormReactive implements OnInit {
|
||||||
error: string = null
|
error: string = null
|
||||||
|
@ -4,7 +4,8 @@ import { AuthService, ConfirmService, Notifier, RedirectService, User, UserServi
|
|||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-danger-zone',
|
selector: 'my-account-danger-zone',
|
||||||
templateUrl: './my-account-danger-zone.component.html',
|
templateUrl: './my-account-danger-zone.component.html',
|
||||||
styleUrls: [ './my-account-danger-zone.component.scss' ]
|
styleUrls: [ './my-account-danger-zone.component.scss' ],
|
||||||
|
standalone: true
|
||||||
})
|
})
|
||||||
export class MyAccountDangerZoneComponent {
|
export class MyAccountDangerZoneComponent {
|
||||||
@Input() user: User = null
|
@Input() user: User = null
|
||||||
|
@ -3,11 +3,15 @@ import { Component, Input, OnInit } from '@angular/core'
|
|||||||
import { Notifier, UserService } from '@app/core'
|
import { Notifier, UserService } from '@app/core'
|
||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { User, UserUpdateMe } from '@peertube/peertube-models'
|
import { User, UserUpdateMe } from '@peertube/peertube-models'
|
||||||
|
import { PeertubeCheckboxComponent } from '../../../shared/shared-forms/peertube-checkbox.component'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-email-preferences',
|
selector: 'my-account-email-preferences',
|
||||||
templateUrl: './my-account-email-preferences.component.html',
|
templateUrl: './my-account-email-preferences.component.html',
|
||||||
styleUrls: [ './my-account-email-preferences.component.scss' ]
|
styleUrls: [ './my-account-email-preferences.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ FormsModule, ReactiveFormsModule, PeertubeCheckboxComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountEmailPreferencesComponent extends FormReactive implements OnInit {
|
export class MyAccountEmailPreferencesComponent extends FormReactive implements OnInit {
|
||||||
@Input() user: User = null
|
@Input() user: User = null
|
||||||
|
@ -5,11 +5,16 @@ import { Notifier, ServerService, User } from '@app/core'
|
|||||||
import { UserNotificationService } from '@app/shared/shared-main'
|
import { UserNotificationService } from '@app/shared/shared-main'
|
||||||
import { objectKeysTyped } from '@peertube/peertube-core-utils'
|
import { objectKeysTyped } from '@peertube/peertube-core-utils'
|
||||||
import { UserNotificationSetting, UserNotificationSettingValue, UserRight, UserRightType } from '@peertube/peertube-models'
|
import { UserNotificationSetting, UserNotificationSettingValue, UserRight, UserRightType } from '@peertube/peertube-models'
|
||||||
|
import { FormsModule } from '@angular/forms'
|
||||||
|
import { InputSwitchComponent } from '../../../shared/shared-forms/input-switch.component'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-notification-preferences',
|
selector: 'my-account-notification-preferences',
|
||||||
templateUrl: './my-account-notification-preferences.component.html',
|
templateUrl: './my-account-notification-preferences.component.html',
|
||||||
styleUrls: [ './my-account-notification-preferences.component.scss' ]
|
styleUrls: [ './my-account-notification-preferences.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, NgFor, InputSwitchComponent, FormsModule ]
|
||||||
})
|
})
|
||||||
export class MyAccountNotificationPreferencesComponent implements OnInit {
|
export class MyAccountNotificationPreferencesComponent implements OnInit {
|
||||||
@Input() user: User
|
@Input() user: User
|
||||||
|
@ -3,11 +3,15 @@ import { Component, Input, OnInit } from '@angular/core'
|
|||||||
import { Notifier, User, UserService } from '@app/core'
|
import { Notifier, User, UserService } from '@app/core'
|
||||||
import { USER_DESCRIPTION_VALIDATOR, USER_DISPLAY_NAME_REQUIRED_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
import { USER_DESCRIPTION_VALIDATOR, USER_DISPLAY_NAME_REQUIRED_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
||||||
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactive, FormReactiveService } from '@app/shared/shared-forms'
|
||||||
|
import { FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
|
import { NgIf, NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-profile',
|
selector: 'my-account-profile',
|
||||||
templateUrl: './my-account-profile.component.html',
|
templateUrl: './my-account-profile.component.html',
|
||||||
styleUrls: [ './my-account-profile.component.scss' ]
|
styleUrls: [ './my-account-profile.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, FormsModule, ReactiveFormsModule, NgClass ]
|
||||||
})
|
})
|
||||||
export class MyAccountProfileComponent extends FormReactive implements OnInit {
|
export class MyAccountProfileComponent extends FormReactive implements OnInit {
|
||||||
@Input() user: User = null
|
@Input() user: User = null
|
||||||
|
@ -1,14 +1,42 @@
|
|||||||
import { ViewportScroller } from '@angular/common'
|
import { ViewportScroller, NgIf } from '@angular/common'
|
||||||
import { HttpErrorResponse } from '@angular/common/http'
|
import { HttpErrorResponse } from '@angular/common/http'
|
||||||
import { AfterViewChecked, Component, OnInit } from '@angular/core'
|
import { AfterViewChecked, Component, OnInit } from '@angular/core'
|
||||||
import { AuthService, Notifier, User, UserService } from '@app/core'
|
import { AuthService, Notifier, User, UserService } from '@app/core'
|
||||||
import { genericUploadErrorHandler } from '@app/helpers'
|
import { genericUploadErrorHandler } from '@app/helpers'
|
||||||
import { shallowCopy } from '@peertube/peertube-core-utils'
|
import { shallowCopy } from '@peertube/peertube-core-utils'
|
||||||
|
import { MyAccountDangerZoneComponent } from './my-account-danger-zone/my-account-danger-zone.component'
|
||||||
|
import { MyAccountChangeEmailComponent } from './my-account-change-email/my-account-change-email.component'
|
||||||
|
import { MyAccountEmailPreferencesComponent } from './my-account-email-preferences/my-account-email-preferences.component'
|
||||||
|
import { MyAccountTwoFactorButtonComponent } from './my-account-two-factor/my-account-two-factor-button.component'
|
||||||
|
import { MyAccountChangePasswordComponent } from './my-account-change-password/my-account-change-password.component'
|
||||||
|
import {
|
||||||
|
MyAccountNotificationPreferencesComponent
|
||||||
|
} from './my-account-notification-preferences/my-account-notification-preferences.component'
|
||||||
|
import { UserVideoSettingsComponent } from '../../shared/shared-user-settings/user-video-settings.component'
|
||||||
|
import { UserInterfaceSettingsComponent } from '../../shared/shared-user-settings/user-interface-settings.component'
|
||||||
|
import { MyAccountProfileComponent } from './my-account-profile/my-account-profile.component'
|
||||||
|
import { UserQuotaComponent } from '../../shared/shared-main/users/user-quota.component'
|
||||||
|
import { ActorAvatarEditComponent } from '../../shared/shared-actor-image-edit/actor-avatar-edit.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-settings',
|
selector: 'my-account-settings',
|
||||||
templateUrl: './my-account-settings.component.html',
|
templateUrl: './my-account-settings.component.html',
|
||||||
styleUrls: [ './my-account-settings.component.scss' ]
|
styleUrls: [ './my-account-settings.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
ActorAvatarEditComponent,
|
||||||
|
UserQuotaComponent,
|
||||||
|
MyAccountProfileComponent,
|
||||||
|
UserInterfaceSettingsComponent,
|
||||||
|
UserVideoSettingsComponent,
|
||||||
|
MyAccountNotificationPreferencesComponent,
|
||||||
|
NgIf,
|
||||||
|
MyAccountChangePasswordComponent,
|
||||||
|
MyAccountTwoFactorButtonComponent,
|
||||||
|
MyAccountEmailPreferencesComponent,
|
||||||
|
MyAccountChangeEmailComponent,
|
||||||
|
MyAccountDangerZoneComponent
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class MyAccountSettingsComponent implements OnInit, AfterViewChecked {
|
export class MyAccountSettingsComponent implements OnInit, AfterViewChecked {
|
||||||
user: User = null
|
user: User = null
|
||||||
|
@ -2,10 +2,14 @@ import { Subject } from 'rxjs'
|
|||||||
import { Component, Input, OnInit } from '@angular/core'
|
import { Component, Input, OnInit } from '@angular/core'
|
||||||
import { AuthService, ConfirmService, Notifier, User } from '@app/core'
|
import { AuthService, ConfirmService, Notifier, User } from '@app/core'
|
||||||
import { TwoFactorService } from '@app/shared/shared-users'
|
import { TwoFactorService } from '@app/shared/shared-users'
|
||||||
|
import { ButtonComponent } from '../../../shared/shared-main/buttons/button.component'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-two-factor-button',
|
selector: 'my-account-two-factor-button',
|
||||||
templateUrl: './my-account-two-factor-button.component.html'
|
templateUrl: './my-account-two-factor-button.component.html',
|
||||||
|
standalone: true,
|
||||||
|
imports: [ NgIf, ButtonComponent ]
|
||||||
})
|
})
|
||||||
export class MyAccountTwoFactorButtonComponent implements OnInit {
|
export class MyAccountTwoFactorButtonComponent implements OnInit {
|
||||||
@Input() user: User = null
|
@Input() user: User = null
|
||||||
|
@ -1,15 +1,21 @@
|
|||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { FormGroup } from '@angular/forms'
|
import { FormGroup, FormsModule, ReactiveFormsModule } from '@angular/forms'
|
||||||
import { Router } from '@angular/router'
|
import { Router } from '@angular/router'
|
||||||
import { AuthService, Notifier, User } from '@app/core'
|
import { AuthService, Notifier, User } from '@app/core'
|
||||||
import { USER_EXISTING_PASSWORD_VALIDATOR, USER_OTP_TOKEN_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
import { USER_EXISTING_PASSWORD_VALIDATOR, USER_OTP_TOKEN_VALIDATOR } from '@app/shared/form-validators/user-validators'
|
||||||
import { FormReactiveService } from '@app/shared/shared-forms'
|
import { FormReactiveService } from '@app/shared/shared-forms'
|
||||||
import { TwoFactorService } from '@app/shared/shared-users'
|
import { TwoFactorService } from '@app/shared/shared-users'
|
||||||
|
import { QRCodeModule } from 'angularx-qrcode'
|
||||||
|
import { InputTextComponent } from '../../../shared/shared-forms/input-text.component'
|
||||||
|
import { NgIf } from '@angular/common'
|
||||||
|
import { GlobalIconComponent } from '../../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-account-two-factor',
|
selector: 'my-account-two-factor',
|
||||||
templateUrl: './my-account-two-factor.component.html',
|
templateUrl: './my-account-two-factor.component.html',
|
||||||
styleUrls: [ './my-account-two-factor.component.scss' ]
|
styleUrls: [ './my-account-two-factor.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ GlobalIconComponent, NgIf, FormsModule, ReactiveFormsModule, InputTextComponent, QRCodeModule ]
|
||||||
})
|
})
|
||||||
export class MyAccountTwoFactorComponent implements OnInit {
|
export class MyAccountTwoFactorComponent implements OnInit {
|
||||||
twoFactorAlreadyEnabled: boolean
|
twoFactorAlreadyEnabled: boolean
|
||||||
|
@ -1,11 +1,15 @@
|
|||||||
import { Component, OnInit } from '@angular/core'
|
import { Component, OnInit } from '@angular/core'
|
||||||
import { AuthUser, ScreenService } from '@app/core'
|
import { AuthUser, ScreenService } from '@app/core'
|
||||||
import { TopMenuDropdownParam } from '../shared/shared-main/misc/top-menu-dropdown.component'
|
import { TopMenuDropdownParam, TopMenuDropdownComponent } from '../shared/shared-main/misc/top-menu-dropdown.component'
|
||||||
|
import { RouterOutlet } from '@angular/router'
|
||||||
|
import { NgClass } from '@angular/common'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'my-my-account',
|
selector: 'my-my-account',
|
||||||
templateUrl: './my-account.component.html',
|
templateUrl: './my-account.component.html',
|
||||||
styleUrls: [ './my-account.component.scss' ]
|
styleUrls: [ './my-account.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [ TopMenuDropdownComponent, NgClass, RouterOutlet ]
|
||||||
})
|
})
|
||||||
export class MyAccountComponent implements OnInit {
|
export class MyAccountComponent implements OnInit {
|
||||||
menuEntries: TopMenuDropdownParam[] = []
|
menuEntries: TopMenuDropdownParam[] = []
|
||||||
|
@ -1,97 +0,0 @@
|
|||||||
import { QRCodeModule } from 'angularx-qrcode'
|
|
||||||
import { AutoCompleteModule } from 'primeng/autocomplete'
|
|
||||||
import { TableModule } from 'primeng/table'
|
|
||||||
import { DragDropModule } from '@angular/cdk/drag-drop'
|
|
||||||
import { NgModule } from '@angular/core'
|
|
||||||
import { SharedAbuseListModule } from '@app/shared/shared-abuse-list'
|
|
||||||
import { SharedActorImageEditModule } from '@app/shared/shared-actor-image-edit'
|
|
||||||
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 { SharedShareModal } from '@app/shared/shared-share-modal'
|
|
||||||
import { SharedUserInterfaceSettingsModule } from '@app/shared/shared-user-settings'
|
|
||||||
import { SharedUsersModule } from '@app/shared/shared-users'
|
|
||||||
import { SharedActorImageModule } from '../shared/shared-actor-image/shared-actor-image.module'
|
|
||||||
import { MyAccountAbusesListComponent } from './my-account-abuses/my-account-abuses-list.component'
|
|
||||||
import { MyAccountApplicationsComponent } from './my-account-applications/my-account-applications.component'
|
|
||||||
import { MyAccountBlocklistComponent } from './my-account-blocklist/my-account-blocklist.component'
|
|
||||||
import { MyAccountServerBlocklistComponent } from './my-account-blocklist/my-account-server-blocklist.component'
|
|
||||||
import { MyAccountNotificationsComponent } from './my-account-notifications/my-account-notifications.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 { MyAccountEmailPreferencesComponent } from './my-account-settings/my-account-email-preferences'
|
|
||||||
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 { MyAccountTwoFactorButtonComponent, MyAccountTwoFactorComponent } from './my-account-settings/my-account-two-factor'
|
|
||||||
import { MyAccountComponent } from './my-account.component'
|
|
||||||
import {
|
|
||||||
MyAccountImportExportComponent,
|
|
||||||
MyAccountExportComponent,
|
|
||||||
MyAccountImportComponent,
|
|
||||||
UserImportExportService
|
|
||||||
} from './my-account-import-export'
|
|
||||||
import { UploadProgressComponent } from '@app/shared/standalone-upload'
|
|
||||||
import { UserNotificationsComponent } from '@app/shared/standalone-notifications/user-notifications.component'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
MyAccountRoutingModule,
|
|
||||||
|
|
||||||
QRCodeModule,
|
|
||||||
AutoCompleteModule,
|
|
||||||
TableModule,
|
|
||||||
DragDropModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedModerationModule,
|
|
||||||
SharedUserInterfaceSettingsModule,
|
|
||||||
SharedUsersModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedAbuseListModule,
|
|
||||||
SharedShareModal,
|
|
||||||
SharedActorImageModule,
|
|
||||||
SharedActorImageEditModule,
|
|
||||||
|
|
||||||
UploadProgressComponent,
|
|
||||||
UserNotificationsComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
MyAccountComponent,
|
|
||||||
MyAccountSettingsComponent,
|
|
||||||
MyAccountChangePasswordComponent,
|
|
||||||
MyAccountProfileComponent,
|
|
||||||
MyAccountChangeEmailComponent,
|
|
||||||
MyAccountApplicationsComponent,
|
|
||||||
|
|
||||||
MyAccountTwoFactorButtonComponent,
|
|
||||||
MyAccountTwoFactorComponent,
|
|
||||||
|
|
||||||
MyAccountDangerZoneComponent,
|
|
||||||
MyAccountBlocklistComponent,
|
|
||||||
MyAccountAbusesListComponent,
|
|
||||||
MyAccountServerBlocklistComponent,
|
|
||||||
MyAccountNotificationsComponent,
|
|
||||||
MyAccountNotificationPreferencesComponent,
|
|
||||||
|
|
||||||
MyAccountEmailPreferencesComponent,
|
|
||||||
MyAccountImportExportComponent,
|
|
||||||
MyAccountExportComponent,
|
|
||||||
MyAccountImportComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [
|
|
||||||
MyAccountComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
providers: [
|
|
||||||
UserImportExportService
|
|
||||||
]
|
|
||||||
})
|
|
||||||
export class MyAccountModule {
|
|
||||||
}
|
|
@ -1,5 +1,4 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { CanDeactivateGuard, LoginGuard } from '../core'
|
import { CanDeactivateGuard, LoginGuard } from '../core'
|
||||||
import { MyAccountAbusesListComponent } from './my-account-abuses/my-account-abuses-list.component'
|
import { MyAccountAbusesListComponent } from './my-account-abuses/my-account-abuses-list.component'
|
||||||
import { MyAccountApplicationsComponent } from './my-account-applications/my-account-applications.component'
|
import { MyAccountApplicationsComponent } from './my-account-applications/my-account-applications.component'
|
||||||
@ -8,13 +7,24 @@ import { MyAccountServerBlocklistComponent } from './my-account-blocklist/my-acc
|
|||||||
import { MyAccountNotificationsComponent } from './my-account-notifications/my-account-notifications.component'
|
import { MyAccountNotificationsComponent } from './my-account-notifications/my-account-notifications.component'
|
||||||
import { MyAccountSettingsComponent } from './my-account-settings/my-account-settings.component'
|
import { MyAccountSettingsComponent } from './my-account-settings/my-account-settings.component'
|
||||||
import { MyAccountTwoFactorComponent } from './my-account-settings/my-account-two-factor'
|
import { MyAccountTwoFactorComponent } from './my-account-settings/my-account-two-factor'
|
||||||
import { MyAccountImportExportComponent } from './my-account-import-export'
|
import { MyAccountImportExportComponent, UserImportExportService } from './my-account-import-export'
|
||||||
import { MyAccountComponent } from './my-account.component'
|
import { MyAccountComponent } from './my-account.component'
|
||||||
|
import { TwoFactorService } from '@app/shared/shared-users'
|
||||||
|
import { AbuseService, BlocklistService, VideoBlockService } from '@app/shared/shared-moderation'
|
||||||
|
import { VideoCommentService } from '@app/shared/shared-video-comment'
|
||||||
|
|
||||||
const myAccountRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
component: MyAccountComponent,
|
component: MyAccountComponent,
|
||||||
|
providers: [
|
||||||
|
UserImportExportService,
|
||||||
|
TwoFactorService,
|
||||||
|
BlocklistService,
|
||||||
|
AbuseService,
|
||||||
|
VideoCommentService,
|
||||||
|
VideoBlockService
|
||||||
|
],
|
||||||
canActivateChild: [ LoginGuard ],
|
canActivateChild: [ LoginGuard ],
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
@ -151,10 +161,4 @@ const myAccountRoutes: Routes = [
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(myAccountRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class MyAccountRoutingModule {}
|
|
@ -5,10 +5,38 @@ import { Component } from '@angular/core'
|
|||||||
import { AuthService, ComponentPagination, ConfirmService, hasMoreItems, Notifier, ScreenService } from '@app/core'
|
import { AuthService, ComponentPagination, ConfirmService, hasMoreItems, Notifier, ScreenService } from '@app/core'
|
||||||
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
|
import { VideoChannel, VideoChannelService } from '@app/shared/shared-main'
|
||||||
import { formatICU } from '@app/helpers'
|
import { formatICU } from '@app/helpers'
|
||||||
|
import { NumberFormatterPipe } from '../../shared/shared-main/angular/number-formatter.pipe'
|
||||||
|
import { ChartModule } from 'primeng/chart'
|
||||||
|
import { DeferLoadingDirective } from '../../shared/shared-main/angular/defer-loading.directive'
|
||||||
|
import { DeleteButtonComponent } from '../../shared/shared-main/buttons/delete-button.component'
|
||||||
|
import { EditButtonComponent } from '../../shared/shared-main/buttons/edit-button.component'
|
||||||
|
import { ActorAvatarComponent } from '../../shared/shared-actor-image/actor-avatar.component'
|
||||||
|
import { InfiniteScrollerDirective } from '../../shared/shared-main/angular/infinite-scroller.directive'
|
||||||
|
import { AdvancedInputFilterComponent } from '../../shared/shared-forms/advanced-input-filter.component'
|
||||||
|
import { ChannelsSetupMessageComponent } from '../../shared/shared-main/misc/channels-setup-message.component'
|
||||||
|
import { RouterLink } from '@angular/router'
|
||||||
|
import { NgIf, NgFor } from '@angular/common'
|
||||||
|
import { GlobalIconComponent } from '../../shared/shared-icons/global-icon.component'
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
templateUrl: './my-video-channels.component.html',
|
templateUrl: './my-video-channels.component.html',
|
||||||
styleUrls: [ './my-video-channels.component.scss' ]
|
styleUrls: [ './my-video-channels.component.scss' ],
|
||||||
|
standalone: true,
|
||||||
|
imports: [
|
||||||
|
GlobalIconComponent,
|
||||||
|
NgIf,
|
||||||
|
RouterLink,
|
||||||
|
ChannelsSetupMessageComponent,
|
||||||
|
AdvancedInputFilterComponent,
|
||||||
|
InfiniteScrollerDirective,
|
||||||
|
NgFor,
|
||||||
|
ActorAvatarComponent,
|
||||||
|
EditButtonComponent,
|
||||||
|
DeleteButtonComponent,
|
||||||
|
DeferLoadingDirective,
|
||||||
|
ChartModule,
|
||||||
|
NumberFormatterPipe
|
||||||
|
]
|
||||||
})
|
})
|
||||||
export class MyVideoChannelsComponent {
|
export class MyVideoChannelsComponent {
|
||||||
videoChannels: VideoChannel[] = []
|
videoChannels: VideoChannel[] = []
|
||||||
|
@ -1,29 +0,0 @@
|
|||||||
import { ChartModule } from 'primeng/chart'
|
|
||||||
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 { MyVideoChannelsRoutingModule } from './my-video-channels-routing.module'
|
|
||||||
import { MyVideoChannelsComponent } from './my-video-channels.component'
|
|
||||||
import { SharedActorImageModule } from '@app/shared/shared-actor-image/shared-actor-image.module'
|
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [
|
|
||||||
MyVideoChannelsRoutingModule,
|
|
||||||
|
|
||||||
ChartModule,
|
|
||||||
|
|
||||||
SharedMainModule,
|
|
||||||
SharedFormModule,
|
|
||||||
SharedGlobalIconModule,
|
|
||||||
SharedActorImageModule
|
|
||||||
],
|
|
||||||
|
|
||||||
declarations: [
|
|
||||||
MyVideoChannelsComponent
|
|
||||||
],
|
|
||||||
|
|
||||||
exports: [],
|
|
||||||
providers: []
|
|
||||||
})
|
|
||||||
export class MyVideoChannelsModule { }
|
|
@ -1,8 +1,7 @@
|
|||||||
import { NgModule } from '@angular/core'
|
import { Routes } from '@angular/router'
|
||||||
import { RouterModule, Routes } from '@angular/router'
|
|
||||||
import { MyVideoChannelsComponent } from './my-video-channels.component'
|
import { MyVideoChannelsComponent } from './my-video-channels.component'
|
||||||
|
|
||||||
const myVideoChannelsRoutes: Routes = [
|
export default [
|
||||||
{
|
{
|
||||||
path: '',
|
path: '',
|
||||||
component: MyVideoChannelsComponent,
|
component: MyVideoChannelsComponent,
|
||||||
@ -20,10 +19,4 @@ const myVideoChannelsRoutes: Routes = [
|
|||||||
path: 'update/:videoChannelName',
|
path: 'update/:videoChannelName',
|
||||||
redirectTo: '/manage/update/:videoChannelName'
|
redirectTo: '/manage/update/:videoChannelName'
|
||||||
}
|
}
|
||||||
]
|
] satisfies Routes
|
||||||
|
|
||||||
@NgModule({
|
|
||||||
imports: [ RouterModule.forChild(myVideoChannelsRoutes) ],
|
|
||||||
exports: [ RouterModule ]
|
|
||||||
})
|
|
||||||
export class MyVideoChannelsRoutingModule {}
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user