HomeBody.vue 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. <template>
  2. <div class="modal fade" id="register" tabindex="-1" role="dialog" aria-labelledby="register-modal">
  3. <div class="modal-dialog" role="document">
  4. <div class="modal-content">
  5. <div class="modal-header">
  6. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  7. <h4 class="modal-title">Register</h4>
  8. </div>
  9. <div class="modal-body">
  10. <input class="form-control" type="text" placeholder="Email..."/>
  11. <input class="form-control" type="text" placeholder="Username..."/>
  12. <input class="form-control" type="password" placeholder="Password..."/>
  13. <div class="g-recaptcha" data-sitekey="6Ld5jygTAAAAAEi0E1IwovUuVFhZKctMvKnY553W"></div>
  14. </div>
  15. <div class="modal-footer">
  16. <button type="button" class="btn btn-primary" data-dismiss="modal">Submit</button>
  17. </div>
  18. </div>
  19. </div>
  20. </div>
  21. <!-- Will be deleted soon ^^ -->
  22. <div class="group" v-for="group in groups">
  23. <div class="group-title">{{group.name}}</div>
  24. <div class="group-rooms">
  25. <div class="rooms-room" v-for="room in group.rooms" @click="this.$dispatch('switchView', 'home', 'station');">
  26. <img class="room-image" :src="room.thumbnail" />
  27. <div class="room-info">
  28. <div class="room-grid-left">
  29. <h3>{{ room.name }}</h3>
  30. <p>{{ room.description }}</p>
  31. </div>
  32. <div class="room-grid-right">
  33. <div>{{ room.users }}&nbsp;&nbsp;<i class="fa fa-user" aria-hidden="true"></i></div>
  34. </div>
  35. </div>
  36. </div>
  37. </div>
  38. </div>
  39. </template>
  40. <script>
  41. export default {
  42. data() {
  43. return {
  44. groups: [
  45. {
  46. id: "lu08gw56571r4497wrk9",
  47. name: "Official Rooms",
  48. rooms: [
  49. { id: "73qvw65746acvo8yqfr", thumbnail: "https://lh6.googleusercontent.com/-ghASz3s6yL4/AAAAAAAAAAI/AAAAAAAAALc/tFblPp2myu0/s0-c-k-no-ns/photo.jpg", name: "Country", description: "Johnny Cash - I Walk The Line", users: 10 },
  50. { id: "enxcysmhn1k7ld56ogvi", thumbnail: "http://66.media.tumblr.com/1734069af425e491fae7deae0a19869f/tumblr_o0i0xmIYrF1v421f2o1_1280.jpg", name: "Pop", description: "Sia - Cheap Thrills", users: 14 },
  51. { id: "kqa99gbva7lij05dn29", thumbnail: "http://www.youredm.com/wp-content/uploads/2014/09/taking-you-higher.jpg", name: "Chill", description: "MrSuicideSheep - Taking you higher", users: 13 },
  52. { id: "w19hu791iiub6wmjf9a4i", thumbnail: "http://edmsauce.wpengine.netdna-cdn.com/wp-content/uploads/2012/12/Deadmau5-album-title-goes-here.jpg", name: "EDM", description: "Deadmau5 - There Might Be Coffee", users: 13 }
  53. ]
  54. },
  55. {
  56. id: "g2b8v03xaedj8ht1emi",
  57. name: "Trending Rooms",
  58. rooms: [
  59. { id: "73qvw65746acvo8yqfr", thumbnail: "https://lh6.googleusercontent.com/-ghASz3s6yL4/AAAAAAAAAAI/AAAAAAAAALc/tFblPp2myu0/s0-c-k-no-ns/photo.jpg", name: "Country", description: "Johnny Cash - I Walk The Line", users: 10 },
  60. { id: "enxcysmhn1k7ld56ogvi", thumbnail: "http://66.media.tumblr.com/1734069af425e491fae7deae0a19869f/tumblr_o0i0xmIYrF1v421f2o1_1280.jpg", name: "Pop", description: "Sia - Cheap Thrills", users: 14 },
  61. { id: "kqa99gbva7lij05dn29", thumbnail: "http://www.youredm.com/wp-content/uploads/2014/09/taking-you-higher.jpg", name: "Chill", description: "MrSuicideSheep - Taking you higher", users: 13 },
  62. { id: "w19hu791iiub6wmjf9a4i", thumbnail: "http://edmsauce.wpengine.netdna-cdn.com/wp-content/uploads/2012/12/Deadmau5-album-title-goes-here.jpg", name: "EDM", description: "Deadmau5 - There Might Be Coffee", users: 13 }
  63. ]
  64. }
  65. ]
  66. }
  67. },
  68. methods: {
  69. log: function(thing) {
  70. console.log(thing);
  71. }
  72. }
  73. }
  74. </script>
  75. <style lang="sass" scoped>
  76. .g-recaptcha {
  77. display: flex;
  78. justify-content: center;
  79. margin-top: 10px;
  80. }
  81. .group {
  82. width: 100%;
  83. height: 448px;
  84. margin: 64px 0 64px 0;
  85. .group-title {
  86. float: left;
  87. clear: none;
  88. width: 100%;
  89. height: 64px;
  90. line-height: 48px;
  91. text-align: center;
  92. font-size: 48px;
  93. }
  94. .group-rooms {
  95. white-space: nowrap;
  96. text-align: center;
  97. overflow: hidden;
  98. float: left;
  99. clear: none;
  100. width: 100%;
  101. height: 384px;
  102. .rooms-room {
  103. position: relative;
  104. top: 16px;
  105. display: inline-block;
  106. clear: none;
  107. width: 256px;
  108. height: 345px;
  109. margin: 0 16px 0 16px;
  110. box-shadow: 0 1px 6px 2px rgba(0, 0, 0, 0.25);
  111. cursor: pointer;
  112. .room-info {
  113. display: flex;
  114. flex-direction: row;
  115. align-items: center;
  116. padding: 5px;
  117. }
  118. .room-image {
  119. width: 100%;
  120. height: 256px;
  121. }
  122. .room-grid-left {
  123. display: flex;
  124. flex-direction: column;
  125. width: 75%;
  126. text-align: left;
  127. padding-left: 10px;
  128. h3, p {
  129. margin: 0;
  130. white-space: normal;
  131. }
  132. }
  133. .room-grid-right {
  134. display: flex;
  135. flex-direction: column;
  136. width: 25%;
  137. }
  138. }
  139. }
  140. }
  141. </style>