HTML Element Component

Overview

One of the best ways to increase end-user experience in your application is with an HTML Element component. The HTML Element component allows you to add HTML formatting right into your application. In Express View, you can see your HTML Elements render along with the rest of your module.

Some common examples of when to use the HTML Element component are:

  • Inserting a custom logo or image.

  • Showing a section heading or break.

  • Adding a paragraph of static text.

You'll find the HTML Element component in the Display & Layout group to the left of the Module Builder.

What You'll Learn

After completing this article, you’ll know when to use an HTML Element component, how to configure its  settings, and how to add it to an application.

About the Configuration Window

General

Setting

Description

Property ID

A Property ID is the unique field ID used by Unqork to track and link components in your module.

The Property ID is how the software identifies your component. Using Property IDs lets you link components, creating logic-based configurations and API APIs (application programming interfaces) are a set of protocols and definitions developers use to build and integrate application software. APIs act as the connective tissue between products and services. calls.

Property IDs must use camel case A naming convention for computer programming. Use camelCase for Property IDs, for example: newUser, lastName, & rdoButton. (stylized as camelCase) without spaces or punctuation.

(ON)/ (OFF)

The component is active and visible in Express View Express View is how your end-user views you application. Express View also lets you preview your applications to test your configuration and view the styling. After configuring a module, click Preview in the Module Editor to interact with the module in Express View. While active, other components and processes can reference your component.

Setting the toggle to Toggle Off icon (OFF) makes your component inactive. Other components and processes cannot reference your component while it's inactive.

By default, the Active toggle is set to Toggle On Icon (ON).

Notes

Select this tab to display the component's Notes area. You can use notes to keep your teammates informed.

The Notes editor offers a semi-WYSIWYG (What You See is What You Get) content editor. Built to look like a word processor, this editor lets you create, edit, and format your notes. Notes save when saving the component.

Display Icon Display

Select this tab to manage your component's display settings.

Advanced Icon Advanced

Select this tab to manage your component's advanced settings.

Permissions Icon Permissions

Select this tab to see the RBAC RBAC (Role-Based Access Control) is a method to control system access for authorized users. The role in RBAC refers to the levels of access employees have to a network. (role-based access control) settings of the component.

Field Tag Icon Field Tags

Assign components one-word labels to help organize, identify, and group the components in your application.

Consider an example from the API Specification Snippet: Field Tags are applied to Hidden components in the panelRequest and panelResponse Panels. The Field Tags identify the data type of parameters included in the API APIs (application programming interfaces) are a set of protocols and definitions developers use to build and integrate application software. APIs act as the connective tissue between products and services. request and response. The API Docs Dashboard tool populates with information about each parameter’s data type, identified by the Field Tag.

Field Tags act as a type of Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module. group and let you group components for configuration purposes. Field Tags let you target two or more components using a simple logic component.

For example, add the Field Tag tagForDecision to multiple components in your module. Open the Inputs table of a Decisions component and reference the tagForDecision Field Tag as the input of the Decisions component. The output of the Decisions component then affects all components with the tagForDecision Field Tag.

Save your Field Tags by pressing Enter (Return) or adding a comma after each entry.

Shortcuts Icon Shortcuts

Select this tab to open the list of supported keyboard shortcuts you can use in the component settings modal. Keyboard shortcuts include:

  • Cmd + S (Mac) / Ctrl + S (PC): Save and close the component settings modal.

  • Cmd + G (Mac) / Ctrl + G (PC): Opens a search window to find specific fields and settings in the component settings modal.

  • Tab: Tab to the next field or setting in the component settings modal. This keyboard shortcut tabs left to right and top to bottom.

  • Shift + Tab: Tab to the previous field or setting in the component settings modal. The keyboard shortcut tabs from right to left and bottom to top.

  • Enter (Return): When tabbing to a Tooltip Icon (tooltip), press Enter (Return) to display the field or setting tooltip. Press Enter (Return) again to hide the tooltip.

Additional keyboard shortcuts:

  • Drop-down menus: When you Tab to a settings drop-down, use the keyboard's Up-Arrow Icon (up)/ Down-Arrow icon (down) arrows to make a selection. Then, press Enter (Return) to confirm the selection.

Documentation IconDocumentation

Select this tab to access the component documentation in Unqork's In-Product Help.

Cancel

Click this button to undo any unsaved configuration changes and return to the canvas.

Save & Close

Click this button to save all settings as configured and return to the canvas.

Display Panel

A static image dispaying the HTML Element component's Display settings.
(click to expand image)

Formatting

Setting

Description

Tag

Set the HTML container for your content here. The HTML Tag is what you'll see inside angled brackets in traditional HTML. Common HTML tags you can use include:

  • h1: Heading 1 text.

  • p: Paragraph of text.

  • a: Basic hyperlink.

  • hr: Horizontal rule.

By default, the HTML Tag is set to p.

Content

The Content window works together with your HTML Tag. If you create a heading, enter your heading text here. The same goes for a paragraph or a basic hyperlink. What you enter here is what displays to your end-user in Express View. In traditional HTML, your content displays between your start and end tags. You can also enter additional HTML tags in the Content window. What you enter in the Tag setting field determines the default HTML tag.

