Skip to content
  1. Extras
  2. PageBuilder
  3. Field types
  4. Pro
  5. imask

Field imask

Version: Pro.

Why this type

Phone, tax id, card pattern without validate-only. Mask or preset in schema. Pro advanced-fields.

When to use

  • Phone in contact_form fields
  • SKU or serial with fixed format
  • Promo code pattern

Tips

Plain numeric use number. Value is string with mask literals per preset.

Similar types

  • text without format constraint
  • url for links, not phone mask

Schema

json
{
  "name": "phone",
  "type": "imask",
  "label": "Phone",
  "mask": "+7 (000) 000-00-00",
  "maskOptions": {
    "lazy": false
  },
  "tab": "Content",
  "width": 100,
  "active": true
}

Value

Masked string.

Section data

Key phone in the section data: masked string:

json
{
  "phone": "+7 (495) 123-45-67"
}

Chunk example

html
<a href="tel:{$phone|escape}">{$phone|escape}</a>

Notes

Short mask: mask. Full IMask config: maskOptions (object or JSON string).

Common properties

For fields with name that are stored in the section data:

KeyTypeRoleCMP
tabstringGroup subtitle in the inspectoryes
width25–100Field width as % of the row (flex)yes
descriptionstringHint under the labelyes
defaultanyInitial value for a new sectionyes
activeboolfalse hides the field in the inspectoryes
requiredboolRequired on publish (draft still saves)yes
  • Also: mask or maskOptions (IMask JSON).

See fields overview.

See also