style: lint
This commit is contained in:
parent
43e9780857
commit
efa676b921
5 changed files with 5 additions and 4 deletions
|
@ -78,7 +78,7 @@ const main = (): void => {
|
||||||
|
|
||||||
// parse mscz data
|
// parse mscz data
|
||||||
const data = new Uint8Array(
|
const data = new Uint8Array(
|
||||||
new Uint8Array(await fetchMscz()) // copy its ArrayBuffer
|
new Uint8Array(await fetchMscz()), // copy its ArrayBuffer
|
||||||
)
|
)
|
||||||
score = await w['WebMscore'].load('mscz', data)
|
score = await w['WebMscore'].load('mscz', data)
|
||||||
await score.generateExcerpts()
|
await score.generateExcerpts()
|
||||||
|
|
|
@ -5,7 +5,7 @@ import scoreinfo from './scoreinfo'
|
||||||
|
|
||||||
let pdfBlob: Blob
|
let pdfBlob: Blob
|
||||||
|
|
||||||
const _downloadPDF = async (imgURLs: string[], imgType: 'svg' | 'png', name?: string): Promise<void> => {
|
const _downloadPDF = async (imgURLs: string[], imgType: 'svg' | 'png', name = ''): Promise<void> => {
|
||||||
if (pdfBlob) {
|
if (pdfBlob) {
|
||||||
return saveAs(pdfBlob, `${name}.pdf`)
|
return saveAs(pdfBlob, `${name}.pdf`)
|
||||||
}
|
}
|
||||||
|
|
|
@ -6,7 +6,7 @@ const SITE_KEY = '6Ldxtt8UAAAAALvcRqWTlVOVIB7MmEWwN-zw_9fM'
|
||||||
|
|
||||||
type token = string;
|
type token = string;
|
||||||
interface GRecaptcha {
|
interface GRecaptcha {
|
||||||
ready (cb: Function): void;
|
ready (cb: () => any): void;
|
||||||
execute (siteKey: string, opts: { action: string }): Promise<token>;
|
execute (siteKey: string, opts: { action: string }): Promise<token>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,7 @@ const scoreinfo = {
|
||||||
|
|
||||||
get playerdata (): ScorePlayerData {
|
get playerdata (): ScorePlayerData {
|
||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-return
|
||||||
return window.UGAPP.store.jmuse_settings.score_player
|
return window.UGAPP.store.jmuse_settings.score_player
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
import { PDFWorkerMessage } from './worker'
|
import { PDFWorkerMessage } from './worker'
|
||||||
import { PDFWorker } from '../dist/cache/worker'
|
import { PDFWorker } from '../dist/cache/worker'
|
||||||
|
|
||||||
const scriptUrlFromFunction = (fn: Function): string => {
|
const scriptUrlFromFunction = (fn: () => any): string => {
|
||||||
const blob = new Blob(['(' + fn.toString() + ')()'], { type: 'application/javascript' })
|
const blob = new Blob(['(' + fn.toString() + ')()'], { type: 'application/javascript' })
|
||||||
return URL.createObjectURL(blob)
|
return URL.createObjectURL(blob)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue