Commit Graph

1565 Commits (707dc36cc2391d13973a2edc6442b8796cd66b96)

Author SHA1 Message Date
Michael Telatynski 287a3fd0cf
Fix issues with inhibited accessible focus outlines (#10579) 2023-04-12 12:49:12 +00:00
alunturner e03eac12c3
Add room and user avatars to rte (#10497)
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2023-04-06 08:43:49 +00:00
Kerry 2434749f65
Highlight event when any version triggered a highlight (#10502)
* check previous events pushactions when deciding to highlight

* test event highlight

* strict fix

* highlight edited text to red
2023-04-05 02:46:17 +00:00
alunturner 7a250f41ac
Update rte autocomplete styling (#10503)
* amend className to reflect usage
* move new class into file used by Send/Edit composers
* add border styling to autocomplete
2023-04-04 14:52:57 +01:00
alunturner 974dc35c41
Allow editing with RTE to overflow for autocomplete visibility (#10499) 2023-04-04 11:43:02 +01:00
Suguru Hirahara b06b602c5b
Remove an obsolete style block related to highlighting from `_IRCLayout.pcss` (#10451)
* Remove an obsolete style block related to highlighting from _IRCLayout.pcss

Initially it has been added with this commit 67249e1e9c for the implementation of IRC layout, but the border declarations for highlighting were removed with this commit 3a2aa9d96c to replace the 'border-left' declaration with the 'box-shadow' declaration.

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-04-04 11:07:53 +02:00
alunturner 6ac366ee5a
Style mentions as pills in rich text editor (#10448) 2023-04-03 10:16:29 +01:00
alunturner 6f791d28c8
Add mentions as links to rte (#10463)
* adds autocomplete behaviour for mentions in rich text editor
* allows adding mentions as links
* adds tests
2023-03-31 14:14:55 +01:00
Suguru Hirahara 232daaff68
Fix decryption failure bar covering the timeline (#10360)
* Use grid layout instead

- BEM naming style
- Increase block gap from 4px to 8px
- Use flexbox inside 'header' grid-area to let the buttons wrapped
- Use variables
- Remove 4px gap when one of the buttons is not rendered
- Change 'body' to 'message'
- Set 'align-self: start' to the icon and spinner

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Unset height of spinner

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Break lines at newline characters with white-space: pre-line

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Edit tests to check decryption failure bars on narrow timeline

- checkTimelineNarrow() looks for buttons by default
- Test indicator as well

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Remove a line

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Edit the test to have it check mx_EventTile_last only inside mx_RoomView_body

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Fix double underscores

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Fix double underscores - pcss

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Iterate - buttons at the bottom

- Set common spacing to buttons with variables
- Remove line breaks, yarn run i18n
- Set data-testid for headlines and buttons in case the tested strings would be displayed elsewhere simultaneously

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Check waiting headline as well

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Increase spacing between the message and the buttons

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* lint

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Increase block gap between wrapped buttons for clickability

Apply 8px between wrapped buttons

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Revert bottom margin of buttons which are not expected to be wrapped

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Check visibility instead of existence

This commit removes data-testid from headlines and data-testid-button and checks whether the elements are really visible, not overflowing the viewport.

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Remove redundant gap between 'mx_DecryptionFailureBar_start' and the bottom edge

This commit adds '.mx_DecryptionFailureBar--withEnd' class name to have it applied to the bar only if it has button(s). This way the bar is rendered with a flexbox and the row-gap declaration is respected only if there is a 'mx_DecryptionFailureBar--withEnd' element. The element  currently includes the button(s) only.

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* lint - prettier

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Have Percy take a snapshot of the bar loading spinner before checkTimelineNarrow()

The loading spinner is likely to disappear while checking the bar on the narrow timeline.

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
Co-authored-by: Kerry <kerrya@element.io>
2023-03-30 10:11:16 +01:00
alunturner 0fcb9d6a3e
Remove css causing list and paragraph issues (#10424) 2023-03-27 18:16:37 +01:00
Suguru Hirahara afb2cb93f2
Fix flaky Percy tests of `ReplyChain` (#10450)
* Fix flaky Percy tests of ReplyChain

- Add media query for percy on _ReplyChain.pcss to apply the same color to vertical strokes (border-left)of ReplyChain
- Use CSS variables for visibility
- Manage those variables on _common.pcss for maintainability

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Check receptSent as well for consistency

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Add a comment

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Specify zero spacing and remove list-style

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-03-27 12:13:25 +00:00
Janne Mareike Koschinski 63678603e0
Revert "Mentions as links rte (#10422)" (#10458)
This reverts commit 1af71089dd.
2023-03-27 12:57:05 +02:00
alunturner 1af71089dd
Mentions as links rte (#10422)
* bumps the RTE dependency to introduce user/room mention handling
* adds autocomplete behaviour to allow users to insert user and room mentions as links
* sets up tests for the autocomplete behaviour
2023-03-24 17:07:24 +00:00
Suguru Hirahara 8e1b9f46d4
Set expected value of line-height to expanded generic event list summary (GELS) spacer on IRC layout (#10211)
* Set expected line height to an expanded GELS line on IRC layout, add a test
* Add a test for compact modern/group layout
* Create a new test category on timeline.spec.ts
* Rename the class name as 'spacer'
* Add a test for GELS' spacer on bubble layout
---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
Co-authored-by: Germain <germain@souquet.com>
2023-03-24 12:57:32 +00:00
Suguru Hirahara d8acdd1750
Fix profile resizer to make first character of a line selectable in IRC layout (#10396) 2023-03-21 10:10:13 +01:00
Suguru Hirahara 587da5b7dc
Initialize line-height for room name on IRC layout (#10188) 2023-03-14 15:32:12 +01:00
Suguru Hirahara d244b9065c
Fix long display name overflowing reply tile on IRC layout (#10343)
* Prevent long name blowout from Replytile on IRC layout

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Add a test to check long strings do not overflow

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Sort declarations based on .mx_IRCLayout .mx_EventTile .mx_DisambiguatedProfile

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-03-10 10:47:14 +00:00
Suguru Hirahara f60f7a19af
Display redacted body on ThreadView in the same way as normal messages (#9016) 2023-03-08 12:23:41 +01:00
Suguru Hirahara fef8f3955f
Change --name-width on _IRCLayout.pcss based on ircDisplayNameWidth on Settings.tsx (#10285)
Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-03-07 13:32:38 +00:00
Suguru Hirahara 727afdc33a
Reduce bottom margin of ReplyChain on compact modern layout (#8972) 2023-03-06 09:19:38 +00:00
Suguru Hirahara ecebac6ea1
Align info EventTile and normal EventTile on IRC layout (#10197)
* fixes alignment issue in IRC layout
* adds cypress test for alignment

---------

Contributed-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
Signed-off-by: Alun Turner <alunturner@users.noreply.github.com>
2023-03-03 09:32:38 +00:00
Suguru Hirahara db7748b743
Fix the hidden view source toggle on IRC layout (#10266)
* Display view source toggle on IRC layout

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Add a test

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Merge tests

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Collapse hidden event source before checking clickability of view source toggle on IRC layout

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Select view source event under the edited line on the test

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* Fix the test

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

* lint

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>

---------

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-03-01 14:41:56 +00:00
Suguru Hirahara 9e5c4e95f9
Fix buttons on the room header being compressed due to long room name (#10155)
This PR adds the flex declaration to mx_RoomHeader_button to prevent the buttons from being compressed due to a long room name, copying the whole declarations from mx_RightPanel_headerButton for reference.

Signed-off-by: Suguru Hirahara <luixxiul@users.noreply.github.com>
2023-03-01 12:21:44 +00:00
alunturner 95223c87fe
Fix block code styling in rich text editor (#10246) 2023-02-28 10:08:53 +00:00
alunturner 41c8ab5e59
fix paragraph display for MD from plain text editor (#10071) 2023-02-03 13:55:12 +00:00
Florian Duros 1ad16fbeae
Fix new line for inline code (#10062) 2023-02-02 15:49:50 +00:00
Michael Telatynski 21c3967010
Revert "Member avatars without canvas" (#10057
* Revert "Apply more general fix for base avatar regressions (#10045)"

This reverts commit 371a3c0d36.

* Revert "Fix layout and visual regressions around default avatars (#10031)"

This reverts commit 0d1fce37b2.

* Revert "Member avatars without canvas (#9990)"

This reverts commit a8aa4de4b4.

* Update snapshots
2023-02-02 10:22:19 +00:00
alunturner 43e7870d92
Change ul list style to disc when editing message (#10043)
* ensures consistency between timeline, composer and "editor" composer
2023-02-02 09:09:52 +00:00
alunturner 39f5fc034f
Paragraph integration for rich text editor (#10008)
* integrates paragraph refactor in rich text editor
* minor CSS changes to accomodate this
* bumps rich text editor version to 0.22.0
2023-01-31 09:45:34 +00:00
Clark Fischer a8aa4de4b4
Member avatars without canvas (#9990)
* Strict typechecking fixes for Base/Member/Avatar

Update the core avatar files to pass `--strict --noImplicitAny` typechecks.

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>

* Add tests for Base/Member/Avatar

More thoroughly test the core avatar files. Not necessarily the most thorough,
but an improvement.

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>

* Extract TextAvatar from BaseAvatar

Extracted the fallback/textual avatar into its own component.

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>

* Use standard HTML for non-image avatars

Firefox users with `resistFingerprinting` enabled were seeing random noise
for rooms and users without avatars. There's no real reason to use data
URLs to present flat colors.

This converts non-image avatars to inline blocks with background colors.

See https://github.com/vector-im/element-web/issues/23936

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>

* Have pills use solid backgrounds rather than colored images

Similar to room and member avatars, pills now use colored pseudo-elements
rather than background images.

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>

---------

Signed-off-by: Clark Fischer <clark.fischer@gmail.com>
Co-authored-by: Andy Balaam <andy.balaam@matrix.org>
2023-01-30 09:50:08 +00:00
Mustafa Kapadia 3f766b3f0f
Issue Fix: Misaligned reply preview in thread composer (#9977) 2023-01-25 08:51:07 +01:00
Robin 9d0230b6ab
Show the room name in the room header during calls (#9942) 2023-01-20 08:45:39 -05:00
alunturner 9dbc5f3773
Add quotes to rich text editor (#9932)
* bump rich text editor to 0.20.0
* add new svg for the button
* show the button
* make the composer display look like the timeline display
2023-01-20 10:55:46 +00:00
alunturner a63da74f06
Add code blocks to rich text editor (#9921)
* Applies small changes to code block display in timeline
* Makes the composer code block look like the timeline display, but without line numbers
* Adds a button to allow code blocks to be implemented
* Adds tests for the new button
2023-01-19 15:49:21 +00:00
Florian Duros 314b2e7ba6
Add new style for inline code (#9936)
Add new style for inline code
2023-01-19 13:42:59 +00:00
alunturner 8a2e386531
Add disabled button state to rich text editor (#9930)
* add disabled css state
* conditionally apply disabled css state
* hides disabled tooltips
2023-01-19 09:24:29 +00:00
Janne Mareike Koschinski 4d2b27a96d
Fix broken threads list timestamp layout (#9922)
* Add option to show full identifier as tooltip on sender profiles
* Show full user id as tooltip on threads list entries
* Fix broken threads list timestamp layout

Previously, thread list timestamps would overflow
into the unread messages bubble on the right.

This is fixed by resetting the width of the
timestamp and ensuring both the timestamp and the
display name can shrink if necessary.
Both now also use ellipses if necessary.
2023-01-18 15:56:43 +01:00
Kerry 62913218d2
use 100% rather than auto with for reply tile width (#9924) 2023-01-18 14:57:58 +13:00
Janne Mareike Koschinski 9ef4e14385
Replace outdated css attribute (#9912) 2023-01-16 14:46:54 +01:00
alunturner 6052db1e8a
Add list functionality to rich text editor (#9871)
* adds buttons to toggle bulleted and numbered lists on and off
* adds icons for those buttons
* css changes to timeline display
* adds tests for the new buttons, refactors existing tests
2023-01-13 15:44:35 +00:00
Janne Mareike Koschinski cce506b1c1
Fix misaligned timestamps for thread roots which are emotes (#9875)
* Fix misaligned timestamps for thread roots which are emotes
* Use cross-browser variant instead of webkit-only variant for fill-available
2023-01-11 16:39:44 +01:00
Florian Duros a691e634b0
Add edit and remove actions to link in RTE (#9864)
Add edit and remove actions to link in RTE
2023-01-11 10:10:55 +00:00
Robin cb1af0d3de
Redesign the picture-in-picture window (#9800)
* Remove unnecessary PipContainer component

* Redesign the picture-in-picture window

* Add a hover effect to the controls

* Clarify that WidgetPip has call-specific behavior
2023-01-04 04:44:38 +00:00
Michael Weimann ecb3e7a197
Use compound Mic icons everywhere (#9849) 2023-01-02 13:36:58 +00:00
Florian Duros fe0273b1a6
Add link creation to rich text editor (#9775)
Add link creation to RTE
2022-12-23 11:34:15 +00:00
Germain bef8e077f6
Unify notifications panel event design (#9754) 2022-12-21 10:25:50 +00:00
Kerry d3ab11928b
Use compound colours for verification badges (#9794)
* update e2e colour variables to compound colours

* use e2e colour vars for e2e icons
2022-12-20 02:07:28 +00:00
Faye Duxovni 4724506320
Improve decryption error UI by consolidating error messages and providing instructions when possible (#9544)
* Improve decryption error UI by consolidating error messages and providing instructions when possible

* Fix TS strict errors

* Rename .scss to .pcss

* Avoid accessing clipboard, Cypress doesn't like it

* Display DecryptionFailureBar alongside other AuxPanel bars

* Add comments

* Add small margin off-screen for visible decryption failures

* Fix some more TS strict errors

* Add unit tests for DecryptionFailureBar

* Add button to resend key requests manually

* Remove references to matrix-js-sdk crypto internals

* Add hysteresis to visible decryption failures

* Add comment

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>

* Add comment

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>

* Don't create empty div if we're not showing resend requests button

* cancel updateSessions on unmount

* Update unit tests

* Fix lint and implicit any

* Simplify visible event bounds checking

* Adjust cypress test descriptions

* Add percy snapshots

* Update src/components/structures/TimelinePanel.tsx

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>

* Add comments on TimelinePanel IState

* comment

* Add names to percy snapshots

* Show Resend Key Requests button when there are sessions that haven't already been requested via this bar

* We no longer request keys from senders

* update i18n

* update expected text in cypress test

* don't download keys ourselves, update device info in response to updates from client

* fix ts strict errors

* visibledecryptionfailures undefined handling

* Fix implicitAny errors

Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2022-12-15 17:24:33 +00:00
Michael Weimann 526645c791
Apply prettier formatting 2022-12-12 12:24:14 +01:00
Florian Duros dec72c7683
Use icon component instead of mask-image for formatting buttons (#9732)
Use icon component instead of mask-image for formatting buttons
2022-12-09 17:01:03 +01:00