EYHN
5dd7382693
refactor(core): workbench ( #7355 )
...
Merge the right sidebar logic into the workbench. this can simplify our logic.
Previously we had 3 modules
* workbench
* right-sidebar (Control sidebar open&close)
* multi-tab-sidebar (Control tabs)
Now everything is managed in Workbench.
# Behavioral changes
The sidebar button is always visible and can be opened at any time.
If there is no content to display, will be `No Selection`

Elements in the sidebar can now be defined as`unmountOnInactive=false`. Inactive sidebars are marked with `display: none` but not unmount, so the `ChatPanel` can always remain in the DOM and user input will be retained even if the sidebar is closed.
2024-07-12 04:11:05 +00:00
donteatfriedrice
a0ce75c902
fix: ai button should not display in readonly mode ( #7415 )
...
[BS-737](https://linear.app/affine-design/issue/BS-737/shared-page-也可以用-ai )
2024-07-03 07:34:07 +00:00
Flrande
4d484ea814
feat: bump blocksuite ( #7372 )
2024-07-01 19:21:14 +08:00
EYHN
3bbb657a78
feat(core): replace ai template ( #7396 )
2024-07-01 10:24:54 +00:00
golok727
fbf676002f
fix: code block toolbar z-index issue in right sidebar ( #7376 )
...
Closes: [BS-549](https://linear.app/affine-design/issue/BS-549/code-block-%E5%9C%A8%E5%8F%B3%E4%BE%A7%E8%BE%B9%E6%A0%8F%E6%9C%89-z-index-%E9%97%AE%E9%A2%98%E8%AF%AD%E8%A8%80%E7%9A%84%E4%BF%A1%E6%81%AF%E5%87%BA%E7%8E%B0%E5%9C%A8%E4%BA%86-tab-%E4%B8%8A%E9%9D%A2 ),[BS-600](https://linear.app/affine-design/issue/BS-600/the-code-toolbar-remains-visible-when-it-overflows-in-the-ai-panel )
2024-06-28 07:48:50 +00:00
regischen
f4f84d2793
fix: click continue with ai not work ( #7374 )
2024-06-28 14:43:45 +08:00
forehalo
d51fd8b54b
fix(core): correct image action icon ( #7370 )
...
fix AF-1002

2024-06-28 05:24:06 +00:00
donteatfriedrice
742c10ac94
feat: make width and height of generated image same with input image ( #7356 )
...
[BS-641](https://linear.app/affine-design/issue/BS-641/通过image-action生成的图像尺寸应与原图保持一致 )
2024-06-27 08:02:32 +00:00
Fangdun Tsai
a5662e3de2
fix(core): optimize request chat cards fn ( #7331 )
2024-06-26 23:50:45 +08:00
EYHN
dcf766f0ee
feat(core): impl ai onboarding templates ( #7341 )
2024-06-26 13:49:23 +00:00
donteatfriedrice
6f9a4bb01a
feat: optimize edgeless ai action insert handler ( #7342 )
...
[BS-653](https://linear.app/affine-design/issue/BS-653/在-edgeless-text-上使用-ai-功能时,应该在-edgeless-text-内换行插入,而不是新建一个-note )
2024-06-26 10:17:19 +00:00
L-Sun
16096978d8
fix(core): add synced doc content to edgeless ai context ( #7327 )
...
Closes: [BS-633](https://linear.app/affine-design/issue/BS-633/synced-block-%E7%99%BD%E6%9D%BF%E6%94%AF%E6%8C%81%EF%BC%9A%E4%BD%9C%E4%B8%BA%E4%B8%8A%E4%B8%8B%E6%96%87%E6%8F%90%E4%BE%9B%E7%BB%99-ai#comment-f336c6d5 )
Related PR: https://github.com/toeverything/blocksuite/pull/7417
Read content from synced doc model as AI context in edgeless model.
2024-06-26 04:05:19 +00:00
fundon
2278cfc9ce
fix(core): direct replacement of old card with new card in ai chat input ( #7324 )
...
Closes: [BS-643](https://linear.app/affine-design/issue/BS-643/continue-with-ai-:-在存在候选内容的情况下,点击-continue-with-ai-应该将选区内容直接替换 )
https://github.com/toeverything/AFFiNE/assets/27926/ff6e2c31-9d2e-462b-aa7e-6ef1eba50ef5
2024-06-25 15:56:47 +00:00
fundon
a92515b5aa
fix(core): ai chat opening and append card ( #7322 )
...
Closes: [BS-642](https://linear.app/affine-design/issue/BS-642/continue-with-ai-:-侧边栏关闭的情况下,先唤起-侧边栏,同时插入选中的内容 )
https://github.com/toeverything/AFFiNE/assets/27926/3022d808-d560-4bc8-8a04-735b76056121
2024-06-25 15:56:44 +00:00
L-Sun
532a628989
fix(core): add synced doc block content to ai context ( #7312 )
...
Closes: [AF-955](https://linear.app/affine-design/issue/AF-955/synced-block-%E6%96%87%E6%A1%A3%E6%94%AF%E6%8C%81%EF%BC%9A%E8%AF%BB%E5%8F%96%E6%96%87%E6%A1%A3%E5%86%85%E5%AE%B9%E4%BD%9C%E4%B8%BA-ai-%E7%9A%84%E4%B8%8A%E4%B8%8B%E6%96%87-cotent )
Related PR: https://github.com/toeverything/blocksuite/pull/7405
2024-06-25 10:42:50 +00:00
donteatfriedrice
0918730274
fix: text renderer last child margin bottom ( #7309 )
2024-06-24 09:57:16 +00:00
fundon
8d602d4398
fix(core): selected content should not be activated when executing open in chat ( #7302 )
...
Closes: [AF-949](https://linear.app/affine-design/issue/AF-949/执行-open-in-chat-时,不应该激活选中内容 )
2024-06-21 12:06:22 +00:00
forehalo
7b3673ae82
chore: assign todos ( #7297 )
2024-06-21 07:54:14 +00:00
fundon
92be6b2ff7
fix(core): open ai chat for first time ( #7291 )
...
There are two issues here:
1. open right sidebar with chat
2. notify chat-panel of selected content
The second issue will be fixed in a subsequent PR.
2024-06-21 10:32:34 +08:00
fundon
dbd678cc31
fix(core): ai chat bugs ( #7283 )
...
Closes: [AF-929](https://linear.app/affine-design/issue/AF-929/continue-with-ai-点击后应当是立即激活选区 )
* [x] remove icon background on `chat-input`
* [x] activate the selected card immediately
* [x] fix quote when selecting `Start with this doc`
* [x] clear candidate card list when switching doc
https://github.com/toeverything/AFFiNE/assets/27926/706d499e-b738-4bb4-9353-510f73613875
2024-06-20 11:57:36 +00:00
L-Sun
b99e8b1e8a
chore: adjust padding of ask ai panel ( #7287 )
...
Related PR: https://github.com/toeverything/blocksuite/pull/7389
2024-06-20 19:20:23 +08:00
regischen
e0c6d23691
feat: ai onboarding ( #7279 )
2024-06-20 07:48:10 +00:00
L-Sun
1a8bbc6951
fix: ask ai panel not auto flip ( #7284 )
...
Close [AF-928](https://linear.app/affine-design/issue/AF-928/ask-ai-%E5%87%BA%E7%8E%B0%E5%9C%A8%E5%BA%95%E9%83%A8%E7%9A%84%E6%97%B6%E5%80%99-menu-%E5%BC%B9%E5%87%BA%E4%BD%8D%E7%BD%AE%E4%B8%8D%E5%AF%B9 )
The CSS rule for portal content uses `position: absolute` which causes the portal size to become zero. As a result, the `computePosition` function returns incorrect results.
Before:

After:

2024-06-20 07:33:25 +00:00
fundon
671fa1149d
feat(core): continue with AI ( #7253 )
...
Closes: [AFF-1251](https://linear.app/affine-design/issue/AFF-1251/continue-with-ai-的-action-的入口区分-open-with-ai ) [BS-515](https://linear.app/affine-design/issue/BS-515/添加白板选区的-continue-with-ai-支持 ) [AFF-1256](https://linear.app/affine-design/issue/AFF-1256/continue-with-ai-当只有不支持的-block-时,需要特殊处理 ) [AF-919](https://linear.app/affine-design/issue/AF-919/内容为空时,不需要显示-start-with-this-doc )
* add the selected element to the candidate card list
* select the candidate card to hide the candidate card list and add quote into input
* close quote to show the candidate card list
* show only the three newest candidates
* **`Start with this doc`**: Currently only determines if a document has content after the first load
https://github.com/toeverything/AFFiNE/assets/27926/d19c8ab6-37eb-495f-9c38-e579b2f57000
https://github.com/toeverything/AFFiNE/assets/27926/3ba654c3-6af4-4662-a641-17cfe2ed5ff7
2024-06-20 04:05:11 +00:00
L-Sun
0d711667a8
chore: adjust order of slash menu items ( #7278 )
...
Before -> After
<p float="left">
<img src="https://github.com/toeverything/AFFiNE/assets/20479050/b3937947-7c7c-4463-ae05-87b8f2694989 " width="45%" />
<img src="https://github.com/toeverything/AFFiNE/assets/20479050/e886c20d-e436-4190-aebf-a6b7d711b61e " width="45%" />
</p>
2024-06-20 02:33:18 +00:00
L-Sun
d84eea85b6
fix: ai slide render initialize error ( #7261 )
...
Need add `collection.meta.initialize()` in AI slide render.
Similar codes:
https://github.com/toeverything/AFFiNE/blob/b3ec3a2b3efc0a88770c855e25e7f21ef8142d9c/packages/frontend/core/src/blocksuite/presets/ai/utils/markdown-utils.ts#L177-L195
2024-06-19 04:26:57 +00:00
L-Sun
501fa0bb91
fix(core): ai lit element import ( #7257 )
...
Fix ai lit component import error.
https://github.com/toeverything/AFFiNE/blob/f57a6658190ee55105b08905344d83ec272b6eb3/packages/frontend/core/package.json#L13-L16
2024-06-19 04:26:49 +00:00
regischen
dddfcdbabb
fix: chat more popper position ( #7260 )
2024-06-19 04:11:08 +00:00
donteatfriedrice
ce9a3c82ee
feat: remove new image actions feature flag ( #7256 )
2024-06-19 03:13:19 +00:00
L-Sun
b3ec3a2b3e
refactor(core): migrate ai preset to AFFiNE ( #7219 )
...
## TL;DR
Move `@blocksuite/presets/ai` to AFFiNE. After this PR is merged, you can use AI features from `@affine/core/blocksuite/presets/ai`.
2024-06-18 07:31:06 +00:00