Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@crave/farmblocks-empty-state

Package Overview
Dependencies
Maintainers
6
Versions
1247
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@crave/farmblocks-empty-state

Farmblocks empty state

  • 5.1.16
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
101
increased by4950%
Maintainers
6
Weekly downloads
 
Created
Source

logo-farmblocks

Empty State

A placeholder to use on screens without content.

Usage

import React from "react";
import { render } from "react-dom";

import EmptyState from "@crave/farmblocks-empty-state";

const text =
  "Integer posuere erat a ante venenatis dapibus posuere velit aliquet. Etiam porta sem malesuada magna mollis euismod.";
const imgSrc =
  "https://sourcewhatsgood.com/assets/images/utility_images/gallery-third-about-a518a29f64.jpg";

const App = () => (
  <EmptyState
    imageSrc={imgSrc}
    title="Empty State Title"
    description={text}
    actions={[
      {
        text: "Primary Action",
        onClick: () => console.log("clicked"),
        type: buttonTypes.PRIMARY,
      },
    ]}
    info={text}
  />
);

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

API

propertytypedescriptionRequired
titlestringa text that is bold and will be rendered on the first lineYes
descriptionstringa text that will be rendered bellow title
imageSrcstringimage source to be rendered. This property overrides icon if both are present
iconnodeicon name to be rendered
actionsarray of objectseach object corresponds to one button that will be rendered. We expect 3 required properties on each object: text (string), type(string) a valid farmblocks-theme.buttonTypes or any color, onClick (function)
infostringa text that is smaller than the others and will be rendered bellow buttons

Peer dependencies

  • prop-types
  • react
  • styled-components
  • react-responsive
  • styled-system

License

MIT

Keywords

FAQs

Package last updated on 09 Mar 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc