File tree Expand file tree Collapse file tree 4 files changed +16
-0
lines changed
components/WatchVideoDescription Expand file tree Collapse file tree 4 files changed +16
-0
lines changed Original file line number Diff line number Diff line change 43
43
max-block-size : 4lh ;
44
44
overflow : hidden;
45
45
}
46
+
47
+ .license {
48
+ margin-block : 1em ;
49
+ }
Original file line number Diff line number Diff line change 22
22
@timestamp-event =" onTimestamp"
23
23
@click.native =" expandDescriptionWithClick"
24
24
/>
25
+ <span
26
+ v-if =" license && showFullDescription"
27
+ class =" license"
28
+ >
29
+ {{ license }}
30
+ </span >
25
31
<span
26
32
v-if =" showControls && showFullDescription"
27
33
class =" descriptionStatus"
@@ -51,6 +57,10 @@ const props = defineProps({
51
57
descriptionHtml: {
52
58
type: String ,
53
59
default: ' '
60
+ },
61
+ license: {
62
+ type: String ,
63
+ default: null ,
54
64
}
55
65
})
56
66
Original file line number Diff line number Diff line change @@ -413,6 +413,7 @@ export default defineComponent({
413
413
// extract localised title first and fall back to the not localised one
414
414
this . videoTitle = result . primary_info ?. title . text ?? result . basic_info . title
415
415
this . videoViewCount = result . basic_info . view_count ?? ( result . primary_info . view_count ? extractNumberFromString ( result . primary_info . view_count . text ) : null )
416
+ this . license = result . secondary_info . metadata . rows . find ( element => element . title . text === 'License' ) ?. contents [ 0 ] . text
416
417
417
418
this . channelId = result . basic_info . channel_id ?? result . secondary_info . owner ?. author . id
418
419
this . channelName = result . basic_info . author ?? result . secondary_info . owner ?. author . name
Original file line number Diff line number Diff line change 168
168
v-if =" !isLoading && !hideVideoDescription"
169
169
:description =" videoDescription"
170
170
:description-html =" videoDescriptionHtml"
171
+ :license =" license"
171
172
class =" watchVideo"
172
173
:class =" { theatreWatchVideo: useTheatreMode }"
173
174
@timestamp-event =" changeTimestamp"
You can’t perform that action at this time.
0 commit comments