Edgewall Software
Modify

Opened 15 years ago

Closed 15 years ago

#8839 closed enhancement (fixed)

Improve the plugin admin panel

Reported by: Remy Blank Owned by: Remy Blank
Priority: normal Milestone: 0.12
Component: admin/web Version: devel
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

The current plugin admin panel has several drawbacks:

  • The components are listed in seemingly random order, which makes finding a specific component difficult.
  • The only information displayed for each component is the package and component name. This is not enough for users to decide if they want specific components enabled or disabled.

I have improved the panel to group the components by package, and to display the docstrings of both components and packages if available. Descriptions are initially collapsed, and can be shown using JavaScript. A fallback is also available if JavaScript is disabled.

Feedback welcome.

Attachments (2)

8839-plugin-admin-panel-r8829.patch (41.9 KB ) - added by Remy Blank 15 years ago.
Improved plugin admin panel.
8839-plugin-admin-panel-r8885.patch (44.0 KB ) - added by Remy Blank 15 years ago.
Improved collapsing.

Download all attachments as: .zip

Change History (10)

by Remy Blank, 15 years ago

Improved plugin admin panel.

comment:1 by Remy Blank, 15 years ago

The patch also fixes many component docstrings for consistency. More docstrings could be added if desired.

comment:2 by Christian Boos, 15 years ago

Quite nice.

I'm not sure however the tooltip for the summary is the best thing here, it should be possible to get an overview at once. And despite the component name being highlighted as a link, it's not obvious you'd get the description by clicking on it, so I'd prefer something like:

 ComponentName            summary .....   [+]

And the description should then appear as a smaller text, maybe a bit like the hint style.

Perhaps also have an "expand/collapse all descriptions " button somewhere?

One little thing: there's a typo in trac/admin/web_ui.py, Return the docstring of an object as a a tuple .

in reply to:  2 comment:3 by Remy Blank, 15 years ago

Replying to cboos:

I'm not sure however the tooltip for the summary is the best thing here,

I wasn't sure either. The summary is actually repeated when you expand the description, so the tooltip is not strictly necessary.

it should be possible to get an overview at once.

I thought this would be too crowded, but I'll try and see.

And despite the component name being highlighted as a link, it's not obvious you'd get the description by clicking on it, so I'd prefer something like:

Yes, why not. Will try.

Perhaps also have an "expand/collapse all descriptions " button somewhere?

This I'm not sure. Some of the descriptions are pretty lengthy (e.g. authz_policy.py). OTOH, a "show all / hide all" link at the top somewhere wouldn't harm, I suppose.

Thanks for the suggestions, I'll try them and report back.

by Remy Blank, 15 years ago

Improved collapsing.

comment:4 by Remy Blank, 15 years ago

The patch above is an improved version taking into account comment:2. I know I'm biased, but I think this just went from "quite nice" to "really usable" :-)

comment:5 by Christian Boos, 15 years ago

When expanding the descriptions for Trac components, as there are a few code blocks in the markup, we easily end up with a larger width than what can be displayed - same problem as for #8866, so I suppose that when we fix it, the problem will also be fixed here.

What would you think about using monospace font for the component names, and maybe display the module paths as e.g. trac.mimeview.*, as a hint about how this will look like in the TracIni.

  • trac/admin/templates/admin_plugins.html

    diff --git a/trac/admin/templates/admin_plugins.html b/trac/admin/templates/admin_plugins.html
    a b  
    127127                        href="${href.admin('general', 'plugin', show=not show_doc and module_name or None)
    128128                                + '#trac-mod-' + module_name}">${show_doc and '&ndash;' or '+'}</a>]
    129129                  </span>
    130                   ${module_name}
     130                  <span class="trac-name">${module_name}.*</span>
    131131                  <span py:if="module.summary" class="trac-summary"> &mdash; ${module.summary}</span>
    132132                </p>
    133133                <div py:if="module.description" xml:space="preserve">${wiki_to_html(context, module.description)}</div>
     
    143143                        href="${href.admin('general', 'plugin', show=not show_doc and component.full_name or None)
    144144                                + '#trac-comp-' + component.full_name}">${show_doc and '&ndash;' or '+'}</a>]
    145145                  </span>
    146                   ${component_name}
     146                  <span class="trac-name">${component_name}</span>
    147147                  <span py:if="component.summary" class="trac-summary"> &mdash; ${component.summary}</span>
    148148                </p>
    149149                <div py:if="component.description" xml:space="preserve">${wiki_to_html(context, component.description)}</div>
  • trac/htdocs/css/admin.css

    diff --git a/trac/htdocs/css/admin.css b/trac/htdocs/css/admin.css
    a b  
    6262.plugin .listing { width: 100% }
    6363.plugin .listing td { background: #fff }
    6464.trac-heading { margin: 0 }
     65.trac-name { font-family: monospace }
    6566.trac-toggler { float: right; color: #000; font-weight: normal }
    6667.trac-toggler :link, .trac-toggler :visited,
    6768.trac-toggler :link:hover, .trac-toggler :visited:hover {

in reply to:  5 comment:6 by Remy Blank, 15 years ago

Replying to cboos:

What would you think about using monospace font for the component names, and maybe display the module paths as e.g. trac.mimeview.*, as a hint about how this will look like in the TracIni.

I wanted to try monospace at some point, but I forgot :) What is better: using font-family: monospace on a <span> or wrapping in <tt></tt>?

comment:7 by Christian Boos, 15 years ago

<tt> fits better in "rich text", inside paragraphs. Here it's not the case and more part of the structure of the information in the page, so span + class is perhaps more appropriate. No idea if this is common practice or not, it's just my opinion ;-)

comment:8 by Remy Blank, 15 years ago

Resolution: fixed
Status: newclosed

Functionality committed in [8899], including the suggestions in comment:5. Thanks!

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Remy Blank.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Remy Blank to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.