Skip to content

Commit

Permalink
feat: The list of basic contents was added
Browse files Browse the repository at this point in the history
  • Loading branch information
unknown committed Jul 28, 2022
1 parent d1eed79 commit 04fdf0a
Show file tree
Hide file tree
Showing 60 changed files with 2,310 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@

.DS_Store
examples
packages


# Logs
logs
*.log
Expand Down
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.next
node_modules
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 RaminRakhshani
Copyright (c) 2020 Shu Ding

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# [Nextra](https://nextra.vercel.app)

**Nextra** is a [Next.js](https://nextjs.org) and [MDX](https://mdxjs.com) powered, no-code site generator.

![](/public/demo.png)

## Development

The code of Nextra is under the [`core`](https://github.com/shuding/nextra/tree/core) branch.

## Themes

- [nextra-theme-docs](https://github.com/vercel/swr-site) ([demo](https://swr.vercel.app))
- [nextra-theme-blog](https://github.com/shuding/site) ([demo](https://shud.in))

---

Created by [@shuding](https://github.com/shuding) and [@pacocoursey](https://github.com/pacocoursey) at [Vercel](https://vercel.com). Released under the MIT license.
6 changes: 6 additions & 0 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
const withNextra = require('nextra')({
theme: 'nextra-theme-docs',
themeConfig: './theme.config.js',
unstable_staticImage: true,
})
module.exports = withNextra()
27 changes: 27 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "nextra",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"dev": "next",
"start": "next start",
"build": "next build"
},
"author": "Shu Ding",
"license": "MIT",
"dependencies": {
"next": "^12.1.0",
"nextra": "^1.1.0",
"nextra-theme-docs": "^1.2.2",
"react": "^17.0.1",
"react-dom": "^17.0.1"
},
"devDependencies": {
"prettier": "^2.0.5"
},
"prettier": {
"semi": false,
"singleQuote": true
}
}
5 changes: 5 additions & 0 deletions pages/_app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import 'nextra-theme-docs/style.css'

export default function Nextra({ Component, pageProps }) {
return <Component {...pageProps} />
}
3 changes: 3 additions & 0 deletions pages/basics/assembly.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Assembly
3 changes: 3 additions & 0 deletions pages/basics/call.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Call
3 changes: 3 additions & 0 deletions pages/basics/calling-other-contract.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Calling Other Contract
3 changes: 3 additions & 0 deletions pages/basics/calling-parent-contracts.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Calling Parent Contracts
3 changes: 3 additions & 0 deletions pages/basics/data-locations.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Data Locations - Storage, Memory and Calldata
3 changes: 3 additions & 0 deletions pages/basics/delegate-call.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# DelegateCall
3 changes: 3 additions & 0 deletions pages/basics/fallback.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Fallback
3 changes: 3 additions & 0 deletions pages/basics/function-selector.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Function Selector
3 changes: 3 additions & 0 deletions pages/basics/hashing-with-keccak256.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Hashing with Keccak256
3 changes: 3 additions & 0 deletions pages/basics/inheritance.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Inheritance
3 changes: 3 additions & 0 deletions pages/basics/inherited-state-variables.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Inherited State Variables
3 changes: 3 additions & 0 deletions pages/basics/interface.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Interface
3 changes: 3 additions & 0 deletions pages/basics/library.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Library
20 changes: 20 additions & 0 deletions pages/basics/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"state-variables": "State variables",
"structs": "Structs",
"data-locations": "Data Locations - Storage, Memory and Calldata",
"inheritance": "Inheritance",
"inherited-state-variables": "Inherited State Variables",
"calling-parent-contracts": "Calling Parent Contracts",
"visibility": "Visibility(public, private, internal, external)",
"interface": "Interface",
"fallback": "Fallback",
"call": "Call",
"delegate-call": "DelegateCall",
"function-selector": "Function Selector",
"calling-other-contract": "Calling Other Contract",
"library": "Library",
"hashing-with-keccak256": "Hashing with Keccak256",
"assembly": "Assembly",
"upgradeable-proxy": "Upgradeable Proxy",
"write-to-any-slot": "Write to Any Slot"
}
3 changes: 3 additions & 0 deletions pages/basics/state-variables.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# State variables
3 changes: 3 additions & 0 deletions pages/basics/structs.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Structs
3 changes: 3 additions & 0 deletions pages/basics/upgradeable-proxy.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Upgradeable Proxy
3 changes: 3 additions & 0 deletions pages/basics/visibility.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Visibility(public, private, internal, external)
3 changes: 3 additions & 0 deletions pages/basics/write-to-any-slot.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Write to Any Slot
3 changes: 3 additions & 0 deletions pages/diamond/app-storage.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# App Storage
3 changes: 3 additions & 0 deletions pages/diamond/deployement.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Deployement
3 changes: 3 additions & 0 deletions pages/diamond/diamond-cut.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Diamond Cut
3 changes: 3 additions & 0 deletions pages/diamond/diamond-loupe.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Diamond Loupe
3 changes: 3 additions & 0 deletions pages/diamond/diamond-storage.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Diamond Storage
3 changes: 3 additions & 0 deletions pages/diamond/diamond.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Diamond
3 changes: 3 additions & 0 deletions pages/diamond/diamonds-in-projects.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Diamonds in Projects
3 changes: 3 additions & 0 deletions pages/diamond/eternal-storage.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Eternal Storage
3 changes: 3 additions & 0 deletions pages/diamond/facets.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Facets
3 changes: 3 additions & 0 deletions pages/diamond/inherited-storage.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Inherited Storage
15 changes: 15 additions & 0 deletions pages/diamond/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"diamond": "Diamond",
"facets": "Facets",
"diamond-loupe": "Diamond Loupe",
"diamond-cut":"DiamondCut",
"unstructured-storage": "Unstructured Storage",
"inherited-storage": "Inherited Storage",
"eternal-storage": "Eternal Storage",
"app-storage": "App Storage",
"diamond-storage": "Diamond Storage",
"deployement": "Deployement",
"motivation": "Motivation",
"tools": "Tools",
"diamonds-in-projects": "Diamonds in Projects"
}
3 changes: 3 additions & 0 deletions pages/diamond/motivation.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Motivation
3 changes: 3 additions & 0 deletions pages/diamond/tools.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Tools
3 changes: 3 additions & 0 deletions pages/diamond/unstructured-storage.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Unstructured Storage
5 changes: 5 additions & 0 deletions pages/get-started.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Get Started

## Quick Start

## Create
5 changes: 5 additions & 0 deletions pages/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import Bleed from 'nextra-theme-docs/bleed'

# Diamond

The EIP-2535 Diamonds is a way to organize your Solidity code and contracts to give them the right amount of modularity and cohesion for your system. In addition, flexible upgrade capability is a key part of it.
3 changes: 3 additions & 0 deletions pages/libraries/library1.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Library1
3 changes: 3 additions & 0 deletions pages/libraries/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"library1": "Library1"
}
10 changes: 10 additions & 0 deletions pages/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"index": "Introduction",
"get-started": "Get Started",
"basics":"Basics",
"diamond": "Diamond",
"articles": "Articles",
"libraries": "Libraries",
"tools": "Tools",
"audits": "Audits"
}
3 changes: 3 additions & 0 deletions pages/tools/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"tools1": "Tools1"
}
3 changes: 3 additions & 0 deletions pages/tools/tools1.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import Callout from 'nextra-theme-docs/callout'

