<div id="cck-complete-percent-bar-wrapper-'. $id .'">

should be replaced by

<div class="cck-complete-percent-bar-wrapper">

so we can do a generic style of the percent bar regardless of the content type CC applies to

Comments

floretan’s picture

I would keep both the id and the class, so that existing styles don't get broken with an update.

<div id="cck-complete-percent-bar-wrapper-'. $id .'" class="cck-complete-percent-bar-wrapper">
pvhee’s picture

Status: Active » Closed (fixed)

I have added both id and class to the latest dev, for the wrapper and the bar.

In addition, I've added new classes to have more options to style the percent bar, depending on the percentage. For example, you can use '.cck-complete-percent-bar-leq-25' to style the appearance of the percent bar if the percent is lower or equal (leq) to 25. Likewise, there are classes for leq-50, leq-75 and leq-100. Absolute numbers can be styled using '.cck-complete-percent-bar-x', with x replacing the actual percentage.