File tree 1 file changed +9
-1
lines changed
editor/src/components/canvas/canvas-strategies/strategies
1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -164,9 +164,17 @@ export const setGridGapStrategy: CanvasStrategyFactory = (
164
164
return emptyStrategyApplicationResult
165
165
}
166
166
167
+ const shouldSetGapByAxis = gridGap . row . value != null || gridGap . column . value != null
168
+
167
169
const axis = interactionSession . activeControl . axis
168
170
const shouldTearOffGapByAxis = axis === 'row' ? shouldTearOffGap . y : shouldTearOffGap . x
169
- const axisStyleProp = axis === 'row' ? StyleRowGapProp : StyleColumnGapProp
171
+
172
+ const axisStyleProp = shouldSetGapByAxis
173
+ ? axis === 'row'
174
+ ? StyleRowGapProp
175
+ : StyleColumnGapProp
176
+ : StyleGapProp
177
+
170
178
const gridGapMeasurement =
171
179
axis === 'row' ? updatedGridGapMeasurement . row : updatedGridGapMeasurement . column
172
180
You can’t perform that action at this time.
0 commit comments