* Add letter spacing to cell text * Set window control height in px * Add temp unused routes * Migrate text title font weights * Bump mantine to v6 alpha * Migrate modals / notifications * Increase header bar to 65px * Adjust play button props * Migrate various components * Migrate various pages and root styles * Adjust default badge padding * Fix sidebar spacing * Fix list header badges * Adjust default theme
32 lines
751 B
TypeScript
32 lines
751 B
TypeScript
import type { BadgeProps as MantineBadgeProps } from '@mantine/core';
|
|
import { createPolymorphicComponent, Badge as MantineBadge } from '@mantine/core';
|
|
import styled from 'styled-components';
|
|
|
|
export type BadgeProps = MantineBadgeProps;
|
|
|
|
const StyledBadge = styled(MantineBadge)<BadgeProps>`
|
|
.mantine-Badge-root {
|
|
color: var(--badge-fg);
|
|
}
|
|
|
|
.mantine-Badge-inner {
|
|
color: var(--badge-fg);
|
|
}
|
|
`;
|
|
|
|
const _Badge = ({ children, ...props }: BadgeProps) => {
|
|
return (
|
|
<StyledBadge
|
|
radius="md"
|
|
size="sm"
|
|
styles={{
|
|
root: { background: 'var(--badge-bg)' },
|
|
}}
|
|
{...props}
|
|
>
|
|
{children}
|
|
</StyledBadge>
|
|
);
|
|
};
|
|
|
|
export const Badge = createPolymorphicComponent<'button', BadgeProps>(_Badge);
|