Skip to content

Demos

Basis example

Code Editor
render(
  <Theme name="sbanken">
    <Logo size={40} />
  </Theme>,
)

Basis example propMapping

Code Editor
const MyMapping = styled.div`
  .eufemia-theme__sbanken.eufemia-theme__prop-mapping--my-mapping {
    --color-sea-green: var(--sb-color-purple-alternative);
  }
`
const CustomComponent = styled(P)`
  color: var(--color-sea-green);
`
render(
  <MyMapping>
    <Theme name="sbanken">
      <Theme propMapping="my-mapping">
        <CustomComponent>Text with custom color</CustomComponent>
      </Theme>
    </Theme>
  </MyMapping>,
)
Error: Unexpected token when processing JSX children.