You are here

style.css in Fine Image Upload 8

Same filename and directory in other branches
  1. 8.2 css/style.css
.fiu-wrapper:after {
  content: " ";
  display: block;
  width: 1px;
  height: 1px;
  clear: both;
}

.fiu-wrapper > .messages {
  float: none;
}

.fiu-add-element {
  position: relative;
  float: left;
  width: 180px;
  height: 120px;
  margin: 5px;
  background-color: #eee;
}

.fiu-add-element .form-item .description {
  display: none;
  position: absolute;
  bottom: calc(100% + 15px);
  left: 50%;
  width: 100%;
  margin: 0;
  padding: 5px;
  box-shadow: 0 0 3px 0 rgba(0, 0, 0, .25);
  border-radius: 4px;
  background-color: rgba(0, 0, 0, .8);
  color: #fff;
  font-size: 12px;
  transform: translateX(-50%);
  z-index: 99;
}

.fiu-add-element .form-item .description:before {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -20px;
  width: 0;
  height: 0;
  margin: 0;
  border: 10px solid transparent;
  border-top: 10px solid rgba(0, 0, 0, .8);
  transform: translateX(-50%);
}

.fiu-add-element:hover .description {
  display: block;
}

.fiu-add-element input[type="file"] {
  height: 0;
  opacity: 0;
  overflow: hidden;
  position: absolute;
  width: 0;
  z-index: -1;
}

.fiu-add-element .form-type-managed-file {
  height: 120px;
  margin: 0;
  position: relative;
  width: 100%;
}

.fiu-add-element .form-type-managed-file label {
  align-items: center;
  background-color: #eee;
  color: #000;
  cursor: pointer;
  display: flex;
  font-size: 1.25em;
  font-weight: 700;
  height: 120px;
  justify-content: center;
  left: 0;
  position: absolute;
  top: 0;
  width: 100%;
}

.fiu-add-element .form-type-managed-file--advanced label {
  background-image: url(/modules/fiu/icons/upload.svg);
  background-position: center 30px;
  background-repeat: no-repeat;
  background-size: 40px;
  font-size: 1em;
  height: 60px;
  padding-top: 60px;
}

.fiu-add-element .form-type-managed-file--advanced.is-dragover label {
  background-color: #ddd;
}

.fiu-add-element:focus label,
.fiu-add-element label:hover {
  outline: none;
}

.fiu-add-element label * {
  pointer-events: none;
}

.field--widget-fine-image .messages--status,
.fiu-add-element .messages,
.fiu-wrapper .fiu-image-info {
  display: none;
}

.mfp-inline-holder .mfp-content {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  align-items: stretch;
  width: 90%;
  height: 70%;
  transform: translate(-50%, -50%);
}

.fiu-full-image {
  position: relative;
  width: 100%;
}

.fiu-full-image .mfp-close {
  right: 20%;
  margin: 10px;
  width: 32px;
  height: 32px;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: 50%;
  background-color: rgba(0, 0, 0, .25);
  color: #fff;
  font-size: 28px;
  line-height: 32px;
}

.fiu-full-image img {
  display: block;
  width: 80%;
  height: auto;
  object-fit: cover;
  float: left;
}
.fiu-img-description {
  width: 20%;
  float: left;
}
.mfp-content .inner-fiu-full-image ul {
  margin: 0 0 0 30px;
  padding: 0;
  list-style: none;
  color: #ddd;
}
.inner-fiu-full-image .attr {
  margin: 0 0 0 30px;
  display: block;
}
.inner-fiu-full-image .attr label {
  color: #eee;
}
.inner-fiu-full-image .attr .description {
  color: #ddd;
}
.item-list ul.fiu-sortable-list {
  position: relative;
  margin: 0;
  padding: 0;
  list-style: none;
}

.item-list ul.fiu-sortable-list li {
  float: left;
  width: 180px;
  height: 120px;
  overflow: hidden;
  margin: 5px;
  list-style: none;
}

ul.fiu-sortable-list li > .form-type-select {
  display: none;
}

.fine-image-widget {
  position: relative;
}

.fine-image-preview {
  position: relative;
  width: 100%;
  height: 120px;
}

.fine-image-preview img {
  background: #eee;
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fine-image-data {
  position: absolute;
  top: 10px;
  right: 0;
  display: flex;
  justify-content: space-between;
  width: 100%;
}

.fiu-broken-file input.form-submit[value="Remove selected"],
.fine-image-data .button[value="Remove"],
.fiu-image-details {
  display: inline-block;
  width: 24px;
  height: 24px;
  min-width: unset;
  margin: 0 10px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .5);
  border-radius: 50%;
  box-shadow: none;
  background: rgba(0, 0, 0, .25) center no-repeat;
  background-size: 16px;
  text-indent: 100%;
  cursor: pointer;
  opacity: .8;
}

.fiu-broken-file input.form-submit[value="Remove selected"]:hover,
.fine-image-data .button[value="Remove"]:hover,
.fiu-image-details:hover {
  opacity: 1;
}

.fiu-broken-file input.form-submit[value="Remove selected"],
.fine-image-data .button[value="Remove"] {
  background-image: url('../icons/close.svg');
}

.fiu-image-details {
  background-image: url('../icons/magnify.svg');
}

.fiu-progress-wrapper {
  position: absolute;
  top: -10px;
  height: 120px;
  width: 180px;
  text-align: center;
  background: #ccc;
}

.sp {
  width: 32px;
  height: 32px;
  clear: both;
  margin: 40px auto;
}

/* Spinner Circle Rotation */
.sp-circle {
  border: 4px rgba(0, 0, 0, 1) solid;
  border-top: 4px rgba(255, 255, 255, 1) solid;
  border-radius: 50%;
  -webkit-animation: spCircRot .6s infinite linear;
  animation: spCircRot .6s infinite linear;
  display: inline-block;
}
@-webkit-keyframes spCircRot {
  from {
    -webkit-transform: rotate(0deg);
  }
  to {
    -webkit-transform: rotate(359deg);
  }
}
@keyframes spCircRot {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(359deg);
  }
}

.fiu-load-image .form-item {
  margin: 0;
}
.fiu-load-image.fiu-add-element label,
.fiu-load-image .fiu-image-details {
  display: none;
}
.fiu-load-image.fiu-add-element .fine-image-widget {
  display: block;
}

/* Single element style */
.unitary-element .fiu-add-element {
  float: none;
  width: 100%;
  height: auto;
  background-color: unset;
}
.unitary-element .form-item {
  position: relative;
  width: 180px;
  height: 120px;
  margin: 5px;
}
.unitary-element .fiu-add-element div[id^="ajax-wrapper"] .fine-image-widget.fiu-single-item {
  display: block;
}
.unitary-element .fiu-add-element div[id^="ajax-wrapper"] .form-item {
  width: 180px;
  height: 120px;
  overflow: hidden;
}
.unitary-element .messages--error {
  display: block;
}
.fiu-broken-file .fiu-image-details {
  width: 0;
  height: 0;
  background: none;
  border: none;
}
.fiu-broken-file .fine-image-preview {
  color: black;
  font: 80px/100% arial, sans-serif;
  text-decoration: none;
  text-shadow: 0 1px 0 #fff;
  background: #eee;
  text-align: center;
  line-height: 120px;
}
.fiu-broken-file .fine-image-preview:after {
  content: '✖';
}
.fiu-broken-file .fine-image-preview img {
  display: none;
}

.fiu-broken-file input[type="file"],
.fiu-broken-file .form-type-checkbox {
  display: none;
}

/* Add integration with IMCE. */
.fiu-wrapper .imce-filefield-widget {
  position: absolute;
  top: 5px;
  text-align: center;
  width: 100%;
}
.fiu-wrapper .fiu-load-image. .imce-filefield-widget {
  display: none;
}

/* Add integration with filefield_sources module. */
.fiu-wrapper .filefield-sources-list {
  position: absolute;
  top: 70px;
  text-align: center;
  z-index: 99;
  width: 100%;
}

/* Hide some sources. */
.fiu-wrapper .filefield-sources-list .filefield-source-imce,
.fiu-wrapper .filefield-sources-list .filefield-source-attach,
.fiu-wrapper .filefield-sources-list .filefield-source-clipboard {
  display: none;
}

.fiu-wrapper .filefield-sources-list a {
  display: inline-block;
  margin: 0 2px;
}

.fiu-wrapper .filefield-source.filefield-source-remote.clear-block,
.fiu-wrapper .filefield-source.filefield-source-reference.clear-block {
  position: absolute;
  left: 0;
  width: 170px;
  top: -10px;
  background: #eee;
  padding: 10px 5px;
}

.fiu-wrapper .filefield-source.filefield-source-remote.clear-block .field-suffix,
.fiu-wrapper .filefield-source.filefield-source-reference.clear-block .field-suffix {
  text-align: center;
  width: 170px;
  display: inline-block;
  margin: 5px 0px;
}

.fiu-wrapper .unitary-element .filefield-source.clear-block > .form-item {
  width: 100% !important;
  margin: 0;
}

.fiu-wrapper .filefield-source-remote .ajax-progress-bar {
  margin: 0;
  padding: 0;
  width: 100%;
  position: relative;
  z-index: 999;
  background: #eee;
}

File

css/style.css
View source
  1. .fiu-wrapper:after {
  2. content: " ";
  3. display: block;
  4. width: 1px;
  5. height: 1px;
  6. clear: both;
  7. }
  8. .fiu-wrapper > .messages {
  9. float: none;
  10. }
  11. .fiu-add-element {
  12. position: relative;
  13. float: left;
  14. width: 180px;
  15. height: 120px;
  16. margin: 5px;
  17. background-color: #eee;
  18. }
  19. .fiu-add-element .form-item .description {
  20. display: none;
  21. position: absolute;
  22. bottom: calc(100% + 15px);
  23. left: 50%;
  24. width: 100%;
  25. margin: 0;
  26. padding: 5px;
  27. box-shadow: 0 0 3px 0 rgba(0, 0, 0, .25);
  28. border-radius: 4px;
  29. background-color: rgba(0, 0, 0, .8);
  30. color: #fff;
  31. font-size: 12px;
  32. transform: translateX(-50%);
  33. z-index: 99;
  34. }
  35. .fiu-add-element .form-item .description:before {
  36. content: '';
  37. position: absolute;
  38. left: 50%;
  39. bottom: -20px;
  40. width: 0;
  41. height: 0;
  42. margin: 0;
  43. border: 10px solid transparent;
  44. border-top: 10px solid rgba(0, 0, 0, .8);
  45. transform: translateX(-50%);
  46. }
  47. .fiu-add-element:hover .description {
  48. display: block;
  49. }
  50. .fiu-add-element input[type="file"] {
  51. height: 0;
  52. opacity: 0;
  53. overflow: hidden;
  54. position: absolute;
  55. width: 0;
  56. z-index: -1;
  57. }
  58. .fiu-add-element .form-type-managed-file {
  59. height: 120px;
  60. margin: 0;
  61. position: relative;
  62. width: 100%;
  63. }
  64. .fiu-add-element .form-type-managed-file label {
  65. align-items: center;
  66. background-color: #eee;
  67. color: #000;
  68. cursor: pointer;
  69. display: flex;
  70. font-size: 1.25em;
  71. font-weight: 700;
  72. height: 120px;
  73. justify-content: center;
  74. left: 0;
  75. position: absolute;
  76. top: 0;
  77. width: 100%;
  78. }
  79. .fiu-add-element .form-type-managed-file--advanced label {
  80. background-image: url(/modules/fiu/icons/upload.svg);
  81. background-position: center 30px;
  82. background-repeat: no-repeat;
  83. background-size: 40px;
  84. font-size: 1em;
  85. height: 60px;
  86. padding-top: 60px;
  87. }
  88. .fiu-add-element .form-type-managed-file--advanced.is-dragover label {
  89. background-color: #ddd;
  90. }
  91. .fiu-add-element:focus label,
  92. .fiu-add-element label:hover {
  93. outline: none;
  94. }
  95. .fiu-add-element label * {
  96. pointer-events: none;
  97. }
  98. .field--widget-fine-image .messages--status,
  99. .fiu-add-element .messages,
  100. .fiu-wrapper .fiu-image-info {
  101. display: none;
  102. }
  103. .mfp-inline-holder .mfp-content {
  104. position: absolute;
  105. top: 50%;
  106. left: 50%;
  107. display: flex;
  108. align-items: stretch;
  109. width: 90%;
  110. height: 70%;
  111. transform: translate(-50%, -50%);
  112. }
  113. .fiu-full-image {
  114. position: relative;
  115. width: 100%;
  116. }
  117. .fiu-full-image .mfp-close {
  118. right: 20%;
  119. margin: 10px;
  120. width: 32px;
  121. height: 32px;
  122. border: 1px solid rgba(255, 255, 255, .5);
  123. border-radius: 50%;
  124. background-color: rgba(0, 0, 0, .25);
  125. color: #fff;
  126. font-size: 28px;
  127. line-height: 32px;
  128. }
  129. .fiu-full-image img {
  130. display: block;
  131. width: 80%;
  132. height: auto;
  133. object-fit: cover;
  134. float: left;
  135. }
  136. .fiu-img-description {
  137. width: 20%;
  138. float: left;
  139. }
  140. .mfp-content .inner-fiu-full-image ul {
  141. margin: 0 0 0 30px;
  142. padding: 0;
  143. list-style: none;
  144. color: #ddd;
  145. }
  146. .inner-fiu-full-image .attr {
  147. margin: 0 0 0 30px;
  148. display: block;
  149. }
  150. .inner-fiu-full-image .attr label {
  151. color: #eee;
  152. }
  153. .inner-fiu-full-image .attr .description {
  154. color: #ddd;
  155. }
  156. .item-list ul.fiu-sortable-list {
  157. position: relative;
  158. margin: 0;
  159. padding: 0;
  160. list-style: none;
  161. }
  162. .item-list ul.fiu-sortable-list li {
  163. float: left;
  164. width: 180px;
  165. height: 120px;
  166. overflow: hidden;
  167. margin: 5px;
  168. list-style: none;
  169. }
  170. ul.fiu-sortable-list li > .form-type-select {
  171. display: none;
  172. }
  173. .fine-image-widget {
  174. position: relative;
  175. }
  176. .fine-image-preview {
  177. position: relative;
  178. width: 100%;
  179. height: 120px;
  180. }
  181. .fine-image-preview img {
  182. background: #eee;
  183. position: relative;
  184. display: block;
  185. width: 100%;
  186. height: 100%;
  187. object-fit: cover;
  188. }
  189. .fine-image-data {
  190. position: absolute;
  191. top: 10px;
  192. right: 0;
  193. display: flex;
  194. justify-content: space-between;
  195. width: 100%;
  196. }
  197. .fiu-broken-file input.form-submit[value="Remove selected"],
  198. .fine-image-data .button[value="Remove"],
  199. .fiu-image-details {
  200. display: inline-block;
  201. width: 24px;
  202. height: 24px;
  203. min-width: unset;
  204. margin: 0 10px;
  205. padding: 0;
  206. overflow: hidden;
  207. border: 1px solid rgba(255, 255, 255, .5);
  208. border-radius: 50%;
  209. box-shadow: none;
  210. background: rgba(0, 0, 0, .25) center no-repeat;
  211. background-size: 16px;
  212. text-indent: 100%;
  213. cursor: pointer;
  214. opacity: .8;
  215. }
  216. .fiu-broken-file input.form-submit[value="Remove selected"]:hover,
  217. .fine-image-data .button[value="Remove"]:hover,
  218. .fiu-image-details:hover {
  219. opacity: 1;
  220. }
  221. .fiu-broken-file input.form-submit[value="Remove selected"],
  222. .fine-image-data .button[value="Remove"] {
  223. background-image: url('../icons/close.svg');
  224. }
  225. .fiu-image-details {
  226. background-image: url('../icons/magnify.svg');
  227. }
  228. .fiu-progress-wrapper {
  229. position: absolute;
  230. top: -10px;
  231. height: 120px;
  232. width: 180px;
  233. text-align: center;
  234. background: #ccc;
  235. }
  236. .sp {
  237. width: 32px;
  238. height: 32px;
  239. clear: both;
  240. margin: 40px auto;
  241. }
  242. /* Spinner Circle Rotation */
  243. .sp-circle {
  244. border: 4px rgba(0, 0, 0, 1) solid;
  245. border-top: 4px rgba(255, 255, 255, 1) solid;
  246. border-radius: 50%;
  247. -webkit-animation: spCircRot .6s infinite linear;
  248. animation: spCircRot .6s infinite linear;
  249. display: inline-block;
  250. }
  251. @-webkit-keyframes spCircRot {
  252. from {
  253. -webkit-transform: rotate(0deg);
  254. }
  255. to {
  256. -webkit-transform: rotate(359deg);
  257. }
  258. }
  259. @keyframes spCircRot {
  260. from {
  261. transform: rotate(0deg);
  262. }
  263. to {
  264. transform: rotate(359deg);
  265. }
  266. }
  267. .fiu-load-image .form-item {
  268. margin: 0;
  269. }
  270. .fiu-load-image.fiu-add-element label,
  271. .fiu-load-image .fiu-image-details {
  272. display: none;
  273. }
  274. .fiu-load-image.fiu-add-element .fine-image-widget {
  275. display: block;
  276. }
  277. /* Single element style */
  278. .unitary-element .fiu-add-element {
  279. float: none;
  280. width: 100%;
  281. height: auto;
  282. background-color: unset;
  283. }
  284. .unitary-element .form-item {
  285. position: relative;
  286. width: 180px;
  287. height: 120px;
  288. margin: 5px;
  289. }
  290. .unitary-element .fiu-add-element div[id^="ajax-wrapper"] .fine-image-widget.fiu-single-item {
  291. display: block;
  292. }
  293. .unitary-element .fiu-add-element div[id^="ajax-wrapper"] .form-item {
  294. width: 180px;
  295. height: 120px;
  296. overflow: hidden;
  297. }
  298. .unitary-element .messages--error {
  299. display: block;
  300. }
  301. .fiu-broken-file .fiu-image-details {
  302. width: 0;
  303. height: 0;
  304. background: none;
  305. border: none;
  306. }
  307. .fiu-broken-file .fine-image-preview {
  308. color: black;
  309. font: 80px/100% arial, sans-serif;
  310. text-decoration: none;
  311. text-shadow: 0 1px 0 #fff;
  312. background: #eee;
  313. text-align: center;
  314. line-height: 120px;
  315. }
  316. .fiu-broken-file .fine-image-preview:after {
  317. content: '✖';
  318. }
  319. .fiu-broken-file .fine-image-preview img {
  320. display: none;
  321. }
  322. .fiu-broken-file input[type="file"],
  323. .fiu-broken-file .form-type-checkbox {
  324. display: none;
  325. }
  326. /* Add integration with IMCE. */
  327. .fiu-wrapper .imce-filefield-widget {
  328. position: absolute;
  329. top: 5px;
  330. text-align: center;
  331. width: 100%;
  332. }
  333. .fiu-wrapper .fiu-load-image. .imce-filefield-widget {
  334. display: none;
  335. }
  336. /* Add integration with filefield_sources module. */
  337. .fiu-wrapper .filefield-sources-list {
  338. position: absolute;
  339. top: 70px;
  340. text-align: center;
  341. z-index: 99;
  342. width: 100%;
  343. }
  344. /* Hide some sources. */
  345. .fiu-wrapper .filefield-sources-list .filefield-source-imce,
  346. .fiu-wrapper .filefield-sources-list .filefield-source-attach,
  347. .fiu-wrapper .filefield-sources-list .filefield-source-clipboard {
  348. display: none;
  349. }
  350. .fiu-wrapper .filefield-sources-list a {
  351. display: inline-block;
  352. margin: 0 2px;
  353. }
  354. .fiu-wrapper .filefield-source.filefield-source-remote.clear-block,
  355. .fiu-wrapper .filefield-source.filefield-source-reference.clear-block {
  356. position: absolute;
  357. left: 0;
  358. width: 170px;
  359. top: -10px;
  360. background: #eee;
  361. padding: 10px 5px;
  362. }
  363. .fiu-wrapper .filefield-source.filefield-source-remote.clear-block .field-suffix,
  364. .fiu-wrapper .filefield-source.filefield-source-reference.clear-block .field-suffix {
  365. text-align: center;
  366. width: 170px;
  367. display: inline-block;
  368. margin: 5px 0px;
  369. }
  370. .fiu-wrapper .unitary-element .filefield-source.clear-block > .form-item {
  371. width: 100% !important;
  372. margin: 0;
  373. }
  374. .fiu-wrapper .filefield-source-remote .ajax-progress-bar {
  375. margin: 0;
  376. padding: 0;
  377. width: 100%;
  378. position: relative;
  379. z-index: 999;
  380. background: #eee;
  381. }