AEM 6.4 has reached the end of extended support and this documentation is no longer updated. For further details, see our technical support periods. Find the supported versions here.
You can define the overall appearance and style of an adaptive form by specifying styles using theme editor. Also, you can apply inline CSS styles to individual adaptive form components and preview the changes on the fly. Inline styles override styling provided in the theme.
To add inline styles to a component:
Open your form in the form editor, and change the mode to styling mode. To change the mode to styling mode, in the page toolbar, tap > Style.
Select a component in the page, and tap the edit button . Styling properties open in the sidebar.
You can also select components from the form hierarchy tree in the sidebar. Form hierarchy tree is available as Form Objects in the sidebar.
You can also select a component from the sidebar. In the Style mode, you can see components listed under Form Objects. However, Form Objects list in the sidebar lists components such as fields and panels. Fields and panels are generic components that can contain components such as text-box and radio-buttons.
When you select a component from the sidebar, you see all the sub-components listed and the properties of the selected component. You can select a specific sub-component and style it.
Click a tab in the sidebar to specify CSS properties. You can specify properties such as:
Similarly, you can apply styles for other parts of a component such as Widget, Caption, and Help.
Tap Done to confirm the changes or Cancel to discard the changes.
The following images depict a text field before and after inline styles are applied to it.
Text box component before applying inline style properties
Notice the change in text box style as shown in the following image after applying the following CSS properties.
Selector |
CSS property |
Value |
Effect |
Field |
border |
Border width =2px Border style=Solid Border color=#1111 |
Creates a Black 2px wide border around the field |
Text box |
background-color |
#6495ED |
Changes the background color to CornflowerBlue (#6495ED) Note: You can specify a color name or its hex code in the value field. |
Label |
Dimenstions & Position > width |
100px |
Fixes the width as 100px for the label |
Field Help Icon | Text > Font Color | #2ECC40 | Changes the color of the help icon face. |
Long description |
text-align |
center |
Aligns the long description for help to center |
Figure: Text box component after applying inline style properties
Following the steps above, you can select and style other components, such as panels, submit buttons, and radio buttons.
Styling properties vary based on the component you select.