daggerheart/styles/less/global/chat.less
Carlos Fernandez d76b4bb707
Some checks are pending
Project CI / build (24.x) (push) Waiting to run
Fix chat being jumpy as timestamps get longer (#2095)
2026-07-18 11:42:50 +02:00

157 lines
4.7 KiB
Text

@import '../utils/colors.less';
@import '../utils/fonts.less';
@import '../utils/mixin.less';
.daggerheart.chat-sidebar.theme-light,
#interface.theme-light {
.chat-log .chat-message {
background-image: url('../assets/parchments/dh-parchment-light.png');
.message-header .message-header-main .message-metadata,
.message-header .message-header-main .name {
color: @dark;
}
.message-header .message-header-main h4 {
color: @dark-blue;
}
.message-content {
.table-draw {
.table-description {
color: @dark;
}
}
}
}
}
#chat-message {
font-family: @font-body;
padding: 8px;
}
.vtt.stream.system-daggerheart .chat-sidebar,
.daggerheart.chat-sidebar,
#chat-notifications {
.chat-log {
.chat-message {
border: none !important;
padding: 0;
background-image: url('../assets/parchments/dh-parchment-dark.png');
.message-header {
display: flex;
gap: 8px;
padding: 8px;
align-items: center;
.portrait {
flex: 0 0 auto;
.actor-img {
border-radius: 50%;
width: 40px;
height: 40px;
object-fit: cover;
object-position: top center;
}
}
.message-header-main {
display: flex;
align-items: center;
column-gap: 4px;
row-gap: 2px;
flex: 1;
overflow: hidden;
display: grid;
grid-template:
"title metadata"
"subtitle subtitle";
h4 {
font-size: var(--font-size-16);
font-weight: bold;
margin-bottom: 0;
font-family: @font-subtitle;
color: @golden;
white-space: nowrap;
text-overflow: ellipsis;
flex: 1;
overflow: hidden;
align-self: flex-end;
}
.message-metadata {
font-family: @font-body;
color: @beige;
white-space: nowrap;
align-items: baseline;
.message-timestamp {
font-size: var(--font-size-11);
}
}
.subtitle {
grid-area: subtitle;
flex: 1;
display: flex;
justify-content: space-between;
color: @beige;
gap: 4px;
align-items: baseline;
line-height: 1;
.name {
flex: 1;
}
.whisper-to {
color: @color-text-subtle;
flex: 0;
white-space: nowrap;
}
}
}
}
.message-content {
padding-bottom: 8px;
.flavor-text {
font-size: var(--font-size-12);
line-height: 20px;
color: light-dark(@dark, @beige);
text-align: center;
display: block;
}
.table-draw {
.table-flavor {
padding-top: 5px;
padding-bottom: 0.5rem;
font-size: var(--font-size-12);
}
.table-description {
color: @beige;
font-style: italic;
&.flavor-spaced {
padding-top: 0;
}
}
.table-results {
.description {
flex-basis: min-content;
> p:first-of-type {
margin-top: 0;
}
}
}
}
}
}
}
}