Project

General

Profile

Actions

Feature #3045

closed

Create 'clear formatting' button for profile editor

Added by Matt Gold about 10 years ago. Updated over 9 years ago.

Status:
Resolved
Priority name:
Normal
Assignee:
Category name:
Public Portfolio
Target version:
Start date:
2014-02-18
Due date:
% Done:

0%

Estimated time:
2.00 h
Deployment actions:

Description

Building on the discussion here - http://redmine.gc.cuny.edu/issues/3044 - a 'clear formatting' button may make it easier get rid of unwanted formats

Actions #1

Updated by Chris Stein about 10 years ago

This may be one solution if we keep having problems like in #3044
But, in the interest of time and until we are able to see if formatting issues are common, perhaps we could table this one?

Actions #2

Updated by Matt Gold about 10 years ago

  • Target version set to 1.6

Sounds good to me.

Actions #3

Updated by Boone Gorges about 10 years ago

  • Category name changed from Commons Profile to Public Portfolio
  • Estimated time set to 2.00 h

perhaps we could table this one?

Target version set to 1.6

cognitive dissonance

Actions #4

Updated by Matt Gold about 10 years ago

  • Target version changed from 1.6 to 1.7

Sorry.

Actions #5

Updated by Boone Gorges about 10 years ago

Ha, I just wasn't certain.

Actions #6

Updated by Boone Gorges over 9 years ago

I have added a Clear Formatting button in https://github.com/cuny-academic-commons/cac-advanced-profiles/commit/d234700886754ae4db53235ab55832bc58c22c48. This will be ready to test on cdev after we have finished using it for some other My Commons testing.

Actions #7

Updated by Matt Gold over 9 years ago

Thanks - looking forward to checking it out.

Actions #8

Updated by Boone Gorges over 9 years ago

  • Status changed from Assigned to Testing Required

Ready to test on cdev.

Actions #9

Updated by Boone Gorges over 9 years ago

Adding Chris and Samantha as watchers. Chris and Samantha, could you please have a look at the implementation on cdev? Log in > go to profile edit > create a free text widget > checkout the "Clear formatting" link. It's not particularly beautiful, and I'd be open to making minor design changes for 1.7. Thanks!

Actions #10

Updated by Matt Gold over 9 years ago

Looks like it works well to me. Many thanks, Boone.

Actions #11

Updated by Samantha Raddatz over 9 years ago

I agree - it works well!

There doesn't seem to be a way to undo after you've cleared the formatting. This could be frustrating for someone who changes their mind after clicking it or who clicks on it unintentionally. Would it be possible to add an undo link or to at least allow the functionality of the browser's undo?

Actions #12

Updated by Matt Gold over 9 years ago

Thanks, Samantha. I think that an undo button may be overkill, but allowing undos via browser/keyboard via cntrl-z seems reasonable if possible and not too heavy of a lift

Actions #13

Updated by Boone Gorges over 9 years ago

Samantha - I agree that at least enabling the ctrl-z undo would be nice. But supporting this is going to be quite difficult - clicking a hyperlink is not natively recorded by browsers as an undoable action, and I'm not sure that there's an API accessible to javascript that'd allow us to intervene into browser action history like this. The alternative would then be to fake it by capturing all ctrl-z keypresses and checking against some custom history, but this is likely to be pretty buggy, so I'd prefer to avoid it for 1.7 at this point.

Maybe we could mitigate this by requiring confirmation of "Clear formatting"? Ie a popup "Are you sure you want to remove all formatting from this field? OK/Cancel" This is doable for 1.7.

Actions #14

Updated by Matt Gold over 9 years ago

Maybe we could mitigate this by requiring confirmation of "Clear formatting"? Ie a popup "Are you sure you want to remove all formatting from this field? OK/Cancel" This is doable for 1.7.

That sounds very reasonable to me.

Actions #15

Updated by Samantha Raddatz over 9 years ago

Yep, sounds good. Thanks, Boone!

Thanks for explaining the ctrl-z limitation too. That's good to know going forward.

Actions #16

Updated by Boone Gorges over 9 years ago

  • Status changed from Testing Required to Resolved

Sounds good. I've added the confirm dialog here: https://github.com/cuny-academic-commons/cac-advanced-profiles/commit/c694ca52961423583427963c433e0caa151b8ca4 There are some issues on cdev that are making it impossible to deploy this for testing at the moment, but it sounds like I've gotten the testing that I needed for the moment. Thanks for the feedback - marking resolved.

Actions

Also available in: Atom PDF