Commit Graph

219 Commits

Author SHA1 Message Date
Eugen Rochko bd0791d800
Add redraft function (#7735)
* Add redraft function

Fix #7010

* Add explicit confirmation

* Add explicit confirmation message
2018-06-05 00:17:38 +02:00
Eugen Rochko 1bbe81030c
Display numbers in account header using shortNumberFormat for consistency (#7723) 2018-06-04 05:15:50 +02:00
Mélanie Chauvel (ariasuni) 691107263c Put the CW field between the toot we are replying to and the toot field (#7508)
* Remove Collapsable and use CSS instead

* Put the CW field between the toot we are replying to and the toot field

* Use same spacing between all fields in the composing column
2018-05-31 15:16:31 +02:00
Eugen Rochko 1a7a74ff76
Improve getting started column (#7676)
* Adjust footer of getting started column

- Improved style
- Moved hotkeys, about this instance and logout to footer
- Removed FAQ, User Guide, Apps links
- Use hamburger icon for the column

* Add edit profile action button to profile and more to dropdown

* Add "Trending now" to getting started column

* Add preferences/security links on mobile layout
2018-05-30 18:41:47 +02:00
Eugen Rochko 90b64c0069
Always display tab navigation on local/federated timeline even when empty (#7663)
Fix #7659
2018-05-29 02:01:04 +02:00
Eugen Rochko 22e067bf5c
Use real container width in MediaGallery srcSet (#7571)
Fix #7568
2018-05-21 16:04:01 +02:00
Yamagishi Kazutoshi d9b2f84c92 Open video modal on public UI (#7469) 2018-05-13 13:48:14 +02:00
Yamagishi Kazutoshi e0b1e17bd0 Show media modal on public timeline (#7413) 2018-05-08 13:33:09 +02:00
ThibG e06fbc4fcf Fixes/rollback scroll changes (#7387)
* Revert "Do not re-position scroll when loading more (inserting items from below) (#7344)"

This reverts commit 8c601b54cc.

* Revert "Prevent timeline from moving when cursor is hovering over it (fixes #7278) (#7327)"

This reverts commit 58852695c8.
2018-05-06 22:26:39 +02:00
ThibG ef7d64c801 Dropdowns accessibility (#7318)
* Mark currently selected privacy setting in privacy dropdown

* Prevent Enter keypresses from triggering dropdown display toggle twice

* Give focus to first/selected item of dropdown menus

* Implement keyboard navigation in privacy dropdown

* Implement keyboard navigation in generic dropdown menus
2018-05-04 22:13:26 +02:00
ThibG 8c601b54cc Do not re-position scroll when loading more (inserting items from below) (#7344) 2018-05-03 22:32:05 +02:00
ThibG 58852695c8 Prevent timeline from moving when cursor is hovering over it (fixes #7278) (#7327) 2018-05-03 12:09:11 +02:00
Eugen Rochko 660cb058e1
Improve relative timestamps in web UI (#7233)
Use short instead of numeric month, display year when different year

E.g.: "Apr 4" instead of "4/4", "Apr 4, 2017" if different year
2018-04-23 00:43:53 +02:00
unarist 84214b864c Ignore keyevents during text composition (#7205)
KeyboardEvent.key may be physical key name (Escape, Tab, etc.)
even in text composition and it causes hotkeys or suggestion selection.
So we need to check e.which or e.isComposing.

Checking e.which also allows us to avoid Esc key on compositionend in Safari.
2018-04-20 18:36:52 +02:00
TakesxiSximada 23106844a1 Fix the hot key (j, k) does not function correctly when there is a pinned toot in account timeline. (#7202)
* Fix the hot key (j, k) does not function correctly when there is a pinned toot in account timeline.

* Fix typo

* Add custom attribute prefix
2018-04-20 18:14:21 +02:00
mayaeh ee2e0f694a Fix #6157: boosting own private toots (#7200)
* Fix boosting own private toots.

* Run yarn manage:translations and update Japanese translations.
2018-04-20 14:58:33 +02:00
unarist 4e35ce8269 Fix Esc hotkey behavior (#7199)
This fixes following cases which causes hotkey action accidentally:

* hitting Esc key to cancel text composition (mostly in CJK)

  Although events on cancelling composition are still heavily
  browser / input method dependent, but this implementation would
  covers current UI Events spec and some exceptions.

* hitting Esc key to close autocomplete suggestions

This PR changes to use keydown event instead of keyup event as well as other hotkeys.
2018-04-20 14:04:16 +02:00
Neil Moore fad7b9f5f2 Adds keyboard hotkey for revealing/hiding statuses (#7173)
Resolves #5550
2018-04-18 03:33:59 +02:00
ThibG e5dd385431 Allow boosting own private toots (#6157)
* Adjust policy to allow boosting own private toots

* Add ability to reblog private toots from dropdown menu
2018-04-17 23:35:45 +02:00
ThibG 7e0aed398f Fix scrolling behavior (#7151)
* Update React.JS

* Use React's new lifecycles for scrollable lists

* Clean up dead code

* Make CodeClimate happy
2018-04-16 21:04:24 +02:00
Eugen Rochko 45c9f16f71
Improve load gap styling in web UI (#7100) 2018-04-10 17:12:10 +02:00
Emelia Smith 904a2479dd Feature: Direct message from Statuses (#7089)
* Fix: Switching between composing direct message and mention from menus

Previously clicking "direct message" followed by "mention" resulted in the composed status staying as "direct", along with weird spacing of items in the text area. This attempts to fix that.

* Fix: Add missing proptype check for onMention in Status component

* Add the ability to send a direct message to a user from the menu on Statuses

* Add space between "Embed" and "Mention" on expanded statuses menu
2018-04-09 17:09:11 +02:00
unarist fb3dc00dda Ignore AbortError when cancelled sharing (#6978)
`navigator.share()` rejects Promise if user cancelled sharing, and it may
print it as an error on JavaScript console.

This patch ignores it and prints other errors on the console.
2018-03-31 13:16:38 +02:00
ThibG a6c129ddbd Add some UI for user-defined domain blocks (#6628)
* Keep list of blocked domains

Might be overkill, but I'm trying to follow the same logic as for blocked users

* Add basic domain block UI

* Add the domain blocks UI to Getting Started

* Fix undefined URL in `fetchDomainBlocks`

* Update all known users' domain_blocking relationship instead of just one's
2018-03-30 12:38:00 +02:00
Stephen Burgess 18965cb0e6 feat(ShowMore): Add classname to show more/show less button (#6904) 2018-03-26 13:59:44 +02:00
Akihiko Odaki 9a1a55ce52 Allow clients to fetch statuses made while they were offline (#6876) 2018-03-24 15:25:15 +01:00
Akihiko Odaki ff7941e652 Show media modal on public pages (#6801) 2018-03-24 12:52:26 +01:00
Eugen Rochko 8bf3e750ab
Fix #6757: Adjust RTL styles for landing page (#6768) 2018-03-13 08:14:08 +01:00
Eugen Rochko 56eb5c3f34
Fix focal point cropping in MediaGallery, fix focal point modal (#6740)
* Use object-position with object-fit instead of JS top/left

* Fix focal point modal
2018-03-11 15:12:33 +01:00
Eugen Rochko b6003afcdb
Add show more/less toggle for entire threads in web UI (#6733)
Fix #1258
2018-03-11 09:52:59 +01:00
Eugen Rochko 11697d6894
Fix thumbnail not filling entire space sometimes (#6709) 2018-03-09 11:33:05 +01:00
Eugen Rochko b79ab15859
When enabled, always display media in gallery. Also: click to reveal (#6692)
Fix #6677
2018-03-08 08:57:21 +01:00
Eugen Rochko 77406d3a09
Display AttachmentList in notifications (#6693) 2018-03-08 08:22:04 +01:00
Eugen Rochko 86a9de6753
Display AttachmentList in timelines in compact style when media missing (#6680) 2018-03-08 04:54:26 +01:00
Eugen Rochko b170627ceb
Fix cover behaviour of thumbnails that are wider than taller (#6678) 2018-03-07 12:02:05 +01:00
Eugen Rochko cfa9b6e13a
Remove text requirement when media attached from statuses (#6672) 2018-03-07 08:28:52 +01:00
Akihiko Odaki 913a38111f Remove pointer events on the entire UI when a dropdown menu is open (#6648)
* Remove pointer events on the entire UI when a dropdown menu is open

This prevents operations to change the location of the menu such as
scrolling.

* Fix mistake from merge
2018-03-07 02:26:43 +01:00
Akihiko Odaki b0664a5e6c Replace onScrollToBottom with onLoadMore (#6615)
onScrollToBottom was a function to run instead of onScrollToTop and
onScroll when scrolling to the bottom. The behavior to prevent
onScrollToTop was inconvenient because the viewport can be at the bottom
and at the top at the same time if the viewport is larger than the
container.

onScrollToBottom was also called when the button to load more is clicked
on contray to the name suggests, which led notifications and
status_list_container components to mark the scrolled location is not at
the top mistakenly.

onLoadMore is a replacement for onScrollToBottom. It will be called
independently from onScrollToTop and onScroll.
2018-03-05 19:31:40 +01:00
Akihiko Odaki f6a8d835d3 Place dropdown menu top if it is closer to the bottom of the viewport (#6641) 2018-03-05 19:28:56 +01:00
Yuto Tokunaga 4e929b2d17 [RFC] Improved media modal (#5956)
* Improved media modal

ImageLoader: Impliment pinch zoom by CSS `transform: scale(X)`
ImageLoader: Impliment panning by CSS `overflow: scroll`
ImageLoader: Larger image
MediaModal: Larger close button
MediaModal: Close the modal by swiping vertically
MediaModal: Show/hide close button and right/left navigation on tapping image
MediaModal: Change the `pointer-event` CSS prpp to get more blank space to close the modal
ImageLoader: Zoom/reset zoom on double tap
MediaModal: disable vertical swiping while horizontally swiped
ImageLoader: prevent propagating touchmove event to MediaModal
MediaModal: Adjust size and potision of buttons
ImageLoader: Adjust scroll potision on pinch zoom

* Remove "swipe to close" and "double tap to zoom" features

* remove unused prop and functions

removed `onScroll` prop and `handleScroll` func in ImageLoader

* separate zoom functionary to ZoomableImage component

adjust styling of ImageLoader
add styling for ZoomableImage

* adjust size and potision of close button of media modal

* Fix for gif video

add `onClick` prop to ExtendedVideoPlayer
specify `onClick` prop to video tag for switching nav of `MediaModal`
add `.video-modal` class to scss to separate styling for `VideoModal`

* fix styling for centering

specify height of `ZoomableImage` by pixel
clean styling for `ImageLoader`

* fix lint errors

* small fix

* fixed designated parts
2018-03-04 20:32:24 +01:00
Akihiko Odaki 460e380d38 Implement tag auto-completion by history (#6621)
This is a functionality similar to one implemented in Pawoo:
21a3c70f80
2018-03-04 20:27:25 +01:00
Eugen Rochko 9110db41c5
Federate pinned statuses over ActivityPub (#6610)
* Federate pinned statuses over ActivityPub

* Display pinned toots in web UI

Fix #6117

* Fix migration

* Fix tests

* Update outbox_serializer.rb

* Update remove_serializer.rb

* Update add_serializer.rb

* Update fetch_featured_collection_service.rb
2018-03-04 09:19:11 +01:00
Eugen Rochko 036dd98abb
Responsively enforce 16:9 ratio on all media thumbnails in web UI (#6590)
* Responsively enforce 16:9 ratio on all media thumbnails in web UI

Also change video player behaviour to "contain" rather than
"cover" videos that don't fit the ratio, unlike images and GIFs,
it's expected that a video is shown fully.

* Fix spacing issues and remove floor

* Remove floor
2018-03-02 07:00:04 +01:00
Eugen Rochko 90f12f2e5a
Focal points (#6520)
* Add focus param to media API, center thumbnails on focus point

* Add UI for setting a focal point

* Improve focal point icon on upload item

* Use focal point in upload preview

* Add focalPoint property to ActivityPub

* Don't show focal point button for non-image attachments
2018-02-22 00:35:46 +01:00
Eugen Rochko cbb69d41f6
Fix media spoiler design (#6507)
- 4px rounded corners on media attachments
- Better colors/contrast for CW/media spoiler on public pages
- Fix vertical alignment of "Show more" button
- Fix layout jump when unhiding standalone media
2018-02-19 02:39:18 +01:00
abcang ecdac9017e Fix media button type (#6478) 2018-02-15 04:40:42 +01:00
Eugen Rochko 76f3d5d16b
Add preference to always display sensitive media (#6448) 2018-02-09 00:26:57 +01:00
takayamaki d75d2a9f99 fix ColumnBackButtonSlim should extended from ColumnBackButton (#6417) 2018-02-03 18:41:51 +01:00
abcang ffb2b8ef8c Fix button hiding when header title is too long (#6406) 2018-02-01 17:17:17 +01:00
Eugen Rochko 7badad7797
Fix home regeneration (#6251)
* Fix regeneration marker not being removed after completion

* Return HTTP 206 from /api/v1/timelines/home if regeneration in progress
Prioritize RegenerationWorker by putting it into default queue

* Display loading indicator and poll home timeline while it regenerates

* Add graphic to regeneration message

* Make "not found" indicator consistent with home regeneration
2018-01-17 23:56:03 +01:00