Commit Graph

345 Commits

Author SHA1 Message Date
William Boman
658dc5a3a2 fix automatically closing sidebar on some mobile viewports
Co-authored-by: Pavel Djundik <github@xpaw.me>

Mobile viewports whose width is equal to the upper boundary
of the mobile viewport breakpoint would not automatically
close the sidebar when selecting an item in it.

Closes #2783.
2018-09-19 09:37:03 +02:00
Pavel Djundik
d63f0ccc50 Make userlist state consistent on mobile and desktop 2018-07-04 10:26:07 +03:00
Pavel Djundik
d178ac9749 Make context menus accessible with keyboard 2018-06-15 13:27:58 +03:00
Jay2k1
a0a2e91928 add highlight count to page title 2018-06-13 19:06:32 +02:00
Pavel Djundik
7a3008aec6 Synchronize number of highlighted messages to client
Also fixes #1791
2018-06-11 14:29:57 +03:00
Max Leiter
9c4c1d6d51 Allow connecting/disconnecting from networks in UI, closes #631 2018-06-09 16:32:21 -07:00
Jay2k1
d0284dc1b9 Remove else so join is always sent
Fixes #2472
2018-05-29 19:39:57 +02:00
Jérémie Astori
8edc1be7b5
Merge pull request #2414 from thelounge/xpaw/fix-2329
Fix join channel form not working
2018-05-15 01:19:38 -04:00
Pavel Djundik
f23c063b71 Fix join channel form not working
Fixes #2329
2018-05-02 17:09:32 +03:00
Pavel Djundik
94f1d8dde0 Override server provided defaults with parameters passed in the URL if they match the data type 2018-05-02 13:08:00 +03:00
Pavel Djundik
426893077f Add prefix to channels from connect window
Fixes #2327
2018-05-02 13:08:00 +03:00
Pavel Djundik
14cc8b7827 Use attr() on user-controlled data
See https://www.reddit.com/r/javascript/comments/8f57i1/psa_there_are_over_1000_people_in_the_us_named/dy0rib2/
2018-04-28 11:19:49 +03:00
Pavel Djundik
a392a08c7a Remove nick editor 2018-04-15 22:17:30 +03:00
Pavel Djundik
f86d73972d Implement network editing UI and object updating 2018-04-12 10:38:35 +03:00
Jérémie Astori
ac02bd370b
Do not compute preview "More" buttons on mobile 2018-04-09 21:39:40 -04:00
Jérémie Astori
dbabdd83dc
Lighten the "More" button handler when checks are not necessary 2018-04-09 21:39:40 -04:00
Jérémie Astori
7355db94d6
Improve UI of previews
- Remove margins around thumbnails and images, increase radius, etc. for a fresher look overall
- Increase preview body contrast just enough to pass AA standards
- Add a `More`/`Less` button to expand previews that take more than one line. Button is added only when necessary
- Use a zoom-in cursor on hover for thumbnails
- Improve preview message errors
2018-04-09 21:39:38 -04:00
Jérémie Astori
7591088982
Merge pull request #2290 from lol768/feature/join-alias-query-param
Add ?channels=x,y,z alias for ?join=x,y,z
2018-03-31 14:05:25 -04:00
Jérémie Astori
fe08547d6b
Merge pull request #2289 from lol768/master
Add auto-prepend behaviour for unprefixed channel names
2018-03-29 01:19:45 -04:00
Al McKinlay
ce08201d13
Merge pull request #1878 from thelounge/yamanickill/refactor-context-menu
Pull context menu code out of lounge.js and make it more generic
2018-03-29 06:04:24 +01:00
Jérémie Astori
7d057a9ca7
Fix bug preventing to click on channels/queries
This bug is present both in channel list, #channel in messages, etc.
2018-03-27 19:28:20 -04:00
Al McKinlay
edba18375f
Merge pull request #2286 from thelounge/xpaw/input-history
Reimplement input history
2018-03-27 17:38:49 +01:00
Pavel Djundik
a2440e665f Do not close sidebar when collapsing networks
Fixes #2293
2018-03-27 12:07:19 +03:00
Pavel Djundik
3aea9d34e9 Reimplement input history 2018-03-26 11:23:10 +03:00
Al McKinlay
1dc356a8f2 Pull context menu code out of lounge.js and make it more generic
Add separate call for divider in context menu factory
2018-03-26 09:08:43 +01:00
Adam Williams
25dee77600 Add auto-prepend behaviour for unprefixed channels
This change adds behaviour to automatically prefix channel names passed in via the "?join=x,y,z" query string/search parameter which do not appear to include an appropriate channel symbol.
2018-03-24 22:17:32 +00:00
Adam Williams
950bad1d7a Add ?channels=x,y,z alias for ?join=x,y,z
For backwards compat. with Iris and other systems.
2018-03-24 16:54:26 +00:00
Pavel Djundik
6f47a78afd Unfocus input on touch devices to close the keyboard
Fixes #2257
2018-03-22 12:47:15 +02:00
Jérémie Astori
dbe81f1e59
Merge pull request #2254 from thelounge/astorije/sign-out-settings
Empty local storage on sign out and move the sign out button to the settings
2018-03-20 21:06:44 -04:00
Pavel Djundik
528d2b5fb7
Scroll channel list only when using keybinds 2018-03-20 19:27:07 -04:00
Jérémie Astori
d1548572d4
Move the sign out button to the settings and empty local storage on sign out
This change improves privacy/security by ensuring all local storage (which includes settings, etc.) is destroyed on sign out or when revoking a remote session. Because signing out is now more "risky", the button has been moved to the settings along with other existing sessions.

