@worksafevictoria/wcl7.5 1.1.0-beta.73 → 1.1.0-beta.75

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -16,29 +16,28 @@
16
16
  </div>
17
17
  </a>
18
18
  <!-- Modal -->
19
- <div v-if="showModal" :id="wcl-video-modal" class="modal" tabindex="-1" aria-modal="true" role="dialog" style="display: block;">
20
- <div class="modal-dialog modal-dialog-scrollable">
21
- <div class="modal-content">
22
- <div class="modal-header">
23
- <button type="button" class="btn-close" @click="showModal = !showModal" aria-label="close"></button>
24
- </div>
25
- <div class="modal-body">
26
- <div class="wcl-video-modal__video">
27
- <video-media
28
- :media-title="video.mediaTitle"
29
- :media-description="video.mediaDescription"
30
- :video-id="video.id"
31
- :provider="video.provider"
32
- :transcript="video.transcript"
33
- :transcript-title="video.transcriptTitle"
34
- :fix-width="video.fixWidth"
35
- :rtl="video.rtl"
36
- />
37
- </div>
38
- </div>
39
- </div>
19
+ <b-modal
20
+ :id="`wcl-video-modal`"
21
+ v-model="showModal"
22
+ scrollable
23
+ class="wcl-video-modal__modal"
24
+ no-footer
25
+ size="xl"
26
+ >
27
+ <div class="wcl-video-modal__video">
28
+ <video-media
29
+ :media-title="video.mediaTitle"
30
+ :media-description="video.mediaDescription"
31
+ :video-id="video.id"
32
+ :provider="video.provider"
33
+ :transcript="video.transcript"
34
+ :transcript-title="video.transcriptTitle"
35
+ :fix-width="video.fixWidth"
36
+ :rtl="video.rtl"
37
+ />
40
38
  </div>
41
- </div>
39
+ <template #footer><div></div></template>
40
+ </b-modal>
42
41
  </div>
43
42
  </template>
44
43
 
@@ -46,25 +45,27 @@
46
45
  import VideoMedia from './../../Paragraphs/VideoPlayer/index.vue'
47
46
  import VideoPlay from './../../../assets/icons/video-play.svg?url'
48
47
  import IconClose from './../../../assets/icons/icon-close.svg?url'
48
+ import { BModal } from 'bootstrap-vue-next'
49
49
 
50
50
  export default {
51
51
  name: 'VideoThumbnail',
52
52
  components: {
53
53
  VideoMedia,
54
- IconClose
54
+ IconClose,
55
+ 'b-modal': BModal,
55
56
  },
56
57
  props: {
57
58
  video: {
58
59
  type: Object,
59
- required: true
60
- }
60
+ required: true,
61
+ },
61
62
  },
62
63
  data() {
63
64
  return {
64
65
  VideoPlay,
65
66
  IconClose,
66
67
  showModal: false,
67
- videoThumbnail: ''
68
+ videoThumbnail: '',
68
69
  }
69
70
  },
70
71
  mounted() {
@@ -76,7 +77,7 @@ export default {
76
77
  this.videoThumbnail = `https://i.ytimg.com/vi/${this.video.id}/maxresdefault.jpg`
77
78
  if (process.env.IS_STORYBOOK !== 'TRUE') {
78
79
  let thumbnailAvailable = await this.$axios?.get(
79
- `${window.location.origin}/api/v2/urlExists?url=${this.videoThumbnail}`
80
+ `${window.location.origin}/api/v2/urlExists?url=${this.videoThumbnail}`,
80
81
  )
81
82
  if (
82
83
  thumbnailAvailable &&
@@ -92,99 +93,15 @@ export default {
92
93
  },
93
94
  async getVimeoThumbnail() {
94
95
  let thumbnail = await this.$axios.get(
95
- `https://vimeo.com/api/v2/video/${this.video.id}.json`
96
+ `https://vimeo.com/api/v2/video/${this.video.id}.json`,
96
97
  )
97
98
  if (thumbnail.data) {
98
99
  this.videoThumbnail = thumbnail.data[0].thumbnail_large
99
100
  }
100
- }
101
- }
101
+ },
102
+ },
102
103
  }
103
104
  </script>
