_login.scss 5.7 KB

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