小说小程序前端代码仓库(小程序)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
720 B

  1. <template>
  2. <button :class="['login-btn', type]" @click="$emit('click')">
  3. <slot />
  4. </button>
  5. </template>
  6. <script>
  7. export default {
  8. name: 'LoginButton',
  9. props: {
  10. type: {
  11. type: String,
  12. default: ''
  13. }
  14. }
  15. }
  16. </script>
  17. <style scoped>
  18. .login-btn {
  19. width: 80%;
  20. height: 44px;
  21. border-radius: 22px;
  22. font-size: 18px;
  23. font-weight: 500;
  24. margin: 12px 0;
  25. outline: none;
  26. border: none;
  27. cursor: pointer;
  28. display: flex;
  29. align-items: center;
  30. justify-content: center;
  31. transition: background 0.2s;
  32. }
  33. .login-btn.primary {
  34. background: #183b6b;
  35. color: #fff;
  36. }
  37. .login-btn.secondary {
  38. background: #fff;
  39. color: #183b6b;
  40. border: 2px solid #183b6b;
  41. position: relative;
  42. }
  43. </style>