react-modal icon indicating copy to clipboard operation
react-modal copied to clipboard

Unable to add backgroundImage to content styling

Open jaredmharris opened this issue 9 years ago • 1 comments

Summary:

Unable to add backgroundImage to content styling

Steps to reproduce:

  1. added backgroundImage: 'url(\'../path/myimage.jpg\')', to the content section of the modal styling
  2. inspecting the rendered html shows that it gets converted to simply 'background'

Expected behavior:

Instead of backgroundColor I should be able to use backgroundImage to set the background of the content layer.

jaredmharris avatar Feb 14 '17 17:02 jaredmharris

Nevermind, was able to do:

const img = require('../path/myimage.jpg');

and then under content: { backgroundImage: 'url('+ img +')', }

jaredmharris avatar Feb 14 '17 19:02 jaredmharris