fix: QIANXING1-860 修复 divider 样式
parent
22918d8c15
commit
c6eb1d3b03
|
|
@ -3,7 +3,9 @@ import { defaultConfig } from '../../theme/internal';
|
|||
import type { Ref } from 'vue';
|
||||
import { computed } from 'vue';
|
||||
import devWarning from '../../vc-util/warning';
|
||||
const themeKey = 'antdvtheme';
|
||||
import { cssVarPrefix } from '../../theme/util/themeTokenUtil';
|
||||
|
||||
const themeKey = cssVarPrefix;
|
||||
export default function useTheme(theme?: Ref<ThemeConfig>, parentTheme?: Ref<ThemeConfig>) {
|
||||
const themeConfig = computed(() => theme?.value || {});
|
||||
const parentThemeConfig = computed<ThemeConfig>(() =>
|
||||
|
|
|
|||
|
|
@ -108,7 +108,7 @@ const genSharedDividerStyle: GenerateStyle<DividerToken> = (token): CSSObject =>
|
|||
},
|
||||
},
|
||||
|
||||
[`&-horizontal${componentCls}-with-text-start`]: {
|
||||
[`&-horizontal${componentCls}-with-text-left`]: {
|
||||
'&::before': {
|
||||
width: `calc(${orientationMargin} * 100%)`,
|
||||
},
|
||||
|
|
@ -117,7 +117,7 @@ const genSharedDividerStyle: GenerateStyle<DividerToken> = (token): CSSObject =>
|
|||
},
|
||||
},
|
||||
|
||||
[`&-horizontal${componentCls}-with-text-end`]: {
|
||||
[`&-horizontal${componentCls}-with-text-right`]: {
|
||||
'&::before': {
|
||||
width: `calc(100% - ${orientationMargin} * 100%)`,
|
||||
},
|
||||
|
|
@ -178,7 +178,7 @@ const genSharedDividerStyle: GenerateStyle<DividerToken> = (token): CSSObject =>
|
|||
fontSize: token.fontSize,
|
||||
},
|
||||
|
||||
[`&-horizontal${componentCls}-with-text-start${componentCls}-no-default-orientation-margin-start`]:
|
||||
[`&-horizontal${componentCls}-with-text-left${componentCls}-no-default-orientation-margin-left`]:
|
||||
{
|
||||
'&::before': {
|
||||
width: 0,
|
||||
|
|
@ -193,7 +193,7 @@ const genSharedDividerStyle: GenerateStyle<DividerToken> = (token): CSSObject =>
|
|||
},
|
||||
},
|
||||
|
||||
[`&-horizontal${componentCls}-with-text-end${componentCls}-no-default-orientation-margin-end`]:
|
||||
[`&-horizontal${componentCls}-with-text-right${componentCls}-no-default-orientation-margin-right`]:
|
||||
{
|
||||
'&::before': {
|
||||
width: '100%',
|
||||
|
|
|
|||
Loading…
Reference in New Issue