Thanks to visit codestin.com
Credit goes to github.com

Skip to content

SegmentedButton / Segment theming broken #1611

@andreaslydemann

Description

@andreaslydemann

The segmented button is using RMWC theme. Instead the theme of the button should fit with the rest of our theme in the application.

No theme prop set:
image

Theme prop set with "secondary":
image

Notice that in this case, the text color is correct but background color is still RMWC themed.

Example:

"dependencies": {
    "react": "^18.3.1",
    "react-dom": "^18.3.1",
    "@rmwc/segmented-button": "14.3.5",
}
import { Segment, SegmentedButton } from '@rmwc/segmented-button';

export const ViewSwitch = () => {
  return (
    <SegmentedButton selectType="single">
      <Segment
        label="Kortvisning"
        theme="secondary"
      />
      <Segment
        label="Listevisning"
        theme="secondary"
      />
    </SegmentedButton>
  );
};

Metadata

Metadata

Assignees

No one assigned

    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