forked from 2factorauth/twofactorauth
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
56 lines (46 loc) · 1.96 KB
/
index.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
---
layout: default
---
<div id="main">
<img alt="" loading="lazy" id="logo" src="/img/icons/icon.svg">
<h2>2FA Directory</h2>
<div class="sub header">List of websites and whether or not they support
<a href="https://en.wikipedia.org/wiki/Two-factor_authentication">2FA</a>.
</div>
</div>
<div class="col-11 col-md-8 col-lg-6" id="outerSearchBox">
<i class="fas fa-search fa-2x" id="searchIcon"></i>
<input aria-label="search" id="innerSearchBox" type="search">
</div>
<!-- Categories list -->
<div class="row justify-content-start category-row row-cols-1 row-cols-lg-5">
{% assign keywordsMain = site.data.categories | sort: "title" | where_exp: "item", "item.name != 'other'" %}
{% assign keywordsOther = site.data.categories | where_exp: "item", "item.name == 'other'" %}
{% assign keywords = keywordsMain | concat: keywordsOther %}
{% assign all_entries = site.data.all %}
{% assign keywords_length = keywords | size %}
<!-- Category loop -->
{% for keyword in keywords %}
{% assign entries = "" | split: ',' %}
{% for entry in all_entries %}
{% if entry[1].keywords contains keyword.name %}
{% assign entries = entries | push: entry %}
{% endif %}
{% endfor %}
{% assign _offset = forloop.index | minus: 1 %}
{% assign md = _offset | modulo: 5 %}
<!-- List previous 5 categories (desktop button) -->
{% if md == 0 %}
{% for _keyword in keywords limit: 5 offset: _offset %}
{% include html/category-button.html category-param=_keyword viewport="desktop" %}
{% endfor %}
{% endif %}
<!-- Display mobile category button -->
{% include html/category-button.html category-param=keyword viewport="mobile" %}
<!-- Display desktop table -->
{% include html/desktop-table.html category=keyword entries=entries %}
<!-- Display mobile table -->
{% include html/mobile-table.html category=keyword entries=entries %}
{% endfor %}
</div>
<h2 id="no-results">No results found.</h2>