Treat newline as neweline (#261)

* Treat newline as neweline

* Update changelog
This commit is contained in:
Sung Won Cho 2019-10-02 16:34:55 +08:00 committed by GitHub
commit 97ff614ab9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 58 additions and 41 deletions

View file

@ -10,6 +10,13 @@ All notable changes to the projects under this repository will be documented in
The following log documentes the history of the server project.
## [Unreleased]
### Changed
- Treat a linebreak as a new line in the preview (#261)
- Allow to have multiple editor states for adding and editing notes (#260)
### 0.1.1 - 2019-09-30
#### Fixed

77
web/package-lock.json generated
View file

@ -1324,9 +1324,9 @@
"dev": true
},
"@types/react": {
"version": "16.9.3",
"resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.3.tgz",
"integrity": "sha512-Ogb2nSn+2qQv5opoCv7Ls5yFxtyrdUYxp5G+SWTrlGk7dmFKw331GiezCgEZj9U7QeXJi1CDtws9pdXU1zUL4g==",
"version": "16.9.4",
"resolved": "https://registry.npmjs.org/@types/react/-/react-16.9.4.tgz",
"integrity": "sha512-ItGNmJvQ0IvWt8rbk5PLdpdQhvBVxAaXI9hDlx7UMd8Ie1iMIuwMNiKeTfmVN517CdplpyXvA22X4zm4jGGZnw==",
"requires": {
"@types/prop-types": "*",
"csstype": "^2.2.0"
@ -1372,12 +1372,12 @@
}
},
"@typescript-eslint/eslint-plugin": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.3.1.tgz",
"integrity": "sha512-VqVNEsvemviajlaWm03kVMabc6S3xCHGYuY0fReTrIIOZg+3WzB+wfw6fD3KYKerw5lYxmzogmHOZ0i7YKnuwA==",
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.3.2.tgz",
"integrity": "sha512-tcnpksq1bXzcIRbYLeXkgp6l+ggEMXXUcl1wsSvL807fRtmvVQKygElwEUf4hBA76dNag3VAK1q2m3vd7qJaZA==",
"dev": true,
"requires": {
"@typescript-eslint/experimental-utils": "2.3.1",
"@typescript-eslint/experimental-utils": "2.3.2",
"eslint-utils": "^1.4.2",
"functional-red-black-tree": "^1.0.1",
"regexpp": "^2.0.1",
@ -1385,13 +1385,13 @@
}
},
"@typescript-eslint/experimental-utils": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-2.3.1.tgz",
"integrity": "sha512-FaZEj73o4h6Wd0Lg+R4pZiJGdR0ZYbJr+O2+RbQ1aZjX8bZcfkVDtD+qm74Dv77rfSKkDKE64UTziLBo9UYHQA==",
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-2.3.2.tgz",
"integrity": "sha512-t+JGdTT6dRbmvKDlhlVkEueoZa0fhJNfG6z2cpnRPLwm3VwYr2BjR//acJGC1Yza0I9ZNcDfRY7ubQEvvfG6Jg==",
"dev": true,
"requires": {
"@types/json-schema": "^7.0.3",
"@typescript-eslint/typescript-estree": "2.3.1",
"@typescript-eslint/typescript-estree": "2.3.2",
"eslint-scope": "^5.0.0"
},
"dependencies": {
@ -1408,14 +1408,14 @@
}
},
"@typescript-eslint/parser": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-2.3.1.tgz",
"integrity": "sha512-ZlWdzhCJ2iZnSp/VBAJ/sowFbyHycIux8t0UEH0JsKgQvfSf7949hLYFMwTXdCMeEnpP1zRTHimrR+YHzs8LIw==",
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-2.3.2.tgz",
"integrity": "sha512-nq1UQeNGdKdqdgF6Ww+Ov2OidWgiL96+JYdXXZ2rkP/OWyc6KMNSbs6MpRCpI8q+PmDa7hBnHNQIo7w/drYccA==",
"dev": true,
"requires": {
"@types/eslint-visitor-keys": "^1.0.0",
"@typescript-eslint/experimental-utils": "2.3.1",
"@typescript-eslint/typescript-estree": "2.3.1",
"@typescript-eslint/experimental-utils": "2.3.2",
"@typescript-eslint/typescript-estree": "2.3.2",
"eslint-visitor-keys": "^1.1.0"
},
"dependencies": {
@ -1428,9 +1428,9 @@
}
},
"@typescript-eslint/typescript-estree": {
"version": "2.3.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-2.3.1.tgz",
"integrity": "sha512-9SFhUgFuePJBB6jlLkOPPhMkZNiDCr+S8Ft7yAkkP2c5x5bxPhG3pe/exMiQaF8IGyVMDW6Ul0q4/cZ+uF3uog==",
"version": "2.3.2",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-2.3.2.tgz",
"integrity": "sha512-eZNEAai16nwyhIVIEaWQlaUgAU3S9CkQ58qvK0+3IuSdLJD3W1PNuehQFMIhW/mTP1oFR9GNoTcLg7gtXz6lzA==",
"dev": true,
"requires": {
"glob": "^7.1.4",
@ -4104,9 +4104,9 @@
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
},
"eslint": {
"version": "6.5.0",
"resolved": "https://registry.npmjs.org/eslint/-/eslint-6.5.0.tgz",
"integrity": "sha512-IIbSW+vKOqMatPmS9ayyku4tvWxHY2iricSRtOz6+ZA5IPRlgXzEL0u/j6dr4eha0ugmhMwDTqxtmNu3kj9O4w==",
"version": "6.5.1",
"resolved": "https://registry.npmjs.org/eslint/-/eslint-6.5.1.tgz",
"integrity": "sha512-32h99BoLYStT1iq1v2P9uwpyznQ4M2jRiFB6acitKz52Gqn+vPaMDUTB1bYi1WN4Nquj2w+t+bimYUG83DC55A==",
"dev": true,
"requires": {
"@babel/code-frame": "^7.0.0",
@ -4425,20 +4425,20 @@
}
},
"eslint-plugin-react": {
"version": "7.14.3",
"resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.14.3.tgz",
"integrity": "sha512-EzdyyBWC4Uz2hPYBiEJrKCUi2Fn+BJ9B/pJQcjw5X+x/H2Nm59S4MJIvL4O5NEE0+WbnQwEBxWY03oUk+Bc3FA==",
"version": "7.15.1",
"resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.15.1.tgz",
"integrity": "sha512-YotSItgMPwLGlr3df44MGVyXnHkmKcpkHTzpte3QwJtocr3nFqCXCuoxFZeBtnT8RHdj038NlTvam3dcAFrMcA==",
"dev": true,
"requires": {
"array-includes": "^3.0.3",
"doctrine": "^2.1.0",
"has": "^1.0.3",
"jsx-ast-utils": "^2.1.0",
"jsx-ast-utils": "^2.2.1",
"object.entries": "^1.1.0",
"object.fromentries": "^2.0.0",
"object.values": "^1.1.0",
"prop-types": "^15.7.2",
"resolve": "^1.10.1"
"resolve": "^1.12.0"
},
"dependencies": {
"doctrine": {
@ -4449,6 +4449,15 @@
"requires": {
"esutils": "^2.0.2"
}
},
"resolve": {
"version": "1.12.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.12.0.tgz",
"integrity": "sha512-B/dOmuoAik5bKcD6s6nXDCjzUKnaDvdkRyAk6rsmsKLipWj4797iothd7jmmUhWTfinVMU+wc56rYKsit2Qy4w==",
"dev": true,
"requires": {
"path-parse": "^1.0.6"
}
}
}
},
@ -9302,9 +9311,9 @@
}
},
"react-router": {
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/react-router/-/react-router-5.1.1.tgz",
"integrity": "sha512-ozTXqxKZsn4GfZqpG5rVFHSSxlNuDoMNxgyjM+mFJVhqlnPwwkRsAPkDm1PcNjBdYxMzqAhtz48HkQB6fSYaAQ==",
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/react-router/-/react-router-5.1.2.tgz",
"integrity": "sha512-yjEuMFy1ONK246B+rsa0cUam5OeAQ8pyclRDgpxuSCrAlJ1qN9uZ5IgyKC7gQg0w8OM50NXHEegPh/ks9YuR2A==",
"requires": {
"@babel/runtime": "^7.1.2",
"history": "^4.9.0",
@ -9327,15 +9336,15 @@
}
},
"react-router-dom": {
"version": "5.1.1",
"resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-5.1.1.tgz",
"integrity": "sha512-r8R8H0Vt2ISqpk02rR6VZBLk+JZdR6pZV+h9K1y0ISh3/G4GGByNevYBS69x6czcOcWVRcZmXjwY8l9UBCKV+w==",
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-5.1.2.tgz",
"integrity": "sha512-7BPHAaIwWpZS074UKaw1FjVdZBSVWEk8IuDXdB+OkLb8vd/WRQIpA4ag9WQk61aEfQs47wHyjWUoUGGZxpQXew==",
"requires": {
"@babel/runtime": "^7.1.2",
"history": "^4.9.0",
"loose-envify": "^1.3.1",
"prop-types": "^15.6.2",
"react-router": "5.1.1",
"react-router": "5.1.2",
"tiny-invariant": "^1.0.2",
"tiny-warning": "^1.0.0"
}

View file

@ -19,23 +19,23 @@
"@babel/register": "^7.6.2",
"@hot-loader/react-dom": "^16.9.0",
"@types/mocha": "^5.2.7",
"@types/react": "^16.9.3",
"@types/react": "^16.9.4",
"@types/react-dom": "^16.9.1",
"@typescript-eslint/eslint-plugin": "^2.3.1",
"@typescript-eslint/parser": "^2.3.1",
"@typescript-eslint/eslint-plugin": "^2.3.2",
"@typescript-eslint/parser": "^2.3.2",
"autoprefixer": "^9.6.1",
"babel-eslint": "^10.0.3",
"babel-loader": "^8.0.6",
"chai": "^4.2.0",
"css-loader": "^3.2.0",
"cssnano": "^4.1.10",
"eslint": "^6.5.0",
"eslint": "^6.5.1",
"eslint-config-airbnb": "^18.0.1",
"eslint-config-prettier": "^6.3.0",
"eslint-plugin-import": "^2.18.2",
"eslint-plugin-jsx-a11y": "^6.2.3",
"eslint-plugin-prettier": "^3.1.1",
"eslint-plugin-react": "^7.14.3",
"eslint-plugin-react": "^7.15.1",
"eslint-plugin-react-hooks": "^2.1.1",
"fibers": "^4.0.1",
"file-loader": "^4.2.0",
@ -83,9 +83,9 @@
"react-helmet": "^5.2.1",
"react-hot-loader": "^4.12.14",
"react-redux": "^7.1.1",
"react-router": "^5.1.1",
"react-router": "^5.1.2",
"react-router-config": "^5.1.1",
"react-router-dom": "^5.1.1",
"react-router-dom": "^5.1.2",
"react-stripe-elements": "^5.0.1",
"react-tooltip": "^3.11.1",
"redux": "^4.0.4",

View file

@ -22,6 +22,7 @@ import hljs from 'highlight.js';
const md = markdown({
html: true,
linkify: true,
breaks: true,
highlight: (str, lang) => {
if (lang && hljs.getLanguage(lang)) {
return hljs.highlight(lang, str).value;