Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bump up @blocksuite/affine version to v0.18.3 #9019

Merged
merged 1 commit into from
Dec 6, 2024
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
2 changes: 1 addition & 1 deletion packages/common/env/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"private": true,
"type": "module",
"devDependencies": {
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"vitest": "2.1.8"
},
"exports": {
Expand Down
2 changes: 1 addition & 1 deletion packages/common/infra/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"@affine/debug": "workspace:*",
"@affine/env": "workspace:*",
"@affine/templates": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@datastructures-js/binary-search-tree": "^5.3.2",
"eventemitter2": "^6.4.9",
"foxact": "^0.2.33",
Expand Down
6 changes: 2 additions & 4 deletions packages/common/infra/src/modules/doc/services/docs.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
import { DebugLogger } from '@affine/debug';
import { Unreachable } from '@affine/env/constant';
import {
type AffineTextAttributes,
type DocMode,
} from '@blocksuite/affine/blocks';
import type { DocMode } from '@blocksuite/affine/blocks';
import type { DeltaInsert } from '@blocksuite/affine/inline';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';

import { Service } from '../../../framework';
import { type DocProps, initDocFromProps } from '../../../initialization';
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/apps/android/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"@affine/component": "workspace:*",
"@affine/core": "workspace:*",
"@affine/i18n": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@blocksuite/icons": "2.1.75",
"@capacitor/android": "^6.1.2",
"@capacitor/core": "^6.1.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/apps/electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"@affine/core": "workspace:*",
"@affine/i18n": "workspace:*",
"@affine/native": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@electron-forge/cli": "^7.3.0",
"@electron-forge/core": "^7.3.0",
"@electron-forge/core-utils": "^7.3.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/apps/ios/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"@affine/component": "workspace:*",
"@affine/core": "workspace:*",
"@affine/i18n": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@blocksuite/icons": "2.1.75",
"@capacitor/app": "^6.0.1",
"@capacitor/browser": "^6.0.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/apps/mobile/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"@affine/component": "workspace:*",
"@affine/core": "workspace:*",
"@affine/i18n": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@blocksuite/icons": "2.1.75",
"@sentry/react": "^8.0.0",
"react": "^18.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/component/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
"zod": "^3.22.4"
},
"devDependencies": {
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@blocksuite/icons": "2.1.75",
"@chromatic-com/storybook": "^3.0.0",
"@storybook/addon-essentials": "^8.2.9",
Expand Down
11 changes: 4 additions & 7 deletions packages/frontend/component/src/lit-react/create-component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,8 +277,6 @@ export const createComponent = <
}
}

const element = elementRef.current;

for (const [k, v] of Object.entries(props)) {
if (reservedReactProperties.has(k)) {
reactProps[k] = v;
Expand Down Expand Up @@ -318,14 +316,13 @@ export const createComponent = <

React.useLayoutEffect(() => {
const container = containerRef.current;
if (!container) {
const element = elementRef.current;
if (!container || !element) {
return;
}
if (element.isConnected) return;
container.append(element);
return () => {
element.remove();
};
}, [element]);
pengx17 marked this conversation as resolved.
Show resolved Hide resolved
}, []);

return React.createElement(tagName, {
...reactProps,
Expand Down
2 changes: 1 addition & 1 deletion packages/frontend/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"@affine/i18n": "workspace:*",
"@affine/templates": "workspace:*",
"@affine/track": "workspace:*",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@blocksuite/icons": "2.1.75",
"@capacitor/app": "^6.0.1",
"@capacitor/browser": "^6.0.3",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
import { globalVars } from '@affine/core/mobile/styles/mobile.css';
import { type KeyboardToolbarConfig } from '@blocksuite/affine/blocks';

export function createKeyboardToolbarConfig(): Partial<KeyboardToolbarConfig> {
return {
// TODO(@L-Sun): check android following the PR
// https://github.com/toeverything/blocksuite/pull/8645
useScreenHeight: BUILD_CONFIG.isIOS,
safeBottomPadding: BUILD_CONFIG.isIOS ? globalVars.appTabHeight : '0px',
};
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { AffineTextAttributes } from '@blocksuite/affine/blocks';
import type { DeltaInsert } from '@blocksuite/affine/inline';
import type { DocCollection } from '@blocksuite/affine/store';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import { useCallback } from 'react';

export function useReferenceLinkHelper(docCollection: DocCollection) {
Expand Down
6 changes: 6 additions & 0 deletions packages/frontend/core/src/mobile/styles/mobile.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ globalStyle('body', {
globalStyle('body:has(#app-tabs)', {
paddingBottom: `calc(${globalVars.appTabHeight} + env(safe-area-inset-bottom))`,
});
globalStyle('body:has(#app-tabs) affine-keyboard-toolbar[data-shrink="true"]', {
paddingBottom: `calc(${globalVars.appTabHeight} + env(safe-area-inset-bottom))`,
});
globalStyle('body:has(#app-tabs) affine-keyboard-tool-panel', {
paddingBottom: `calc(${globalVars.appTabHeight} + env(safe-area-inset-bottom) + 8px)`,
});
globalStyle('html', {
height: '100dvh',
overflowY: 'auto',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import type {
AffineTextAttributes,
AttachmentBlockModel,
BookmarkBlockModel,
EmbedBlockModel,
Expand All @@ -14,6 +13,7 @@ import {
type JobMiddleware,
type YBlock,
} from '@blocksuite/affine/store';
import type { AffineTextAttributes } from '@blocksuite/affine-shared/types';
import type { DeltaInsert } from '@blocksuite/inline';
import { Document, getAFFiNEWorkspaceSchema } from '@toeverything/infra';
import { toHexString } from 'lib0/buffer.js';
Expand Down
2 changes: 1 addition & 1 deletion tools/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"@affine/env": "workspace:*",
"@affine/templates": "workspace:*",
"@aws-sdk/client-s3": "^3.620.0",
"@blocksuite/affine": "0.18.1",
"@blocksuite/affine": "0.18.3",
"@clack/core": "^0.3.4",
"@clack/prompts": "^0.8.0",
"@magic-works/i18n-codegen": "^0.6.0",
Expand Down
Loading
Loading