change-avatar.less 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238
  1. //
  2. // Change avatar modal styles
  3. // --------------------------------------------------
  4. // Default form styles
  5. .avatar-options-menu {
  6. .avatar-preview {
  7. position: relative;
  8. margin: 0px auto;
  9. margin-bottom: @line-height-computed;
  10. width: 60%;
  11. img {
  12. border-radius: @avatar-radius;
  13. width: 100%;
  14. height: auto;
  15. }
  16. .loading-overlay {
  17. border-radius: @avatar-radius;
  18. }
  19. }
  20. @media (min-width: @screen-md-min) {
  21. .avatar-preview {
  22. width: 100%;
  23. }
  24. .btn-block {
  25. text-align: left;
  26. }
  27. }
  28. }
  29. // Avatar upload
  30. .avatar-upload {
  31. input.file-upload {
  32. position: absolute;
  33. top: -9999px;
  34. left: -9999px;
  35. }
  36. .upload-file {
  37. margin-top: @line-height-computed;
  38. margin-bottom: @line-height-computed * 1.5;
  39. text-align: center;
  40. .btn {
  41. margin-bottom: @line-height-computed / 3;
  42. }
  43. p {
  44. font-size: @font-size-small;
  45. }
  46. }
  47. .uploading-file {
  48. margin-top: @line-height-computed;
  49. margin-bottom: @line-height-computed * 1.5;
  50. text-align: center;
  51. img {
  52. border-radius: @border-radius-base;
  53. margin-bottom: @line-height-computed * .7;
  54. max-width: 50%;
  55. height: auto;
  56. }
  57. .progress {
  58. margin-left: auto;
  59. margin-right: auto;
  60. width: 100%;
  61. @media (min-width: @screen-md-min) {
  62. width: 70%;
  63. }
  64. }
  65. }
  66. }
  67. // Avatar crop
  68. .avatar-crop {
  69. .image-cropper {
  70. margin: 0px auto;
  71. margin-bottom: @line-height-computed;
  72. .cropit-image-zoom-input {
  73. margin-top: @line-height-computed / 2;
  74. /*removes default webkit styles*/
  75. -webkit-appearance: none;
  76. /*fix for FF unable to apply focus style bug */
  77. border: 1px solid white;
  78. /*required for proper track sizing in FF*/
  79. width: 100%;
  80. &::-webkit-slider-runnable-track {
  81. width: 100%;
  82. height: 8px;
  83. background: @gray-lighter;
  84. border: none;
  85. border-radius: 3px;
  86. }
  87. &::-webkit-slider-thumb {
  88. -webkit-appearance: none;
  89. border: none;
  90. height: 20px;
  91. width: 20px;
  92. border-radius: 50%;
  93. background: @gray-light;
  94. margin-top: -6px;
  95. }
  96. &:focus {
  97. outline: none;
  98. }
  99. &:focus::-webkit-slider-runnable-track {
  100. background: @gray-lighter;
  101. }
  102. &::-moz-range-track {
  103. width: 100%;
  104. height: 8px;
  105. background: @gray-lighter;
  106. border: none;
  107. border-radius: 4px;
  108. }
  109. &::-moz-range-thumb {
  110. border: none;
  111. height: 20px;
  112. width: 20px;
  113. border-radius: 50%;
  114. background: @gray-light;
  115. }
  116. /*hide the outline behind the border*/
  117. &:-moz-focusring{
  118. outline: 1px solid white;
  119. outline-offset: -1px;
  120. }
  121. &::-ms-track {
  122. width: 100%;
  123. height: 8px;
  124. /*remove bg colour from the track, we'll use ms-fill-lower and ms-fill-upper instead */
  125. background: transparent;
  126. /*leave room for the larger thumb to overflow with a transparent border */
  127. border-color: transparent;
  128. border-width: 8px 0;
  129. /*remove default tick marks*/
  130. color: transparent;
  131. }
  132. &::-ms-fill-lower {
  133. background: @gray-lighter;
  134. border-radius: 16px;
  135. }
  136. &::-ms-fill-upper {
  137. background: @gray-lighter;
  138. border-radius: 16px;
  139. }
  140. &::-ms-thumb {
  141. border: none;
  142. height: 20px;
  143. width: 20px;
  144. border-radius: 50%;
  145. background: @gray-light;
  146. }
  147. &:focus::-ms-fill-lower {
  148. background: @gray-lighter;
  149. }
  150. &:focus::-ms-fill-upper {
  151. background: @gray-lighter;
  152. }
  153. }
  154. }
  155. }
  156. // Avatar galleries
  157. .avatar-galleries {
  158. .avatar-gallery {
  159. border-bottom: 1px solid @hr-border;
  160. padding-bottom: @line-height-computed;
  161. margin-bottom: @line-height-computed;
  162. .gallery-name {
  163. margin: 0px;
  164. padding-bottom: @line-height-computed / 2;
  165. }
  166. .row {
  167. margin-top: @line-height-computed / 2;
  168. margin-bottom: @line-height-computed / 2;
  169. }
  170. .btn {
  171. border-radius: @avatar-radius + 2px;
  172. margin: 0px;
  173. padding: 0px;
  174. overflow: hidden;
  175. position: relative;
  176. img {
  177. border-radius: @avatar-radius;
  178. width: 100%;
  179. }
  180. .loading-overlay {
  181. border-radius: @avatar-radius;
  182. left: 2px;
  183. top: 2px;
  184. }
  185. }
  186. }
  187. }