Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
Madzhini authored Nov 19, 2021
1 parent 8e628c7 commit 185791a
Show file tree
Hide file tree
Showing 19 changed files with 8,889 additions and 0 deletions.
1,174 changes: 1,174 additions & 0 deletions common/chess.js

Large diffs are not rendered by default.

32 changes: 32 additions & 0 deletions common/xhr.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@

// retrieves a file via XMLHTTPRequest, calls fncCallback when done or fncError on error.

function XHR(strURL, fncCallback /*, argumentToPass1, argumentToPass2, etc. */) {
var oHTTP, argsArr = Array.prototype.slice.call(arguments, 2);
if (window.XMLHttpRequest) { oHTTP = new XMLHttpRequest(); }
else if (window.ActiveXObject) { oHTTP = new ActiveXObject("Microsoft.XMLHTTP"); }
if (oHTTP) {
if (fncCallback) {
if (typeof(oHTTP.onload) !== "undefined")
oHTTP.onload = function() {
fncCallback.apply(oHTTP, argsArr);
oHTTP = null;
};
else {
oHTTP.onreadystatechange = function() {
if (oHTTP.readyState === 4) {
fncCallback.apply(oHTTP, argsArr);
oHTTP = null;
}
};
}
}
oHTTP.open("GET", strURL, true);
oHTTP.setRequestHeader("Content-Type", "text/plain");
oHTTP.setRequestHeader("If-Modified-Since", "Sat, 1 Jan 2000 00:00:00 GMT");
oHTTP.send(null);
}
}

function setAttribs() { for (var iAttr = 0; iAttr < arguments.length; iAttr++) { this[arguments[iAttr][0]] = arguments[iAttr][1]; } return(this); }
function setStyles() { for (var iPropr = 0; iPropr < arguments.length; iPropr++) { this.style[arguments[iPropr][0]] = arguments[iPropr][1]; } return(this); }
276 changes: 276 additions & 0 deletions css/chess.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,276 @@
span.intLink, #chessClosePanel {
cursor: pointer;
}

a.chessCtrlBtn:link, span.chessCtrlBtn {
margin: 0 20px;
text-decoration: none;
-moz-user-select: none;
color: #000000;
cursor: default;
height: 21px;
padding: 0 8px;
font: 0.6em; / 0.8em; "Noto Sans", sans-serif;
-moz-border-radius: 10px;
-webkit-border-radius: 10px;
border-radius: 10px;
background: #cdbc9a;

}
a.chessCtrlBtn:active:hover, span.chessCtrlBtn:active:hover {
background-color: #cdbc9a;

}
div.chessFilmBox {
position: absolute;
left: 0;
top: 0;
border: 1px #000000 solid;
background-color: #ffffaa;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
z-index: 10000000;
}

div.gnotify {
padding: 10px;
z-index: 10000001;
}

/** Normal Style Positions **/
div.gnotify { position: fixed; }

div.gnotify.top-left {
left: 0;
top: 0;
}

div.gnotify.top-right {
right: 0;
top: 0;
}

div.gnotify.bottom-left {
left: 0;
bottom: 0;
}

div.gnotify.bottom-right {
right: 0;
bottom: 0;
}

div.gnotify.center {
top: 0;
width: 50%;
left: 25%;
}

div.gnotify-message span.intLink, div.gnotify-message a, div.gnotify-message a:link, div.gnotify-message a:visited, div.gnotify-message a:hover {
font-weight: bold;
text-decoration: inherit;
color: inherit;
}

/** Cross Browser Styling **/
div.center div.gnotify-notification, div.center div.gnotify-closer {
margin-left: auto;
margin-right: auto;
}

div.gnotify div.gnotify-notification, div.gnotify div.gnotify-closer {
background-color: #000000;
color: #ffffff;
opacity: 0.85;
filter: alpha(opacity=85);
width: 300px;
padding: 10px;
margin-top: 5px;
margin-bottom: 5px;
font-size: 0.8em;
text-align: left;
display: none;
border-radius: 5px;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
}

div.gnotify div.gnotify-notification { min-height: 40px; }

div.gnotify div.gnotify-notification div.header {
font-weight: bold;
font-size: 0.8em;
}

div.gnotify div.gnotify-notification div.close {
float: right;
font-weight: bold;
font-size: 0.8em;
cursor: pointer;
}

div.gnotify div.gnotify-closer {
height: 15px;
padding-top: 4px;
padding-bottom: 4px;
cursor: pointer;
font-size: 0.8em;;
font-weight: bold;
text-align: center;
}

#chessboardsBox {
position: relative;
margin-left: auto;
margin-right: auto;
left: 0;
top: 0;
clear: both;
overflow: hidden;
background-color: #cdbc9a;
border: 1px #cdbc9a solid;
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
border-radius: 5px;
/*
-moz-box-shadow:
0 0 20px black,
20px 15px 30px yellow,
-20px 15px 30px lime,
-20px -15px 30px blue,
20px -15px 30px red;
-webkit-box-shadow:
0 0 20px black,
20px 15px 30px yellow,
-20px 15px 30px lime,
-20px -15px 30px blue,
20px -15px 30px red;
box-shadow:
0 0 20px black,
20px 15px 30px yellow,
-20px 15px 30px lime,
-20px -15px 30px blue,
20px -15px 30px red;
*/
}
#chessSizeHandle {
background-color: #cdbc9a;
color: #333333;
font-size: 0.8em;
line-height: 24px;
width: auto;
height: auto;
position: absolute;
right: -12px;
bottom: -12px;
float: right;
margin-top: auto;
cursor: se-resize;
}

#chess3DBox {
/**
* width: [DYNAMIC VALUE];
* height: [DYNAMIC VALUE];
*/
float: left;
}

#chess2DBox {
/**
* width: [DYNAMIC VALUE];
* height: [DYNAMIC VALUE];
*/
float: right;
}
#chessCtrlPanel, #chessCtrlPanel select, #chessCtrlPanel input[type=text] {
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
border-radius: 5px;
}

#chessCtrlPanel {
position: fixed;
bottom: 0;
right: 0;
width: 240px;
height: auto;
overflow: hidden;
background-color: #404d4f;
color: #ffffff;
font-size: 0.8em;
}

#chessCtrlPanel form {
clear: both;
}

#chessClosePanel {
width: auto;
height: auto;
margin: 0 12px 1px auto;
float: right;
}

#chessCtrlPanel p {
margin-top: 6px;
text-align: center;
}

#chessInfo span.intLink {
color: #ffffff;
text-decoration: underline;
}

span.infoKey, span.infoVal {
color: #ffffff;
cursor: pointer;
}

span.infoKey {
font-weight: bold;
}

#chessMoves {
width: 92%;
height: 120px;
padding: 4px;
font-size: 0.8em;
}

#chessMoves, #chessAlgebraic {
border: 1px solid #778284;
background-color: transparent;
color: #ffffff;
}

#chessAlgebraic {
width: 90%;
margin-top: 3px;
font-size: 0.8em;
}

#chessInfo p {
text-align: center;
margin: 6px 4px 6px 4px;
}

#chessCurtain {
display:table;
width: 100%;
height: 100%;
position: fixed;
left: 0;
top: 0;
background-color: #000000;
z-index: 10000002;
}

#chessLoading {
display: table-cell;
vertical-align: middle;
text-align: center;
border: 1px #000000 solid;
color: #ffff00;
}
Loading

0 comments on commit 185791a

Please sign in to comment.