Select
public final class Select : GenericElement
This class define a select element
### Usage Example: ###
let select = Select([["0-13": "0-13"],
["14-17": "14-17"],
["18-23": "18-23"]],
attr:("id", "ageRangeField"))
-
Override tag element for option. Default is
option
Declaration
Swift
override var tag: String { get }
-
Override container element for table row elements defaults is
true
Declaration
Swift
override var container: Bool { get }
-
List with array of
SelectOptionsType
default is []Declaration
Swift
public private(set) var options: SelectOptionsType { get }
-
Default initializer input select element
Declaration
Swift
public init(_ options: SelectOptionsType, attributes: AttributeType...)
Parameters
options
This is a options for select options
SelectOptionsType
attributes
This is a attr for select attributes
AttributeType...
CVarArg
-
This method iterates over the list of options and creates the option element for each of the items
Declaration
Swift
private func makeOptions()