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

enhance(apps/frontend-manage): replace navigation on lecturer frontend #4469

Merged
merged 4 commits into from
Jan 20, 2025

Conversation

sjschlapbach
Copy link
Member

@sjschlapbach sjschlapbach commented Jan 18, 2025

Before merging, complete the following tasks:

  • Replace favicon through higher resolution version of small icon
  • Extract navigation component to design-system?
Screenshot 2025-01-18 at 11 46 02 Screenshot 2025-01-18 at 11 46 51

Summary by CodeRabbit

  • Dependency Updates

    • Updated @uzh-bf/design-system to version 3.0.0-alpha.47 across multiple packages and applications
  • Localization

    • Added new analytics-related translation keys in German and English localization files
  • UI Improvements

    • Minor adjustments to button heights in the Live Quiz Timeline component
    • Updated navigation structure in the Header component
    • Enhanced rendering of the navigation component in the DocsLayout

Copy link

coderabbitai bot commented Jan 18, 2025

📝 Walkthrough

Walkthrough

This pull request involves an update of the @uzh-bf/design-system dependency across multiple packages in the KlickerUZH project. The version is updated from 3.0.0-alpha.42 to 3.0.0-alpha.47 in various package.json files across different applications and packages. Additionally, new localization keys related to analytics have been added in both German and English translation files, and there are significant modifications to the Header and DocsLayout components, including changes to navigation structures and rendering logic.

Changes

File/Path Change Summary
apps/*/package.json Updated @uzh-bf/design-system from 3.0.0-alpha.42 to 3.0.0-alpha.47 in multiple packages including auth, backend-docker, docs, frontend-control, frontend-manage, frontend-pwa, func-incoming-responses, func-response-processor, and office-addin
packages/*/package.json Updated @uzh-bf/design-system from 3.0.0-alpha.42 to 3.0.0-alpha.47 in markdown, shared-components, and transactional packages
packages/i18n/messages/de.ts Added new analytics-related localization keys: activity, performance, quizzes, olderCourses
packages/i18n/messages/en.ts Added new analytics-related localization keys: activity, performance, quizzes, olderCourses
apps/frontend-manage/src/components/common/Header.tsx Refactored navigation structure, updated import statements, added new GraphQL queries, and simplified rendering logic
apps/frontend-manage/src/components/liveQuiz/cockpit/LiveQuizTimeline.tsx Reduced button heights from h-10 to h-8, minor icon adjustments
apps/frontend-pwa/src/components/docs/DocsLayout.tsx Updated navigation rendering logic, removed dynamic class name function, and streamlined navigation item structure

Possibly related PRs


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR. (Beta)
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (9)
apps/frontend-manage/src/components/liveQuiz/cockpit/LiveQuizTimeline.tsx (1)

168-168: Consider consistent icon sizing across all buttons.

While adjusting the icon size with h-4 makes sense with the reduced button height, this explicit sizing is only applied to one icon. Consider applying consistent sizing to all button icons in this component.

- <FontAwesomeIcon icon={faUpRightFromSquare} className="h-4" />
+ <FontAwesomeIcon icon={faUpRightFromSquare} />

And update the Button.Icon component's default styling in the design system to handle icon sizing consistently.

packages/markdown/package.json (1)

43-43: Consider using a version range for peer dependencies.

The strict version requirement "3.0.0-alpha.45" for @uzh-bf/design-system in peerDependencies might cause compatibility issues. Consider using a version range (e.g., "^3.0.0-alpha.45") to allow minor updates.

-    "@uzh-bf/design-system": "3.0.0-alpha.45",
+    "@uzh-bf/design-system": "^3.0.0-alpha.45",
apps/frontend-manage/src/components/common/Header.tsx (3)

30-30: Address the TODO: Generalize the query for the new catalogue

There's a TODO comment indicating that the GetCollectionSharingRequestsDocument query needs to be generalized for the new catalogue. Do you need assistance with this task?

