forked from mitsuhiko/timesched
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtimesched.html
275 lines (264 loc) · 13.1 KB
/
timesched.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
<!doctype html>
<html ng-app="timesched">
<title>Time Scheduler</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="lib/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="static/main.css">
<link rel="stylesheet" href="static/theme.css">
<div class="container" ng-controller="TimezoneCtrl">
<div class="header">
<h1 class="text-muted">Time Scheduler</h1>
<div class="share" hidden>
<span>Like it?</span>
<a href="https://twitter.com/share?url=http://timesched.pocoo.org/&text=Schedule+meetings+with+timesched&related=mitsuhiko" class="twitter-share-button" data-lang="en">Tweet</a>
</div>
</div>
<div class="contentwrapper" hidden>
<div class="navbar navbar-default navbar-actions" role="navigation">
<div class="navbar-collapse collapse">
<form class="navbar-form navbar-left navbar-timezone-form"
name="zoneform" ng-submit="addInputZone()">
<div class="form-group">
<input type="text" class="form-control timezone-input"
placeholder="Type to add city or timezone"
ng-model="currentZone" timezone>
</div>
<button type="submit" class="btn btn-default"
ng-disabled="false" style="display: none">Add</button>
</form>
<form class="navbar-form navbar-left navbar-date-form">
<div class="form-group">
<input type="text" class="form-control"
datepicker-popup="yyyy-MM-dd" ng-model="day" readonly ng-required="true">
</div>
</form>
<p class="navbar-text navbar-warning-text" ng-show="!isToday">
<strong>Reminder:</strong>
you're not scheduling for today.
<a href="#" ng-click="goToTodayInteractive()">Go to today</a>.
<ul class="nav navbar-nav navbar-right">
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Actions <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a ng-click="sortByOffset()">Sort by offset</a></li>
<li><a ng-click="sortByName()">Sort by name</a></li>
<li><a ng-click="reverse()">Reverse list</a></li>
<li><a ng-click="clearList()">Clear list</a></li>
<li class="divider">
<li><a ng-click="goToToday()">Go to today</a>
<li class="divider">
<li><a ng-click="toggleMarkWeekends()">{{ markWeekends && 'Hide weekends' || 'Show weekends' }}</a>
<li><a ng-click="toggleClocks()" ng-show="isToday">{{ showClocks && 'Hide clocks' || 'Show clocks' }}</a>
<li><a ng-click="toggleRestoreTimezones()">{{ restoreTimezones && 'Don\'t restore timezones' || 'Restore timezones' }}</a>
<li class="divider">
<li><a ng-click="getShortURL()">Get short link</a>
<li><a ng-click="showHelp()">Get help</a>
</ul>
</li>
</ul>
</div>
</div>
<div class="time-list">
<ul ui-sortable="{axis: 'y', handle: 'div.handle', cursor: 'row-resize'}" ng-model="zones">
<li ng-repeat="zone in zones" ng-class="{home: zone.isHome}">
<div class="handle"></div>
<div class="location-info">
<h3>{{ zone.homeOffset }} <em
tooltip-placement="right"
tooltip="{{ zone.timezoneOffsetInfo }}, {{ zone.timezoneName }}">{{ zone.timezoneAbbr }}</em></h3>
<div class="dropdown">
<a href="#" data-toggle="dropdown">{{ zone.timezoneShortName }}</a>
<ul class="dropdown-menu" role="menu">
<li><a ng-click="setAsHome(zone)" ng-hide="zone.isHome">Set as home</a>
<li><a ng-click="removeZone(zone)">Remove</a>
</ul>
</div>
</div>
<div class="clock">
<div class="clockwrapper" ng-show="isToday && showClocks">
<span class="hour">{{ zone.clockHour }}</span><!--
--><span class="sep">:</span><!--
--><span class="minute">{{ zone.clockMinute }}</span>
<span class="day">{{ zone.clockDay }}</span>
</div>
</div>
<div class="time-cells">
<table>
<tr>
<td ng-repeat="cell in zone.timeCells">
<span class="cell-wrapper" ng-class="{
daystart: cell.hour == 0,
night: cell.hour >= 22 || cell.hour < 6,
morning: cell.hour >= 6 && cell.hour < 8,
day: cell.hour >= 8 && cell.hour < 18,
evening: cell.hour >= 18 && cell.hour < 22,
weekend: cell.isWeekend && markWeekends,
even: cell.minute == 0
}" tooltip-placement="bottom" tooltip="{{ cell.tooltip }}">
<span class="hour">{{ cell.hourFormat }}</span><span class="sep"
>:</span><span class="minute">{{ cell.minuteFormat }}</span>
<span class="dayinfo" ng-if="cell.hour == 0">
<span class="weekday">{{ cell.weekDayFormat }}</span>
<span class="day">{{ cell.dayFormat }}</span>
<span class="month">{{ cell.monthFormat }}</span>
</span>
</span>
</table>
</div>
</li>
</ul>
<div class="clock-pointer"><div class="actual-pointer"></div></div>
<div class="range-selection" ng-show="zones.length > 0">
<div class="action"><input type="checkbox" id="meeting" ng-model="scheduleMeeting">
<label for="meeting">Schedule a meeting</label></div>
<div ui-slider ng-model="timeRange" ng-show="scheduleMeeting"></div>
<pre class="meeting-info" ng-show="scheduleMeeting">{{ meetingSummary }}</pre>
<p class="share-links" ng-show="scheduleMeeting">
Share this meeting:
<a href="#" ng-click="sendMeetingMail()">via e-mail</a>,
<a href="#" ng-click="sendMeetingMailViaGMail()">send via gmail</a>,
<a href="#" ng-click="addToGoogleCalendar()">add to google calendar</a>,
<a href="#" ng-click="getICalFile()">add to desktop calendar</a>,
<a href="#" ng-click="tweet()">tweet it</a>,
<a href="#" ng-click="getShortURL()">get short link</a>
</div>
</div>
</div>
<div class="loading">
<p>Loading timezones …
</div>
<div class="footer">
<p>
© Copyright 2013 by <a href="http://lucumr.pocoo.org/">Armin Ronacher</a>.
Proudly BSD licensed.
<a href="https://github.com/mitsuhiko/timesched">Fork me on github</a>.
</div>
</div>
<div class="modal fade" id="short-url-modal" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h4 class="modal-title" id="myModalLabel">Short URL Generated</h4>
</div>
<div class="modal-body">
<p>A short URL for this page was generated:
<p class="short-url"><input onclick="this.select()" type="text" class="form-control" readonly>
<p>
You can share this URL with other people and they will see the same
page as you.
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
</div>
</div>
</div>
</div>
<div class="modal fade" id="help-modal" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h4 class="modal-title" id="myModalLabel">Time Scheduler Help</h4>
</div>
<div class="modal-body">
<p>
This application allows you to schedule meetings in different timezones around
the world. It knows about most large cities and timezones in the world.
<h3>How to Add Timezones</h3>
<p>
Enter the name of the city you want to add to the top left input box and an
auto complete should appear to help you add it. Note that some cities might
have slightly different names to what you expect as all cities have latin
transcribed names here for ease of input. For instance it's “Nuernberg” instead
of “Nürnberg”.
<h3>Why Cities and not Timezones?</h3>
<p>
The application supports most timezones in the world but it's recommended to use
cities instead because that will give you more accurate information. For
instance if you pick arabic cities the weekends will be adjusted accordingly
based on local rules.
<h3>What are the Colors?</h3>
<p>
The darker the colors the more into the night it goes. Red means weekends. Note
that weekends are country specific. If you just select a timezone but not a
city the weekends will be generic (Saturday and Sunday).
<h3>Can I schedule less than 15 Minute Intervals?</h3>
<p>
Yes you can, if you hold cmd (on mac) or alt (on windows) down and it lets you
select in 5 minute intervals.
<h3>How do I remove a timezone?</h3>
<p>
To remove a timezone (or to set it as home timezone) you can use click on the
name of the timezone which will open a drop-down menu. It contains a link to
remove the timezone as well as to make it the home timezone.
<h3>A Timzone is Wrong</h3>
<p>
The timezones are not defined by this application but pulled from official sources.
It can however happen that the version here lags behind.
<a href="mailto:[email protected]">Contact the
developer</a> if something is wrong.
<h3>Who Made This?</h3>
<p>
This application was written by Armin Ronacher for a person very dear to his
heart after a similar service started charging for this functionality.
<a href="mailto:[email protected]">Contact him</a> for feedback.
<h3>Can I Get the Sourcecode?</h3>
<p>
Yes, the sourcecode is available on github:
<a href="https://github.com/mitsuhiko/timesched">mitsuhiko/timesched</a>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Got it</button>
</div>
</div>
</div>
</div>
<script id="template/datepicker/datepicker.html" type="text/ng-template">
<table>
<thead>
<tr class="text-center">
<th><button type="button" class="btn pull-left"
ng-click="move(-1)"><i class="glyphicon glyphicon-chevron-left"></i></button></th>
<th colspan="{{ rows[0].length - 2 + showWeekNumbers }}"><button type="button" class="btn btn-block" ng-click="toggleMode()"><strong>{{ title }}</strong></button></th>
<th><button type="button" class="btn pull-right" ng-click="move(1)"><i class="glyphicon glyphicon-chevron-right"></i></button></th>
</tr>
<tr class="text-center" ng-show="labels.length > 0">
<th ng-show="showWeekNumbers">#</th>
<th ng-repeat="label in labels">{{ label }}</th>
</tr>
</thead>
<tbody>
<tr ng-repeat="row in rows">
<td ng-show="showWeekNumbers" class="text-center"><em>{{ getWeekNumber(row) }}</em></td>
<td ng-repeat="dt in row" class="text-center">
<button type="button" style="width:100%;" class="btn" ng-class="{'btn-info': dt.selected}" ng-click="select(dt.date)" ng-disabled="dt.disabled"><span ng-class="{muted: dt.secondary}">{{ dt.label }}</span></button>
</td>
</tr>
</tbody>
</table>
</script>
<script id="template/datepicker/popup.html" type="text/ng-template">
<ul class="dropdown-menu datepicker-dialog" ng-style="{display: (isOpen && 'block') || 'none', top: position.top+'px', left: position.left+'px'}">
<li ng-transclude></li>
<li ng-show="true" style="padding:10px 9px 2px">
<span class="btn-group">
<button type="button" class="btn btn-small btn-inverse" ng-click="$parent.goToTodayInteractive()">{{ currentText }}</button>
</span>
</li>
</ul>
</script>
<script src="lib/generated/compressed.js"></script>
<script src="static/app.js"></script>
<script src="lib/generated/data-compressed.js"></script>
<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-46285110-1', 'pocoo.org');
ga('send', 'pageview');
</script>
</html>