Commit Graph

90 Commits (37e613bb05d4e9bb9d83d9910bd1e46151e7341a)

Author SHA1 Message Date
Kerry 5a9c2e530a
Device manager - selectable device tile wrapper (PSG-637) (#9153)
* add selectabledevicetile wrapper

* set pointer cursor

* line up own device icon with new checkboxes
2022-08-09 13:07:25 +00:00
Kerry eb2e61e9cf
Device manager: generic settings subsection component (PSG-636) (#9147)
* add feature_new_device_manager labs flag

* add generic settings tab container

* settingstab section styles

* add session manager tab to user settings

* add sessions tab case to UserSettingDialog test

* fussy import ordering

* remove posthog tracking

* i18n

* add generic settings subsection component
2022-08-09 10:14:30 +02:00
Kerry ed67aec334
Device Manager - add new labsed session manager screen (PSG-636) (#9119)
* add feature_new_device_manager labs flag

* add generic settings tab container

* settingstab section styles

* add session manager tab to user settings

* add sessions tab case to UserSettingDialog test

* fussy import ordering

* remove posthog tracking

* i18n
2022-08-08 13:51:00 +00:00
Kerry 94f3168ab8
Device manager - New device tile info design (#9122)(PSG-637)
* redesign device tile info

* test DeviceTile except for broken date mocking

* mock dates the nice way, test lastactivity in device tile

* tweak spacing style

* update comment style in rethemendex

* i18n
2022-08-08 06:59:22 +00:00
Michael Weimann 27ba1e57e6
Update matrix-org/react (enzyme deprecation) (#9116) 2022-08-02 15:10:43 +02:00
Michael Telatynski d5db131eef
Spike AXE A11Y testing in Cypress (#9111)
* Spike AXE A11Y testing in Cypress

* Fix NewRoomIntro breaking html/aria list rules

* Fix HeaderButtons breaking aria role semantics rules

* missing type

* Switch left panel from aside to nav and include space panel

* Give the page a main heading of the room name when viewing a room

* Use header landmark on RoomHeader

* Improve aria attributes on composer when autocomplete is closed

* Fix aria-owns on RoomHeader

* Give Spinner an aria role

* Give server picker help button an aria label

* Improve auth aria attributes and semantics

* Improve heading semantics in use case selection screen

* Fix autocomplete attribute to be valid

* Fix heading semantics on login page

* Improve Cypress axe testing

* Add axe tests

* Stop synapse after the timeline tests

* Await spinners to fade before percy snapshotting timeline tests

* Improve naming of plugin

* Update snapshots

* Fix accidental heading change

* Fix double synapse stoppage

* Fix Cypress timeline avatar assertions to be DPI agnostic

* Fix aria attributes on date separators

* delint

* Update snapshots

* Revert style change

* Skip redundant call
2022-08-01 08:31:14 +01:00
Suguru Hirahara 814ca6811c
Improve font scaling panel style (#8887) 2022-06-25 14:20:01 +02:00
Suguru Hirahara 18c21d77cd
Remove references to mx_GroupLayout from scss files (#8875) 2022-06-20 18:55:47 +02:00
Travis Ralston e87bda9f37
Add an option to ignore (block) a user when reporting their events (#8471)
* Add an option to ignore (block) a user when reporting their events

This is primarily useful if the content being reported really doesn't belong on your screen, and the room moderators are slow to react.

Ideally we'd use the word "block" instead of "ignore", but we call it "ignore user" everywhere else. See https://github.com/vector-im/element-web/issues/19590 for further context on the word choice.

This change includes a minor refactor to the styles of labelled toggles (for reusability).

* Appease the linter

* Use a checkbox instead of toggle in the dialog

* Update classnames handling for toggle switch

* Appease the linter
2022-05-18 16:20:55 +00:00
James Salter fcc4d62ede
Fall back to untranslated string rather than showing missing translation error (#8609) 2022-05-16 13:28:24 +01:00
Robin 0b0e414fd4
Fix unresponsive notification toggles (#8549)
* Return consistently typed setting values from localStorage

* Watch notification toggles

* Test that it all works
2022-05-10 09:13:02 -04:00
Kerry 2c19d286ed
Eslint - require copyright header rule (#8514)
* bump eslint plugin to 0.5.2

Signed-off-by: Kerry Archibald <kerrya@element.io>

* add rule

Signed-off-by: Kerry Archibald <kerrya@element.io>

* add missing copyright headers

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix comment order

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-05-06 09:09:28 +00:00
Travis Ralston a987ead7d2 Step 8.1: Remove skinning setup from all tests 2022-03-28 14:02:31 -06:00
Travis Ralston fce36ec826
Delete groups (legacy communities system) (#8027)
* Remove deprecated feature_communities_v2_prototypes

* Update _components

* i18n

* delint

* Cut out a bit more dead code

* Carve into legacy components

* Carve into mostly the room list code

* Carve into instances of "groupId"

* Carve out more of what comes up with "groups"

* Carve out some settings

* ignore related groups state

* Remove instances of spacesEnabled

* Fix some obvious issues

* Remove now-unused css

* Fix variable naming for legacy components

* Update i18n

* Misc cleanup from manual review

* Update snapshot for changed flag

* Appease linters

* rethemedex

* Remove now-unused AddressPickerDialog

* Make ConfirmUserActionDialog's member a required prop

* Remove useless override from RightPanelStore

* Remove extraneous CSS

* Update i18n

* Demo: "Communities are now Spaces" landing page

* Restore linkify for group IDs

* Demo: Dialog on click for communities->spaces notice

* i18n for demos

* i18n post-merge

* Update copy

* Appease the linter

* Post-merge cleanup

* Re-add spaces_learn_more_url to the new SdkConfig place

* Round 1 of post-merge fixes

* i18n

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2022-03-22 23:07:37 +00:00
Kerry abc225d3c6
Unit test tsc fixes part 15 (#8104)
* fix ts issues in MPollBody test

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix ts issues in PollCreateDialog

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix settings components

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix DateSeparator

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix loosies

Signed-off-by: Kerry Archibald <kerrya@element.io>

* update tsconfig

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-03-22 11:32:35 +01:00
Šimon Brandner 8418b4fd71
Move `KeyboardShortcut` styling into a separate file (#8067) 2022-03-21 11:41:32 +00:00
Šimon Brandner 8d13e238b9
Keybinding code unification #6 (#8042) 2022-03-14 13:25:51 +00:00
Šimon Brandner a58b1e9d79
Document keyboard shortcuts (#7908) 2022-03-04 12:14:52 +00:00
Michael Telatynski f25e6813bb
Mandate use of js-sdk/src/matrix import over js-sdk/src (#7933) 2022-03-01 20:42:05 +00:00
Charlie Calendre 8103e606c4
Fix translation for keyboard shortcut displaynames (#7758) 2022-02-10 09:11:35 +00:00
Kerry 818fddd72c
Add customisation point to disable space creation (#7766)
* mock matchMedia in jest setup

Signed-off-by: Kerry Archibald <kerrya@element.io>

* use UIComponent.CreateSpaces in space panel

Signed-off-by: Kerry Archibald <kerrya@element.io>

* lint

Signed-off-by: Kerry Archibald <kerrya@element.io>

* hide add space in spacecontextmenu

Signed-off-by: Kerry Archibald <kerrya@element.io>

* use UIComponent customistations in space oom view add space button

Signed-off-by: Kerry Archibald <kerrya@element.io>

* copyright

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-02-09 17:21:40 +01:00
Kerry 292971dd0e
Upgrade to jest 27 (#7699)
* use jest@27.4.0, replace jest-environment-jsdom-sixteen with jest-environment-jsdom

Signed-off-by: Kerry Archibald <kerrya@element.io>

* polyfill setImmediate

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove done from async test cases

* useRealTimers in test relying on promise flushing

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove jest environment file

Signed-off-by: Kerry Archibald <kerrya@element.io>

* replace ts-jest mocked with jest utils mocked

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-02-02 13:02:17 +01:00
Šimon Brandner 57a5647079
Work towards unifying `KeyboardShortcuts` and `KeyBindingsDefaults` #1 (#7651) 2022-01-27 11:37:53 +00:00
Kerry b481fc069e
Wrapping component to show/hide UI based on UIFeature setting (#7585)
* add wrapping component for hiding UI

Signed-off-by: Kerry Archibald <kerrya@element.io>

* rename and move to components

Signed-off-by: Kerry Archibald <kerrya@element.io>

* prefix interface and add missing copyright

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove roomId prop

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-01-25 10:25:41 +01:00
Šimon Brandner 5f18e4888c
Improve the look of the keyboard settings tab (#7562)
* First cut of new keyboard shortcuts

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Remove unused code

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* i18n

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Amend shortcuts

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Improve CATEGORIES struct

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Add tests for registerShortcut()

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Simplifie code tiny bit

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Translate ALTERNATE_KEY_NAME

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Fix `key` usage

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Export components for tests

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>

* Write snapshot tests

Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-01-24 11:33:27 +00:00
Kerry fed53a268b
A11y - fix anchors-as-buttons (#7444)
* add link_inline accessiblebutton variant

* valid anchors in SecurityRoomSettingsTab

Signed-off-by: Kerry Archibald <kerrya@element.io>

* new room intro link button

Signed-off-by: Kerry Archibald <kerrya@element.io>

* replace anchor with button in rerequest encryption keys message

Signed-off-by: Kerry Archibald <kerrya@element.io>

* inline button in UrlPreviewSettings

Signed-off-by: Kerry Archibald <kerrya@element.io>

* ButtonResetDefault mixin

Signed-off-by: Kerry Archibald <kerrya@element.io>

* inline link buttons in TextForEvent

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in InviteDialog

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in DevToolsDialog

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in login/registration/reset pword flows

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix types after fixing anchors in devtools

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in MemberEventListSummary

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in ReactionsRow and RoomUpgrade

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in ReplyChain

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix more anchors

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix anchors in auth comps

* stylelint fixes

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove ignore of jsx-a11y rule that is not added yet

Signed-off-by: Kerry Archibald <kerrya@element.io>

* devtools style important explainer

Signed-off-by: Kerry Archibald <kerrya@element.io>

* translate button alt in devtools dialog

Signed-off-by: Kerry Archibald <kerrya@element.io>

* AccessibleButton is reactionsrow

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix viewsourcevent button placement, use AccessibleButton

Signed-off-by: Kerry Archibald <kerrya@element.io>

* use AccessibleButton in EventTile

Signed-off-by: Kerry Archibald <kerrya@element.io>

* unignore jsx-a11y/anchor-is-valid

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix lint issue in test jsx

Signed-off-by: Kerry Archibald <kerrya@element.io>

* update coment

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-01-07 10:40:53 +01:00
Kerry dc2d52c1f2
a11y - wrap notification level radios in fieldsets (#7471)
* notification settings radios table -> fieldset

Signed-off-by: Kerry Archibald <kerrya@element.io>

* aria-label for inputs

Signed-off-by: Kerry Archibald <kerrya@element.io>

* update tests for fielset

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove unneccessary wrapping div

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix stylelint

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-01-06 18:52:06 +01:00
Kerry 92ee02fe02
unit test Notifications.tsx (#7468)
Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-01-06 09:47:03 +00:00
Kerry 03f5a3c3e6
Associate room alias warning with public option in settings (#7430)
* add describedby to styledradiogroup description

Signed-off-by: Kerry Archibald <kerrya@element.io>

* alias warning in description

Signed-off-by: Kerry Archibald <kerrya@element.io>

* lint

Signed-off-by: Kerry Archibald <kerrya@element.io>

* update snapshot

Signed-off-by: Kerry Archibald <kerrya@element.io>
2022-01-03 09:55:09 +01:00
Travis Ralston e4b96cff1f Merge remote-tracking branch 'aaronraimist/sort-imports' into develop 2021-12-09 16:03:59 -07:00
Kerry 2e3f225520
Put room settings form elements in fieldsets (#7311)
* override default fieldset styles

Signed-off-by: Kerry Archibald <kerrya@element.io>

* SettingsFieldset component

Signed-off-by: Kerry Archibald <kerrya@element.io>

* test settings fieldset

Signed-off-by: Kerry Archibald <kerrya@element.io>

* refactor SettingsFlag styles

* use SettingsFieldset in room > securit settings

* use fieldset in urlpreviewsettings

Signed-off-by: Kerry Archibald <kerrya@element.io>

* use SettingsFieldset in AliasSettings

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fieldset in room > roles settings

Signed-off-by: Kerry Archibald <kerrya@element.io>

* css lint

Signed-off-by: Kerry Archibald <kerrya@element.io>

* run i18n

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fussy order

Signed-off-by: Kerry Archibald <kerrya@element.io>

* default export

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix copyright headers

Signed-off-by: Kerry Archibald <kerrya@element.io>
2021-12-09 18:44:22 +01:00
Aaron Raimist 7b94e13a84 Merge branch 'develop' into sort-imports
Signed-off-by: Aaron Raimist <aaron@raim.ist>
2021-12-09 08:34:20 +00:00
Andy Balaam 9c8e1d32e2
Rename mx_RadioButton to mx_StyledRadioButton to match class name (#7083) 2021-11-04 12:57:38 +00:00
Faye Duxovni 71244f3b3c
Add more checkbox styles (#7058)
Add a "kind" param for StyledCheckbox, allowing designers to choose different styles of checkbox as needed.  In addition to the preexisting default kind (now called Solid), there's an Outline kind with a green checkmark and a transparent fill.  This is used in the device trust view, since the default checkbox style looks too much like the green "verified" shield and it's awkward to have those next to each other.
2021-10-29 21:57:32 -04:00
Aaron Raimist bdc56be863
Auto fix
Signed-off-by: Aaron Raimist <aaron@raim.ist>
2021-10-22 17:23:37 -05:00
Andy Balaam 4b903b9fbd
Break ThemeChoicePanel into a separate component (#6998)
* Break ThemeChoicePanel into a separate component

* Tests for ThemeChoicePanel

* i18n fixes

* Fix copyright for ThemeChoicePanel
2021-10-20 14:58:27 +00:00
Andy Balaam 96bd052ecf
Improve visibility of font size chooser (#6988)
* Improve visibility of font size chooser

* Move slider dot sizes into variables

* Use a standard font size instead of percentage in Slider

* Use shorthand for padding in FontScalingPanel

* Change Slider text pos to px to be consistent when font changes

* Cleaner dot size for Slider selection
2021-10-20 13:41:27 +01:00
Andy Balaam 2582f6df23 Replace manual mock with jest.mock 2021-10-19 15:45:11 +01:00
Andy Balaam 4ad32b16ea Break out font size settings to a separate component 2021-10-19 14:50:09 +01:00
Andy Balaam a547ee4654 Break 'Cryptography' settings into a separate component 2021-10-15 16:02:44 +01:00