Repository navigation
Expand file tree
/
Copy pathFAQ.html
More file actions
427 lines (392 loc) · 25.6 KB
/
Copy pathFAQ.html
File metadata and controls
427 lines (392 loc) · 25.6 KB
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
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
<html>
<div class="container" role="main">
<h1>myKN FAQ</h1>
<div class="faq">
<input type="search" value="" placeholder="Type some keywords (e.g. communities, profiles, login)">
<ul>
<li id="faq-1">
<h2><a href="#faq-1">Employee cannot login to myKN</a></h2>
<div>
<p></p><p>In case employee cannot log into <strong>myKN</strong>, please check the following: <br><br></p>
<ul dir="ltr">
<li>whether he/she uses correct URL: connections.mykn.community</li>
<li>whether he/she logs in with his/her Windows user name and password (the same as he/she would log in to his/her PC). In most cases the login name is firstname.lastname and the personal password</li>
<li>the user should also be in Kuehne + Nagel corporate network, either <strong>LAN </strong>or <strong>WLAN </strong>or <strong>VPN </strong>(if the user can open <strong>myKN </strong>login page, he/she most likely is in corporate network).</li>
</ul>
<p><br>If your question was not answered after reviewing materials in this section, please submit a ticket <a href="http://tcf.int.kn/en/link/GlobalServiceDesk/myKN/User/Change%20Personal%20Info">here</a>, and we will investigate the matter further. </p><p></p>
</div>
</li>
<li id="faq-2">
<h2><a href="#faq-2">User’s personal profile data is missing or wrong
</a></h2>
<div>
<p></p><p dir="ltr">User data is added into <strong>myKN </strong>from the <strong>Active directory</strong>, and our peoples database <strong>PDM</strong>. User data originates from <strong>PDM</strong>, but is always filtered through the <strong>Active Directory</strong>, before it goes to myKN. </p>
<p dir="ltr">The following data comes to your myKN profile only from local <strong>Active Directory</strong>:</p>
<p dir="ltr"> </p>
<table dir="ltr" border="1">
<tbody>
<tr>
<td>
<p>First Name</p>
<p>Last Name </p>
</td>
<td>In case this data is displayed incorrectly in your myKN user profile, please contact your local <strong>LAN </strong>Support and request this to be checked / corrected in the <strong>Active Directory.</strong> <br><br></td>
<td>If the previous step did not resolve the issue after <strong>AD </strong>information was updated, then it is necessary to request this to be checked / corrected by your local <strong>HR </strong>to check if the data is correct in <strong>PDM</strong>.</td>
</tr>
</tbody>
</table>
<p dir="ltr"><br>The following profile data comes automatically to <strong>myKN </strong>from our people’s database <strong>PDM</strong> and through the local <strong>Active Directories</strong>: </p>
<p> </p>
<table dir="ltr" border="1">
<tbody>
<tr>
<td>KN Code <br>Street <br>City <br>Country name <br>E-Mail address <br>Phone <br>Mobile <br>Fax <br>Job title <br>Solid line manager </td>
<td>In case this data is displayed incorrectly in your myKN user profile, please contact your local HR and request this to be checked / corrected in the PDM. </td>
<td>If the previous step did not resolve the issue after <strong>PDM</strong> information was updated, then it is necessary to request this to be checked / corrected by the local <strong>LAN</strong> <strong>Support</strong> in the <strong>Active Directory</strong> (the above mentioned data originates from <strong>PDM</strong>, but is always filtered through the <strong>Active Directory</strong>, before it goes to myKN). </td>
</tr>
</tbody>
</table>
<p dir="ltr"> </p>
<p dir="ltr"> </p>
<div id="wikiContentDiv" class="qkrWikiPreview bidiAware" dir="ltr">
<div>If your question was not answered after reviewing materials in this section, please submit a ticket <a href="http://tcf.int.kn/en/link/GlobalServiceDesk/myKN/User/Change%20Personal%20Info">here</a>, and we will investigate the matter further. </div>
</div>
</div>
</li>
<li id="faq-3">
<h2><a href="#faq-3">Employees left KN but are shown as active users
</a></h2>
<div>
<p></p><p dir="ltr">In some cases employees that left KN might still be shown as active users in <strong>myKN </strong>/ <strong>IBM Sametime</strong>. If that is the case, then please verify that local HR updated users <strong>PDM </strong>profile, and notified local LAN support about the fact that employee left KN. Once local LAN support receives a notification (from HR) that user left KN, his/her <strong>Active Directory</strong> profile will be "deactivated" (timeframes vary by region). and users profile will no longer be shown as active in myKN.</p>
<p dir="ltr"> </p>
<div id="wikiContentDiv" class="qkrWikiPreview bidiAware" dir="ltr">
<div>
<p>If your question was not answered after reviewing materials in this section, please submit a ticket <a href="http://tcf.int.kn/en/link/GlobalServiceDesk/myKN/User/Change%20Personal%20Info">here</a>, and we will investigate the matter further. </p>
</div>
</div><p></p>
</div>
</li>
<li id="faq-4">
<h2><a href="#faq-4">How to create a myKN community
</a></h2>
<div>
<p></p><h2 dir="ltr">Intro</h2>
<p dir="ltr"> </p>
<p dir="ltr">Community creation process is easy and quick, below are two steps that you need to take in order to set it up:</p>
<p dir="ltr"> </p>
<h2 dir="ltr">Pick the community name</h2>
<p dir="ltr"> </p>
<p dir="ltr">We would like to clarify the reasoning behind the community name requirements. We would like all the communities to share a similar name structure. This will be beneficial for users, and community owners, as it will simplify the community search process. It makes it easier for the employees to navigate between communities, understand what different communities we have across the organization, and ultimately, foster cooperation between different teams and units. <br><br><em>Please note: community name should be in English, and abbreviations are not allowed. <br><br></em>Here is the community name structure that we are looking for: <br><br>1.Business unit name (without abbreviations, in English) <br>2.The purpose of the community (optional)<br>3.Geographical reach of the community <br><br>Example: <br><br><strong>Airfreight </strong>(<em>< - Business Unit name</em>) <strong>Systems </strong>- <strong>Business Process Automation </strong>(<em>< - The purpose of the community</em>) <strong>Global </strong>(<em>< - Geographical reach of the community</em>). <br><br>Result: Airfreight Systems - Business Process Automation Global</p>
<p dir="ltr"><br>You can check the Community Naming Convention here: <br><br><a href="https://wiki.int.kn/display/MYKN/myKN+-+Community+Owners#myKN-CommunityOwners-NamingConventionforCommunities">https://wiki.int.kn/display/MYKN/myKN+-+Community+Owners#myKN-CommunityOwners-NamingConventionforCommunities</a> </p>
<p dir="ltr">Once you have composed the community name, it's time to get to the next step:</p>
<p dir="ltr"> </p>
<h2 dir="ltr">Request the community to be setup</h2>
<p dir="ltr"> </p>
<p dir="ltr">You can request the community to be set up for you using the following <a href="http://tcf.int.kn/en/link/GlobalServiceDesk/myKN/Request/Community/Create">TCF </a>form. </p><p></p>
</div>
</li>
<li id="faq-5">
<h2><a href="#faq-5">Adding a video to your post
</a></h2>
<div>
<p></p><p dir="ltr">In order to add a video to a page / app please take the following steps: </p>
<ul dir="ltr">
<li>Upload a video into your personal / community files folder. </li>
<li>Choose the page / app where you wish to add a video. It can be added in any app that is using the Rich Content editor (with enabled HTML Source view).</li>
<li>Add the following code into the <strong>HTML Source </strong>of the Rich Content editor: <video width="320" height="240" controls="" dir="ltr"> <br><source src="<strong>Link To Your Video</strong>" type="video/mp4"> <br></video> </li>
</ul>
<ul dir="ltr">
<li>Within the code that you added in <strong>the third step</strong> replace the text in bold with the link that you copied from the video frame. </li>
<li>Save the changes.</li>
</ul>
<p dir="ltr"> </p>
<p dir="ltr"><strong>Note</strong>: please use videos in .<strong>mov</strong> format, other formats might fail to play the video for users that use certain browsers. </p>
<p dir="ltr">if you are adding a video from your personal files into a community, then make sure that during the video file upload you have chosen to <strong>Share with everyone in my organization</strong>, otherwise users wont be able to play the video.</p><p></p>
</div>
</li>
<li id="faq-6">
<h2><a href="#faq-6">How to Clear your Web-Browsers cache
</a></h2>
<div>
<p></p><p dir="ltr">Clearing the browsers cache can solve a variety of issues such as performance, functionality of web pages and even login issues.<br><br>Please keep in mind that the supported browsers for the <strong>myKN</strong> platform are <em><strong>Internet Explorer</strong></em> and <em><strong>Mozilla Firefox</strong></em>, as such we would recommend using one of them to achieve optimal performance and functionality of the platform.<br><br>How to clear the cache for<strong> <em>Internet Explorer</em></strong> :<br><br><strong>Step 1</strong><br>Navigate to the top right section of the browsers where you will see a "<strong>Gear</strong>" icon and select "<strong>Internet Options</strong>" from there.</p>
<p dir="ltr"><br><img src="https://image.ibb.co/huhR8J/IE_Clear_Cache_Step1.png" alt="" width="271" height="350"><br><br><br><strong>Step 2</strong><br>This will open up the General tab by default, from there click on "<strong>Delete...</strong>" which is located in the "<strong>Browsing History</strong>" section.</p>
<p dir="ltr"><br><img src="https://image.ibb.co/g7Bm8J/IE_Clear_Cache_Step2.png" alt="" width="417" height="540"><br><br><br><strong>Step 3</strong><br>A pop-up will appear with additional options, make sure that the following boxes are ticked: <strong>Preserve Favorites website data</strong>, <strong>Temporary Internet files and website files</strong>, <strong>Cookies and website data</strong>, <strong>Form Data</strong>, <strong>Passwords</strong>.<br>Once the boxes are accordingly ticked simply click on "<strong>Delete</strong>" and your <strong><em>Internet Explorer's</em></strong> cache is cleared.</p>
<p dir="ltr"><br><img src="https://image.ibb.co/gy5w8J/IE_Clear_Cache_Step3.png" alt="" width="400" height="546"><br><br><br>How to clear the cache for <strong><em>Mozilla Firefox</em></strong> :<br><br><strong>Step 1<br></strong>In the top right section of the browser there is a "<strong>Burger</strong>" icon, from there select "<strong>Options</strong>".</p>
<p dir="ltr"><br><img src="https://image.ibb.co/nKSFJJ/Firefox_Clear_Cache_Step1.png" alt="" width="273" height="619"><br><strong><br><br>Step 2<br></strong>From the browser settings screen navigate to "<strong>Privacy & Security</strong>", locate the "<strong>Cookies and Site Data</strong>" section and press "<strong>Clear Data...</strong>". Now your <strong><em>Mozilla Firefox </em></strong>cache is cleared.</p>
<p dir="ltr"><br><img src="https://image.ibb.co/bCKUdJ/Firefox_Clear_Cache_Step2.png" alt="" width="933" height="542"></p><p></p>
</div>
</li>
<li id="faq-7">
<h2><a href="#faq-7">How To Create an RSS Feed for Outlook
</a></h2>
<div>
<p></p><p dir="ltr">Creating an <strong>RSS Feed for Outlook</strong> would be particularly useful if you want to receive updates to your <strong>Outlook </strong>about notifications for a specific app or a communities updates. Naturally the same can be done for a news article on the web, but let's focus on why it is good to have an <strong>RSS Feed</strong> for apps in myKN and why would you want to do that.</p>
<p dir="ltr">The notification settings which you can adjust from your personal profile are <strong>Global </strong>settings, what that means is if you would choose to get emails about updates then you would automatically get a notification e-mail into your inbox about every update for every community that you are following. If you are a part of multiple communities this can cause a lot of clutter and traffic for your inbox and would make it a fair deal harder to navigate it. By creating an <strong>RSS Feed</strong> you have the possibility to choose what kind of notifications and from where you receive them. </p>
<p dir="ltr">The receive all of the updates from a community we would recommend creating a feed for the "<strong>Recent Updates</strong>" and "<strong>Status Updates</strong>" apps of the desired community. If you would like to receive updates only for a specific forum which you found to be of interest, use or importance, you can do so and at the same time not receive notification emails about what else goes on in the community in general.</p>
<p dir="ltr">An example then, let's say that community "X" in general does not have much value for me individually in my day to day work, but I found some forum posts/blog posts that are directly related to my daily work and they also post various announcements which are of great use to me. Then I would create an <strong>RSS Feed</strong> for that forum/blog and receive notifications to a standalone <strong>RSS Feed</strong> folder, allowing me to optimize the relevance of notifications that I receive as well as organizing it. Instead of getting an e-mail for every community that has an update and I am following.</p>
<p dir="ltr">The process of creating an <strong>RSS Feed for Outlook</strong> is fairly short. There are two ways to create an RSS Feed for Outlook:</p>
<p dir="ltr"> </p>
<p dir="ltr"><strong>1. Option:</strong></p>
<p dir="ltr">First open up the app that you would like to create an <strong>RSS Feed</strong> for and scroll to the bottom of it, once there you will see the <strong>RSS Feed</strong> icon with the available options, for some apps you can just create a feed for comments or all entries, for some you can just create a feed for entries.</p>
<p dir="ltr"> </p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/f0dfd7c3-8e4b-4d47-bad1-b634928abf94/media/RSS%20Feed%20for%20Outlook3.png?preventCache=1553849827113" alt=""></p>
<p dir="ltr"> </p>
<p dir="ltr">Once you click on it, it will open up a new page with the feed itself, now you would need to copy the entire <strong>URL</strong> of the page that opened, this is located at the top section of the web-browser.</p>
<p dir="ltr"> </p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/0142c858-59ff-4771-8333-74b2fd8dd13e/media/RSS%20Feed%20for%20Outlook4.png?preventCache=1553849827113" alt=""></p>
<p dir="ltr"> </p>
<p dir="ltr">Once the entire <strong>URL</strong> is copied, open up your <strong>Outlook</strong>, right click on "<strong>RSS Feeds</strong>" folder located on the left side, from the available options select "<strong>Add a New RSS Feed...</strong>".</p>
<p dir="ltr">If this is your first time creating an <strong>RSS Feed for Outlook</strong> you would need to navigate to the "<strong>File</strong>" tab which is located in the top left, click on "<strong>Account Settings</strong>", this will open up a menu, from there click on "<strong>Account Settings...</strong>". Once the account settings window pops-up navigate to the "<strong>RSS Feeds</strong>" tab and click on "<strong>New...</strong>". Now you would have to paste the copied<strong> URL</strong> into the box and click "<strong>Add</strong>" and "<strong>OK</strong>" afterwards. This process will come up with a prompt requesting your windows credentials, type them in and make sure to have outlook save your credentials so that you could use the shorter and easier way of creating an <strong>RSS Feed</strong> in the future.</p>
<p dir="ltr"> </p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/2b1dcbc2-8cc0-46e8-8a8b-3ee157323a88/media/RSS%20Feed%20for%20Outlook1.png?preventCache=1553849827113" alt=""></p>
<p dir="ltr"> </p>
<p dir="ltr">This will give you a pop-up where you would need to paste the <strong>URL</strong> we copied earlier and then click "<strong>Add</strong>" once done. A new pop-up will appear asking for confirmation if you want to add this feed to <strong>Outlook</strong>, click "<strong>Yes</strong>" and you have successfully created an <strong>RSS Feed for Outlook</strong>.</p>
<p dir="ltr"> </p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/31eb2cf7-8c5e-48b3-a681-722ed802cb61/media/RSS%20Feed%20for%20Outlook2.png?preventCache=1553849827113" alt=""></p>
<p dir="ltr"> </p>
<p dir="ltr"><strong>2. Option:</strong></p>
<p dir="ltr">1. Open up the files app and click on "Feed for this Folder"</p>
<p dir="ltr"> </p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/660be1da-d625-433a-92f7-fa89fad59b01/media/w1.png?preventCache=1553849827113"></p>
<p dir="ltr"> </p>
<p dir="ltr">2. Copy the link</p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/0908250b-1716-4c55-95a6-9b62c1b35d07/media/w2.png?preventCache=1553849827113"></p>
<p dir="ltr"> </p>
<p dir="ltr">3. Go to Outlook and click on File -> Info -> Account Settings</p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/b36fa209-21d0-4475-a890-95ca48a8ff53/media/w3.png?preventCache=1553849827113"></p>
<p dir="ltr"> </p>
<p dir="ltr">4. Click in the tab "RSS Feeds" on "New" and add the link</p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/f781687a-2108-417f-b635-b7a1b4e9e3d7/media/w4.png?preventCache=1553849827113"></p>
<p dir="ltr"> </p>
<p dir="ltr">5. A second window appears. Confirm with "ok".</p>
<p dir="ltr"><img src="https://connections.mykn.community/wikis/form/api/wiki/8859230b-37eb-47bb-a79f-f841e6aafc7f/page/6dca04a3-c3d1-406f-927a-54790970201e/attachment/55b80371-5776-4f02-bbee-ff39267ef1c6/media/w5.png?preventCache=1553849827113"></p><p></p>
</div>
</li>
</ul>
<div class="faq__notfound"><p>No matches were found… Try “giza”.</p></div>
</div>
</div>
</html>
<style>
body
{
font-family: Roboto, sans-serif;
color: #34434b;
background-color: #f4fbfc;
padding: 5rem 1.25rem; /* 80 20 */
}
.container
{
width: 100%;
max-width: 640px; /* 960 */
margin: 0 auto;
}
.container h1
{
font-size: 42px;
font-weight: 300;
color: #5594b3;
margin-bottom: 40px;
}
.container h1 a:hover,
.container h1 a:focus
{
color: #a664b7;
}
.container p
{
line-height: 1.6;
}
.faq
{
}
.faq input
{
width: 100%;
height: 60px;
font-size: 20px;
background-color: #fff;
box-shadow: 0px 2px 4px rgba( 52, 67, 75, .2 );
display: block;
padding: 0 20px;
margin-bottom: 40px;
-webkit-transition: box-shadow .1s linear;
transition: box-shadow .1s linear;
}
.faq input::-webkit-input-placeholder { color: #a1bdcb !important; }
.faq input::-moz-placeholder { color: #a1bdcb !important; }
.faq input:-ms-input-placeholder { color: #a1bdcb !important; }
.faq input:focus
{
box-shadow: 0px 4px 8px rgba( 52, 67, 75, .4 );
}
.faq .highlight
{
background-color: #fffd77;
}
.faq > ul
{
}
.faq > ul > li
{
}
.faq > ul > li:not( :first-child )
{
border-top: 1px solid #dcebed;
margin-top: 20px;
padding-top: 20px;
}
.faq > ul > li.is-hidden
{
display: none;
}
.faq > ul > li h2
{
font-size: 24px;
font-weight: 700;
}
.faq > ul > li h2:hover,
.faq > ul > li h2:focus,
.faq > ul > li.is-active h2,
.faq > ul > li:target h2
{
color: #a664b7;
}
.faq > ul > li > div
{
display: none;
}
.faq > ul > li.is-active > div,
.faq > ul > li:target > div
{
display: block;
margin-top: 10px;
}
.faq__notfound
{
font-size: 20px;
font-style: italic;
display: none;
}
.faq__notfound.is-visible
{
display: block;
}
.container footer
{
color: #a1bdcb;
margin-top: 40px;
}
.container footer a:hover,
.container footer a:focus
{
color: #5594b3;
}
</style>
<script>
'use strict';
;( function ( document, window, index )
{
var hasElementClass = function( element, className ){ return element.classList ? element.classList.contains( className ) : new RegExp( '(^| )' + className + '( |$)', 'gi' ).test( element.className ); },
addElementClass = function( element, className ){ element.classList ? element.classList.add( className ) : element.className += ' ' + className; },
removeElementClass = function( element, className ){ element.classList ? element.classList.remove( className ) : element.className = element.className.replace( new RegExp( '(^|\\b)' + className.split( ' ' ).join( '|' ) + '(\\b|$)', 'gi' ), ' ' ); };
// search & highlight
;( function ( document, window, index )
{
var container = document.querySelector( '.faq' );
if( !container ) return true;
var input = container.querySelector( 'input' ),
notfound = container.querySelector( '.faq__notfound' ),
items = document.querySelectorAll( '.faq > ul > li' ),
item = {},
itemsIndexed = [];
[].forEach.call( items, function( entry )
{
itemsIndexed.push( entry.textContent.replace( /\s{2,}/g, ' ' ).toLowerCase() );
});
input.addEventListener( 'keyup', function( e )
{
if( e.keyCode == 13 ) // enter
{
input.blur();
return true;
}
[].forEach.call( items, function( entry )
{
entry.innerHTML = entry.innerHTML.replace( /<span class="highlight">([^<]+)<\/span>/gi, '$1' );
});
var searchVal = input.value.trim().toLowerCase();
if( searchVal.length )
{
itemsIndexed.forEach( function( entry, i )
{
if( itemsIndexed[ i ].indexOf( searchVal ) != -1 )
{
removeElementClass( items[ i ], 'is-hidden' );
items[ i ].innerHTML = items[ i ].innerHTML.replace( new RegExp( searchVal+'(?!([^<]+)?>)', 'gi' ), '<span class="highlight">$&</span>' );
}
else
addElementClass( items[ i ], 'is-hidden' );
});
}
else [].forEach.call( items, function( entry ){ removeElementClass( entry, 'is-hidden' ); });
if( items.length == [].filter.call( items, function( entry ){ return hasElementClass( entry, 'is-hidden' ) } ).length )
addElementClass( notfound, 'is-visible' );
else
removeElementClass( notfound, 'is-visible' );
});
}( document, window, 0 ));
// toggling items on title press
;( function ( document, window, index )
{
[].forEach.call( document.querySelectorAll( '.faq h2 a' ), function( entry )
{
addElementClass( entry, 'js--is-toggleable-item' );
});
document.addEventListener( 'click', function( e )
{
if( hasElementClass( e.target, 'js--is-toggleable-item' ) )
{
e.preventDefault();
var current = e.target;
while( current.parentNode )
{
current = current.parentNode;
if( current.tagName.toLowerCase() == 'li' )
{
hasElementClass( current, 'is-active' ) ? removeElementClass( current, 'is-active' ) : addElementClass( current, 'is-active' );
break;
}
}
}
});
}( document, window, 0 ));
// auto-show item content when show results reduces to single
;( function ( document, window, index )
{
var container = document.querySelector( '.faq' );
if( !container ) return true;
var input = container.querySelector( 'input' ),
items = document.querySelectorAll( '.faq > ul > li' ),
item = {};
input.addEventListener( 'keyup', function( e )
{
item = [].filter.call( items, function( entry ){ return !hasElementClass( entry, 'is-hidden' ); } )
if( item.length == 1 )
{
addElementClass( item[ 0 ], 'js--autoshown' );
addElementClass( item[ 0 ], 'is-active' );
}
else
[].forEach.call( items, function( entry )
{
if( hasElementClass( entry, 'js--autoshown' ) )
{
removeElementClass( entry, 'js--autoshown' );
removeElementClass( entry, 'is-active' );
}
});
});
}( document, window, 0 ));
}( document, window, 0 ));
</script>