git ssb

2+

mixmix / ticktack



Commit 7cf45e7c039b145503518e3560ac8943fa1e3708

fix mistakes @mixmix saw

Dominic Tarr committed on 12/6/2017, 11:40:04 PM
Parent: 42429c62406fd68f3e1e166a77c05433cf34801e

Files changed

blogs/blog.jschanged
blogs/post.jschanged
blogs/blog.jsView
@@ -28,13 +28,13 @@
2828 return data.value.content.title
2929 },
3030 summary: function (data) {
3131 if('blog' == typeof data.value.content.type) return
32- return data.value.content.title
32+ return data.value.content.summary
3333 },
3434 thumbnail: function (data) {
3535 if('blog' == typeof data.value.content.type) return
36- return data.value.content.title
36+ return data.value.content.thumbnail
3737 },
3838 content: function (data) {
3939 if('blog' == typeof data.value.content.type) return
4040 var div = h('Markdown')
@@ -54,9 +54,4 @@
5454 }
5555 }
5656 }
5757
58-
59-
60-
61-
62-
blogs/post.jsView
@@ -1,9 +1,6 @@
11 var marksum = require('markdown-summary')
22
3-//var markdown = require('ssb-markdown')
4-
5-
63 exports.gives = {
74 message: {
85 html: {
96 title: true,
@@ -20,20 +17,8 @@
2017
2118
2219 exports.create = function (api) {
2320
24- function render (source) {
25- return markdown.block(source, {
26- emoji: (emoji) => {
27- return renderEmoji(emoji, api.emoji.sync.url(emoji))
28- },
29- toUrl: (id) => {
30- if (ref.isBlob(id)) return api.blob.sync.url(id)
31- return id
32- },
33- imageLink: (id) => id
34- })
35- }
3621 function fromPost(fn) {
3722 return function (data) {
3823 if('post' !== data.value.content.type) return
3924 return api.message.html.markdown ({text: fn(data.value.content)})
@@ -66,4 +51,6 @@
6651 }
6752
6853
6954
55+
56+

Built with git-ssb-web