Commit graph

286 commits

Author SHA1 Message Date
ThibG
365f875f57 Disable the underlying button element when an ItemButton is disabled (#10194)
Fixes #10191
2019-03-06 15:10:32 +01:00
Eugen Rochko
9cae3a3b48 Fix poll options not rendering text after vote/refresh (#10189)
* Fix poll options not rendering text after vote/refresh

* Fix poll options not showing up on public pages

* Fix code style issue
2019-03-06 05:35:52 +01:00
Eugen Rochko
73d3bb4a2c Render unicode emoji in polls using emoji pack (#10185) 2019-03-06 03:57:46 +01:00
Eugen Rochko
1321801577 Fix various issues in polls (#10165)
* Fix ActivityPub poll results being serialized even with hide_totals

* Fix poll refresh button having a different font size

* Display poll in OpenGraph description

* Fix NoMethodError when serializing votes

Regression from #10158

* Fix polls on public pages being broken for non-logged-in users

* Do not show time remaining if poll has no expiration date
2019-03-05 03:51:18 +01:00
ThibG
674d232cd1 Display closed polls as such (#10156) 2019-03-04 22:52:41 +01:00
ThibG
4987602069 Fixes to the polls UI (#10150)
* Allow unselecting choices in multiple choice polls

* Properly disable checkboxes/radio buttons for polls in public pages

* Visually differentiate checkboxes and radio buttons
2019-03-04 01:54:14 +01:00
Eugen Rochko
21246d861e Fix web UI crash on page load when detailed status has a poll (#10139) 2019-03-03 23:45:02 +01:00
Eugen Rochko
4a3acdc916 Add polls (#10111)
* Add polls

Fix #1629

* Add tests

* Fixes

* Change API for creating polls

* Use name instead of content for votes

* Remove poll validation for remote polls

* Add polls to public pages

* When updating the poll, update options just in case they were changed

* Fix public pages showing both poll and other media
2019-03-03 22:18:23 +01:00
ThibG
8a8e476a32 Fix crash when conversations have no valid participants (#10078)
* Never return empty participants for conversations

Fixes #10068

* Fix client-side crash when conversations have no participants
2019-02-19 20:00:41 +01:00
Eugen Rochko
6534acc019 Change buttons on timeline preview to open the interaction dialog (#10054)
Fix #9922
2019-02-15 19:43:09 +01:00
Eugen Rochko
4b9df07eac Change conversations to always show names of other participants (#10047)
Fix #9190
2019-02-15 16:08:48 +01:00
rinsuki
1a12ef6099 Fix breaks when opening a reply tree in WebUI (#10046)
fix #10045
2019-02-14 17:03:01 +01:00
ThibG
98642fef2a Fix timeline jumps (#10001)
* Avoid two-step rendering of statuses as much as possible

Cache width shared by Video player, MediaGallery and Cards at the
ScrollableList level, pass it down through StatusList and Notifications.

* Adjust scroll when new preview cards appear

* Adjust scroll when statuses above the current scroll position are deleted
2019-02-11 13:19:59 +01:00
Eugen Rochko
12cb694634 Add "copy link" item to status action bars (#9983)
Fix #6848
2019-02-11 12:19:49 +09:00
ThibG
d66346eb0c Fix IntersectionObserverArticle not hiding some out-of-view items (#9982)
IntersectionObserverArticle is made to save on RAM by avoiding fully rendering
items that are far out of view. However, it did not work for items spawned
outside the intersection observer.
2019-02-06 23:36:43 +01:00
Eugen Rochko
77dc5cc132 Refactor icons in web UI to use Icon component (#9951)
* Refactor uses of icons to an Icon component in web UI

* Refactor options passed to the Icon component

* Make tests work with absolute component paths
2019-02-01 00:14:05 +01:00
Clar Charr
4fb1d8129d Replace unlock-alt icon with unlock (#9952) 2019-01-31 13:45:15 +01:00
Eugen Rochko
380b246728 Redesign public hashtag page to use a masonry layout (#9822) 2019-01-16 19:47:46 +01:00
ThibG
65c546f9b0 Make hashtag search results link to the hashtag URL (#9810)
Currently, middle-clicking on a hashtag search result will open a new
instance of the WebUI, which is inconsistent with middle-clicking on
an account result, or a hashtag in a toot.
2019-01-14 23:29:21 +01:00
kedama
2a113f0185 Stop gifv timeline preview explicitly when open the media gallery. (#9749) 2019-01-07 15:54:40 +01:00
0xflotus
695de5d134 refactored account.js (#9739) 2019-01-07 08:23:09 +01:00
ThibG
631a91cbc0 Add quick links to the admin interface in the WebUI (#8545)
* Allow to show a specific status in the admin interface

* Let the front-end know the current account is a moderator

* Add admin links to status and account menus

If the current logged-in user is an admin, add quick links to the admin
interface in account and toot dropdown menu. Suggestion by @ashkitten

* Use @statuses.first instead of @statuses[0]
2019-01-04 13:10:43 +01:00
mayaeh
6429b2f94f Change the icon to "reply-all" when reply to other accounts (#9378) 2018-12-28 03:51:32 +01:00
ThibG
39e4cbe2dc Fix composer not getting focus after reply confirmation dialog (#9602)
The modal-handling code gives back focus to the element focused when the
modal opened. However, in the case of reply confirmation, it would do so
*after* the composer code itself requested focus.
2018-12-21 18:52:41 +01:00
ThibG
240d41b3ca Fix unnecessary loadMore calls when the end of a timeline has been reached (#9581)
Fixes #9568
2018-12-19 22:23:16 +01:00
kedama
f579f1b10e Back to the getting-started when pins the timeline. (#9561) 2018-12-18 16:43:50 +01:00
ThibG
513f59726a Various fixes to scrollable lists and media gallery (#9501)
* Always use the scrollable class for the ScrollList component

Fixes #9499 as well as empty timelines' scrollbar “blinking”
between loading state and empty state.

* Do not display empty message when the list is known to have more elements

Fixes #9500

* Fix LoadMore usage in account media gallery

(Even though that codepath is probably never actually used…)

* Make account media gallery more consistent with account timeline

Fixes #9498

Display “load more” more consistently, add a loading indicator on first load.

* Fix “load more” button when no data has been fetched
2018-12-12 22:32:44 +01:00
Les Orchard
4e067b1bd0 Only consider mouse move in scrolling on item insertion (#9262)
Fixes #9259
2018-11-11 23:20:20 +01:00
Les Orchard
59ecfbd28c Identify manual scrolling to cancel scroll to top reset on mouse idle (#9245) 2018-11-09 18:06:43 +01:00
Eugen Rochko
9a32abcbac Use local instead of global loading indicator for timelines, account timelines (#9224)
So that opening a profile feels faster. Also, pinned toots are not
shown before other toots have loaded. Also, if no toots are loaded,
added empty message
2018-11-08 21:35:06 +01:00
Eugen Rochko
142940f4c6 Add "Show thread" link to self-replies (#9228)
Fix #4716
2018-11-08 21:08:57 +01:00
Les Orchard
54bc905a57 Cancel list scroll reset after mouse move on wheel scroll (#9233)
- Use object properties rather than component state for
  mouseMovedRecently and scrollToTopOnMouseIdle flags

- Remove redundant scrollToTop prop call, also fixing an attempt to call
  an undefined prop.

Fixes #9217
2018-11-08 18:45:20 +01:00
Les Orchard
6e72dda7ef Temporarily hold timeline if mouse moved recently (fixes #8630) (#9200)
- On recent mouse movement, hold timeline position so statuses remain in
  place for interactions in progress.

- If the timeline had been scrolled to the top before mouse movement,
  restore scroll on mouse idle.
2018-11-05 18:59:41 +01:00
Eugen Rochko
766a808de4 Fix dimensions of preview cards, fix crash in web UI, fix warning (#9133) 2018-10-29 04:42:07 +01:00
Eugen Rochko
cf2ab9c394 Include preview cards in status entity in REST API (#9120)
* Include preview cards in status entity in REST API

* Display preview card in-stream

* Improve in-stream display of preview cards
2018-10-28 06:35:03 +01:00
Eugen Rochko
541fda5fc8 Show suggested follows on search screen in mobile layout (#9010)
Reminder: Suggestions were added in #7918 and are based on who you
interact with who you do not follow. E.g. if you boost someone a lot
from seeing other people's boosts of that person, it makes sense you
might be interested in following the original source; or if you reply
to someone a lot, maybe you'd want to follow them

Each suggestion can be dismissed
2018-10-23 00:08:39 +02:00
Eugen Rochko
a984d5a1c4 Revert "RTL: remove blank character inside bdi (#9038)" (#9056)
This reverts commit 4bfec4b32d.
2018-10-22 23:23:00 +02:00
Masoud Abkenar
4bfec4b32d RTL: remove blank character inside bdi (#9038)
* RTL: remove blank character inside bdi

* Update app/javascript/mastodon/components/display_name.js

Co-Authored-By: mabkenar <ampbox@gmail.com>
2018-10-22 01:04:32 +02:00
Eugen Rochko
9309e5981d Redesign direct messages column (#9022) 2018-10-20 02:23:58 +02:00
Eugen Rochko
c9b5168ebd Add conversations API (#8832)
* Add conversations API

* Add web UI for conversations

* Add test for conversations API

* Add tests for ConversationAccount

* Improve web UI

* Rename ConversationAccount to AccountConversation

* Remove conversations on block and mute

* Change last_status_id to be a denormalization of status_ids

* Add optimistic locking
2018-10-07 23:44:58 +02:00
Eugen Rochko
db1a581491 Double the threshold for "read more" functionality (#8835) 2018-10-01 03:38:10 +02:00
Eugen Rochko
ad0670fe87 Revert Font Awesome 5 upgrade (#8810)
* Revert "Fix some icon names changed by the Font Awesome 5. (#8796)"

This reverts commit c8a1e945d9.

* Revert "Migrate to font-awesome 5.0. (#8799)"

This reverts commit ae20afbc80.

* Revert "Fix some icons names, unavailable in fontawesome5 (free license). (#8792)"

This reverts commit 30b1bb0704.

* Revert "Update the icon name changed by the Font Awesome 5. (#8776)"

This reverts commit 84bcf89764.

* Revert "Add bot icon to bot avatars and migrate to newer version of Font Awesome (#8484)"

This reverts commit cc784f3c16.
2018-09-28 02:11:14 +02:00
Maciek Baron
4a2fe07e28 Add test for AutosuggestEmoji (#8805) 2018-09-27 20:35:58 +02:00
Naoki Kosaka
ae20afbc80 Migrate to font-awesome 5.0. (#8799) 2018-09-27 17:08:56 +02:00
Haelwenn Monnier
ec1119d2c9 Show "read more" link on overly long in-stream statuses (#8205)
Show "read more" link on overly long in-stream statuses
2018-09-27 17:04:33 +02:00
theboss
30b1bb0704 Fix some icons names, unavailable in fontawesome5 (free license). (#8792)
- pencil => pencil-alt
- sliders => sliders-h

related: #8484 #8776
2018-09-26 22:48:21 +09:00
ふぁぼ原
bb8afc4608 Add a new preference to always hide all media (#8569) 2018-09-25 05:09:35 +02:00
Maciek Baron
cc784f3c16 Add bot icon to bot avatars and migrate to newer version of Font Awesome (#8484)
* Migrate to newer version of Font Awesome

* Add bot icon to bot avatars
2018-09-25 05:08:55 +02:00
Yamagishi Kazutoshi
23ab704b2b Upgrade Babel to version 7.0.0 (#5925) 2018-09-14 17:59:48 +02:00
ThibG
0b39d19dbf Only focus first element of dropdown menus if using keyboard (#8679)
* Only focus first item of dropdown if it was opened via keyboard

* Improve keyboard VS mouse navigation of dropdown menus
2018-09-13 20:31:33 +02:00