GitHub

Hero

A hero is a top-level container designed to be large and captivating, typically used as the first component to introduce a page's main purpose or message.

Components

DaffHeroComponent

import { DaffHeroComponent } from '@daffodil/design/hero'

Hero is a top level container designed to be large and captivating. It should be used only once per page, typically as the first component to introduce the page’s main purpose or message.

@Component()
class DaffHeroComponent {
  @Input() textAlignment: DaffTextAlignment
  @Input() compact: boolean = false
  @Input() color: DaffColor
}

Inputs

textAlignment
DaffTextAlignment
Default
Description

The text alignment of the component.

compact
boolean
Defaultfalse
Description

Whether the component is compact.

color
DaffColor
Default
Description

The color of the component.


Directives

DaffHeroTaglineDirective

import { DaffHeroTaglineDirective } from '@daffodil/design/hero'

Tagline is a short, memorable phrase that complements the title and provides quick context.

@Directive()
class DaffHeroTaglineDirective {}

DaffHeroTitleDirective

import { DaffHeroTitleDirective } from '@daffodil/design/hero'

Title is the primary heading for the hero.

@Directive()
class DaffHeroTitleDirective {}

DaffHeroSubtitleDirective

import { DaffHeroSubtitleDirective } from '@daffodil/design/hero'

Subtitle is a secondary descriptive text displayed beneath the title.

@Directive()
class DaffHeroSubtitleDirective {}

DaffHeroBodyDirective

import { DaffHeroBodyDirective } from '@daffodil/design/hero'

Body is a flexible wrapper for additional components or custom layouts. It's unstyled except for spacing, allowing for a ton of control and customization. It should only be used once per hero.

@Directive()
class DaffHeroBodyDirective {}

DaffHeroIconDirective

import { DaffHeroIconDirective } from '@daffodil/design/hero'

Icon is used to display a visual or branding element. Avoid using this for interactive or actionable icons.

@Directive()
class DaffHeroIconDirective {}

Modules

DaffHeroModule

Deprecated

import { DaffHeroModule } from '@daffodil/design/hero'

@NgModule()
class DaffHeroModule {}