1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-10-31 00:07:48 +02:00

Clipper: Fixes #1990: Clipper was not saving page URL when taking screenshot

This commit is contained in:
Laurent Cozic
2019-11-07 18:12:14 +00:00
parent a6f190766c
commit 4af8bb8e8d
2 changed files with 2 additions and 1 deletions

View File

@@ -57,6 +57,7 @@ browser_.runtime.onMessage.addListener(async (command) => {
const imageDataUrl = await browserCaptureVisibleTabs(null); const imageDataUrl = await browserCaptureVisibleTabs(null);
const content = Object.assign({}, command.content); const content = Object.assign({}, command.content);
content.image_data_url = imageDataUrl; content.image_data_url = imageDataUrl;
if ('url' in content) content.source_url = content.url;
const newArea = Object.assign({}, command.content.crop_rect); const newArea = Object.assign({}, command.content.crop_rect);
newArea.x *= zoom; newArea.x *= zoom;

View File

@@ -433,7 +433,7 @@
const content = { const content = {
title: pageTitle(), title: pageTitle(),
crop_rect: selectionArea, crop_rect: selectionArea,
url: pageLocationOrigin() + location.pathname, url: pageLocationOrigin() + location.pathname + location.search,
parent_id: command.parent_id, parent_id: command.parent_id,
tags: command.tags, tags: command.tags,
}; };