Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

✨ feat: update Novita AI logos and colors (#62) #63

Merged
merged 2 commits into from
Jan 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions src/Novita/components/Avatar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { memo } from 'react';

import IconAvatar, { type IconAvatarProps } from '@/features/IconAvatar';

import { COLOR_GRADIENT, TITLE } from '../style';
import { COLOR_PRIMARY, TITLE } from '../style';
import Mono from './Mono';

export type AvatarProps = Omit<IconAvatarProps, 'Icon'>;
Expand All @@ -14,9 +14,8 @@ const Avatar = memo<AvatarProps>(({ background, ...rest }) => {
<IconAvatar
Icon={Mono}
aria-label={TITLE}
background={background || COLOR_GRADIENT}
color={'#fff'}
iconMultiple={0.6}
background={COLOR_PRIMARY || background}
color={'#000'}
{...rest}
/>
);
Expand Down
12 changes: 2 additions & 10 deletions src/Novita/components/Color.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,11 @@

import { forwardRef } from 'react';

import { useFillId } from '@/hooks/useFillId';
import type { IconType } from '@/types';

import { TITLE } from '../style';

const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
const { fill, id } = useFillId(TITLE);
return (
<svg
height={size}
Expand All @@ -22,16 +20,10 @@ const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
<title>{TITLE}</title>
<path
clipRule="evenodd"
d="M2.371 0C1.614 0 1 .614 1 1.371v18.522c0 .758.614 1.372 1.371 1.372h2.397l7.21 2.691a.686.686 0 00.926-.642V7.756c0-.572-.355-1.084-.891-1.284L4.768 3.765h13.72v17.5h2.398c.757 0 1.371-.614 1.371-1.372V1.371C22.257.614 21.643 0 20.886 0H2.37zm8.612 16.183c.31.15.562-.037.562-.42 0-.385-.251-.818-.562-.968-.31-.152-.561.037-.561.42s.251.816.561.968z"
fill={fill}
d="M9.167 4.17v5.665L0 19.003h9.167v-5.666l5.666 5.666H24L9.167 4.17z"
fill="#23D57C"
fillRule="evenodd"
/>
<defs>
<linearGradient gradientUnits="userSpaceOnUse" id={id} x1="0" x2="24.5" y1="0" y2="24">
<stop stopColor="#2622FF" />
<stop offset="1" stopColor="#A717FF" />
</linearGradient>
</defs>
</svg>
);
});
Expand Down
2 changes: 1 addition & 1 deletion src/Novita/components/Mono.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
<title>{TITLE}</title>
<path
clipRule="evenodd"
d="M2.371 0C1.614 0 1 .614 1 1.371v18.522c0 .758.614 1.372 1.371 1.372h2.397l7.21 2.691a.686.686 0 00.926-.642V7.756c0-.572-.355-1.084-.891-1.284L4.768 3.765h13.72v17.5h2.398c.757 0 1.371-.614 1.371-1.372V1.371C22.257.614 21.643 0 20.886 0H2.37zm8.612 16.183c.31.15.562-.037.562-.42 0-.385-.251-.818-.562-.968-.31-.152-.561.037-.561.42s.251.816.561.968z"
d="M9.167 4.17v5.665L0 19.003h9.167v-5.666l5.666 5.666H24L9.167 4.17z"
/>
</svg>
);
Expand Down
16 changes: 2 additions & 14 deletions src/Novita/components/Text.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,27 +14,15 @@ const Icon: IconType = forwardRef(({ size = '1em', style, ...rest }, ref) => {
height={size}
ref={ref}
style={{ flex: 'none', lineHeight: 1, ...style }}
viewBox="0 0 126 24"
viewBox="0 0 92 24"
xmlns="http://www.w3.org/2000/svg"
{...rest}
>
<title>{TITLE}</title>
<path d="M59.34 2.062a2.05 2.05 0 01-2.072 2.061c-1.18 0-2.1-.903-2.1-2.061S56.088 0 57.268 0a2.05 2.05 0 012.071 2.062zM58.878 21.746h-3.28V6.185h3.28v15.56zM13.249 21.746h3.25v-9.179c0-4.349-2.79-6.636-6.501-6.636-1.899 0-3.654.762-4.718 2.033v-1.78H2v15.562h3.28v-8.699c0-2.852 1.582-4.32 3.999-4.32 2.387 0 3.97 1.468 3.97 4.32v8.699z" />
<path
clipRule="evenodd"
d="M27.693 5.93c4.516 0 8.084 3.136 8.084 8.021 0 4.886-3.683 8.049-8.228 8.049-4.517 0-7.94-3.163-7.94-8.049 0-4.885 3.567-8.02 8.084-8.02zm-.057 2.797c-2.474 0-4.689 1.694-4.689 5.224 0 3.53 2.129 5.253 4.603 5.253 2.445 0 4.862-1.723 4.862-5.253 0-3.53-2.33-5.224-4.776-5.224z"
d="M68.236 18.3h5.11v3.228H69.29c-2.838 0-4.623-1.56-4.623-4.466V8.476h-2.892V5.22h2.892l.838-4.279h2.704v4.279h5.136v3.256h-5.11v9.822zM7.84 0l7.434 16.576h.217V0h3.865v21.528h-5.84L6.083 4.952h-.216v16.576H2V0h5.84zm21.438 21.851c-4.731 0-7.759-3.31-7.759-8.45 0-5.14 2.974-8.503 7.76-8.503 4.784 0 7.704 3.229 7.704 8.504 0 5.274-2.974 8.45-7.705 8.45zm0-3.229c2.11 0 3.866-.727 3.92-2.799V10.98c0-2.126-1.784-2.853-3.92-2.853s-3.974.727-3.974 2.853v4.843c.054 2.1 1.865 2.8 3.974 2.8zM41.12 5.194l4.217 12.916h.216L49.77 5.194h3.893L47.85 21.5h-4.813L37.252 5.194H41.12zm14.545.027h3.569v16.307h-3.57V5.221zM55.447 0h4.001v3.068h-4V0zm26.657 21.878c-4.353 0-7.137-3.31-7.137-8.476 0-5.167 2.73-8.477 7.137-8.477 2.055 0 3.731.807 4.732 2.314h.216l.703-2.018h2.703v16.307h-2.703l-.703-1.965h-.216c-1.082 1.426-2.893 2.314-4.732 2.314v.001zm.73-3.256c2.136 0 4-.673 4.054-2.799V10.98c0-2.18-1.947-2.8-4.135-2.8-2.19 0-4.001.674-4.001 2.8v4.843c.054 2.153 1.92 2.8 4.082 2.8z"
/>
<path d="M43.169 21.746L37.156 6.185h3.51l4.488 12.68 4.488-12.68h3.48l-6.04 15.56h-3.913zM68.286 21.746c-2.82 0-4.575-1.158-4.575-4.321V8.81h-1.87V6.185h1.87v-3.87h3.309v3.87h3.855V8.81H67.02v8.614c0 1.158.46 1.638 1.84 1.638h2.015v2.683h-2.589z" />
<path
clipRule="evenodd"
d="M80.224 22c-4.114 0-7.423-3.304-7.423-8.105s3.309-7.964 7.48-7.964c2.676 0 4.517 1.242 5.495 2.513v-2.26h3.309v15.562h-3.309V19.43C84.77 20.757 82.87 22 80.224 22zm.747-2.796c2.474 0 4.804-1.892 4.804-5.253 0-3.332-2.33-5.224-4.804-5.224-2.445 0-4.804 1.807-4.804 5.168 0 3.36 2.36 5.31 4.804 5.31z"
/>
<path d="M94.725 17.82a2.05 2.05 0 012.071 2.062 2.05 2.05 0 01-2.071 2.062c-1.18 0-2.1-.904-2.1-2.062s.92-2.062 2.1-2.062z" />
<path
clipRule="evenodd"
d="M106.662 22c-4.114 0-7.422-3.304-7.422-8.105s3.308-7.964 7.479-7.964c2.676 0 4.517 1.242 5.495 2.513v-2.26h3.309v15.562h-3.309V19.43c-1.007 1.327-2.905 2.57-5.552 2.57zm.747-2.796c2.474 0 4.804-1.892 4.804-5.253 0-3.332-2.33-5.224-4.804-5.224-2.445 0-4.804 1.807-4.804 5.168 0 3.36 2.359 5.31 4.804 5.31z"
/>
<path d="M121.508 4.123a2.05 2.05 0 002.071-2.061A2.05 2.05 0 00121.508 0c-1.18 0-2.1.904-2.1 2.062s.92 2.061 2.1 2.061zM119.839 21.746h3.279V6.185h-3.279v15.56z" />
</svg>
);
});
Expand Down
1 change: 0 additions & 1 deletion src/Novita/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ import { Flexbox } from 'react-layout-kit';
export default () => (
<Flexbox gap={16} align={'flex-start'}>
<Novita.Combine size={64} />
<Novita.Combine size={64} type={'color'} />
</Flexbox>
);
```
Expand Down
4 changes: 1 addition & 3 deletions src/Novita/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,13 @@ import Color from './components/Color';
import Combine from './components/Combine';
import Mono from './components/Mono';
import Text from './components/Text';
import { COLOR_GRADIENT, COLOR_PRIMARY, TITLE } from './style';
import { COLOR_PRIMARY, TITLE } from './style';

export type CompoundedIcon = typeof Mono & {
Avatar: typeof Avatar;
Color: typeof Color;
Combine: typeof Combine;
Text: typeof Text;
colorGradient: string;
colorPrimary: string;
title: string;
};
Expand All @@ -23,7 +22,6 @@ Icons.Text = Text;
Icons.Combine = Combine;
Icons.Avatar = Avatar;
Icons.colorPrimary = COLOR_PRIMARY;
Icons.colorGradient = COLOR_GRADIENT;
Icons.title = TITLE;

export default Icons;
5 changes: 2 additions & 3 deletions src/Novita/style.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
export const TITLE = 'novita.ai';
export const TITLE = 'Novita AI';
export const TEXT_MULTIPLE = 0.7;
export const SPACE_MULTIPLE = 0.25;
export const COLOR_PRIMARY = '#6847f5';
export const COLOR_GRADIENT = 'linear-gradient(-45deg, #A717FF, #2622FF)';
export const COLOR_PRIMARY = '#23D57C';
5 changes: 2 additions & 3 deletions src/toc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1487,8 +1487,7 @@ const toc: IconToc[] = [
title: 'Nova',
},
{
color: '#6847f5',
colorGradient: 'linear-gradient(-45deg, #A717FF, #2622FF)',
color: '#23D57C',
desc: 'https://novita.ai/',
docsUrl: 'novita',
fullTitle: 'Novita',
Expand All @@ -1504,7 +1503,7 @@ const toc: IconToc[] = [
hasTextCn: false,
hasTextColor: false,
},
title: 'novita.ai',
title: 'Novita AI',
},
{
color: '#74B71B',
Expand Down
Loading