The title component

Defines HTML headings. The level 1 is used for the maximal size and the level 6 is used for the minimal size.

Introduced in SQLPage v0.19.0.

Top-level parameters

contents

REQUIRED. A text to display.

center

Whether to center the title.

class

class attribute added to the container in HTML. It can be used to apply custom styling to this item through css. Added in v0.18.0.

id

id attribute added to the container in HTML. It can be used to target this item through css or for scrolling to this item through links (use "#id" in link url).

level

Set the heading level (default level is 1)

Example 1

Displays several titles with different levels.

select 
    'title'   as component,
    'Level 1' as contents;
select 
    'title'   as component,
    'Level 2' as contents,
    2         as level;
select 
    'title'   as component,
    'Level 3' as contents,
    3         as level;

Result

Level 1

Level 2

Level 3

Example 2

Displays a centered title.

select 
    'title'   as component,
    'Level 1' as contents,
    TRUE      as center;

Result

Level 1

See also: other components