如何使用反应工具箱图标

How to I make use of react-toolbox icons

我正在为我的项目使用 react-toolbox

我尝试了它的一些功能,即图标按钮。现在我需要一个带有 arrow-up 图标的按钮。不知道是不是react-toolbox提供的

<Button icon='arrow-up' floating />

上面的代码没有在按钮上显示任何图标

如何使用 arrow-up 图标?感谢任何帮助

React Toolbox 是一组实现 Google's Material Design specification 的 React 组件。

根据Github page

Roboto Font and Material Design Icons

React Toolbox assumes that you are importing Roboto Font and Material Design Icons.

In order to import the fonts for you, we'd need to include them in the CSS which is considered a bad practice. If you are not including them in your app, go to the linked sites and follow the instructions.

由于使用了material-icon,你可以从material icons

获取所有的图标列表

您将使用向上箭头图标

 <Button icon='keyboard-arrow-up' floating />

如果您遇到图标不显示的问题,您可能忘记将以下内容添加到 .html 文件中 link:

<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons" />

查看网页material.io安装指南: https://material.io/develop/web/docs/getting-started/