taiga-front/app/styles/modules/common/attachments.scss

157 lines
3.3 KiB
SCSS

.attachments {
margin-bottom: 2rem;
}
.attachments-header {
background: $whitish;
@include clearfix;
padding: .5rem 1rem;
.button {
float: right;
}
.icon,
.attachments-num,
.attachments-text {
@extend %medium;
margin-right: .5rem;
position: relative;
top: 2px;
}
}
.single-attachment {
@include table-flex();
@extend %small;
align-items: center;
border-bottom: 1px solid #cdcdcd;
padding: 1rem 0 1rem 1rem;
position: relative;
&:last-child {
border: 0;
}
&:hover {
.attachment-settings {
.settings {
@include transition (opacity .2s ease-in);
opacity: 1;
}
}
}
&.ui-sortable-helper {
@include transition (background .2s ease-in);
background: lighten($green-taiga, 60%);
box-shadow: 1px 1px 10px rgba($black, .1);
}
&.deprecated {
color: $gray-light;
.attachment-name a {
color: $gray-light;
}
}
.attachment-name {
@include ellipsis(200px);
@include table-flex-child(1, 300px);
@extend %bold;
padding-right: 1rem;
.icon {
margin-right: .5rem;
}
}
.attachment-size {
@include table-flex-child(1, 100px);
color: $gray-light;
margin-right: .5rem;
}
.attachment-comments {
@include table-flex-child(10, 300px);
}
.attachment-settings {
@include table-flex-child(1, 100px);
.settings {
@extend %large;
color: $gray-light;
display: block;
opacity: 0;
position: absolute;
top: 1rem;
&:hover {
color: $green-taiga;
}
}
.icon-edit {
right: 4rem;
}
.icon-delete {
right: 2rem;
&:hover {
color: $red;
}
}
.icon-drag-v {
cursor: move;
right: 0;
}
}
// REFACTOR //
.editable {
@include table-flex-child(10, 300px);
}
.attachment-delete {
@include table-flex-child(1, 10px);
}
.icon-delete {
@extend %large;
color: $gray-light;
&:hover {
color: $red;
}
}
.editable-attachment-deprecated {
padding-left: 1rem;
span {
color: $gray-light;
}
input {
margin-right: .5rem;
&:checked {
+ span {
color: $grayer;
}
}
}
}
.editable-attachment-comment {
input {
color: $white;
}
}
&.edit {
.settings,
.attachment-comment {
display: none;
}
.editable {
display: block;
}
}
}
.more-attachments {
@extend %small;
border-bottom: 1px solid $gray-light;
display: block;
padding: 1rem 0 1rem 1rem;
span {
color: $gray-light;
}
.more-attachments-num {
color: $green-taiga;
margin-left: .5rem;
}
&:hover {
@include transition (background .2s ease-in);
background: lighten($green-taiga, 60%);
}
}