-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
33 changed files
with
1,860 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
@api Visualization Bar | ||
@inline api/*.um |
22 changes: 22 additions & 0 deletions
22
docs/content/docs/visualization-bar/api/VisualizationBar.um
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
@prototype hx.VisualizationBar | ||
@collapsed false | ||
@added nextReleaseVersion | ||
@description | ||
|
||
@constructor | ||
@collapsed false | ||
@arg selector [String/HTMLElement/Selection] | ||
The selector to create the visualization bar inside | ||
|
||
@arg options [Object] | ||
@collapsed false | ||
@inline ./options/*.um | ||
|
||
@function hx.visualizationBar | ||
@collapsed false | ||
@added nextReleaseVersion | ||
@description | ||
Create a visualization bar component wrapped in a selection | ||
|
||
@arg options [Object] | ||
@inline ./options/*.um |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
@property? breakdown [String] | ||
@description | ||
The 'breakdown text' to display below the visualization bar. This can be used | ||
to explain what each segment is, or how the calculation is performed. |
39 changes: 39 additions & 0 deletions
39
docs/content/docs/visualization-bar/api/options/segments.um
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
@property segments [Array[Segment]] | ||
@description | ||
The array of segments to display. At least one segment is required to render a | ||
visualization bar. Segments can also be shown with a zero value. | ||
|
||
@extra | ||
@object Segment | ||
@property id [String] | ||
@description | ||
A unique identifier string used to ensure segments are rendered in the correct order | ||
|
||
@property? label [String] | ||
@description | ||
The text label shown below the segment. If a label is provided, the percentage of the | ||
total for the segment is also shown. | ||
|
||
If no label is provided, only the count is shown on the segment. | ||
|
||
@property count [Number] | ||
@description | ||
The number to display in this segment. A count is required for each segment, | ||
however it can be @code[0] | ||
|
||
@property? type [String] | ||
@description | ||
The type (i.e. colour) of the segment. | ||
|
||
Available types are: | ||
|
||
@list | ||
@item: default (or @code[undefined] type) | ||
@item: light | ||
@item: medium | ||
@item: dark | ||
@item: danger | ||
@item: warning | ||
@item: done | ||
@item: in-progress | ||
@item: todo |
Oops, something went wrong.