zhangyong
2023-08-22 1353e87cb21a4032d585d7404bae9042f2ebcf08
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
@use 'mixins/mixins' as *;
@use 'mixins/var' as *;
@use 'common/var' as *;
 
@include b(card) {
  @include set-component-css-var('card', $card);
}
 
@include b(card) {
  border-radius: getCssVar('card', 'border-radius');
  border: 1px solid getCssVar('card', 'border-color');
  background-color: getCssVar('card', 'bg-color');
  overflow: hidden;
  color: getCssVar('text-color', 'primary');
  transition: getCssVar('transition-duration');
 
  @include when(always-shadow) {
    box-shadow: getCssVar('box-shadow', 'light');
  }
 
  @include when(hover-shadow) {
    &:hover,
    &:focus {
      box-shadow: getCssVar('box-shadow', 'light');
    }
  }
 
  @include e(header) {
    padding: calc(#{getCssVar('card', 'padding')} - 2px)
      getCssVar('card', 'padding');
    border-bottom: 1px solid getCssVar('card', 'border-color');
    box-sizing: border-box;
  }
 
  @include e(body) {
    padding: getCssVar('card', 'padding');
  }
}