From 08bfe1436f4559fe89b34de1ec9f755cab8afa4f Mon Sep 17 00:00:00 2001 From: ful1e5 <24286590+ful1e5@users.noreply.github.com> Date: Tue, 1 Sep 2020 16:47:36 +0530 Subject: [PATCH] =?UTF-8?q?=F0=9F=92=BE=20Write=20Schema?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/core/src/schema.ts | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/core/src/schema.ts b/packages/core/src/schema.ts index 848776be..0c90f5e0 100644 --- a/packages/core/src/schema.ts +++ b/packages/core/src/schema.ts @@ -53,12 +53,12 @@ const generateConfigs = ({ .replace(new RegExp(outlineKeyColor, "g"), outline); // Save Schema - const cursorPath = path.resolve( - schemaSvgsPath, - "static", - path.basename(cursor) - ); - writeSchemaData(cursorPath, content); + const cursorPath = path.resolve(schemaSvgsPath, "static"); + writeSchemaData({ + path: cursorPath, + fileName: path.basename(cursor), + content + }); return cursorPath; }); @@ -87,12 +87,12 @@ const generateConfigs = ({ } // Save Schema - const cursorPath = path.resolve( - schemaSvgsPath, - "animated", - path.basename(cursor) - ); - writeSchemaData(cursorPath, content); + const cursorPath = path.resolve(schemaSvgsPath, "animated"); + writeSchemaData({ + path: cursorPath, + fileName: path.basename(cursor), + content + }); return cursorPath; }); @@ -102,7 +102,7 @@ const generateConfigs = ({ fs.mkdirSync(bitmapsDir, { recursive: true }); // push config to Object - configs[schema] = { + configs[schemaName] = { bitmapsDir, animatedCursors: aCursors, staticCursors: sCursors