Skip to content

Commit 33f62d9

Browse files
authored
Merge pull request #160 from a8cteam51/fix/gh147-improve-dashboard-widget
Created new dashboard widget with own tempalte file and scss file
2 parents e3f5424 + ebd37db commit 33f62d9

10 files changed

Lines changed: 380 additions & 187 deletions

File tree

assets/css/build/style-style.scss.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 123 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,123 @@
1+
.wlf_dashboard {
2+
&-wrapper {
3+
margin: -12px;
4+
padding: 0;
5+
}
6+
&-status {
7+
&-section {
8+
padding: 12px;
9+
border-bottom: 1px solid #e5e5e5;
10+
&:last-child {
11+
border-bottom: none;
12+
}
13+
}
14+
&-indicator {
15+
display: inline-block;
16+
width: 10px;
17+
height: 10px;
18+
border-radius: 50%;
19+
margin-right: 8px;
20+
&.online {
21+
background-color: #46b450;
22+
}
23+
&.offline {
24+
background-color: #dc3232;
25+
}
26+
}
27+
}
28+
&-stats {
29+
&-grid {
30+
display: grid;
31+
grid-template-columns: repeat(2, 1fr);
32+
gap: 12px;
33+
}
34+
&-box {
35+
background: #f8f9fa;
36+
padding: 12px;
37+
border-radius: 4px;
38+
text-align: center;
39+
}
40+
&-number,
41+
&-ratio {
42+
font-size: 28px;
43+
font-weight: 600;
44+
color: #1d2327;
45+
line-height: 1.3;
46+
}
47+
&-label {
48+
color: #50575e;
49+
font-size: 13px;
50+
margin-top: 4px;
51+
}
52+
}
53+
&-section {
54+
&-title {
55+
font-size: 14px;
56+
font-weight: 600;
57+
color: #1d2327;
58+
margin: 0 12px 8px;
59+
padding-bottom: 8px;
60+
border-bottom: 1px solid #e5e5e5;
61+
}
62+
}
63+
&-features {
64+
display: grid;
65+
grid-template-columns: repeat(2, 1fr);
66+
gap: 12px;
67+
padding: 12px;
68+
&-item {
69+
display: flex;
70+
align-items: flex-start;
71+
gap: 8px;
72+
padding: 8px;
73+
background: #f8f9fa;
74+
border-radius: 4px;
75+
}
76+
&-content {
77+
flex: 1;
78+
}
79+
&-status {
80+
display: inline-flex;
81+
align-items: center;
82+
justify-content: center;
83+
width: 20px;
84+
height: 20px;
85+
border-radius: 50%;
86+
flex-shrink: 0;
87+
&.enabled {
88+
background: #edfaef;
89+
color: #46b450;
90+
}
91+
&.disabled {
92+
background: #fef1f1;
93+
color: #d63638;
94+
}
95+
}
96+
&-label {
97+
font-size: 13px;
98+
color: #50575e;
99+
}
100+
&-description {
101+
font-size: 12px;
102+
color: #757575;
103+
margin-top: 2px;
104+
}
105+
}
106+
&-warning {
107+
color: #d63638;
108+
padding: 12px;
109+
background: #fcf0f1;
110+
border-left: 4px solid #d63638;
111+
margin: 0 0 12px 0;
112+
}
113+
&-navigation {
114+
padding: 12px;
115+
background: #f0f0f1;
116+
display: flex;
117+
gap: 10px;
118+
justify-content: flex-end;
119+
a {
120+
text-decoration: none;
121+
}
122+
}
123+
}

assets/css/src/admin/_events.scss

Lines changed: 0 additions & 43 deletions
This file was deleted.

assets/css/src/admin/_main.scss

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,8 @@
8181
background-color: #e6e6e6;
8282
}
8383

84-
// Create css colours for each http code.
85-
@import "meta_box_runner.scss";
84+
// Import admin styles
8685
@import "settings.scss";
87-
@import "events.scss";
8886
@import "report_list.scss";
89-
@import "wizard.scss";
87+
@import "wizard.scss";
88+
@import "dashboard";

0 commit comments

Comments
 (0)