Skip to content

Commit

Permalink
fix(components): [popover] abnormal style when effect is dark (#10190)
Browse files Browse the repository at this point in the history
  • Loading branch information
holazz committed Oct 22, 2022
1 parent 99fe8b2 commit dec859a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/components/popover/style/css.ts
@@ -1,3 +1,3 @@
import '@element-plus/components/base/style/css'
import '@element-plus/theme-chalk/el-popover.css'
import '@element-plus/components/popper/style/css'
import '@element-plus/theme-chalk/el-popover.css'
2 changes: 1 addition & 1 deletion packages/components/popover/style/index.ts
@@ -1,3 +1,3 @@
import '@element-plus/components/base/style'
import '@element-plus/theme-chalk/src/popover.scss'
import '@element-plus/components/popper/style'
import '@element-plus/theme-chalk/src/popover.scss'
11 changes: 10 additions & 1 deletion packages/theme-chalk/src/popover.scss
Expand Up @@ -40,9 +40,18 @@

@include when(dark) {
@include set-css-var-value(
'popover-title-text-color',
('popover', 'bg-color'),
var(#{getCssVarName('text-color', 'primary')})
);
@include set-css-var-value(
('popover', 'border-color'),
var(#{getCssVarName('text-color', 'primary')})
);
@include set-css-var-value(
('popover', 'title-text-color'),
var(#{getCssVarName('bg-color')})
);
color: getCssVar('bg-color');
}

&:focus:active,
Expand Down

0 comments on commit dec859a

Please sign in to comment.