Skip to content

Commit

Permalink
Merge pull request #153 from ensdomains/hotfix/disable-playroom
Browse files Browse the repository at this point in the history
Remove playroom
  • Loading branch information
storywithoutend authored May 22, 2024
2 parents f9e768b + bc843a3 commit f3e536d
Show file tree
Hide file tree
Showing 7 changed files with 418 additions and 1,833 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ yarn-error.log*

docs/.next/
docs/out/
docs/public/playroom/
# docs/public/playroom/
docs/src/playroom/snippets

components/dist/
Expand Down
1 change: 0 additions & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
"next": "12.3.0",
"next-mdx-remote": "^3.0.6",
"nookies": "^2.5.2",
"playroom": "^0.28.1",
"prism-react-renderer": "^1.2.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
Expand Down
15 changes: 15 additions & 0 deletions docs/public/playroom/preview/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@

<!DOCTYPE html>
<html lang="en">

<head>
<meta name="description" content="Design systems for ENS built with React and styled-components" />
<meta charset="utf-8">
<title>ENS Design</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="author" content="">
</head>

<body>
</body>
</html>
10 changes: 9 additions & 1 deletion docs/src/playroom/types.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
import { Snippets as PlayroomSnippets } from 'playroom'
// import { Snippets as PlayroomSnippets } from 'playroom'
import { Optional } from 'utility-types'

interface PlayroomSnippet {
group: string
name: string
code: string
}

type PlayroomSnippets = PlayroomSnippet[]

export type Snippet = Omit<
Optional<PlayroomSnippets[number], 'group'>,
'code'
Expand Down
10 changes: 9 additions & 1 deletion docs/src/types/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
import { Snippets as PlayroomSnippets } from 'playroom'
// import { Snippets as PlayroomSnippets } from 'playroom'
import { Optional } from 'utility-types'

interface PlayroomSnippet {
group: string
name: string
code: string
}

type PlayroomSnippets = PlayroomSnippet[]

export type Snippet = Omit<
Optional<PlayroomSnippets[number], 'group'>,
'code'
Expand Down
23 changes: 12 additions & 11 deletions docs/src/utils/playroom.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { CreateUrlOptions, createUrl } from 'playroom'
export {}
// import { CreateUrlOptions, createUrl } from 'playroom'

export const createPlayroomLink = (options: CreateUrlOptions = {}) => {
return createUrl({
baseUrl:
process.env.NODE_ENV === 'development'
? 'http://localhost:8082'
: '/playroom',
widths: [640],
...options,
})
}
// export const createPlayroomLink = (options: CreateUrlOptions = {}) => {
// return createUrl({
// baseUrl:
// process.env.NODE_ENV === 'development'
// ? 'http://localhost:8082'
// : '/playroom',
// widths: [640],
// ...options,
// })
// }
Loading

0 comments on commit f3e536d

Please sign in to comment.