mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-05 05:18:34 +08:00
添加一种机制可以设置类名大写开头,但是不自动加主题前缀
This commit is contained in:
parent
e36c9de4b3
commit
0cce1ea9e5
@ -48,7 +48,7 @@ export function makeClassnames(ns?: string) {
|
||||
|
||||
const fn = (...classes: ClassValue[]) => {
|
||||
const str = cx(...(classes as any));
|
||||
return str && ns ? str.replace(/(^|\s)([A-Z])/g, '$1' + ns + '$2') : str || '';
|
||||
return str && ns ? str.replace(/(^|\s)([A-Z])/g, '$1' + ns + '$2').replace(/(^|\s)\:/g, '$1') : str || '';
|
||||
};
|
||||
|
||||
ns && (fns[ns] = fn);
|
||||
|
Loading…
Reference in New Issue
Block a user