{% load i18n %}
<b-notification :active.sync="showForm">
	<div class="subtitle">Send a message in {! formChan !}</div> 
	<form id="instant_form" onsubmit="return false" method="post">
		<div class="field has-addons">
			<div class="control has-icons-left is-expanded">
  				<input class="input is-medium" type="text" name="msg" placeholder="Message" v-model="formMsg" />
				<span class="icon is-left">
 					<i class="fas fa-envelope"></i>
				</span>
			</div>
			<div class="control"> 
				<button id="post-btn" class="button is-medium has-text-grey" @click="postInstantForm()" disabled>
					<span class="icon">
      					<i class="far fa-share-square"></i>
    				</span>	
    				<span>{% trans "Publish" %}</span>
				</button>
			</div>
		</div>
		<div class="control has-icons-left inline" style="max-width:12em;margin-right:1em">
 			<input class="input is-medium" type="text" name="msg_class" placeholder="Class" v-model="msgClass" />
			<span class="icon is-left">
				<i class="fas fa-code"></i>
			</span>
		</div>
		<div v-for="cl in eventLabels" class="inline">
			<span v-bind:id="cl.name"
				class="event-label inline"
				v-html="cl.label"
				@click="setEventLabel(cl.name)">
			</span>
		</div>
		<div class="control has-icons-left topmargin">
 			<input class="input is-medium" type="text" name="msg_data" placeholder="Json data" v-model="formData" />
			<span class="icon is-left">
				<i class="fas fa-coins"></i>
			</span>
		</div>
		<input type="hidden" name="channel" v-model="formChan" />
		{% csrf_token %}
	</form>
</b-notification>

