Start work on UI of serverPage

This commit is contained in:
Prayag committed 2022-03-09 21:33:12 +05:30
1 parent 7f447538e9
commit d41ecb8312
5 files changed
+203 -12

No files matched your search

+43 -7
View File
@@ -5,25 +5,61 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="../css/login.css">
<link rel="stylesheet" href="../css/global.css">
<title>Jellyfin</title>
</head>
<body>
<main>
<canvas id="background"></canvas>
<section class="server__cont">
<input type="url" class="input__text server__url">
<input type="button" class="input__btn save__server" value="Save">
<div class="logo">
<svg width="100%" height="100%" viewBox="0 0 1536 460" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M40.0977 349.84C23.6868 338.455 10.6758 322.827 2.45385 304.624C0.910092 302.304 0.0593875 299.592 0.0013282 296.806C-0.0263705 294.928 0.379494 293.068 1.1874 291.373C1.99531 289.677 3.18341 288.19 4.65942 287.029C7.41246 284.546 10.9767 283.153 14.6836 283.111C19.8849 283.111 24.4608 285.893 28.3618 291.423C34.0706 304.849 43.3783 316.435 55.2573 324.903C66.7707 333.142 80.6039 337.511 94.7612 337.38C117.267 337.38 135.522 330.455 149.523 316.607C163.525 302.759 170.532 284.587 170.543 262.092V34.2202C170.49 32.256 170.854 30.3028 171.612 28.4898C172.369 26.6767 173.503 25.045 174.938 23.7023C177.991 20.8911 182.032 19.4002 186.18 19.5544C188.199 19.4592 190.215 19.7781 192.106 20.4914C193.997 21.2048 195.722 22.2975 197.175 23.7023C198.547 25.0808 199.624 26.7243 200.34 28.5326C201.056 30.3409 201.396 32.2761 201.339 34.2202V262.026C201.607 280.846 196.882 299.401 187.645 315.801C178.754 331.548 165.642 344.5 149.787 353.198C133.7 362.207 115.386 366.711 94.8436 366.711C75.2857 366.909 56.1514 361.013 40.0977 349.84Z" fill="white"/>
<path d="M492.779 232.513C491.426 233.85 489.822 234.906 488.059 235.62C486.297 236.335 484.41 236.694 482.508 236.678H297.729C297.729 256.232 301.718 273.745 309.695 289.218C317.414 304.426 329.277 317.14 343.915 325.891C358.74 334.867 376.259 339.349 396.472 339.338C411.076 339.583 425.514 336.225 438.511 329.561C450.211 323.612 460.409 315.086 468.336 304.624C471.143 302.007 474.776 300.452 478.607 300.229C481.923 300.397 485.059 301.789 487.407 304.137C489.755 306.485 491.147 309.621 491.314 312.937C491.228 314.893 490.745 316.812 489.897 318.578C489.048 320.343 487.851 321.918 486.376 323.208C475.552 336.231 462.153 346.878 447.021 354.482C431.568 362.54 414.394 366.736 396.966 366.711C371.87 366.711 349.704 361.334 330.468 350.581C311.494 340.071 295.898 324.384 285.499 305.349C274.756 285.97 269.379 263.568 269.368 238.143C269.368 211.412 274.663 188.028 285.252 167.99C295.841 147.953 309.937 132.634 327.538 122.034C344.451 111.641 363.914 106.143 383.765 106.15C402.947 106.055 421.85 110.751 438.758 119.812C456.071 129.135 470.518 142.996 480.55 159.908C491.314 177.466 496.856 198.315 497.174 222.456C497.2 224.349 496.822 226.225 496.064 227.96C495.306 229.694 494.186 231.247 492.779 232.513ZM331.208 154.049C315.078 167.085 304.73 185.849 300.165 210.342H466.871V206.424C465.543 192.521 460.469 179.238 452.189 167.99C444.253 157.253 433.749 148.678 421.639 143.053C409.805 137.446 396.877 134.524 383.782 134.494C364.864 134.494 347.339 141.012 331.208 154.049Z" fill="white"/>
<path d="M585.91 357.658C583.856 359.761 581.218 361.199 578.338 361.786C575.458 362.373 572.468 362.082 569.755 360.951C567.043 359.819 564.732 357.9 563.122 355.441C561.512 352.981 560.677 350.096 560.726 347.157V14.6658C560.726 10.7762 562.271 7.04587 565.022 4.2955C567.772 1.54512 571.502 0 575.392 0C579.281 0 583.012 1.54512 585.762 4.2955C588.513 7.04587 590.058 10.7762 590.058 14.6658V347.157C590.119 349.098 589.783 351.03 589.069 352.836C588.356 354.642 587.281 356.283 585.91 357.658Z" fill="white"/>
<path d="M698.348 357.658C696.294 359.761 693.656 361.199 690.776 361.786C687.896 362.373 684.906 362.082 682.193 360.951C679.481 359.819 677.17 357.9 675.56 355.441C673.95 352.981 673.115 350.096 673.164 347.157V14.6658C673.164 10.7762 674.709 7.04587 677.459 4.2955C680.21 1.54512 683.94 0 687.83 0C691.719 0 695.45 1.54512 698.2 4.2955C700.95 7.04587 702.496 10.7762 702.496 14.6658V347.157C702.557 349.098 702.22 351.03 701.507 352.836C700.794 354.642 699.719 356.283 698.348 357.658Z" fill="white"/>
<path d="M972.093 111.763C973.465 113.142 974.542 114.785 975.258 116.593C975.974 118.402 976.314 120.337 976.258 122.281V337.906C976.258 363.628 971.204 385.624 961.098 403.894C951.526 421.617 936.89 436.087 919.059 445.456C901.129 454.904 880.922 459.628 858.437 459.628C845.516 459.72 832.632 458.238 820.069 455.216C809.638 452.893 799.639 448.937 790.441 443.497C783.594 439.25 780.17 434.521 780.17 429.308C780.358 427.637 780.688 425.985 781.158 424.37C781.919 421.437 783.661 418.852 786.096 417.046C788.211 415.465 790.779 414.605 793.42 414.593C795.461 414.615 797.469 415.117 799.28 416.058C820.129 427.459 840.013 433.166 858.931 433.177C885.98 433.177 907.411 424.705 923.224 407.762C939.036 390.82 946.937 367.677 946.926 338.334V321.249C938.426 335.233 926.254 346.62 911.734 354.169C896.432 362.478 879.273 366.771 861.861 366.645C833.517 366.645 812.009 358.169 797.338 341.215C782.667 324.261 775.331 301.288 775.331 272.297V122.281C775.331 118.391 776.876 114.661 779.626 111.911C782.377 109.16 786.107 107.615 789.997 107.615C793.886 107.615 797.617 109.16 800.367 111.911C803.117 114.661 804.663 118.391 804.663 122.281V267.952C804.663 291.423 809.798 309.189 820.069 321.249C830.34 333.309 846.388 339.344 868.214 339.355C881.654 339.332 894.865 335.882 906.599 329.331C918.37 323.064 928.437 314.025 935.931 302.995C943.056 292.726 946.891 280.533 946.926 268.034V122.281C946.941 119.372 947.812 116.532 949.431 114.115C951.049 111.699 953.344 109.812 956.027 108.69C958.711 107.568 961.666 107.262 964.523 107.808C967.38 108.355 970.013 109.73 972.093 111.763Z" fill="white"/>
<path d="M1115.82 38.1871C1110.1 45.0344 1107.25 54.4879 1107.26 66.5476V116.899H1162.02C1165.59 116.891 1169.02 118.3 1171.55 120.816C1172.87 122.084 1173.91 123.603 1174.62 125.283C1175.34 126.963 1175.7 128.769 1175.7 130.593C1175.7 132.418 1175.34 134.224 1174.62 135.904C1173.91 137.583 1172.87 139.103 1171.55 140.37C1169.02 142.876 1165.59 144.278 1162.02 144.271H1107.3V347.157C1107.3 351.046 1105.75 354.777 1103 357.527C1100.25 360.278 1096.52 361.823 1092.63 361.823C1088.74 361.823 1085.01 360.278 1082.26 357.527C1079.51 354.777 1077.96 351.046 1077.96 347.157V144.271H1042.28C1040.45 144.314 1038.63 143.967 1036.94 143.251C1035.26 142.536 1033.74 141.47 1032.5 140.124C1029.99 137.586 1028.59 134.16 1028.6 130.593C1028.51 128.742 1028.81 126.892 1029.48 125.165C1030.15 123.437 1031.18 121.871 1032.5 120.569C1035.15 118.104 1038.66 116.784 1042.28 116.899H1077.96V66.5476C1077.96 46.0275 1083.91 30.1162 1095.81 18.8137C1107.7 7.51122 1123.61 1.89288 1143.54 1.95872C1152.19 1.88148 1160.79 3.28434 1168.97 6.10664C1176.79 8.88288 1180.7 13.3655 1180.69 19.5544C1180.74 21.3639 1180.42 23.1646 1179.75 24.846C1179.08 26.5273 1178.07 28.0537 1176.79 29.3316C1175.67 30.5486 1174.3 31.5226 1172.79 32.1935C1171.28 32.8645 1169.64 33.2181 1167.98 33.2326C1164.28 33.0699 1160.64 32.2449 1157.23 30.7966C1151.67 29.1042 1145.92 28.1198 1140.12 27.8667C1129.61 27.9106 1121.52 31.3507 1115.82 38.1871ZM1224.16 70.2182C1220.56 67.1237 1218.78 62.6301 1218.78 56.7704V51.8324C1218.78 45.9726 1220.65 41.49 1224.39 38.3846C1228.13 35.2792 1233.27 33.7319 1239.8 33.7429C1252.83 33.7429 1259.35 39.7782 1259.35 51.8489V56.7868C1259.35 62.6466 1257.71 67.1402 1254.22 70.2346C1250.73 73.3291 1245.82 74.8763 1239.3 74.8763C1232.79 74.8763 1227.68 73.3126 1224.16 70.2182ZM1249.82 357.658C1247.77 359.761 1245.13 361.199 1242.25 361.786C1239.37 362.373 1236.38 362.082 1233.67 360.951C1230.95 359.819 1228.64 357.9 1227.03 355.441C1225.42 352.981 1224.59 350.096 1224.64 347.157V122.281C1224.64 120.355 1225.02 118.448 1225.75 116.669C1226.49 114.889 1227.57 113.273 1228.93 111.911C1230.3 110.549 1231.91 109.469 1233.69 108.732C1235.47 107.995 1237.38 107.615 1239.3 107.615C1241.23 107.615 1243.14 107.995 1244.92 108.732C1246.7 109.469 1248.31 110.549 1249.67 111.911C1251.04 113.273 1252.12 114.889 1252.85 116.669C1253.59 118.448 1253.97 120.355 1253.97 122.281V347.157C1254.02 349.101 1253.68 351.036 1252.96 352.842C1252.24 354.648 1251.15 356.287 1249.77 357.658H1249.82Z" fill="white"/>
<path d="M1514.73 132.782C1528.91 150.559 1535.99 174.108 1535.99 203.429V347.157C1536.05 349.119 1535.69 351.07 1534.93 352.881C1534.17 354.692 1533.04 356.32 1531.6 357.658C1528.86 360.353 1525.17 361.851 1521.33 361.823C1519.39 361.884 1517.45 361.547 1515.64 360.832C1513.84 360.117 1512.2 359.039 1510.82 357.664C1509.45 356.29 1508.37 354.649 1507.65 352.841C1506.94 351.034 1506.6 349.099 1506.66 347.157V204.893C1506.66 183.704 1501.37 166.514 1490.78 153.324C1480.19 140.135 1463.81 133.551 1441.65 133.573C1427.92 133.634 1414.4 136.917 1402.17 143.158C1389.94 149.399 1379.35 158.423 1371.25 169.505C1363.64 179.757 1359.53 192.179 1359.51 204.943V347.206C1359.51 351.096 1357.97 354.826 1355.22 357.577C1352.47 360.327 1348.73 361.872 1344.85 361.872C1340.96 361.872 1337.23 360.327 1334.47 357.577C1331.72 354.826 1330.18 351.096 1330.18 347.206V128.141C1330.18 124.251 1331.72 120.521 1334.47 117.77C1337.23 115.02 1340.96 113.475 1344.85 113.475C1348.73 113.475 1352.47 115.02 1355.22 117.77C1357.97 120.521 1359.51 124.251 1359.51 128.141V155.036C1368.29 141.023 1380.91 129.37 1397.37 120.075C1412.74 111.083 1430.21 106.281 1448.02 106.15C1478.31 106.15 1500.55 115.028 1514.73 132.782Z" fill="white"/>
</svg>
</div>
<div class="form__cont">
<div class="input">
<input id="serverUrl" type="url" class="input__text server__url">
<label for="serverUrl" class="input__label">Server Address</label>
</div>
<div class="input"></div>
<input type="button" class="input__btn save__server" value="Save">
</div>
</section>
<section class="user__cont"></section>
<section class="manual__input"></section>
<div class="popup error hide">
<div class="icon">
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-exclamation-triangle" viewBox="0 0 16 16">
<path d="M7.938 2.016A.13.13 0 0 1 8.002 2a.13.13 0 0 1 .063.016.146.146 0 0 1 .054.057l6.857 11.667c.036.06.035.124.002.183a.163.163 0 0 1-.054.06.116.116 0 0 1-.066.017H1.146a.115.115 0 0 1-.066-.017.163.163 0 0 1-.054-.06.176.176 0 0 1 .002-.183L7.884 2.073a.147.147 0 0 1 .054-.057zm1.044-.45a1.13 1.13 0 0 0-1.96 0L.165 13.233c-.457.778.091 1.767.98 1.767h13.713c.889 0 1.438-.99.98-1.767L8.982 1.566z"/>
<path d="M7.002 12a1 1 0 1 1 2 0 1 1 0 0 1-2 0zM7.1 5.995a.905.905 0 1 1 1.8 0l-.35 3.507a.552.552 0 0 1-1.1 0L7.1 5.995z"/>
</svg>
</div>
<h2 class="text">The url given is not a valid JF server Url </h2>
</div>
</main>
<script>if (typeof module === 'object') {
window.module = module;
module = undefined;
};
</script>
<script src="../../common/jquery.js"></script>
<script src="../js/login.js"></script>
<script>if (window.module) module = window.module;</script>
</script>
<script src="../../common/jquery.js"></script>
<script src="../js/login.js"></script>
<script>if (window.module) module = window.module;</script>
<script>
function normalizeColor(e){return[(e>>16&255)/255,(e>>8&255)/255,(255&e)/255]}["SCREEN","LINEAR_LIGHT"].reduce(((e,n,t)=>Object.assign(e,{[n]:t})),{});class MiniGl{constructor(e,n,t,i=!1){const s=this,o=-1!==document.location.search.toLowerCase().indexOf("debug=webgl");s.canvas=e,s.gl=s.canvas.getContext("webgl",{antialias:!0}),s.meshes=[];const r=s.gl;n&&t&&this.setSize(n,t),s.lastDebugMsg,s.debug=i&&o?function(e){const n=new Date;n-s.lastDebugMsg>1e3&&console.log("---"),console.log(n.toLocaleTimeString()+Array(Math.max(0,32-e.length)).join(" ")+e+": ",...Array.from(arguments).slice(1)),s.lastDebugMsg=n}:()=>{},Object.defineProperties(s,{Material:{enumerable:!1,value:class{constructor(e,n,t={}){const i=this;function o(e,n){const t=r.createShader(e);return r.shaderSource(t,n),r.compileShader(t),r.getShaderParameter(t,r.COMPILE_STATUS)||console.error(r.getShaderInfoLog(t)),s.debug("Material.compileShaderSource",{source:n}),t}function a(e,n){return Object.entries(e).map((([e,t])=>t.getDeclaration(e,n))).join("\n")}i.uniforms=t,i.uniformInstances=[];const l="\n precision highp float;\n ";i.vertexSource=`\n ${l}\n attribute vec4 position;\n attribute vec2 uv;\n attribute vec2 uvNorm;\n ${a(s.commonUniforms,"vertex")}\n ${a(t,"vertex")}\n ${e}\n `,i.Source=`\n ${l}\n ${a(s.commonUniforms,"fragment")}\n ${a(t,"fragment")}\n ${n}\n `,i.vertexShader=o(r.VERTEX_SHADER,i.vertexSource),i.fragmentShader=o(r.FRAGMENT_SHADER,i.Source),i.program=r.createProgram(),r.attachShader(i.program,i.vertexShader),r.attachShader(i.program,i.fragmentShader),r.linkProgram(i.program),r.getProgramParameter(i.program,r.LINK_STATUS)||console.error(r.getProgramInfoLog(i.program)),r.useProgram(i.program),i.attachUniforms(void 0,s.commonUniforms),i.attachUniforms(void 0,i.uniforms)}attachUniforms(e,n){const t=this;void 0===e?Object.entries(n).forEach((([e,n])=>{t.attachUniforms(e,n)})):"array"==n.type?n.value.forEach(((n,i)=>t.attachUniforms(`${e}[${i}]`,n))):"struct"==n.type?Object.entries(n.value).forEach((([n,i])=>t.attachUniforms(`${e}.${n}`,i))):(s.debug("Material.attachUniforms",{name:e,uniform:n}),t.uniformInstances.push({uniform:n,location:r.getUniformLocation(t.program,e)}))}}},Uniform:{enumerable:!1,value:class{constructor(e){this.type="float",Object.assign(this,e),this.typeFn={float:"1f",int:"1i",vec2:"2fv",vec3:"3fv",vec4:"4fv",mat4:"Matrix4fv"}[this.type]||"1f",this.update()}update(e){void 0!==this.value&&r[`uniform${this.typeFn}`](e,0===this.typeFn.indexOf("Matrix")?this.transpose:this.value,0===this.typeFn.indexOf("Matrix")?this.value:null)}getDeclaration(e,n,t){const i=this;if(i.excludeFrom!==n){if("array"===i.type)return i.value[0].getDeclaration(e,n,i.value.length)+`\nconst int ${e}_length = ${i.value.length};`;if("struct"===i.type){let s=e.replace("u_","");return s=s.charAt(0).toUpperCase()+s.slice(1),`uniform struct ${s} \n {\n`+Object.entries(i.value).map((([e,t])=>t.getDeclaration(e,n).replace(/^uniform/,""))).join("")+`\n} ${e}${t>0?`[${t}]`:""};`}return`uniform ${i.type} ${e}${t>0?`[${t}]`:""};`}}}},PlaneGeometry:{enumerable:!1,value:class{constructor(e,n,t,i,o){r.createBuffer(),this.attributes={position:new s.Attribute({target:r.ARRAY_BUFFER,size:3}),uv:new s.Attribute({target:r.ARRAY_BUFFER,size:2}),uvNorm:new s.Attribute({target:r.ARRAY_BUFFER,size:2}),index:new s.Attribute({target:r.ELEMENT_ARRAY_BUFFER,size:3,type:r.UNSIGNED_SHORT})},this.setTopology(t,i),this.setSize(e,n,o)}setTopology(e=1,n=1){const t=this;t.xSegCount=e,t.ySegCount=n,t.vertexCount=(t.xSegCount+1)*(t.ySegCount+1),t.quadCount=t.xSegCount*t.ySegCount*2,t.attributes.uv.values=new Float32Array(2*t.vertexCount),t.attributes.uvNorm.values=new Float32Array(2*t.vertexCount),t.attributes.index.values=new Uint16Array(3*t.quadCount);for(let e=0;e<=t.ySegCount;e++)for(let n=0;n<=t.xSegCount;n++){const i=e*(t.xSegCount+1)+n;if(t.attributes.uv.values[2*i]=n/t.xSegCount,t.attributes.uv.values[2*i+1]=1-e/t.ySegCount,t.attributes.uvNorm.values[2*i]=n/t.xSegCount*2-1,t.attributes.uvNorm.values[2*i+1]=1-e/t.ySegCount*2,n<t.xSegCount&&e<t.ySegCount){const s=e*t.xSegCount+n;t.attributes.index.values[6*s]=i,t.attributes.index.values[6*s+1]=i+1+t.xSegCount,t.attributes.index.values[6*s+2]=i+1,t.attributes.index.values[6*s+3]=i+1,t.attributes.index.values[6*s+4]=i+1+t.xSegCount,t.attributes.index.values[6*s+5]=i+2+t.xSegCount}}t.attributes.uv.update(),t.attributes.uvNorm.update(),t.attributes.index.update(),s.debug("Geometry.setTopology",{uv:t.attributes.uv,uvNorm:t.attributes.uvNorm,index:t.attributes.index})}setSize(e=1,n=1,t="xz"){const i=this;i.width=e,i.height=n,i.orientation=t,i.attributes.position.values&&i.attributes.position.values.length===3*i.vertexCount||(i.attributes.position.values=new Float32Array(3*i.vertexCount));const o=e/-2,r=nLine truncated
let gradient = new Gradient();
gradient.initGradient("#background", "#aa5cc3","#00a4dc", "#003C50", "#3E2247");
</script>
</body>
</html>