Defines self-contained content that could exist independently of the rest of the content.
Defines the main or important content in the document. There is only one
main element in the document.
Use the context passed in to create an Html node
Turn an Html context msg from elm-html-with-context into an Html.msg from elm/html
Represents a summary, caption, or legend for a given details.
Represents a widget from which the user can obtain additional information or controls.
Represents a scalar measurement (or a fractional value), within a known range.
Represents the completion progress of a task.
Represents the result of a calculation.
Represents a multiline text edit control.
Represents an option in a select element or a suggestion of a datalist
element.
Represents a set of options, logically grouped.
Represents a set of predefined options for other controls.
Represents a control allowing selection among a set of options.
Represents a button.
Represents a typed data field allowing the user to edit the data.
Represents the caption of a form control.
Represents the caption for a fieldset.
Represents a set of controls.
Represents a form, consisting of controls, that can be submitted to a server for processing.
Represents a header cell in a table.
Represents a data cell in a table.
Represents a row of cells in a table.
Represents the block of rows that describes the column summaries of a table.
Represents the block of rows that describes the column labels of a table.
Represents the block of rows that describes the concrete data of a table.
Represents a column of a table.
Represents a set of one or more columns of a table.
Represents the title of a table.
Represents data with more than one dimension.
Defines a mathematical formula.
Represents a bitmap area for graphics rendering.
Allows authors to specify timed text track for media elements like video
or audio.
Allows authors to specify alternative media resources for media elements
like video or audio.
Represents a sound or audio stream.
Represents a video, the associated audio and captions, and controls.
Defines parameters for use by plug-ins invoked by object elements.
Represents an external resource, which is treated as an image, an HTML sub-document, or an external resource to be processed by a plug-in.
Represents a integration point for an external, often non-HTML, application or interactive content.
Embedded an HTML document.
Represents an image.
Defines a removal from the document.
Defines an addition to the document.
Represents a line break opportunity, that is a suggested point for wrapping text in order to improve readability of text split on several lines.
Represents a line break.
Represents text with no specific meaning. This has to be used when no other
text-semantic element conveys an adequate meaning, which, in this case, is
often brought by global attributes like class, lang, or dir.
Represents the directionality of its children, in order to explicitly override the Unicode bidirectional algorithm.
Represents text that must be isolated from its surrounding for bidirectional text formatting. It allows embedding a span of text with a different, or unknown, directionality.
Represents parenthesis around a ruby annotation, used to display the annotation in an alternate way by browsers not supporting the standard display for annotations.
Represents the text of a ruby annotation.
Represents content to be marked with ruby annotations, short runs of text presented alongside the text. This is often used in conjunction with East Asian language where the annotations act as a guide for pronunciation, like the Japanese furigana.
Represents text highlighted for reference purposes, that is for its relevance in another context.
Represents a non-textual annotation for which the conventional presentation is underlining, such labeling the text as being misspelt or labeling a proper name in Chinese text.
Represents a text which to which attention is drawn for utilitarian purposes. It doesn't convey extra importance and doesn't imply an alternate voice.
Represents some text in an alternate voice or mood, or at least of different quality, such as a taxonomic designation, a technical term, an idiomatic phrase, a thought, or a ship name.
Represent a superscript.
Represent a subscript.
Represents user input, often from the keyboard, but not necessarily; it may represent other input, like transcribed voice commands.
Represents the output of a program or a computer.
Represents a variable. Specific cases where it should be used include an actual mathematical expression or programming context, an identifier representing a constant, a symbol identifying a physical quantity, a function parameter, or a mere placeholder in prose.
Represents computer code.
Represents a date and time value; the machine-readable equivalent can be represented in the datetime attribute.
Represents an abbreviation or an acronym; the expansion of the abbreviation can be represented in the title attribute.
Represents a term whose definition is contained in its nearest ancestor content.
Represents an inline quotation.
Represents the title of a work.
Represents content that is no longer accurate or relevant.
Represents a side comment, that is, text like a disclaimer or a copyright, which is not essential to the comprehension of the document.
Represents especially important text.
Represents emphasized text, like a stress accent.
Represents a hyperlink, linking to another resource.
Represents a generic container with no special meaning.
Represents the legend of a figure.
Represents a figure illustrated as part of the document.
Represents the definition of the terms immediately listed before it.
Represents a term defined by the next dd.
Defines a definition list, that is, a list of terms and their associated definitions.
Defines a item of an enumeration list.
Defines an unordered list of items.
Defines an ordered list of items.
Represents a content that is quoted from another source.
Indicates that its content is preformatted and that this format must be preserved.
Represents a thematic break between paragraphs of a section or article or any longer content.
Defines a portion that should be displayed as a paragraph.
Defines the main or important content in the document. There is only one
main element in the document.
Defines a section containing contact information.
Defines the header of a page or section. It often contains a logo, the title of the web site, and a navigational table of content.
Defines some content loosely related to the page content. If it is removed, the remaining content still makes sense.
Defines self-contained content that could exist independently of the rest of the content.
Defines a section in a document.
Transform the messages produced by some Html. In the following example,
we have viewButton that produces () messages, and we transform those values
into Msg values in view.
type Msg = Left | Right
view : model -> Html Msg
view model =
div []
[ map (\_ -> Left) (viewButton "Left")
, map (\_ -> Right) (viewButton "Right")
]
viewButton : String -> Html ()
viewButton name =
button [ onClick () ] [ text name ]This should not come in handy too often. Definitely read this before deciding if this is what you want.
Just put plain text in the DOM. It will escape the string so that it appears exactly as you specify.
text "Hello World!"General way to create HTML nodes. It is used to define all of the helper functions in this library.
div : List (Attribute msg) -> List (Html msg) -> Html msg
div attributes children =
node "div" attributes childrenYou can use this to create custom nodes if you need to create something that is not covered by the helper functions in this library.
Set attributes on your Html. Learn more in the
Html.Attributes module.
The core building block used to build up HTML. Here we create an Html
value with no attributes and one child:
hello : Html msg
hello =
div [] [ text "Hello!" ]
Use the context passed in to create an Html attribute