mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 06:39:48 +00:00
Drag handles on environment sidebar (Closes #982)
This commit is contained in:
parent
6519274a9d
commit
1e72f5270a
@ -51,6 +51,7 @@ const SidebarListItem = SortableElement(({environment, activeEnvironment, showEn
|
||||
return (
|
||||
<li key={environment._id} className={classes}>
|
||||
<Button onClick={showEnvironment} value={environment}>
|
||||
<i className="fa fa-drag-handle drag-handle"/>
|
||||
{environment.color
|
||||
? <i className="space-right fa fa-circle" style={{color: environment.color}}/>
|
||||
: <i className="space-right fa fa-empty"/>
|
||||
|
@ -91,6 +91,14 @@
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
position: relative;
|
||||
.drag-handle {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
opacity: 0;
|
||||
color: var(--hl-lg)
|
||||
}
|
||||
|
||||
.editable {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
@ -112,6 +120,11 @@
|
||||
&:hover > button {
|
||||
background-color: @hl-xs;
|
||||
}
|
||||
|
||||
&.env-modal__sidebar-item--dragging .drag-handle,
|
||||
&:hover .drag-handle {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.env-modal__sidebar-item {
|
||||
|
@ -645,6 +645,11 @@ i.fa:not(.fa--skinny) {
|
||||
}
|
||||
}
|
||||
|
||||
.fa-drag-handle:before {
|
||||
content: "\f142\f142";
|
||||
letter-spacing: 0.1em;
|
||||
}
|
||||
|
||||
.bold,
|
||||
strong {
|
||||
font-weight: 600;
|
||||
|
Loading…
Reference in New Issue
Block a user