-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathwords.html
205 lines (159 loc) · 5.88 KB
/
words.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
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="icon" href="12.png" type="image/icon type">
<style>
button {
top : 0px;
position: fixed;
display: flex;
justify-content: center;
align-items: center;
padding: 20px 25px 20px 22px;
box-shadow: rgba(10, 37, 64, 0.35) 0px -2px 6px 0px inset;
background-color: #e8e8e8;
border-color: #ffe2e2;
border-style: solid;
border-width: 9px;
border-radius: 35px;
font-size: 25px;
font-weight: 900;
color: rgb(134, 124, 124);
font-family: monospace;
transition: transform 400ms cubic-bezier(.68,-0.55,.27,2.5),
border-color 400ms ease-in-out,
background-color 400ms ease-in-out;
word-spacing: -2px;
}
@keyframes movingBorders {
0% {
border-color: #fce4e4;
}
50% {
border-color: #ffd8d8;
}
90% {
border-color: #fce4e4;
}
}
button:hover {
background-color: #eee;
transform: scale(105%);
animation: movingBorders 3s infinite;
}
button svg {
margin-right: 11px;
fill: rgb(255, 110, 110);
transition: opacity 100ms ease-in-out;
}
.filled {
position: absolute;
opacity: 0;
top: 20px;
left: 22px;
}
@keyframes beatingHeart {
0% {
transform: scale(1);
}
15% {
transform: scale(1.15);
}
30% {
transform: scale(1);
}
45% {
transform: scale(1.15);
}
60% {
transform: scale(1);
}
}
button:hover .empty {
opacity: 0;
}
button:hover .filled {
opacity: 1;
animation: beatingHeart 1.2s infinite;
}
table {
border:1px solid green;
}
tr {
height: 50px;
}
.splitscreen {
display: flex;
}
.splitscreen .left,
.splitscreen .right {
flex: 1;
}
</style>
<link rel="icon" href="12.png" type="image/icon type">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Words !!!</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<script>
function hide() {
var x = document.getElementById("myDIV");
if (x.style.display === "none") {
x.style.display = "block";
} else {
x.style.display = "none";
}
}
function myFunction() {
var element = document.body;
element.classList.toggle("dark-mode");
}
var books;
var xmlhttp = new XMLHttpRequest();
var url = "https://raw.githubusercontent.com/Jeevasimba/files/main/egdata/data.json";
xmlhttp.onreadystatechange = function() {
if (this.readyState == 4 && this.status == 200) {
var myArr = JSON.parse(this.responseText);
books = myArr;
render(books);
}
};
xmlhttp.open("GET", url, true);
xmlhttp.send();
var render = function(data) {
var app = document.getElementById('app');
var appa = document.getElementById('myDIV');
var wordct = 0;
var act = 0;
var word = '<ul>'+
data.map(function(book){
wordct++;
return '<table style="width:100%;height:10%"><tr><td>'+ wordct + " . " +book.word +'</td></tr></table>';
}).join('');
+ '</ul>';
var a = '<ul>'+
data.map(function(book){
act++;
return '<table style="width:100%;height:10%"><tr><td>'+ act + " . "+ book.a +'</td></tr></table>';
}).join('');
+ '</ul>';
app.innerHTML = word;
appa.innerHTML = a;
}
</script>
</head>
<body>
<button class="button" onclick="hide()">
<svg class="empty" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="32" height="32"><path fill="none" d="M0 0H24V24H0z"></path><path d="M16.5 3C19.538 3 22 5.5 22 9c0 7-7.5 11-10 12.5C9.5 20 2 16 2 9c0-3.5 2.5-6 5.5-6C9.36 3 11 4 12 5c1-1 2.64-2 4.5-2zm-3.566 15.604c.881-.556 1.676-1.109 2.42-1.701C18.335 14.533 20 11.943 20 9c0-2.36-1.537-4-3.5-4-1.076 0-2.24.57-3.086 1.414L12 7.828l-1.414-1.414C9.74 5.57 8.576 5 7.5 5 5.56 5 4 6.656 4 9c0 2.944 1.666 5.533 4.645 7.903.745.592 1.54 1.145 2.421 1.7.299.189.595.37.934.572.339-.202.635-.383.934-.571z"></path></svg>
<svg class="filled" height="32" width="32" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M0 0H24V24H0z" fill="none"></path><path d="M16.5 3C19.538 3 22 5.5 22 9c0 7-7.5 11-10 12.5C9.5 20 2 16 2 9c0-3.5 2.5-6 5.5-6C9.36 3 11 4 12 5c1-1 2.64-2 4.5-2z"></path></svg>
Hide
</button>
<div class="splitscreen" style="margin-top: 100px;">
<div id="app" class="left">
</div>
<div id="myDIV" class="right">
</div>
</div>
</body>
</html>