mirror of https://github.com/msgbyte/tailchat
feat: 增加配色方案插件支持
parent
e0696d917f
commit
8996fd6ecb
@ -1,2 +1,3 @@
|
|||||||
@import "./overwrite.less";
|
@import "./overwrite.less";
|
||||||
|
@import "./theme.less";
|
||||||
@import "./dark.less";
|
@import "./dark.less";
|
||||||
|
|||||||
@ -0,0 +1,9 @@
|
|||||||
|
// antd 主题色支持
|
||||||
|
#tailchat-app {
|
||||||
|
--tc-primary-color: rgb(24, 144, 255);
|
||||||
|
|
||||||
|
.ant-btn-primary {
|
||||||
|
background: var(--tc-primary-color);
|
||||||
|
border-color: var(--tc-primary-color);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,12 @@
|
|||||||
|
/**
|
||||||
|
* 返回tailchat逻辑根节点
|
||||||
|
* 如果找不到根节点则返回body
|
||||||
|
*/
|
||||||
|
export function getPopupContainer() {
|
||||||
|
const appRoot = document.querySelector<HTMLElement>('#tailchat-app');
|
||||||
|
if (appRoot) {
|
||||||
|
return appRoot;
|
||||||
|
}
|
||||||
|
|
||||||
|
return document.body;
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue