From 57e835e75abd5db811474d4b0a2ae9383f4249d6 Mon Sep 17 00:00:00 2001 From: Taimoor Aslam Date: Thu, 6 Feb 2025 16:34:46 +0100 Subject: [PATCH] chore(heureka): initialise new heureka app (#751) * chore(heureka): initialise app * chore(heureka): add preview for new heureka app * refactor(heureka): change new app name to snakecase * refactor(heureka): fix PR preview for new heureka app * chore(heureka): add changeset * chore(heureka): add page header * refactor(heureka): remove ItemKeyType * refactor(heureka): change default to named exports * refactor(heureka): remove default exports completely --- .changeset/tame-worms-compare.md | 5 + .github/workflows/deploy-pr-preview.yaml | 15 +- apps/heureka-next/.gitignore | 30 + apps/heureka-next/LICENSE | 201 +++ apps/heureka-next/README.md | 13 + apps/heureka-next/eslint.config.mjs | 36 + apps/heureka-next/index.html | 13 + apps/heureka-next/package.json | 60 + apps/heureka-next/postcss.config.mjs | 6 + apps/heureka-next/src/App.tsx | 22 + apps/heureka-next/src/assets/favicon.ico | Bin 0 -> 15086 bytes .../ErrorBoundary/ErrorBoundary.test.tsx | 42 + .../ErrorBoundary/ErrorBoundary.tsx | 12 + .../ErrorBoundary/ErrorFallback.tsx | 11 + .../src/components/ErrorBoundary/index.ts | 6 + .../src/components/Images/Images.test.tsx | 15 + .../src/components/Images/Images.tsx | 8 + .../src/components/Images/index.ts | 6 + .../components/Navigation/Navigation.test.tsx | 30 + .../src/components/Navigation/Navigation.tsx | 48 + .../src/components/Navigation/index.ts | 6 + .../src/components/Services/Services.test.tsx | 15 + .../src/components/Services/Services.tsx | 8 + .../src/components/Services/index.ts | 6 + .../src/components/Shell/Shell.test.tsx | 38 + .../src/components/Shell/Shell.tsx | 36 + .../Shell/ShellContent/ShellContent.tsx | 23 + .../components/Shell/ShellContent/index.ts | 6 + .../src/components/Shell/index.ts | 6 + .../Vulnerabilities/Vulnerabilities.test.tsx | 15 + .../Vulnerabilities/Vulnerabilities.tsx | 8 + .../src/components/Vulnerabilities/index.ts | 6 + apps/heureka-next/src/constants/index.ts | 8 + apps/heureka-next/src/index.scss | 11 + apps/heureka-next/src/index.tsx | 10 + apps/heureka-next/src/styles.scss | 9 + apps/heureka-next/src/types/index.d.ts | 7 + apps/heureka-next/tailwind.config.mjs | 17 + apps/heureka-next/tsconfig.json | 33 + apps/heureka-next/turbo.json | 20 + apps/heureka-next/vite.config.ts | 59 + apps/heureka-next/vitest.config.ts | 15 + apps/heureka-next/vitest.setup.ts | 14 + package-lock.json | 1525 +++++++++++++---- 44 files changed, 2146 insertions(+), 334 deletions(-) create mode 100644 .changeset/tame-worms-compare.md create mode 100644 apps/heureka-next/.gitignore create mode 100644 apps/heureka-next/LICENSE create mode 100644 apps/heureka-next/README.md create mode 100644 apps/heureka-next/eslint.config.mjs create mode 100644 apps/heureka-next/index.html create mode 100644 apps/heureka-next/package.json create mode 100644 apps/heureka-next/postcss.config.mjs create mode 100644 apps/heureka-next/src/App.tsx create mode 100644 apps/heureka-next/src/assets/favicon.ico create mode 100644 apps/heureka-next/src/components/ErrorBoundary/ErrorBoundary.test.tsx create mode 100644 apps/heureka-next/src/components/ErrorBoundary/ErrorBoundary.tsx create mode 100644 apps/heureka-next/src/components/ErrorBoundary/ErrorFallback.tsx create mode 100644 apps/heureka-next/src/components/ErrorBoundary/index.ts create mode 100644 apps/heureka-next/src/components/Images/Images.test.tsx create mode 100644 apps/heureka-next/src/components/Images/Images.tsx create mode 100644 apps/heureka-next/src/components/Images/index.ts create mode 100644 apps/heureka-next/src/components/Navigation/Navigation.test.tsx create mode 100644 apps/heureka-next/src/components/Navigation/Navigation.tsx create mode 100644 apps/heureka-next/src/components/Navigation/index.ts create mode 100644 apps/heureka-next/src/components/Services/Services.test.tsx create mode 100644 apps/heureka-next/src/components/Services/Services.tsx create mode 100644 apps/heureka-next/src/components/Services/index.ts create mode 100644 apps/heureka-next/src/components/Shell/Shell.test.tsx create mode 100644 apps/heureka-next/src/components/Shell/Shell.tsx create mode 100644 apps/heureka-next/src/components/Shell/ShellContent/ShellContent.tsx create mode 100644 apps/heureka-next/src/components/Shell/ShellContent/index.ts create mode 100644 apps/heureka-next/src/components/Shell/index.ts create mode 100644 apps/heureka-next/src/components/Vulnerabilities/Vulnerabilities.test.tsx create mode 100644 apps/heureka-next/src/components/Vulnerabilities/Vulnerabilities.tsx create mode 100644 apps/heureka-next/src/components/Vulnerabilities/index.ts create mode 100644 apps/heureka-next/src/constants/index.ts create mode 100644 apps/heureka-next/src/index.scss create mode 100644 apps/heureka-next/src/index.tsx create mode 100644 apps/heureka-next/src/styles.scss create mode 100644 apps/heureka-next/src/types/index.d.ts create mode 100644 apps/heureka-next/tailwind.config.mjs create mode 100644 apps/heureka-next/tsconfig.json create mode 100644 apps/heureka-next/turbo.json create mode 100644 apps/heureka-next/vite.config.ts create mode 100644 apps/heureka-next/vitest.config.ts create mode 100644 apps/heureka-next/vitest.setup.ts diff --git a/.changeset/tame-worms-compare.md b/.changeset/tame-worms-compare.md new file mode 100644 index 000000000..72d930819 --- /dev/null +++ b/.changeset/tame-worms-compare.md @@ -0,0 +1,5 @@ +--- +"heureka-next": minor +--- + +Initialise new Heureka app. diff --git a/.github/workflows/deploy-pr-preview.yaml b/.github/workflows/deploy-pr-preview.yaml index 23c450ae9..2b0a95983 100644 --- a/.github/workflows/deploy-pr-preview.yaml +++ b/.github/workflows/deploy-pr-preview.yaml @@ -26,6 +26,7 @@ on: - "apps/carbon/**" - "apps/greenhouse/**" - "apps/example/**" + - "apps/heureka-next/**" # Limit the concurrency of entire workflow concurrency: deploy-pr-preview-${{ github.ref }} @@ -58,6 +59,7 @@ jobs: echo "IS_CARBON_CHANGED=${{ contains(needs.run-detect-changes.outputs.changes, 'carbon') }}" >> $GITHUB_ENV echo "IS_GREENHOUSE_CHANGED=${{ contains(needs.run-detect-changes.outputs.changes, 'greenhouse') }}" >> $GITHUB_ENV echo "IS_EXAMPLE_CHANGED=${{ contains(needs.run-detect-changes.outputs.changes, 'example') || contains(needs.run-detect-changes.outputs.changes, 'ui-components') }}" >> $GITHUB_ENV + echo "IS_HEUREKA_NEXT_CHANGED=${{ contains(needs.run-detect-changes.outputs.changes, 'heureka-next') }}" >> $GITHUB_ENV # setup ENVs for each app to add query params echo "GREENHOUSE_QUERY_PARAMS=org=demo" >> $GITHUB_ENV @@ -146,6 +148,16 @@ jobs: TARGET_FOLDER: example continue-on-error: true + - name: Build HEUREKA_NEXT if changes detected + id: build-heureka-next + if: github.event.action != 'closed' && env.IS_HEUREKA_NEXT_CHANGED == 'true' + run: ./.github/scripts/build-vite-app.sh + env: + PACKAGE_PATH: apps/heureka-next + TARGET_FOLDER: heureka_next + APP_PROPS_BASE64: ${{ secrets.HEUREKA_NEXT_APP_PROPS_BASE64 }} + continue-on-error: true + - name: Generate index.html for Deployed Apps if: github.event.action != 'closed' env: @@ -156,11 +168,12 @@ jobs: CARBON_OUTCOME: "${{ steps.build-carbon.outcome }}" GREENHOUSE_OUTCOME: "${{ steps.build-greenhouse.outcome }}" EXAMPLE_OUTCOME: "${{ steps.build-example.outcome }}" + HEUREKA_NEXT_OUTCOME: "${{ steps.build-heureka-next.outcome }}" run: | echo "PR Preview

Deployed Packages for PR ${GITHUB_HEAD_REF}