From 9707c74f339baee168bac8fc6c0d3ef6b557edb5 Mon Sep 17 00:00:00 2001 From: Raghav Jajodia Date: Wed, 18 Jan 2017 01:21:30 +0530 Subject: [PATCH] message_edit: Added copy to clipboard button. A copy-to-clipboard button is added over message-edit textarea. Closes #3239. --- .eslintrc.json | 3 ++- package.json | 1 + static/images/clippy.svg | Bin 0 -> 519 bytes static/js/click_handlers.js | 8 +++++++ static/js/message_edit.js | 6 +++++ static/js/ui_init.js | 19 ++++++++++++++++ static/styles/zulip.css | 21 ++++++++++++++++++ static/templates/message_edit_form.handlebars | 2 ++ version.py | 2 +- zproject/settings.py | 1 + 10 files changed, 61 insertions(+), 2 deletions(-) create mode 100644 static/images/clippy.svg diff --git a/.eslintrc.json b/.eslintrc.json index 614aa2b12e..c0dfa499ea 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -118,7 +118,8 @@ "Plotly": false, "emoji_codes": false, "drafts": false, - "katex": false + "katex": false, + "Clipboard": false }, "rules": { "no-restricted-syntax": 0, diff --git a/package.json b/package.json index 23327e5deb..7b82bd04b2 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "description": "", "main": "", "dependencies": { + "clipboard": "1.5.16", "handlebars": "4.0.6", "i18next": "3.4.4", "i18next-parser": "0.11.1", diff --git a/static/images/clippy.svg b/static/images/clippy.svg new file mode 100644 index 0000000000000000000000000000000000000000..e1b17035905df02cbdca2fbb8417ca48dc4842e2 GIT binary patch literal 519 zcmZWm%Wi`(5WMphE8iXbTuc>m>4igkDR*yYpB$j`KkA z{W8R<5n351Xt|uH*oaWGpzquDV{Am6ru$P_F3WOQ?BVlkD2-C81Xr92qT~H-iga$o zt2Tiu4$*j?*|jKV$!?{aHA>pBA?zZ`y^$EYHl1_f1p~xRT~TMOQhBoT6}LE$ktPHP zW?{%^-efjkOz*(n2LUulMs_oddZ|eVS&_9;*W~;tO_dPm;n%Y3rS+s>AWfZab{(?x zi0&yP&;l3%K4V4lkkXbErQ~W%y8y~7nUJRXqz4k%=|&7}9+NKKFr1MO;Z%o@w&pD$ n8@=8
+
diff --git a/version.py b/version.py index bd6eae3c97..5bf1fbd09f 100644 --- a/version.py +++ b/version.py @@ -1,2 +1,2 @@ ZULIP_VERSION = "1.5.1+git" -PROVISION_VERSION = '4.12' +PROVISION_VERSION = '4.13' diff --git a/zproject/settings.py b/zproject/settings.py index 02405d57a0..a40b6471e7 100644 --- a/zproject/settings.py +++ b/zproject/settings.py @@ -793,6 +793,7 @@ JS_SPECS = { 'third/bootstrap-notify/js/bootstrap-notify.js', 'third/html5-formdata/formdata.js', 'node_modules/jquery-validation/dist/jquery.validate.js', + 'node_modules/clipboard/dist/clipboard.js', 'third/jquery-form/jquery.form.js', 'third/jquery-filedrop/jquery.filedrop.js', 'third/jquery-caret/jquery.caret.1.5.2.js',