Jump to content
tpr

AdminOnSteroids

Recommended Posts

Fortunately I have a maximum of 1 dev site and 1 live, and I mostly work on the dev and merge changes. But I see your pain :) This is where your red-colored admin header will be of great help :)

  • Like 1

Share this post


Link to post
Share on other sites

v054 is up. There were many updates under the hood so make sure to clear browser and module cache.

  • module settings are exported to settings.php on uninstall and restored on install
  • load admin.js and admin.css from /site/templates/ directory if exist
  • new tweak "NavItems" (experimental): add pages to main nav or sidebar (depending on theme)
  • HTML classes added by AOS are added by PHP instead JavaScript: faster and eliminates initial page jump so the loader is no longer needed
  • loader removed
  • added "cog" icon to footer to jump to AOS settings
  • fix: keep sidebar menu colors for non-inline mode (Reno theme)
  • module CSS classnames were abbreviated
  • Like 2

Share this post


Link to post
Share on other sites

You do realise that if you (and Adrian with Tracy) keep developing your modules at this rate, they will become sentient before I do.

  • Like 4

Share this post


Link to post
Share on other sites

No, it's the other way: we just try to bring you the most of what the module is capable before you get sentient :)

  • Like 2

Share this post


Link to post
Share on other sites

hi tpr,

short (maybe) bugreport: i think the field-name-tooltips do not get loaded when using ajax collapsed fields. can you confirm that?

Share this post


Link to post
Share on other sites

Yes, it fails because the labels aren't surrounded by span tags but can't figure out why. I'll try to find it out or solve this by Js.

Share this post


Link to post
Share on other sites

Here's another one:

Screen Shot 2016-08-31 at 8.35.19 AM.png

Seems to happen after a field has been collapsed.

  • Like 1

Share this post


Link to post
Share on other sites

Yep, just discovered that, it's been fixed, thanks.

Anyone knows why ajax-loaded fields doesn't allow modifying the label with Inputfield::render (or renderValue)? I can add link to the inputfield and other things too but this one doesn't work. Its value is set before thea ajax event runs, and of course it doesn't modify the existing label markup on the page. But where does it come from then?

I could solve this issue with JS but it's not pretty.

Share this post


Link to post
Share on other sites

Hi tpr,

for me v054 gives an error just after updating:

Parse error: syntax error, unexpected '.', expecting ',' or ';' in /Users/armin/Websites/pwreiter/site/assets/cache/FileCompiler/site/modules/AdminOnSteroids/AdminOnSteroids.module on line 23

I'm running on PW 3.0.32 in local environment (MAMP). I had no issues with past versions of AdminOnSteroids.

  • Like 1

Share this post


Link to post
Share on other sites

Thanks, that was a PHP version syntax error which was fixed.

v055 is up:

  • module settings restore is optional (disabled by default)
  • JS workaround for field edit links for ajax-loaded fields
  • syntax error fix (thanks to TomasKostadinov)
  • Like 1

Share this post


Link to post
Share on other sites

Just wanted to let you know that the sticky header isn't sticking for me with the latest 3.0.32 devns and the default theme.  Seems like it started after I upgraded to 3.0.32.  I'm also using the latest AOS.  I have hard refresh the browser several times.

Share this post


Link to post
Share on other sites

I can't reproduce this. Have you tried clearing the module cache (at the bottom of the Modules page)?

If that doesn't help, could you post the body and html classes your admin has? 

Share this post


Link to post
Share on other sites

Strange.  It still didn't work.  I clicked the clear compiled files button at /admin/module/.  I also did a module refresh.  I'm using the latest Google Chrome on a mac.

Here are my body classes when editing a page.

id-10 template-admin hasWireTabs AdminThemeDefault ProcessPageEdit-id-1002 ProcessPageEdit-template-basic-page pw-ready InputfieldColumnWidthsInit

Share this post


Link to post
Share on other sites

Thanks - could you post the classes on the "html" tag? That would be more helpful.

Share this post


Link to post
Share on other sites

I was afraid of that :) Anyway, try v056, hopefully this is solved now. You should see classes appear on the html element.

Share this post


Link to post
Share on other sites

I just updated to v056 and here are my html element classes

<html class=" headSticky HoverDropdown moduleCompact moduleModal" lang="en">

and

<body class="id-10 template-admin hasWireTabs AdminThemeDefault ProcessPageEdit-id-1015 ProcessPageEdit-template-left-sidebar pw-ready InputfieldColumnWidthsInit">

So I have classes now, but the header still isn't sticking.  Sorry... I'm trying to find the problem as well.

Share this post


Link to post
Share on other sites

The default theme is missing the "AdminThemeDefault" class on the html element.  After I added that manually it worked.

Share this post


Link to post
Share on other sites

Actually I bet what is happening is the AOS css is targeting the html element when it should be targeting the body element on line 2166 of AdminOnSteriods.scss

Share this post


Link to post
Share on other sites

After reading the comment in the scss file

// AdminTweaks (default theme tweaks)
// note: the default theme adds theme name class only to body, AOS adds to html

maybe AOS isn't adding the class "AdminThemeDefault" to the html element in the default admin theme in AdminOnSteriods.module line 243?

Share this post


Link to post
Share on other sites

It's intentional to use html.AdminThemeDefault (as you figured out already).

What I don't get how your html classes doesn't contain 'AdminThemeDefault' because it should be added by AOS.

echo wire('user')->admin_theme;

This should echo "AdminThemeDefault", could you try it?

Share this post


Link to post
Share on other sites

I added that snippet to a template file, but it didn't output anything.  I also have Tracy debugger and tried using the php console, but it didn't output anything either.

Share this post


Link to post
Share on other sites

No idea then atm... do you have other PW installation where you could check AOS?

  • Like 1

Share this post


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

What I don't get how your html classes doesn't contain 'AdminThemeDefault' because it should be added by AOS.

I've just updated to 0.5.6, and I do get the AdminThemeReno class and the sticky header.

  • Like 1

Share this post


Link to post
Share on other sites

Well it's the AdminThemeDefault class what's in question when using the default theme.

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By eelkenet
      Hi! I've created a small Inputfield module called InputfieldFloatRange which allows you to use an HTML5 <input type="range" ../> slider as an InputField. I needed something like this for a project where the client needs to be able to tweak this value more based on 'a feeling' than just entering a boring old number. Maybe more people can use this so I'm hereby releasing it into the wild. 
      EDIT: You can now install it directly from the Modules directory: http://modules.processwire.com/modules/inputfield-float-range/
       
      What is it?
      The missing range slider Inputfield for Processwire. 
      What does it do?
      This module extends InputfieldFloat and allows you to use HTML5 range sliders for number fields in your templates.
      It includes a visible and editable value field, to override/tweak the value if required.  
      Features
      Min/max values Precision (number of decimals) Optional step value (Read more) Optional manual override of the selected value (will still adhere to the rules above) Configurable rounding of manually entered values (floor, round, ceil, disable) Usage
      Clone / zip repo Install FieldtypeFloatRange, this automatically installs the Inputfield Create new field of type `Float (range)` or convert an existing `Float`, `Integer` or `Text` field. To render the field's value simply echo `$page->field` Demo
      A field with Min=0, Max=1, Step=0.2, Precision=2

      Field with settings Min=0, Max=200, Step=0.25, Precision=2

       
      Todo
      Make the display-field's size configurable (will use the Input Size field setting)  Hopefully become redundant  
      Changelog
      005 (current version)
      - Fix bug where the Inputfield would not work properly within repeaters / repeater matrices
      004
      - Make rounding of manually entered values configurable (floor, round, ceil or disable)
      - Fix small JS bug when the value-display field was not displayed
      - Update README
      003
      - Code cleanup, add some ModuleInfo data & LICENSE
      - Submit to PW Modules directory (http://modules.processwire.com/modules/inputfield-float-range/)
      002
      - Fix issue where setting the step value to an empty value created problem with validation
      - Make the display-field optional
      001
      - Initial release
       
      Thanks!
       
       
    • By Gadgetto
      Status update links (inside this thread) for SnipWire development will be always posted here:
      2019-10-18
      2019-08-08
      2019-06-15
      2019-06-02
      2019-05-25
      If you are interested, you can test the current state of development:
      https://github.com/gadgetto/SnipWire
      Please note that the software is not yet intended for use in a production system (alpha version).
      If you like, you can also submit feature requests and suggestions for improvement. I also accept pull requests.
      ---- INITIAL POST FROM 2019-05-25 ----
      I wanted to let you know that I am currently working on a new ProcessWire module that fully integrates the Snipcart Shopping Cart System into ProcessWire. (this is a customer project, so I had to postpone the development of my other module GroupMailer).
      The new module SnipWire offers full integration of the Snipcart Shopping Cart System into ProcessWire.
      Here are some highlights:
      simple setup with (optional) pre-installed templates, product fields, sample products (quasi a complete shop system to get started immediately) store dashboard with all data from the snipcart system (no change to the snipcart dashboard itself required) Integrated REST API for controlling and querying snipcart data webhooks to trigger events from Snipcart (new order, new customer, etc.) multi currency support self-defined/configurable tax rates etc. Development is already well advanced and I plan to release the module in the next 2-3 months.
      I'm not sure yet if this will be a "Pro" module or if it will be made available for free.
      I would be grateful for suggestions and hints!
      (please have a look at the screenshots to get an idea what I'm talking about)
       




    • By Robin S
      Another little admin helper module...
      Template Field Widths
      Adds a "Field widths" field to Edit Template that allows you to quickly set the widths of inputfields in the template.

      Why?
      When setting up a new template or trying out different field layouts I find it a bit slow and tedious to have to open each field individually in a modal just to set the width. This module speeds up the process.
      Installation
      Install the Template Field Widths module.
      Config options
      You can set the default presentation of the "Field widths" field to collapsed or open. Field widths entered into the Template Field Widths inputfield are only applied if the Edit Template form is submitted with the Template Field Widths inputfield in an opened state. "Collapsed" is the recommended setting if you think you might also use core inputs for setting field widths in a template context. You can choose Name or Label as the primary identifier shown for the field. The unchosen alternative will become the title attribute shown on hover. You can choose to show the original field width next to the template context field width.  
      https://github.com/Toutouwai/TemplateFieldWidths
      https://modules.processwire.com/modules/template-field-widths/
    • By adrian
      Tracy Debugger for ProcessWire
      The ultimate “swiss army knife” debugging and development tool for the ProcessWire CMF/CMS

       
      Integrates and extends Nette's Tracy debugging tool and adds 35+ custom tools designed for effective ProcessWire debugging and lightning fast development
      The most comprehensive set of instructions and examples is available at: https://adrianbj.github.io/TracyDebugger
      Modules Directory: http://modules.processwire.com/modules/tracy-debugger/
      Github: https://github.com/adrianbj/TracyDebugger
      A big thanks to @tpr for introducing me to Tracy and for the idea for this module and for significant feedback, testing, and feature suggestions.
×
×
  • Create New...