Commit graph

200 commits

Author SHA1 Message Date
Simon Ser
6524dc5dd2 Add support for the soju.im/bouncer-networks-notify cap 2021-05-25 17:01:20 +02:00
Simon Ser
5165df718f Disconnect on BOUNCER BIND error 2021-05-25 16:59:59 +02:00
Simon Ser
b429243573 Add support for the soju.im/bouncer-networks extension 2021-05-25 16:58:50 +02:00
Simon Ser
f122e44e9b Use ISUPPORT CHATHISTORY to discover max page size 2021-05-11 16:10:50 +02:00
Simon Ser
305ffb569c Parse ISUPPORT tokens in client 2021-05-11 16:03:16 +02:00
Simon Ser
8ab10cf2a5 lib/irc: escape/unescape everything in tags
Without the greedy flag on the regexp, String.replace will just
replace the first match.

While at it, also make sure to convert to a string when formatting
tag values. This allows tag values to be e.g. numbers.
2021-03-09 17:40:57 +01:00
Simon Ser
2d4409e7aa lib/irc: accept tags without value 2021-03-09 17:31:12 +01:00
Simon Ser
5fea13df0a Trigger client error if server doesn't support SASL 2021-03-09 09:44:48 +01:00
Simon Ser
194168c062 Display server messages in server buffer
References: https://todo.sr.ht/~emersion/gamja/21
2021-03-08 14:27:05 +01:00
Simon Ser
6430fa252a lib/client: log close code 2021-03-03 18:30:15 +01:00
Simon Ser
aa79067179 lib/client: extract fetchBatch function from roundtripChatHistory 2021-03-03 14:13:05 +01:00
Simon Ser
3536331f94 lib/client: throw error in send if disconnected 2021-03-03 09:37:26 +01:00
Simon Ser
8a5fa4d5c2 lib/client: reset state when websocket is closed 2021-03-03 09:36:48 +01:00
Simon Ser
80e0175d36 Make all resource paths relative
Closes: https://todo.sr.ht/~emersion/gamja/17
2021-03-02 22:46:48 +01:00
Simon Ser
b0a3cd23e4 Fix inverted condition in fetchHistoryBefore 2021-01-23 12:23:30 +01:00
Simon Ser
4d540d55ac Fix undefined CHATHISTORY_PAGE_SIZE 2021-01-23 12:19:40 +01:00
Simon Ser
1f640a4010 Log WebSocket constructor error in the console 2021-01-22 20:59:17 +01:00
Simon Ser
987f0b3389 Spread it like butter 2021-01-22 20:58:57 +01:00
Simon Ser
430373dd13 Move chat history operations into Client 2021-01-22 18:51:38 +01:00
Simon Ser
4e1f06b960 Move auto-reconnect logic into Client 2021-01-22 18:44:06 +01:00
Simon Ser
41cd2153cf Keep track of client status in Client 2021-01-22 18:29:22 +01:00
Simon Ser
0261bc11e7 Delay Client error event
Right now the caller won't receive the event, because it's triggered
before the function returns.
2021-01-22 17:50:52 +01:00
Simon Ser
06eb639ee9 Convert caps to lower case 2021-01-22 12:27:32 +01:00
Simon Ser
51523f4014 Extract network name from ISUPPORT 2021-01-22 11:43:47 +01:00
Simon Ser
b3f8b0c97d Add support for RPL_ISUPPORT 2021-01-22 11:34:04 +01:00
Simon Ser
0b03f9d767
Ignore RPL_TOPICWHOTIME
We don't need this piece of information yet, and we don't want to
clutter the server buffer with channel messages.
2020-09-03 11:36:08 +02:00
Simon Ser
516de5b3ea
Better handle registration errors 2020-08-25 11:42:40 +02:00
Simon Ser
bce216b7fb
Parse all CTCP messages
We display them nicely, however we never reply to them.
2020-08-13 16:04:39 +02:00
Simon Ser
917b348992
lib/irc: make isHighlight operate on messages
Makes it easier to re-use elsewhere.
2020-08-13 11:44:41 +02:00
Simon Ser
9df58971ea
Improve SASL error message 2020-08-10 15:01:48 +02:00
bbworld1
16582a6592
Add error reporting on connect and main page 2020-08-08 10:34:45 +02:00
Simon Ser
96c890f1f5
Strip ANSI escape sequences
References: https://todo.sr.ht/~emersion/gamja/11
2020-08-04 14:25:05 +02:00
Simon Ser
0157dd4cc6
Handle RPL_NOTOPIC 2020-08-03 18:59:54 +02:00
Simon Ser
36df984b09
Fetch all unread messages on reconnect 2020-07-15 18:21:09 +02:00
Simon Ser
3b0253855e
Mark FAIL as an error 2020-07-15 11:07:28 +02:00
Simon Ser
c9b07efc9c
Implement chathistory support 2020-07-10 14:37:38 +02:00
Simon Ser
7f0ca72d3e
Remove outdated TODO 2020-07-02 11:02:29 +02:00
Simon Ser
db13f34a40
Reply to PING 2020-07-01 12:12:56 +02:00
Simon Ser
99004165f2
Print IRC error messages in red 2020-06-29 14:29:31 +02:00
Simon Ser
abece1e3fd
Detect highlights 2020-06-29 11:08:47 +02:00
Simon Ser
deb8d4c01e
Avoid String.prototype.replaceAll
Not well supported in web browsers, except Firefox.
2020-06-28 15:40:57 +02:00
Simon Ser
0aa8cca483
Enable echo-message 2020-06-26 14:50:29 +02:00
Simon Ser
0bd2e10631
Add away indicator 2020-06-26 12:45:27 +02:00
Simon Ser
c59a8ff63c
Request caps on CAP NEW 2020-06-26 12:37:45 +02:00
Simon Ser
1807f29d2d
Parse RPL_MYINFO 2020-06-26 12:08:14 +02:00
Simon Ser
57ed3a13a3
Send WHO query when opening nick buffer 2020-06-26 12:00:10 +02:00
Simon Ser
2bb8f68f6f
Linkify messages 2020-06-25 17:27:24 +02:00
Simon Ser
df0981e8e0
Add isChannel 2020-06-24 15:52:33 +02:00
Simon Ser
b449ace4b4
Switch to react
Under the hood, preact is used to reduce dependency size. We still don't
have a build stage, so htm is used instead of JSX.
2020-06-24 14:37:49 +02:00
Simon Ser
62300746d3
Remove assets/ 2020-06-24 11:18:51 +02:00