<roundcube:include file="includes/layout.html" />
<roundcube:include file="includes/menu.html" />

<h1 class="voice"><roundcube:label name="calendar.calendar" /></h1>

<!-- calendars list -->
<div id="layout-sidebar" class="listbox" role="navigation" aria-labelledby="arial-label-calendars">
	<div class="header">
		<a class="button icon back-content-button" href="#back" data-hidden="big"><span class="inner"><roundcube:label name="back" /></span></a>
		<span id="aria-label-calendars" class="header-title"><roundcube:label name="calendar.calendars" /></span>
		<roundcube:button name="calendaractionsmenu" id="calendaroptionsmenulink" type="link"
			title="calendar.calendaractions" class="button icon sidebar-menu" data-popup="calendaractions-menu"
			innerClass="inner" label="actions" />
	</div>
	<roundcube:object name="libkolab.folder_search_form" id="calendarlistsearch" wrapper="searchbar menu"
		ariatag="h2" label="calsearchform" label-domain="calendar" buttontitle="findcalendars" />
	<div id="calendars-content" class="scroller">
		<roundcube:object name="plugin.calendar_list" id="calendarslist" class="treelist listing iconized" />
	</div>
	<h2 id="aria-label-minical" class="voice"><roundcube:label name="calendar.arialabelminical" /></h2>
	<div id="datepicker" class="calendar-datepicker" role="presentation"></div>
</div>

<!-- calendar -->
<div id="layout-content" class="selected no-navbar" role="main">
	<h2 id="aria-label-toolbar" class="voice"><roundcube:label name="arialabeltoolbar" /></h2>
	<div class="header" role="toolbar" aria-labelledby="aria-label-toolbar">
		<a class="button icon task-menu-button" href="#menu"><span class="inner"><roundcube:label name="menu" /></span></a>
		<a class="button icon back-sidebar-button folders" href="#sidebar" data-hidden="big"><span class="inner"><roundcube:label name="calendar.calendars" /></span></a>
		<span class="header-title"></span>
		<!-- toolbar -->
		<div id="calendartoolbar" class="toolbar menu">
			<roundcube:button command="addevent" type="link"
				class="button create disabled" classAct="button create"
				label="create" title="calendar.new_event" innerClass="inner" />
			<roundcube:button command="print" type="link" data-hidden="small"
				class="button print disabled" classAct="button print"
				label="calendar.print" title="calendar.printtitle" innerClass="inner" />
			<span class="spacer"></span>
			<roundcube:button command="events-import" type="link"
				class="button import disabled" classAct="button import"
				label="import" title="calendar.importevents" innerClass="inner" />
			<roundcube:button command="export" type="link"
				class="button export disabled" classAct="button export"
				label="calendar.export" title="calendar.exporttitle" innerClass="inner" />
			<roundcube:container name="toolbar" id="calendartoolbar" />
		</div>
	</div>
	<roundcube:object name="plugin.searchform" id="searchform" wrapper="searchbar menu"
		label="searchform" buttontitle="calendar.findevents" label-domain="calendar" ariatag="h2" />
	<h2 id="aria-label-calendarview" class="voice"><roundcube:label name="calendar.arialabelcalendarview" /></h2>
	<div id="calendar" class="content" role="main" aria-labelledby="aria-label-calendarview" data-elastic-mode="true">
		<roundcube:object name="plugin.agenda_options" id="agendaoptions" />
		<div id="searchcontrols" class="search-controls"></div>
	</div>
	<div class="footer toolbar menu content-frame-navigation" role="toolbar" data-hidden="big">
		<a href="#" class="button prev" onclick="$('.fc-prev-button').click()"><span class="inner"><roundcube:label name="previous" /></span></a>
		<a href="#" class="button today" onclick="$('.fc-today-button').click()"><span class="inner"><roundcube:label name="today" /></span></a>
		<a href="#" class="button date" onclick="window.calendar_datepicker()"><span class="inner"><roundcube:label name="date" /></span></a>
		<a href="#" class="button next" onclick="$('.fc-next-button').click()"><span class="inner"><roundcube:label name="next" /></span></a>
	</div>
</div>

<div id="timezone-display" class="hidden"><roundcube:var name="env:timezone" /></div>

