Skip to content

Commit

Permalink
embed links into markdown content
Browse files Browse the repository at this point in the history
  • Loading branch information
HarveyKandola committed May 10, 2017
1 parent 88add0a commit 60131df
Show file tree
Hide file tree
Showing 7 changed files with 628 additions and 620 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ The mission is to bring software dev inspired features (refactoring, testing, li

## Latest version

v1.47.0
v1.47.1

## OS Support

Expand Down
4 changes: 2 additions & 2 deletions app/app/components/document/document-view.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export default Ember.Component.extend(NotifierMixin, TooltipMixin, {
if (!$(jumpTo).inView()) {
$(jumpTo).velocity("scroll", { duration: 250, offset: -100 });
}
});
});
},

didRender() {
Expand Down Expand Up @@ -83,7 +83,7 @@ export default Ember.Component.extend(NotifierMixin, TooltipMixin, {
link.orphan = true;
} else {
if (link.linkType === "section") {
self.attrs.gotoPage(link.targetId);
self.attrs.onGotoPage(link.targetId);
}
}
}
Expand Down
8 changes: 8 additions & 0 deletions app/app/pods/document/index/controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ export default Ember.Controller.extend(NotifierMixin, {
documentService: Ember.inject.service('document'),
templateService: Ember.inject.service('template'),
sectionService: Ember.inject.service('section'),
linkService: Ember.inject.service('link'),
folder: {},
pages: [],
toggled: false,
Expand All @@ -42,6 +43,10 @@ export default Ember.Controller.extend(NotifierMixin, {
if (documentId === targetDocumentId) {
this.set('pageId', '');
this.get('target.router').refresh();

this.get('linkService').getDocumentLinks(this.get('model.document.id')).then((links) => {
this.set('model.links', links);
});
}
});
},
Expand All @@ -65,6 +70,9 @@ export default Ember.Controller.extend(NotifierMixin, {
this.get('documentService').updatePage(documentId, page.get('id'), model).then((up) => {
page = up;
this.set('pageId', page.get('id'));
this.get('linkService').getDocumentLinks(this.get('model.document.id')).then((links) => {
this.set('model.links', links);
});
});
},

Expand Down
2 changes: 1 addition & 1 deletion app/app/pods/document/index/template.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
{{document/document-view document=model.document links=model.links pages=model.pages
folder=model.folder folders=model.folders sections=model.sections isEditor=model.isEditor pageId=pageId
onSavePage=(action 'onSavePage') onInsertSection=(action 'onInsertSection')
onSavePageAsBlock=(action 'onSavePageAsBlock') onDeleteBlock=(action 'onDeleteBlock')
onSavePageAsBlock=(action 'onSavePageAsBlock') onDeleteBlock=(action 'onDeleteBlock') onGotoPage=(action 'onGotoPage')
onCopyPage=(action 'onCopyPage') onMovePage=(action 'onMovePage') onDeletePage=(action 'onPageDeleted')}}
</div>
{{/layout/zone-content}}
Expand Down
2 changes: 1 addition & 1 deletion app/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "documize",
"version": "1.47.0",
"version": "1.47.1",
"description": "The Document IDE",
"private": true,
"repository": "",
Expand Down
2 changes: 1 addition & 1 deletion core/api/endpoint/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ var Product core.ProdInfo
func init() {
Product.Major = "1"
Product.Minor = "47"
Product.Patch = "0"
Product.Patch = "1"
Product.Version = fmt.Sprintf("%s.%s.%s", Product.Major, Product.Minor, Product.Patch)
Product.Edition = "Community"
Product.Title = fmt.Sprintf("%s Edition", Product.Edition)
Expand Down
1,228 changes: 614 additions & 614 deletions embed/bindata_assetfs.go

Large diffs are not rendered by default.

0 comments on commit 60131df

Please sign in to comment.