chore: add getZIndexStyle util (#8254)

This commit is contained in:
neverland
2021-03-03 16:45:32 +08:00
committed by GitHub
parent 202edb24c7
commit 2d8914c2c8
11 changed files with 40 additions and 36 deletions

View File

@@ -85,19 +85,19 @@ export default createComponent({
linkChildren({ props });
const sidebarStyle = computed(() => {
const sidebarStyle = computed<CSSProperties | undefined>(() => {
if (isDef(props.zIndex)) {
return {
zIndex: +props.zIndex + 1,
} as CSSProperties;
};
}
});
const highlightStyle = computed(() => {
const highlightStyle = computed<CSSProperties | undefined>(() => {
if (props.highlightColor) {
return {
color: props.highlightColor,
} as CSSProperties;
};
}
});