meilisearch-admin/app/components/input-textarea.hbs

26 lines
654 B
Handlebars
Raw Normal View History

2022-03-26 15:46:45 +00:00
<div class="mb-4">
{{#if @label}}
<label for={{this.id}} class="block font-medium mb-1 text-dark">{{@label}}</label>
{{/if}}
2022-04-13 08:26:24 +00:00
<div class="relative flex items-center border rounded-md border-gray">
2022-03-26 15:46:45 +00:00
{{#if @prefixIcon}}
<MdIcon
@icon={{@prefixIcon}}
2022-04-13 08:26:24 +00:00
class="h-8 w-8 pl-2"
2022-03-26 15:46:45 +00:00
/>
{{/if}}
<textarea
type="text"
name={{@name}}
id={{this.id}}
class="block w-full p-2 bg-transparent focus:outline-none"
placeholder={{@placeholder}}
2022-03-28 11:20:06 +00:00
{{on 'change' this.onChange}}
2022-03-26 15:46:45 +00:00
>{{@value}}</textarea>
</div>
2022-03-28 10:37:09 +00:00
{{#if @helper}}
<div class="mt-1 text-sm">{{@helper}}</div>
{{/if}}
2022-03-26 15:46:45 +00:00
</div>