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

feat: support bookmark #2458

Merged
merged 18 commits into from May 26, 2023
Merged

feat: support bookmark #2458

merged 18 commits into from May 26, 2023

Conversation

QiShaoXuan
Copy link
Contributor

@QiShaoXuan QiShaoXuan commented May 19, 2023

This PR needs to be linked with blocksuite. Ths specific requirements are here: toeverything/blocksuite#2574

What this pr has to do are:

  • Display the bookmark menu after identify link, and support to choose by keyboard
  • After insert bookmark block, Affine need to support a function to get the page information by link

@codesandbox
Copy link

codesandbox bot commented May 19, 2023

CodeSandbox logoCodeSandbox logo  Open in CodeSandbox Web Editor | VS Code | VS Code Insiders | Preview

@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:13 — with GitHub Actions Inactive
@vercel
Copy link

vercel bot commented May 19, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
affine-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 26, 2023 6:51am
affine-storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 26, 2023 6:51am

@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:13 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:13 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:13 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:13 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:16 — with GitHub Actions Inactive
@codecov
Copy link

codecov bot commented May 19, 2023

Codecov Report

Patch coverage: 21.10% and project coverage change: -0.77 ⚠️

Comparison is base (7dcbe64) 72.60% compared to head (8b663fd) 71.83%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2458      +/-   ##
==========================================
- Coverage   72.60%   71.83%   -0.77%     
==========================================
  Files         318      319       +1     
  Lines        7103     7211     +108     
  Branches     1161     1185      +24     
==========================================
+ Hits         5157     5180      +23     
- Misses       1744     1829      +85     
  Partials      202      202              
Flag Coverage Δ
e2etest 65.23% <22.22%> (-0.89%) ⬇️
e2etest-macos-latest-x64 ∅ <ø> (∅)
e2etest-ubuntu-latest-x64 47.72% <22.22%> (+0.52%) ⬆️
e2etest-windows-latest-x64 ?
server-test 73.12% <ø> (ø)
storybook-test 53.54% <13.08%> (-2.57%) ⬇️
unittest 36.47% <7.44%> (-0.65%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
apps/web/preset.config.mjs 62.50% <ø> (ø)
packages/component/src/ui/menu/menu-item.tsx 100.00% <ø> (ø)
...components/block-suite-editor/plugins/bookmark.tsx 8.60% <8.60%> (ø)
packages/component/src/ui/menu/styles.ts 68.96% <75.00%> (-0.27%) ⬇️
...ponent/src/components/block-suite-editor/index.tsx 94.59% <100.00%> (+1.04%) ⬆️

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@cloudflare-pages
Copy link

cloudflare-pages bot commented May 19, 2023

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: 8b663fd
Status: ✅  Deploy successful!
Preview URL: https://7970acf9.affine.pages.dev
Branch Preview URL: https://feat-bookmark.affine.pages.dev

View logs

@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@QiShaoXuan QiShaoXuan temporarily deployed to development May 19, 2023 10:19 — with GitHub Actions Inactive
@perfsee
Copy link

perfsee bot commented May 19, 2023

affine-toeverything

Bundle main

diff ------------------- Bundle Size Diff -------------------------

@@                       EntryPoint: main                        @@
##                     master  feat/bookmark                 +/- ##
===================================================================
< Bundle              3.34 MB        3.41 MB    +73.1 kB(+2.19%)   
< Initial JS          2.08 MB        2.16 MB    +83.5 kB(+4.01%)   
= Initial CSS         35.6 kB        35.6 kB                       
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets                   47             47                       
= Chunks                   40             40                       
= Packages                144            144                       
= Duplicates                3              3                       
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Warnings ~~~~~~~~~~~~~~~~~~~~~~~~~~~#
! Separate mixed content assets files                              
! Avoid cache wasting                                              

@@                    EntryPoint: pages/_app                     @@
##                     master  feat/bookmark                 +/- ##
===================================================================
< Bundle              3.22 MB        3.29 MB    +73.1 kB(+2.27%)   
< Initial JS          1.96 MB        2.04 MB    +83.5 kB(+4.26%)   
= Initial CSS         35.6 kB        35.6 kB                       
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets                   45             45                       
= Chunks                   38             38                       
= Packages                144            144                       
= Duplicates                3              3                       
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Warnings ~~~~~~~~~~~~~~~~~~~~~~~~~~~#
! Separate mixed content assets files                              
! Avoid cache wasting                                              

@@                   EntryPoint: pages/_error                    @@
##                     master  feat/bookmark                 +/- ##
===================================================================
= Bundle              16.6 kB        16.6 kB                       
= Initial JS          16.6 kB        16.6 kB                       
= Initial CSS             0 B            0 B                       
#~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~#
= Assets                    2              2                       
= Chunks                    2              2                       
= Packages                  5              5                       
= Duplicates                0              0                       

...and more

@vercel vercel bot temporarily deployed to Preview – affine-preview May 19, 2023 10:21 Inactive
@vercel vercel bot temporarily deployed to Preview – affine-storybook May 19, 2023 10:25 Inactive
@github-actions github-actions bot added the app:electron Related to electron app label May 23, 2023
@github-actions github-actions bot removed the app:electron Related to electron app label May 23, 2023
@himself65 himself65 temporarily deployed to development May 26, 2023 06:27 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:27 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:27 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:27 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:27 — with GitHub Actions Inactive
@himself65 himself65 enabled auto-merge (squash) May 26, 2023 06:27
@himself65 himself65 temporarily deployed to development May 26, 2023 06:30 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:31 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:31 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:31 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:31 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:31 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:34 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@himself65 himself65 temporarily deployed to development May 26, 2023 06:38 — with GitHub Actions Inactive
@vercel vercel bot temporarily deployed to Preview – affine-storybook May 26, 2023 06:46 Inactive
@vercel vercel bot temporarily deployed to Preview – affine-preview May 26, 2023 06:51 Inactive
@himself65 himself65 merged commit 6d3c273 into master May 26, 2023
9 checks passed
@himself65 himself65 deleted the feat/bookmark branch May 26, 2023 06:52
himself65 added a commit that referenced this pull request May 26, 2023
Co-authored-by: himself65 <himself65@outlook.com>
himself65 added a commit that referenced this pull request Jun 2, 2023
Co-authored-by: himself65 <himself65@outlook.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants