tpr

Module
AdminOnSteroids

848 posts in this topic

Yes, that's an issue that needs some thinking. Do you think globally disabling to remember position would be enough?

Also now all splitters share the same splitter setting which is probably not suitable for everyone. I guess I can fix this easily though.

Another idea borrowed from file managers to use double click on the splitter to restore the default position. So you can drag it freely and it would be remembered but you could restore defaults when needed.

1 person likes this

Share this post


Link to post
Share on other sites
21 minutes ago, tpr said:

Do you think globally disabling to remember position would be enough?

I think the key thing is that when there is no position stored in LocalStorage, it should use the field's width setting (default or template context override) as it did before.

22 minutes ago, tpr said:

Another idea borrowed from file managers to use double click on the splitter to restore the default position. So you can drag it freely and it would be remembered but you could restore defaults when needed.

Yeah, something like that sounds good.

 

Share this post


Link to post
Share on other sites

Ok, all shoud be fine in v139. One thing that I removed is the drag handler icon. I couldn't find a way to show it nicely so now the only thing that indicates the splitter is the mouse cursor.

There was an issue with the splitter's height too. Now it's set by JS because I didn't want to go flex and risk breaking other things.

From the docs:

Quote

From v137 columns are resizable by dragging the gutter between the columns. The splitter position is remembered per template and per user. Double-click on the splitter to restore the default position (set at aos_column_break field's "Column Width" setting, or defaults to the module's default value).

This feature is not available inside tabs.

 

1 person likes this

Share this post


Link to post
Share on other sites
2 minutes ago, tpr said:

Ok, all shoud be fine in v139. One thing that I removed is the drag handler icon. I couldn't find a way to show it nicely so now the only thing that indicates the splitter is the mouse cursor.

There was an issue with the splitter's height too. Now it's set by JS because I didn't want to go flex and risk breaking other things.

Looks and works great now - thanks!

1 person likes this

Share this post


Link to post
Share on other sites

Hi @tpr,

I just noticed that the position of the restore icon for PageListSelect looks a bit off when the field is inside a repeater:

2017-03-24_170618.png.8c9a4919926dc187684f97a1b34786ad.png

Share this post


Link to post
Share on other sites

hi tpr, the draggable devider looks great. would it be possible to add this feature also to the core pw-panel?

Share this post


Link to post
Share on other sites

I'm talking about the built in panel. Just add the class "pw-panel pw-panel-right" to a link and it opens in a sidebar panel like this:

58d528220521d_2017-03-2415_04_11-Akquiseliste.thumb.png.85d447c5c6d8d5c1593b6b45f332268c.png

It's similar to the modal, but newer and i prefer it over modals. It's great to open PDFs for a preview for example. Or to open items in my datatables.

See \wire\modules\Jquery\JqueryUI\panel.js for details. Would be awesome to make those panels draggable :) 

Share this post


Link to post
Share on other sites

The "Tree" panel is already draggable here, and also the "View page" panel.

But it's a different thing than in case of columns, here you only resize one element.

1 person likes this

Share this post


Link to post
Share on other sites
On 24.3.2017 at 3:32 PM, tpr said:

The "Tree" panel is already draggable here, and also the "View page" panel.

But it's a different thing than in case of columns, here you only resize one element.

thanks for making me aware of this! works only on left-aligned panels though... https://github.com/processwire/processwire/blob/50f2834a0ae2a9f9f2ac53439184ebdc04db2f54/wire/modules/Jquery/JqueryUI/panel.js#L411-L432

better than nothing :)

 

Share this post


Link to post
Share on other sites

Handy shortcuts to edit translations in a textdomain file in other languages in the upcoming version:

aos-translator-links.png

2 people like this

Share this post


Link to post
Share on other sites

The abovementioned feature is available in v141, plus a new CKEditor plugin Indent Block and some minor updates.

4 people like this

Share this post


Link to post
Share on other sites