Do you want me to help with generalizing this query or open a GitHub issue to track this task?


Line range hint 208-239: Avoid rendering empty dropdown when disabled

Currently, when the dropdown is disabled, the MenubarTrigger is still rendered, which might confuse users as it appears interactive. To improve user experience, consider not rendering the dropdown at all when it's disabled.

Apply this diff to conditionally render the dropdown:

        <MenubarMenu>
+         {!disabled && (
          <MenubarTrigger
            disabled={disabled}
            data-cy={data?.cy}
            data-test={data?.test}
            className={twMerge(
              'text-base hover:cursor-pointer',
              hasIconAndLabel && 'flex flex-row items-center gap-2',
              !iconOnly && !disabled && dynamicUnderline,
              active && 'text-black after:scale-x-100',
              disabled && 'hover:cursor-not-allowed',
              className?.trigger
            )}
          >
            {/* Trigger content */}
          </MenubarTrigger>
          {!disabled ? (
            <MenubarContent className={className?.content}>
              {/* Content */}
            </MenubarContent>
          ) : null}
+         )}
        </MenubarMenu>

Line range hint 208-239: Simplify conditional rendering of MenubarContent

The current conditional rendering of MenubarContent uses a ternary operator that returns null when the dropdown is disabled. This can be simplified for better readability.

Apply this diff to simplify the conditional rendering:

          {!disabled ? (
            <MenubarContent className={className?.content}>
              {/* Content */}
            </MenubarContent>
-          ) : null}
+          )}
apps/frontend-manage/src/components/common/Navigation.tsx (4)

1-1: Address the TODO: Extract component to design system

There's a TODO comment indicating that this Navigation component should be extracted to the design system with generalized props. Do you need assistance with this task?

Do you want me to help with extracting this component to the design system or open a GitHub issue to track this task?


59-60: Simplify boolean expressions

The boolean expressions used to determine hasIconAndLabel and iconOnly can be simplified for clarity.

Apply this diff to simplify the expressions:

-      const hasIconAndLabel =
-        typeof label !== 'undefined' && typeof icon !== 'undefined'
-      const iconOnly = typeof label === 'undefined' && typeof icon !== 'undefined'
+      const hasIconAndLabel = label && icon
+      const iconOnly = !label && icon

74-75: Improve disabled state styling

When the button is disabled, it still has the hover:cursor-not-allowed class, but the hover pseudo-class is unnecessary as the cursor should always reflect the disabled state.

Apply this diff to adjust the styling:

-              disabled && 'hover:cursor-not-allowed',
+              disabled && 'cursor-not-allowed',

220-221: Consistent class names in NavigationDropdown

In NavigationDropdown, the className for the submenu trigger uses className?.label, which might be confusing. Ensure that class names are consistently named and applied.

Apply this diff to rename the className property:

          <MenubarSubTrigger
            className={twMerge(
              'h-8 text-base hover:cursor-pointer',
-             className?.label
+             element.className?.label
            )}
          >
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2a4475c and 7e175b8.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (17)
  • apps/auth/package.json (1 hunks)
  • apps/backend-docker/package.json (1 hunks)
  • apps/docs/package.json (1 hunks)
  • apps/frontend-control/package.json (1 hunks)
  • apps/frontend-manage/package.json (1 hunks)
  • apps/frontend-manage/src/components/common/Header.tsx (2 hunks)
  • apps/frontend-manage/src/components/common/Navigation.tsx (1 hunks)
  • apps/frontend-manage/src/components/liveQuiz/cockpit/LiveQuizTimeline.tsx (3 hunks)
  • apps/frontend-pwa/package.json (1 hunks)
  • apps/func-incoming-responses/package.json (1 hunks)
  • apps/func-response-processor/package.json (1 hunks)
  • apps/office-addin/package.json (1 hunks)
  • packages/i18n/messages/de.ts (1 hunks)
  • packages/i18n/messages/en.ts (1 hunks)
  • packages/markdown/package.json (1 hunks)
  • packages/shared-components/package.json (1 hunks)
  • packages/transactional/package.json (1 hunks)
