mirror of
https://github.com/zotero/zotero.git
synced 2026-10-08 03:08:19 +00:00
Semantic similarity has no natural relevance threshold, so instead of asking the user to pick an arbitrary result count, show every scored item and surface the ranking directly: a Relevance column appears and becomes the sort while a best-match search is active, and the previous sort and columns return when it clears. The merged results are scored in a single pass in the row provider, so ranks are global across a multi-collection selection, child items (attachments, notes, annotations) rank via their top-level item, and equal scores get equal ranks that order deterministically via the secondary sort fields. Items without a stored embedding are filtered out. Each cell renders the score's position within the model's display range as a bar, so relevant results read as full and the irrelevant tail reads as empty. The ranges are provisional per-model display constants. Sorting uses the ranks, which are also exposed to assistive technology and as the cell tooltip. On a focused selected row the bar switches to white so the fill doesn't vanish into the accent selection background.
58 lines
862 B
SCSS
58 lines
862 B
SCSS
.icon > svg, .icon > img {
|
|
width: 16px;
|
|
}
|
|
|
|
.icon-bg {
|
|
width: 16px;
|
|
height: 16px;
|
|
display: inline-block;
|
|
background-repeat: no-repeat;
|
|
background-size: contain;
|
|
background-position: center;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.icon-css {
|
|
display: inline-block;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.icon {
|
|
-moz-appearance: none !important;
|
|
}
|
|
|
|
.icon-20 {
|
|
width: 20px;
|
|
height: 20px;
|
|
}
|
|
|
|
.icon-16 {
|
|
width: 16px;
|
|
height: 16px;
|
|
}
|
|
|
|
.icon-8 {
|
|
width: 8px;
|
|
height: 8px;
|
|
}
|
|
|
|
$-icons: (
|
|
attachment: 16,
|
|
chevron-6: 8,
|
|
filter: 16,
|
|
list-number: 16,
|
|
note: 16,
|
|
x-8: 16,
|
|
play: 16,
|
|
pause: 16,
|
|
// attachment-annotations: 16,
|
|
chevron-tabs: 20
|
|
);
|
|
|
|
@each $icon, $size in $-icons {
|
|
.icon-#{$icon} {
|
|
fill: var(--fill-secondary);
|
|
background: url('chrome://zotero/skin/#{$size}/universal/#{$icon}.svg') content-box no-repeat;
|
|
-moz-context-properties: fill, fill-opacity;
|
|
}
|
|
}
|