仲裁视频会议H5

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. <template>
  2. <div class="page">
  3. <div class="content">
  4. <div class="screenShare"></div>
  5. <div :class="videoList">
  6. <div :class="videoClass" v-for="(item, index) in vivdeoList"></div>
  7. </div>
  8. </div>
  9. <div class="footerList">
  10. <button @click="screenShare">分享</button>
  11. <button @click="screenShareQ">取消分享</button>
  12. </div>
  13. </div>
  14. </template>
  15. <script>
  16. export default {
  17. props: [],
  18. data() {
  19. return {
  20. vivdeoList: [1],
  21. videoClass: "videoItem",
  22. videoList: "videoList",
  23. screenShareFlag: false,
  24. };
  25. },
  26. methods: {
  27. screenShare() {
  28. this.videoList = "videoList1";
  29. // this.screenShareFlag = true;
  30. this.videoClass = "videoItem2";
  31. },
  32. screenShareQ(){
  33. this.videoList = "videoList";
  34. if(this.vivdeoList.length > 1){
  35. this.videoClass = "videoItem1";
  36. }else{
  37. this.videoClass = "videoItem";
  38. }
  39. this.screenShareFlag = false;
  40. }
  41. },
  42. mounted() {
  43. if (this.vivdeoList.length == 1) {
  44. this.videoClass = "videoItem";
  45. } else if(this.vivdeoList.length > 1){
  46. this.videoClass = "videoItem1";
  47. }
  48. },
  49. watch: {},
  50. };
  51. </script>
  52. <style scoped>
  53. .page {
  54. width: 100%;
  55. height: 100vh;
  56. }
  57. .content {
  58. width: 100%;
  59. height: 90%;
  60. display: flex;
  61. }
  62. .videoList {
  63. width: 100%;
  64. height: 100%;
  65. display: flex;
  66. justify-content: space-around;
  67. flex-wrap: wrap;
  68. align-items: center;
  69. overflow-y: scroll;
  70. margin-bottom: 20px;
  71. }
  72. .videoList1 {
  73. width: 20%;
  74. height: 100%;
  75. display: flex;
  76. justify-content: space-around;
  77. flex-wrap: wrap;
  78. align-items: center;
  79. overflow-y: scroll;
  80. margin-bottom: 20px;
  81. }
  82. .screenShare {
  83. width: 80%;
  84. height: 90%;
  85. background: yellow;
  86. }
  87. .footerList {
  88. width: 100%;
  89. height: 10%;
  90. background: green;
  91. }
  92. .videoItem {
  93. width: 100%;
  94. height: 100%;
  95. background: red;
  96. border-radius: 20px;
  97. }
  98. .videoItem1 {
  99. width: 32%;
  100. height: 32%;
  101. background: red;
  102. border-radius: 20px;
  103. }
  104. .videoItem2 {
  105. width: 90%;
  106. height: 25%;
  107. background: red;
  108. border-radius: 20px;
  109. margin-bottom: 20px;
  110. }
  111. </style>