This repository was archived by the owner on Apr 15, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 123
123
checkContent : function ( link ) {
124
124
var $this = this ,
125
125
href = link . attr ( 'href' ) ,
126
- video = href . match ( / ( y o u t u b e | y o u t u | v i m e o ) \. ( c o m | b e ) \/ ( w a t c h \? v = ( [ \w - ] + ) | ( [ \w - ] + ) ) / ) ;
126
+ video = href . match ( / ( y o u t u b e | y o u t u b e - n o c o o k i e | y o u t u | v i m e o ) \. ( c o m | b e ) \/ ( w a t c h \? v = ( [ \w - ] + ) | ( [ \w - ] + ) ) / ) ;
127
127
128
128
if ( href . match ( / \. ( j p e g | j p g | g i f | p n g ) $ / i) !== null ) {
129
129
return true ;
151
151
processContent : function ( content , link ) {
152
152
var $this = this ,
153
153
href = link . attr ( 'href' ) ,
154
- video = href . match ( / ( y o u t u b e | y o u t u | v i m e o ) \. ( c o m | b e ) \/ ( w a t c h \? v = ( [ \w - ] + ) | ( [ \w - ] + ) ) / ) ;
154
+ video = href . match ( / ( y o u t u b e | y o u t u b e - n o c o o k i e | y o u t u | v i m e o ) \. ( c o m | b e ) \/ ( w a t c h \? v = ( [ \w - ] + ) | ( [ \w - ] + ) ) / ) ;
155
155
156
156
content . html ( '' ) . addClass ( 'nivo-lightbox-loading' ) ;
157
157
197
197
src = 'http://www.youtube.com/embed/' + video [ 4 ] ;
198
198
classTerm = 'nivo-lightbox-youtube' ;
199
199
}
200
+ if ( video [ 1 ] == 'youtube-nocookie' ) {
201
+ src = href ; //https://www.youtube-nocookie.com/embed/...
202
+ classTerm = 'nivo-lightbox-youtube' ;
203
+ }
200
204
if ( video [ 1 ] == 'youtu' ) {
201
205
src = 'http://www.youtube.com/embed/' + video [ 3 ] ;
202
206
classTerm = 'nivo-lightbox-youtube' ;
You can’t perform that action at this time.
0 commit comments