diff options
Diffstat (limited to 'client/src/app/+signup')
4 files changed, 8 insertions, 2 deletions
diff --git a/client/src/app/+signup/+register/register-step-terms.component.html b/client/src/app/+signup/+register/register-step-terms.component.html index 1cfdc0a3a..28a6e0021 100644 --- a/client/src/app/+signup/+register/register-step-terms.component.html +++ b/client/src/app/+signup/+register/register-step-terms.component.html | |||
@@ -2,8 +2,8 @@ | |||
2 | <div class="form-group form-group-terms"> | 2 | <div class="form-group form-group-terms"> |
3 | <my-peertube-checkbox inputName="terms" formControlName="terms"> | 3 | <my-peertube-checkbox inputName="terms" formControlName="terms"> |
4 | <ng-template ptTemplate="label"> | 4 | <ng-template ptTemplate="label"> |
5 | <ng-container i18n> | 5 | <ng-container i18n> |
6 | I am at least 16 years old and agree | 6 | I am at least {{ minimumAge }} years old and agree |
7 | to the <a class="terms-anchor" (click)="onTermsClick($event)" href='#'>Terms</a> | 7 | to the <a class="terms-anchor" (click)="onTermsClick($event)" href='#'>Terms</a> |
8 | <ng-container *ngIf="hasCodeOfConduct"> and to the <a (click)="onCodeOfConductClick($event)" href='#'>Code of Conduct</a></ng-container> | 8 | <ng-container *ngIf="hasCodeOfConduct"> and to the <a (click)="onCodeOfConductClick($event)" href='#'>Code of Conduct</a></ng-container> |
9 | of this instance | 9 | of this instance |
diff --git a/client/src/app/+signup/+register/register-step-terms.component.ts b/client/src/app/+signup/+register/register-step-terms.component.ts index db834c68d..20c1ae1c4 100644 --- a/client/src/app/+signup/+register/register-step-terms.component.ts +++ b/client/src/app/+signup/+register/register-step-terms.component.ts | |||
@@ -12,6 +12,7 @@ import { FormReactive, FormValidatorService } from '@app/shared/shared-forms' | |||
12 | }) | 12 | }) |
13 | export class RegisterStepTermsComponent extends FormReactive implements OnInit { | 13 | export class RegisterStepTermsComponent extends FormReactive implements OnInit { |
14 | @Input() hasCodeOfConduct = false | 14 | @Input() hasCodeOfConduct = false |
15 | @Input() minimumAge = 16 | ||
15 | 16 | ||
16 | @Output() formBuilt = new EventEmitter<FormGroup>() | 17 | @Output() formBuilt = new EventEmitter<FormGroup>() |
17 | @Output() termsClick = new EventEmitter<void>() | 18 | @Output() termsClick = new EventEmitter<void>() |
diff --git a/client/src/app/+signup/+register/register.component.html b/client/src/app/+signup/+register/register.component.html index dc1c7496f..de72065d3 100644 --- a/client/src/app/+signup/+register/register.component.html +++ b/client/src/app/+signup/+register/register.component.html | |||
@@ -17,6 +17,7 @@ | |||
17 | 17 | ||
18 | <my-register-step-terms | 18 | <my-register-step-terms |
19 | [hasCodeOfConduct]="!!aboutHtml.codeOfConduct" | 19 | [hasCodeOfConduct]="!!aboutHtml.codeOfConduct" |
20 | [minimumAge]="minimumAge" | ||
20 | (formBuilt)="onTermsFormBuilt($event)" (termsClick)="onTermsClick()" (codeOfConductClick)="onCodeOfConductClick()" | 21 | (formBuilt)="onTermsFormBuilt($event)" (termsClick)="onTermsClick()" (codeOfConductClick)="onCodeOfConductClick()" |
21 | ></my-register-step-terms> | 22 | ></my-register-step-terms> |
22 | 23 | ||
diff --git a/client/src/app/+signup/+register/register.component.ts b/client/src/app/+signup/+register/register.component.ts index 8e89bb01a..241ca04c6 100644 --- a/client/src/app/+signup/+register/register.component.ts +++ b/client/src/app/+signup/+register/register.component.ts | |||
@@ -56,6 +56,10 @@ export class RegisterComponent implements OnInit { | |||
56 | return this.serverConfig.signup.requiresEmailVerification | 56 | return this.serverConfig.signup.requiresEmailVerification |
57 | } | 57 | } |
58 | 58 | ||
59 | get minimumAge () { | ||
60 | return this.serverConfig.signup.minimumAge | ||
61 | } | ||
62 | |||
59 | ngOnInit (): void { | 63 | ngOnInit (): void { |
60 | this.serverConfig = this.route.snapshot.data.serverConfig | 64 | this.serverConfig = this.route.snapshot.data.serverConfig |
61 | 65 | ||