DocSpace-client/packages/asc-web-components/heading
2021-08-27 17:10:26 +03:00
..
heading.stories.js Web: Components: added stories (ModalDialog, MainButton, Loader, Link, LinkWithDropDown, Label, IconButton),fix HelpButton, Heading stories 2021-03-08 23:18:45 +03:00
heading.test.js Web: Components: changed component hierarchy 2021-02-24 17:42:09 +03:00
index.js Web: fixed firefox frame 2021-04-13 14:07:44 +03:00
README.md Web: Components/Common: fix imports 2021-02-26 00:19:45 +03:00
styled-heading.js Fix Bug 52089 - Client.Files. Elements of the page are not selected using left mouse button. 2021-08-27 17:10:26 +03:00

Heading

Heading text structured in levels.

Usage

import Heading from "@appserver/components/heading";
<Heading level={1} title="Some title">
  Some text
</Heading>

If you need to override styles add forwardedAs instead of as

const StyledHeading = styled(Heading)`
  &:hover {
    border-bottom: 1px dotted;
  }
`;
<StyledHeading forwardedAs="h2" title="Some title">
  Some text
</StyledHeading>

Properties

Props Type Required Values Default Description
color string - - #333333 Specifies the headline color
isInline bool - - false Sets the 'display: inline-block' property
level oneOf - 1, 2, 3, 4, 5, 6 1 The heading level. It corresponds to the number after the 'H' for the DOM tag. Set the level for semantic accuracy and accessibility.
size oneOF - xsmall, small, medium, large, xlarge large Sets the size of headline
title bool - - - Title
truncate bool - - false Disables word wrapping