<div id="eventshow" class="popupmenu formcontent propform text-only">
	<h1 id="event-title" class="event-title form-group">Event Title</h1>
	<div id="event-status-badge"><span></span></div>
	<div class="event-location form-group" id="event-location">Location</div>
	<div class="event-date form-group" id="event-date">From-To</div>
	<div class="event-description form-group" id="event-description">
		<div class="event-text"></div>
	</div>
	<div class="event-attendees form-group" id="event-attendees">
		<div class="event-text"></div>
	</div>
	<div id="event-url" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.url" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-repeat" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.repeat" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-alarm" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.alarms" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-partstat" class="form-group row event-partstat">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.mystatus" /></label>
		<span class="col-sm-8 form-control-plaintext">
			<span class="event-text rsvp-status"></span>
			<a class="changersvp button edit" href="#" title="<roundcube:label name='calendar.changepartstat' />"><span class="inner"><roundcube:label name='calendar.changepartstat' /></span></a>
		</span>
	</div>
	<div id="event-calendar" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.calendar" /></label>
		<span class="col-sm-8 form-control-plaintext event-text">Default</span>
	</div>
	<div id="event-category" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.category" /></label>
		<span class="col-sm-8 form-control-plaintext event-text"></span>
	</div>
	<div id="event-status" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.status" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-free-busy" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.freebusy" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-priority" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.priority" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-rsvp-comment" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.rsvpcomment" /></label>
		<span class="event-text col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-links" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.links" /></label>
		<span class="event-text col-sm-8"></span>
	</div>
	<div id="event-attachments" class="form-group row">
		<label class="col-sm-4 col-form-label"><roundcube:label name="attachments" /></label>
		<span class="event-text col-sm-8"></span>
	</div>
	<div id="event-created" class="form-group row faded">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.created" /></label>
		<span class="event-text event-created col-sm-8 form-control-plaintext"></span>
	</div>
	<div id="event-changed" class="form-group row faded">
		<label class="col-sm-4 col-form-label"><roundcube:label name="calendar.changed" /></label>
		<span class="event-text event-changed col-sm-8 form-control-plaintext"></span>
	</div>
	<roundcube:object name="plugin.event_rsvp_buttons" id="event-rsvp" class="calendar-invitebox invitebox boxinformation" style="display:none" />
</div>

<roundcube:include file="/templates/eventedit.html" />

<div id="calendaractions-menu" class="popupmenu">
	<h3 id="aria-label-calendaroptions" class="voice"><roundcube:label name="calendar.calendaractions" /></h3>
	<ul class="menu listing" role="menu" aria-labelledby="aria-label-calendaroptions">
		<roundcube:button type="link-menuitem" command="calendar-create" label="calendar.addcalendar" class="create disabled" classAct="create active" />
		<roundcube:button type="link-menuitem" command="calendar-edit" label="calendar.editcalendar" class="edit disabled" classAct="edit active" />
		<roundcube:button type="link-menuitem" command="calendar-delete" label="calendar.deletecalendar" class="delete disabled" classAct="delete active" />
		<roundcube:if condition="env:calendar_driver == 'kolab'" />
			<roundcube:button type="link-menuitem" command="calendar-remove" label="calendar.removelist" class="remove disabled" classAct="remove active" />
		<roundcube:endif />
		<roundcube:button type="link-menuitem" command="calendar-showurl" label="calendar.showurl" class="showurl disabled" classAct="showurl active" />
		<roundcube:if condition="!empty(env:calendar_settings['freebusy_url'])" />
			<roundcube:button type="link-menuitem" command="calendar-showfburl" label="calendar.showfburl" class="showurl disabled" classAct="showurl active" />
		<roundcube:endif />
		<roundcube:if condition="env:calendar_driver == 'kolab'" />
			<roundcube:button type="link-menuitem" command="folders" task="settings" label="managefolders" class="folders disabled" classAct="folders active" />
		<roundcube:endif />
	</ul>
</div>

<div id="eventoptionsmenu" class="popupmenu">
	<h3 id="aria-label-eventoptions" class="voice"><roundcube:label name="calendar.eventoptions" /></h3>
	<ul class="menu listing" role="menu" aria-labelledby="aria-label-eventoptions">
		<roundcube:button type="link-menuitem" command="event-download" label="download" class="download disabled" classAct="download active" />
		<roundcube:button type="link-menuitem" command="event-sendbymail" label="send" class="send disabled" classAct="send active" />
		<roundcube:button type="link-menuitem" command="event-copy" label="copy" class="copy disabled" classAct="copy active" />
		<roundcube:if condition="env:calendar_driver == 'kolab' && config:kolab_bonnie_api" />
			<roundcube:button type="link-menuitem" command="event-history" label="calendar.eventhistory" class="history disabled" classAct="history active" />
		<roundcube:endif />
	</ul>
</div>

