UX: hide settings btn when disabled
Also sets lighter border on hover
This commit is contained in:
parent
64971e5972
commit
74f01b8cbd
|
@ -2,8 +2,8 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
padding: 0.5rem;
|
padding: 0.5rem;
|
||||||
border-radius: 6px;
|
border-radius: 4px;
|
||||||
background-color: var(--d-selected);
|
background-color: var(--primary-very-low);
|
||||||
border: 1px solid transparent;
|
border: 1px solid transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@
|
||||||
.touch & {
|
.touch & {
|
||||||
&:active {
|
&:active {
|
||||||
background-color: var(--d-hover);
|
background-color: var(--d-hover);
|
||||||
border: 1px solid var(--primary-medium);
|
border: 1px solid var(--primary-300);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@
|
||||||
&:hover,
|
&:hover,
|
||||||
&:active {
|
&:active {
|
||||||
background-color: var(--d-hover);
|
background-color: var(--d-hover);
|
||||||
border: 1px solid var(--primary-medium);
|
border: 1px solid var(--primary-300);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,6 +41,10 @@
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&__settings[disabled] {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
&__open-button {
|
&__open-button {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
||||||
.chat-thread-list-item {
|
.chat-thread-list-item {
|
||||||
margin: 0.5rem 0.25rem 0.5rem 0.5rem;
|
margin: 0.75rem 0.25rem 0.75rem 0.5rem;
|
||||||
|
|
||||||
& + .chat-thread-list-item {
|
& + .chat-thread-list-item {
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
|
|
|
@ -108,12 +108,12 @@ describe "Thread list in side panel | full page", type: :system, js: true do
|
||||||
it "does not allow updating if user is neither admin nor original message user" do
|
it "does not allow updating if user is neither admin nor original message user" do
|
||||||
thread_1.update!(original_message_user: other_user)
|
thread_1.update!(original_message_user: other_user)
|
||||||
thread_1.original_message.update!(user: other_user)
|
thread_1.original_message.update!(user: other_user)
|
||||||
|
|
||||||
open_thread_list
|
open_thread_list
|
||||||
expect(
|
|
||||||
thread_list_page.item_by_id(thread_1.id).find(".chat-thread-list-item__settings")[
|
expect(thread_list_page.item_by_id(thread_1.id)).to have_no_css(
|
||||||
:disabled
|
".chat-thread-list-item__settings",
|
||||||
],
|
)
|
||||||
).to eq("true")
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue