fileinput.scss 7.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481
  1. /*!
  2. * bootstrap-fileinput v4.4.0
  3. * http://plugins.krajee.com/file-input
  4. *
  5. * Krajee default styling for bootstrap-fileinput.
  6. *
  7. * Author: Kartik Visweswaran
  8. * Copyright: 2014 - 2017, Kartik Visweswaran, Krajee.com
  9. *
  10. * Licensed under the BSD 3-Clause
  11. * https://github.com/kartik-v/bootstrap-fileinput/blob/master/LICENSE.md
  12. */
  13. .file-loading {
  14. top: 0;
  15. right: 0;
  16. width: 25px;
  17. height: 25px;
  18. font-size: 999px;
  19. text-align: right;
  20. color: #fff;
  21. background: transparent url('../img/loading.gif') top left no-repeat;
  22. border: none;
  23. }
  24. .file-object {
  25. margin: 0 0 -5px 0;
  26. padding: 0;
  27. }
  28. .btn-file {
  29. position: relative;
  30. overflow: hidden;
  31. input[type=file] {
  32. position: absolute;
  33. top: 0;
  34. right: 0;
  35. min-width: 100%;
  36. min-height: 100%;
  37. text-align: right;
  38. opacity: 0;
  39. background: none repeat scroll 0 0 transparent;
  40. cursor: inherit;
  41. display: block;
  42. }
  43. }
  44. .file-caption-name {
  45. display: inline-block;
  46. overflow: hidden;
  47. height: 20px;
  48. word-break: break-all;
  49. }
  50. .input-group-lg .file-caption-name {
  51. height: 25px;
  52. }
  53. .file-zoom-dialog {
  54. text-align: left;
  55. }
  56. .file-error-message {
  57. color: #a94442;
  58. background-color: #f2dede;
  59. margin: 5px;
  60. border: 1px solid #ebccd1;
  61. border-radius: 4px;
  62. padding: 15px;
  63. pre, ul {
  64. margin: 0;
  65. text-align: left;
  66. }
  67. pre {
  68. margin: 5px 0;
  69. }
  70. }
  71. .file-caption-disabled {
  72. background-color: #EEEEEE;
  73. cursor: not-allowed;
  74. opacity: 1;
  75. }
  76. .file-preview {
  77. border-radius: 5px;
  78. border: 1px solid #ddd;
  79. padding: 5px;
  80. width: 100%;
  81. margin-bottom: 5px;
  82. }
  83. .krajee-default {
  84. &.file-preview-frame {
  85. position: relative;
  86. display: table;
  87. margin: 8px;
  88. border: 1px solid #ddd;
  89. box-shadow: 1px 1px 5px 0 #a2958a;
  90. padding: 6px;
  91. float: left;
  92. text-align: center;
  93. &:not(.file-preview-error):hover {
  94. box-shadow: 3px 3px 5px 0 #333;
  95. }
  96. .kv-file-content {
  97. height: 170px;
  98. }
  99. .file-thumbnail-footer {
  100. height: 70px;
  101. }
  102. }
  103. .file-preview-image {
  104. vertical-align: middle;
  105. image-orientation: from-image;
  106. }
  107. .file-preview-text {
  108. display: block;
  109. color: #428bca;
  110. border: 1px solid #ddd;
  111. font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
  112. outline: none;
  113. padding: 8px;
  114. resize: none;
  115. }
  116. .file-preview-html {
  117. border: 1px solid #ddd;
  118. padding: 8px;
  119. overflow: auto;
  120. }
  121. &[data-template="audio"] .file-preview-audio {
  122. display: table-cell;
  123. vertical-align: middle;
  124. height: 170px;
  125. border: 1px solid #ddd;
  126. border-radius: 5px;
  127. }
  128. .file-preview-audio audio {
  129. vertical-align: middle;
  130. }
  131. .file-zoom-dialog .file-preview-text {
  132. font-size: 1.2em;
  133. }
  134. .file-preview-other {
  135. left: 0;
  136. top: 0;
  137. right: 0;
  138. bottom: 0;
  139. margin: auto;
  140. text-align: center;
  141. vertical-align: middle;
  142. padding: 10px;
  143. &:hover {
  144. opacity: 0.8;
  145. }
  146. }
  147. .file-actions, .file-other-error {
  148. text-align: left;
  149. }
  150. .file-other-icon {
  151. font-size: 8em;
  152. }
  153. .file-actions {
  154. margin-top: 15px;
  155. }
  156. .file-footer-buttons {
  157. float: right;
  158. }
  159. .file-footer-caption {
  160. display: block;
  161. white-space: nowrap;
  162. overflow: hidden;
  163. text-overflow: ellipsis;
  164. width: 160px;
  165. text-align: center;
  166. padding-top: 4px;
  167. font-size: 11px;
  168. color: #777;
  169. margin: 5px auto;
  170. }
  171. .file-preview-error {
  172. opacity: 0.65;
  173. box-shadow: none;
  174. }
  175. .file-preview-frame:not(.file-preview-error) .file-footer-caption:hover {
  176. color: #000;
  177. }
  178. .file-drag-handle, .file-upload-indicator {
  179. position: absolute;
  180. text-align: center;
  181. bottom: -6px;
  182. left: -6px;
  183. padding: 8px 8px 1px 3px;
  184. border-left: none;
  185. border-bottom: none;
  186. border-right: 1px solid #8a6d3b;
  187. border-top: 1px solid #8a6d3b;
  188. border-top-right-radius: 24px;
  189. font-size: 12px;
  190. }
  191. .file-drag-handle {
  192. background-color: #d9edf7;
  193. border-color: #bce8f1;
  194. }
  195. .file-upload-indicator {
  196. font-size: 13px;
  197. background-color: #fcf8e3;
  198. border-color: #faebcc;
  199. padding-bottom: 0;
  200. }
  201. &.file-preview-error .file-upload-indicator {
  202. background-color: #f2dede;
  203. border-color: #ebccd1;
  204. }
  205. &.file-preview-success .file-upload-indicator {
  206. background-color: #dff0d8;
  207. border-color: #d6e9c6;
  208. }
  209. &.file-preview-loading .file-upload-indicator {
  210. background-color: #e5e5e5;
  211. border-color: #777;
  212. }
  213. .file-thumb-progress {
  214. height: 10px;
  215. .progress, .progress-bar {
  216. height: 10px;
  217. font-size: 9px;
  218. line-height: 10px;
  219. }
  220. }
  221. .file-thumbnail-footer {
  222. position: relative;
  223. }
  224. .file-thumb-progress {
  225. position: absolute;
  226. top: 35px;
  227. left: 0;
  228. right: 0;
  229. }
  230. &.kvsortable-ghost {
  231. background: #e1edf7;
  232. border: 2px solid #a1abff;
  233. }
  234. }
  235. /* noinspection CssOverwrittenProperties */
  236. .file-zoom-dialog .file-other-icon {
  237. font-size: 8em;
  238. font-size: 65vmin;
  239. }
  240. .file-input-new {
  241. .file-preview, .close, .glyphicon-file, .fileinput-remove-button, .fileinput-upload-button {
  242. display: none;
  243. }
  244. }
  245. .file-input-ajax-new {
  246. .fileinput-remove-button, .fileinput-upload-button {
  247. display: none;
  248. }
  249. }
  250. .file-caption-main {
  251. width: 100%;
  252. }
  253. .file-input-ajax-new .no-browse .input-group-btn, .file-input-new .no-browse .input-group-btn {
  254. display: none;
  255. }
  256. .file-input-ajax-new .no-browse .form-control, .file-input-new .no-browse .form-control {
  257. border-top-right-radius: 4px;
  258. border-bottom-right-radius: 4px;
  259. }
  260. .file-thumb-loading {
  261. background: transparent url('../img/loading.gif') no-repeat scroll center center content-box !important;
  262. }
  263. .file-sortable .file-drag-handle {
  264. cursor: move;
  265. cursor: -webkit-grabbing;
  266. opacity: 1;
  267. &:hover {
  268. opacity: 0.7;
  269. }
  270. }
  271. .file-drop-zone {
  272. border: 1px dashed #aaa;
  273. border-radius: 4px;
  274. height: 100%;
  275. text-align: center;
  276. vertical-align: middle;
  277. margin: 12px 15px 12px 12px;
  278. padding: 5px;
  279. }
  280. .file-drop-zone-title {
  281. color: #aaa;
  282. font-size: 1.6em;
  283. padding: 85px 10px;
  284. cursor: default;
  285. }
  286. .file-preview .clickable, .clickable .file-drop-zone-title {
  287. cursor: pointer;
  288. }
  289. .file-drop-zone {
  290. &.clickable {
  291. &:hover {
  292. border: 2px dashed #999;
  293. }
  294. &:focus {
  295. border: 2px solid #5acde2;
  296. }
  297. }
  298. .file-preview-thumbnails {
  299. cursor: default;
  300. }
  301. }
  302. .file-highlighted {
  303. border: 2px dashed #999 !important;
  304. background-color: #f0f0f0;
  305. }
  306. .file-uploading {
  307. background: url('../img/loading-sm.gif') no-repeat center bottom 10px;
  308. opacity: 0.65;
  309. }
  310. .file-zoom-fullscreen {
  311. &.modal {
  312. position: fixed;
  313. top: 0;
  314. right: 0;
  315. bottom: 0;
  316. left: 0;
  317. }
  318. .modal-dialog {
  319. position: fixed;
  320. margin: 0;
  321. width: 100%;
  322. height: 100%;
  323. padding: 0;
  324. }
  325. .modal-content {
  326. border-radius: 0;
  327. box-shadow: none;
  328. }
  329. .modal-body {
  330. overflow-y: auto;
  331. }
  332. }
  333. .file-zoom-dialog {
  334. .modal-body {
  335. position: relative !important;
  336. }
  337. .btn-navigate {
  338. position: absolute;
  339. padding: 0;
  340. margin: 0;
  341. background: transparent;
  342. text-decoration: none;
  343. outline: none;
  344. opacity: 0.7;
  345. top: 45%;
  346. font-size: 4em;
  347. color: #1c94c4;
  348. }
  349. .floating-buttons {
  350. position: absolute;
  351. top: 5px;
  352. right: 10px;
  353. }
  354. }
  355. .floating-buttons {
  356. z-index: 3000;
  357. .btn {
  358. z-index: 3000;
  359. }
  360. }
  361. .file-zoom-dialog .kv-zoom-actions .btn, .floating-buttons .btn {
  362. margin-left: 3px;
  363. }
  364. .file-zoom-dialog {
  365. .btn-navigate {
  366. &:not([disabled]) {
  367. &:hover, &:focus {
  368. outline: none;
  369. box-shadow: none;
  370. opacity: 0.5;
  371. }
  372. }
  373. &[disabled] {
  374. opacity: 0.3;
  375. }
  376. }
  377. .btn-prev {
  378. left: 1px;
  379. }
  380. .btn-next {
  381. right: 1px;
  382. }
  383. }
  384. .file-zoom-content {
  385. height: 480px;
  386. text-align: center;
  387. .file-preview-image {
  388. max-height: 100%;
  389. }
  390. }
  391. .file-preview- .file-zoom-content .file-preview-video {
  392. max-height: 100%;
  393. }
  394. .file-preview-initial.sortable-chosen {
  395. background-color: #d9edf7;
  396. }
  397. /* IE 10 fix */
  398. .btn-file ::-ms-browse {
  399. width: 100%;
  400. height: 100%;
  401. }