Next: , Previous: , Up: API  


1.9 (hygguile components select)

1.9.1 Procedures

Procedure: glyph-option KEY: #:value #:glyph #:content #:family #:selected-value #:option-flex-css

Construct an HTML option styled with an inline icon or glyph indicator.

value

The structural form state value string assigned to the option.

glyph

An S-expression fragment or character representing the icon prefix element.

content

The text label descriptive string. Defaults to value if false.

family

List of symbols representing layout font family CSS classes.

selected-value

The active control target state tracker matching criteria.

option-flex-css

List of symbols determining internal flexbox element alignment constraints.

(glyph-option #:value "nl" #:glyph "🇳🇱" #:content "Nederlands")
Procedure: option KEY: #:value #:content #:family #:selected-value

Construct an HTML <option> element.

If selected-value matches value, the option will render with a selected attribute status.

value

The structural form state value string assigned to the option.

content

The visual display text string or inner components. Defaults to value if false.

family

List of symbols representing font family CSS classes applied if selected.

selected-value

The active value configuration used to evaluate selection symmetry.

(option #:value "light" #:content "Cozy Light Theme" #:selected-value "dark")
Procedure: select KEY: #:options #:on-change #:name #:id #:family #:select-classes

Construct a dropdown list interactive selection menu wrapper.

options

A list of option or glyph-option S-expressions making up the menu rows.

on-change

A string JavaScript execution statement evaluated during interaction changes.

name

The element name context configuration string bound onto target HTML form tracking.

id

The unique DOM string selector matching layout identifier tables.

family

List of symbols representing base structural font choices.

select-classes

List of symbols specifying visual layout styles for the component wrapper card.

(select #:id "theme-picker"
        #:on-change "console.log('Changed!')"
        #:options (list (option #:value "dim")))

Next: (hygguile components typography), Previous: (hygguile components notification), Up: API