Action buttons: positioning
Poll

Where do you like your action buttons best?

At the top of my posts, like it used to be.
0 (0%)
Below my posts, like now.
16 (72.7%)
Either way is fine to me.
2 (9.1%)
Either way is awkward to me, at least for now.
1 (4.5%)
I think they should be located on planet Mars, where at least with a good telescope I might be able to notice them.
3 (13.6%)
Total Members Voted: 20

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Action buttons: positioning
« Reply #75, on May 17th, 2012, 05:15 PM »
I never understood how the whole 'auto' thing works. Might as well say 'left: magic' for all the good it does ;)
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

Nao

  • Dadman with a boy
  • Posts: 16,082

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Action buttons: positioning
« Reply #77, on May 17th, 2012, 09:41 PM »
But for example in the context of margins, what does 'default' mean, exactly?

It feels like it's just a meaningless term.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Action buttons: positioning
« Reply #78, on May 17th, 2012, 11:00 PM »
Quote from Arantor on May 17th, 2012, 09:41 PM
But for example in the context of margins, what does 'default' mean, exactly?
Well... Zero?
Quote
It feels like it's just a meaningless term.
Hmm I don't know. To me, it simply means "let the browser calculate this automatically based on other data available..."

Anyway. So, I did my commit...
You'll mainly notice two hacks that I couldn't get rid of -- namely for IE8 and iPhone, in their respective stylesheets.
I'd really like to know if anyone manages to remove these hacks without breaking anything. ESPECIALLY on the iPhone, because AFAIK, Safari Mobile is a decent browser, unlike IE, and I don't get why it's not following my queries regarding positioning... :-/

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
A confident man keeps quiet.whereas a frightened man keeps talking, hiding his fear.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Action buttons: positioning
« Reply #80, on May 18th, 2012, 01:10 AM »
This is what I mean, it feels like magic and voodoo.

At first brush, all looks good to me, will test more properly later on.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Action buttons: positioning
« Reply #81, on May 18th, 2012, 07:23 AM »
Quote from live627 on May 18th, 2012, 01:09 AM
But then what would happen if the browser default for a margin on a particular tag (<p>) isn't zero?
Sorry, I forgot -- margin: auto centers the thing. So it doesn't set the margin to zero, obviously... ;)
Re: Action buttons: positioning
« Reply #82, on May 18th, 2012, 12:15 PM »
Decided to create all mini-menus at page load rather than on the fly. Saved over 30 gzipped bytes. Yay. Until I realized it added a whole second of load time to IE6... On my super-modern PC running XP in a box. Must be pretty close to regular numbers, especially since even Opera in my Win7 takes 0.15s to run it.
Back to square one...
Anyway, I've saved about 10 gzipped bytes by keeping to the on-the-fly creation thingy, which is better than nothing...

OTOH, I've added an extra 10 bytes to script.js just to filter correctly the click event on main menus.
Remember how someone complained that clicking the top-level item in the profile menu would close the menu and clicking it again would do nothing...? Well, the goal wasn't to close the menu, but to close any menu after a click was made, to give a feeling of responsiveness, i.e. "I've registered your call, I'm processing it." However, in the profile menu, there's no link in the top-level item, so it just closes it and does nothing... I had two solution: either I added a filter (for an extra ~10b) or removed the entire click event (to save a whopping ~20 bytes). In the end, I decided to use the filter (.filter(':has(>a,>h4>a)')), because I really like the responsiveness thing... But it also wastes 30 bytes in total, eh.

So, my solution to this...
Well, it's pretty elegant if you will... Although it's totally unrelated :lol:
I 'simply' moved we_avatarResize() to a new file. This function is ~150 bytes gzipped, and it's not used by default (one has to enable a feature in the admin area, "resize with JavaScript" or something.)
That's it... New script file is now 120 bytes smaller, ahah, I love my cache system.

Totally OT now...

