diff --git a/packages/sketch/src/commands/icons/shared.js b/packages/sketch/src/commands/icons/shared.js index a3bbdf5cefbd..b6f6eb85f854 100644 --- a/packages/sketch/src/commands/icons/shared.js +++ b/packages/sketch/src/commands/icons/shared.js @@ -188,8 +188,6 @@ function createSVGArtboards( }); } - shape.style.borders = []; - for (const layer of transparent) { layer.remove(); } diff --git a/packages/sketch/src/tools/sharedStyles.js b/packages/sketch/src/tools/sharedStyles.js index 2226f1834c3d..f987317c57b6 100644 --- a/packages/sketch/src/tools/sharedStyles.js +++ b/packages/sketch/src/tools/sharedStyles.js @@ -35,12 +35,14 @@ export function syncSharedStyle( // If none exists, we can create one from scratch if (!sharedStyle) { - return SharedStyle.fromStyle({ + const generatedSharedStyle = SharedStyle.fromStyle({ name, style, styleType, document, }); + generatedSharedStyle.style.borders = []; + return generatedSharedStyle; } // Otherwise, we'll go and update values of the sharedStyle with the given