summaryrefslogtreecommitdiffhomepage
path: root/packages/ui/src/components/tool-count-label.css
blob: 11a33ff5d14c6c5d6184f841fc00790bf03ffdf7 (plain)
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
[data-component="tool-count-label"] {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
  gap: 0;

  [data-slot="tool-count-label-before"] {
    display: inline-block;
    white-space: pre;
    line-height: inherit;
  }

  [data-slot="tool-count-label-word"] {
    display: inline-flex;
    align-items: baseline;
    white-space: pre;
    line-height: inherit;
  }

  [data-slot="tool-count-label-stem"] {
    display: inline-block;
    white-space: pre;
  }

  [data-slot="tool-count-label-suffix"] {
    display: inline-grid;
    grid-template-columns: 0fr;
    opacity: 0;
    filter: blur(calc(var(--tool-motion-blur, 2px) * 0.42));
    overflow: hidden;
    transform: translateX(-0.04em);
    transition-property: grid-template-columns, opacity, filter, transform;
    transition-duration: 250ms, 250ms, 250ms, 250ms;
    transition-timing-function:
      var(--tool-motion-ease, cubic-bezier(0.22, 1, 0.36, 1)), ease-out, ease-out,
      var(--tool-motion-ease, cubic-bezier(0.22, 1, 0.36, 1));
  }

  [data-slot="tool-count-label-suffix"][data-active="true"] {
    grid-template-columns: 1fr;
    opacity: 1;
    filter: blur(0);
    transform: translateX(0);
  }

  [data-slot="tool-count-label-suffix-inner"] {
    min-width: 0;
    overflow: hidden;
    white-space: pre;
  }
}

@media (prefers-reduced-motion: reduce) {
  [data-component="tool-count-label"] [data-slot="tool-count-label-suffix"] {
    transition-duration: 0ms;
  }
}