Variable defaultConst

    default: {
        colorGenerator: ((quantity?: number) => string | string[]);
        deepCopy: (<T>(object: T) => T);
        getGitVersion: (() => string);
        groupToAvatar: ((group: {
            id?: string;
            name?: string;
        }) => ReactNode);
        projectToAvatar: ((project: {
            id?: string;
            title?: string;
        }) => ReactNode);
        rgbToHex: ((color: {
            b: number;
            g: number;
            r: number;
        }) => string);
        rgbToRgba: ((color?: {
            b: number;
            g: number;
            r: number;
        }, alpha?: number) => string);
        stringToColor: ((str?: string) => string);
        usermodelToAvatar: ((usermodel: {
            id?: string;
            model?: IModel;
        }) => ReactNode);
        userToAvatar: ((user: {
            avatar?: Buffer;
            email?: string;
            firstname?: string;
            id?: string;
            lastname?: string;
            pending?: boolean;
        }) => ReactNode);
        validateEmail: ((email: string) => boolean);
        workspaceToAvatar: ((workspace: {
            id?: string;
            name?: string;
        }) => ReactNode);
    } = ...

    Type declaration

    • colorGenerator: ((quantity?: number) => string | string[])
        • (quantity?): string | string[]
        • Contrasting color generator

          Parameters

          • Optionalquantity: number

            Number

          Returns string | string[]

          HEX array

    • deepCopy: (<T>(object: T) => T)
        • <T>(object): T
        • Deep copy

          Type Parameters

          • T extends {}

          Parameters

          • object: T

            Object

          Returns T

          Copy

    • getGitVersion: (() => string)
        • (): string
        • Get git version

          Returns string

          Git version

    • groupToAvatar: ((group: {
          id?: string;
          name?: string;
      }) => ReactNode)
        • (group): ReactNode
        • Group to avatar

          Parameters

          • group: {
                id?: string;
                name?: string;
            }

            Group

            • Optionalid?: string
            • Optionalname?: string

          Returns ReactNode

          Avatar

    • projectToAvatar: ((project: {
          id?: string;
          title?: string;
      }) => ReactNode)
        • (project): ReactNode
        • Project to avatar

          Parameters

          • project: {
                id?: string;
                title?: string;
            }

            Project

            • Optionalid?: string
            • Optionaltitle?: string

          Returns ReactNode

          Avatar

    • rgbToHex: ((color: {
          b: number;
          g: number;
          r: number;
      }) => string)
        • (color): string
        • RGB to Hex

          Parameters

          • color: {
                b: number;
                g: number;
                r: number;
            }

            Color {r, g, b}

            • b: number
            • g: number
            • r: number

          Returns string

          Hex

    • rgbToRgba: ((color?: {
          b: number;
          g: number;
          r: number;
      }, alpha?: number) => string)
        • (color?, alpha?): string
        • rgb to CSS rgba

          Parameters

          • Optionalcolor: {
                b: number;
                g: number;
                r: number;
            }

            Color {r, g, b}

            • b: number
            • g: number
            • r: number
          • alpha: number = 1

            Alpha

          Returns string

          rgba

    • stringToColor: ((str?: string) => string)
        • (str?): string
        • String to color

          Parameters

          • Optionalstr: string

            String

          Returns string

          HSL color

    • usermodelToAvatar: ((usermodel: {
          id?: string;
          model?: IModel;
      }) => ReactNode)
        • (usermodel): ReactNode
        • Usermodel to avatar

          Parameters

          • usermodel: {
                id?: string;
                model?: IModel;
            }

            User model

            • Optionalid?: string
            • Optionalmodel?: IModel

          Returns ReactNode

          Avatar

    • userToAvatar: ((user: {
          avatar?: Buffer;
          email?: string;
          firstname?: string;
          id?: string;
          lastname?: string;
          pending?: boolean;
      }) => ReactNode)
        • (user): ReactNode
        • User to avatar

          Parameters

          • user: {
                avatar?: Buffer;
                email?: string;
                firstname?: string;
                id?: string;
                lastname?: string;
                pending?: boolean;
            }

            User

            • Optionalavatar?: Buffer
            • Optionalemail?: string
            • Optionalfirstname?: string
            • Optionalid?: string
            • Optionallastname?: string
            • Optionalpending?: boolean

          Returns ReactNode

          Avatar

    • validateEmail: ((email: string) => boolean)
        • (email): boolean
        • Validate email

          Parameters

          • email: string

            Email

          Returns boolean

          Valid

    • workspaceToAvatar: ((workspace: {
          id?: string;
          name?: string;
      }) => ReactNode)
        • (workspace): ReactNode
        • Workspace to avatar

          Parameters

          • workspace: {
                id?: string;
                name?: string;
            }

            Workspace

            • Optionalid?: string
            • Optionalname?: string

          Returns ReactNode

          Avatar

    Generated using TypeDoc and TypeDoc Airthium Plugin