Skip to content

Commit 008a2da

Browse files
committed
👩‍👧 Ana'yı feature branch'e merge'le
2 parents d26b1a0 + 2080612 commit 008a2da

File tree

13 files changed

+127
-50
lines changed

13 files changed

+127
-50
lines changed

birim/tckt/birim.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<div id="tc" style="opacity:0">
1+
<div id="tc">
22
<div id=tca>🔒</div>
33
<div id=tci>
44
<div id="tcc">

birim/telefon/birim.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
</div>
2121
</div>
2222
<div id="tenftb">
23-
<birim:tckt />
23+
<birim:tckt style="opacity:0" />
2424
<div id="tenft-button" style="display:none" data-en="Hide">Gizle</div>
2525
</div>
2626
</div>

font/f700-tr.txt

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ Tarayıcı cüzdanı bağlandı
55
E-devlet ile giriş yap
66
E-devlet'ten bilgileriniz alındı
77
Cüzdanıma istek yolla
8+
Gizle
89
Türkçe English Bağlı değil Evet Hayır
910
0123456789x
1011
abcdefABCDEF

incele/sayfa.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ const EşikModal = dom.adla("inmes");
2929
/** @const {Element} */
3030
const SilModal = dom.adla("inmsy");
3131

32-
dom.adla("tc").style.opacity = "";
33-
3432
const modalKapat = () => {
3533
Mask.style.display = "none";
3634
İmeceİptalModal.style.display = "none";
@@ -39,8 +37,7 @@ const modalKapat = () => {
3937
}
4038

4139
Mask.onmousedown = (e) => {
42-
if (e.target != Mask) return;
43-
modalKapat();
40+
if (e.target == Mask) modalKapat();
4441
};
4542

4643
dom.adla("inx").onclick = modalKapat;

tools/workers.js lib/cf-worker.js

File renamed without changes.

lib/ipfs.js

+8-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
import { base58 } from '/lib/çevir';
22

3-
const URL = "https://ipfs.kimlikdao.org/api/v0/add";
3+
/**
4+
* @const {string}
5+
* @noinline
6+
*/
7+
const IPFS_URL = "//ipfs.kimlikdao.org/";
48

59
/**
610
* @param {!Uint8Array} data heş
@@ -31,7 +35,7 @@ const CID = (hash) => {
3135
*/
3236
const cidBytetanOku = (cidByte) => {
3337
const yerelCID = CID(cidByte);
34-
return fetch("//ipfs.kimlikdao.org/ipfs/" + yerelCID)
38+
return fetch(IPFS_URL + "ipfs/" + yerelCID)
3539
.then((res) => res.arrayBuffer())
3640
.then((buf) => hash(new Uint8Array(buf))
3741
.then((gelenByte) => CID(new Uint8Array(gelenByte)) === yerelCID
@@ -42,15 +46,15 @@ const cidBytetanOku = (cidByte) => {
4246

4347
/**
4448
* @param {string} veri IPFS'e yazılacak veri.
45-
* @return {Promise<Uint8Array>} onaylanmış IPFS cidByte.
49+
* @return {Promise<!Uint8Array>} onaylanmış IPFS cidByte.
4650
*/
4751
const yaz = (veri) => {
4852
/** @type {!Uint8Array} */
4953
const encoded = new TextEncoder().encode(veri);
5054
console.log(veri.length);
5155
const formData = new FormData()
5256
formData.append("blob", new Blob([encoded]));
53-
const gelenSöz = fetch(URL, {
57+
const gelenSöz = fetch(IPFS_URL + "api/v0/add", {
5458
method: "POST",
5559
body: formData
5660
}).then((res) => res.json()).then((res) => res["Hash"])

lib/sha3.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
import { hex } from '/lib/çevir';
66

77
/**
8-
* A keccak256 implementation specialized to byte arrays of a length
9-
* multiple of 4. The data at hand needs to passed as a `Uint32Array`
10-
* which enforces the length requirement.
8+
* A keccak256 implementation specialized to byte arrays of a length multiple
9+
* of 4. The data at hand needs to be passed as a `Uint32Array` which enforces
10+
* the length requirement.
1111
*
1212
* @param {Uint32Array} words A typed array of `u32`s to be hashed.
1313
* @return {string} hex encoded hash.

lib/çevir.js

+19-5
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,10 @@ for (let /** number */ n = 0; n <= 0xff; ++n) {
66
}
77

88
/**
9-
* @param {ArrayBuffer|Uint8Array} buffer hex'e çevrilecek buffer.
9+
* @param {!Uint8Array} buff hex'e çevrilecek Uint8Array.
1010
* @return {string} hex temsil eden dizi.
1111
*/
12-
const hex = (buffer) => {
13-
const buff = new Uint8Array(buffer);
12+
const hex = (buff) => {
1413
const octets = new Array(buff.length);
1514

1615
for (let /** number */ i = 0; i < buff.length; ++i)
@@ -87,12 +86,27 @@ const base64 = (buffer) => {
8786
* @param {string} b64 base64 olarak yazılı veri.
8887
*/
8988
const base64ten = (b64) => {
90-
const decoded = window.atob(b64);
89+
const decoded = atob(b64);
9190
const buffer = new Uint8Array(decoded.length);
9291
const len = decoded.length;
9392
for (let i = 0; i < len; ++i)
9493
buffer[i] = decoded.charCodeAt(i);
9594
return buffer;
9695
};
9796

98-
export { base58, base64, base64ten, hex, hexten, Uint8denHexe }
97+
const uint8ArrayeBase64ten = (buffer, b64) => {
98+
const decoded = atob(b64);
99+
const len = decoded.length;
100+
for (let i = 0; i < len; ++i)
101+
buffer[i] = decoded.charCodeAt(i);
102+
}
103+
104+
export {
105+
base58,
106+
base64,
107+
base64ten,
108+
hex,
109+
hexten,
110+
uint8ArrayeBase64ten,
111+
Uint8denHexe,
112+
}

oyla/sayfa.css

+18
Original file line numberDiff line numberDiff line change
@@ -206,6 +206,7 @@
206206
font-size: 11pt;
207207
color: #888;
208208
border-bottom: 1px solid rgba(0 0 0 / 10%);
209+
border-bottom: 1px solid rgba(0 0 0 / 10%);
209210
}
210211

211212
.oyok {
@@ -239,6 +240,7 @@
239240
display: flex;
240241
justify-content: space-between;
241242
width: 100%;
243+
width: 100%;
242244
}
243245

244246
.oyaotitle {
@@ -250,6 +252,7 @@
250252
.oyaotb {
251253
position: relative;
252254
cursor: pointer;
255+
cursor: pointer;
253256
width: 25px;
254257
height: 20px;
255258
opacity: 0.3;
@@ -278,6 +281,7 @@
278281
.oyao_middle {
279282
display: flex;
280283
width: 100%;
284+
width: 100%;
281285
}
282286

283287
@media (max-width: 425px) {
@@ -371,6 +375,8 @@
371375
display: flex;
372376
justify-content: center;
373377
margin-bottom: 1em;
378+
justify-content: center;
379+
margin-bottom: 1em;
374380
}
375381

376382
.chartbtn {
@@ -435,6 +441,18 @@
435441
margin-top: 3em;
436442
}
437443

444+
.oybdis {
445+
margin: 1em 0;
446+
cursor: pointer;
447+
color: #2ec479;
448+
449+
}
450+
451+
.oyao_bottom {
452+
width: 100%;
453+
margin-top: 3em;
454+
}
455+
438456
.oybdis {
439457
margin: 1em 0;
440458
cursor: pointer;

oyla/sayfa.html

+12-3
Original file line numberDiff line numberDiff line change
@@ -76,18 +76,20 @@ <h2><a href="/">KimlikDAO</a></h2>
7676
</div>
7777
<div id="oyac" class="oyc">
7878
<div class="oycb">Devam eden oylamalar</div>
79-
<div class="oyok" style="display:none">
80-
<div class="oyao_top">
79+
<div class="oyok" style="display:none" style="display:none">
80+
<div class="oyao__top">
8181
<div class="oyaotitle">TCKT Fiyat Değişikliği</div>
82-
<div class="oyaotb" style="display:none"></div>
82+
<div class="oyaotb" style="display:none" style="display:none"></div>
8383
</div>
8484
<div class="oyao_middle">
8585
<div class="oyaodac">
8686
<div class="oyaod">TCKT fiyatı $1,5 olarak belirlensin.</div>
8787
<div class="oyaoac">
8888
<div>Address: <span class="code_adr">TCKT</span> on <span class="code_network">Avalanche</span>(<span
8989
class="code_network">Raw</span>:
90+
9091
<span class="code_adr">"0xa86a, 0xcCc23478203948cCc"</span>)
92+
9193
</div>
9294
<div>Calldata: <span class="code_function">updatePrice</span>(USDC, $1.5) (<span
9395
class="code_network">Raw</span>: "0x94934811238773733")</div>
@@ -116,6 +118,13 @@ <h2><a href="/">KimlikDAO</a></h2>
116118
</div>
117119
<div class="oybdis">Discussion</div>
118120
</div>
121+
<div class="oyao_bottom">
122+
<div class="oybt">lorem ipsum Lorem Ipsum is simply dummy text of the
123+
printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the
124+
1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.
125+
</div>
126+
<div class="oybdis">Discussion</div>
127+
</div>
119128
</div>
120129
</div>
121130
<div id="oyiac" class="oyc">

tools/Makefile

+2-1
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,10 @@ removeLang = $(subst -tr,,$(subst -en,,$(1)))
1313
Lang-en := false
1414
Lang-tr := true
1515

16-
build/prod.js: tools/prod.js tools/workers.js
16+
build/prod.js: tools/prod.js lib/cf-worker.js
1717
mkdir -p build
1818
yarn google-closure-compiler -W VERBOSE -O ADVANCED --charset UTF-8 \
19+
--env BROWSER \
1920
--assume_function_wrapper \
2021
--js $^ \
2122
--js_output_file $@

tools/dev.js

+1
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ const SAYFALAR = {
4343
"/al": "al/sayfa.html",
4444
"/get": "al/sayfa.html",
4545
"/incele": "incele/sayfa.html",
46+
"/view": "incele/sayfa.html",
4647
"/oyla": "oyla/sayfa.html",
4748
"/vote": "oyla/sayfa.html",
4849
};

0 commit comments

Comments
 (0)