From 681c077ddaf88376bfb1bde2fcb222af48bfda93 Mon Sep 17 00:00:00 2001 From: Nithin David Thomas <1277421+nithindavid@users.noreply.github.com> Date: Mon, 7 Apr 2025 14:06:37 +0530 Subject: [PATCH] fix: Makes container header hidden by default --- .../AppBuilder/WidgetManager/widgets/container.js | 6 ++++-- .../src/Editor/WidgetManager/configs/container.js | 12 +++++++----- .../modules/apps/services/widget-config/container.js | 6 ++++-- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/frontend/src/AppBuilder/WidgetManager/widgets/container.js b/frontend/src/AppBuilder/WidgetManager/widgets/container.js index c4f5ac8d49..424b9a801d 100644 --- a/frontend/src/AppBuilder/WidgetManager/widgets/container.js +++ b/frontend/src/AppBuilder/WidgetManager/widgets/container.js @@ -44,7 +44,7 @@ export const containerConfig = { displayName: 'Show header', validation: { schema: { type: 'boolean' }, - defaultValue: true, + defaultValue: false, }, }, }, @@ -58,6 +58,7 @@ export const containerConfig = { }, displayName: 'ContainerText', properties: ['text'], + slotName: 'header', accessorKey: 'text', styles: ['fontWeight', 'textSize', 'textColor'], defaultValue: { @@ -153,7 +154,7 @@ export const containerConfig = { showOnMobile: { value: '{{false}}' }, }, properties: { - showHeader: { value: `{{true}}` }, + showHeader: { value: `{{false}}` }, loadingState: { value: `{{false}}` }, visibility: { value: '{{true}}' }, disabledState: { value: '{{false}}' }, @@ -163,6 +164,7 @@ export const containerConfig = { backgroundColor: { value: '#fff' }, headerBackgroundColor: { value: '#fff' }, borderRadius: { value: '4' }, + headerHeight: { value: '{{80}}' }, borderColor: { value: '#fff' }, boxShadow: { value: '0px 0px 0px 0px #00000040' }, }, diff --git a/frontend/src/Editor/WidgetManager/configs/container.js b/frontend/src/Editor/WidgetManager/configs/container.js index 37a895f553..424b9a801d 100644 --- a/frontend/src/Editor/WidgetManager/configs/container.js +++ b/frontend/src/Editor/WidgetManager/configs/container.js @@ -44,7 +44,7 @@ export const containerConfig = { displayName: 'Show header', validation: { schema: { type: 'boolean' }, - defaultValue: true, + defaultValue: false, }, }, }, @@ -58,6 +58,7 @@ export const containerConfig = { }, displayName: 'ContainerText', properties: ['text'], + slotName: 'header', accessorKey: 'text', styles: ['fontWeight', 'textSize', 'textColor'], defaultValue: { @@ -71,7 +72,7 @@ export const containerConfig = { events: {}, styles: { backgroundColor: { - type: 'color', + type: 'colorSwatches', displayName: 'Background', validation: { schema: { type: 'string' }, @@ -80,7 +81,7 @@ export const containerConfig = { accordian: 'container', }, headerBackgroundColor: { - type: 'color', + type: 'colorSwatches', displayName: 'Background', validation: { schema: { type: 'string' }, @@ -89,7 +90,7 @@ export const containerConfig = { accordian: 'header', }, borderColor: { - type: 'color', + type: 'colorSwatches', displayName: 'Border color', validation: { schema: { type: 'string' }, @@ -153,7 +154,7 @@ export const containerConfig = { showOnMobile: { value: '{{false}}' }, }, properties: { - showHeader: { value: `{{true}}` }, + showHeader: { value: `{{false}}` }, loadingState: { value: `{{false}}` }, visibility: { value: '{{true}}' }, disabledState: { value: '{{false}}' }, @@ -163,6 +164,7 @@ export const containerConfig = { backgroundColor: { value: '#fff' }, headerBackgroundColor: { value: '#fff' }, borderRadius: { value: '4' }, + headerHeight: { value: '{{80}}' }, borderColor: { value: '#fff' }, boxShadow: { value: '0px 0px 0px 0px #00000040' }, }, diff --git a/server/src/modules/apps/services/widget-config/container.js b/server/src/modules/apps/services/widget-config/container.js index c4f5ac8d49..424b9a801d 100644 --- a/server/src/modules/apps/services/widget-config/container.js +++ b/server/src/modules/apps/services/widget-config/container.js @@ -44,7 +44,7 @@ export const containerConfig = { displayName: 'Show header', validation: { schema: { type: 'boolean' }, - defaultValue: true, + defaultValue: false, }, }, }, @@ -58,6 +58,7 @@ export const containerConfig = { }, displayName: 'ContainerText', properties: ['text'], + slotName: 'header', accessorKey: 'text', styles: ['fontWeight', 'textSize', 'textColor'], defaultValue: { @@ -153,7 +154,7 @@ export const containerConfig = { showOnMobile: { value: '{{false}}' }, }, properties: { - showHeader: { value: `{{true}}` }, + showHeader: { value: `{{false}}` }, loadingState: { value: `{{false}}` }, visibility: { value: '{{true}}' }, disabledState: { value: '{{false}}' }, @@ -163,6 +164,7 @@ export const containerConfig = { backgroundColor: { value: '#fff' }, headerBackgroundColor: { value: '#fff' }, borderRadius: { value: '4' }, + headerHeight: { value: '{{80}}' }, borderColor: { value: '#fff' }, boxShadow: { value: '0px 0px 0px 0px #00000040' }, },