Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite3f2144

Browse files
committed
rotation and boxshadow conflict resolved
1 parent0edac5c commite3f2144

File tree

1 file changed

+10
-17
lines changed

1 file changed

+10
-17
lines changed

‎client/packages/lowcoder/src/comps/generators/uiCompBuilder.tsx‎

Lines changed: 10 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -264,24 +264,17 @@ function UIView(props: {
264264
width:'100%',
265265
height:'100%',
266266
margin:'0px',
267-
// padding:'0px',
268267
padding:(
269-
rotationVal===null||rotationVal===undefined||restrictPaddingOnRotation
270-
?'0px'
271-
:(
272-
boxShadowVal===null||boxShadowVal===undefined
273-
?(
274-
rotationVal===''||rotationVal==='0deg'
275-
?'0px'
276-
:`calc(min(50%,${Math.min(50,Math.abs(rotationVal.replace('deg',''))/90)*100}%)) 0px`
277-
)
278-
:(
279-
(rotationVal===''||rotationVal==='0deg')&&(boxShadowVal===''||boxShadowVal==='0px')
280-
?'0px'
281-
:`calc(min(50%,${Math.min(50,Math.abs(rotationVal.replace('deg',''))/90)*100}%)) 0px`
282-
)
283-
)
284-
)
268+
(rotationVal===null||rotationVal===undefined||restrictPaddingOnRotation)&&
269+
(boxShadowVal===null||boxShadowVal===undefined||boxShadowVal==='0px')
270+
) ?'0px'// Both rotation and box-shadow are empty or restricted
271+
:rotationVal!==''&&rotationVal!=='0deg'// Rotation applied
272+
?(boxShadowVal!==''&&boxShadowVal!=='0px')// Both rotation and box-shadow applied
273+
?`calc(min(50%,${Math.abs(rotationVal.replace('deg','')+parseFloat(boxShadowVal.replace('px','')))/90} * 100%)) 0px`
274+
:`calc(min(50%,${Math.abs(rotationVal.replace('deg',''))/90} * 100%)) 0px`// Only rotation applied
275+
:boxShadowVal!==''&&boxShadowVal!=='0px'// Box-shadow applied
276+
?`calc(min(50%,${Math.abs(parseFloat(boxShadowVal.replace('px','')))/90} * 100%)) 0px`
277+
:'0px'// Default value if neither rotation nor box-shadow is applied
285278
}}
286279
>
287280
<HidableViewhidden={childrenProps.hiddenasboolean}>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp