Skip to content

Commit

Permalink
Vue3 frontend for identity
Browse files Browse the repository at this point in the history
  • Loading branch information
shps951023 committed Apr 25, 2024
1 parent b4f95b9 commit 63814fb
Show file tree
Hide file tree
Showing 42 changed files with 7,378 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Frontend_Identity/.env.development
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ENV = 'development'
VITE_DEBUG=true
VITE_APP_BASE_API = "http://localhost:5566/MiniAuth/"
3 changes: 3 additions & 0 deletions src/Frontend_Identity/.env.production
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ENV = 'production'
VITE_DEBUG=false
VITE_APP_BASE_API = "/MiniAuth/"
15 changes: 15 additions & 0 deletions src/Frontend_Identity/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/* eslint-env node */
require('@rushstack/eslint-patch/modern-module-resolution')

module.exports = {
root: true,
'extends': [
'plugin:vue/vue3-essential',
'eslint:recommended',
'@vue/eslint-config-typescript',
'@vue/eslint-config-prettier/skip-formatting'
],
parserOptions: {
ecmaVersion: 'latest'
}
}
30 changes: 30 additions & 0 deletions src/Frontend_Identity/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
.DS_Store
dist
dist-ssr
coverage
*.local

/cypress/videos/
/cypress/screenshots/

# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?

*.tsbuildinfo
8 changes: 8 additions & 0 deletions src/Frontend_Identity/.prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"$schema": "https://json.schemastore.org/prettierrc",
"semi": false,
"tabWidth": 2,
"singleQuote": true,
"printWidth": 100,
"trailingComma": "none"
}
8 changes: 8 additions & 0 deletions src/Frontend_Identity/.vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"recommendations": [
"Vue.volar",
"Vue.vscode-typescript-vue-plugin",
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode"
]
}
Empty file added src/Frontend_Identity/README.md
Empty file.
14 changes: 14 additions & 0 deletions src/Frontend_Identity/buildExt.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import * as fs from 'fs';
// remove the base URL from the login.js file
{
const filePath = '../MiniAuth/wwwroot/login.js';
const fileData = fs.readFileSync(filePath, 'utf8');
const updatedData = fileData.replace('http://localhost:5566/MiniAuth/', '');
fs.writeFileSync(filePath, updatedData, 'utf8');
}
{
const filePath = '../MiniAuth.IdentityAuth/wwwroot/login.js';
const fileData = fs.readFileSync(filePath, 'utf8');
const updatedData = fileData.replace('http://localhost:5566/MiniAuth/', '');
fs.writeFileSync(filePath, updatedData, 'utf8');
}
1 change: 1 addition & 0 deletions src/Frontend_Identity/env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="vite/client" />
15 changes: 15 additions & 0 deletions src/Frontend_Identity/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="icon" href="./src/assets/images/favicon.ico">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>MiniAuth</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<script src="js/bootstrap.bundle.min.js"></script>
</head>
<body>
<div id="app"></div>
<script type="module" src="/src/main.ts"></script>
</body>
</html>
Loading

0 comments on commit 63814fb

Please sign in to comment.