A quick poll... I'm thinking of doing a small rewrite to $context['javascript_files']. Instead of adding strings to the array ( [] = 'script.js' ), you would add an indexed array ( ['script.js'] = true ), where 'true' means 'add the filename to the final filename' while false would ignore it.
While it isn't useful right now, I can imagine that some modders would like to be able to add their files to the main script, *and* not have them pollute the final filename. Right now, it's not possible to do it because the list of ignored filenames (custom, sbox, theme, and now avasize) is hardcoded into our source files...
Since it makes the javascript_files array a bit harder to understand than just using a simple list of files, I'd rather ask because there's always a fine line between customizability (English??) and complexity.
Posted: May 18th, 2012, 11:38 AM
Quote from Nao on May 18th, 2012, 11:38 AM
A quick poll... I'm thinking of doing a small rewrite to $context['javascript_files']. Instead of adding strings to the array ( [] = 'script.js' ), you would add an indexed array ( ['script.js'] = true ), where 'true' means 'add the filename to the final filename' while false would ignore it.
Implemented. I can always revert, but I'm pretty happy with it. :)
Except for the fact that the $ignore_files flag now acts differently in both add_js_file and add_css_file... Meh!
Re: Action buttons: positioning
« Reply #83, on May 18th, 2012, 07:21 PM »
Okay, another set of questions...

I'd like to add mini-menus to more buttons.
Let's see if we can set something up that would make sense and improve usability?

- Like: I already mentioned it, there are several links that could be added to it...
- Quote: main link points to the default setup...? Opening it in a new tab points to full quote either way. Additional links: disambiguation -- Quick quote, Full quote.
- Modify: main link points to quick edit, but opening it in a new tab points to full edit. Additional links: disambiguation -- Quick edit, Full edit.

What do you think...?

Also, should the Modify button be placed where it is, and the Quick Edit button removed entirely? Or should the Modify button be placed to the right of More? (Renaming More to Actions...?) Or should both buttons stay?

Re: Action buttons: positioning
« Reply #84, on May 18th, 2012, 07:42 PM »
Function buttons always are meant to people who know how to use them, I'm always struggling in my forum with the newbies teaching them and making tutorials on how to use Report button, posting, navigating AeMe. Whatever, I got Off-Topic lol.

Personally I like to have all actions in one place. Edit, quick edit, report should be in the More menu.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Action buttons: positioning
« Reply #85, on May 18th, 2012, 07:45 PM »
Anything in the more menu should be things you don't use often. I don't want to discourage people from quick editing their posts to fix a typo they found while re-reading it...!

Re: Action buttons: positioning
« Reply #86, on May 18th, 2012, 07:51 PM »
Yeah, even when nothing is wrong I edit some parts of a large post to make it look better.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Action buttons: positioning
« Reply #87, on May 18th, 2012, 07:53 PM »
Plus, if instead of a quick edit button, you had a button that clearly said "full edit" or "quick edit", that's something that newbies will appreciate...

(Hmm, here's wondering if we should add some kind of warning that although edits are allowed, the threshold for 'last modified' has expired...)

Re: Action buttons: positioning
« Reply #88, on May 18th, 2012, 07:59 PM »
What if the topic starter have a check button with "No edit" except for the topic starter (or the first post), that way people can't edit their posts within a time limit.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Action buttons: positioning
« Reply #89, on May 18th, 2012, 08:58 PM »
Bump... :whistle:
Quote from Nao on May 18th, 2012, 07:21 PM
Okay, another set of questions...

I'd like to add mini-menus to more buttons.
Let's see if we can set something up that would make sense and improve usability?

- Like: I already mentioned it, there are several links that could be added to it...
- Quote: main link points to the default setup...? Opening it in a new tab points to full quote either way. Additional links: disambiguation -- Quick quote, Full quote.
- Modify: main link points to quick edit, but opening it in a new tab points to full edit. Additional links: disambiguation -- Quick edit, Full edit.

What do you think...?

Also, should the Modify button be placed where it is, and the Quick Edit button removed entirely? Or should the Modify button be placed to the right of More? (Renaming More to Actions...?) Or should both buttons stay?