Budibase is an open-source low-code platform for creating internal apps in minutes. Supports PostgreSQL, MySQL, MSSQL, MongoDB, Rest API, Docker, K8s 🚀
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

31 lines
782 B

<script>
import "@material/select/helper-text/mdc-select-helper-text.scss"
import { onMount } from "svelte"
import { MDCSelectHelperText } from "@material/select/helper-text"
import ClassBuilder from "../ClassBuilder.js"
const cb = new ClassBuilder("select-helper-text")
let helperText
let instance
export let id = ""
export let text = ""
export let persistent = false
onMount(() => {
if (!!helperText) {
instance = new MDCSelectHelperText(helperText)
return () => {
instance && instance.destroy()
instance = null
}
}
})
$: modifiers = { persistent }
$: props = { modifiers }
$: helperClass = cb.build({ props })
</script>
<p bind:this={helperText} {id} class={helperClass} aria-hidden="true">{text}</p>