diff --git a/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/featureflags/FeatureFlags.java b/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/featureflags/FeatureFlags.java index 49af7265ec..f813562945 100644 --- a/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/featureflags/FeatureFlags.java +++ b/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/featureflags/FeatureFlags.java @@ -14,4 +14,5 @@ public class FeatureFlags { private boolean showSearchFiltersV2 = false; private boolean showBrowseV2 = false; private PreProcessHooks preProcessHooks; + private boolean showAcrylInfo = false; } diff --git a/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/resolvers/config/AppConfigResolver.java b/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/resolvers/config/AppConfigResolver.java index 48f0617c99..026ac719f0 100644 --- a/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/resolvers/config/AppConfigResolver.java +++ b/datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/resolvers/config/AppConfigResolver.java @@ -151,6 +151,7 @@ public class AppConfigResolver implements DataFetcher + Schedule a Demo + + ); +} diff --git a/datahub-web-react/src/app/home/AcrylDemoBanner.tsx b/datahub-web-react/src/app/home/AcrylDemoBanner.tsx new file mode 100644 index 0000000000..d2e79d4c21 --- /dev/null +++ b/datahub-web-react/src/app/home/AcrylDemoBanner.tsx @@ -0,0 +1,56 @@ +import Link from 'antd/lib/typography/Link'; +import React from 'react'; +import styled from 'styled-components'; +import AcrylLogo from '../../images/acryl-light-mark.svg'; + +const BannerWrapper = styled.div` + padding: 12px; + display: flex; + align-items: center; + justify-content: center; + color: #262626; + background-color: #e6f4ff; + width: 100%; + margin-bottom: 24px; +`; + +const Logo = styled.img` + margin-right: 12px; + height: 40px; + width: 40px; +`; + +const TextWrapper = styled.div` + font-size: 14px; +`; + +const Title = styled.div` + font-weight: 700; +`; + +const StyledLink = styled(Link)` + color: #1890ff; + font-weight: 700; +`; + +export default function AcrylDemoBanner() { + return ( + + + + Schedule a Demo of Managed Datahub + + DataHub is already the industries #1 Open Source Data Catalog.{' '} + + Schedule a demo + {' '} + of Acryl DataHub to see the advanced features that take it to the next level! + + + + ); +} diff --git a/datahub-web-react/src/app/home/HomePageHeader.tsx b/datahub-web-react/src/app/home/HomePageHeader.tsx index 1d61eff66e..02c847bb04 100644 --- a/datahub-web-react/src/app/home/HomePageHeader.tsx +++ b/datahub-web-react/src/app/home/HomePageHeader.tsx @@ -16,12 +16,14 @@ import { EntityType, FacetFilterInput } from '../../types.generated'; import analytics, { EventType } from '../analytics'; import { HeaderLinks } from '../shared/admin/HeaderLinks'; import { ANTD_GRAY } from '../entity/shared/constants'; -import { useAppConfig } from '../useAppConfig'; +import { useAppConfig, useIsShowAcrylInfoEnabled } from '../useAppConfig'; import { DEFAULT_APP_CONFIG } from '../../appConfigContext'; import { HOME_PAGE_SEARCH_BAR_ID } from '../onboarding/config/HomePageOnboardingConfig'; import { useQuickFiltersContext } from '../../providers/QuickFiltersContext'; import { getAutoCompleteInputFromQuickFilter } from '../search/utils/filterUtils'; import { useUserContext } from '../context/useUserContext'; +import AcrylDemoBanner from './AcrylDemoBanner'; +import DemoButton from '../entity/shared/components/styled/DemoButton'; const Background = styled.div` width: 100%; @@ -147,6 +149,7 @@ export const HomePageHeader = () => { const appConfig = useAppConfig(); const [newSuggestionData, setNewSuggestionData] = useState(); const { selectedQuickFilter } = useQuickFiltersContext(); + const showAcrylInfo = useIsShowAcrylInfoEnabled(); const { user } = userContext; const viewUrn = userContext.localState?.selectedViewUrn; @@ -243,9 +246,11 @@ export const HomePageHeader = () => { pictureLink={user?.editableProperties?.pictureLink || ''} name={(user && entityRegistry.getDisplayName(EntityType.CorpUser, user)) || undefined} /> + {showAcrylInfo && } + {showAcrylInfo && } { const [isSearchBarFocused, setIsSearchBarFocused] = useState(false); const themeConfig = useTheme(); + const showAcrylInfo = useIsShowAcrylInfoEnabled(); const appConfig = useAppConfig(); const viewsEnabled = appConfig.config?.viewsConfig?.enabled; @@ -118,6 +120,7 @@ export const SearchHeader = ({ )} + {showAcrylInfo && } ); diff --git a/datahub-web-react/src/app/useAppConfig.ts b/datahub-web-react/src/app/useAppConfig.ts index d2b897e2de..cdc8f92210 100644 --- a/datahub-web-react/src/app/useAppConfig.ts +++ b/datahub-web-react/src/app/useAppConfig.ts @@ -7,3 +7,8 @@ import { AppConfigContext } from '../appConfigContext'; export function useAppConfig() { return useContext(AppConfigContext); } + +export function useIsShowAcrylInfoEnabled() { + const appConfig = useAppConfig(); + return appConfig.config.featureFlags.showAcrylInfo; +} diff --git a/datahub-web-react/src/appConfigContext.tsx b/datahub-web-react/src/appConfigContext.tsx index d680dfd07a..6866278838 100644 --- a/datahub-web-react/src/appConfigContext.tsx +++ b/datahub-web-react/src/appConfigContext.tsx @@ -41,6 +41,7 @@ export const DEFAULT_APP_CONFIG = { readOnlyModeEnabled: false, showSearchFiltersV2: true, showBrowseV2: true, + showAcrylInfo: false, }, }; diff --git a/datahub-web-react/src/graphql/app.graphql b/datahub-web-react/src/graphql/app.graphql index f39793891b..f62822047f 100644 --- a/datahub-web-react/src/graphql/app.graphql +++ b/datahub-web-react/src/graphql/app.graphql @@ -54,6 +54,7 @@ query appConfig { readOnlyModeEnabled showSearchFiltersV2 showBrowseV2 + showAcrylInfo } } } diff --git a/datahub-web-react/src/images/acryl-light-mark.svg b/datahub-web-react/src/images/acryl-light-mark.svg new file mode 100644 index 0000000000..7da565b499 --- /dev/null +++ b/datahub-web-react/src/images/acryl-light-mark.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/metadata-service/factories/src/main/resources/application.yml b/metadata-service/factories/src/main/resources/application.yml index ad5f27dd54..d028c73c14 100644 --- a/metadata-service/factories/src/main/resources/application.yml +++ b/metadata-service/factories/src/main/resources/application.yml @@ -289,6 +289,7 @@ featureFlags: showBrowseV2: ${SHOW_BROWSE_V2:true} # Enables showing the browse v2 sidebar experience. preProcessHooks: uiEnabled: ${PRE_PROCESS_HOOKS_UI_ENABLED:true} # Circumvents Kafka for processing index updates for UI changes sourced from GraphQL to avoid processing delays + showAcrylInfo: ${SHOW_ACRYL_INFO:false} # Show different CTAs within DataHub around moving to Managed DataHub. Set to true for the demo site. entityChangeEvents: enabled: ${ENABLE_ENTITY_CHANGE_EVENTS_HOOK:true}