feat: bump eslint & oxlint (#14452)

#### PR Dependency Tree


* **PR #14452** 👈

This tree was auto-generated by
[Charcoal](https://github.com/danerwilliams/charcoal)

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved null-safety, dependency tracking, upload validation, and
error logging for more reliable uploads, clipboard, calendar linking,
telemetry, PDF/theme printing, and preview/zoom behavior.
* Tightened handling of all-day calendar events (missing date now
reported).

* **Deprecations**
  * Removed deprecated RadioButton and RadioButtonGroup; use RadioGroup.

* **Chores**
* Unified and upgraded linting/config, reorganized imports, and
standardized binary handling for more consistent builds and tooling.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
DarkSky
2026-02-16 13:52:08 +08:00
committed by GitHub
parent 792164edd1
commit 728e02cab7
156 changed files with 1230 additions and 1066 deletions
@@ -3,7 +3,7 @@ import { PanTool } from '@blocksuite/affine-gfx-pointer';
import { on } from '@blocksuite/affine-shared/utils';
import type { PointerEventState } from '@blocksuite/std';
import {
BaseTool,
type BaseTool,
MouseButton,
type ToolOptionWithType,
type ToolType,
@@ -21,9 +21,7 @@ const pointerUpHandlers: unknown[] = [];
const pointerUpDisposers: Array<ReturnType<typeof vi.fn>> = [];
vi.mock('@blocksuite/affine-shared/utils', async () => {
const actual = await vi.importActual<
typeof import('@blocksuite/affine-shared/utils')
>('@blocksuite/affine-shared/utils');
const actual = await vi.importActual('@blocksuite/affine-shared/utils');
return {
...actual,
@@ -11,7 +11,7 @@ import type { BlockStdScope } from '@blocksuite/std';
import { css, html } from 'lit';
import { property } from 'lit/decorators.js';
import { getCustomPageEditorBlockSpecs } from '../text-renderer';
import { getCustomPageEditorBlockSpecs } from '../page-editor-block-specs';
import { ArtifactTool } from './artifact-tool';
import type { ToolError } from './type';
@@ -0,0 +1,22 @@
import { ViewExtensionManager } from '@blocksuite/affine/ext-loader';
import { getInternalViewExtensions } from '@blocksuite/affine/extensions/view';
import { BlockViewIdentifier } from '@blocksuite/affine/std';
import type { ExtensionType } from '@blocksuite/affine/store';
import { literal } from 'lit/static-html.js';
const manager = new ViewExtensionManager([...getInternalViewExtensions()]);
const customPageEditorBlockSpecs: ExtensionType[] = [
...manager.get('page'),
{
setup: di => {
di.override(
BlockViewIdentifier('affine:page'),
() => literal`affine-page-root`
);
},
},
];
export const getCustomPageEditorBlockSpecs = () => {
return customPageEditorBlockSpecs;
};
@@ -1,5 +1,4 @@
import { createReactComponentFromLit } from '@affine/component';
import { getViewManager } from '@affine/core/blocksuite/manager/view';
import type { FeatureFlagService } from '@affine/core/modules/feature-flag';
import { PeekViewProvider } from '@blocksuite/affine/components/peek';
import { SignalWatcher, WithDisposable } from '@blocksuite/affine/global/lit';
@@ -13,7 +12,6 @@ import {
import { unsafeCSSVarV2 } from '@blocksuite/affine/shared/theme';
import {
BlockStdScope,
BlockViewIdentifier,
type EditorHost,
ShadowlessElement,
} from '@blocksuite/affine/std';
@@ -32,27 +30,12 @@ import { css, html, nothing, type PropertyValues, unsafeCSS } from 'lit';
import { property, query } from 'lit/decorators.js';
import { classMap } from 'lit/directives/class-map.js';
import { keyed } from 'lit/directives/keyed.js';
import { literal } from 'lit/static-html.js';
import React from 'react';
import { filter } from 'rxjs/operators';
import { markDownToDoc } from '../../utils';
import type { AffineAIPanelState } from '../widgets/ai-panel/type';
export const getCustomPageEditorBlockSpecs: () => ExtensionType[] = () => {
const manager = getViewManager().config.init().value;
return [
...manager.get('page'),
{
setup: di => {
di.override(
BlockViewIdentifier('affine:page'),
() => literal`affine-page-root`
);
},
},
];
};
import { getCustomPageEditorBlockSpecs } from './page-editor-block-specs';
const customHeadingStyles = css`
.custom-heading {
@@ -1,4 +1,7 @@
import { ViewBody, ViewHeader } from '@affine/core/modules/workbench';
import {
ViewBody,
ViewHeader,
} from '@affine/core/modules/workbench/view/view-islands';
import { AttachmentFallback, AttachmentPreviewErrorBoundary } from './error';
import { PDFViewer } from './pdf/pdf-viewer';
@@ -280,6 +280,7 @@ const BlockSuiteEditorImpl = ({
export const BlockSuiteEditor = (props: EditorProps) => {
const [isLoading, setIsLoading] = useState(true);
const [longerLoading, setLongerLoading] = useState(false);
// eslint-disable-next-line react-hooks/purity
const [loadStartTime] = useState(Date.now());
const workspaceService = useService(WorkspaceService);
@@ -1,7 +1,7 @@
import { Popover, uniReactRoot } from '@affine/component';
import { Button } from '@affine/component/ui/button';
import { Menu, MenuItem } from '@affine/component/ui/menu';
import { PeekViewService } from '@affine/core/modules/peek-view';
import { PeekViewService } from '@affine/core/modules/peek-view/services/peek-view';
import {
type Cell,
type CellRenderProps,
@@ -361,8 +361,10 @@ const FileCellComponent: ForwardRefRenderFunction<
CellRenderProps<{}, FileCellRawValueType, FileCellJsonValueType>
> = (props, ref): ReactNode => {
const peekView = useService(PeekViewService);
// eslint-disable-next-line react-hooks/exhaustive-deps
const manager = useMemo(() => new FileCellManager(props, peekView), []);
const manager = useMemo(
() => new FileCellManager(props, peekView), // eslint-disable-line react-hooks/preserve-manual-memoization
[] // oxlint-disable-line react/exhaustive-deps
);
useEffect(() => {
return () => {
@@ -260,8 +260,10 @@ export const MemberPreview = ({
export const MultiMemberSelect: React.FC<MemberManagerOptions> = props => {
const inputRef = useRef<HTMLInputElement>(null);
const memberListRef = useRef<HTMLDivElement>(null);
// eslint-disable-next-line react-hooks/exhaustive-deps
const memberManager = useMemo(() => new MemberManager(props), []);
const memberManager = useMemo(
() => new MemberManager(props), // eslint-disable-line react-hooks/preserve-manual-memoization
[] // oxlint-disable-line react/exhaustive-deps
);
const isLoading = useSignalValue(memberManager.userListService.isLoading$);
const selectedMembers = useSignalValue(memberManager.selectedMembers);
@@ -69,8 +69,10 @@ const MemberCellComponent: ForwardRefRenderFunction<
DataViewCellLifeCycle,
CellRenderProps<{}, MemberCellRawValueType, MemberCellJsonValueType>
> = (props, ref): ReactNode => {
// eslint-disable-next-line react-hooks/exhaustive-deps
const manager = useMemo(() => new MemberManager(props), []);
const manager = useMemo(
() => new MemberManager(props), // eslint-disable-line react-hooks/preserve-manual-memoization
[] // oxlint-disable-line react/exhaustive-deps
);
useImperativeHandle(
ref,