File tree 2 files changed +17
-0
lines changed
2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -210,6 +210,18 @@ describe(`gatsby-remark-copy-linked-files`, () => {
210
210
expect ( fsExtra . copy ) . toHaveBeenCalled ( )
211
211
} )
212
212
213
+ it ( `can copy flash from object elements with the value attribute` , async ( ) => {
214
+ const path = `myMovie.swf`
215
+
216
+ const markdownAST = remark . parse (
217
+ `<object type="application/x-shockwave-flash">\n<param name="movie" value="${ path } " />\n</object>`
218
+ )
219
+
220
+ await plugin ( { files : getFiles ( path ) , markdownAST, markdownNode, getNode } )
221
+
222
+ expect ( fsExtra . copy ) . toHaveBeenCalled ( )
223
+ } )
224
+
213
225
it ( `can copy HTML videos when some siblings are in ignore extensions` , async ( ) => {
214
226
const path = `videos/sample-video.mp4`
215
227
const path1 = `images/sample-image.jpg`
Original file line number Diff line number Diff line change @@ -267,6 +267,11 @@ module.exports = (
267
267
`src`
268
268
) . forEach ( processUrl )
269
269
270
+ // Handle flash embed tags.
271
+ extractUrlAttributeAndElement ( $ ( `object param[value]` ) , `value` ) . forEach (
272
+ processUrl
273
+ )
274
+
270
275
// Handle a tags.
271
276
extractUrlAttributeAndElement ( $ ( `a[href]` ) , `href` ) . forEach ( processUrl )
272
277
You can’t perform that action at this time.
0 commit comments