mirror of
https://github.com/torappinfo/uweb.git
synced 2024-08-14 23:54:59 +00:00
Compare commits
No commits in common. "68fa9617bee6f3a5f038b9936a983fd49402bd63" and "f308403a3e454e7434fecc40e51c747933819f1d" have entirely different histories.
68fa9617be
...
f308403a3e
2 changed files with 13 additions and 14 deletions
|
@ -13,19 +13,16 @@ let sa = [`<head><meta charset="utf-8"><meta name="viewport" content="width=devi
|
||||||
<option value="monospace">
|
<option value="monospace">
|
||||||
<option value="cursive">
|
<option value="cursive">
|
||||||
</datalist>
|
</datalist>
|
||||||
<script>
|
<form onsubmit="let d=document;let f=d.forms[0];d.location.href='i:b1Save config.html%0A%0Ai:8lconfig.html%0Ai:0i/data/data/info.torapp.uweb/files/config.html:'
|
||||||
function save(){
|
+f.redirecturl.value+
|
||||||
let d=document;let f=d.forms[0];
|
'&'+ f.downloadpath.value+
|
||||||
let inputs = Array.from(f.querySelectorAll('input')).map(input => input.value);
|
'&'+ f.font.value+
|
||||||
inputs.pop();
|
'&'+ f.cursive.value +
|
||||||
inputs.push('<script charset="utf-8" src="https://jamesfengcao.codeberg.page/en/searchurl/config.js"><\\/script>');
|
'&'+ f.fantasy.value +
|
||||||
let str = inputs.join('\\n');
|
'&'+ f.fixed.value +
|
||||||
let url = 'i:b1Save config.html%0A%0Ai:8lconfig.html%0Ai:0lconfig.html:'+btoa(str);
|
'&'+ f.sansserif.value +
|
||||||
d.location.href=url;
|
'&'+ f.serif.value +
|
||||||
return false;
|
':https://jamesfengcao.codeberg.page/en/searchurl/template/config.html';return false;" accept-charset=utf-8 >`];
|
||||||
}
|
|
||||||
</script>
|
|
||||||
<form onsubmit="return save()" accept-charset=utf-8 >`];
|
|
||||||
|
|
||||||
function gen(text) {
|
function gen(text) {
|
||||||
let strs = text.split('\n');
|
let strs = text.split('\n');
|
||||||
|
|
|
@ -20,7 +20,9 @@ function save(){
|
||||||
inputs.pop();
|
inputs.pop();
|
||||||
inputs.push('<script charset="utf-8" src="https://jamesfengcao.codeberg.page/zh/searchurl/config.js"><\\/script>');
|
inputs.push('<script charset="utf-8" src="https://jamesfengcao.codeberg.page/zh/searchurl/config.js"><\\/script>');
|
||||||
let str = inputs.join('\\n');
|
let str = inputs.join('\\n');
|
||||||
let url = 'i:b1保存配置%0A%0Ai:8lconfig.html%0Ai:0lconfig.html:'+btoa(str);
|
const encoder = new TextEncoder();
|
||||||
|
const bytes = encoder.encode(str);
|
||||||
|
let url = 'i:b1保存配置%0A%0Ai:8lconfig.html%0Ai:0lconfig.html:'+btoa(bytes);
|
||||||
d.location.href=url;
|
d.location.href=url;
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue