mirror of
https://github.com/flarum/framework.git
synced 2024-11-25 09:41:49 +08:00
Release 0.1.0-beta.4
This commit is contained in:
parent
5041428b8c
commit
eefdb40f08
12
extensions/embed/CHANGELOG.md
Normal file
12
extensions/embed/CHANGELOG.md
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
# Change Log
|
||||||
|
All notable changes to the Embed extension will be documented in this file.
|
||||||
|
This project adheres to [Semantic Versioning](http://semver.org/).
|
||||||
|
|
||||||
|
## [0.1.0-beta.4] - 2015-11-05
|
||||||
|
### Added
|
||||||
|
- Make the toolbar fixed to the top, add a comment count
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
- Fix incorrect post permalinks
|
||||||
|
|
||||||
|
[0.1.0-beta.4]: https://github.com/flarum/embed/compare/v0.1.0-beta.3...v0.1.0-beta.4
|
19
extensions/embed/js/forum/dist/extension.js
vendored
19
extensions/embed/js/forum/dist/extension.js
vendored
|
@ -73,6 +73,23 @@ System.register('flarum/embed/components/DiscussionPage', ['flarum/components/Di
|
||||||
|
|
||||||
items.remove('scrubber');
|
items.remove('scrubber');
|
||||||
|
|
||||||
|
var count = this.discussion.repliesCount();
|
||||||
|
|
||||||
|
items.add('replies', m(
|
||||||
|
'h3',
|
||||||
|
null,
|
||||||
|
m(
|
||||||
|
'a',
|
||||||
|
{ href: app.route.discussion(this.discussion).replace('/embed', '/d'), config: m.route },
|
||||||
|
count,
|
||||||
|
' comment',
|
||||||
|
count == 1 ? '' : 's'
|
||||||
|
)
|
||||||
|
), 100);
|
||||||
|
|
||||||
|
var props = items.get('controls').props;
|
||||||
|
props.className = props.className.replace('App-primaryControl', '');
|
||||||
|
|
||||||
return items;
|
return items;
|
||||||
}
|
}
|
||||||
}]);
|
}]);
|
||||||
|
@ -129,7 +146,7 @@ System.register('flarum/embed/main', ['flarum/extend', 'flarum/app', 'flarum/com
|
||||||
|
|
||||||
// Trim the /embed prefix off of post permalinks
|
// Trim the /embed prefix off of post permalinks
|
||||||
override(PostMeta.prototype, 'getPermalink', function (original, post) {
|
override(PostMeta.prototype, 'getPermalink', function (original, post) {
|
||||||
return original(post).replace('/embed', '');
|
return original(post).replace('/embed', '/d');
|
||||||
});
|
});
|
||||||
|
|
||||||
app.pane = new Pane(document.getElementById('app'));
|
app.pane = new Pane(document.getElementById('app'));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user