Skip to content

Commit

Permalink
fix: ignore parent frame that is under section
Browse files Browse the repository at this point in the history
  • Loading branch information
kamleshchandnani committed Jan 31, 2025
1 parent 965028d commit d5a3f68
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions packages/plugin-figma-blade-coverage/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -249,11 +249,6 @@ const calculateCoverage = (node: SceneNode): CoverageMetrics | null => {
isOverridden = true;
}
if (node.overriddenFields.includes('cornerRadius')) {
console.log(
'card corner radius',
traversedNode.mainComponent?.key,
bladeThemeData.components.Card.key,
);
isOverridden = true;
const isCardBorderRadiusValid = [
traversedNode.boundVariables?.topLeftRadius?.id,
Expand Down Expand Up @@ -489,7 +484,8 @@ const calculateCoverage = (node: SceneNode): CoverageMetrics | null => {
) || BLADE_COMPONENT_IDS.includes(traversedNode.mainComponent?.key ?? '')
))) &&
!ignoreInstanceFrameNodeNames.includes(traversedNode.name) &&
getParentNode(traversedNode)?.type !== 'PAGE'
getParentNode(traversedNode)?.type !== 'PAGE' &&
getParentNode(traversedNode)?.type !== 'SECTION'
) {
const hasStrokes =
traversedNode?.boundVariables?.strokes?.length ??
Expand Down

0 comments on commit d5a3f68

Please sign in to comment.