我如何在 BlueprintJS 中使用颜色?

How do I use Colors in BlueprintJS?

在我的反应文件的顶部,我包括以下内容:

import { Colors } from '@blueprintjs/core';

如何从现在开始使用 colors,例如 @blue3?

const homeStyle = {
 background: '@blue2';
};

这似乎行不通。

颜色作为单个对象导出,因此要访问它,您应该这样做:

const homeStyle = {
   background: Colors.BLUE3;
};