<div id="eventresourcesdialog" class="popupmenu">
	<h3 class="voice" id="aria-label-resourceselection"><roundcube:label name="calendar.arialabelresourceselection" /></h3>
	<div class="resource-selection selection-list" role="navigation" aria-labelledby="aria-label-resourceselection">
		<div class="header">
			<span class="header-title"><roundcube:label name="calendar.tabresources" /></span>
		</div>
		<roundcube:object name="plugin.resources_searchform" id="resourcesearchbox"
			wrapper="searchbar menu" ariatag="h4" buttontitle="calendar.findresources"
			label="resourcesearchform" label-domain="calendar" />
		<div class="scroller">
			<roundcube:object name="plugin.resources_list" id="resources-list" class="listing treelist" />
		</div>
	</div>
	<div class="resource-content selection-content">
		<div class="header" data-hidden="normal,big">
			<a class="button icon back" href="#back" onclick="$('#eventresourcesdialog .resource-content').hide(); $('#eventresourcesdialog .resource-selection').show()">
				<span class="inner"><roundcube:label name="back" /></span>
			</a>
			<span class="header-title"><roundcube:label name="calendar.resourceprops" /></span>
		</div>
		<ul class="nav nav-tabs" role="tablist">
			<li class="nav-item">
				<a class="nav-link active" href="#resource-availability" data-toggle="tab" role="tab">
					<roundcube:label name="calendar.resourceavailability" />
				</a>
			</li>
			<li class="nav-item">
				<a class="nav-link" href="#resource-info" data-toggle="tab" role="tab">
					<roundcube:label name="calendar.resourcedetails" />
				</a>
			</li>
		</ul>
		<div class="tab-content">
			<div id="resource-availability" class="tab-pane active" role="tabpanel" aria-labelledby="aria-label-resourceavailability">
				<h3 class="voice" id="aria-label-resourceavailability"><roundcube:label name="calendar.resourceavailability" /></h3>
				<roundcube:object name="plugin.resource_calendar" id="resource-freebusy-calendar" class="raw-tables" />
				<div class="slot-nav">
					<roundcube:button name="resource-cal-prev" id="resource-calendar-prev" type="link"
						class="icon prevpage" title="calendar.prevslot" label="calendar.prevweek" />
					<roundcube:button name="resource-cal-next" id="resource-calendar-next" type="link"
						class="icon nextpage" title="calendar.nextslot" label="calendar.nextweek" />
				</div>
			</div>
			<div id="resource-info" class="tab-pane" role="tabpanel" aria-labelledby="aria-label-resourcedetails">
				<h3 class="voice" id="aria-label-resourcedetails"><roundcube:label name="calendar.resourcedetails" /></h3>
				<roundcube:object name="plugin.resource_info" id="resource-details" class="propform text-only"
					aria-live="polite" aria-relevant="text" aria-atomic="true" />
			</div>
		</div>
	</div>
</div>

<div id="eventfreebusy" class="popupmenu calendar-scheduler formcontent">
	<roundcube:object name="plugin.attendees_freebusy_table" id="attendees-freebusy-table"
		class="schedule-table" data-h-margin="-1" data-v-margin="1" />
	<div class="nav">
		<div class="schedule-buttons">
			<button type="button" id="schedule-find-prev" class="btn btn-secondary prev-slot"><roundcube:label name="calendar.prevslot" /></button>
			<button type="button" id="schedule-find-next" class="btn btn-secondary next-slot"><roundcube:label name="calendar.nextslot" /></button>
		</div>
		<div class="schedule-options">
			<label><input type="checkbox" id="schedule-freebusy-workinghours" value="1" class="pretty-checkbox" /><roundcube:label name="calendar.onlyworkinghours" /></label>
		</div>
		<div class="schedule-nav">
			<button type="button" id="schedule-freebusy-prev" title="<roundcube:label name='previouspage' />">&#9668;</button>
			<button type="button" id="schedule-freebusy-next" title="<roundcube:label name='nextpage' />">&#9658;</button>
		</div>
	</div>
	<div class="schedule-range">
		<div class="form-group row">
			<label for="schedule-startdate" class="col-form-label col-sm-2"><roundcube:label name="calendar.start" /></label>
			<span class="col-sm-10 datetime">
				<input type="text" name="startdate" size="11" id="schedule-startdate" class="form-control" disabled="true" /> &nbsp;
				<input type="text" name="starttime" size="6" id="schedule-starttime" class="form-control" disabled="true" />
			</span>
		</div>
		<div class="form-group row">
			<label for="schedule-enddate" class="col-form-label col-sm-2"><roundcube:label name="calendar.end" /></label>
			<span class="col-sm-10 datetime">
				<input type="text" name="enddate" size="11" id="schedule-enddate" class="form-control" disabled="true" /> &nbsp;
				<input type="text" name="endtime" size="6" id="schedule-endtime" class="form-control" disabled="true" />
			</span>
		</div>
		<div class="schedule-legend form-group row">
			<label class="col-form-label col-sm-2"><roundcube:label name="calendar.legend" /></label>
			<span class="col-sm-10 form-control-plaintext">
				<roundcube:include file="/templates/freebusylegend.html" />
				<span class="attendee organizer"><roundcube:label name="calendar.roleorganizer" /></span>
				<span class="attendee req-participant"><roundcube:label name="calendar.rolerequired" /></span>
				<span class="attendee opt-participant"><roundcube:label name="calendar.roleoptional" /></span>
				<span class="attendee non-participant"><roundcube:label name="calendar.rolenonparticipant" /></span>
				<span class="attendee chair"><roundcube:label name="calendar.rolechair" /></span>
			</span>
		</div>
	</div>
