Commit graph

24 commits

Author SHA1 Message Date
Jérémie Astori
900d41bf47
Re-use .previews to order incoming previews instead of extra links 2017-07-21 01:51:51 -04:00
Jérémie Astori
1c8ea0b75c
Fix preserved whitespace-related issues for previews by separating them from main text 2017-07-21 01:50:09 -04:00
Jérémie Astori
a13c08a45b
Enforce correct order for previews on server-side prefectch rather than at client parsing
This has the benefit of not adding `.preview` divs everywhere, anytime we use `parse()`, and also to un-tie the position of the preview blocks from the result of the helper. This means that templates that call `parse` and have some extra markup after that are not constrained anymore.

This is effectively an alternative, better way to fix https://github.com/thelounge/lounge/issues/1343, but the initial fix that was put in place (https://github.com/thelounge/lounge/pull/1347) is still relevant, for example to make sure a preview stays hidden (and does not add extra margin/padding/etc.) if the link does not prefetch.
2017-07-21 01:06:42 -04:00
Jérémie Astori
64ebe0f437
Support multiple previews per message
- Load up to 5 previews per message (to avoid abuse)
- Do not load multiple times the same URL
- Prepare preview containers per message instead of appending (to maintain correct order)
- Store an array of previews instead of a single preview in `Msg` objects
- Consolidate preview rendering for new messages and upon refresh/load history (when rendering entire channels)
- Update `parse` tests to reflect previous point
- Add test for multiple URLs
- Switch preview tests from `assert` API to `expect` API
2017-07-08 04:34:12 -04:00
Pavel Djundik
14b2ad7938 Refactor link previews 2017-07-03 00:41:18 +03:00
Niko Bews
eb4a4c7dfe Move nickname rendering to a single template
Closes #1241
2017-06-22 13:28:17 +03:00
Pavel Djundik
c0a7ae9d92 Use css tooltips on time elements 2017-04-13 01:55:27 -04:00
William Boman
c6ed95e555 views/msg: set data-from attribute to allow styling messages from specific user(s) 2017-03-20 23:08:28 +01:00
Pavel Djundik
fb87bd3a58 Webpack 2016-12-27 19:15:30 +02:00
stepie22
93f0f6942e Add a date seperator 2016-11-23 16:35:42 +02:00
Jérémie Astori
fc03a338fc Display localized timestamp in title of message times 2016-10-01 02:46:19 -04:00
Pavel Djundik
d37e94308d Unread marker MVP 2016-07-05 15:32:41 -04:00
Pavel Djundik
1438ba6f93 Change nicks from links to spans everywhere
Fixes #338
2016-06-22 22:34:10 +03:00
Jérémie Astori
c87d82dc48 Replace color generation with CSS classes
These colors were built using the current generation function to have
similar style.
2016-05-15 15:21:18 -04:00
Jérémie Astori
97c08d409e Add missing aria-label on icon buttons 2016-05-08 15:06:36 -04:00
Maxime Poulin
f1ecae8023 Display whitespace properly
Fixes alignment in many server's motd as well as in-channel ASCII art
2016-04-05 22:36:04 -04:00
Pavel Djundik
84ed021e0e Add context menus 2016-03-01 13:56:36 +02:00
Pavel Djundik
357e238a45 Fix how highlights are handled 2016-02-28 01:30:20 +02:00
Alistair McKinlay
e5aa02d696 Change user buttons to as. Allows highlighting on firefox. 2016-01-24 16:53:06 +00:00
Pavel Djundik
bb98be475a Render user actions separately 2016-01-24 16:59:13 +02:00
Pavel Djundik
7a9bc41b30 Use a single function to process and render messages 2016-01-23 16:59:05 +02:00
Jérémie Astori
37aa9c7eeb Revert "Change user buttons to as. Allows highlighting on firefox." 2016-01-09 14:16:44 -05:00
Alistair McKinlay
fe0eff8abd Change user buttons to as. Allows highlighting on firefox. 2016-01-09 15:51:54 +00:00
Mattias Erming
b801689eaa Show user modes in channel 2014-10-04 05:31:45 -07:00
Renamed from client/templates/msg.tpl (Browse further)