|
@@ -0,0 +1,48 @@
|
|
1
|
+/* global interfaceConfig */
|
|
2
|
+//list of tips
|
|
3
|
+var hints = [
|
|
4
|
+ "You can pin participants by clicking on their thumbnails.",// jshint ignore:line
|
|
5
|
+ "You can tell others you have something to say by using the \"Raise Hand\" feature",// jshint ignore:line
|
|
6
|
+ "You can learn about key shortcuts by pressing Shift+?",// jshint ignore:line
|
|
7
|
+ "You can learn more about the state of everyone's connection by hovering on the bars in their thumbnail",// jshint ignore:line
|
|
8
|
+ "You can hide all thumbnails by using the button in the bottom right corner"// jshint ignore:line
|
|
9
|
+];
|
|
10
|
+
|
|
11
|
+/**
|
|
12
|
+ * Get a random hint meessage from hint array.
|
|
13
|
+ *
|
|
14
|
+ * @return {string} the hint message.
|
|
15
|
+ */
|
|
16
|
+function getHint(){
|
|
17
|
+ var l = hints.length - 1;
|
|
18
|
+ var n = Math.round(Math.random() * l);
|
|
19
|
+
|
|
20
|
+ return hints[n];
|
|
21
|
+}
|
|
22
|
+
|
|
23
|
+/**
|
|
24
|
+ * Inserts text message
|
|
25
|
+ * into DOM element
|
|
26
|
+ *
|
|
27
|
+ * @param id {string} element identificator
|
|
28
|
+ * @param msg {string} text message
|
|
29
|
+ */
|
|
30
|
+// eslint-disable-next-line no-unused-vars
|
|
31
|
+function insertTextMsg(id, msg){
|
|
32
|
+ var el = document.getElementById(id);
|
|
33
|
+
|
|
34
|
+ if (el)
|
|
35
|
+ el.innerText = msg;
|
|
36
|
+}
|
|
37
|
+
|
|
38
|
+/**
|
|
39
|
+ * Sets the hint and thanks messages. Will be executed on load event.
|
|
40
|
+ */
|
|
41
|
+function onLoad() {
|
|
42
|
+ //Works only for close2.html because close.html doesn't have this element.
|
|
43
|
+ insertTextMsg('thanksMessage',
|
|
44
|
+ 'Thank you for using ' + interfaceConfig.APP_NAME);
|
|
45
|
+ insertTextMsg('hintMessage', getHint());
|
|
46
|
+}
|
|
47
|
+
|
|
48
|
+window.onload = onLoad;
|