Class Audio
java.lang.Object
io.mindspice.simplypages.core.HtmlTag
io.mindspice.simplypages.components.media.Audio
- All Implemented Interfaces:
Component
HTML audio wrapper with boolean media attribute helpers.
Mutable and not thread-safe. Source/attribute configuration updates this instance in place. Mutate within a request-scoped flow. For reuse, stop mutating and render as a stable structure with per-request slot/context values.
-
Field Summary
Fields inherited from class HtmlTag
attributes, children, id, innerText, innerTextSlot, selfClosing, tagName, trustedHtml -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic AudioCreates audio with the trusted/context-validated source contract ofAudio(String).Alias forHtmlTag.addClass(String).withControls(boolean controls) Sets or removes the native playback controls.withLoop()withPreload(String preload) Methods inherited from class HtmlTag
addClass, addStyle, addTrustedStyle, getChildrenStream, getId, hxDelete, hxGet, hxInclude, hxPatch, hxPost, hxPushUrl, hxPut, hxScrollTargetTop, hxSwap, hxTarget, hxTrigger, render, withAttribute, withChild, withId, withInnerText, withInnerText, withMaxWidth, withMinWidth, withUnsafeHtml, withWidth
-
Constructor Details
-
Audio
Creates audio with an application-controlled or separately media-context-validated source. Attribute encoding does not validate URL schemes, destinations, or media payloads.
-
-
Method Details
-
create
Creates audio with the trusted/context-validated source contract ofAudio(String). -
withControls
-
withControls
Sets or removes the native playback controls. -
withAutoplay
-
withLoop
-
withMuted
-
withPreload
-
withClass
-