When changing a page layout using the latest Panopoly dev, I get a page full of variables after hitting the Save button. The layout change happens, but you have to back out or otherwise input a URL into the address bar to see it.
To reproduce:
- Install Panopoly dev (commit da14b87), accepting all defaults
- Go to a demo page such as Lovely Vegetables
- Click Change layout
- Select a different layout, such as Radix Bryant Flipped
- Click Save
- Note that the browser is full of JSON
- Hit the browser Back button
- Note you are on the Lovely Vegetables page, and the layout has been changed
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | panopoly_test-change-layout-error-2476227-1.patch | 3.83 KB | dsnopek |
| #1 | panopoly_images-change-layout-error-2476227-1.patch | 2.99 KB | dsnopek |
| layout-change-error.png | 450.96 KB | cboyden |
Comments
Comment #1
dsnopekThanks! We desperately need tests for changing the layout via IPE to prevent breaking this in the future, so I'll try to come up with something.
It turns out that the Javascript for #2287805: Caption filter does not work with Quarter Size image format - or with floated captions. was being activated on the 'Change layout' dialog because the layout icons use the class 'caption'. I've got a patch to fix it, which is attached!
(I also noticed another issue with that functionality when looking into this: #2476543: <meta> tag getting added to the WYSIWYG output)
Comment #2
dsnopekHere is a patch that adds a test for the 'Change layout' dialog. It fails without the panopoly_images patch, and succeeds with it!
In order to actually click a layout in the dialog, I had to add a temporary CSS hack that unhides the labels hidden in panopoly_theme. This should be removed once we have a solution to #2427993: Layout names not available to screenreaders in "Change layout" dialog
I'm going to run this on Travis-CI, and if all looks good, I'll commit!
EDIT: Here's the build on Travis: https://travis-ci.org/panopoly/panopoly/builds/59723619
Comment #3
dsnopekComment #4
dsnopekOk, Travis reported success on the new test! So, I've committed this.