Corex.ColorPicker.Translation (Corex v0.1.0-rc.0)

View Source

Translatable strings for Corex.ColorPicker.

Pass translation={%Corex.ColorPicker.Translation{}} to override any field. Omitted fields use gettext defaults (see table).

FieldDefaultUsed for
hexHex color valueHex channel input aria-label
alphaAlpha (opacity) valueAlpha channel input aria-label

Partial override example:

translation={%Corex.ColorPicker.Translation{
  hex: Corex.Gettext.gettext("Hex code"),
  alpha: Corex.Gettext.gettext("Opacity")
}}

Summary

Types

t()

@type t() :: %Corex.ColorPicker.Translation{alpha: String.t(), hex: String.t()}

Functions

resolve(partial)