1
1
mirror of https://github.com/jxnblk/mdx-deck.git synced 2024-09-11 06:35:24 +03:00

Use v3 package imports in examples

This commit is contained in:
John Gosset 2019-10-24 10:04:32 -04:00
parent 738243dad4
commit 04ca47cea2
8 changed files with 11 additions and 16 deletions

View File

@ -1,5 +1,4 @@
import future from '@mdx-deck/themes/future'
import aspect from '@mdx-deck/themes/aspect'
import { future, aspect } from 'mdx-deck/themes'
export const themes = [
future,

View File

@ -1,4 +1,4 @@
import { Head } from '@mdx-deck/components'
import { Head } from 'mdx-deck'
<Head>
<title>Hello</title>

View File

@ -1,6 +1,6 @@
import {
Image,
} from '@mdx-deck/components'
} from 'mdx-deck'
# Hello!

View File

@ -4,7 +4,7 @@ import {
SplitRight,
Horizontal,
FullScreenCode,
} from '@mdx-deck/layouts'
} from 'mdx-deck'
# Hello!

View File

@ -1,9 +1,8 @@
import future from '@mdx-deck/themes/future'
import highlight from '@mdx-deck/themes/syntax-highlighter-prism'
import { future, prism } from 'mdx-deck/themes'
export const themes = [
future,
highlight
prism
]
# Hello!

View File

@ -1,4 +1,4 @@
import comic from '@mdx-deck/themes/comic'
import { comic } from 'mdx-deck/themes'
import theme from './theme'
export const themes = [

View File

@ -1,5 +1,4 @@
import future from '@mdx-deck/themes/future'
import highlight from '@mdx-deck/themes/syntax-highlighter'
import { future, highlight } from 'mdx-deck/themes'
export const themes = [
future,

View File

@ -1,7 +1,7 @@
import React, { useState, useContext } from 'react'
import { ThemeProvider } from 'emotion-theming'
import { MDXProvider } from '@mdx-js/react'
import * as themes from '@mdx-deck/themes'
import * as themes from 'mdx-deck/themes'
const names = Object.keys(themes)
@ -35,16 +35,14 @@ const Provider = props => {
right: 0,
bottom: 0,
margin: 16,
}}
>
}}>
<label>
Theme
<select
value={name}
onChange={e => {
setTheme(e.target.value)
}}
>
}}>
{names.map(name => (
<option key={name}>{name}</option>
))}