0
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2026-08-06 05:42:36 +08:00
discourse/app/assets/stylesheets/common/post-action-feedback.scss
Kris 891a50ef65
UX: update new reviewable style, add permalink, nav, link posts (#35768)
This updates some new reviewable styles and adds some functionality... 

Permalink copy button: 
<img width="362" height="202" alt="image"
src="https://github.com/user-attachments/assets/010354d7-a61f-4e51-b674-c77ed5dd0857"
/>

Edit count:
<img width="1514" height="278" alt="image"
src="https://github.com/user-attachments/assets/3a91b97c-0a04-4c55-88cb-86700dc72153"
/>

Removed icons from the Insights menu to simplify a little... also
linking the count of the user's post for easy access
<img width="1506" height="932" alt="image"
src="https://github.com/user-attachments/assets/e19f3ec1-285b-40a7-84a0-f0003718f627"
/>

(before)
<img width="763" height="471" alt="image"
src="https://github.com/user-attachments/assets/b7c6c5a4-9bbc-4a37-91e0-bcf69d96c6cc"
/>


Persistent nav for all tabs:
<img width="2188" height="476" alt="image"
src="https://github.com/user-attachments/assets/b322db14-dfa7-4325-afbb-08f39f01ce51"
/>

Also fixed pre/code content so it scroll on overflow instead of wrapping
(to more closely match the post styles)
2025-11-03 17:36:08 -05:00

75 lines
1.2 KiB
SCSS
Vendored

@keyframes draw {
to {
stroke-dashoffset: 0;
}
}
.post-action-feedback-button {
position: relative;
height: 100%;
&.--activated,
&.--activated:hover {
.d-icon-d-post-share {
color: var(--success);
}
}
}
.post-action-feedback-svg {
position: absolute;
bottom: 0;
right: 0;
width: 20px;
height: 20px;
display: block;
stroke: var(--success);
opacity: 0;
path {
stroke: var(--success);
stroke-width: 4;
stroke-dasharray: 100;
stroke-dashoffset: 100;
animation: draw 1s forwards;
}
}
.post-action-feedback-alert {
position: absolute;
top: -1.5rem;
left: 60%;
transform: translateX(-50%);
color: var(--success);
padding: 0.25rem 0.5rem;
white-space: nowrap;
font-size: var(--font-down-2);
opacity: 0;
z-index: calc(z("timeline") + 1);
}
.--transition {
.post-action-feedback-alert,
.post-action-feedback-svg {
transition:
opacity 0.25s,
color 0.25s;
}
}
.--activated {
.post-action-feedback-alert,
.post-action-feedback-svg {
opacity: 1;
}
.post-action-feedback-alert {
&.-success {
color: var(--success);
}
&.-fail {
color: var(--danger);
}
}
}