The open alternative to Salesforce, designed for AI.
TypeScript crmcrm-systemcustomergood-first-issuegraphqlhacktoberfestjavascriptmarketingmonoreponestjsopen-sourcepostgresqlreactreactjssalestypescriptweb
import { styled } from '@linaria/react';
import { TopBar } from '@/ui/layout/top-bar/components/TopBar';
import { TintedIconTile } from 'twenty-ui/components/data-display';
import { IconBuildingSkyscraper, IconChevronDown } from 'twenty-ui/icon';
import { useTheme, themeCssVariables } from 'twenty-ui/theme';
import { useLingui } from '@lingui/react/macro';
const StyledViewPicker = styled.div`
align-items: center;
color: ${themeCssVariables.font.color.secondary};
cursor: pointer;
display: flex;
font-weight: ${themeCssVariables.font.weight.medium};
gap: ${themeCssVariables.spacing[1]};
height: 100%;
padding: 0 ${themeCssVariables.spacing[2]};
`;
const StyledViewPickerCount = styled.span`
color: ${themeCssVariables.font.color.tertiary};
`;
const StyledRightAction = styled.div`
align-items: center;
color: ${themeCssVariables.font.color.tertiary};
display: flex;
font-weight: ${themeCssVariables.font.weight.regular};
height: 100%;
padding: 0 ${themeCssVariables.spacing[2]};
`;
export const BackgroundMockViewBar = () => {
const { t } = useLingui();
const theme = useTheme();
return (
<TopBar
leftComponent={
<StyledViewPicker>
<TintedIconTile
icon={<IconBuildingSkyscraper size={theme.icon.size.md} />}
color="blue"
/>
<span>{t`All Companies`}</span>
<StyledViewPickerCount>· 599</StyledViewPickerCount>
<IconChevronDown
size={theme.icon.size.sm}
stroke={theme.icon.stroke.sm}
/>
</StyledViewPicker>
}
rightComponent={
<>
<StyledRightAction>{t`Filter`}</StyledRightAction>
<StyledRightAction>{t`Sort`}</StyledRightAction>
<StyledRightAction>{t`Options`}</StyledRightAction>
</>
}
/>
);
};