chore: fix eslint in blocksuite (#9232)

This commit is contained in:
Saul-Mirone
2024-12-20 16:48:10 +00:00
parent bfcc53dc1f
commit 3a82da0e5b
269 changed files with 935 additions and 842 deletions

View File

@@ -68,7 +68,7 @@ export class EmbedHtmlFullscreenToolbar extends LitElement {
}
`;
private _popSettings = () => {
private readonly _popSettings = () => {
this._popperVisible = true;
popMenu(popupTargetFromElement(this._fullScreenToolbarContainer), {
options: {

View File

@@ -48,7 +48,7 @@ import { getEmbedLinkedDocIcons } from './utils.js';
export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinkedDocModel> {
static override styles = styles;
private _load = async () => {
private readonly _load = async () => {
const {
loading = true,
isError = false,
@@ -103,7 +103,7 @@ export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinke
}
};
private _selectBlock = () => {
private readonly _selectBlock = () => {
const selectionManager = this.host.selection;
const blockSelection = selectionManager.create('block', {
blockId: this.blockId,
@@ -111,7 +111,7 @@ export class EmbedLinkedDocBlockComponent extends EmbedBlockComponent<EmbedLinke
selectionManager.setGroup('note', [blockSelection]);
};
private _setDocUpdatedAt = () => {
private readonly _setDocUpdatedAt = () => {
const meta = this.doc.collection.meta.getDocMeta(this.model.pageId);
if (meta) {
const date = meta.updatedDate || meta.createDate;

View File

@@ -55,7 +55,7 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
// Caches total bounds, includes all blocks and elements.
private _cachedBounds: Bound | null = null;
private _initEdgelessFitEffect = () => {
private readonly _initEdgelessFitEffect = () => {
const fitToContent = () => {
if (this.isPageMode) return;
@@ -99,7 +99,7 @@ export class EmbedSyncedDocBlockComponent extends EmbedBlockComponent<EmbedSynce
.catch(() => {});
};
private _pageFilter: Query = {
private readonly _pageFilter: Query = {
mode: 'loose',
match: [
{