tpr

Front-End Edit Lightbox (FEEL) for ProcessWire

Recommended Posts

I can edit and re-edit an image with CI3 without any issue. How are you calling FEEL, or is anything specific in your setup?

Share this post


Link to post
Share on other sites

As for the future of FEEL, I think I'll rewrite it in TypeScript, to remove jQuery dependency and to learn TypeScript.

Share this post


Link to post
Share on other sites

This is how I'm calling FEEL:

		echo $page->feel(array(
		    "text" => "Edit your page",
		    "class" => "fixed center",
		    "fields" => "title,artist_business_name,body_artists,artist_address_01,artist_address_02,artist_address_suburb,artist_address_state,artist_address_postcode,artist_website,artist_facebook,artist_twitter,artist_instagram,artist_behance,artist_dribbble,artist_email_public,artist_phone_studio,artist_phone_mobile,artist_categories,portfolio_images,pinterest_button"
		    )
		);

I get the initial modal appearing and I can see all the CI3 fields but when I click on a pre-defined crop I get pushed to the page tree.

Share this post


Link to post
Share on other sites

Unfortunately I'm still was not able to reproduce. I'm using the latest CI3, FEEL and PW dev. I have tried with 2 CI3 fields on a page and with all 3 admin themes.

Perhaps you could check these:

  • does it happen with less fields (eg. "title, "oneCI3field"). If no, perhaps you could check which field causes the issue, and figure out why.
  • if you middle-click on the edit link, the admin opens in a new browser tab. If you edit the CI3 field now, perhaps there will be an error shown.
  • check if there's an Access defined on a CI3 field
  • is the page in a repeater?
  • is anything in the logs? (Admin\Setup\Logs)
  • is any JS error in the devtools console?

I can check the site if you give me access

Share this post


Link to post
Share on other sites

My apologies. It was an access issue for that user group - CI3 wasn't selected. Thanks for your help. - Marty

  • Like 1

Share this post


Link to post
Share on other sites

Hi, I'm wondering if there is an easy way to let it run on mobile devices e.g. iPhone. If I open it, the content in the lightbox won't scroll when I drag the conten within the iframe. The content behind is scrolling. Is it a but in my setup or is this normal behaviour?

Share this post


Link to post
Share on other sites

Hi,

I'm struggling with something :

  • My 'user' template has page-edit permission for my 'teacher' role
  • My 'teacher' role has page-edit, page-edit-front and profile-edit permissions

And yet if I type $user->feel() in my template page (while logged as a 'teacher' user), I get nothing 😞 If I add 'superuser' role to my logged-in teacher, I get the 'Edit' link. 

I thought $user were behaving like regular pages... So I've been looking thorugh all my permissions roles for hours but I can't get it to work... I'm lost... Maybe $user is not possible in this context ?

If anyone has an idea on where I could look or can explain what's going on here, I'd appreciate. 

Share this post


Link to post
Share on other sites

@hheyne I haven't checked the lightbox on small screens, but I will when I'll have some time. Could you uncomment line 96 in FrontEndEditLightbox.css (max-height: 90%;) and check if that makes a difference?

@celfred There is a permission called "user-admin", what if you assign it for the "teacher" user?

Share this post


Link to post
Share on other sites
Posted (edited)

@tpr Thanks for your quick reply, but with no luck.. I had tried to set the 'user-admin' permission to the 'teacher' role (and I'm trying again right now), but still no Edit link appearing. If I set 'superuser' role back, the link comes back... Another idea ?

More info : if I try to front-end edit using the built-in PW capabilities method D gives the same result : not editable even though I'm setting all permissions like superuser's permissions, but editable by double-clicking if I add the 'superuser' role to my 'teacher'. I just don't get it...

EDIT : As a follow-up, I have applied a workaround : building a linked page to my user (with a specific editable template) and behavior is now as expected... I should dig a little for the 'official' user profile page front-end edit, but I am not a 'superuser' myself 😉 

Edited by celfred
Follow up

Share this post


Link to post
Share on other sites
16 hours ago, tpr said:

@hheyne I haven't checked the lightbox on small screens, but I will when I'll have some time. Could you uncomment line 96 in FrontEndEditLightbox.css (max-height: 90%;) and check if that makes a difference?

@tpr thank you for your reply. Unfortunately this setting make not real difference at all.

 

 

Share this post


Link to post
Share on other sites

Hello,

Another question I have, related not only to FEEL module, but I'm facing it with it so here it is :

I load a page via ajax. In the loaded page, I would like to have a $page->feel() to have my front-end link, but the result is nothing. I thought having namespace ProcessWire; at the top of my ajax-loaded page would do the trick, but it doesn't...

Does anyone know what I should do ?

Thanks !

Share this post


Link to post
Share on other sites
On 8/14/2018 at 3:49 PM, celfred said:

More info : if I try to front-end edit using the built-in PW capabilities method D gives the same result : not editable even though I'm setting all permissions like superuser's permissions, but editable by double-clicking if I add the 'superuser' role to my 'teacher'. I just don't get it...

 

@celfredFEEL checks if a page is editable, but since $user->editable() return false (actually it's userEditable() method), the link is not displayed.

On 8/24/2018 at 5:53 PM, celfred said:

I load a page via ajax. In the loaded page, I would like to have a $page->feel() to have my front-end link, but the result is nothing.

Could you edit FrontEndEditLightBox.module and remove && !$this->wire('config')->ajax from line 82 and see if it work?

  • Thanks 1

Share this post


Link to post
Share on other sites
14 hours ago, matjazp said:

 

@celfredFEEL checks if a page is editable, but since $user->editable() return false (actually it's userEditable() method), the link is not displayed.

 

Thanks a lot for your explanation. I understand things better now 🙂 

Quote

Could you edit FrontEndEditLightBox.module and remove && !$this->wire('config')->ajax from line 82 and see if it work?

I've just tested and made sure my cache was up to date, but no change... What's surprising is that with the initial config, I tested somewhere else on my site and it worked. Of course, I double-checked all permissions for the template I'm trying to have the 'Edit' button for... and I'm testing only as a superuser. So that's still a bit myserious to me. But since the problem doesn't occur somewhere else, I guess I AM the culprit who messes things up. That's not a big deal either. I'll do more testing and come back here if I find an explanation.

Thanks for your help ! 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.