Read-Only Rule

   MaestroThe UI design product.  |   Form Builder |  All versions This feature is related to all versions.

Maestro allows you to add a rule that prevents the user from editing a component's value if a condition is true.

Create a Read-Only Rule

To create a Read-Only rule:

  1. Inside the Maestro Editor, select a component from the View pane.
  2. In the Properties pane, click the Create Rule button.
  3. Click the Read-Only link, located under the Editability heading.
  4. Define the JavaScript-based logic of the rule within the code editor. As a Editability rule, the Read-Only rule should return true for the component to be editable or false to for the component to not be editable.
  5. Click Save.

The rule will appear in the Properties pane, under the Rules heading.

Note

You can only attach one rule of each type to a component.

Editability Rules

There are 2 types of editability rules:

For a complete list of rules, refer to List of Maestro Rules.