Skip to content

Commit

Permalink
Update add-new-theme.cjs
Browse files Browse the repository at this point in the history
  • Loading branch information
romw314 authored Dec 6, 2023
1 parent 4698ffa commit 1751c93
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions scripts/add-new-theme.cjs
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
const themeRaw = JSON.parse(process.argv[2]);
const _undef = undefined; // can be either null of undefined
console.log('theme raw:', themeRaw);
const themeObj = {
fullName: themeRaw.fullName,
availability: {
availability: ([...themeRaw.availability].length === 12) ? {
monthSeason: [...themeRaw.availability]
},
} : _undef,
bodyStyle: {
backgroundColor: themeRaw.bgcolor,
color: themeRaw.color
},
images: themeRaw.custimg ? undefined : '%-default-@.png',
images: themeRaw.custimg ? _undef : '%-default-@.png',
squares: {
lightColor: [themeRaw.lscolor, themeRaw['lscolor-selected'], themeRaw['lscolor-canmove']],
darkColor: [themeRaw.dscolor, themeRaw['dscolor-selected'], themeRaw['dscolor-canmove']]
Expand Down

1 comment on commit 1751c93

@vercel
Copy link

@vercel vercel bot commented on 1751c93 Dec 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

chess-no-25-docs – ./

chess-no-25-docs-git-master-romw314.vercel.app
chess-no-25-docs-romw314.vercel.app
chess-no-25-docs.vercel.app

Please sign in to comment.