Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RacksDB web UI #32

Merged
merged 150 commits into from
Dec 22, 2023
Merged

RacksDB web UI #32

merged 150 commits into from
Dec 22, 2023

Conversation

florianLSP
Copy link
Contributor

fix #7

Copy link
Contributor

@rezib rezib left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix following errors reported by eslint:

$ npm run lint

> ui@0.0.0 lint
> eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore


/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/postcss.config.js
  1:1  error  'module' is not defined  no-undef

/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/tailwind.config.js
  2:1  error  'module' is not defined  no-undef

✖ 2 problems (2 errors, 0 warnings)

Also please reformat your code with prettier for more consistency:

$ npm run format

And fix the following type-check error:

$ npm run type-check

> ui@0.0.0 type-check
> vue-tsc --noEmit -p tsconfig.vitest.json --composite false

src/components/InfrastructureContentCard.vue:62:157 - error TS2345: Argument of type 'string' is not assignable to parameter of type '"nodes" | "storage" | "network"'.

62                         <span class="text-base font-normal leading-tight  dark:text-gray-400 capitalize text-purple-700 cursor-pointer" @click="popUp(name, equipment)">{{ id }}</span>
                                                                                                                                                               ~~~~~~~~~


Found 1 error in src/components/InfrastructureContentCard.vue:62

Please also add mention to copyright and license in SPDX format in all source code files header.

Also please add newline at the end of your files. For the record, this can de done automatically in VSCode with files.insertFinalNewline: true setting.

Some methods (ex: getDatacenters()) are duplicated in multiple views and components. I think you should introduce a composable to define all interfaces/types (Datacenter, Room, Infrastructures, etc) with all methods to request the API. Then all views and components could use this composable to import types/interfaces and request the API.

Have you tested the UI with multiple datacenters, multiple rooms in a datacenter and multiple infrastructures? We could work together on the definition of such an example database if needed.

racksdb/web/ui/.gitignore Outdated Show resolved Hide resolved
racksdb/web/ui/.vscode/extensions.json Outdated Show resolved Hide resolved
racksdb/web/ui/README.md Outdated Show resolved Hide resolved
racksdb/web/ui/package.json Outdated Show resolved Hide resolved
racksdb/web/ui/package.json Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/InfrastructureDetailsView.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/InfrastructureDetailsView.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/InfrastructureDetailsView.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/InfrastructureDetailsView.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/InfrastructureDetailsView.vue Outdated Show resolved Hide resolved
@rezib rezib changed the title RacksDB web app RacksDB web UI Nov 9, 2023
@rezib rezib self-requested a review December 13, 2023 10:20
Copy link
Contributor

@rezib rezib left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please fix this:

$ npm run lint

> racksdb-webui@0.2.0 lint
> eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore


Oops! Something went wrong! :(

ESLint: 8.50.0

Error: Cannot read .eslintignore file: /home/remi/Documents/git/products/RacksDB/racksdb/web/ui/.gitignore
Error: ENOENT: no such file or directory, open '/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/.gitignore'
    at Object.openSync (node:fs:603:3)
    at Object.readFileSync (node:fs:471:35)
    at readFile (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/@eslint/eslintrc/dist/eslintrc.cjs:2491:35)
    at loadESLintIgnoreFile (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/@eslint/eslintrc/dist/eslintrc.cjs:2619:16)
    at ConfigArrayFactory.loadESLintIgnore (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/@eslint/eslintrc/dist/eslintrc.cjs:2925:32)
    at createCLIConfigArray (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/@eslint/eslintrc/dist/eslintrc.cjs:3643:34)
    at new CascadingConfigArrayFactory (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/@eslint/eslintrc/dist/eslintrc.cjs:3724:29)
    at new CLIEngine (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/eslint/lib/cli-engine/cli-engine.js:617:36)
    at new ESLint (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/eslint/lib/eslint/eslint.js:430:27)
    at Object.execute (/home/remi/Documents/git/products/RacksDB/racksdb/web/ui/node_modules/eslint/lib/cli.js:382:24)

Also please re-run npm run format.

Please ensure new line is present at the end of all files.

.vscode/settings.json Outdated Show resolved Hide resolved
docs/modules/overview/images/logo_racksdb.svg Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
racksdb/web/ui/public/assets/logo_racksdb.svg Outdated Show resolved Hide resolved
racksdb/web/ui/public/favicon.ico Outdated Show resolved Hide resolved
racksdb/web/ui/src/components/HeaderPage.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/components/HeaderPage.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/components/HomeViewCard.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/views/HomeView.vue Outdated Show resolved Hide resolved
racksdb/web/ui/src/composables/RacksDBIMG.ts Outdated Show resolved Hide resolved
florianLSP and others added 20 commits December 14, 2023 10:10
fix: changed the name of the link picture
feat: now the component uses the API to get the data to display in the homeview
@rezib rezib merged commit fd9153c into main Dec 22, 2023
rezib pushed a commit that referenced this pull request Dec 22, 2023
This commit introduces a brand new web UI to explore RacksDB content in
a web browser. This feature is a technology preview in beta version.

The frontend of this UI is developed in Typescript with Vue.js
framework and Tailwind CSS UI toolkit. The backend is the existing
RacksDB REST API. Documentation to install and use this web UI is
planned, along with many improvements in terms of design and usability.
@rezib rezib deleted the ui branch January 10, 2024 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide tiny web app to explore DB content
2 participants