Skip to content

Commit

Permalink
feat: init provider console with next, tailwind and shadcn (#243)
Browse files Browse the repository at this point in the history
  • Loading branch information
jigar-arc10 authored Jul 10, 2024
1 parent 5db2a42 commit 8afb22d
Show file tree
Hide file tree
Showing 40 changed files with 1,971 additions and 147 deletions.
1 change: 1 addition & 0 deletions apps/provider-console/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = require('@akashnetwork/dev-config/.eslintrc.next');
36 changes: 36 additions & 0 deletions apps/provider-console/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js
.yarn/install-state.gz

# testing
/coverage

# next.js
/.next/
/out/

# production
/build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# local env files
.env*.local

# vercel
.vercel

# typescript
*.tsbuildinfo
next-env.d.ts
19 changes: 19 additions & 0 deletions apps/provider-console/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
## Provider Console
Provider console is responsible for creating provider in Akash Network using UI with best practices
## Getting Started

First, run the development server:

```bash
npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev
```

Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.

You can start editing the page by modifying `pages/index.tsx`. The page auto-updates as you edit the file.
17 changes: 17 additions & 0 deletions apps/provider-console/components.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"$schema": "https://ui.shadcn.com/schema.json",
"style": "default",
"rsc": true,
"tsx": true,
"tailwind": {
"config": "tailwind.config.ts",
"css": "src/styles/global.css",
"baseColor": "neutral",
"cssVariables": true,
"prefix": ""
},
"aliases": {
"components": "@src/components",
"utils": "@src/utils/styleUtils"
}
}
38 changes: 38 additions & 0 deletions apps/provider-console/next.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: false,
compiler: {
// Enables the styled-components SWC transform
styledComponents: true
},
images: {
domains: ["raw.githubusercontent.com"]
},
output: "standalone",
typescript: {
tsconfigPath: "./tsconfig.json"
},
eslint: {
ignoreDuringBuilds: true
},
transpilePackages: ["geist", "@akashnetwork/ui"],
// experimental: {
// // outputStandalone: true,
// externalDir: true // to make the import from shared parent folder work https://github.com/vercel/next.js/issues/9474#issuecomment-810212174
// },
i18n: {
locales: ["en-US"],
defaultLocale: "en-US"
},
webpack: config => {
// Fixes npm packages that depend on `node:crypto` module
config.externals.push({
"node:crypto": "crypto"
});
config.externals.push("pino-pretty");
return config;
},
};

module.exports = nextConfig;

38 changes: 38 additions & 0 deletions apps/provider-console/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"name": "provider-console",
"version": "0.1.0",
"private": true,
"scripts": {
"build": "next build",
"build-analyze": "set ANALYZE=true&& next build",
"dev": "next -p 3000",
"format": "prettier --write ./*.{ts,js,json} **/*.{ts,tsx,js,json}",
"lint": "eslint .",
"start": "next start",
"type-check": "tsc"
},
"dependencies": {
"@akashnetwork/ui": "*",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.1",
"lucide-react": "^0.395.0",
"next": "14.2.4",
"react": "^18",
"react-dom": "^18",
"tailwind-merge": "^2.3.0",
"tailwindcss-animate": "^1.0.7",
"ts-loader": "^9.5.1"
},
"devDependencies": {
"@akashnetwork/dev-config": "*",
"@types/node": "^20",
"@types/react": "^18",
"@types/react-dom": "^18",
"eslint": "^8",
"eslint-config-next": "14.2.4",
"next-transpile-modules": "^10.0.1",
"postcss": "^8",
"tailwindcss": "^3.4.1",
"typescript": "^5"
}
}
1 change: 1 addition & 0 deletions apps/provider-console/postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = require("@akashnetwork/ui/postcss");
Binary file added apps/provider-console/public/favicon.ico
Binary file not shown.
48 changes: 48 additions & 0 deletions apps/provider-console/public/images/akash-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions apps/provider-console/src/components/home/HomeContainer.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
"use client";
import React from "react";
import { Footer } from "@src/components/layout/Footer";
import Layout from "../layout/Layout";

export function HomeContainer() {
return (
<Layout containerClassName="flex h-full flex-col justify-between" isLoading={false}>
<div>
<div className="mb-4"></div>
</div>
<Footer />
</Layout>
);
}

Loading

0 comments on commit 8afb22d

Please sign in to comment.