Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

14
LINES

< > BotCompany Repo | #1012831 // html_chessBoard

JavaX fragment (include)

1  
static S html_chessBoard(S position) {
2  
  ret [[<link rel="stylesheet" href="http://tinybrain.de:8080/chessboard-js/css/chessboard-0.3.0.css" />]]
3  
    + loadJQuery()
4  
    + [[<script src="http://tinybrain.de:8080/chessboard-js/js/chessboard-0.3.0.js"></script>]]
5  
    + [[<div id="board1" style="width: 400px"></div>]]
6  
    + hjavascript([[
7  
  $(document).ready(function() {
8  
    var cfg = {
9  
      pieceTheme: 'http://tinybrain.de:8080/chessboard-js/img/chesspieces/wikipedia/{piece}.png',
10  
      position: ]] + jsQuote(position) + [[
11  
    };
12  
    var board = ChessBoard('board1', cfg);
13  
  });]]);
14  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1012831
Snippet name: html_chessBoard
Eternal ID of this version: #1012831/1
Text MD5: 2f9812e451ddba1d2df674cd6d334659
Author: stefan
Category: javax / html
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2017-12-14 00:58:23
Source code size: 602 bytes / 14 lines
Pitched / IR pitched: No / No
Views / Downloads: 407 / 392
Referenced in: [show references]