Skip to content

TextFieldPropertyView

Steve Hannah edited this page Jul 9, 2021 · 1 revision

TextFieldPropertyView

<radTextField>javadoc

Synopsis

A <textField> that is bound to a view property.

Usage

<radTextField tag="..."/>

Attributes

tag

A tag for the property of the view model to bind to.

component.*

Set properties on the embedded TextField

Example

The following example creates a view property "description" which we bind a <radTextField> to. We also add a binding to a label that tracks the number of characters in the text field.

<?xml version="1.0"?>
<y xsi:noNamespaceSchemaLocation="RADTextFieldSample.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <title>RADTextField Sample</title>

    <define-tag name="description"/>

    <label>Enter Description</label>
    <radTextField tag="description"/>
    <flow>
        <label>Char count</label>
        <label bind-text="java:String.valueOf(${description}.text.length())"
            rad-transition="text 0s"
        />
    </flow>

</y>
RADTextFieldSample
Clone this wiki locally