-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15706 from schlawg/ui-remove-debug-module-preload
UI remove debug module preload
- Loading branch information
Showing
6 changed files
with
26 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { init as initBoard } from 'common/miniBoard'; | ||
|
||
export function initModule() { | ||
$('main.lobby').each(function (this: HTMLElement) { | ||
// fake tv for debugging layout, ui/build with -d flag | ||
if (this.querySelector('.lobby__tv')) return; | ||
|
||
const ds = document.body.dataset; | ||
const tv = $as<HTMLElement>( | ||
` | ||
<div class="lobby__tv"> | ||
<a href="/tv" class="mini-game mini-game-abcd1234 standard is2d"> | ||
<span class="mini-game__player"><span class="mini-game__user"><span class="utitle" title="Candidate Master">CM</span> Tester1<img class="uflair" src="${ds.assetUrl}/assets/______2/flair/img/activity.lichess-horsey.webp"><span class="rating">2649</span></span><span class="mini-game__clock mini-game__clock--black clock--run" data-time="60">0:26</span></span> | ||
<span id="fake-tv" data-state="3R1r1k/pp4p1/2n1Q1bp/1Bp5/PqN4P/2b2NP1/1P4P1/2K4R,black,d1d8"></span> | ||
<span class="mini-game__player"><span class="mini-game__user"><span class="utitle" title="FIDE Master">FM</span> tester2<img class="uflair" src="${ds.assetUrl}/assets/______2/flair/img/activity.lichess-berserk.webp"><span class="rating">2760</span></span><span class="mini-game__clock mini-game__clock--white" data-time="60">0:19</span></span> | ||
</a> | ||
</div>`.trim(), | ||
); | ||
initBoard(tv.querySelector('#fake-tv')!); | ||
this.append(tv); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.