_login.scss 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306
  1. .nologin {
  2. $gray-dark-for-login: darken(white, 30%);
  3. // background color
  4. background:
  5. linear-gradient(45deg, darken($inverse, 30%) 0%, hsla(340, 100%, 55%, 0) 70%),
  6. linear-gradient(135deg, $growi-green 10%, hsla(225, 95%, 50%, 0) 70%),
  7. linear-gradient(225deg, $growi-blue 10%, hsla(140, 90%, 50%, 0) 80%),
  8. linear-gradient(315deg, darken($inverse, 25%) 100%, hsla(35, 95%, 55%, 0) 70%);
  9. #page-wrapper {
  10. background: none;
  11. }
  12. // layout
  13. #wrapper {
  14. height: 100vh;
  15. #page-wrapper {
  16. height: 100vh;
  17. display: flex;
  18. align-items: center;
  19. .main {
  20. width: 100vw;
  21. > .row {
  22. margin-right: 20px;
  23. margin-left: 20px;
  24. }
  25. .login-header {
  26. padding-top: 30px;
  27. padding-bottom: 10px;
  28. display: flex;
  29. flex-direction: column;
  30. align-items: center;
  31. }
  32. .login-form-errors {
  33. width: 100%;
  34. .alert {
  35. margin-top: 10px;
  36. margin-bottom: 0;
  37. padding: 5px;
  38. ul {
  39. padding-left: 1.5em;
  40. }
  41. }
  42. }
  43. } // .main
  44. } // #page-wrapper
  45. } // #wrapper
  46. // styles
  47. .login-header {
  48. background-color: rgba(white, 0.5);
  49. .logo {
  50. .group1, .group2 {
  51. fill: rgba(black, 0.5);
  52. }
  53. }
  54. h1 {
  55. color: rgba(black, 0.5);
  56. font-size: 22px;
  57. line-height: 1em;
  58. }
  59. }
  60. .login-dialog {
  61. background-color: rgba(white, 0.5);
  62. }
  63. .input-group {
  64. margin-bottom: 10px;
  65. .input-group-addon {
  66. text-align: center;
  67. border: none;
  68. border-radius: 0;
  69. color: $gray-dark-for-login;
  70. background-color: rgba(black, 0.4);
  71. }
  72. .form-control {
  73. color: white;
  74. background-color: rgba(lighten(black, 10%), 0.4);
  75. &::placeholder {
  76. color: $gray-dark-for-login;
  77. }
  78. }
  79. }
  80. .input-group:not(.has-error) {
  81. .form-control {
  82. border: transparent;
  83. }
  84. }
  85. .collapse-oauth {
  86. overflow: hidden;
  87. &:not(.in) {
  88. height: 0;
  89. padding: 0 !important;
  90. }
  91. form {
  92. flex: 1;
  93. @media(min-width: 350px) {
  94. flex: 0.49;
  95. }
  96. }
  97. .spacer {
  98. height: 10px;
  99. }
  100. }
  101. // button style
  102. .btn-login.fcbtn, .btn-register.fcbtn, .btn-login-oauth.fcbtn, .btn-collapse-oauth {
  103. border: none;
  104. color: white;
  105. background-color: rgba(lighten(black, 20%), 0.4);
  106. .btn-label {
  107. margin: -8px 20px -8px -20px;
  108. padding: 9px 15px;
  109. }
  110. &:focus {
  111. border: none;
  112. }
  113. }
  114. .btn-login-oauth {
  115. flex: 1;
  116. .btn-label-text {
  117. flex: 1;
  118. }
  119. }
  120. .btn-login.fcbtn {
  121. .btn-label {
  122. background-color: rgba($brand-danger, 0.4);
  123. }
  124. &:after {
  125. background-color: #7e4153;
  126. }
  127. }
  128. .btn-login-oauth.fcbtn#google {
  129. .btn-label {
  130. background: rgba(#f13d25, 0.4);
  131. }
  132. &:after {
  133. background-color: #555;
  134. }
  135. }
  136. .btn-login-oauth.fcbtn#github {
  137. .btn-label {
  138. background-color: rgba(#24292e, 0.4);
  139. }
  140. &:after {
  141. background-color: #555;
  142. }
  143. }
  144. .btn-login-oauth.fcbtn#facebook {
  145. .btn-label {
  146. background-color: rgba(#29487d, 0.4);
  147. }
  148. &:after {
  149. background-color: #555;
  150. }
  151. }
  152. .btn-login-oauth.fcbtn#twitter {
  153. .btn-label {
  154. background-color: rgba(#1da1f2, 0.4);
  155. }
  156. &:after {
  157. background-color: #555;
  158. }
  159. }
  160. .btn-register.fcbtn {
  161. .btn-label {
  162. background-color: rgba($brand-success, 0.4);
  163. }
  164. &:after {
  165. background-color: #3f7263;
  166. }
  167. }
  168. hr {
  169. margin: 10px 0;
  170. border-color: #ccc;
  171. }
  172. // footer link text
  173. .link-growi-org {
  174. color: rgba(black, 0.4);
  175. font-weight: bold;
  176. font-size: smaller;
  177. &, .growi, .org {
  178. transition: color 0.8s;
  179. }
  180. &:hover, &.focus {
  181. color: black;
  182. .growi {
  183. color: darken($growi-green, 20%);
  184. }
  185. .org {
  186. color: darken($growi-blue, 15%);
  187. }
  188. }
  189. }
  190. .link-switch {
  191. color: $gray-lighter;
  192. &:hover {
  193. color: white;
  194. }
  195. }
  196. }
  197. .login-page {
  198. // layout
  199. .main .row {
  200. @media(min-width: 350px) {
  201. .col-sm-offset-4 {
  202. margin-left: calc(50% - 160px);
  203. }
  204. .col-sm-4 {
  205. width: 320px;
  206. }
  207. }
  208. }
  209. .link-growi-org {
  210. position: absolute;
  211. z-index: 2;
  212. bottom: 9px;
  213. }
  214. // flip animation
  215. .login-dialog.flipper {
  216. transition: min-height 0.2s;
  217. &.to-flip {
  218. min-height: 295px;
  219. // has-error
  220. &.has-error {
  221. min-height: #{295px + 32px};
  222. }
  223. }
  224. .front, .back {
  225. transition: 0.4s;
  226. backface-visibility: hidden;
  227. transform-style: preserve-3d;
  228. // fix https://github.com/weseek/growi/issues/330
  229. -webkit-backface-visibility: hidden;
  230. -webkit-transform-style: preserve-3d;
  231. }
  232. .front {
  233. z-index: 2;
  234. }
  235. .back {
  236. position: absolute;
  237. top: 0;
  238. left: 15px;
  239. right: 15px;
  240. }
  241. .back,
  242. &.to-flip .front {
  243. transform: rotateY(180deg);
  244. // fix https://github.com/weseek/growi/issues/330
  245. // 'backface-visibility: hidden' and 'z-index: -1' breaks layout in iOS
  246. .fcbtn:after {
  247. z-index: 0;
  248. opacity: 0.3;
  249. }
  250. }
  251. &.to-flip .back {
  252. transform: rotateY(0deg);
  253. }
  254. }
  255. }
  256. .installer, .invited, .nologin.error {
  257. // layout
  258. .main .row {
  259. @media(min-width: 510px) {
  260. .col-sm-offset-4 {
  261. margin-left: calc(50% - 240px);
  262. }
  263. .col-sm-4 {
  264. width: 480px;
  265. }
  266. }
  267. }
  268. }
  269. .nologin.error {
  270. .alert h2 {
  271. line-height: 1em;
  272. }
  273. }