</div>

<div id="eventsimport" class="popupmenu formcontent">
	<roundcube:object name="plugin.events_import_form" id="events-import-form" />
</div>

<div id="eventsexport" class="popupmenu formcontent">
	<roundcube:object name="plugin.events_export_form" id="events-export-form" />
</div>

<div id="calendarurlbox" class="popupmenu">
	<p><roundcube:label name="calendar.showurldescription" /></p>
	<textarea id="calfeedurl" rows="2" readonly="readonly"></textarea>
	<div id="calendarcaldavurl" style="display:none; margin-top:1rem">
		<p><roundcube:label name="calendar.caldavurldescription" html="yes" /></p>
		<textarea id="caldavurl" rows="2" readonly="readonly"></textarea>
	</div>
</div>

<div id="fburlbox" class="popupmenu">
	<p><roundcube:label name="calendar.fburldescription" /></p>
	<textarea id="fburl" rows="2" readonly="readonly"></textarea>
</div>

<roundcube:if condition="config:kolab_bonnie_api" />

<div id="eventhistory" class="popupmenu" aria-hidden="true">
	<roundcube:object name="plugin.object_changelog_table" id="event-changelog-table" class="changelog-table" />
	<div class="compare-button"><input type="button" class="button" value="<roundcube:label name='libkolab.compare' />" /></div>
</div>

<div id="eventdiff" class="popupmenu formcontent text-only">
	<h1 class="event-title">Event Title</h1>
	<h1 class="event-title-new event-text-new"></h1>
	<div class="form-group row event-date"></div>
	<div class="form-group row event-location">
		<h5 class="label"><roundcube:label name="calendar.location" /></h5>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
	<div class="form-group row event-description">
		<h5 class="label"><roundcube:label name="calendar.description" /></h5>
		<div class="event-text-diff" style="white-space:pre-wrap"></div>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
	<div class="form-group row event-url">
		<h5 class="label"><roundcube:label name="calendar.url" /></h5>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
	<div class="form-group row event-recurrence">
		<h5 class="label"><roundcube:label name="calendar.repeat" /></h5>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
	<div class="form-group row event-alarms">
		<h5 class="label"><roundcube:label name="calendar.alarms" /><span class="index"></span></h5>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
	<div class="event-line event-start">
		<label><roundcube:label name="calendar.start" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-end">
		<label><roundcube:label name="calendar.end" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-attendees">
		<label><roundcube:label name="calendar.tabattendees" /><span class="index"></span></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-calendar">
		<label><roundcube:label name="calendar.calendar" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-categories">
		<label><roundcube:label name="calendar.category" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-status">
		<label><roundcube:label name="calendar.status" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-free_busy">
		<label><roundcube:label name="calendar.freebusy" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-priority">
		<label><roundcube:label name="calendar.priority" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="event-line event-sensitivity">
		<label><roundcube:label name="calendar.sensitivity" /></label>
		<span class="event-text-old"></span> &#8674;
		<span class="event-text-new"></span>
	</div>
	<div class="form-group row event-attachments">
		<label><roundcube:label name="attachments" /><span class="index"></span></label>
		<div class="event-text-old"></div>
		<div class="event-text-new"></div>
	</div>
</div>

<roundcube:endif />

<roundcube:object name="plugin.calendar_css" folder-class="div.$class a.calname:before" folder-fallback-color="#161b1d" />

<roundcube:include file="includes/footer.html" />
