1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-14 10:16:26 +00:00

Compare commits

...

5 Commits

Author SHA1 Message Date
Kohei TAKATA
16061a7eba v0.8.6 2017-03-04 13:04:18 +09:00
SuenagaRyota
8beb661af4 Merge pull request #291 from kostaldavid8/image-drag-fix
Image drag fix
2017-02-18 21:06:16 +09:00
kostaldavid8
f7fb531902 Fixed image drag and drop
Added escaping and changed function that wasn't working
2017-02-17 10:31:41 +01:00
Sota Sugiura
b32b38bb0d Merge pull request #287 from ericsolomon/274_font_color_rename_folder_modal
Fix font color for dark theme rename folder modal
2017-02-16 21:38:37 -08:00
Eric Solomon
6e5f6cc739 Fix font color for dark theme rename folder modal 2017-02-14 03:21:23 -06:00
3 changed files with 5 additions and 4 deletions

View File

@@ -168,13 +168,13 @@ export default class CodeEditor extends React.Component {
e.preventDefault()
let imagePath = e.dataTransfer.files[0].path
let filename = path.basename(imagePath)
let imageMd = `![${filename}](${imagePath})`
let imageMd = `![${encodeURI(filename)}](${encodeURI(imagePath)})`
this.insertImage(imageMd)
}
insertImage (imageMd) {
const textarea = this.editor.getInputField()
textarea.value = textarea.value.substr(0, textarea.selectionStart) + imageMd + textarea.value.substr(textarea.selectionEnd)
const cm = this.editor
cm.setValue(cm.getValue() + imageMd)
}
render () {

View File

@@ -75,3 +75,4 @@ body[data-theme="dark"]
.control-input
border-color $ui-dark-borderColor
color $ui-dark-text-color

View File

@@ -1,6 +1,6 @@
{
"name": "boost",
"version": "0.8.5",
"version": "0.8.6",
"description": "Boostnote",
"main": "index.js",
"license": "GPL-3.0",