✅ Files skipped from review due to trivial changes (6)
  • packages/shared-components/package.json
  • apps/office-addin/package.json
  • apps/frontend-manage/package.json
  • apps/auth/package.json
  • apps/backend-docker/package.json
  • apps/frontend-pwa/package.json
⏰ Context from checks skipped due to timeout of 90000ms (2)
  • GitHub Check: SonarCloud
  • GitHub Check: cypress-run
🔇 Additional comments (10)
apps/frontend-manage/src/components/liveQuiz/cockpit/LiveQuizTimeline.tsx (2)

118-118: LGTM! Consistent button height adjustments.

The height reduction from h-10 to h-8 has been consistently applied across all buttons in the control panel section, maintaining UI uniformity.

Also applies to: 146-146, 163-163, 182-182


Line range hint 176-190: LGTM! Well-implemented feedback quiz section.

The feedback quiz conditional block is well-implemented with:

  • Consistent button styling and height
  • Proper use of twMerge for class composition
  • Appropriate conditional rendering
packages/i18n/messages/en.ts (1)

2033-2036: LGTM! Analytics section enhanced with new categories.

The new translation keys provide better categorization for analytics features. The translations are consistent with their German counterparts.

Let's verify that all new keys have corresponding translations in the German file:

✅ Verification successful

✓ All analytics keys are properly translated

All new analytics keys (activity, performance, quizzes, olderCourses) have corresponding and semantically correct translations in the German language file.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify that all new analytics keys exist in both language files
# and have appropriate translations

echo "Checking for new analytics keys in both language files..."

# Check English keys
rg "activity: '.*'" packages/i18n/messages/en.ts
rg "performance: '.*'" packages/i18n/messages/en.ts
rg "quizzes: '.*'" packages/i18n/messages/en.ts
rg "olderCourses: '.*'" packages/i18n/messages/en.ts

# Check German translations
rg "activity: '.*'" packages/i18n/messages/de.ts
rg "performance: '.*'" packages/i18n/messages/de.ts
rg "quizzes: '.*'" packages/i18n/messages/de.ts
rg "olderCourses: '.*'" packages/i18n/messages/de.ts

Length of output: 979

packages/i18n/messages/de.ts (1)

2050-2053: LGTM! German translations added for new analytics categories.

The German translations are appropriate and maintain consistency with the English version.

packages/transactional/package.json (1)

11-11: Verify the design system version update impact.

The @uzh-bf/design-system dependency has been updated from 3.0.0-alpha.42 to 3.0.0-alpha.45.

Let's verify the consistency of the design system version across all package.json files:

✅ Verification successful

Design system version update verified successfully

The @uzh-bf/design-system dependency has been consistently updated to version 3.0.0-alpha.45 across all packages. As this is a minor alpha version bump, the update should be safe, but standard testing procedures are recommended to catch any potential visual or functional regressions.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify design system version consistency across all package.json files
# and check for any breaking changes in the version update

# Check all package.json files for design system version
echo "Checking design system version across all package.json files..."
rg -A 1 '"@uzh-bf/design-system"' '**/package.json'

# Look for any migration guides or breaking changes
echo "Checking for migration guides or breaking changes..."
rg -i "breaking.*change" "CHANGELOG.md"

Length of output: 401


Script:

#!/bin/bash
# Find all package.json files and check for design system dependency
echo "Checking design system versions in package.json files..."
fd package.json --type f --exec grep -A 1 "@uzh-bf/design-system" {} \;

# Look for any documentation files that might contain breaking changes
echo -e "\nChecking for breaking changes in documentation..."
fd -e md -e mdx --type f --exec grep -l -i "breaking.*changes\|migration" {} \;

# Check actual usage of design system components
echo -e "\nChecking design system component usage..."
rg -l "@uzh-bf/design-system"

Length of output: 25213

apps/func-incoming-responses/package.json (1)

