Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fixes 3182#5598

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation

@withrocks
Copy link
Contributor

@withrockswithrocks commentedJul 10, 2020
edited
Loading

Issue#3182 "Can't paste two images from clipboard in markdown cell"
happens when the user tries to paste a second image into a text
cell and the image gets the same attachment key as the previous one.

This patch fixes that issue by adding an index to each picture that's
pasted after the previous one. Example:

  • User pastes an image blob A. The text![image.png](attachment:image.png)
    is added to the text cell and the blob is saved as attachmentimage.png
  • The user pastes a second image blob B. The same happens as with blob
    A, except the key is nowimage-2.png rather thanimage.png

Special case:

If the user pastes the exact same blob A twice, it will not be added to
the attachments, but the textcell will get a second entry of
![image.png](attachment:image.png).

Issue 3182 "Can't paste two images from clipboard in markdown cell"happens when the user tries to paste a second image into a textcell and the image gets the same attachment key as the previous one.This patch fixes that issue by adding an index to each picture that'spasted after the previous one. Example:* User pastes an image blob A. The text `![image.png](attachment:image.png)`  is added to the text cell and the blob is saved as attachment `image.png`* The user pastes a second image blob B. The same happens as with blob  A, except the key is now `image-1.png` rather than `image.png`Special case:If the user pastes the exact same blob A twice, it will not be added tothe attachments, but the textcell will get a second entry of`![image.png](attachment:image.png)`.
@withrocks
Copy link
ContributorAuthor

I wasn't able to read the general Jupyter general contribution guidelines because the link is broken:https://jupyter.readthedocs.io/en/latest/contributor/content-contributor.html

I hope that won't be an issue.

@kevin-bates
Copy link
Member

Hi@withrocks - your PR content seems fine although I'm not qualified to review it.

The broken link should point here:https://jupyter.readthedocs.io/en/latest/contributing/content-contributor.html

I've opened issue#5599 for this.

withrocks reacted with thumbs up emoji

Copy link
Contributor

@blink1073blink1073 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

LGTM, thanks!

withrocks reacted with thumbs up emojiwithrocks reacted with hooray emoji
@blink1073blink1073 added this to the6.2 milestoneJul 22, 2020
@kevin-bateskevin-bates mentioned this pull requestJul 22, 2020
24 tasks
@blink1073blink1073 modified the milestones:6.2,6.1Jul 23, 2020
@blink1073blink1073 merged commita94d316 intojupyter:masterJul 23, 2020
@github-actionsgithub-actionsbot locked asresolvedand limited conversation to collaboratorsMar 23, 2021
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.

Reviewers

1 more reviewer

@blink1073blink1073blink1073 approved these changes

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Projects

None yet

Milestone

6.1

Development

Successfully merging this pull request may close these issues.

3 participants

@withrocks@kevin-bates@blink1073

[8]ページ先頭

©2009-2025 Movatter.jp