Support from Acquia helps fund testing for Drupal Acquia logo

Comments

-enzo-’s picture

The current patch require the image will be copied inside folder panels_ipe/images/

After apply the patch, when a user tried to customize a panel page using IPE a third bottom for preview will be enabled as you can see in the following image.

After click the preview bottom all IPE elements will be hidden, providing a close look & feel to end user to final result before the user save the panel page.

The end user always can return to the regular IPE interfaz to continue adding elements

GDrupal’s picture

Status: Active » Reviewed & tested by the community

It works great for me. RTBC +1

japerry’s picture

Status: Reviewed & tested by the community » Needs work

Unfortunately when you have this option enabled, the preview button actually ends up saving the IPE.

eugene.brit’s picture

Thanx for the patch :)
I added some changes, because I had some propblems.
I used Panopoly 1.2, with Panels 3.4.
When I added some content to the page, then clicked Preview and finally clicked Cancel, I got edit form on the view page(see screenshot).
screenshot
So I changed
Drupal.PanelsIPE.editors[this.element_settings.ipe_cache_key].initEditing();
to
Drupal.PanelsIPE.editors[this.element_settings.ipe_cache_key].showForm();

Also, I wrapped all text in t() and added css styles like an IPE buttons.

drasgardian’s picture

Status: Needs work » Needs review
FileSize
6.61 KB

The patch in #4 was in the wrong format and wouldn't apply so I've tried to merge those changes into a new patch.

The

Drupal.PanelsIPE.editors[this.element_settings.ipe_cache_key].initEditing();

to

Drupal.PanelsIPE.editors[this.element_settings.ipe_cache_key].showForm();

change mentioned above seems to cause me more problems though - the IPE bar disappears when closing the add content dialog box. So I left that change out.

I could not replicate the issue described in #3

Status: Needs review » Needs work

The last submitted patch, 5: enable_inline_preview_IPE-2242835-5.patch, failed testing.

gaborpeter’s picture

Patch #1 worked like a charm, thank you very much

drasgardian’s picture

Status: Needs work » Needs review
FileSize
8.19 KB

re-roll of #5 to apply against latest head attached.

muschpusch’s picture

Assigned: -enzo- » Unassigned
Status: Needs review » Reviewed & tested by the community

Works great and is pretty straight forward

The last submitted patch, 4: enable_inline_preview_IPE-2242835-4.patch, failed testing.

japerry’s picture

Status: Reviewed & tested by the community » Needs work

If you delete a pane from IPE and hit cancel, the expected result is that the pane will come back without having to reload the page.
With the preview functionality, if you delete a pane, then hit the preview button, then cancel, the pane stays gone until you reload the page.

davidsheart02’s picture

I believe the reason the IPE/Cancel functionality wasn't working as expected with the latest patch is because the command to initEditing was resetting things that shouldn't have been reset. I've changed it to simply show the ipe toolbar and it appears to be working as expected.

davidsheart02’s picture

I realized that the patch didn't apply cleanly against the latest dev. Here's the updated version. Same deal as before, expects the preview icon to be in place in the aforementioned folder.

davidsheart02’s picture

Status: Needs work » Needs review
davidsheart02’s picture

Erg... double checked and still ran into an error applying that last patch... Next time I'll test before I post. This one worked cleanly for me.

satrece’s picture

In #17 button value does not change button text when i click on preview. In panels_ipe.js
Instead
$(this.element).attr('value', 'Preview off')
should use the below
$(this.element).attr('value', 'Preview off').html('Preview off');

same goes to else condition also
$(this.element).attr('value', 'Preview')
should use the below
$(this.element).attr('value', 'Preview').html('Preview');

Also after click on 'preview off' lines are not visible on the panels so in 'else' condition
Instead of
$('.panels-ipe-editing').removeClass('panels-ipe-previewing').addClass('panels-ipe-editing');
should use as below
$('.panels-ipe-previewing').removeClass('panels-ipe-previewing').addClass('panels-ipe-editing');

satrece’s picture

In #17 button value does not change button text when i click on preview. In panels_ipe.js
I have updated in the patch

supriyahj’s picture

Hi Fellas,

Do we have inline preview for "Change Layout" ipe by any chance in Drupal 7?

Description: Just like "Customize this page", we also have "Change Layout". Onclick of "Change Layout" we can able to change to the opted layout. Currently, we do not have the option to preview the changed layout page by default.

Can anyone please share the patch/link for the same? or can anyone please guide how to preview the changed layout before saving the layout(panels_change_layout_submit).

Regards,
Supriya