feat(v0.1.1): 周期表五大分区 / 分区与单格改色 / 全屏视线跟随 / 窗口图标 / 跨平台打包
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
const fs = require('fs')
|
||||
const p = 'E:/SodiumPet/WorkPlace/v0.1.1/src/main/index.ts'
|
||||
let c = fs.readFileSync(p, 'utf8')
|
||||
const from =
|
||||
"JSON.stringify({ cells: document.querySelectorAll('.ped-cell').length, zones: document.querySelectorAll('.color-row').length, s: getComputedStyle(document.querySelector('.ped-cell')).backgroundColor })"
|
||||
const to =
|
||||
"JSON.stringify({ cells: document.querySelectorAll('.ped-cell').length, zones: document.querySelectorAll('.color-row').length, colors: [0,4,25,28,56,117].map(i => getComputedStyle(document.querySelectorAll('.ped-cell')[i]).backgroundColor) })"
|
||||
if (!c.includes(from)) {
|
||||
console.log('MISS stats')
|
||||
process.exit(1)
|
||||
}
|
||||
c = c.replace(from, to)
|
||||
fs.writeFileSync(p, c, 'utf8')
|
||||
console.log('stats patched')
|
||||
Reference in New Issue
Block a user