File tree Expand file tree Collapse file tree 3 files changed +50
-2
lines changed Expand file tree Collapse file tree 3 files changed +50
-2
lines changed Original file line number Diff line number Diff line change @@ -83,3 +83,34 @@ summary {
83
83
color : # 606060 ;
84
84
padding : 10px 0px ;
85
85
}
86
+
87
+ .a-watermark {
88
+ pointer-events : none;
89
+ }
90
+
91
+
92
+
93
+ .w {
94
+ position : relative;
95
+ }
96
+
97
+ .w : before {
98
+ content : " " ;
99
+ background-color : red;
100
+ position : absolute;
101
+ width : 100px ;
102
+ height : 100px ;
103
+ right : 10px ;
104
+ top : 10px ;
105
+ background : url ("swm_logo.svg" );
106
+ max-width : 15% ;
107
+ background-repeat : no-repeat;
108
+ max-height : 15% ;
109
+ opacity : 0.9 ;
110
+ pointer-events : all;
111
+ }
112
+
113
+ .w : hover : before {
114
+ transform : scale (1.1 );
115
+ transition : all 0.2s linear;
116
+ }
Original file line number Diff line number Diff line change @@ -74,14 +74,31 @@ async function connectInput(id) {
74
74
whepClient . onstream = ( stream ) => {
75
75
console . log ( `[${ id } ]: Creating new video element` ) ;
76
76
77
+
78
+ const w = document . createElement ( 'div' ) ;
79
+ w . className = 'w'
80
+
77
81
const videoPlayer = document . createElement ( 'video' ) ;
78
82
videoPlayer . srcObject = stream ;
79
83
videoPlayer . autoplay = true ;
80
84
videoPlayer . controls = true ;
81
85
videoPlayer . muted = true ;
82
86
videoPlayer . className = 'rounded-xl w-full h-full object-cover bg-black' ;
83
87
84
- videoPlayerGrid . appendChild ( videoPlayer ) ;
88
+ w . appendChild ( videoPlayer ) ;
89
+
90
+ // const a = document.createElement('a');
91
+ // a.appendChild(w);
92
+ // a.href = "https://swmansion.com"
93
+ // a.className = 'a-watermark';
94
+
95
+ const watermark = document . createElement ( 'div' ) ;
96
+ watermark . style = 'position: absolute; width: 20px; height: 20px; background-color: red;'
97
+ const p = document . createElement ( 'div' ) ;
98
+ p . style = 'position: relative; display: inline-block;' ;
99
+ p . appendChild ( videoPlayer ) ;
100
+ p . appendChild ( watermark ) ;
101
+ videoPlayerGrid . appendChild ( p ) ;
85
102
inputData . videoPlayer = videoPlayer ;
86
103
updateVideoGrid ( ) ;
87
104
statusMessage . classList . add ( 'hidden' ) ;
Original file line number Diff line number Diff line change 20
20
"globals" : " ^15.8.0" ,
21
21
"prettier" : " ^3.3.3"
22
22
}
23
- }
23
+ }
You can’t perform that action at this time.
0 commit comments