marinebon / infographiqR

R functions for creation of interactive intelligent infographics, ie infographiq
https://marinebon.github.io/infographiqR
MIT License
11 stars 2 forks source link

migrate info-demo/drupal-module to infographiq #55

Closed bbest closed 3 years ago

bbest commented 3 years ago

Transfer info-demo/drupal-module

References:

Develop from Drupal Docker Locally

Match with IEA Drupal version 8.9.13

# pull the docker image
docker pull drupal:8.9.13

# run with default folders as daemon
docker run --name drupal -p 8080:80 -d drupal:8.9.13
# visit browser: http://localhost:8080 and choose sqlite

# run with custom mounted folders
docker run --name drupal -p 8080:80 -d \
    -v /path/on/host/modules:/var/www/html/modules \ 
    -v /path/on/host/profiles:/var/www/html/profiles \
    -v /path/on/host/sites:/var/www/html/sites \
    -v /path/on/host/themes:/var/www/html/themes \
    drupal:8.9.13
superjai commented 3 years ago

Here is the test page created in their drupal environment for us to match.

superjai commented 3 years ago

The fastest option would be to use the iframe module for drupal, as can be seen in the following test drupal environment where the iframe module has been installed. By some miracle, everything in the iframe seems to work properly out of the box with no customization of anything.

Here's a screenshot of the page:

Screen Shot 2021-03-10 at 11 20 07 PM

bbest commented 3 years ago

---------- Forwarded message --------- From: Ben Best ben@ecoquants.com Date: Fri, Mar 19, 2021 at 9:45 AM Subject: Re: Interactive pieces on IEA site To: Avi Litwack - NOAA Federal avi.litwack@noaa.gov Cc: Ellen Spooner - NOAA Affiliate ellen.spooner@noaa.gov, Jai Ranganathan jai.ranganathan@gmail.com

Hi Avi, I see that you loaded my last suggestion -- thanks for that, but the same error message about "modal is not a function" in the JS Console continues to prevent the modal window from opening. I think the problem is related to jquery already being loaded twice, which you can see at the bottom of Infographiq-test | IEA when viewing its page source:

<script src="/core/assets/vendor/jquery/jquery.min.js?v=3.5.1"></script>
...
<script src="/themes/iea2017/js/jquery.min.js?qoa2gt"></script>

The first version is 3.5.1 and the second one is a far more ancient version 1.12.0. Would it be possible for you to remove the second old jquery theme line? This thinking is based on javascript - TypeError: $(...).modal is not a function with bootstrap Modal - Stack Overflow:

image

Thanks a bunch, Ben

bbest commented 3 years ago

See "infographiq consolidation" under 2021-04-06 BB, JR in notes | iea-auto