From 305fc512027af9f82518f7800cb2aea908aa3a5b Mon Sep 17 00:00:00 2001 From: Kristiyan Ivanov Date: Fri, 1 Aug 2025 14:57:18 +0300 Subject: [PATCH 1/3] RI-7244 -Edit-and-remove-buttons-are-not-aligned --- .../base/forms/buttons/EmptyButton.tsx | 38 +++++++++++-------- .../DatabasesListWrapper.tsx | 1 + 2 files changed, 24 insertions(+), 15 deletions(-) diff --git a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx index 8ab479dda7..5c79586c5a 100644 --- a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx +++ b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx @@ -2,12 +2,15 @@ import React from 'react' import { TextButton } from '@redis-ui/components' import { ButtonIcon } from 'uiSrc/components/base/forms/buttons/Button' import { IconType } from 'uiSrc/components/base/icons' +import { Row } from '../../layout/flex' +import { justifyValues } from '../../layout/flex/flex.styles' export type ButtonProps = React.ComponentProps & { icon?: IconType iconSide?: 'left' | 'right' loading?: boolean size?: 'small' | 'large' | 'medium' + justify?: (typeof justifyValues)[number] } export const EmptyButton = ({ children, @@ -15,23 +18,28 @@ export const EmptyButton = ({ iconSide = 'left', loading, size = 'small', + justify = 'center', ...rest }: ButtonProps) => ( - - {children} - + + + {children} + + ) diff --git a/redisinsight/ui/src/pages/home/components/database-list-component/DatabasesListWrapper.tsx b/redisinsight/ui/src/pages/home/components/database-list-component/DatabasesListWrapper.tsx index d71c18609e..eb8f7a129e 100644 --- a/redisinsight/ui/src/pages/home/components/database-list-component/DatabasesListWrapper.tsx +++ b/redisinsight/ui/src/pages/home/components/database-list-component/DatabasesListWrapper.tsx @@ -619,6 +619,7 @@ const DatabasesListWrapper = (props: Props) => {
Date: Fri, 1 Aug 2025 16:48:40 +0300 Subject: [PATCH 2/3] Update redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx Co-authored-by: pd-redis --- .../ui/src/components/base/forms/buttons/EmptyButton.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx index 5c79586c5a..5b2f870aae 100644 --- a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx +++ b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx @@ -10,7 +10,7 @@ export type ButtonProps = React.ComponentProps & { iconSide?: 'left' | 'right' loading?: boolean size?: 'small' | 'large' | 'medium' - justify?: (typeof justifyValues)[number] + justify?: FlexProps['justify'] } export const EmptyButton = ({ children, From 38b23aa96319078ad4df4288c2a047cc47324e7a Mon Sep 17 00:00:00 2001 From: Kristiyan Ivanov Date: Fri, 1 Aug 2025 16:48:46 +0300 Subject: [PATCH 3/3] Update redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx Co-authored-by: pd-redis --- .../ui/src/components/base/forms/buttons/EmptyButton.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx index 5b2f870aae..4f04342dd3 100644 --- a/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx +++ b/redisinsight/ui/src/components/base/forms/buttons/EmptyButton.tsx @@ -3,7 +3,7 @@ import { TextButton } from '@redis-ui/components' import { ButtonIcon } from 'uiSrc/components/base/forms/buttons/Button' import { IconType } from 'uiSrc/components/base/icons' import { Row } from '../../layout/flex' -import { justifyValues } from '../../layout/flex/flex.styles' +import { FlexProps } from '../../layout/flex/flex.styles' export type ButtonProps = React.ComponentProps & { icon?: IconType