This commit is contained in:
AliciaRussel 2023-10-26 17:36:46 +08:00
commit 43187f7f0b
4 changed files with 20 additions and 19 deletions

View File

@ -140,11 +140,12 @@ class BasicGenerator extends Generator {
if (fs.lstatSync(fullpath).isDirectory()) {
this.traverseDirBubble(fullpath, dirCallback, fileCallback);
dirCallback(fullpath);
continue;
}
else{
fileCallback(fullpath);
}
}
}
emptyDir(dir) {
if (!fs.existsSync(dir)) {

View File

@ -17,25 +17,25 @@ export function Checkbox({ value }) {
return (
<div
style={{
border: "1px solid black",
borderRadius: "2px",
width: "0.75rem",
height: "0.75rem",
padding: "1px",
backgroundColor: "white",
display: "inline-block",
position: "relative",
cursor: "pointer",
verticalAlign: "sub",
marginBottom: "0.1rem"
border: '1px solid black',
borderRadius: '2px',
width: '0.75rem',
height: '0.75rem',
padding: '1px',
backgroundColor: 'white',
display: 'inline-block',
position: 'relative',
cursor: 'pointer',
verticalAlign: 'sub',
marginBottom: '0.1rem'
}}
>
<div
style={{
width: "100%",
height: "100%",
backgroundColor: value? "black" : "white",
position: "relative"
width: '100%',
height: '100%',
backgroundColor: value? 'black' : 'white',
position: 'relative'
}}
></div>
</div>

View File

@ -17,7 +17,7 @@
* IE浏览器没有Object.is
*/
export function isSame(x: any, y: any) {
if (!(typeof Object.is === 'function')) {
if (typeof Object.is !== 'function') {
if (x === y) {
// +0 != -0
return x !== 0 || 1 / x === 1 / y;