Skip to content

Commit

Permalink
test: refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
pcheremu committed Apr 12, 2024
1 parent 88d029d commit 4808589
Show file tree
Hide file tree
Showing 11 changed files with 25 additions and 169 deletions.
Binary file not shown.
25 changes: 0 additions & 25 deletions packages/testing-docs/blog/2021-08-26-welcome/index.md

This file was deleted.

17 changes: 0 additions & 17 deletions packages/testing-docs/blog/authors.yml

This file was deleted.

43 changes: 2 additions & 41 deletions packages/testing-docs/docs/intro.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,46 +2,7 @@
sidebar_position: 1
---

# Tutorial Intro
# Tests for zkSync Era Block Explorer

Let's discover **Docusaurus in less than 5 minutes**.
Use lef sidebar for navigation

## Getting Started

Get started by **creating a new site**.

Or **try Docusaurus immediately** with **[docusaurus.new](https://docusaurus.new)**.

### What you'll need

- [Node.js](https://nodejs.org/en/download/) version 18.0 or above:
- When installing Node.js, you are recommended to check all checkboxes related to dependencies.

## Generate a new site

Generate a new Docusaurus site using the **classic template**.

The classic template will automatically be added to your project after you run the command:

```bash
npm init docusaurus@latest my-website classic
```

You can type this command into Command Prompt, Powershell, Terminal, or any other integrated terminal of your code editor.

The command also installs all necessary dependencies you need to run Docusaurus.

## Start your site

Run the development server:

```bash
cd my-website
npm run start
```

The `cd` command changes the directory you're working with. In order to work with your newly created Docusaurus site, you'll need to navigate the terminal there.

The `npm run start` command builds your website locally and serves it through a development server, ready for you to view at http://localhost:3000/.

Open `docs/intro.md` (this page) and edit some lines: the site **reloads automatically** and displays your changes.
7 changes: 0 additions & 7 deletions packages/testing-docs/docs/tutorial-extras/_category_.json

This file was deleted.

Binary file not shown.
Binary file not shown.
65 changes: 15 additions & 50 deletions packages/testing-docs/docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,20 @@ import type {Config} from '@docusaurus/types';
import type * as Preset from '@docusaurus/preset-classic';

const config: Config = {
title: 'My Site',
tagline: 'Dinosaurs are cool',
title: 'Block Explorer',
tagline: '',
favicon: 'img/favicon.ico',

// Set the production url of your site here
url: 'https://your-docusaurus-site.example.com',
url: 'https://github.com/',
// Set the /<baseUrl>/ pathname under which your site is served
// For GitHub pages deployment, it is often '/<projectName>/'
baseUrl: '/',

// GitHub pages deployment config.
// If you aren't using GitHub pages, you don't need these.
organizationName: 'facebook', // Usually your GitHub org/user name.
projectName: 'docusaurus', // Usually your repo name.
organizationName: 'MatterLabs', // Usually your GitHub org/user name.
projectName: 'blockexplorer', // Usually your repo name.

onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
Expand All @@ -36,16 +36,8 @@ const config: Config = {
docs: {
sidebarPath: './sidebars.ts',
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
},
blog: {
showReadingTime: true,
// Please change this to your repo.
// Remove this to remove the "edit this page" links.
editUrl:
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
// routeBasePath: '/', // Set this value to '/'.
// homePageId: 'BE Tests', // Set to existing document id.
},
theme: {
customCss: './src/css/custom.css',
Expand All @@ -58,70 +50,43 @@ const config: Config = {
// Replace with your project's social card
image: 'img/docusaurus-social-card.jpg',
navbar: {
title: 'My Site',
title: 'Block Explorer',
logo: {
alt: 'My Site Logo',
alt: 'Block Explorer',
src: 'img/logo.svg',
},
items: [
{
type: 'docSidebar',
sidebarId: 'tutorialSidebar',
position: 'left',
label: 'Tutorial',
},
{to: '/blog', label: 'Blog', position: 'left'},
{
href: 'https://github.com/facebook/docusaurus',
label: 'GitHub',
position: 'right',
label: 'Tests',
},
],
},
footer: {
style: 'dark',
links: [
{
title: 'Docs',
items: [
{
label: 'Tutorial',
to: '/docs/intro',
},
],
},
{
title: 'Community',
title: 'Block Explorer',
items: [
{
label: 'Stack Overflow',
href: 'https://stackoverflow.com/questions/tagged/docusaurus',
},
{
label: 'Discord',
href: 'https://discordapp.com/invite/docusaurus',
},
{
label: 'Twitter',
href: 'https://twitter.com/docusaurus',
label: 'Main link',
href: 'https://explorer.zksync.io/',
},
],
},
{
title: 'More',
items: [
{
label: 'Blog',
to: '/blog',
},
{
label: 'GitHub',
href: 'https://github.com/facebook/docusaurus',
href: 'https://github.com/matter-labs/block-explorer',
},
],
},
],
copyright: `Copyright © ${new Date().getFullYear()} My Project, Inc. Built with Docusaurus.`,
// copyright: `Copyright © ${new Date().getFullYear()} My Project, Inc. Built with Docusaurus.`,
},
prism: {
theme: prismThemes.github,
Expand Down
27 changes: 3 additions & 24 deletions packages/testing-docs/src/components/HomepageFeatures/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,32 +10,11 @@ type FeatureItem = {

const FeatureList: FeatureItem[] = [
{
title: 'Easy to Use',
Svg: require('@site/static/img/undraw_docusaurus_mountain.svg').default,
title: 'zkSync Block Explorer',
Svg: require('@site/static/img/main.PNG').default,
description: (
<>
Docusaurus was designed from the ground up to be easily installed and
used to get your website up and running quickly.
</>
),
},
{
title: 'Focus on What Matters',
Svg: require('@site/static/img/undraw_docusaurus_tree.svg').default,
description: (
<>
Docusaurus lets you focus on your docs, and we&apos;ll do the chores. Go
ahead and move your docs into the <code>docs</code> directory.
</>
),
},
{
title: 'Powered by React',
Svg: require('@site/static/img/undraw_docusaurus_react.svg').default,
description: (
<>
Extend or customize your website layout by reusing React. Docusaurus can
be extended while reusing the same header and footer.
Some text
</>
),
},
Expand Down
6 changes: 3 additions & 3 deletions packages/testing-docs/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function HomepageHeader() {
<Link
className="button button--secondary button--lg"
to="/docs/intro">
Docusaurus Tutorial - 5min ⏱️
To tests ⏱️
</Link>
</div>
</div>
Expand All @@ -33,10 +33,10 @@ export default function Home(): JSX.Element {
return (
<Layout
title={`Hello from ${siteConfig.title}`}
description="Description will go into a meta tag in <head />">
description="">
<HomepageHeader />
<main>
<HomepageFeatures />
{/*<HomepageFeatures />*/}
</main>
</Layout>
);
Expand Down
4 changes: 2 additions & 2 deletions packages/testing-docs/src/pages/markdown-page.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@
title: Markdown page example
---

# Markdown page example
# Tests for zkSync Era Block Explorer

You don't need React to write simple standalone pages.
Online blockchain browser for viewing and analyzing zkSync Era blockchain.

0 comments on commit 4808589

Please sign in to comment.