@tpr, I often want to work with system templates. Examples being:

  • Add fields to the user template, and want easy access to the template from the admin menus or without having to set the "Show system templates" filter in the templates list.
  • When editing a field, add that field to the template of a repeater field.

Normally to do stuff like this you have to have $config->advanced = true in /site/config.php, but I don't want the risk of messing up the other things that this setting exposes. So I looked at making system templates visible through hooks and came up with this:

// Show system templates
$this->addHookBefore('ProcessField::buildEditFormInfo', function($event) {
    // Show system templates in templates list of Edit Field
    $this->wire('config')->advanced = true;
});
$this->addHookBefore('ProcessTemplate::executeNavJSON', function($event) {
    // Show system templates in admin menu
    $this->wire('config')->advanced = true;
});
$this->addHookAfter('Session::loginSuccess(roles=superuser)', null, function($event) {
    // Show system templates in templates list unless explicitly hidden
    $this->wire('session')->set('ProcessTemplateFilterSystem', 1);
});

Is this something you think would be a good option to add to AOS?

2 people like this

Share this post


Link to post
Share on other sites
7 minutes ago, Robin S said:

would be a good option to add to AOS

+1 :)

Share this post


Link to post
Share on other sites
8 hours ago, Robin S said:

Is this something you think would be a good option to add to AOS?

Sure, I'll have a look later. 

 

8 hours ago, Robin S said:

$this->addHookAfter('Session::loginSuccess(roles=superuser)', null, function($event) {

This "(roles=superuser)" is new to me. Is there somewhere I can read more about this (and similar tricks)?

Share this post


Link to post
Share on other sites

@tpr, another idea/request: if the "permanent delete" option for Page List is checked then there is also an option to permanently delete the page from the Delete tab of Page Edit.

2017-04-03_103048.png.1b4254c7495135eb2f4c35b628366bcb.png

Thanks!

2 people like this

Share this post


Link to post
Share on other sites

How about:

Confirm to move to Trash        Permanently delete instead

to make it less confusing?

Share this post


Link to post
Share on other sites

Hey @tpr - as I mentioned here: https://github.com/ryancramerdesign/AdminThemeUikit/issues/20, the icons only PageList option doesn't work in the UiKit theme sidebar. Now maybe Ryan will add this option to the core, but if not, it would be good to get fixed in AoS. Also, the full width hover links don't work. And also wondering if you can make an icon for the template link in the PageList - this would also help with allowing the width of the sidebar to be narrower.

I understand that the UiKit theme is still a moving target, so just ideas for you at the moment :)

Share this post


Link to post
Share on other sites

I'll have a look on the above issues/requests later, nowadays I'm busy with a 4.04 kg newborn who thinks he can steal all the hours in a day (and night) :) 

7 people like this

Share this post


Link to post
Share on other sites
1 minute ago, tpr said:

4.04 kg newborn

That sounds like a baby on steroids!!! :D:D

Congratulations! ^-^

3 people like this

Share this post


Link to post
Share on other sites

Sure :) It's the second and I thought the first one is on steroids... Now I know I was very wrong :) 

5 people like this

Share this post


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

It's the second and

Keep up the good work! You need to keep your sanity so that you will also be able to have fun with the third one too ;)

1 person likes this

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.

  • Similar Content

    • By benbyf
      HELLO!
      I've been working on a user messaging module which I am nearly ready to release as version 1.
      Currently I have the below functionality and I'm looking for feedback to what other things may be useful for people looking to add user to user messaging on their sites.
      compose message to one or more users known to PW js to enable tag based UI display of user names input on compose message form display all message threads with reply forms reply to message thread displaying each user name by each message in the thread display "unread" when a thread has new content that hasnt been seen by current user delete or unpublish message thread (configurable) display total message thread count display total unread threads (threads that have new replies that the current user has not seen) delete all message threads and associated data (not meant for the users to have access to) road map
      send email to user on new message to a thread they are included in
    • By louisstephens
      So I was working on a module and trying to include a library (so I could use it across the site) using $modules->get('myModule'); . However, When I go to include the library folder (modeled after the LibFlourish module created some time ago). I keep getting: 
      site/modules/MyModule/libraryName/ProcessWire\filetoinclude.php This comes with an error notifying that "failed to open stream: No such file or directory in ...".. Is ProcessWire supposed to be in the include url, or is there a way around this? Sorry, I am quite new to working with my own modules.
       
      I just noticed the sub forum regarding Development, if someone could move this to the correct area I would appreciate it.
    • By louisstephens
      I wasn't quite sure where to post this, as this is a question regarding the module (sorry if it is in the wrong place). I was wondering if anyone has used the Email to Page module and figured out a way to "move" incoming css to another field, or how to render the css so the message just renders utilizing the css. 
      Right now all of the message contents get dropped into a textarea field and display in a template as a jumbled mess. Perhaps I am missing a formatting option in the text area field to render the css and html.
    • By blynx
      Hej,
      just finished the first working version of my photoswipe bundle. https://github.com/blynx/MarkupProcesswirePhotoswipe
      Haven't published it to the module directory, yet. Wanted to wait for some feedback.
      You can add a photoswipe enabled thumbnail gallery / lightbox to your site like this. Just pass an image field to the renderGallery method:
      <?php $pwpswp = $modules->get('Pwpswp'); echo $pwpswp->renderGallery($page->nicePictures); Options are provided like so:
      <?php $galleryOptions = [ 'imageResizerOptions' => [ 'size' => '500x500' 'quality' => 70, 'upscaling' => false, 'cropping' => false ], 'loresResizerOptions' => [ 'size' => '500x500' 'quality' => 20, 'upscaling' => false, 'cropping' => false ], 'pswpOptions' => (object) [ 'shareEl' => false, 'indexIndicatorSep' => ' von ', 'closeOnScroll' => false ] ]; echo $pswp->renderGallery($page->images, $galleryOptions); More info about all that is in the readme: https://github.com/blynx/MarkupProcesswirePhotoswipe
      It is possible to customize pretty much anything by providing your own templates and scripts.
      What do you think? Any ideas, bugs, critique, requests?
      cheers
      Steffen
    • By kixe
      FieldtypeColor is on github

      Fieldtype stores a 32bit integer value reflecting a RGBA value.
      Input
      4 types of Inputfields provided
      Html5 Inputfield of type='color' (if supported by browser)    Inputfield type='text' expecting a 24bit hexcode string (RGB). Input format: '#4496dd'.
      The background color of the input field shows selected color Inputfield of type='text' expecting 32bit hexcode strings (RGB + alpha channel) Input format: '#fa4496dd' Inputfield with Spectrum Color Picker
      (Options modifiable) Inputfield type='text' with custom JavaScript and/or CSS (since version 1.0.3) Output
      Define output format under 'Details' tab in field settings. Select from the following 8 options
      string 6-digit hex color. Example: '#4496dd' string 8-digit hex color (limited browser support).  Example: '#fa4496dd' string CSS color value RGB. Example: 'rgb(68, 100, 221)' string CSS color value RGB. Example: 'rgba(68, 100, 221, 0.98)' string CSS color value RGB. Example: 'hsl(227, 69.2%, 56.7%)' string CSS color value RGB. Example: 'hsla(227, 69.2%, 56.7%, 0.98)' string 32bit raw hex value. Example: 'fa4496dd' int 32bit. Example: '4198799069' (unformatted storage value) The Fieldtype includes
      Spectrum Color Picker by Brian Grinstead

      SCREENSHOTS
      Input type=text with changing background and font color (for better contrast)

      Input type=color (in Firefox)


      Javascript based input (Spectrum Color Picker)


      Settings Output

       
      Settings Input