aboutsummaryrefslogtreecommitdiffstats
path: root/packages/excalidraw/components/LibraryMenuItems.scss
blob: 59cd9f1cf9cd47f138aedb728740c6dbbc08a9b3 (plain) (blame)
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
@import "open-color/open-color";

.excalidraw {
  --container-padding-y: 1.5rem;
  --container-padding-x: 0.75rem;

  .library-menu-items__no-items {
    text-align: center;
    color: var(--color-gray-70);
    line-height: 1.5;
    font-size: 0.875rem;
    width: 100%;

    &__label {
      color: var(--color-primary);
      font-weight: 700;
      font-size: 1.125rem;
      margin-bottom: 0.75rem;
    }
  }

  &.theme--dark {
    .library-menu-items__no-items {
      color: var(--color-gray-40);
    }
  }

  .library-menu-items-container {
    width: 100%;
    display: flex;
    flex-grow: 1;
    flex-shrink: 1;
    flex-basis: 0;
    overflow-y: auto;
    flex-direction: column;
    height: 100%;
    justify-content: center;
    margin: 0;

    position: relative;

    & > div {
      padding-left: 0.75rem;
      padding-right: 0.75rem;
    }

    &__row {
      display: grid;
      grid-template-columns: repeat(4, 1fr);
      gap: 1rem;
    }

    &__items {
      row-gap: 0.5rem;
      padding: var(--container-padding-y) 0;
      flex: 1;
      overflow-y: auto;
      overflow-x: hidden;
      margin-bottom: 1rem;
    }

    &__header {
      color: var(--color-primary);
      font-size: 1.125rem;
      font-weight: 700;
      margin-bottom: 0.75rem;
      width: 100%;
      padding-right: 4rem; // due to dropdown button
      box-sizing: border-box;

      &--excal {
        margin-top: 2rem;
      }
    }

    &__grid {
      display: grid;
      grid-template-columns: 1fr 1fr 1fr 1fr;
      grid-gap: 1rem;
    }

    .separator {
      width: 100%;
      display: flex;
      align-items: center;
      font-weight: 500;
      font-size: 0.9rem;
      margin: 0.6em 0.2em;
      color: var(--text-primary-color);
    }
  }

  .library-menu-items-private-library-container {
    // so that when you toggle between pending item and no items, there's
    // no layout shift (this is hardcoded and works only with ENG locale)
    min-height: 3.75rem;
    width: 100%;
  }
}