-
-
Notifications
You must be signed in to change notification settings - Fork 626
Expand file tree
/
Copy pathassets.css
More file actions
200 lines (166 loc) · 4.55 KB
/
assets.css
File metadata and controls
200 lines (166 loc) · 4.55 KB
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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
/* ==========================================================================
ASSETS
========================================================================== */
.asset-modal {
.saving {
@apply absolute inset-0 flex items-center rounded-xs bg-white/90;
z-index: 200;
.inner {
text-align: center;
padding: 50px;
margin: 0 auto;
}
i {
position: relative;
top: -1px;
margin-right: 10px;
[dir='rtl'] & {
margin-left: 10px;
margin-right: 0;
}
}
}
}
.drag-notification {
@apply absolute inset-0 flex items-center justify-center rounded-sm p-1 text-center text-xs leading-tight @sm:text-lg;
border: 1px dashed var(--color-gray-600);
pointer-events: none;
z-index: 1049;
background: rgba(255, 255, 255, 0.9);
.dark & {
@apply bg-dark-900/90;
border-color: var(--color-dark-600);
}
}
/* Table Listing
========================================================================== */
.asset-table-listing {
@apply relative overflow-hidden rounded-sm border dark:border-dark-900;
table {
@apply m-0 w-full select-none rounded-b border-none;
}
tbody tr {
@apply outline-hidden;
}
tbody tr:not(:last-child) {
@apply border-b dark:border-dark-900;
}
tbody tr td {
@apply p-2;
}
}
.assets-fieldtype-picker + .asset-table-listing {
@apply rounded-t-none;
}
.asset-listing .actions {
margin-bottom: 15px;
display: flex;
.search {
flex: 1;
margin-right: 15px;
[dir='rtl'] & {
margin-left: 15px;
margin-right: 0;
}
margin-left: 0;
[dir='rtl'] & {
margin-right: 0;
margin-left: 0;
}
}
> .btn {
margin-right: 15px;
[dir='rtl'] & {
margin-left: 15px;
margin-right: 0;
}
}
}
/* Fieldtype
========================================================================== */
.asset-tile.draggable-source--is-dragging {
@apply opacity-50;
}
.asset-tile.draggable-mirror {
@apply shadow-lg;
}
/* Grid Listing
========================================================================== */
.asset-grid-listing {
@apply relative grid gap-6 xl:gap-10;
}
.folder-grid-listing {
@apply relative grid gap-8;
grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
}
/* Asset Tile
========================================================================== */
.asset-tile {
@apply relative flex min-w-0 cursor-pointer flex-col items-center justify-between rounded-lg outline outline-gray-300 dark:outline-gray-700;
.selected & {
@apply outline-3 outline-blue-500;
}
.asset-thumb {
@apply flex items-center justify-center size-full;
> img,
> svg,
> .svg-img {
@apply absolute max-h-full max-w-full;
}
}
.asset-thumb-container:hover .asset-controls {
@apply block;
}
.asset-meta-btn {
@apply px-2 py-1 text-blue hover:bg-gray-200 dark:border-dark-300 dark:hover:bg-dark-800 ltr:border-l rtl:border-r;
}
.asset-controls {
@apply absolute hidden;
}
}
.asset-filename {
@apply font-mono text-xs text-gray-500 mt-2 whitespace-nowrap text-center;
.selected & {
@apply text-blue-500;
}
}
/* The Asset Editor
========================================================================== */
.asset-editor {
.editor-preview {
.editor-preview-image {
@apply flex flex-1 flex-col p-8;
}
.image-wrapper {
flex: 1 1 auto;
position: relative;
> * {
@apply absolute h-auto max-h-full w-auto max-w-full;
left: 50%;
[dir='rtl'] & {
left: auto;
right: 50%;
}
top: 50%;
transform: translate(-50%, -50%);
[dir='rtl'] & {
transform: translate(50%, -50%);
}
box-shadow: 0 0 32px rgba(0, 0, 0, 0.35);
}
}
}
.loading {
@apply absolute inset-0 z-10 flex items-center justify-center rounded-sm bg-white/70;
}
}
/* Lazyloading
========================================================================== */
.lazyload,
.lazyloading {
opacity: 0;
}
.lazyloaded {
opacity: 1;
transition: opacity 180ms;
}