diff --git a/app/client/src/constants/DefaultTheme.tsx b/app/client/src/constants/DefaultTheme.tsx index e6f3350282..d41a429745 100644 --- a/app/client/src/constants/DefaultTheme.tsx +++ b/app/client/src/constants/DefaultTheme.tsx @@ -50,6 +50,13 @@ export const hideScrollbar = css` } `; +export const addEllipsisToTextBlock = css` + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; + display: block; +`; + export const scrollbarDark = css` scrollbar-color: ${(props) => props.theme.colors.paneCard} ${(props) => props.theme.colors.paneBG}; diff --git a/app/client/src/pages/Applications/index.tsx b/app/client/src/pages/Applications/index.tsx index 1ac2e5f56c..97ca42f486 100644 --- a/app/client/src/pages/Applications/index.tsx +++ b/app/client/src/pages/Applications/index.tsx @@ -11,6 +11,7 @@ import { connect, useDispatch, useSelector } from "react-redux"; import { useLocation } from "react-router-dom"; import { AppState } from "reducers"; import { Card, Classes as BlueprintClasses, Dialog } from "@blueprintjs/core"; +import { addEllipsisToTextBlock } from "constants/DefaultTheme"; import { getApplicationList, getApplicationSearchKeyword, @@ -469,10 +470,7 @@ const CreateNewLabel = styled(Text)` const OrgNameElement = styled(Text)` max-width: 500px; - text-overflow: ellipsis; - overflow: hidden; - white-space: nowrap; - display: block; + ${addEllipsisToTextBlock} `; const OrgNameHolder = styled(Text)` diff --git a/app/client/src/pages/organization/settings.tsx b/app/client/src/pages/organization/settings.tsx index d3f3419828..8819c6704e 100644 --- a/app/client/src/pages/organization/settings.tsx +++ b/app/client/src/pages/organization/settings.tsx @@ -18,6 +18,7 @@ import IconComponent from "components/designSystems/appsmith/IconComponent"; import { GeneralSettings } from "./General"; import * as Sentry from "@sentry/react"; import { getAllApplications } from "actions/applicationActions"; +import { addEllipsisToTextBlock } from "constants/DefaultTheme"; const SentryRoute = Sentry.withSentryRouting(Route); const LinkToApplications = styled(Link)` @@ -31,6 +32,7 @@ const LinkToApplications = styled(Link)` svg { cursor: pointer; } + ${addEllipsisToTextBlock} `; const SettingsWrapper = styled.div` width: ${(props) => props.theme.pageContentWidth}px;