BloksMoleculeIcon Feature

Icon Feature

Description

The Icon Feature component is a flexible and customizable element designed to showcase features or information with accompanying icons. It supports various layout options, icon sizes, and styling preferences, making it suitable for creating visually appealing feature lists or highlight sections in a user interface.

Installation

bash
sabaccui add iconFeature

Usage

Here are some examples of how to use the Icon Feature component:

Basic usage with icon on the left:

Preview

Feature Icon

Fast Performance: Our solution offers lightning-fast performance for all your needs.

Icon on top with glow effect and border:

Preview

Speed Icon

Optimized Speed: Enjoy blazing fast load times and smooth user experiences.

Large icon with custom styling:

Preview

Security Icon

Enhanced Security: State-of-the-art encryption and protection for your data.

Schema

Field NameTypeDescriptionDefault Value
iconassetThe icon image to be displayed. Only image files are allowed.-
textmarkdownThe text content describing the feature. Supports markdown formatting.-
layoutoptionDetermines the layout of the icon and text. Options: left (Icon left), top (Icon top).left
glowbooleanEnables a glow effect behind the icon.false
borderedbooleanAdds a border and background to the feature.false
iconSizeoptionSets the size of the icon. Options: sm (Small), md (Medium), lg (Large), xl (Xlarge), 2xl (2X Large).-

Notes

  1. The component uses a flexible layout with a gap between the icon and text.
  2. The component supports responsive design, adjusting gap sizes for different screen sizes. 3Markdown content is rendered using a separate Markdown component, allowing for rich text formatting.

Best Practices:

  • Use consistent icon sizes within a group of Icon Feature components for a cohesive look.
  • When using the glow effect, ensure sufficient contrast with the background for accessibility.
  • Leverage the markdown support in the text field to create structured and formatted content.
  • Consider the layout option based on the overall design of the section where the component is used.
  • Use the bordered option to create visually distinct feature blocks when needed.