Skip to content

Commit 0e1f109

Browse files
authored
Merge pull request #213 from SoftwareDesignLab/dev
SVIP GUI v1.10 alpha Pre-Release - Reviewed with @jwj7297 and @txdvse to confirm everything works
2 parents a1d3e99 + e73164e commit 0e1f109

File tree

143 files changed

+1861
-10019
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

143 files changed

+1861
-10019
lines changed
File renamed without changes.

.gitignore

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,47 @@
1+
# See http://help.github.com/ignore-files/ for more about ignoring files.
2+
3+
# Compiled output
4+
/dist
5+
/tmp
6+
/out-tsc
7+
/bazel-out
8+
9+
# Node
10+
/node_modules
11+
npm-debug.log
12+
yarn-error.log
13+
14+
# IDEs and editors
15+
.idea/
16+
.project
17+
.classpath
18+
.c9/
19+
*.launch
20+
.settings/
21+
*.sublime-workspace
22+
23+
# Visual Studio Code
24+
.vscode/*
25+
!.vscode/settings.json
26+
!.vscode/tasks.json
27+
!.vscode/launch.json
28+
!.vscode/extensions.json
29+
.history/*
30+
31+
# Miscellaneous
32+
/.angular/cache
33+
.sass-cache/
34+
/connect.lock
35+
/coverage
36+
/libpeerconnection.log
37+
testem.log
38+
/typings
39+
40+
# System files
141
.DS_Store
42+
Thumbs.db
43+
44+
/.vscode/
45+
/builds/
46+
47+
temp.zip
File renamed without changes.

frontend/app.js renamed to app.js

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ const { app, BrowserWindow, ipcMain, dialog } = require("electron");
22
const fs = require("fs");
33
const url = require("url");
44
const path = require("path");
5+
const { zip } = require("zip-a-folder");
56

67
let mainWindow;
78

@@ -50,6 +51,37 @@ ipcMain.handle("selectFiles", async () => {
5051
return files.filePaths;
5152
});
5253

54+
ipcMain.handle("getZipFromFolder", async () => {
55+
return new Promise(async(resolve, reject) => {
56+
let folder = await dialog.showOpenDialog(mainWindow, {
57+
properties: ["openDirectory"],
58+
});
59+
60+
if(folder.filePaths.length === 1) {
61+
let zipPath = folder.filePaths[0];
62+
let tempPath = path.join(__dirname, "temp.zip");
63+
64+
zipPaths = [zipPath, tempPath];
65+
66+
return resolve(true);
67+
}
68+
69+
return reject(false);
70+
})
71+
});
72+
73+
ipcMain.handle("zipDirectory", async() => {
74+
return new Promise(async(resolve, reject) => {
75+
try {
76+
await zip(zipPaths[0], zipPaths[1]);
77+
const fileData = await fs.promises.readFile(zipPaths[1]);
78+
return resolve(fileData);
79+
} catch(error) {
80+
return reject(error);
81+
}
82+
})
83+
})
84+
5385
ipcMain.handle("getFileData", async (event, ...args) => {
5486
let data = fs.readFileSync(args[0], "utf8");
5587
return data;

doc/README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Frontend
2+
3+
This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 15.2.0.
4+
5+
## Common Issues
6+
- Run `npm ci` prior to building or running the app, otherwise you will be met with errors
7+
8+
## Development server
9+
10+
- Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The application will automatically reload if you change any of the source files. If file uploading is needed, please refer to `Run App`.
11+
12+
## Run App
13+
- Run `npm start` to launch electron app. This will not automatically reload and will need to be re-launched when code is updated.

frontend/changelog.md renamed to doc/changelog.md

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,24 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [v1.1.0] - (9/28/23)
9+
### Added
10+
- Can download `vex` and `metrics` reports
11+
- `Generate` SBOMS with both `OSI` and `Parsers`
12+
- `Filter` added to metrics
13+
- Can close opened menus on the right
14+
- Loading spinners added as indicators
15+
16+
### Changed
17+
- Corrected `Schema` header in file upload to `Format`
18+
- Fixed various scaling issues with all display resolutions
19+
- Removed `/frontend` folder and put `src` in root directory
20+
- Accordions now automatically close when a sibling is opened
21+
22+
### Known Issues
23+
- Repair Button doesn't do anything currently on metrics
24+
- Generation modal may get stuck open on errors
25+
826
## [v1.0.0] - (7/31/23)
927
### Added
1028
- `Uploading` SBOMS
@@ -28,4 +46,4 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2846
- `Sidepanel`: Sidepanel may have information pop off the screen or not fully close
2947
- `Comparison`: Information goes off screen and cannot be scrolled to
3048
- `Navbar`: There is no indication of buttons being disabled
31-
- `Vulnerabilities`: Vulnerabilities button is not shown to be disabled
49+
- `Vulnerabilities`: Vulnerabilities button is not shown to be disabled

frontend/.gitignore

Lines changed: 0 additions & 45 deletions
This file was deleted.

frontend/src/app/features/comparison/comparison.component.html

Lines changed: 0 additions & 34 deletions
This file was deleted.

frontend/src/app/features/comparison/comparison.component.ts

Lines changed: 0 additions & 37 deletions
This file was deleted.

frontend/src/app/shared/components/accordion/accordion.component.ts

Lines changed: 0 additions & 15 deletions
This file was deleted.

frontend/src/app/shared/components/menu/menu.component.html

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)