104
- <style lang="scss">
105
- @import '../../../includes/scss/all';
106
- // The modal styling
107
- .modal {
108
- background: rgba(0,0,0,0.5)
109
- }
110
-
111
- .modal-backdrop {
112
- display: none;
113
- }
114
- .modal-dialog {
115
- max-width: 1110px;
116
- @media only screen and (max-width: 1150px) {
117
- margin: {
118
- left: 15px;
119
- right: 15px;
120
- top: 15px;
121
- }
122
- }
123
-
124
- .modal-content {
125
- position: relative;
126
- border-radius: 8px;
127
- }
128
-
129
- .modal-header {
130
- top: 0;
131
- height: 45px;
132
- background: $white;
133
- z-index: 1;
134
- margin-left: auto;
135
- margin-right:0%;
136
-
137
- &__wrap {
138
- position: relative;
139
- width: 100%;
140
- a {
141
- position: absolute;
142
- right: 0;
143
- z-index: 1;
144
- &.rtl {
145
- right: auto;
146
- left: 0;
147
- }
148
- svg {
149
- fill: $black;
150
- }
151
- }
152
- }
153
- }
154
- .modal-body {
155
- padding: 0px 32px 32px;
156
- margin-top: 16px;
157
- .video-player {
158
- @include fp(min-height, 250, 588);
159
- }
160
-
161
- .paragraph--video-media {
162
- margin: 0;
163
- .container {
164
- padding: 0;
165
- width: 100%;
166
- }
167
- h3 {
168
- margin: 0;
169
- font-style: normal;
170
- font-weight: bold;
171
- font-size: 28px;
172
- line-height: 32px;
173
- margin-bottom: 16px;
174
- display: inline-block;
175
- width: 98%;
176
- }
177
- }
178
- .section-group__block {
179
- max-width: 100%;
180
- }
181
- }
182
- .modal-header,
183
- .modal-footer {
184
- border: none;
185
- }
186
- }
187
- </style>
188
105
  <style lang="scss" scoped>
189
106
  @import '../../../includes/scss/all';
190
107
  // Outside wrapper style
@@ -20,6 +20,20 @@ $yellow: #ffd229;
20
20
  $lightyellow: #fff6d4;
21
21
  $outline: #da47ff;
22
22
  $outline-dark: #ffffff;
23
+ // Functional colours
24
+ $wsv-fun-dark-green: #576D2F;
25
+ $wsv-fun-dark-blue: #104f77;
26
+ $wsv-fun-dark-purple: #55356b;
27
+ $wsv-fun-dark-red: #760031;
28
+ $wsv-fun-dark-brown: #763b00;
29
+ $wsv-fun-dark-caramel: #cb7c2d;
30
+ $wsv-fun-light-teal: #7ac2b5;
31
+ $wsv-fun-light-blue: #8ecade;
32
+ $wsv-fun-light-purple: #9871a8;
33
+ $wsv-fun-light-fuchsia: #f16a7e;
34
+ $wsv-fun-light-green: #edeb72;
35
+ $wsv-fun-light-brown: #dbc38b;
36
+
23
37
 
24
38
  $theme-colors: (
25
39
  'gold': $gold,
@@ -43,7 +57,20 @@ $theme-colors: (
43
57
  'yellow': $yellow,
44
58
  'lightyellow': $lightyellow,
45
59
  'outline': $outline,
46
- 'outline-dark': $outline-dark
60
+ 'outline-dark': $outline-dark,
61
+ // Functional colours
62
+ 'wsv-fun-dark-green':$wsv-fun-dark-green,
63
+ 'wsv-fun-dark-blue':$wsv-fun-dark-blue,
64
+ 'wsv-fun-dark-purple':$wsv-fun-dark-purple,
65
+ 'wsv-fun-dark-red':$wsv-fun-dark-red,
66
+ 'wsv-fun-dark-brown':$wsv-fun-dark-brown,
67
+ 'wsv-fun-dark-caramel':$wsv-fun-dark-caramel,
68
+ 'wsv-fun-light-teal':$wsv-fun-light-teal,
69
+ 'wsv-fun-light-blue':$wsv-fun-light-blue,
70
+ 'wsv-fun-light-purple':$wsv-fun-light-purple,
71
+ 'wsv-fun-light-fuchsia':$wsv-fun-light-fuchsia,
72
+ 'wsv-fun-light-green':$wsv-fun-light-green,
73
+ 'wsv-fun-light-brown':$wsv-fun-light-brown
47
74
  );
48
75
 
49
76
  :export {