Skip to content

Commit d00906b

Browse files
committed
style: Refine Portal News TreeList Dark Theme Styling (#8788)
Refactor TreeList SCSS to use CSS variables for theming. Apply var(--white-off) for secondary content (dates, ticket titles) in Dark Theme. Unify secondary content color in Light Theme to rgba(0,0,0,0.8). Wrap ticket titles in span.ticket-title and align styling (font-size, margins) with release dates for consistency.
1 parent fd61293 commit d00906b

4 files changed

Lines changed: 25 additions & 3 deletions

File tree

apps/portal/model/Ticket.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ class Ticket extends Model {
4747
* @returns {String}
4848
*/
4949
calculate({id, isLeaf, title}) {
50-
return isLeaf ? `<b>${id}</b> ${title}` : id
50+
return isLeaf ? `<b>${id}</b> <span class="ticket-title">${title}</span>` : id
5151
}
5252
}]
5353
}

resources/scss/src/apps/portal/shared/content/TreeList.scss

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,10 @@
8787
overflow : hidden;
8888
text-overflow : ellipsis;
8989
white-space : nowrap;
90+
91+
b {
92+
color: var(--portal-treelist-bold-color, inherit);
93+
}
9094
}
9195
}
9296

@@ -127,17 +131,25 @@
127131
}
128132

129133
.release-date {
134+
color : var(--portal-treelist-meta-color, inherit);
130135
font-size : 90%;
131136
margin-left : 5px;
132-
opacity : 0.8;
133137
position : relative;
134138
top : -1px;
135139
}
136140

137141
.blog-date {
142+
color : var(--portal-treelist-meta-color, inherit);
138143
font-size : 90%;
139144
margin-right: 5px;
140-
opacity : 0.8;
145+
position : relative;
146+
top : -1px;
147+
}
148+
149+
.ticket-title {
150+
color : var(--portal-treelist-ticket-title-color, inherit);
151+
font-size : 90%;
152+
margin-left : 5px;
141153
position : relative;
142154
top : -1px;
143155
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
:root .neo-theme-neo-dark {
2+
--portal-treelist-bold-color : inherit;
3+
--portal-treelist-meta-color : var(--white-off);
4+
--portal-treelist-ticket-title-color: var(--white-off);
5+
}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
:root .neo-theme-neo-light {
2+
--portal-treelist-bold-color : inherit;
3+
--portal-treelist-meta-color : rgba(0, 0, 0, 0.8);
4+
--portal-treelist-ticket-title-color: rgba(0, 0, 0, 0.8);
5+
}

0 commit comments

Comments
 (0)