19-19: LGTM! Design system version update is consistent.

The @uzh-bf/design-system dependency update matches other package updates in the PR.

apps/func-response-processor/package.json (1)

21-21: Verify compatibility with other dependencies.

The update to @uzh-bf/[email protected] is an alpha version. Since this is used as a development dependency, ensure it's compatible with other related packages.

Run this script to check for potential version conflicts:

✅ Verification successful

Version compatibility verified ✓

All packages in the monorepo are using the same version (3.0.0-alpha.45) of @uzh-bf/design-system, ensuring consistent dependency management.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Check for potential version conflicts with @uzh-bf/design-system
# Look for other packages that might depend on different versions of @uzh-bf/design-system

# Search for dependencies on @uzh-bf/design-system across all package.json files
fd package.json --exec jq -r 'select(.dependencies."@uzh-bf/design-system" or .devDependencies."@uzh-bf/design-system" or .peerDependencies."@uzh-bf/design-system") | "\(.name): \(.dependencies."@uzh-bf/design-system" // .devDependencies."@uzh-bf/design-system" // .peerDependencies."@uzh-bf/design-system")"'

Length of output: 832

apps/docs/package.json (1)

25-25: Verify documentation site compatibility.

The update to @uzh-bf/[email protected] in the documentation project should be tested to ensure no visual regressions in the documentation site.

Run this script to check for design system component usage in documentation:

apps/frontend-control/package.json (1)

20-20: Test UI components after design system update.

Since this is a frontend application and the PR involves navigation changes, ensure that all UI components using @uzh-bf/design-system are thoroughly tested after the update to version 3.0.0-alpha.45.

Run this script to identify affected components:

apps/frontend-manage/src/components/common/Header.tsx (1)

85-113: ⚠️ Potential issue

Ensure safe usage of spread operator with potentially undefined arrays

When using the spread operator with courses?.slice(0, 5).map(...), if courses is undefined, it could cause a runtime error because spreading undefined is not allowed. To prevent this, ensure that courses is always an array.

Initialize courses to an empty array if it's undefined:

-      const courses = courseData?.userCourses
+      const courses = courseData?.userCourses ?? []

This way, courses.slice(0, 5).map(...) will not throw an error even if courses is undefined.

Likely invalid or redundant comment.

apps/frontend-manage/src/components/common/Header.tsx Outdated Show resolved Hide resolved
apps/frontend-manage/src/components/common/Header.tsx Outdated Show resolved Hide resolved
Copy link

cypress bot commented Jan 18, 2025

klicker-uzh    Run #4116

Run Properties:  status check passed Passed #4116  •  git commit 708f647be2 ℹ️: Merge 79875d5890b5a9c0132bb8ed8527f4d580de42c9 into 2a4475cea5eae14ea651191257c8...
Project klicker-uzh
Branch Review new-navigation-manage
Run status status check passed Passed #4116
Run duration 17m 24s
Commit git commit 708f647be2 ℹ️: Merge 79875d5890b5a9c0132bb8ed8527f4d580de42c9 into 2a4475cea5eae14ea651191257c8...
Committer Julius Schlapbach
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 0
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 272
View all changes introduced in this branch ↗︎

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
apps/frontend-manage/src/components/common/Header.tsx (1)

85-113: Consider extracting course analytics menu configuration

The nested course analytics menu configuration is complex and could benefit from extraction into a separate function for better maintainability.

