updated elements wrapper styles
This commit is contained in:
parent
f839e6c562
commit
d3644125db
@ -2846,13 +2846,20 @@ const ConstructorPage = ({ mode = 'constructor' }: ConstructorPageProps) => {
|
||||
Boolean(element.iconUrl) &&
|
||||
(element.type === 'navigation_next' ||
|
||||
element.type === 'navigation_prev');
|
||||
const hasTransparentBackground =
|
||||
element.type === 'description' &&
|
||||
!element.iconUrl &&
|
||||
(!element.descriptionBackgroundColor ||
|
||||
element.descriptionBackgroundColor === 'transparent');
|
||||
|
||||
return (
|
||||
<button
|
||||
key={element.id}
|
||||
type='button'
|
||||
data-constructor-element-id={element.id}
|
||||
className={`absolute border rounded text-xs font-semibold shadow text-left ${
|
||||
className={`absolute rounded text-xs font-semibold text-left ${
|
||||
hasTransparentBackground ? '' : 'border shadow'
|
||||
} ${
|
||||
hasIconDrivenSize ? 'overflow-hidden p-0 leading-none' : 'px-3 py-2'
|
||||
} ${
|
||||
isNavigationIconElement ? 'flex items-center justify-center' : ''
|
||||
@ -2860,8 +2867,10 @@ const ConstructorPage = ({ mode = 'constructor' }: ConstructorPageProps) => {
|
||||
isConstructorEditMode ? 'cursor-move' : 'cursor-pointer'
|
||||
} ${
|
||||
selectedElementId === element.id
|
||||
? 'border-blue-500 bg-blue-50'
|
||||
: 'border-blue-200 bg-white/95'
|
||||
? 'border-blue-500 bg-blue-50 border shadow'
|
||||
: hasTransparentBackground
|
||||
? 'bg-transparent'
|
||||
: 'border-blue-200 bg-white/95'
|
||||
}`}
|
||||
style={{
|
||||
...buildCanvasElementStyle(element),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user