discourse/plugins/discourse-post-voting/assets/stylesheets/common/post-voting.scss
2025-07-15 16:38:05 +02:00

298 lines
5.4 KiB
SCSS
Vendored

.post-voting-topic,
.post-voting-topic-sort-by-activity {
.time-gap,
.topic-post-visited-line,
.timeline-date-wrapper,
.timeline-last-read,
.timeline-ago {
display: none;
}
.time-gap + .topic-post,
.topic-post-visited + .topic-post {
.topic-avatar,
.topic-body {
border-top: 1px solid var(--primary-low);
}
}
.posts-filtered-notice:empty {
display: none;
}
}
.post-voting-answers-header {
box-sizing: border-box;
display: flex;
flex-direction: row;
padding: 0.5em;
.post-voting-answers-headers-count {
font-size: var(--font-up-1);
}
.post-voting-answers-headers-sort {
margin-left: auto;
.btn {
color: var(--primary-high);
border: 1px solid var(--primary-low-mid);
&:hover {
background-color: var(--primary-very-low);
}
+ .btn {
margin-left: 0.3em;
}
&:first-of-type {
margin-left: 0.5em;
}
}
.btn.active[disabled] {
background-color: var(--primary-low);
color: var(--primary);
opacity: 1;
cursor: default;
}
}
}
.rtl .qa-answers-header {
.qa-answers-headers-sort {
margin-left: unset;
margin-right: auto;
.btn {
+ .btn {
margin-left: 0;
margin-right: 0.3em;
}
&:first-of-type {
margin-left: 0;
margin-right: 0.5em;
}
}
}
}
.post-voting-comments {
width: 100%;
padding-top: 5px;
}
.post-voting-comment {
font-size: var(--font-down-1);
border-top: 1px solid var(--primary-low);
display: flex;
flex-direction: row;
align-items: flex-start;
padding: 0.7em 0;
word-break: break-word;
&.post-voting-comment-deleted {
background-color: var(--danger-low-mid);
}
.post-voting-comment-actions-vote {
margin-right: 0.5em;
display: inline-grid;
grid-auto-flow: column;
align-items: flex-start;
.post-voting-comment-actions-vote-count {
text-align: center;
width: auto;
min-width: 16px;
padding: 0.1em 0;
color: var(--primary-low-mid-or-secondary-high);
}
.btn {
font-size: var(--font-up-3);
background: none;
padding: 0;
&.post-voting-button-voted {
.d-icon {
color: var(--success);
}
}
}
}
.post-voting-comment-post {
.post-voting-comment-cooked {
p {
display: inline;
}
}
.post-voting-comment-info-separator {
margin: 0 0.3em;
}
.post-voting-comment-info-username {
display: inline;
margin-right: 0.3em;
}
.post-voting-comment-info-created,
.post-voting-comment-info-username-deleted {
color: var(--primary-med-or-secondary-med);
}
.post-voting-comment-actions {
display: none;
margin-left: 0.3em;
.post-voting-comment-actions-edit-link {
color: var(--primary-med-or-secondary-med);
margin-right: 0.25em;
}
.post-voting-comment-actions-delete-link {
color: var(--primary-med-or-secondary-med);
margin-right: 0.25em;
}
.post-voting-comment-actions-delete-link:hover {
color: var(--danger);
}
.post-voting-comment-actions-flag-link {
color: var(--primary-med-or-secondary-med);
}
.post-voting-comment-actions-flag-link:hover {
color: var(--danger);
}
}
}
.post-voting-comment-editor {
margin: 0.5em 0;
width: 100%;
textarea {
width: 100%;
margin-bottom: 0;
}
.post-voting-comment-editor-cancel {
margin-left: 0.5em;
}
}
&:hover {
.post-voting-comment-actions {
display: inline-block;
}
}
}
.post-voting-comment-composer {
width: 100%;
.post-voting-comment-composer-textarea {
width: 100%;
margin: 0.5em 0;
}
.post-voting-comment-composer-flash {
width: 100%;
color: var(--primary-med-or-secondary-med);
&.error {
color: var(--danger-hover);
}
margin-bottom: 0.5em;
}
}
.post-voting-comments-menu {
font-size: var(--font-down-1);
margin: 0;
.post-voting-comments-menu-composer-cancel {
margin-left: 0.5em;
}
.post-voting-comments-menu-separator {
margin: 0 0.8em;
display: inline;
&::after {
content: "|";
}
}
.post-voting-comments-menu-show-more,
.post-voting-comments-menu-add-link {
display: inline;
}
}
.post-voting-post {
position: relative;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
margin-top: 0.5em;
.post-voting-button {
padding-top: 0.1em;
padding-bottom: 0.1em;
font-size: var(--font-up-5);
}
.post-voting-post-list {
position: absolute;
z-index: 2;
background-color: var(--secondary);
border: 1px solid var(--primary-low);
box-shadow: var(--shadow-card);
display: flex;
flex-direction: column;
top: 4em;
padding: 0.5em;
max-width: 90vw;
overflow: auto;
.post-voting-post-list-voters-wrapper {
display: flex;
flex-direction: row;
}
}
.post-voting-post-list-voters {
display: flex;
a {
margin-left: 0.25em;
margin-bottom: 0.25em;
}
}
.post-voting-post-list-count,
.post-voting-post-list-icon {
margin: 0.15em 0.25em 0 0.25em;
font-size: var(--font-up-1);
color: var(--primary-low-mid);
}
.post-voting-button-voted {
.d-icon {
color: var(--success);
}
}
.post-voting-post-toggle-voters {
padding-top: 0;
padding-bottom: 0;
}
}