website refactor

This commit is contained in:
2026-01-16 13:48:18 +01:00
parent 20a42c52fd
commit 7e02fc3ea5
796 changed files with 1946 additions and 2545 deletions

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
/**
@@ -37,7 +37,7 @@ const VALID_REASON_CODES: AdminTrustReasonCodeValue[] = [
'ADMIN_ACTION_ABUSE_REPORT_PENALTY',
];
export class AdminTrustReasonCode implements IValueObject<AdminTrustReasonCodeProps> {
export class AdminTrustReasonCode implements ValueObject<AdminTrustReasonCodeProps> {
readonly value: AdminTrustReasonCodeValue;
private constructor(value: AdminTrustReasonCodeValue) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
/**
@@ -49,7 +49,7 @@ const VALID_REASON_CODES: DrivingReasonCodeValue[] = [
'DRIVING_SEASON_ATTENDANCE_BONUS',
];
export class DrivingReasonCode implements IValueObject<DrivingReasonCodeProps> {
export class DrivingReasonCode implements ValueObject<DrivingReasonCodeProps> {
readonly value: DrivingReasonCodeValue;
private constructor(value: DrivingReasonCodeValue) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import type { EmailValidationResult } from '../types/EmailAddress';
import { validateEmail, isDisposableEmail } from '../types/EmailAddress';
@@ -12,7 +12,7 @@ export interface EmailAddressProps {
* Wraps a validated, normalized email string and provides equality semantics.
* Validation and helper utilities live in domain/types/EmailAddress.
*/
export class EmailAddress implements IValueObject<EmailAddressProps> {
export class EmailAddress implements ValueObject<EmailAddressProps> {
public readonly props: EmailAddressProps;
private constructor(value: string) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
import { GameKey } from './GameKey';
@@ -8,7 +8,7 @@ export interface ExternalRatingProps {
value: number;
}
export class ExternalRating implements IValueObject<ExternalRatingProps> {
export class ExternalRating implements ValueObject<ExternalRatingProps> {
readonly gameKey: GameKey;
readonly type: string;
readonly value: number;

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export interface ExternalRatingProvenanceProps {
@@ -7,7 +7,7 @@ export interface ExternalRatingProvenanceProps {
verified?: boolean;
}
export class ExternalRatingProvenance implements IValueObject<ExternalRatingProvenanceProps> {
export class ExternalRatingProvenance implements ValueObject<ExternalRatingProvenanceProps> {
readonly source: string;
readonly lastSyncedAt: Date;
readonly verified: boolean;

View File

@@ -1,11 +1,11 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export interface GameKeyProps {
value: string;
}
export class GameKey implements IValueObject<GameKeyProps> {
export class GameKey implements ValueObject<GameKeyProps> {
readonly value: string;
private constructor(value: string) {

View File

@@ -1,5 +1,5 @@
import bcrypt from 'bcrypt';
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
export interface PasswordHashProps {
value: string;
@@ -10,7 +10,7 @@ export interface PasswordHashProps {
*
* Wraps a bcrypt-hashed password string and provides verification.
*/
export class PasswordHash implements IValueObject<PasswordHashProps> {
export class PasswordHash implements ValueObject<PasswordHashProps> {
public readonly props: PasswordHashProps;
private constructor(value: string) {

View File

@@ -1,11 +1,11 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export interface RatingDeltaProps {
value: number;
}
export class RatingDelta implements IValueObject<RatingDeltaProps> {
export class RatingDelta implements ValueObject<RatingDeltaProps> {
readonly value: number;
private constructor(value: number) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export interface RatingDimensionKeyProps {
@@ -7,7 +7,7 @@ export interface RatingDimensionKeyProps {
const VALID_DIMENSIONS = ['driving', 'adminTrust', 'stewardTrust', 'broadcasterTrust'] as const;
export class RatingDimensionKey implements IValueObject<RatingDimensionKeyProps> {
export class RatingDimensionKey implements ValueObject<RatingDimensionKeyProps> {
readonly value: RatingDimensionKeyProps['value'];
private constructor(value: RatingDimensionKeyProps['value']) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
import { v4 as uuidv4 } from 'uuid';
@@ -6,7 +6,7 @@ export interface RatingEventIdProps {
value: string;
}
export class RatingEventId implements IValueObject<RatingEventIdProps> {
export class RatingEventId implements ValueObject<RatingEventIdProps> {
readonly value: string;
private constructor(value: string) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export type RatingReferenceType = 'race' | 'penalty' | 'vote' | 'adminAction';
@@ -10,7 +10,7 @@ export interface RatingReferenceProps {
const VALID_TYPES: RatingReferenceType[] = ['race', 'penalty', 'vote', 'adminAction'];
export class RatingReference implements IValueObject<RatingReferenceProps> {
export class RatingReference implements ValueObject<RatingReferenceProps> {
readonly type: RatingReferenceType;
readonly id: string;

View File

@@ -1,11 +1,11 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
import { IdentityDomainValidationError } from '../errors/IdentityDomainError';
export interface RatingValueProps {
value: number;
}
export class RatingValue implements IValueObject<RatingValueProps> {
export class RatingValue implements ValueObject<RatingValueProps> {
readonly value: number;
private constructor(value: number) {

View File

@@ -1,11 +1,11 @@
import { v4 as uuidv4 } from 'uuid';
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
export interface UserIdProps {
value: string;
}
export class UserId implements IValueObject<UserIdProps> {
export class UserId implements ValueObject<UserIdProps> {
public readonly props: UserIdProps;
private constructor(value: string) {

View File

@@ -1,4 +1,4 @@
import type { IValueObject } from '@core/shared/domain';
import type { ValueObject } from '@core/shared/domain';
/**
* Value Object: UserRating
@@ -40,7 +40,7 @@ const DEFAULT_DIMENSION: RatingDimension = {
lastUpdated: new Date(),
};
export class UserRating implements IValueObject<UserRatingProps> {
export class UserRating implements ValueObject<UserRatingProps> {
readonly props: UserRatingProps;
private constructor(props: UserRatingProps) {