File tree Expand file tree Collapse file tree 1 file changed +13
-12
lines changed
client/packages/lowcoder/src/comps/generators Expand file tree Collapse file tree 1 file changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -257,17 +257,7 @@ function UIView(props: {
257257 boxShadowVal = defaultChildren . style ?. children ?. boxShadow ?. valueAndMsg ?. value ;
258258 restrictPaddingOnRotationVal = defaultChildren ?. restrictPaddingOnRotation ?. valueAndMsg ?. value ;
259259 }
260- return (
261- < div
262- ref = { props . innerRef }
263- className = { childrenProps . className as string }
264- data-testid = { childrenProps . dataTestId as string }
265- style = { {
266- width : '100%' ,
267- height : '100%' ,
268- margin : '0px' ,
269- padding :
270- ( rotationVal === null ||
260+ const getPadding = ( ) => ( rotationVal === null ||
271261 rotationVal === undefined ||
272262 restrictPaddingOnRotation ) &&
273263 ( boxShadowVal === null ||
@@ -300,7 +290,18 @@ function UIView(props: {
300290 ? '0px'
301291 : boxShadowVal !== '' && boxShadowVal !== '0px' // Box-shadow applied
302292 ? `calc(min(50%, ${ Math . abs ( parseFloat ( boxShadowVal . replace ( 'px' , '' ) ) ) / 90 } * 100%)) 0px`
303- : '0px' , // Default value if neither rotation nor box-shadow is applied
293+ : '0px' // Default value if neither rotation nor box-shadow is applied
294+ return (
295+ < div
296+ ref = { props . innerRef }
297+ className = { childrenProps . className as string }
298+ data-testid = { childrenProps . dataTestId as string }
299+ style = { {
300+ width : '100%' ,
301+ height : '100%' ,
302+ margin : '0px' ,
303+ padding :getPadding ( )
304+
304305 } }
305306 >
306307 < HidableView hidden = { childrenProps . hidden as boolean } >
You can’t perform that action at this time.
0 commit comments