123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310 |
- /* The MIT License */
- $preview-width: 200px;
- $preview-height: 150px;
- .dropzone {
- position: relative;
- border-radius: $form-border-radius;
- min-height: 4rem;
- &.dz-clickable {
- cursor: pointer;
- }
- &.dz-drag-hover {
- border-color: rgba(0,0,0,0.15);
- background: rgba(0,0,0,0.04);
- }
- &.dz-started .dz-message {
- display: none;
- }
- .dz-message {
- opacity: 1;
- -ms-filter: none;
- filter: none;
- }
- .dz-preview {
- position: relative;
- display: inline-block;
- margin: 1rem 1rem 1.5rem 1rem;
- vertical-align: top;
- &.dz-file-preview [data-dz-thumbnail] {
- display: none;
- }
- &.dz-error .dz-error-mark {
- display: block;
- }
- &.dz-success .dz-success-mark {
- display: block;
- }
- .dz-success-mark, .dz-error-mark {
- font-family: FontAwesome;
- display: none;
- position: absolute;
- width: 22px;
- height: 22px;
- font-size: 18px;
- line-height: 25px;
- border-radius: 100%;
- text-align: center;
- right: 2px;
- top: 2px;
- span {
- display: none;
- }
- }
- &:hover {
- .dz-success-mark, .dz-error-mark {
- display: none;
- }
- }
- .dz-success-mark {
- &::after {
- content: '\f00c';
- }
- }
- .dz-error-mark {
- &::after {
- content: '\f12a';
- }
- }
- .dz-progress {
- position: absolute;
- top: $preview-height;
- left: 0px;
- right: 0px;
- height: 4px;
- display: none;
- .dz-upload {
- display: block;
- position: absolute;
- top: 0;
- bottom: 0;
- left: 0;
- width: 0%;
- }
- }
- .dz-error-message {
- display: none;
- position: absolute;
- top: 0;
- left: 0;
- right: 0;
- font-size: 0.9rem;
- line-height: 1.2;
- padding: 8px 10px;
- z-index: 500;
- }
- &.dz-processing .dz-progress {
- display: block;
- }
- &:hover {
- .dz-remove, .dz-unset, .dz-view, .dz-insert, .dz-metadata {
- display: block;
- }
- }
- &:hover.dz-error .dz-error-message {
- display: block;
- }
- //.dz-remove, .dz-unset, .dz-insert {
- // display: none;
- //}
- .dz-filename {
- position: absolute;
- z-index: 1;
- bottom: 0;
- width: 100%;
- padding: 0 5px;
- background: rgba(0,0,0,0.3);
- color: #fff;
- text-align: center;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
- .dz-remove, .dz-unset, .dz-view, .dz-insert, .dz-metadata {
- display: none;
- position: absolute;
- width: 25px;
- height: 25px;
- right: -25px;
- font-size: 0;
- cursor: pointer;
- &:hover {
- &:after {
- color: #fff;
- }
- }
- &:after {
- text-align: center;
- display: block;
- color: #999;
- font-family: FontAwesome;
- font-size: 18px;
- line-height: 25px;
- }
- }
- .dz-insert {
- top: -1px;
- border-top-right-radius: 4px;
- &:after {
- content: '\f055';
- }
- }
- .dz-view {
- top: 24px;
- &:after {
- content: '\f06e';
- }
- }
- .dz-remove {
- top: 72px;
- &:after {
- content: '\f1f8';
- }
- }
- .dz-unset {
- top: 96px;
- border-bottom-right-radius: 4px;
- &:after {
- content: '\f00d';
- }
- }
-
- .dz-metadata {
- top: 49px;
- &:after {
- content: '\f05a';
- }
- }
- &.dz-no-editor {
- .dz-view {
- top: -1px;
- border-top-right-radius: 4px;
- }
- .dz-remove {
- top: 24px;
- }
- .dz-unset {
- top: 72px;
- }
- }
- //&:hover .dz-remove, .dz-unset:not(.file-thumbnail-remove), &:hover .dz-insert {
- // display: block;
- // position: absolute;
- // left: 0;
- // right: 0;
- // bottom: 22px;
- // width: 50%;
- // text-align: center;
- // cursor: pointer;
- // font-size: 0.8rem;
- //}
- &:hover .dz-remove, &:hover .dz-unset {
- &.file-thumbnail-remove {
- display: block;
- }
- &:not(.file-thumbnail-remove) {
- left: inherit;
- border-left: 0;
- }
- }
- //&:hover .dz-insert {
- // right: inherit;
- //}
- //
- //&.hide-backface:hover {
- // .dz-remove, .dz-unset, .dz-insert {
- // display: none;
- // }
- //}
- &.dz-processing {
- .dz-details {
- overflow: hidden;
- img {
- //position: absolute;
- //left: 50%;
- //top: 50%;
- //height: auto;
- //width: 100%;
- //-webkit-transform: translate(-50%,-50%);
- //-ms-transform: translate(-50%,-50%);
- //transform: translate(-50%,-50%);
- }
- }
- }
- .dz-details {
- width: $preview-width;
- height: $preview-height;
- position: relative;
- font-size: 0.8rem;
- img {
- position: absolute;
- object-fit: contain;
- top: 0;
- left: 0;
- width: $preview-width;
- height: $preview-height;
- }
- .dz-size {
- position: absolute;
- bottom: -28px;
- left: 0;
- right: 0;
- text-align: center;
- font-size: 0.8rem;
- height: 28px;
- line-height: 28px;
- }
- }
- }
- &.dz-clickable {
- .dz-message, .dz-message span {
- cursor: pointer;
- text-align: center;
- font-size: 1.2rem;
- line-height: 1.4;
- margin: 1rem 0;
- }
- }
- * {
- cursor: default;
- }
- }
|