Fix embed mode for versioned links

pull/1/head
yflory 4 years ago
parent 9a3238fb3b
commit 867156917b

@ -4,12 +4,13 @@ define([
'/common/common-hash.js', '/common/common-hash.js',
'/common/common-interface.js', '/common/common-interface.js',
'/common/common-ui-elements.js', '/common/common-ui-elements.js',
'/common/common-feedback.js',
'/common/inner/common-modal.js', '/common/inner/common-modal.js',
'/common/hyperscript.js', '/common/hyperscript.js',
'/common/clipboard.js', '/common/clipboard.js',
'/customize/messages.js', '/customize/messages.js',
'/bower_components/nthen/index.js', '/bower_components/nthen/index.js',
], function ($, Util, Hash, UI, UIElements, Modal, h, Clipboard, ], function ($, Util, Hash, UI, UIElements, Feedback, Modal, h, Clipboard,
Messages, nThen) { Messages, nThen) {
var Share = {}; var Share = {};
@ -437,6 +438,7 @@ define([
className: 'primary', className: 'primary',
name: Messages.share_linkCopy, name: Messages.share_linkCopy,
onClick: function () { onClick: function () {
Feedback.send('SHARE_EMBED');
var v = opts.getEmbedValue(); var v = opts.getEmbedValue();
var success = Clipboard.copy(v); var success = Clipboard.copy(v);
if (success) { UI.log(Messages.shareSuccess); } if (success) { UI.log(Messages.shareSuccess); }
@ -524,7 +526,6 @@ define([
var burnAfterReading = Util.isChecked($rights.find('#cp-share-bar')); var burnAfterReading = Util.isChecked($rights.find('#cp-share-bar'));
if (versionHash) { if (versionHash) {
edit = false; edit = false;
embed = false;
present = false; present = false;
burnAfterReading = false; burnAfterReading = false;
} }

Loading…
Cancel
Save