@bolttech/atoms-section-header
TypeScript icon, indicating that this package has built-in type declarations

0.21.0 • Public • Published

SectionHeader Component

The SectionHeader component is a React component designed to provide a header for sections with an optional icon or background illustration. This component allows you to create visually appealing section headers with customizable titles and decorative elements.

Table of Contents

Installation

To use the SectionHeader component in your React application, you need to follow these steps:

Installation

npm install @bolttech/frontend-foundations @bolttech/atoms-section-header

or

yarn add @bolttech/frontend-foundations @bolttech/atoms-section-header

Once you have the required dependencies installed, you can start using the SectionHeader component in your React application.

Usage

The SectionHeader component provides a visually appealing section header with an optional icon or background illustration. It supports customization through various props.

To use the component, import it and include it in your JSX:

import React from 'react';
import {SectionHeader} from '@bolttech/atoms-section-header';
import {bolttechTheme, BolttechThemeProvider} from "@bolttech/frontend-foundations";

function App() {
  return (
    <BolttechThemeProvider theme={bolttechTheme}>
      <SectionHeader
        title="Welcome to our Section"
        icon={<YourIconComponent/>}
        background={<YourBackgroundComponent/>}
        dataTestId="section-header-component"
      />
    </BolttechThemeProvider>
  );
}

export default App;

Props

The SectionHeader component accepts the following props:

Prop Type Description
dataTestId string The data-testid attribute for testing purposes.
title string The title text of the section header.
icon ReactNode An optional icon component to be displayed.
background ReactNode An optional background illustration component.

Example

Here's an example of using the SectionHeader component:

<SectionHeader
  title="Discover Our New Collection"
  icon={<Icon name="bookmark" />}
  background={<Illustration src={illustrationUrl} />}
  dataTestId="section-header-component"
/>

This will render a SectionHeader component with a title, an icon, and a background illustration.

Contributing

Contributions to the SectionHeader component are welcome. If you find any issues or have suggestions for improvements, please feel free to open an issue or submit a pull request on the project's Bitbucket repository.

Readme

Keywords

none

Package Sidebar

Install

npm i @bolttech/atoms-section-header

Weekly Downloads

39

Version

0.21.0

License

none

Unpacked Size

146 kB

Total Files

7

Last publish

Collaborators

  • plinio.altoe
  • bruno.gomes
  • lukaspiccinibt
  • diogo_aleixo_bolttech
  • pauloazevedo-ed
  • danielkhalebbatista
  • andsfranbolt
  • achraf.ely