This commit:

- Removes the power/sign-out icon from the sidebar footer (gives additional room for when the admin panel gets added)
- Adds a "Sign out" button next to the current session info in the settings session list
- Renames "Disconnect" buttons into "Revoke" to better clarify the intent (I will admit that I borrowed the wording from Telegram)
- Fixes incorrect `localStorage.remove` method
- Uses Sinon.js to mock wrappers for `window.localStorage` and `window.location` (does not mock those themselves, in the "Do not mock what you do not own" fashion, mock our layer instead). I expect we will be able to test a bit more from the UI with this. A good next candidate will be the `mockLogger` things.
2018-03-20 01:52:22 -04:00
Pavel Djundik
5bb0b198e6 Disable scrolling through sidebar overlay 2018-03-17 11:35:33 +02:00
Jérémie Astori
c395e74e64
Merge pull request #2235 from thelounge/xpaw/store-sidebar-visibility
Store visibility status of sidebar menus
2018-03-16 23:57:24 -04:00
Pavel Djundik
7267f89377 Do not aggressively focus input when clicking anywhere 2018-03-16 18:07:19 +02:00
Pavel Djundik
103c3395dd Store visibility status of sidebar menus
Fixes #51
Closes #1606
2018-03-16 09:03:16 +02:00
Jérémie Astori
00bca229f0
Enforce object literal shorthand syntax with ESLint 2018-03-15 00:22:09 -04:00
Pavel Djundik
b01e01bc19 Convert most of the layout to flexbox, make sidebar an overlay 2018-03-11 00:23:43 +02:00
dgw
e5a6417a82 Scroll to newly joined/activated channels
Add a new utility function for scrolling elements into view with the
same, consistent options, and use it for both the new channel scrolling
behavior and the existing userlist scroll code.

Implements & resolves #2062
2018-03-08 10:30:07 -06:00
Pavel Djundik
bb066ecb02 Do not listen to touch events until client is initialized
Fixes #2148
2018-03-07 10:02:02 +02:00
Pavel Djundik
e719e4ff81 Cleanup chat/userlist to use flexbox, fix a couple of bugs 2018-03-05 18:17:13 +02:00
Jérémie Astori
25517f3ad7
Move the user list client code to its own file 2018-02-26 01:36:34 -05:00
Pavel Djundik
bd2907c13f Use document.body when wrapping it in a jquery object 2018-02-23 21:22:05 +02:00
Al McKinlay
c09f06fccc Change isOpInChannel to allow multiple different user roles 2018-02-21 15:05:02 +00:00
Pavel Djundik
c733e72e7a Auto-fix code for padding-line-between-statements rule 2018-02-20 09:28:04 +02:00
Pavel Djundik
7724762c14 Fix active class not being removed when switching channels 2018-02-19 21:05:05 +02:00
Pavel Djundik
a3e448acf5 Enable no-var rule
Fixes #1961
2018-02-19 19:49:39 +02:00
Pavel Djundik
e448dc711c Turn channel list into an accessible tablist 2018-02-18 09:58:44 +02:00
Pavel Djundik
6d6b5cb2a9 Remove deprecated jQuery calls
Fixes #2011
2018-02-01 12:15:51 +02:00
Pavel Djundik
e77de3315a Prevent user contextmenu from opening while selecting text 2018-01-09 18:16:20 +02:00
Pavel Djundik
bd9e219d92 Set aria-label on main input 2017-12-27 22:34:19 +02:00