forked from hupe1980/gatsby-theme-material-ui
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
27 changed files
with
884 additions
and
698 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
{ | ||
"name": "gatsby-theme-material-ui-root", | ||
"version": "1.0.0", | ||
"name": "root", | ||
"private": true, | ||
"author": "[email protected]", | ||
"license": "MIT", | ||
|
@@ -25,6 +24,6 @@ | |
"www" | ||
], | ||
"devDependencies": { | ||
"lerna": "^3.13.4" | ||
"lerna": "^3.14.1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 3 additions & 11 deletions
14
packages/gatsby-theme-material-ui/src/components/button.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,5 @@ | ||
import React from 'react'; | ||
import MuiButton from '@material-ui/core/Button'; | ||
import Button from '@material-ui/core/Button'; | ||
|
||
import GatsbyLink from './gatsby-link'; | ||
import patchBaseButtonComponent from '../utils/patch-base-button-components'; | ||
|
||
function Button(props) { | ||
const { to, href } = props; | ||
const component = to || href ? GatsbyLink : 'button'; | ||
|
||
return <MuiButton component={component} {...props} />; | ||
} | ||
|
||
export default Button; | ||
export default patchBaseButtonComponent(Button); |
14 changes: 3 additions & 11 deletions
14
packages/gatsby-theme-material-ui/src/components/card-action-area.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,5 @@ | ||
import React from 'react'; | ||
import MuiCardActionArea from '@material-ui/core/CardActionArea'; | ||
import CardActionArea from '@material-ui/core/CardActionArea'; | ||
|
||
import GatsbyLink from './gatsby-link'; | ||
import patchBaseButtonComponent from '../utils/patch-base-button-components'; | ||
|
||
function CardActionArea(props) { | ||
const { to, href } = props; | ||
const component = to || href ? GatsbyLink : 'button'; | ||
|
||
return <MuiCardActionArea component={component} {...props} />; | ||
} | ||
|
||
export default CardActionArea; | ||
export default patchBaseButtonComponent(CardActionArea); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
import Fab from '@material-ui/core/Fab'; | ||
|
||
import patchBaseButtonComponent from '../utils/patch-base-button-components'; | ||
|
||
export default patchBaseButtonComponent(Fab); |
14 changes: 3 additions & 11 deletions
14
packages/gatsby-theme-material-ui/src/components/icon-button.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,5 @@ | ||
import React from 'react'; | ||
import MuiIconButton from '@material-ui/core/IconButton'; | ||
import IconButton from '@material-ui/core/IconButton'; | ||
|
||
import GatsbyLink from './gatsby-link'; | ||
import patchBaseButtonComponent from '../utils/patch-base-button-components'; | ||
|
||
function IconButton(props) { | ||
const { to, href } = props; | ||
const component = to || href ? GatsbyLink : 'button'; | ||
|
||
return <MuiIconButton component={component} {...props} />; | ||
} | ||
|
||
export default IconButton; | ||
export default patchBaseButtonComponent(IconButton); |
12 changes: 12 additions & 0 deletions
12
packages/gatsby-theme-material-ui/src/utils/patch-base-button-components.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import React from 'react'; | ||
|
||
import GatsbyLink from '../components/gatsby-link'; | ||
|
||
export default function patchBaseButtonComponent(BaseButtonComponent) { | ||
return props => { | ||
const { to, href } = props; | ||
const component = to || href ? GatsbyLink : 'button'; | ||
|
||
return <BaseButtonComponent component={component} {...props} />; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
# example-composition | ||
[![Netlify Status](https://api.netlify.com/api/v1/badges/c611085a-2b6f-4ca0-8b5d-99c376829144/deploy-status)](https://app.netlify.com/sites/gatsby-theme-material-ui/deploys) | ||
|
||
Gatsby example site that shows how to compose themes. | ||
# gatsby-theme-material-ui |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
title: test | ||
slug: test | ||
date: 2019-05-12T18:01:23.120Z | ||
--- | ||
testhelllollorrrrr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.