File tree Expand file tree Collapse file tree 2 files changed +21
-0
lines changed Expand file tree Collapse file tree 2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change
1
+ import React from "react" ;
2
+ import "./css/main.css" ;
3
+ import styled from "styled-components" ;
4
+ import { getThemeValue } from "./ThemeProvider" ;
5
+
6
+ export const Background = ( props : { children : React . ReactNode } ) => {
7
+ const { children } = props ;
8
+ return < StyledBackground > { children } </ StyledBackground > ;
9
+ } ;
10
+
11
+ const StyledBackground = styled . div `
12
+ background-color: ${ ( props ) =>
13
+ props . theme . background ?? getThemeValue ( "background" ) } ;
14
+ color: ${ ( props ) => props . theme . text ?? getThemeValue ( "text" ) } ;
15
+ min-height: 100vh;
16
+ display: flex;
17
+ flex-direction: column;
18
+ align-items: center;
19
+ justify-content: flex-start;
20
+ ` ;
Original file line number Diff line number Diff line change 1
1
// MARK: Component imports
2
2
3
3
export { Button , type ButtonProps } from './components/Button' ;
4
+ export { Background } from './components/Background' ;
4
5
export { TextField , type TextFieldProps } from './components/TextField' ;
5
6
export { Text , type TextProps } from './components/Text' ;
6
7
export { ThemeProvider } from './components/ThemeProvider' ;
You can’t perform that action at this time.
0 commit comments