MCPcopy Index your code
hub / github.com/MALSync/MALSync / constructor

Method constructor

src/simkl/simklClass.ts:19–45  ·  view source on GitHub ↗
(public url: string)

Source from the content-addressed store, hash-verified

17 protected logger;
18
19 constructor(public url: string) {
20 this.logger = con.m('SimklClass', '#9b7400');
21
22 utils.urlChangeDetect(() => {
23 clearInterval(this.interval);
24 this.interval = utils.waitUntilTrue(
25 function () {
26 return (
27 (!$('#global_div').length || parseInt($('#global_div').css('opacity')) === 1) &&
28 (!$('#tvMainTable').length || parseInt($('#tvMainTable').css('opacity')) === 1)
29 );
30 },
31 () => {
32 this.url = window.location.href;
33 this.init();
34 },
35 1000,
36 );
37 });
38
39 api.storage.addStyle(
40 require('!to-string-loader!css-loader!less-loader!./style.less').toString(),
41 );
42 $(document).ready(() => {
43 this.init();
44 });
45 }
46
47 async init() {
48 await waitForPageToBeVisible();

Callers

nothing calls this directly

Calls 2

initMethod · 0.95
addStyleMethod · 0.80

Tested by

no test coverage detected