@crave/farmblocks-footer

Farmblocks Footer

Stats

stars 🌟issues ⚠️updated 🛠created 🐣size 🏋️‍♀️
2023Jun 14, 2021Aug 23, 2017Minified + gzip package size for @crave/farmblocks-footer in KB

Readme

logo-farmblocks

Farmblocks-Footer

See Storybook image

Design spec

See it on zeplin

Usage

import React, { Component } from "react";
import { render } from "react-dom";
import Footer from "@crave/farmblocks-footer";
import Button, { buttonTypes, buttonSizes } from "@crave/farmblocks-button";

const App = () => (
  <div>
    <Footer
      helpText="Lorem ipsum dolor sit amet, consectetur adipiscing elit"
      helpLinkHref="#"
      helpLinkText="Get support"
      actions={[
        <Button
          onClick={() => console.log("handle onCancelClick")}
          size={buttonSizes.MEDIUM}
          text="Cancel"
          key="cancel"
        />,
        <Button
          onClick={() => console.log("handle onSaveClick")}
          type={buttonTypes.PRIMARY}
          size={buttonSizes.MEDIUM}
          text="Save"
          key="save"
        />
      ]}
    />
  </div>
);

render(<App />, document.getElementById("root"));

API

Helper section:

  • helpText: string (required)
  • helpLinkText: string (required)
  • helpLinkHref: string (required)

Action section:

  • actions: array of dom nodes

See it in the source

License

MIT

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.