Jet\UI_badge

Renderer od badge. Inherited from Jet\UI_Renderer_Single.

The badge must have a defined type, which will determine the colour scheme and other aspects of the design, if any. The following types are predefined (but of course you can make your own types):

Predefined types

Constanta Value
UI_badge::PRIMARYprimary
UI_badge::SECONDARYsecondary
UI_badge::WARNINGwarning
UI_badge::INFOinfo
UI_badge::SUCCESSsuccess
UI_badge::DANGERdanger
UI_badge::LIGHTlight
UI_badge::DARKdark

Overview of methods

Method Meaning of
public __construct(
string $type,
string $text
)
Parameters:
  • $type
    Badge type - idedeally constant - predefined or custom
  • $text
    Content of the element
public getType(
) : string
Returns the type
public getText(
) : string
Returns the content of the element
Previous chapter
Jet\UI_Renderer_Pair
Next chapter
Jet\UI_button