Skip to content

Commit

Permalink
feat: WikiList UI refinements
Browse files Browse the repository at this point in the history
  • Loading branch information
alex4401 committed Jul 25, 2024
1 parent 173d247 commit f4ca6a3
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 7 deletions.
35 changes: 28 additions & 7 deletions css/components/WikiList.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,25 @@
.site-list__qc > button {
height: 1.5em;
width: 1.5em;
display: flex;
align-items: center;
justify-content: center;
border: 1px solid color-mix(in srgb, var(--spacer-colour) 80%, #fff);
border-radius: 2px;
background-color: var(--spacer-colour);
}
.site-list__qc > button::after {
display: block;
width: 1.35em;
height: 1.35em;
content: '';
background: url(/icons/cdx/menu.svg) center / contain no-repeat;
filter: invert(1);
}
.site-list__qc > button:hover,
.site-list__qc--is-open > button {
border-color: color-mix(in srgb, var(--accent-colour) 50%, #fff);
background-color: color-mix(in srgb, var(--accent-colour) 20%, #555);
}
.site-list__qc:not( .site-list__qc--is-open ) > div {
display: none;
Expand Down Expand Up @@ -56,47 +74,50 @@
}


[data-component='WikiList'] .site-list__search-box {
.site-list__search-box {
width: 100%;
background: #bdc1c1aa;
border-radius: 4px;
border: 1px solid var( --spacer-colour );
margin-top: calc(-0.2rem - 1px);
margin-bottom: 0.3rem;
}
[data-component='WikiList'] .site-list__search-box > input {
.site-list__search-box > input {
appearance: none;
border: 0;
width: 100%;
height: 100%;
background: transparent;
padding: 0.3rem 0.6rem;
}
[data-component='WikiList'] > .site-list-wrapper > .site-list {
.site-list-wrapper > .site-list {
max-height: 350px;
overflow-y: auto;
font-size: 102%;
scrollbar-width: thin;
scrollbar-color: var(--accent-colour);
}
[data-component=WikiList] .site-list__entry {
.site-list__entry {
display: flex;
align-items: center;
padding: 0.15rem 0.2rem;
box-sizing: border-box;
}
[data-component=WikiList] .site-list__entry[data-is-filtered-out='true'] {
.site-list__entry[data-is-filtered-out='true'] {
height: 0px;
max-height: 0px;
overflow-y: clip;
padding: 0;
}
[data-component=WikiList] .site-list__entry > label {
.site-list__entry:hover {
background: #fff1;
}
.site-list__entry > label {
flex-grow: 1;
line-height: 1.2;
margin: 0 0.15rem;
}
[data-component=WikiList] .site-list__site-link {
.site-list__site-link {
display: block;
flex-basis: 12px;
flex-shrink: 0;
Expand Down
6 changes: 6 additions & 0 deletions icons/cdx/menu.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit f4ca6a3

Please sign in to comment.