mirror of
https://github.com/zadam/trilium.git
synced 2026-01-05 22:24:25 +01:00
chore(badges): allow overflow with clipping
This commit is contained in:
parent
89ef38ba97
commit
2fef25e57b
@ -16,6 +16,13 @@
|
|||||||
&.share-badge {--color: var(--badge-share-background-color);}
|
&.share-badge {--color: var(--badge-share-background-color);}
|
||||||
&.clipped-note-badge {--color: var(--badge-clipped-note-background-color);}
|
&.clipped-note-badge {--color: var(--badge-clipped-note-background-color);}
|
||||||
&.execute-badge {--color: var(--badge-execute-background-color);}
|
&.execute-badge {--color: var(--badge-execute-background-color);}
|
||||||
|
min-width: 0;
|
||||||
|
|
||||||
|
.text {
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-badge {
|
.dropdown-badge {
|
||||||
|
|||||||
@ -50,16 +50,30 @@
|
|||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
border-radius: var(--badge-radius);
|
border-radius: var(--badge-radius);
|
||||||
|
|
||||||
|
button,
|
||||||
|
.btn {
|
||||||
|
min-width: 0;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
.ext-badge {
|
.ext-badge {
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
|
|
||||||
.text {
|
.text {
|
||||||
display: inline-flex;
|
display: inline-flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
min-width: 0;
|
||||||
|
|
||||||
|
.text-inner {
|
||||||
|
min-width: 0;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
.arrow {
|
.arrow {
|
||||||
font-size: 1.3em;
|
font-size: 1.3em;
|
||||||
margin-left: 0.25em;
|
margin-inline-start: 0.25em;
|
||||||
|
margin-inline-end: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -60,7 +60,10 @@ export function BadgeWithDropdown({ text, children, tooltip, className, dropdown
|
|||||||
<Dropdown
|
<Dropdown
|
||||||
className={`dropdown-badge dropdown-${className}`}
|
className={`dropdown-badge dropdown-${className}`}
|
||||||
text={<Badge
|
text={<Badge
|
||||||
text={<>{text} <Icon className="arrow" icon="bx bx-chevron-down" /></>}
|
text={<>
|
||||||
|
<span class="text-inner">{text}</span>
|
||||||
|
<Icon className="arrow" icon="bx bx-chevron-down" />
|
||||||
|
</>}
|
||||||
className={className}
|
className={className}
|
||||||
{...props}
|
{...props}
|
||||||
/>}
|
/>}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user