Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

Register.vue 4.3KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217
  1. <template lang="pug">
  2. .register__box
  3. h2 Register
  4. form(@submit.prevent='onSubmit')
  5. .user__box
  6. input(
  7. minlength='5'
  8. required=''
  9. type='text'
  10. v-model='form.fullname'
  11. )
  12. label Fullname
  13. .user__box
  14. input(minlength='10' required='' type='email' v-model='form.email')
  15. label Email
  16. .user__box
  17. input(
  18. minlength='6'
  19. required=''
  20. type='password'
  21. v-model='form.password'
  22. )
  23. label Password
  24. .user__box
  25. router-link.forget__link(to='/forget') Forget Password
  26. button(type='submit')
  27. span
  28. span
  29. span
  30. span {{ requesting ? "Log..." : "Register" }}
  31. router-link.links(to='/login') Login
  32. </template>
  33. <script>
  34. export default {
  35. data: () => ({
  36. valid: true,
  37. requesting: false,
  38. form: {
  39. email: '',
  40. password: '',
  41. fullname: '',
  42. },
  43. }),
  44. methods: {
  45. onSubmit() {
  46. this.requesting = true
  47. this.requesting = false
  48. },
  49. },
  50. }
  51. </script>
  52. <style lang="postcss">
  53. html
  54. background-color: #e90d77
  55. .content
  56. background: none
  57. .wrapper
  58. position: unset
  59. .register__box
  60. position: absolute
  61. top: 50%
  62. left: 50%
  63. width: 300px
  64. padding: 40px
  65. transform: translate(-50%, -50%)
  66. background: rgba(0, 0, 0, 0.5)
  67. box-sizing: border-box
  68. box-shadow: 0 15px 25px rgba(0, 0, 0, 0.6)
  69. border-radius: 10px
  70. .register__box h2
  71. margin: 0 0 30px
  72. padding: 0
  73. color: #fff
  74. text-align: center
  75. .register__box .user__box
  76. position: relative
  77. .register__box .user__box input
  78. width: 100%
  79. padding: 10px 0
  80. font-size: 16px
  81. color: #fff
  82. margin-bottom: 30px
  83. border: none
  84. border-bottom: 1px solid #fff
  85. outline: none
  86. background: transparent
  87. .register__box .user__box label
  88. position: absolute
  89. top: 0
  90. left: 0
  91. padding: 10px 0
  92. font-size: 16px
  93. color: #fff
  94. pointer-events: none
  95. transition: 0.5s
  96. .register__box .user__box input:focus ~ label,
  97. .register__box .user__box input:valid ~ label
  98. top: -20px
  99. left: 0
  100. color: #e90d77
  101. font-size: 12px
  102. .register__box form button
  103. position: relative
  104. display: inline-block
  105. padding: 10px 20px
  106. color: #e90d77
  107. font-size: 16px
  108. text-decoration: none
  109. text-transform: uppercase
  110. overflow: hidden
  111. transition: 0.5s
  112. margin-top: 40px
  113. letter-spacing: 4px
  114. background: none
  115. border: none
  116. .register__box button:hover
  117. background: #e90d77
  118. color: #fff
  119. border-radius: 5px
  120. box-shadow: 0 0 5px #e90d77, 0 0 25px #e90d77, 0 0 50px #e90d77,
  121. 0 0 100px #e90d77
  122. .register__box button span
  123. position: absolute
  124. display: block
  125. .register__box button span:nth-child(1)
  126. top: 0
  127. left: -100%
  128. width: 100%
  129. height: 2px
  130. background: linear-gradient(90deg, transparent, #e90d77)
  131. animation: btn-anim1 1s linear infinite
  132. .register__box form .forget__link
  133. color: white
  134. text-decoration: none
  135. .register__box form .forget__link:hover
  136. color: #e90d77
  137. .register__box form .links
  138. color: white
  139. text-decoration: none
  140. margin-left: 5px
  141. padding: 10px
  142. .register__box form .links:hover
  143. background: #e90d77
  144. color: #fff
  145. border-radius: 5px
  146. box-shadow: 0 0 5px #e90d77, 0 0 25px #e90d77, 0 0 50px #e90d77, 0 0 100px #e90d77
  147. @keyframes btn-anim1
  148. 0%
  149. left: -100%
  150. 50%, 100%
  151. left: 100%
  152. .register__box button span:nth-child(2)
  153. top: -100%
  154. right: 0
  155. width: 2px
  156. height: 100%
  157. background: linear-gradient(180deg, transparent, #e90d77)
  158. animation: btn-anim2 1s linear infinite
  159. animation-delay: 0.25s
  160. @keyframes btn-anim2
  161. 0%
  162. top: -100%
  163. 50%, 100%
  164. top: 100%
  165. .register__box button span:nth-child(3)
  166. bottom: 0
  167. right: -100%
  168. width: 100%
  169. height: 2px
  170. background: linear-gradient(270deg, transparent, #e90d77)
  171. animation: btn-anim3 1s linear infinite
  172. animation-delay: 0.5s
  173. @keyframes btn-anim3
  174. 0%
  175. right: -100%
  176. 50%, 100%
  177. right: 100%
  178. .register__box a span:nth-child(4)
  179. bottom: -100%
  180. left: 0
  181. width: 2px
  182. height: 100%
  183. background: linear-gradient(360deg, transparent, #e90d77)
  184. animation: btn-anim4 1s linear infinite
  185. animation-delay: 0.75s
  186. @keyframes btn-anim4
  187. 0%
  188. bottom: -100%
  189. 50%,
  190. 100%
  191. bottom: 100%
  192. </style>