deploy: b0455046e5
This commit is contained in:
13
docs/references/elements/CheckBox.md
Normal file
13
docs/references/elements/CheckBox.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# CheckBox
|
||||
_The CheckBox is a visual element that can be checked._
|
||||
|
||||
Extends: `VisualElement`
|
||||
|
||||
## Properties
|
||||
|
||||
|Property|Type|Default|Description|
|
||||
|---|---|---|---|
|
||||
|checked|boolean|Whether|checkbox is checked|
|
||||
|text|string|empty|Text to display|
|
||||
|checkedText|string|Text|when checked|
|
||||
|autoSize|boolean|true|Whether to automatically size the checkbox|
|
||||
@@ -2,7 +2,7 @@
|
||||
_This is the ComboBox class. It extends the dropdown functionality with editable text input,_
|
||||
_allowing users to either select from a list or type their own custom text._
|
||||
|
||||
Extends: `Dropdown`
|
||||
Extends: `DropDown`
|
||||
|
||||
## Properties
|
||||
|
||||
|
||||
13
docs/references/elements/DropDown.md
Normal file
13
docs/references/elements/DropDown.md
Normal file
@@ -0,0 +1,13 @@
|
||||
# DropDown
|
||||
_This is the DropDown class. It is a visual element that can show a list of selectable items in a DropDown menu._
|
||||
|
||||
Extends: `List`
|
||||
|
||||
## Properties
|
||||
|
||||
|Property|Type|Default|Description|
|
||||
|---|---|---|---|
|
||||
|isOpen|boolean|false|Whether the DropDown menu is currently open|
|
||||
|dropdownHeight|number|5|Maximum height of the DropDown menu when open|
|
||||
|selectedText|string|""|The text to show when no item is selected|
|
||||
|dropSymbol|string|"\31"|The symbol to show for DropDown indication|
|
||||
43
docs/references/elements/FlexBox.md
Normal file
43
docs/references/elements/FlexBox.md
Normal file
@@ -0,0 +1,43 @@
|
||||
# FlexBox
|
||||
_This is the FlexBox class. It is a container that arranges its children in a flexible layout._
|
||||
_The flexbox element adds the following properties to its children:_
|
||||
|
||||
Extends: `Container`
|
||||
|
||||
## Properties
|
||||
|
||||
|Property|Type|Default|Description|
|
||||
|---|---|---|---|
|
||||
|flexDirection|string|"row"|The direction of the flexbox layout "row" or "column"|
|
||||
|flexSpacing|number|1|The spacing between flex items|
|
||||
|flexJustifyContent|string|"flex-start"|The alignment of flex items along the main axis|
|
||||
|flexAlignItems|string|"flex-start"|The alignment of flex items along the cross axis|
|
||||
|flexCrossPadding|number|0|The padding on both sides of the cross axis|
|
||||
|flexWrap|boolean|false|Whether to wrap flex items onto multiple lines|
|
||||
|
||||
## Functions
|
||||
|
||||
|Method|Returns|Description|
|
||||
|---|---|---|
|
||||
|[FlexBox:addChild](#flexbox-addchild-element)|FlexBox|Adds a child element to the flexbox|
|
||||
|[FlexBox:addLineBreak](#flexbox-addlinebreak-self)|FlexBox|Adds a new line break to the flexbox.|
|
||||
|
||||
## FlexBox:addChild(element)
|
||||
|
||||
Adds a child element to the flexbox
|
||||
|
||||
### Parameters
|
||||
* `element` `Element` The child element to add
|
||||
|
||||
### Returns
|
||||
* `FlexBox` `self` The flexbox instance
|
||||
|
||||
## FlexBox:addLineBreak(self)
|
||||
|
||||
Adds a new line break to the flexbox
|
||||
|
||||
### Parameters
|
||||
* `self` `FlexBox` The element itself
|
||||
|
||||
### Returns
|
||||
* `FlexBox`
|
||||
47
docs/references/elements/ScrollBar.md
Normal file
47
docs/references/elements/ScrollBar.md
Normal file
@@ -0,0 +1,47 @@
|
||||
# ScrollBar
|
||||
_A ScrollBar element that can be attached to other elements to control their scroll properties_
|
||||
|
||||
Extends: `VisualElement`
|
||||
|
||||
## Properties
|
||||
|
||||
|Property|Type|Default|Description|
|
||||
|---|---|---|---|
|
||||
|value|number|0|Current scroll value|
|
||||
|min|number|0|Minimum scroll value|
|
||||
|max|number|100|Maximum scroll value|
|
||||
|step|number|1|Step size for scroll operations|
|
||||
|dragMultiplier|number|1|How fast the ScrollBar moves when dragging|
|
||||
|symbol|string|"|" Symbol used for the ScrollBar handle|
|
||||
|backgroundSymbol|string|"\127"|Symbol used for the ScrollBar background|
|
||||
|symbolBackgroundColor|color|black|Background color of the ScrollBar handle|
|
||||
|backgroundSymbol|string|"\127"|Symbol used for the ScrollBar background|
|
||||
|minValue|number|function|0|Minimum value or function that returns it|
|
||||
|maxValue|number|function|100|Maximum value or function that returns it|
|
||||
|orientation|string|vertical|Orientation of the ScrollBar ("vertical" or "horizontal")|
|
||||
|handleSize|number|2|Size of the ScrollBar handle in characters|
|
||||
|
||||
## Functions
|
||||
|
||||
|Method|Returns|Description|
|
||||
|---|---|---|
|
||||
|[ScrollBar:attach](#scrollbar-attach-element-config)|ScrollBar|Attaches the ScrollBar to an element's property|
|
||||
|[ScrollBar:updateAttachedElement](#scrollbar-updateattachedelement)|ScrollBar|Updates the attached element's property based on the ScrollBar value|
|
||||
|
||||
## ScrollBar:attach(element, config)
|
||||
|
||||
Attaches the ScrollBar to an element's property
|
||||
|
||||
### Parameters
|
||||
* `element` `BaseElement` The element to attach to
|
||||
* `config` `table` Configuration {property = "propertyName", min = number|function, max = number|function}
|
||||
|
||||
### Returns
|
||||
* `ScrollBar` `self` The ScrollBar instance
|
||||
|
||||
## ScrollBar:updateAttachedElement()
|
||||
|
||||
Updates the attached element's property based on the ScrollBar value
|
||||
|
||||
### Returns
|
||||
* `ScrollBar` `self` The ScrollBar instance
|
||||
Reference in New Issue
Block a user