box
Content copied to clipboard
This component represents the simplest layout component possible: A simple `div` that acts as a container for arbitrary content.
In fact it is more or less a shorthand for styling a `div` manually and so to avoid the cumbersome syntax of `BasicComponent.styled`
Example usage:
box({
/* styling expressions */
border {
color { dark }
size { normal }
style { solid }
}
}) {
p { +"Some content in the box" }
}Content copied to clipboard
Parameters
styling
a lambda expression for declaring the styling as fritz2's styling DSL
base Class
optional CSS class that should be applied to the element
id
the ID of the element
prefix
the prefix for the generated CSS class resulting in the form `$prefix-$hash`
content
a lambda expression for setting up the content and events of the `div` element itself