Initial YakPanel commit
This commit is contained in:
1
YakPanel/static/codemirror/addon/dialog/dialog.css
vendored
Normal file
1
YakPanel/static/codemirror/addon/dialog/dialog.css
vendored
Normal file
@@ -0,0 +1 @@
|
||||
.CodeMirror-dialog{position:absolute;left:0;right:0;background:inherit;z-index:15;padding:.4em .8em;overflow:hidden;color:inherit}.CodeMirror-dialog-top{border-bottom:1px solid #eee;top:0}.CodeMirror-dialog-bottom{border-top:1px solid #eee;bottom:0}.CodeMirror-dialog input{border:0;outline:0;background:transparent;width:20em;color:inherit;font-family:monospace}.CodeMirror-dialog button{font-size:70%}.Dialog-close{color:#111;float:right;font-family:Arial;font-size:16px;height:30px;line-height:30px;text-align:center;width:30px;cursor:pointer}
|
||||
1
YakPanel/static/codemirror/addon/dialog/dialog.js
vendored
Normal file
1
YakPanel/static/codemirror/addon/dialog/dialog.js
vendored
Normal file
@@ -0,0 +1 @@
|
||||
(function(a){if(typeof exports=="object"&&typeof module=="object"){a(require("../../lib/codemirror"))}else{if(typeof define=="function"&&define.amd){define(["../../lib/codemirror"],a)}else{a(CodeMirror)}}})(function(b){function c(d,h,e){var g=d.getWrapperElement();var f;f=g.appendChild(document.createElement("div"));if(e){f.className="CodeMirror-dialog CodeMirror-dialog-bottom"}else{f.className="CodeMirror-dialog CodeMirror-dialog-top"}if(typeof h=="string"){f.innerHTML=h}else{f.appendChild(h)}return f}function a(d,e){if(d.state.currentNotificationClose){d.state.currentNotificationClose()}d.state.currentNotificationClose=e}b.defineExtension("openDialog",function(i,j,l){if(!l){l={}}a(this,null);var f=c(this,i,l.bottom);var e=false,g=this;function k(m){if(typeof m=="string"){h.value=m}else{if(e){return}e=true;f.parentNode.removeChild(f);g.focus();if(l.onClose){l.onClose(f)}}}var h=f.getElementsByTagName("input")[0],d;if(h){h.focus();if(l.value){h.value=l.value;if(l.selectValueOnOpen!==false){h.select()}}if(l.onInput){b.on(h,"input",function(m){l.onInput(m,h.value,k)})}if(l.onKeyUp){b.on(h,"keyup",function(m){l.onKeyUp(m,h.value,k)})}b.on(h,"keydown",function(m){if(l&&l.onKeyDown&&l.onKeyDown(m,h.value,k)){return}if(m.keyCode==27||(l.closeOnEnter!==false&&m.keyCode==13)){h.blur();b.e_stop(m);k()}if(m.keyCode==13){j(h.value,m)}});if(l.closeOnBlur!==false){b.on(h,"blur",k)}}else{if(d=f.getElementsByTagName("button")[0]){b.on(d,"click",function(){k();g.focus()});if(l.closeOnBlur!==false){b.on(d,"blur",k)}d.focus()}}return k});b.defineExtension("openConfirm",function(m,g,o){a(this,null);var h=c(this,m,o&&o.bottom);var j=h.getElementsByTagName("button");var f=false,k=this,d=1;function n(){if(f){return}f=true;h.parentNode.removeChild(h);k.focus()}j[0].focus();for(var e=0;e<j.length;++e){var l=j[e];(function(i){b.on(l,"click",function(p){b.e_preventDefault(p);n();if(i){i(k)}})})(g[e]);b.on(l,"blur",function(){--d;setTimeout(function(){if(d<=0){n()}},200)});b.on(l,"focus",function(){++d})}});b.defineExtension("openNotification",function(g,e){a(this,j);var f=c(this,g,e&&e.bottom);var d=false,h;var i=e&&typeof e.duration!=="undefined"?e.duration:5000;function j(){if(d){return}d=true;clearTimeout(h);f.parentNode.removeChild(f)}b.on(f,"click",function(k){b.e_preventDefault(k);j()});if(i){h=setTimeout(j,i)}return j})});
|
||||
13
YakPanel/static/codemirror/addon/dialog/index.html
vendored
Normal file
13
YakPanel/static/codemirror/addon/dialog/index.html
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
<div>
|
||||
<p style="margin-bottom:8px"><span style="display: inline-block; width: 104px;">目标URL</span><input class="bt-input-text" type="text" name="toUrl" value="http://" style="margin-left: 5px;width: 380px;height: 30px;margin-right:10px;" placeholder="请填写完整URL,例:http://www.test.com"></p>
|
||||
<p style="margin-bottom:8px"><span style="display: inline-block; width: 104px;">发送域名</span><input class="bt-input-text" type="text" name="toDomain" value="$host" style="margin-left: 5px;width: 380px;height: 30px;margin-right:10px;" placeholder="发送到目标服务器的域名,例:www.test.com"></p>
|
||||
<p style="margin-bottom:8px"><span style="display: inline-block; width: 104px;">内容替换</span><input class="bt-input-text" type="text" name="sub1" value="" style="margin-left: 5px;width: 182px;height: 30px;margin-right:10px;" placeholder="被替换的文本,可留空"><input class="bt-input-text" type="text" name="sub2" value="" style="margin-left: 5px;width: 183px;height: 30px;margin-right:10px;" placeholder="替换为,可留空"></p>
|
||||
<div class="label-input-group ptb10"><label style="font-weight:normal"><input type="checkbox" name="status" onclick="Proxy('w6.hao.com',1)">启用反向代理</label><label style="margin-left: 18px;"><input type="checkbox" name="status" onclick="OpenCache('w6.hao.com',1)">开启缓存</label></div>
|
||||
<ul class="help-info-text c7 ptb10">
|
||||
<li>目标Url必需是可以访问的,否则将直接502</li>
|
||||
<li>默认本站点所有域名访问将被传递到目标服务器,请确保目标服务器已绑定域名</li>
|
||||
<li>若您是被动代理,请在发送域名处填写上目标站点的域名</li>
|
||||
<li>若您不需要内容替换功能,请直接留空</li>
|
||||
<li>可通过purge清理指定URL的缓存,示例:http://test.com/purge/test.png</li>
|
||||
</ul>
|
||||
</div>
|
||||
Reference in New Issue
Block a user