Skip to content
This repository has been archived by the owner on Jun 17, 2021. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/2.0.6'
Browse files Browse the repository at this point in the history
  • Loading branch information
Yago committed Mar 13, 2018
2 parents 552c420 + 497c976 commit 8d26e0e
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 11 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Changelog

*2.0.6* (2018-03-13)
- ⚡️ improve SinglePage link handling (8e4ed63)

*2.0.4* (2018-03-09)
- ✨ better inner link handling (ea7dcc8)

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.0.4
2.0.6
4 changes: 2 additions & 2 deletions build/asset-manifest.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"main.css": "static/css/main.99b383b5.css",
"main.css.map": "static/css/main.99b383b5.css.map",
"main.js": "static/js/main.637ae363.js",
"main.js.map": "static/js/main.637ae363.js.map"
"main.js": "static/js/main.84e6b589.js",
"main.js.map": "static/js/main.84e6b589.js.map"
}
2 changes: 1 addition & 1 deletion build/service-worker.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions build/static/js/main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/static/js/main.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "toolbox-reader",
"version": "2.0.4",
"version": "2.0.6",
"private": true,
"eslintConfig": {
"parser": "babel-eslint",
Expand Down
8 changes: 5 additions & 3 deletions src/views/Single/SinglePage.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,11 @@ class SinglePage extends Single {
// If it's a link related event, redirect to page
const linkParent = parentUrl(e.target);
if (linkParent) {
e.preventDefault();
const slug = linkParent.href.split('/pages/').slice(-1)[0];
this.props.history.push(`/pages/${slug}`);
if (linkParent.href.includes('pages')) {
e.preventDefault();
const slug = linkParent.href.split('pages/').slice(-1)[0];
this.props.history.push(`/pages/${slug}`);
}
}
}

Expand Down

0 comments on commit 8d26e0e

Please sign in to comment.