Skip to content

133 implement redesigned gym booking tornaterem igénylés page#173

Open
DankaMarci wants to merge 2 commits into
mainfrom
133-implement-redesigned-gym-booking-tornaterem-igénylés-page

Hidden character warning

The head ref may contain hidden characters: "133-implement-redesigned-gym-booking-tornaterem-ig\u00e9nyl\u00e9s-page"
Open

133 implement redesigned gym booking tornaterem igénylés page#173
DankaMarci wants to merge 2 commits into
mainfrom
133-implement-redesigned-gym-booking-tornaterem-igénylés-page

Conversation

@DankaMarci

@DankaMarci DankaMarci commented Jul 3, 2026

Copy link
Copy Markdown
Collaborator

Summary by CodeRabbit

  • New Features

    • Added formatted subtitles to the sport support and sports hall pages.
    • Improved page layouts with clearer section cards, lists, notices, and warnings.
    • Page headers now support rich formatted content in subtitles and descriptions.
  • Bug Fixes

    • Standardized content presentation across sport information pages.
    • Improved formatting for lists and descriptive text.

@DankaMarci DankaMarci requested a review from peterlipt July 3, 2026 14:30
@DankaMarci DankaMarci self-assigned this Jul 3, 2026
@DankaMarci DankaMarci linked an issue Jul 3, 2026 that may be closed by this pull request
4 tasks
@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ehk Ready Ready Preview, Comment Jul 3, 2026 2:31pm

Request Review

@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

The PR updates two sport support pages to display parsed descriptions in PageHeader, broadens PageHeader content types to ReactNode, and refactors both content components into reusable section, paragraph, list, notice, and warning helpers.

Changes

Sport support page redesign