# Tools1
Binary file added public/android-icon-192x192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/apple-icon-180x180.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/apple-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon-16x16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon-32x32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon-96x96.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/favicon.ico
Binary file not shown.
Binary file added public/icons8-diamond-50.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/ms-icon-144x144.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/og.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
67 changes: 67 additions & 0 deletions theme.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
export default {
github: 'https://github.com/shuding/nextra',
docsRepositoryBase: 'https://github.com/shuding/nextra/blob/master',
titleSuffix: ' – Diamond',
logo: (
<>
<span className="mr-2 font-extrabold hidden md:inline">Nextra</span>
<span className="text-gray-600 font-normal hidden md:inline">
The Next.js Static Site Generator
</span>
</>
),
head: (
<>
<meta name="msapplication-TileColor" content="#ffffff" />
<meta name="theme-color" content="#ffffff" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta httpEquiv="Content-Language" content="en" />
<meta name="description" content="Nextra: the Next.js site builder" />
<meta name="og:description" content="Nextra: the Next.js site builder" />
<meta name="twitter:card" content="summary_large_image" />
<meta name="twitter:image" content="https://nextra.vercel.app/og.png" />
<meta name="twitter:site:domain" content="nextra.vercel.app" />
<meta name="twitter:url" content="https://nextra.vercel.app" />
<meta name="og:title" content="Nextra: Next.js static site generator" />
<meta name="og:image" content="https://nextra.vercel.app/og.png" />
<meta name="apple-mobile-web-app-title" content="Nextra" />
<link
rel="apple-touch-icon"
sizes="180x180"
href="/apple-icon-180x180.png"
/>
<link
rel="icon"
type="image/png"
sizes="192x192"
href="/android-icon-192x192.png"
/>
<link
rel="icon"
type="image/png"
sizes="32x32"
href="/favicon-32x32.png"
/>
<link
rel="icon"
type="image/png"
sizes="96x96"
href="/favicon-96x96.png"
/>
<link
rel="icon"
type="image/png"
sizes="16x16"
href="/favicon-16x16.png"
/>
<meta name="msapplication-TileImage" content="/ms-icon-144x144.png" />
</>
),
search: true,
prevLinks: true,
nextLinks: true,
footer: true,
footerEditLink: 'Edit this page on GitHub',
footerText: <>MIT {new Date().getFullYear()} © Nextra.</>,
unstable_faviconGlyph: '👋',
}
Loading

0 comments on commit 04fdf0a

Please sign in to comment.