Options
All
  • Public
  • Public/Protected
  • All
Menu

@nextcloud/l10n

Index

Variables

OC

OC: OC | OC | OC

window

window: WindowWithGlobals | WindowWithGlobals | WindowWithGlobals

Functions

getDayNames

  • getDayNames(): string[]
  • Get a list of day names (full names)

    Returns string[]

getDayNamesMin

  • getDayNamesMin(): string[]
  • Get a list of day names (minified names)

    Returns string[]

getDayNamesShort

  • getDayNamesShort(): string[]
  • Get a list of day names (short names)

    Returns string[]

getFirstDay

  • getFirstDay(): number
  • Get the first day of the week

    Returns number

getGettextBuilder

getLanguage

  • getLanguage(): string
  • Returns the user's language

    Returns string

getLocale

  • getLocale(): string
  • Returns the user's locale

    Returns string

getMonthNames

  • getMonthNames(): string[]
  • Get a list of month names (full names)

    Returns string[]

getMonthNamesShort

  • getMonthNamesShort(): string[]
  • Get a list of month names (short names)

    Returns string[]

translate

  • translate(app: string, text: string, vars?: undefined | object, count?: undefined | number, options?: TranslationOptions): string
  • Translate a string

    Parameters

    • app: string

      the id of the app for which to translate the string

    • text: string

      the string to translate

    • Optional vars: undefined | object

      map of placeholder key to value

    • Optional count: undefined | number
    • Optional options: TranslationOptions

    Returns string

translatePlural

  • translatePlural(app: string, textSingular: string, textPlural: string, count: number, vars?: undefined | object, options?: TranslationOptions): string
  • Translate a plural string

    Parameters

    • app: string

      the id of the app for which to translate the string

    • textSingular: string

      the string to translate for exactly one object

    • textPlural: string

      the string to translate for n objects

    • count: number

      number to determine whether to use singular or plural

    • Optional vars: undefined | object

      of placeholder key to value

    • Optional options: TranslationOptions

      options object

    Returns string

Generated using TypeDoc