Skip to main content

Text API Overview

Initialization

<script>
import { Text } from "@wx/svelte-core";
</script>

<!-- minimal configuration for initialization -->
<Text />
tip
  • Visit the Features Guide to learn more about the control's functionality.
  • Explore the samples to visualize the available features.

Text Properties

csssets the position of the icon in an input
disableddefines whether the Text control is disabled
errordefines whether error styling is applied to the Text control
focussets focus in an input
iconadds an icon into an input
idsets an HTML id for a text input
inputstyleapplies a custom style to an input field
placeholdersets a placeholder for an input
readonlydefines whether an input is read-only
selectselects the content of an input
titlesets a tooltip text with additional info about the Text control
typesets the type of the Text control
valuesets the value of an input

Text Events

inputfires on change of the value of an input, i.e. on the HTML input event