0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-30 19:00:10 -05:00
penpot/frontend/resources/styles/main/partials/sidebar-layers.scss

193 lines
2.9 KiB
SCSS
Raw Normal View History

2016-03-01 20:39:13 +02:00
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
2020-03-24 14:38:13 +01:00
// Copyright (c) 2015-2020 Andrey Antukh <niwi@niwi.nz>
// Copyright (c) 2015-2020 Juan de la Cruz <delacruzgarciajuan@gmail.com>
2016-03-01 20:39:13 +02:00
2020-03-24 14:38:13 +01:00
.element-list-body {
align-items: center;
2016-02-14 20:37:01 +01:00
display: flex;
2020-03-24 14:38:13 +01:00
height: 35px;
padding: $x-small $small;
transition: none;
2016-02-14 20:37:01 +01:00
width: 100%;
2020-03-24 14:38:13 +01:00
svg {
fill: $color-gray-20;
height: 13px;
flex-shrink: 0;
margin-right: 8px;
width: 13px;
}
&.group {
&.open {
.toggle-content {
flex-shrink: 0;
2016-03-11 21:04:26 +01:00
svg {
transform: rotate(270deg);
}
}
2016-02-14 20:37:01 +01:00
}
}
2020-03-24 14:38:13 +01:00
&:hover {
background-color: $color-primary;
svg {
fill: $color-gray-60 !important;
}
2020-03-24 14:38:13 +01:00
.element-icon,
.element-actions {
svg {
fill: $color-gray-60;
2016-02-14 20:37:01 +01:00
}
}
2020-03-24 14:38:13 +01:00
.element-actions > * {
2016-02-14 20:37:01 +01:00
display: flex;
2020-03-24 14:38:13 +01:00
}
span {
color: $color-gray-60;
}
.toggle-content {
margin-left: $x-small;
2016-02-14 20:37:01 +01:00
svg {
2020-03-03 13:14:37 +01:00
fill: $color-gray-60;
2016-02-14 20:37:01 +01:00
}
2020-03-24 14:38:13 +01:00
}
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
&.selected {
svg {
fill: $color-primary;
}
.element-icon {
svg {
fill: $color-primary;
2016-02-14 20:37:01 +01:00
}
2020-03-24 14:38:13 +01:00
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
span {
color: $color-primary;
}
&:hover {
background-color: $color-primary;
.element-icon,
.element-actions {
2016-02-14 20:37:01 +01:00
svg {
2020-03-24 14:38:13 +01:00
fill: $color-gray-60;
2016-02-14 20:37:01 +01:00
}
}
2020-03-24 14:38:13 +01:00
.element-name {
color: $color-gray-60;
2016-02-14 20:37:01 +01:00
}
2020-03-24 14:38:13 +01:00
}
}
&.drag-top {
border-top: 40px solid $color-gray-60 !important;
}
&.drag-bottom {
border-bottom: 40px solid $color-gray-60 !important;
}
&.drag-inside {
border: 2px solid $color-primary !important;
}
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
.element-icon {
svg {
fill: $color-gray-30;
}
}
2016-08-31 17:22:27 +03:00
2020-03-24 14:38:13 +01:00
input.element-name {
max-width: 130px;
width: 100%;
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
span.element-name {
color: $color-gray-20;
display: block;
font-size: $fs13;
max-width: 130px;
min-width: 40px;
min-height: 16px;
overflow-x: hidden;
text-overflow: ellipsis;
white-space: nowrap;
width: 100%;
}
.element-actions {
display: flex;
flex-shrink: 0;
height: 14px;
margin-left: auto;
position: relative;
width: 32px;
> * {
display: none;
}
.toggle-element,
.block-element {
left: 0;
position: absolute;
top: 0;
2019-12-16 14:19:25 +01:00
2020-03-24 14:38:13 +01:00
&.selected {
display: flex;
2016-02-14 20:37:01 +01:00
svg {
2020-03-03 13:14:37 +01:00
fill: $color-gray-20;
2016-02-14 20:37:01 +01:00
}
2020-03-24 14:38:13 +01:00
}
}
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
.block-element {
left: 18px !important;
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
svg {
fill: $color-gray-30;
}
}
2016-02-14 20:37:01 +01:00
2020-03-24 14:38:13 +01:00
.toggle-content {
margin-left: auto;
width: 12px;
svg {
fill: $color-gray-30;
transform: rotate(90deg);
width: 10px;
}
&.inverse {
svg { transform: rotate(270deg); }
}
&:hover {
svg {
fill: $color-gray-60;
2016-02-14 20:37:01 +01:00
}
}
2020-03-24 14:38:13 +01:00
}