Script Summary: Adds preview to bugzilla.mozilla.org.
License: This program is in the public domain.
When posting bugs or comments in Bugzilla, we often make careless mistakes (wrong bug numbers, bad formatting, etc.) Although we are supposed not to worry too much about careless mistakes in Bugzilla, we actually do. This Greasemonkey user script adds the preview functionality to bugzilla.mozilla.org which helps you notice those mistakes before posting them.
This script has been tested with Greasemonkey 0.8.20090123.1 on Firefox 3.5.2.
Here is a screenshot. (Uh, clicking it does nothing....)
The current script does not work with Bugzilla Helper. This means that for most Bugzilla users (i.e. those without the “canconfirm” permission bit), this script is only useful when posting a comment, not when posting a new bug.
Absolutely no warranty
This script can break any functionality of Bugzilla. Moreover, it will probably get broken by changes in Bugzilla in future, and I may leave it as it is. Use it at your own risk.
Version 0.2: Version 0.1 introduced a bug that clicking on a comment produced an error “target.getAttribute('onclick') is null” in the Error Console.
Version 0.1: Preview was not updated when a user clicked the [reply] link. Now it is.
A version-less version: Added a
Another version-less version: Initial release without
User goal vs organizational goal: Why isn’t preview already in Bugzilla?
Keep in mind that there is a reason that the preview functionality is not implemented in Bugzilla, and that the reason is not because it is technically difficult. See bug 40896: Bugzilla needs a "preview" mode. I wrote this script because I did not agree the reason given by Bugzilla developers. It is up to you whether you use this script or not, but I strongly wish that you understand the pros and cons of having the preview functionality in Bugzilla before you decide to use it.
I understand Bugzilla developers’ concern: providing a preview not only reduces careless mistakes, but also sets up a new standard, makes a community less tolerant of careless mistakes, makes people feel (perhaps unconscious) pressure to avoid careless mistakes, and reduces productivity as a result. Nevertheless, I believe that users’ desire to avoid careless mistakes is more important than Bugzilla developers’ goal on productivity. To take a radical position, I do not mind lowering productivity of a community, I mind me making careless mistakes, and I want to help the users who think in the same way as me. Call me a selfish community-breaker if you like.
I see this as an example of conflict between a user goal and an organizational goal. Users want to avoid making careless mistakes in public, whereas Bugzilla developers want to develop an atomosphere where people see careless mistakes often enough so that they do not mind them at all. Read more about the difference between user goals and organizational goals in Chapter 5 of a book “About Face 3: The Essentials of Interaction Design” by Cooper, Reimann and Cronin (Wiley, 2007). I agree to the authors’ argument that successful software products meet user goals first and their emphasis on the design principle “Don’t make the user feel stupid.”