Skip to content
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: 1 addition & 6 deletions packages/app-builder/src/components/Breadcrumbs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,7 @@ export const BreadCrumbs = ({ back }: { back?: string }) => {

return (
<div className="flex items-center gap-4" key={`${pathname}-${elementIndex}`}>
<Element
key={pathname}
// eslint-disable-next-line react/jsx-no-leaked-render
isLast={isLastElement && isLastLink}
data={data}
/>
<Element key={pathname} isLast={isLastElement && isLastLink} data={data} />
{!(isLastElement && isLastLink) ? <span className="text-s text-grey-80 font-bold">/</span> : null}
</div>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ export const SnoozePanel = ({

useEffect(() => {
setExpanded(true);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, []);
}, [setExpanded]);

if (rulesByPivotQuery.isPending) {
return <div>Loading...</div>;
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/components/Cases/CaseEvents.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,6 @@ export function CaseEvents({
container.addEventListener('scroll', callback);

return () => container.removeEventListener('scroll', callback);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [filteredEvents]);

return (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,6 @@ export const EditCaseSuspicion = ({ id, reports }: EditCaseSuspicionProps) => {
<Button
type="submit"
className="basis-1/2 first-letter:capitalize"
// eslint-disable-next-line react/jsx-no-leaked-render
disabled={isCompleted && reportFile === undefined}
onClick={() => {
field.handleChange('completed');
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/components/Data/CreateLink.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ function CreateLinkContent({
const parentFieldId = selectedParentTableFields[0]?.id;
if (!parentFieldId) return;
form.setFieldValue('parentFieldId', parentFieldId);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [selectedParentTableFields]);

return (
Expand Down
10 changes: 1 addition & 9 deletions packages/app-builder/src/components/Data/DataModelFlow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -264,15 +264,7 @@ function CustomControls() {
return (
<>
<SchemaMenuRoot>
<MenuButton
render={
<button
// eslint-disable-next-line tailwindcss/no-custom-classname
className="react-flow__controls-button"
title="Focus table"
/>
}
>
<MenuButton render={<button className="react-flow__controls-button" title="Focus table" />}>
<Icon icon="center-focus" />
</MenuButton>
<SchemaMenuMenuPopover>
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/components/Data/TableDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ export function TableDetails({ tableModel, dataModel }: TableDetailsProps) {
<span className="flex flex-1">{tableModel.name}</span>

{isCreateDataModelFieldAvailable ? (
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
<div
onClick={(e) => {
//necessary to prevent clicks on modal interactible to trigger the collapsible
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ export function OutcomeAndReviewStatusFilter() {
}),
flat(),
),
// eslint-disable-next-line react-hooks/exhaustive-deps
[],
);

Expand Down
5 changes: 1 addition & 4 deletions packages/app-builder/src/components/HelpCenter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -153,10 +153,7 @@ function HelpCenterContent({ defaultTab, resources, ChatWithUsButton, searchValu
<MenuItem
key={`${resource.category}-${resource.label}`}
className="border-grey-95 bg-grey-100 data-active-item:bg-purple-98 data-active-item:border-purple-65 flex scroll-my-2 flex-col gap-2 rounded-sm border p-2 outline-hidden"
render={
// eslint-disable-next-line jsx-a11y/anchor-has-content
<a href={resource.href} target="_blank" rel="noreferrer" />
}
render={<a href={resource.href} target="_blank" rel="noreferrer" />}
>
{resource.label}
{resource.tags ? (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,6 @@ export const FieldDataset = ({

useEffect(() => {
onChange?.(selectedIds);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [selectedIds]);

return (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ export const FieldDatasetFilters = ({
setFilters((prev) => ({ ...prev, search: searchValue }));
}, 300);
return () => clearTimeout(delayInputTimeoutId);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [searchValue]);

return (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ export function FieldNodeConcat({
if (nodes.length === 0) {
setNodes([NewUndefinedAstNode()]);
}
// eslint-disable-next-line react-hooks/exhaustive-deps -- We only want to trigger this useEffect on mount
}, []);

useEffect(() => {
Expand Down
5 changes: 1 addition & 4 deletions packages/app-builder/src/components/Webhooks/EventTypes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,7 @@ export function SelectEvents({
<SelectWithCombobox.ComboboxItem
key={event}
value={event}
disabled={
// eslint-disable-next-line react/jsx-no-leaked-render
webhookStatus === 'restricted' && !event.includes('decision.')
}
disabled={webhookStatus === 'restricted' && !event.includes('decision.')}
>
<EventType>
<Highlight text={event} query={deferredSearchValue} />
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/hooks/useIntersection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const useIntersection = (
observer.disconnect();
};
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [ref.current, options.threshold, options.root, options.rootMargin]);

return intersectionObserverEntry;
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/routes/_auth+/sign-in-email.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ export default function LoginWithEmail() {
{() => (
<SignInWithEmailAndPassword
signIn={signIn}
// eslint-disable-next-line react/jsx-no-leaked-render
loading={loading && type === 'email'}
additionalContent={isSsoEnabled ? <SignInFirstConnection isSignInHomepage={false} /> : null}
prefilledEmail={prefilledEmail}
Expand Down
12 changes: 2 additions & 10 deletions packages/app-builder/src/routes/_auth+/sign-in.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,16 +106,8 @@ export default function Login() {
</button>
) : (
<>
<SignInWithGoogle
signIn={signIn}
// eslint-disable-next-line react/jsx-no-leaked-render
loading={loading && type === 'google'}
/>
<SignInWithMicrosoft
signIn={signIn}
// eslint-disable-next-line react/jsx-no-leaked-render
loading={loading && type === 'microsoft'}
/>
<SignInWithGoogle signIn={signIn} loading={loading && type === 'google'} />
<SignInWithMicrosoft signIn={signIn} loading={loading && type === 'microsoft'} />
<Link
className={CtaClassName({
variant: 'primary',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ export default function Webhooks() {
<span className="flex-1">{t('settings:webhooks')}</span>
{isCreateWebhookAvailable ? (
// Necessary to prevent click events from propagating to the Collapsible
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
<span onClick={(e) => e.stopPropagation()}>
<CreateWebhook webhookStatus={webhooksStatus}>
<Button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ export default function WebhookDetail() {
<span className="flex-1">{t('settings:webhook_details')}</span>
{isEditWebhookAvailable ? (
// Necessary to prevent click events from propagating to the Collapsible
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
<span onClick={(e) => e.stopPropagation()}>
<UpdateWebhook defaultValue={webhook} webhookStatus={webhookStatus}>
<Button>
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/services/segment/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ export function useSegmentPageTracking() {
if (!tracking) return;
const { name, properties } = tracking;
void window.analytics?.page(name, properties);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [location, thisPage?.id, isHydrated]);

return null;
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/tests/setup/i18next.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,4 @@ export const i18nextTest = (await i18next.use(initReactI18next).init({
debug: false, // set to true to see more logs
resources,
// cf https://github.com/i18next/react-i18next/issues/1699
// eslint-disable-next-line @typescript-eslint/no-explicit-any
})) as TFunction<any>;
1 change: 0 additions & 1 deletion packages/app-builder/src/utils/hooks/use-callback-ref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import * as React from 'react';
* Inspired from @radix-ui/react-use-callback-ref
*/

// eslint-disable-next-line @typescript-eslint/no-explicit-any
export function useCallbackRef<T extends (...args: any[]) => any>(callback: T | undefined): T {
const callbackRef = React.useRef(callback);

Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/utils/hooks/use-compose-refs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ function composeRefs<T>(...refs: PossibleRef<T>[]) {
* Accepts callback refs and RefObject(s)
*/
function useComposedRefs<T>(...refs: PossibleRef<T>[]) {
// eslint-disable-next-line react-hooks/exhaustive-deps
return React.useCallback(composeRefs(...refs), refs);
}

Expand Down
3 changes: 1 addition & 2 deletions packages/app-builder/src/utils/routes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ export type GetPathParams<Path extends string, Parts = NonEmptySplit<Path, '/'>>
? Head extends `:${infer Name}`
? { [K in Name]: string } & GetPathParams<Path, Tail>
: GetPathParams<Path, Tail>
: // eslint-disable-next-line @typescript-eslint/no-empty-object-type
{};
: {};

export function getRoute<Path extends RoutePath>(
path: Path,
Expand Down
1 change: 0 additions & 1 deletion packages/app-builder/src/utils/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// eslint-disable-next-line @typescript-eslint/no-explicit-any
type Contra<T> = T extends any ? (arg: T) => void : never;

type InferContra<T> = [T] extends [(arg: infer I) => void] ? I : never;
Expand Down
1 change: 0 additions & 1 deletion packages/shared/src/use-callback-ref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import * as React from 'react';
* Inspired from @radix-ui/react-use-callback-ref
*/

// eslint-disable-next-line @typescript-eslint/no-explicit-any
export function useCallbackRef<T extends (...args: any[]) => any>(callback: T | undefined): T {
const callbackRef = React.useRef<T | undefined>();

Expand Down
1 change: 0 additions & 1 deletion packages/typescript-utils/src/utility-types.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
export type RequiredKeys<T, K extends keyof T> = Omit<T, K> & Required<Pick<T, K>>;

export type FunctionKeys<T> = {
// eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
[P in keyof T]: T[P] extends Function ? P : never;
}[keyof T];
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ export function BooleanValueFilter({
if (isOpen) {
setLocalChecked(filter.selectedValue === null ? 'indeterminate' : Boolean(filter.selectedValue));
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [isOpen]);

return (
Expand Down
1 change: 0 additions & 1 deletion packages/ui-design-system/src/Modal/Modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ export const ModalContentV2 = forwardRef<HTMLDivElement, ModalContentV2Props>(fu
),
})}
backdrop={
// eslint-disable-next-line jsx-a11y/click-events-have-key-events, jsx-a11y/no-static-element-interactions
<div
onClick={(e) => e.stopPropagation()}
className="bg-grey-00/20 fixed inset-0 flex items-center justify-center p-4 opacity-0 backdrop-blur-xs transition-all data-enter:opacity-100"
Expand Down