<xf:if is="$event.isInsert()">
	<xf:title>{{ phrase('add_code_event') }}</xf:title>
<xf:else />
	<xf:title>{{ phrase('edit_code_event:') }} {$event.event_id}</xf:title>
</xf:if>

<xf:pageaction if="$event.isUpdate()">
	<xf:button href="{{ link('code-events/delete', $event) }}" icon="delete" overlay="true" />
</xf:pageaction>

<xf:form action="{{ link('code-events/save', $event) }}" ajax="true" class="block">
	<div class="block-container">
		<div class="block-body">
			<xf:textboxrow name="event_id" value="{$event}"
				label="{{ phrase('event_id') }}"
				dir="ltr" />

			<xf:codeeditorrow name="description" value="{$event.description}" mode="html"
				label="{{ phrase('description') }}"
				hint="{{ phrase('you_may_use_html') }}" />

			<xf:macro id="addon_macros::addon_edit" arg-addOnId="{$event.addon_id}" />
		</div>
		<xf:submitrow sticky="true" icon="save" />
	</div>

</xf:form>