To prevent security exploits, only use safe HTML tags and attributes. When configuring your HTML tags and attributes, consider the following:

  • Safe attributes for use in HTML tags: 'class', 'color', 'size', 'href', 'style', 'align', 'target', 'title', 'width', 'height', 'role', 'type', 'id', 'for', 'xmlns', 'rel', 'fill', 'frameborder', 'border', 'charset', 'tabindex', 'allow', 'valign', 'font-size', 'padding-top', 'css', 'tooltip', and 'aria-hidden'.

  • Allowed HTML tag attribute combinations that may only be used in combination with explicitly allowed HTML tags: 'src' and/or 'alt' can only be used in combination with <img>.

    NOTE  'src' is only supported for older, pre-existing configurations.

  • Disallowed HTML tags that are unsafe or otherwise non-permissible: <script> is never allowed.

Default State Options

Setting

Description

Hide Element

Shows or hides the component from view. Setting the Hide Field toggle to Toggle On Icon (ON) hides the component in Express View. Setting the toggle to Toggle Off icon (OFF) shows the component. The component is always visible in the Module Builder.

By default, the Hide Field toggle is set to Toggle Off icon (OFF).

Advanced Panel

A static image dispaying the HTML Element component's Advanced settings.
(click to expand image)

Additional Styling

Setting

Description

Custom CSS Class

Enter a Custom CSS Cascading Style Sheets (CSS) is a style sheet language used for presenting how a HTML or XML document looks to end-users. Class to apply to your component. Use custom CSS to maintain a consistent look and feel if the field or element is part of a template or more than one module.

Updated CSS styling applies to all components that reference this custom class name.

Custom CSS Class for Container

Enter a Custom CSS Class to apply to the HTML tag you entered in the HTML Tag field.

Add Attributes

This table works together with your HTML Tag to define any relevant attributes.

Common examples include:

  • Set the href (or destination) for a hyperlink.

  • Define the src (or source URL) of an image.

Label

Each attribute has a label recognized in HTML.

For example:

  • For the destination of a hyperlink, this is your href.

  • For the source of an image, this is your src.

Value

Each attribute has a value assigned to it. For a hyperlink, this is the URL you link to. For an image, this is the address where the image exists.

Adding an HTML Element Component

In this example, use an HTML Element component to add a heading for a few Personal Information questions. Follow this configuration with two Text Field components to collect the end-user’s first and last names. Also use a Phone Number component to collect their phone number. Then, place these into columns and add a second HTML Element component to hold a horizontal rule denoting the end of the section.

NOTE  These instructions assume that you have an open module saved with a title.

For this configuration, you'll need the following components:

Configure the First HTML Element Component

First, set up the section header. Add an HTML Element component that reads Personal Information and set its size to h3.

1. In the Module Builder, drag and drop an  Columns Component Icon HTML Element component onto your canvas.
2. In the Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module. field, enter htmlPersonalInfo.
3. In the Tag field, enter h3.
4. In the Content window, enter Personal Information..

5. Click Save & Close.

Configure the Columns Component

Using a Columns component, you can create containers for the components that follow. Select the pre-configured layout containing two evenly-spaced columns.

1. Drag and drop a  Columns Component Icon Columns component onto your canvas, placing it below your HTML Element.
2. In the Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module.  field, enter colPersonalInfo.
3. Under Formatting, click the icon displaying  (two) evenly-spaced columns.
4. Click Save & Close.

Configure the Text Field Components

Add two Text Field components to collect your end-user’s first and last name.

1. Drag and drop two  Text Field components onto your canvas, placing one Text Field in each column of the colPersonalInfo  Columns Component Icon Columns component.
2. Complete the Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module. and Label Text Label Text conveys what the input component is and what information it displays. Enter the purpose of the corresponding component or field. as follows:

Property ID

Label Text

firstName

First Name

lastName

Last Name

3. Save & Close each component as you add it.

Configure the Phone Number Component

Add a Phone Number component to collect more personal information.

1. Drag and drop a  Columns Component Icon Phone Number component onto your canvas, placing it below your firstName  Text Field component in the colPersonalInfo  Columns Component Icon Columns component.
2. In the Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module. field, enter phoneNumber.
3. In the Label Text Label Text conveys what the input component is and what information it displays. Enter the purpose of the corresponding component or field. field, enter Phone Number.
4. Click Save & Close.

Configure the Second HTML Element Component

Add a second HTML Element component to the configuration.

1. Drag and drop an  Columns Component Icon HTML Element component onto your canvas, placing it below your colPersonalInfo  Columns Component Icon Columns component.
2. In the Property ID A Property ID is the unique field ID used by Unqork to track and link components in your module. field, enter htmlHorizontalRule.
3. In the Tag field, enter hr to display a horizontal rule on the page.

4. Click Save & Close.
5. Save your module.

Your module looks like the following in Express View Express View is how your end-user views you application. Express View also lets you preview your applications to test your configuration and view the styling. After configuring a module, click Preview in the Module Editor to interact with the module in Express View:

Resources