Layer / File(s) Summary
Page header contract and page wiring
src/components/common/PageHeader.tsx, src/app/(app)/[lang]/sport/*/page.tsx
PageHeader accepts React nodes for subtitle and description, while both pages parse descriptions and pass aliased content through updated layouts.
Gym support section rendering
src/app/(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx
Gym support content uses reusable section, paragraph, list, and notice helpers; the former introduction card is removed.
Sportterem section rendering
src/app/(app)/[lang]/sport/sportterem-igenyles/components/SportteremContent.tsx
Sportterem sections use reusable section, paragraph, list, and warning helpers; the former introduction card is removed and the outer layout is restyled.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related issues

Possibly related PRs

  • kir-dev/ehk#152 — Also changes how PageHeader receives subtitle versus description content.

Suggested reviewers: peterlipt

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title matches the main theme of the PR: a redesigned gym/sport hall booking page.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch 133-implement-redesigned-gym-booking-tornaterem-igénylés-page

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@peterlipt

Copy link
Copy Markdown
Member

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

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)
src/app/(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx (1)

68-103: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Extract SectionCard/Paragraph/TextList into a shared module.

These three helpers are duplicated nearly verbatim in src/app/(app)/[lang]/sport/sportterem-igenyles/components/SportteremContent.tsx (lines 95-130), differing only in SectionCard's Card background (bg-transparent here vs bg-white there). This duplication has already caused drift — see the NoticeBox/WarningBox color inconsistency noted below. Extracting to a shared file (e.g. src/components/common/ContentBlocks.tsx) would prevent future divergence.

♻️ Suggested extraction
// src/components/common/ContentBlocks.tsx
import { ReactNode } from 'react';
import { Card, CardContent } from '`@/components/ui/card`';
import { parseFormattedText } from '`@/utils/parseFormattedText`';

export function SectionCard({ title, children, className = 'bg-transparent' }: { title: string; children: ReactNode; className?: string }) {
  return (
    <Card className={`rounded-2xl border-[`#e9e2d6`] py-0 shadow-none ${className}`}>
      <CardContent className="flex flex-col gap-4 p-4">
        <h2 className="font-playfair text-base font-semibold leading-[1.4] text-black">{title}</h2>
        <div className="h-px w-full bg-[`#e9e2d6`]" />
        <div className="flex flex-col gap-4 font-open-sans text-sm leading-[1.6] text-black">{children}</div>
      </CardContent>
    </Card>
  );
}

export function Paragraph({ children }: { children: ReactNode }) {
  return <p className="richtext max-w-none">{children}</p>;
}

export function TextList({ items, ordered = false }: { items: string[]; ordered?: boolean }) {
  const ListTag = ordered ? 'ol' : 'ul';
  return (
    <ListTag className={`${ordered ? 'list-decimal' : 'list-disc'} space-y-2 pl-5 marker:text-[`#862633`]`}>
      {items.map((item, index) => (
        <li key={`${item}-${index}`} className="pl-1">{parseFormattedText(item)}</li>
      ))}
    </ListTag>
  );
}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@src/app/`(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx
around lines 68 - 103, Extract SectionCard, Paragraph, and TextList into a
shared ContentBlocks module, importing the required UI and parsing dependencies,
then update GymSupportContent and SportteremContent to use those shared exports.
Preserve each page’s SectionCard background by supporting a configurable
className with bg-transparent as the default and bg-white where required, while
removing the duplicated local helper definitions.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@src/app/`(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx:
- Around line 104-110: Update the NoticeBox component’s text color to a neutral,
non-warning color appropriate for its cream background, replacing the dark
maroon text class while preserving its existing layout, border, and typography
classes.

---

Nitpick comments:
In
`@src/app/`(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx:
- Around line 68-103: Extract SectionCard, Paragraph, and TextList into a shared
ContentBlocks module, importing the required UI and parsing dependencies, then
update GymSupportContent and SportteremContent to use those shared exports.
Preserve each page’s SectionCard background by supporting a configurable
className with bg-transparent as the default and bg-white where required, while
removing the duplicated local helper definitions.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 34c90370-2de7-43a2-982c-01c8e1865e94

📥 Commits

Reviewing files that changed from the base of the PR and between 2cbebd5 and f7c65b0.

📒 Files selected for processing (5)
  • src/app/(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx
  • src/app/(app)/[lang]/sport/sportpalya-tamogatas/page.tsx
  • src/app/(app)/[lang]/sport/sportterem-igenyles/components/SportteremContent.tsx
  • src/app/(app)/[lang]/sport/sportterem-igenyles/page.tsx
  • src/components/common/PageHeader.tsx

Comment on lines +104 to +110
function NoticeBox({ children }: { children: ReactNode }) {
return (
<div className="richtext rounded-2xl border border-[#e9e2d6] bg-[#f9f4f0] px-4 py-2 font-open-sans text-sm leading-[1.6] text-[#6b0f1a]">
{children}
</div>
);
} No newline at end of file
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

NoticeBox text color looks copy-pasted from a warning style.

NoticeBox uses text-[#6b0f1a] (dark red/maroon) on a neutral cream background/border — the same alarming text color used by SportteremContent.tsx's WarningBox (which pairs it with a red-tinted bg/border). On this neutral notice box, the red text likely misleads users into reading routine info as a warning.

🎨 Proposed fix
 function NoticeBox({ children }: { children: ReactNode }) {
   return (
-    <div className="richtext rounded-2xl border border-[`#e9e2d6`] bg-[`#f9f4f0`] px-4 py-2 font-open-sans text-sm leading-[1.6] text-[`#6b0f1a`]">
+    <div className="richtext rounded-2xl border border-[`#e9e2d6`] bg-[`#f9f4f0`] px-4 py-2 font-open-sans text-sm leading-[1.6] text-black">
       {children}
     </div>
   );
 }
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
function NoticeBox({ children }: { children: ReactNode }) {
return (
<div className="richtext rounded-2xl border border-[#e9e2d6] bg-[#f9f4f0] px-4 py-2 font-open-sans text-sm leading-[1.6] text-[#6b0f1a]">
{children}
</div>
);
}
\ No newline at end of file
}
function NoticeBox({ children }: { children: ReactNode }) {
return (
<div className="richtext rounded-2xl border border-[`#e9e2d6`] bg-[`#f9f4f0`] px-4 py-2 font-open-sans text-sm leading-[1.6] text-black">
{children}
</div>
);
}
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@src/app/`(app)/[lang]/sport/sportpalya-tamogatas/components/GymSupportContent.tsx
around lines 104 - 110, Update the NoticeBox component’s text color to a
neutral, non-warning color appropriate for its cream background, replacing the
dark maroon text class while preserving its existing layout, border, and
typography classes.

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.

Implement Redesigned Gym Booking (Tornaterem igénylés) Page

2 participants