Skip to content

[ui] Sortinghat UI as a package#1025

Open
evamillan wants to merge 5 commits intochaoss:mainfrom
evamillan:integration-core
Open

[ui] Sortinghat UI as a package#1025
evamillan wants to merge 5 commits intochaoss:mainfrom
evamillan:integration-core

Conversation

@evamillan
Copy link
Copy Markdown
Contributor

@evamillan evamillan commented Nov 7, 2025

In order to integrate SortingHat's user interface into grimoirelab-core, this PR creates a package with the main views (dashboard, individuals and organizations) that can be installed in a separate Vue project. The package is generated and included in the release assets (a test release with the installable package can be found here).

@evamillan evamillan marked this pull request as draft November 7, 2025 12:25
@evamillan evamillan marked this pull request as ready for review December 29, 2025 14:35
Moves the Apollo provider to a configurable `setupApolloProvider` function.

Signed-off-by: Eva Millán <evamillan@bitergia.com>
Splits the Vuex workspace store into a reusable module.

Signed-off-by: Eva Millán <evamillan@bitergia.com>
Creates a Vue plugin in the `/package` directory that includes the
Dashboard, Individual and Organization views.

Signed-off-by: Eva Millán <evamillan@bitergia.com>
Changes the CSS and some Vuetify components to make them
look properly when embedded in another project.

Signed-off-by: Eva Millán <evamillan@bitergia.com>
Builds and attachs the UI package to the release.

Signed-off-by: Eva Millán <evamillan@bitergia.com>
Copy link
Copy Markdown
Member

@sduenas sduenas left a comment

Choose a reason for hiding this comment

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

Please check my comments. I found a problem while building the app.

Comment on lines +38 to +43
yarn pack --filename sortinghat-ui.tgz
- name: Upload UI artifact
uses: actions/upload-artifact@v4
with:
name: sortinghat-ui
path: ./ui/package/sortinghat-ui.tgz
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I think we should include the version in the name of the file. Follow the style of js packages.

current project. Use `yarn build --watch` to rebuild when the code changes.

```
cd sortinghat/ui/package
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
cd sortinghat/ui/package
cd ui/package


```
cd sortinghat/ui/package
yarn build
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Should we add the yarn install first (to update dependencies)?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I found this problem while building:

$ yarn build
You are using Node.js 20.11.1. Vite requires Node.js version 20.19+ or 22.12+. Please upgrade your Node.js version.
vite v7.1.10 building for production...
✓ 7 modules transformed.
✗ Build failed in 198ms
error during build:
[vite:vue] crypto.hash is not a function
file: /home/sduenas/devel/grimoirelab/sortinghat/ui/src/views/Dashboard.vue
    at getHash (file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/@vitejs/plugin-vue/dist/index.js:140:16)
    at createDescriptor (file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/@vitejs/plugin-vue/dist/index.js:89:23)
    at transformMain (file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/@vitejs/plugin-vue/dist/index.js:1633:33)
    at Object.handler (file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/@vitejs/plugin-vue/dist/index.js:2045:27)
    at Object.handler (file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/vite/dist/node/chunks/dep-B0GuR2De.js:33959:13)
    at file:///home/sduenas/devel/grimoirelab/sortinghat/ui/package/node_modules/rollup/dist/es/shared/node-entry.js:22426:40

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.

2 participants