+ const getCourseAnalyticsMenu = (course: Course) => ({
+   key: `course-analytics-${course.id}`,
+   type: 'submenu' as const,
+   label: course.name,
+   data: { cy: `course-analytics-menu-${course.name}` },
+   options: [
+     {
+       key: `activity-dashboard-${course.name}`,
+       type: 'link' as const,
+       label: t('manage.analytics.activity'),
+       onClick: () => router.push(`/analytics/${course.id}/activity`),
+     },
+     // ... other options
+   ],
+ })

  elements: [
-   ...(courses?.slice(0, 5).map((course) => ({
-     key: `course-analytics-${course.id}`,
-     type: 'submenu',
-     // ... rest of the configuration
-   })) ?? []),
+   ...(courses?.slice(0, 5).map(getCourseAnalyticsMenu) ?? []),
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7e175b8 and 2adbcad.

📒 Files selected for processing (1)
  • apps/frontend-manage/src/components/common/Header.tsx (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (9)
  • GitHub Check: check
  • GitHub Check: build
  • GitHub Check: SonarCloud
  • GitHub Check: build
  • GitHub Check: cypress-run
  • GitHub Check: build
  • GitHub Check: build
  • GitHub Check: build
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (4)
apps/frontend-manage/src/components/common/Header.tsx (4)

30-30: Address TODO comment about query generalization

The comment indicates that the collection sharing requests query needs to be generalized for the new catalogue.

Would you like me to help implement the generalized query for the new catalogue?


31-36: Verify the impact of cache-first fetch policy

The cache-first fetch policy has been added to both queries. While this can improve performance, ensure that it doesn't prevent users from seeing real-time updates to their quizzes and courses.

Consider using cache-and-network if real-time updates are important for these queries.


207-213: Address TODO comment about favicon replacement

The comment indicates that the favicon needs to be replaced with a high-resolution version with specific requirements.

Would you like me to help create a task for updating the favicon with the specified requirements:

  • High resolution
  • Transparent background
  • Different gray logo

202-204: Verify keyboard navigation functionality

While the navigation implementation looks good, please ensure that keyboard navigation works correctly across all menu items and dropdowns.

Test the following scenarios:

  • Tab navigation through all menu items
  • Enter/Space to activate buttons
  • Arrow keys for dropdown navigation
  • Escape key to close dropdowns

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (3)
apps/frontend-manage/src/components/common/Header.tsx (3)

85-113: Consider pagination or scrolling for courses in analytics dropdown.

The current implementation limits the course list to 5 items (courses?.slice(0, 5)). This might not be optimal if a user has many courses.

Consider implementing one of these solutions:

  1. Add scrolling to the dropdown menu
  2. Implement pagination
  3. Show a "View More" option that expands the list

Would you like me to provide an implementation for any of these solutions?


207-213: Enhance image accessibility and navigation.

The clickable logo should be wrapped in a button or anchor tag for better accessibility. Also, consider using Next.js Link component for consistent navigation.

-          <Image
-            src="/img/klicker_icon_transparent.png"
-            alt="KlickerUZH Logo"
-            width={35}
-            height={35}
-            onClick={() => router.push('/')}
-            className="hover:cursor-pointer"
-          />
+          <Link href="/" aria-label="Home">
+            <Image
+              src="/img/klicker_icon_transparent.png"
+              alt="KlickerUZH Logo"
+              width={35}
+              height={35}
+              className="hover:cursor-pointer"
+            />
+          </Link>

202-204: Add ARIA landmark for navigation.

The navigation container should have an ARIA role for better accessibility.

   <div
     className="flex h-full w-full flex-row items-center justify-between border-b border-slate-300 bg-slate-100 font-bold text-slate-700 print:!hidden"
     data-cy="navigation"
+    role="navigation"
+    aria-label="Main"
   >
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2adbcad and 2efab6b.

⛔ Files ignored due to path filters (2)
  • apps/frontend-manage/public/img/klicker_icon_transparent.png is excluded by !**/*.png
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (13)
  • apps/auth/package.json (1 hunks)
  • apps/backend-docker/package.json (1 hunks)
  • apps/docs/package.json (1 hunks)
  • apps/frontend-control/package.json (1 hunks)
  • apps/frontend-manage/package.json (1 hunks)
  • apps/frontend-manage/src/components/common/Header.tsx (2 hunks)
  • apps/frontend-pwa/package.json (1 hunks)
  • apps/func-incoming-responses/package.json (1 hunks)
  • apps/func-response-processor/package.json (1 hunks)
  • apps/office-addin/package.json (1 hunks)
  • packages/markdown/package.json (1 hunks)
  • packages/shared-components/package.json (1 hunks)
  • packages/transactional/package.json (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (12)
  • apps/docs/package.json
  • apps/frontend-manage/package.json
  • apps/auth/package.json
  • apps/office-addin/package.json
  • apps/func-incoming-responses/package.json
  • apps/backend-docker/package.json
  • packages/transactional/package.json
  • packages/shared-components/package.json
  • apps/frontend-pwa/package.json
  • packages/markdown/package.json
  • apps/frontend-control/package.json
  • apps/func-response-processor/package.json
⏰ Context from checks skipped due to timeout of 90000ms (7)
  • GitHub Check: cypress-run
  • GitHub Check: build
  • GitHub Check: build
  • GitHub Check: build
  • GitHub Check: SonarCloud
  • GitHub Check: check
  • GitHub Check: Analyze (javascript)
🔇 Additional comments (3)
apps/frontend-manage/src/components/common/Header.tsx (3)

30-30: Address the TODO comment regarding query generalization.

The comment indicates a need to generalize the collection sharing requests query for the new catalogue. This should be addressed before the PR is merged.

Would you like me to help implement the generalized query for the new catalogue?


31-36: LGTM! Appropriate fetch policy for navigation data.

The use of cache-first fetch policy is well-suited for navigation-related data that doesn't require frequent updates.


144-150: LGTM! Fixed dropdown disable logic.

The condition !quizzes || quizzes.length === 0 correctly handles both undefined and empty cases. The conditional styling is also properly implemented.

Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
9.8% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
apps/frontend-pwa/src/components/docs/DocsLayout.tsx (1)

50-50: Avoid using Tailwind's important modifier (!)

The !rounded-b-none class uses Tailwind's important modifier, which can lead to maintainability issues. Consider managing this style through proper component composition or CSS specificity instead.

-          className={{ root: 'w-full !rounded-b-none bg-slate-200' }}
+          className={{ root: 'w-full rounded-none bg-slate-200' }}
📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2efab6b and 79875d5.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (13)
  • apps/auth/package.json (1 hunks)
  • apps/backend-docker/package.json (1 hunks)
  • apps/docs/package.json (1 hunks)
  • apps/frontend-control/package.json (1 hunks)
  • apps/frontend-manage/package.json (1 hunks)
  • apps/frontend-pwa/package.json (1 hunks)
  • apps/frontend-pwa/src/components/docs/DocsLayout.tsx (1 hunks)
  • apps/func-incoming-responses/package.json (1 hunks)
  • apps/func-response-processor/package.json (1 hunks)
  • apps/office-addin/package.json (1 hunks)
  • packages/markdown/package.json (1 hunks)
  • packages/shared-components/package.json (1 hunks)
  • packages/transactional/package.json (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (12)
  • apps/frontend-pwa/package.json
  • apps/docs/package.json
  • packages/shared-components/package.json
  • apps/auth/package.json
  • apps/backend-docker/package.json
  • packages/markdown/package.json
  • apps/office-addin/package.json
  • apps/func-incoming-responses/package.json
  • apps/frontend-control/package.json
  • packages/transactional/package.json
  • apps/func-response-processor/package.json
  • apps/frontend-manage/package.json
⏰ Context from checks skipped due to timeout of 90000ms (2)
  • GitHub Check: SonarCloud
  • GitHub Check: cypress-run
🔇 Additional comments (1)
apps/frontend-pwa/src/components/docs/DocsLayout.tsx (1)

92-92: LGTM! Well-structured content styling

The content wrapper styling is well-implemented using Tailwind's prose classes with appropriate customizations for images and spacing.

@sjschlapbach sjschlapbach merged commit 39d3b8f into v3-new-elements Jan 20, 2025
16 of 18 checks passed
@sjschlapbach sjschlapbach deleted the new-navigation-manage branch January 20, 2025 16:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant