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.

63 lines
1.1 KiB

  1. <template>
  2. <div class="flyout flyout--book">
  3. <ChosenFlights :selected-orig="selectedOrig" :selected-dest="selectedDest" />
  4. <NuxtLink
  5. :to="'/dates/' + selectedOrig.iata + '/' + selectedDest.iata"
  6. :class="['btn btn--primary',{'btn--empty': !selectedOrig.iata || !selectedDest.iata}]"
  7. >
  8. <span :class="['btn__content']">
  9. see flights
  10. </span>
  11. </NuxtLink>
  12. </div>
  13. </template>
  14. <script>
  15. export default {
  16. props: {
  17. selectedOrig: {
  18. type: [Object],
  19. default () {
  20. return {}
  21. }
  22. },
  23. selectedDest: {
  24. type: [Object],
  25. default () {
  26. return {}
  27. }
  28. }
  29. }
  30. }
  31. </script>
  32. <style scoped>
  33. .flyout {
  34. background: #007fff;
  35. border-radius: 3rem 3rem 0 0;
  36. padding: 3rem;
  37. pointer-events: all;
  38. width: clamp(450px, 50vw, 400px);
  39. display: flex;
  40. flex-direction: column;
  41. }
  42. .flyout .btn.btn--primary {
  43. background: white;
  44. color: black;
  45. }
  46. .flyout .btn.btn--primary:hover {
  47. background: #00ca00;
  48. color: #fff;
  49. }
  50. .btn__content {
  51. transition: width 0s 5s;
  52. }
  53. .btn.btn--empty {
  54. background: lightgray;
  55. }
  56. </style>