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

disable hyperlink for attachments #2474

Merged
merged 3 commits into from
Oct 23, 2018

Conversation

daiyam
Copy link
Contributor

@daiyam daiyam commented Oct 8, 2018

This change disables the following popover on attached images:
screenshot

@ZeroX-DG ZeroX-DG added the awaiting review ❇️ Pull request is awaiting a review. label Oct 9, 2018
@@ -52,7 +52,8 @@

if (className.indexOf('cm-url') !== -1) {
const match = /^\((.*)\)|\[(.*)\]|(.*)$/.exec(el.textContent)
return match[1] || match[2] || match[3]
const url = match[1] || match[2] || match[3]
return /^:storage\//.test(url) ? null : url
Copy link
Contributor

Choose a reason for hiding this comment

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

do you mind to use attachmentManagement.STORAGE_FOLDER_PLACEHOLDER instead of hard-coding :storage here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@ehhc it's not possible
require('../browser/main/lib/dataApi/attachmentManagement') throws the error Cannot find module 'browser/lib/findStorage'

hyperlink.js is loaded by Chromium
attachmentManagement.js is written to be loaded by node

Copy link
Contributor

Choose a reason for hiding this comment

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

if it is really not possible (i am not a nodejs/electron pro, so i'm not sure about that) could you at least add an comment pointing to that file? That would help a lot in case somebody will refactor it again (e.g. in a few years..)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@ehhc sure, I can do that

Copy link
Member

@ZeroX-DG ZeroX-DG left a comment

Choose a reason for hiding this comment

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

LGTM 🎉

@ZeroX-DG ZeroX-DG added approved 👍 Pull request has been approved by sufficient reviewers. and removed awaiting review ❇️ Pull request is awaiting a review. labels Oct 21, 2018
@Rokt33r Rokt33r added next release (v0.11.11) and removed approved 👍 Pull request has been approved by sufficient reviewers. labels Oct 23, 2018
@Rokt33r Rokt33r merged commit 1ea1482 into BoostIO:master Oct 23, 2018
@daiyam daiyam deleted the fix-attachment-hyperlink branch November 27, 2018 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants