Skip to content
This repository was archived by the owner on Jan 30, 2025. It is now read-only.
This repository was archived by the owner on Jan 30, 2025. It is now read-only.

Provide styling possibilities #10

Closed
@maheichyk

Description

@maheichyk

Is your feature request related to a problem? Please describe.

We tried to use module API to partially implement sidebar changes described in #8.

The following was applied:

  • Custom module created and installed
  • Simple component was added to the Element menu as an extension point that uses ModuleRunner.instance.invoke to load and render extra sidebar button with menu from a custom module
  • Sidebar button with menu is using matrix-react-sdk components like SpaceButton, IconizedContextMenu etc to make the UI to look like an Element. To be able to use these components matrix-react-sdk was added as dependency to the custom module and some dependencies where updated in matrix-react-sdk-module-api to be as in matrix-react-sdk for the code to compile

While these steps allow to add a sidebar button it seems that it is currently not possible to provide a custom styling for components used from matrix-react-sdk. In particular a sidebar button (SpaceButton) needs a custom icon and to be able to use styles from matrix-react-sdk like here: https://github.com/matrix-org/matrix-react-sdk/blob/0d1fce37b22c0565d25c517ad8e50ff42cab78ff/res/css/structures/_SpacePanel.pcss#L199-L226

Would be great if module system could allow to apply custom styling to matrix-react-sdk components and in general to new components added by custom module.

Describe the solution you'd like

Styling is possible in a similar way it is done in matrix-react-sdk: https://github.com/matrix-org/matrix-react-sdk/tree/develop/res

Describe alternatives you've considered

To apply custom changes to Element fork, but this is what we want to avoid and to use module system instead.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions