psu-libraries / researcher-metadata

Penn State University's faculty and research metadata repository
https://metadata.libraries.psu.edu/
MIT License
7 stars 0 forks source link

Jquery-UI and custom admin assets fix #906

Closed ajkiessl closed 1 year ago

ajkiessl commented 1 year ago

Turns out, some things broke when upgrading to RailsAdmin3. I did not catch these since they are relatively minute features and they are not tested. I added an issue to add tests for these: #909 .

One of the things that broke was the custom RailsAdmin assets. These stopped being loaded the way the RailsAdmin documentation says they should be loaded. Perhaps this is because the rest of the RailsAdmin assets are now being compiled via js-bundling (webpack). I fixed this by adding the custom assets to the js-bundling pipeline to be compiled with the rest of the RailsAdmin assets.

The other thing that broke was the user profiles page. The tabs to switch between different types of works were not working. This requires the rails gem jquery-ui-rails. I had hoped to switch off of this — this is why we ended up upgrading to RailsAdmin3 — but for now this will do. I have an issue to move these assets into the js-bundling pipeline so jquery-ui in node can be used instead of the rails gem: #908 .

Note that the most current version of jquery-ui-rails was not released to RubyGems. So, this gem cannot be cached in vendor/cache and will require pulling from GitHub during builds.

preview: https://researcher-metadata-ui-fix.dev.k8s.libraries.psu.edu/