-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #111 from Concordium/company-gui
Company ID GUI tool
- Loading branch information
Showing
64 changed files
with
16,087 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: 'Publish Company ID' | ||
on: | ||
# push: | ||
# branches: | ||
# - release | ||
|
||
workflow_dispatch: # allows manual trigger | ||
|
||
jobs: | ||
publish-tauri: | ||
permissions: | ||
contents: write | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
platform: [macos-latest, ubuntu-20.04, windows-latest] | ||
|
||
runs-on: ${{ matrix.platform }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
- name: setup node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 20 | ||
- name: install Rust stable | ||
uses: dtolnay/rust-toolchain@stable | ||
- name: install dependencies (ubuntu only) | ||
if: matrix.platform == 'ubuntu-20.04' | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf | ||
- name: install frontend dependencies | ||
working-directory: ./company-id-gui | ||
run: yarn install # change this to npm or pnpm depending on which one you use | ||
- uses: tauri-apps/tauri-action@v0 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
projectPath: 'company-id-gui' | ||
tagName: company-id-gui/v__VERSION__ # the action automatically replaces \_\_VERSION\_\_ with the app version | ||
releaseName: 'Company ID GUI v__VERSION__' | ||
releaseBody: 'See the assets to download this version and install.' | ||
releaseDraft: true | ||
prerelease: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
.eslintrc.cjs | ||
.yarn/ | ||
node_modules/ | ||
dist/ | ||
src-tauri/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
module.exports = { | ||
root: true, | ||
env: { browser: true, es2020: true }, | ||
extends: [ | ||
'eslint:recommended', | ||
'plugin:@typescript-eslint/recommended-type-checked', | ||
'plugin:@typescript-eslint/stylistic-type-checked', | ||
'plugin:react-hooks/recommended', | ||
'plugin:react/recommended', | ||
'plugin:react/jsx-runtime', | ||
'plugin:jsx-a11y/recommended', | ||
'eslint-config-prettier', | ||
], | ||
parser: '@typescript-eslint/parser', | ||
plugins: ['react', 'react-refresh'], | ||
rules: { | ||
'react-refresh/only-export-components': ['warn', { allowConstantExport: true }], | ||
'@typescript-eslint/unbound-method': 0, | ||
'@typescript-eslint/no-misused-promises': [ | ||
'error', | ||
{ | ||
checksVoidReturn: { | ||
attributes: false, | ||
}, | ||
}, | ||
], | ||
}, | ||
parserOptions: { | ||
ecmaVersion: 'latest', | ||
ecmaFeatures: { jsx: true }, | ||
sourceType: 'module', | ||
project: ['./tsconfig.json', './tsconfig.node.json'], | ||
tsconfigRootDir: __dirname, | ||
}, | ||
settings: { | ||
react: { | ||
version: 'detect', | ||
}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
lerna-debug.log* | ||
|
||
.pnp.* | ||
.yarn/* | ||
!.yarn/patches | ||
!.yarn/plugins | ||
!.yarn/releases | ||
!.yarn/sdks | ||
!.yarn/versions | ||
node_modules | ||
|
||
dist | ||
dist-ssr | ||
*.local | ||
|
||
# Editor directories and files | ||
.vscode/* | ||
!.vscode/extensions.json | ||
.idea | ||
.DS_Store | ||
*.suo | ||
*.ntvs* | ||
*.njsproj | ||
*.sln | ||
*.sw? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.yarn/ | ||
node_modules/ | ||
dist/ | ||
src-tauri/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"trailingComma": "all", | ||
"semi": true, | ||
"singleQuote": true, | ||
"printWidth": 120, | ||
"bracketSpacing": true, | ||
"tabWidth": 4 | ||
} |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
yarnPath: .yarn/releases/yarn-3.6.3.cjs | ||
nodeLinker: node-modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# Company ID GUI Tool | ||
|
||
## Building and Running | ||
|
||
Install `tauri-cli`: | ||
|
||
```bash | ||
cargo install tauri-cli | ||
``` | ||
|
||
To build or run, first install the dependencies: | ||
|
||
```bash | ||
yarn install | ||
``` | ||
|
||
Then, to build: | ||
|
||
```bash | ||
cargo tauri build | ||
``` | ||
|
||
To build a signed version for windows the `src-tauri/tauri.conf.json` has to be updated with the correct thumbprint following the last part of the procedure outline in the [documentation](https://tauri.app/v1/guides/distribution/sign-windows#c-prepare-variables). | ||
|
||
Or, to run: | ||
|
||
```bash | ||
cargo tauri dev | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<!doctype html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<link rel="icon" type="image/svg+xml" href="/ccd-logo.svg" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Tauri + React + TS</title> | ||
</head> | ||
|
||
<body> | ||
<div id="root"></div> | ||
<script type="module" src="/src/main.tsx"></script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
{ | ||
"name": "company-id-gui", | ||
"private": true, | ||
"version": "1.0.0", | ||
"type": "module", | ||
"scripts": { | ||
"dev": "vite", | ||
"build": "tsc && vite build", | ||
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", | ||
"lint-fix": "yarn lint --fix", | ||
"fmt": "prettier -w .", | ||
"preview": "vite preview" | ||
}, | ||
"dependencies": { | ||
"@fontsource/ibm-plex-sans": "^5.0.17", | ||
"@tauri-apps/api": "^1.5.1", | ||
"bootstrap": "^5.3.2", | ||
"bootstrap-icons": "^1.11.1", | ||
"react": "^18.2.0", | ||
"react-bootstrap": "^2.8.0", | ||
"react-dom": "^18.2.0" | ||
}, | ||
"devDependencies": { | ||
"@tauri-apps/cli": "^1.5.0", | ||
"@types/react": "^18.2.15", | ||
"@types/react-dom": "^18.2.7", | ||
"@typescript-eslint/eslint-plugin": "^6.0.0", | ||
"@typescript-eslint/parser": "^6.0.0", | ||
"@vitejs/plugin-react-swc": "^3.3.2", | ||
"eslint": "^8.45.0", | ||
"eslint-config-prettier": "^9.0.0", | ||
"eslint-plugin-jsx-a11y": "^6.7.1", | ||
"eslint-plugin-react": "^7.33.2", | ||
"eslint-plugin-react-hooks": "^4.6.0", | ||
"eslint-plugin-react-refresh": "^0.4.3", | ||
"prettier": "^3.0.3", | ||
"sass": "^1.67.0", | ||
"typescript": "^5.0.2", | ||
"vite": "^4.4.5", | ||
"vite-plugin-top-level-await": "^1.3.1", | ||
"vite-plugin-wasm": "^3.2.2" | ||
}, | ||
"packageManager": "[email protected]" | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Generated by Cargo | ||
# will have compiled files and executables | ||
/target/ | ||
|
Oops, something went wrong.