Skip to content
Aichner Christian edited this page May 14, 2020 · 4 revisions

AIButton

Example:

<AIButton
  name="openModalFoo"
  color="danger"
  value="Change Foo"
  editable={false}
  icon="plus-circle"
  googleAnalytics={{
    register: true,
    category: "Modals",
    action: "Open Modal",
    label: "Launch Foo Modal",
  }}
/>;

type : String

Value Notes Default Examples
type String. What would you like the button to do? undefined submit reset button

color : String

Value Notes Default Examples
color String. What color would you like the button to be? primary primary green danger

value : String

Value Notes Default Examples
value String. Text in button "" "Foo"

editable : String

Value Notes Default
editable Boolean. Can the customer change it? false

size : String

Value Notes Default Examples
size String. What size would you like the button to be? undefined sm md lg

className : String

Value Notes Default Examples
className String. Adds custom classes undefined d-block

icon : String

Value Notes Default Examples
icon String. Adds a Font-Awesome icon undefined sm md lg

iconType : String

Value Notes Default Examples
iconType String. What type of Font-Awesome icon? fas far fab

onClick : String

Value Notes Default
onClick f(x). What function that has been passed on would you like to execute on onClick? undefined

googleAnalytics : Object

Value Notes Default
args.register Boolean. Do you want to register the button click? false
args.category String. Defines the Google Analytics category "Button click"
args.action String. Defines the Google Analytics action name "Unnamed action"
args.label String. Defines the Google Analytics label for the action ""
args.value String. Defines the Google Analytics value for the action 0