@ 新鲜工作/ 核心
ember install @freshworks/core
包含 Freshworks DSM 的核心设计模块 :
- 变量
- 动画
- 水电费
要在您的主机应用程序中导入这些样式表, 请在您的应用程序中添加以下内容 app.scss 根据你的要求.
@import "nucleus/variables";
@import "nucleus/animations";
@import "nucleus/utilities";
要导入到另一个依赖的附加件( 如 @ refreshdesk/ 按钮), 在附加件中添加以下内容: index.js数字 :
treeForAddonStyles(tree) {
let coreStyleTree = new Funnel(this.getCoreStylesPath(), {
destDir: 'nucleus'
});
return mergeTrees([coreStyleTree, tree]);
},
getCoreStylesPath() {
let pkgPath = path.dirname(require.resolve(`@freshworks/core/package.json`));
return path.join(pkgPath, 'app/styles');
}
原因是:
@nucleus/core应用程序样式漏斗需要与 addon 样式漏斗合并,以使这些文件被识别 驴子。更多信息 这里