React components library for building Origin marketplace user interface.
For components demo and props documentation - please visit storybook
Origin UI Core is a component of Energy Web Origin's SDK.
This package is available through the npm registry.
npm install @energyweb/origin-ui-core
yarn add @energyweb/origin-ui-core
Before installing and using the package - please make sure you have all peerDependencies installed:
"react": "17.0.2",
"react-router": "6.0.2",
"react-router-dom": "6.0.2",
"@emotion/react": "11.7.0",
"@emotion/styled": "11.6.0",
"emotion-theming": "11.0.0"
Proper styling and usage of this components depends on Material-UI theme provider setup. Here is the basic example of seting up the provider and using it in your app with pre-configured origin theme:
import React, { FC } from 'react';
import { makeOriginUiTheme } from '@energyweb/origin-ui-theme';
import StyledEngineProvider from '@mui/material/StyledEngineProvider';
import { ThemeProvider } from '@mui/material/styles';
export const OriginThemeProvider = ({ children }) => {
const originTheme = makeOriginUiTheme();
return (
<StyledEngineProvider injectFirst>
<ThemeProvider theme={originTheme}>
{children}
</ThemeProvider>
</StyledEngineProvider>
);
};
Then in your index.j(t)sx
or main.j(t)sx
:
ReactDOM.render(
<React.StrictMode>
<OriginThemeProvider>
<App />
</OriginThemeProvider>
</React.StrictMode>,
document.getElementById('root')
);
See contributing.md
EW-Origin is a component of the Energy Web Decentralized Operating System (EW-DOS).
The purpose of EW-DOS is to develop and deploy an open and decentralized digital operating system for the energy sector in support of a low-carbon, customer-centric energy future.
We develop blockchain technology, full-stack applications and middleware packages that facilitate participation of Distributed Energy Resources on the grid and create open market places for transparent and efficient renewable energy trading.
- To learn about more about the EW-DOS tech stack, see our documentation
For a deep-dive into the motivation and methodology behind our technical solutions, read our White Papers:
This project is licensed under the MIT License - see the LICENSE file for details