git ssb

0+

alanz / patchwork



forked from Matt McKegg / patchwork

Commit f673ec400fd6aac5f54664a90b9d9fc631bab957

don't include full blob url in gathering image link

stops external link hover
Matt McKegg committed on 10/18/2017, 5:24:45 AM
Parent: e39458cf79ac14e9ae06c78494db0453c35f8f9b

Files changed

plugs/message/html/render/gathering.jschanged
plugs/message/html/render/gathering.jsView
@@ -39,8 +39,9 @@
3939 following = api.contact.obs.following(yourId)
4040 }
4141
4242 var imageUrl = computed(image, (id) => api.blob.sync.url(id))
43+ var imageId = computed(image, (link) => link && link.link || link)
4344 var content = h('GatheringCard', [
4445 h('div.title', [
4546 h('a', {href: msg.key}, title),
4647 h('button', {
@@ -48,9 +49,9 @@
4849 }, 'Edit Details')
4950 ]),
5051 h('div.time', computed(startDateTime, formatTime)),
5152 when(image, h('a.image', {
52- href: imageUrl,
53+ href: imageId,
5354 style: {
5455 'background-image': computed(imageUrl, (url) => `url(${url})`)
5556 }
5657 })),

Built with git-ssb-web