Skip to main content

Filter groups

A filter group writes the picked value into the variable named by filter-target, which reloads the page or the reactive zones watching it.

filter-group.buttons​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired buttonsnoneDefines the filter group type.
defaultRequirednoneSpecifies the default filter value. Must be one of the <filter> values
filter-targetRequirednoneSpecifies the variable that the filter will set.
CAUTION

Allowed Children: Only <filter type="button"> and <filter type="dynamic-button">.


filter.button​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired buttonnoneFilter type; should match parent group.
filter-valueRequirednoneValue for filtering.
pathRequirednonePath template for visual states.
tooltip-textOptionalnoneTooltip text for additional info.
CAUTION

Parent Constraint: Must be placed inside a <filter-group type=buttons>.

path is expected to be a parametrized path to the images used for normal, over and clicked state.
UCHTML will then substitute normal hover and selected to the parameter of the string.

Example:

path="d:/ymir work/ui/example/group_b_{}.tga"

become

d:/ymir work/ui/example/group_b_normal.tga
d:/ymir work/ui/example/group_b_hover.tga
d:/ymir work/ui/example/group_b_selected.tga

And each of the images need to exist in order to render the button.

Code Example
<filter-group display="flex" justify-content="space-evenly" type="buttons" default="packed_query:GROUP_A"
width="auto" filter-target="query:race">
<filter type="button" path="d:/ymir work/ui/example/group_a_{}.tga" filter-value="packed_query:GROUP_A">
</filter>
<filter type="button" path="d:/ymir work/ui/example/group_b_{}.tga" filter-value="packed_query:GROUP_B">
</filter>
<filter type="button" path="d:/ymir work/ui/example/group_c_{}.tga" filter-value="packed_query:GROUP_C">
</filter>
<filter type="button" path="d:/ymir work/ui/example/group_d_{}.tga" filter-value="packed_query:GROUP_D">
</filter>
</filter-group>

image


filter.dynamic-button​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired dynamic-buttonnoneFilter type; should match parent group.
filter-valueRequirednoneValue for filtering.
textRequirednoneText displayed on the button.
tooltip-textOptionalnoneTooltip information.
CAUTION

Parent Constraint: Must be placed inside a <filter-group type=buttons>.

Code Example
<filter-group display="flex" justify-content="space-evenly" type="buttons" default="foo"
width="auto" filter-target="query:race">
<filter type="dynamic-button" height=25 width="70" text="foo" tooltip-text="foo" filter-value="foo"></filter>
<filter type="dynamic-button" height=25 width="70" text="bar" tooltip-text="bar" filter-value="bar"></filter>
<filter type="dynamic-button" height=25 width="70" text="check" tooltip-text="check" filter-value="check"></filter>
</filter-group>

image


filter-group.list​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired listnoneDefines the filter group type.
defaultRequirednoneSpecifies the default filter value. Must be one of the <filter> values
filter-targetRequirednoneSpecifies the variable that the filter will set.
CAUTION

Allowed Children: Only <filter type=item>.

image


filter.item​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired itemnoneFilter type identifier.
filter-valueRequirednoneValue associated with the filter item.
textRequirednoneDisplay text for the item.
tooltip-textOptionalnoneAdditional tooltip info.
CAUTION

Parent Constraint: Must be placed inside a <filter-group type=list>.


filter-group.tabs​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired tabsnoneDefines the filter group type.
defaultRequirednoneSpecifies the default filter value. Must be one of the <filter> values
filter-targetRequirednoneSpecifies the variable that the filter will set.
CAUTION

Allowed Children: Only <filter type=tab>.

Code Example
<filter-group type="tabs" filter-target="query:tab" width="auto" default="info">
<filter type="tab" height="25" width="100" padding="5" filter-value="info">
<txt color="wikititle" align="center">Foo</txt>
</filter>
<filter type="tab" height="25" width="100" padding="5" filter-value="up">
<txt color="wikititle" align="center">Bar</txt>
</filter>
</filter-group>

image


filter.tab​

AttributeRequirementDefaultConstraints/Notes
Base AttributesOptionalN/AInherits all common base attributes.
typeRequired tabnoneFilter type identifier.
filter-valueRequirednoneValue used for filtering.
heightRequirednoneSpecifies the height of the tab.
CAUTION

Parent Constraint: Must be placed inside a <filter-group type=tabs>.