diff --git a/bin/svgs.js b/bin/svgs.js index f0138f90..70bafae5 100644 --- a/bin/svgs.js +++ b/bin/svgs.js @@ -22,4 +22,5 @@ module.exports = [ {id:'fa-comments', src:'node_modules/font-awesome-svg-png/white/svg/comments.svg', title: 'Conversations'}, {id:'fa-paperclip', src:'node_modules/font-awesome-svg-png/white/svg/paperclip.svg', title: 'Paperclip'}, {id:'fa-thumbtack', src:'node_modules/font-awesome-svg-png/white/svg/thumb-tack.svg', title: 'Thumbtack'}, + {id:'fa-bars', src:'node_modules/font-awesome-svg-png/white/svg/bars.svg', title: 'List'}, ] \ No newline at end of file diff --git a/routes/_api/lists.js b/routes/_api/lists.js new file mode 100644 index 00000000..056154b7 --- /dev/null +++ b/routes/_api/lists.js @@ -0,0 +1,8 @@ +import { get } from '../_utils/ajax' + +export function getLists(instanceName, accessToken) { + let url = `https://${instanceName}/api/v1/lists` + return get(url, { + 'Authorization': `Bearer ${accessToken}` + }) +} \ No newline at end of file diff --git a/routes/_api/timelines.js b/routes/_api/timelines.js index 1f9619d4..40f887e2 100644 --- a/routes/_api/timelines.js +++ b/routes/_api/timelines.js @@ -19,6 +19,8 @@ function getTimelineUrlPath(timeline) { return 'statuses' } else if (timeline.startsWith('account/')) { return 'accounts' + } else if (timeline.startsWith('list/')) { + return 'timelines/list' } } @@ -31,7 +33,9 @@ export function getTimeline(instanceName, accessToken, timeline, maxId, since) { } else if (timeline.startsWith('status/')) { url += '/' + timeline.split('/').slice(-1)[0] + '/context' } else if (timeline.startsWith('account/')) { - url += '/' + timeline.split('/').slice(-1)[0] +'/statuses' + url += '/' + timeline.split('/').slice(-1)[0] + '/statuses' + } else if (timeline.startsWith('list/')) { + url += '/' + timeline.split('/').slice(-1)[0] } let params = {} diff --git a/routes/_components/Nav.html b/routes/_components/Nav.html index e8c82225..655bb478 100644 --- a/routes/_components/Nav.html +++ b/routes/_components/Nav.html @@ -18,6 +18,10 @@