Module: locale

Localizing script for SVG-edit UI.

License:
  • MIT
Source:

Interfaces

LocaleEditorInit

Methods

(static) putLocale(givenParam, goodLangs) → {Promise.<module:locale.LangAndData>}

Parameters:
Name Type Description
givenParam string
goodLangs Array.<string>
Source:
Fires:
  • module:svgcanvas.SvgCanvas#event:ext_addLangData
  • module:svgcanvas.SvgCanvas#event:ext_langReady
  • module:svgcanvas.SvgCanvas#event:ext_langChanged
Returns:

Resolves to result of module:locale.readLang

Type
Promise.<module:locale.LangAndData>

Type Definitions

AddLangExtensionLocaleData

The "data" property is generally set to an an array of objects with "id" and "title" or "textContent" properties.

Type:
Properties:
Name Type Description
data Array.<module:locale.LocaleStrings>

See Locale Docs

Source:

LangAndData

Type:
Properties:
Name Type Description
langParam string
langData module:locale.LocaleStrings
Source:

LocaleSelectorValue

Type:
Source:

LocaleStrings

The string keys of the object are two-letter language codes.

Type:
Source:
Tutorials: