removed @blocknote/core from dependencies (#6580)
Fixes #6564 & #6561 @FelixMalfait Removed @blocknote/core from dependencies https://github.com/user-attachments/assets/ef6acfff-2945-4062-a35c-21dd108a4345 --------- Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
This commit is contained in:
@ -19,7 +19,12 @@ export type FloatingButtonProps = {
|
||||
to?: string;
|
||||
};
|
||||
|
||||
const StyledButton = styled.button<
|
||||
const shouldForwardProp = (prop: string) =>
|
||||
!['applyBlur', 'applyShadow', 'focus', 'position', 'size', 'to'].includes(
|
||||
prop,
|
||||
);
|
||||
|
||||
const StyledButton = styled('button', { shouldForwardProp })<
|
||||
Pick<
|
||||
FloatingButtonProps,
|
||||
| 'size'
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
import { css, useTheme } from '@emotion/react';
|
||||
import styled from '@emotion/styled';
|
||||
import React from 'react';
|
||||
import { IconComponent } from 'twenty-ui';
|
||||
|
||||
export type FloatingIconButtonSize = 'small' | 'medium';
|
||||
@ -22,8 +22,17 @@ export type FloatingIconButtonProps = {
|
||||
onClick?: (event: React.MouseEvent<HTMLButtonElement>) => void;
|
||||
isActive?: boolean;
|
||||
};
|
||||
const shouldForwardProp = (prop: string) =>
|
||||
![
|
||||
'applyBlur',
|
||||
'applyShadow',
|
||||
'isActive',
|
||||
'focus',
|
||||
'position',
|
||||
'size',
|
||||
].includes(prop);
|
||||
|
||||
const StyledButton = styled.button<
|
||||
const StyledButton = styled('button', { shouldForwardProp })<
|
||||
Pick<
|
||||
FloatingIconButtonProps,
|
||||
'size' | 'position' | 'applyShadow' | 'applyBlur' | 'focus' | 'isActive'
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { useEffect, useState } from 'react';
|
||||
import styled from '@emotion/styled';
|
||||
import { motion } from 'framer-motion';
|
||||
import { useEffect, useState } from 'react';
|
||||
|
||||
import { isDefined } from '~/utils/isDefined';
|
||||
|
||||
@ -16,7 +16,7 @@ type ContainerProps = {
|
||||
const StyledContainer = styled.div<ContainerProps>`
|
||||
align-items: center;
|
||||
background-color: ${({ theme, isOn, color }) =>
|
||||
isOn ? color ?? theme.color.blue : theme.background.quaternary};
|
||||
isOn ? (color ?? theme.color.blue) : theme.background.quaternary};
|
||||
border-radius: 10px;
|
||||
cursor: pointer;
|
||||
display: flex;
|
||||
|
||||
Reference in New Issue
Block a user