argo-cd
435 строк · 12.3 Кб
1@import 'node_modules/argo-ui/src/styles/config';
2@import 'node_modules/argo-ui/src/styles/theme';
3
4.application-resource-tree {
5position: relative;
6overflow: hidden;
7
8&__line {
9position: absolute;
10z-index: -1;
11transition: all 0.2s linear;
12border-top: 1px dashed $argo-color-gray-5;
13}
14
15&__edge {
16.application-resource-tree__line {
17&:last-child {
18&:after {
19content: '\25BA';
20position: absolute;
21color: #A3A3A3;
22font-size: 10px;
23top: -10px;
24transform: rotate(180deg);
25}
26}
27}
28}
29
30&--network {
31.application-resource-tree__line {
32background-image: linear-gradient(90deg, $argo-color-teal-5 50%, transparent 50%);
33background-repeat: repeat-x, repeat-x, repeat-y, repeat-y;
34background-size: 20px 3px, 0px 0px, 0px 0px, 0px 0px;
35background-position: left top, right bottom, left bottom, right top;
36animation: network-flow 1s infinite linear;
37height: 3px;
38border-top: none;
39}
40@keyframes network-flow {
410% {
42background-position: left 20px top, right 20px bottom , left bottom 20px , right top 20px;
43}
44100% {
45background-position: left top, right bottom, left bottom, right top;
46}
47}
48
49.application-resource-tree__edge {
50.application-resource-tree__line {
51&:last-child {
52&:after {
53content: none;
54}
55}
56}
57}
58}
59
60$pod-size: 25px;
61$gutter: 3px;
62$pods-per-row: 8;
63$pods-per-column: 4;
64$max-rows: 5;
65$num-stats: 2;
66
67&__node {
68position: absolute;
69transition: all 0.2s linear;
70padding-left: 3.5em;
71padding-right: 1em;
72margin: 10px;
73box-shadow: 1px 1px 1px $argo-color-gray-4;
74@include themify($themes) {
75background-color: themed('background-2');
76color: themed('text-2');
77}
78border-radius: 4px;
79border: 1px solid transparent;
80cursor: pointer;
81
82.theme-dark & {
83box-shadow: 1px 1px 1px $argo-color-gray-7;
84}
85
86.icon {
87font-size: 2em;
88}
89
90.icon-background
91{
92color: $argo-color-gray-4;
93}
94
95.fa-filter {
96margin-left: 8px;
97padding: 2px;
98}
99
100&.active {
101border-color: $argo-color-teal-6;
102}
103
104&--orphaned {
105@include themify($themes) {
106background-color: themed('light-argo-gray-2') !important;
107}
108}
109
110&--load-balancer {
111cursor: default;
112background-color: $argo-color-teal-2;
113}
114
115&--expansion {
116position: absolute;
117flex-shrink: 0px;
118z-index: 10;
119font-size: 0.5em;
120padding: 2px;
121box-shadow: 1px 1px 1px $argo-color-gray-4;
122@include themify($themes) {
123background-color: themed('background-2');
124}
125margin-top: 9px;
126margin-left: 215px;
127
128.theme-dark & {
129box-shadow: 1px 1px 1px $argo-color-gray-7;
130}
131}
132
133&--podgroup--expansion {
134position: absolute;
135flex-shrink: 0px;
136z-index: 10;
137font-size: 0.5em;
138padding: 2px;
139box-shadow: 1px 1px 1px $argo-color-gray-4;
140background-color: white;
141margin-left: 215px;
142
143.theme-dark & {
144box-shadow: 1px 1px 1px $argo-color-gray-7;
145}
146}
147
148&--pod {
149@include themify($themes) {
150background-color: themed('pod-cyan') !important;
151}
152}
153&--nodegroup{
154padding-left: 3.5em;
155padding-top: 25px;
156}
157
158&--lower-section {
159left: 8px;
160right: 10px;
161margin-top: 10px;
162margin-bottom: 10px;
163$pod-container-width: $pods-per-row * ($pod-size + (2 * $gutter)) + 4 * $gutter;
164$pod-container-height: $pods-per-column * ($pod-size + (2 * $gutter)) + 4 * $gutter;
165$padding: 1px;
166$stat-width: 1px;
167padding: $padding;
168transition: all 1s linear;
169position: absolute;
170
171&__pod-group {
172$pod-container-width: $pods-per-row * ($pod-size + (2 * $gutter)) + 4 * $gutter;
173$pod-container-height: $pods-per-column * ($pod-size + (2 * $gutter)) + 4 * $gutter;
174padding: $padding;
175width: $pod-container-width + 2 * $padding;
176
177&__label {
178margin-top: 1em;
179font-size: 10px;
180text-align: center;
181}
182&__pod-container {
183flex-direction: column;
184width: $pod-container-width;
185margin-top: auto;
186&__pods {
187display: flex;
188flex-wrap: wrap;
189width: 100%;
190background-color: $argo-color-gray-3;
191border-radius: 3px;
192align-items: center;
193padding: $gutter * 2;
194margin-right: -1 * $gutter;
195margin-bottom: -1 * $gutter;
196}
197}
198
199&__pod {
200border-radius: 3px;
201width: $pod-size;
202height: $pod-size;
203margin: $gutter;
204cursor: pointer;
205display: flex;
206align-items: center;
207justify-content: center;
208background-color: $argo-color-gray-5;
209transition: all 0.2s ease-in-out;
210i.fa {
211color: white !important;
212}
213&--succeeded,
214&--healthy {
215background-color: $argo-success-color;
216&:hover {
217background-color: $argo-success-color-dark;
218}
219}
220&--pending,
221&--suspended {
222background-color: $argo-status-warning-color;
223&:hover {
224background-color: darken($argo-status-warning-color, 10%);
225}
226}
227&--running,
228&--progressing {
229background-color: $argo-running-color;
230&:hover {
231background-color: $argo-running-color-dark;
232}
233}
234&--failed,
235&--degraded {
236background-color: $argo-failed-color;
237border: 2px solid rgba(0, 0, 0, 0.3);
238&:hover {
239background-color: $argo-failed-color-dark;
240}
241}
242&--unknown,
243&--missing {
244background-color: $argo-color-gray-5;
245&:hover {
246background-color: $argo-color-gray-6;
247}
248}
249&__star-icon {
250background: none;
251color: #ffce25;
252display: block;
253left: 20px;
254margin: 0px;
255position: absolute;
256top: -5px;
257}
258&__stat-tooltip {
259text-align: left;
260
261i {
262display: inline-block;
263height: 1em;
264width: 1em;
265border-radius: 5px;
266}
267}
268
269&__stat-icon-app {
270background-color: $argo-color-teal-7;
271}
272
273&__stat-icon-neighbors {
274background-color: $argo-color-gray-6;
275}
276
277&__stat {
278&__bar {
279background-color: $argo-color-gray-4;
280height: $max-rows * $pod-size;
281width: $stat-width;
282position: relative;
283border-radius: 2px;
284margin: 0 $gutter * 2;
285overflow: hidden;
286cursor: pointer;
287
288&--fill {
289position: absolute;
290background-color: $argo-color-teal-7;
291width: 100%;
292bottom: 0;
293}
294
295&--neighbors {
296background-color: $argo-color-gray-6;
297}
298
299&:hover > &--fill {
300background-color: $argo-color-teal-8;
301}
302
303&:hover &--neighbors {
304background-color: $argo-color-gray-7;
305}
306}
307}
308}
309}
310}
311}
312
313&__filtered-indicator {
314z-index: -1;
315}
316
317&__node-animation {
318position: absolute;
319left: 0;
320right: 0;
321top: 0;
322bottom: 0;
323animation: shadow-pulse 1s 1;
324}
325
326@keyframes shadow-pulse {
3270% {
328box-shadow: 0 0 0 0px rgba(0, 0, 0, 0.2);
329}
330100% {
331box-shadow: 0 0 0 15px rgba(0, 0, 0, 0);
332}
333}
334&__node-menu {
335position: absolute;
336right: 0px;
337top: 7px;
338}
339
340&__node-content {
341overflow: hidden;
342text-overflow: ellipsis;
343white-space: nowrap;
344}
345
346&__node-kind-icon {
347text-align: center;
348position: absolute;
349left: 0;
350top: 8px;
351width: 60px;
352line-height: 1;
353color: $argo-color-gray-7;
354
355&--big {
356background: $argo-color-gray-5;
357position: absolute;
358width: 65px;
359height: 65px;
360border-radius: 33px;
361left: -20px;
362top: -8px;
363text-align: center;
364
365@include themify($themes) {
366border: 4px solid themed('background-2');
367}
368
369i {
370color: $white-color;
371line-height: 56px;
372font-size: 28px;
373}
374}
375}
376
377&__node-labels {
378position: absolute;
379bottom: -14px;
380right: 0;
381}
382
383&__node-label {
384background-color: $argo-color-gray-4;
385color: $argo-color-gray-7;
386border: 1px solid $argo-color-gray-5;
387border-radius: 5px;
388padding: 0 5px;
389font-size: 0.6em;
390text-transform: lowercase;
391margin-right: 1px;
392}
393
394
395&__node-kind {
396font-size: 0.7em;
397color: $argo-color-gray-6;
398}
399
400&__node-content {
401padding: 10px 20px 10px 10px;
402line-height: 0.95;
403display: flex;
404flex-direction: column;
405}
406
407&__node-title {
408font-size: 0.8em;
409padding-bottom: 5px;
410overflow: hidden;
411text-overflow: ellipsis;
412text-align: left;
413
414}
415
416&__node-status-icon {
417font-size: 0.8em;
418i {
419margin-right: 2px;
420}
421}
422&__direction-left {
423direction: ltl;
424}
425&__direction-right {
426direction: rtl;
427}
428&__direction-center-left {
429overflow: hidden;
430padding-top: 15px;
431padding-left: 15px;
432
433}
434
435}