File

packages/ecl/components/ecl-link/ecl-link.directive.ts

Description

'eclLink' directive is used to add some styling to the defalt HTML anchor component. In order to comply with ECL standards.

Extends

ECLBaseDirective

Implements

AfterContentInit

Metadata

Index

Properties
Methods
Inputs
HostBindings
Accessors

Inputs

extraAttributes
Type : [] | undefined

Additional HTML attributes to be set on the link element. Used e.g. by social-media-follow for passing extra_attributes.

isHighlight
Type : boolean
Default value : false

Adds class for hightlighted link (works only with 'primary' variant)

isIconOnly
Type : boolean
Default value : false

Property to style the component if it consist only of an icon.

isInverted
Type : boolean
Default value : false

Property to style the component as 'inverted' (with dark background). Can be used alone or with 'standalone' variant.

isNoVisited
Type : boolean
variant
Type : "standalone" | "primary" | "secondary"

With 'variant' property user can add some more specific styling to the component.

class
Type : string
e2eAttr
Type : any
tabindex
Type : number

HostBindings

class
Type : string

Adds speific ECL classes to the component.

class.ecl-link--icon
Type : boolean

Adds class for styling if the link has icon.

class.ecl-link--no-visited
Type : boolean

Methods

onBlur
onBlur()

Calls the native blur() method of the default HTML element.

Returns : void
onClick
onClick()

Calls the native click() method of the default HTML element.

Returns : void
onFocus
onFocus()

Calls the native focus() method of the default HTML element.

Returns : void
getCssClasses
getCssClasses(rootClass: string)
Parameters :
Name Type Optional
rootClass string No
Returns : string

Properties

cd
Type : unknown
Default value : inject(ChangeDetectorRef)
eclIconComponents
Type : unknown
Default value : contentChildren(EclIconComponent)
el
Type : unknown
Default value : inject(ElementRef)
renderer
Type : unknown
Default value : inject(Renderer2)

Accessors

extraAttributes
setextraAttributes(attrs: literal type[] | undefined)

Additional HTML attributes to be set on the link element. Used e.g. by social-media-follow for passing extra_attributes.

Parameters :
Name Type Optional
attrs literal type[] | undefined No
Returns : void
hasIcon
gethasIcon()

Adds class for styling if the link has icon.

Returns : boolean
isLinkNoVisited
getisLinkNoVisited()
cssClasses
getcssClasses()

Adds speific ECL classes to the component.

results matching ""

    No results matching ""