Skip to content

Feature/policy api#63

Merged
haeni82 merged 9 commits into
developfrom
feature/policy-api
Mar 23, 2026
Merged

Feature/policy api#63
haeni82 merged 9 commits into
developfrom
feature/policy-api

Conversation

@haeni82
Copy link
Copy Markdown
Contributor

@haeni82 haeni82 commented Mar 23, 2026

이슈

  • closed #이슈번호

✔️ 체크리스트

  • : Merge할 브랜치를 확인해 주세요.

🔍 작업 내용

  • 반응형 추가
  • 태블릿으로 접속시 구조 변경

⚠️ 주의 사항 / 기타

Summary by CodeRabbit

  • 새로운 기능

    • 화면 크기에 따른 동적 파이 차트 크기 조정 추가
    • 반응형 그리드/레이아웃 적용으로 다양한 기기에서 개선된 배치 제공
  • 스타일 개선

    • 전체 글자 크기·간격의 반응형 조정 및 버튼/카드 스타일 업데이트
    • 폰트 크기·간격이 작은 화면에 맞춰 축소/태블릿에 맞춰 확대 적용
  • 리팩토링

    • 컴포넌트 레이아웃 구조 현대화로 반응형 동작 최적화
  • 변경

    • 관리자 패밀리 상세 모달 컴포넌트 제거 (UI 흐름에 영향)

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Mar 23, 2026

Warning

Rate limit exceeded

@haeni82 has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 8 minutes and 29 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: a292c95e-90f0-442e-af77-8789ba179932

📥 Commits

Reviewing files that changed from the base of the PR and between 58f7746 and aa483b5.

📒 Files selected for processing (3)
  • src/index.css
  • src/page/Main/components/FamilyMemberList.tsx
  • src/page/Support/Support.tsx
📝 Walkthrough

Walkthrough

다수의 컴포넌트에서 인라인 스타일을 Tailwind 클래스로 전환하고 반응형 레이아웃을 도입했습니다. GradientButton API가 변경되었고, 새로운 훅 usePieChartSize가 추가되어 MainPage의 PieChart에 크기/스트로크 값을 전달합니다. 일부 컴포넌트(예: FamilyDetailModal)가 삭제되었습니다.

Changes

Cohort / File(s) Summary
Tailwind 설정 및 글로벌 CSS
tailwind.config.js, src/index.css
커스텀 스크린(xs/tablet/tablet-lg/desktop)과 responsive fontSize 유틸리티 추가. index.css에 브레이크포인트용 미디어쿼리(≤400px, 768–1399px) 및 텍스트/간격 오버라이드 추가(중복된 max-width:400px 블록 포함).
공통 버튼(인터페이스 변경)
src/components/common/GradientButton.tsx
Props에서 width/height/fontSize 제거, buttonClassNamefullWidth 추가. 패딩/폰트 크기 계산 제거, 고정 패딩 사용, fullWidth에 따른 wrapper/button 클래스 변경, borderRadius 인라인 처리 조건화.
헤더·PolicyScroll 스타일 리팩토링
src/components/Header.tsx, src/components/common/PolicyScroll.tsx
인라인 fontSize 제거 및 Tailwind 텍스트 유틸리티(text-lg, text-xs, text-base 등)로 전환. 일부 제목/타이틀 마크업 소폭 재구성.
새 훅 및 PieChart 연결
src/hooks/usePieChartSize.ts, src/page/Main/MainPage.tsx
viewport 기반으로 pie chart sizestrokeWidth를 계산하는 usePieChartSize 추가. MainPage에서 훅 사용해 PieChart에 size/strokeWidth 전달.
레이아웃·그리드 반응형 조정
src/layout/Layout.tsx, src/page/Detail/DetailPage.tsx, src/page/Main/components/FamilyMemberList.tsx
루트/컨테이너 클래스에 breakpoint별 배경/너비/패딩 조정. DetailPage와 FamilyMemberList에서 컴포넌트들을 반응형 grid로 래핑해 컬럼 전환 적용.
페이지별 GradientButton 사용처 변경
src/page/Login/LoginPage.tsx, src/page/Admin/AdminLoginPage.tsx, src/page/SharedData/..., src/page/Main/MainPage.tsx
여러 페이지에서 GradientButton 호출을 고정 크기 props 대신 fullWidthbuttonClassName으로 대체(기존 클릭 핸들러 및 네비게이션 유지).
Policy 관련 UI/구성 변경
src/page/Policy/Policy.tsx, src/page/Policy/components/UserInfoCard.tsx, src/page/Policy/components/DataRemainingCard.tsx, src/page/Policy/components/Permisssion.tsx
Policy 페이지를 tablet/grid 기반 레이아웃으로 재배치. UserInfoCard의 버튼 레이아웃을 반응형으로 재구성, DataRemainingCard를 수직 레이아웃으로 변경, Permisssion에서 lineId 대신 userName 표시(옵셔널).
PolicyDetail 탭/필터 레이아웃
src/page/PolicyDetail/components/AppPolicyFilters.tsx, .../BlockTab.tsx, .../LimitTab.tsx
인라인 폰트스타일을 유틸리티 클래스로 교체하고, 탭 컨테이너들을 tablet-grid/desktop-flex 하이브리드 레이아웃으로 변경(정렬/간격 조정).
관리자 관련 변경: 컴포넌트 삭제
src/page/Admin/components/FamilyDetailModal.tsx
FamilyDetailModal 컴포넌트 전체 삭제(기능·쿼리 및 렌더 로직 전부 제거).
기타 UI 미세조정
src/page/Support/Support.tsx, src/page/SharedData/..., src/page/PolicyDetail/...
탭 컨테이너 너비, 버튼/카드 내부 레이아웃 등 소규모 클래스 조정 및 몇몇 위치에 우발적 공백 노드({" "}) 추가.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

🚥 Pre-merge checks | ❌ 3

❌ Failed checks (3 warnings)

Check name Status Explanation Resolution
Title check ⚠️ Warning PR 제목이 실제 변경사항과 맞지 않습니다. 제목은 '정책 API'를 의미하지만, 실제로는 UI의 반응형 레이아웃 및 스타일링 개선이 주요 변경사항입니다. 제목을 실제 변경사항을 반영하도록 수정하세요. 예: 'Refactor: Add responsive layout and Tailwind styling updates'
Description check ⚠️ Warning PR 설명이 매우 불완전합니다. 필수 섹션은 존재하지만 '작업 내용'이 구체적이지 않고 변경사항의 상세 설명이 부족합니다. 이슈 번호도 미입력 상태입니다. 이슈 번호를 채우고, 작업 내용에 반응형 구현 내역(새 훅 추가, Tailwind 설정 변경, 컴포넌트별 레이아웃 개선 등)을 구체적으로 작성하세요.
Docstring Coverage ⚠️ Warning Docstring coverage is 29.41% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/policy-api

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 and usage tips.

Copy link
Copy Markdown

@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: 6

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/components/common/GradientButton.tsx (1)

3-16: ⚠️ Potential issue | 🟠 Major

GradientButton API 변경이 호출부 마이그레이션 없이 머지되면 깨집니다.

type Props에서 width/height 속성을 제거했으나, 다음 파일들이 여전히 제거된 props를 전달하고 있습니다:

  • src/page/Admin/AdminLoginPage.tsx (lines 170-171): width={120}, height={16} 사용 중
  • src/page/Admin/components/FamilyDetailModal.tsx (lines 108-109): width={20}, height={8} 사용 중

타입 에러(또는 타입 우회 시 사이즈 회귀) 위험이 큽니다. 이 PR에서 호출부를 함께 정리하거나, 임시 하위호환(deprecated props 매핑)을 두는 편이 안전합니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/components/common/GradientButton.tsx` around lines 3 - 16, The
GradientButton API removed width/height props but callers (AdminLoginPage.tsx
and FamilyDetailModal.tsx) still pass them; restore backward-compatibility by
reintroducing optional width?: number | string and height?: number | string to
the Props in GradientButton and map them into the rendered element's style (or
translate numeric values into appropriate CSS units) while marking them
deprecated in a comment; update the component's prop handling in GradientButton
to prefer explicit className/buttonClassName behavior but apply width/height to
the element style when provided so existing callers keep working without
migrating immediately.
🧹 Nitpick comments (5)
src/hooks/usePieChartSize.ts (1)

11-11: 주석과 코드 불일치

주석에는 "vw의 3%"라고 되어 있지만 실제 코드는 vw * 0.04 (4%)입니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/hooks/usePieChartSize.ts` at line 11, 주석과 실제 계산이 불일치합니다:
usePieChartSize.ts에서 strokeWidth를 계산하는 식이 vw * 0.04(4%)인데 주석은 "vw의 3%"라고 돼 있습니다;
일관성을 위해 둘 중 하나를 고치세요 — 주석이 옳다면 strokeWidth 계산을 vw * 0.03으로 변경하고, 계산이 옳다면 주석을
"vw의 4%" 또는 "vw * 0.04"로 수정하세요 (참조: 변수 vw 및 속성 strokeWidth).
src/index.css (1)

153-194: 전역 CSS 오버라이드 사용에 대한 유지보수 고려사항

!important를 사용한 전역 Tailwind 클래스 오버라이드는 특수한 경우에 유용하지만, 향후 유지보수 시 예상치 못한 스타일 충돌을 일으킬 수 있습니다. Tailwind의 반응형 접두사(xs:text-sm 등)나 tailwind.config.js의 커스텀 유틸리티 확장을 활용하는 것이 더 일관된 접근 방식일 수 있습니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/index.css` around lines 153 - 194, The media query block using `@media`
(max-width: 400px) that overrides Tailwind classes (.text-xs, .text-sm,
.text-base, .text-lg, .text-xl, .text-2xl, .text-3xl, .gap-3, .gap-4, .mb-4,
.p-4, .px-6) with !important should be removed and replaced by Tailwind-native
solutions: either add a small-screen breakpoint (e.g., "xs": "400px") in
tailwind.config.js and use responsive prefixes like xs:text-sm, xs:gap-3 in your
templates, or define custom utilities/components in tailwind.config.js
(theme.extend or plugins) that encapsulate the desired sizes so you no longer
need the global !important overrides in the CSS.
src/components/common/GradientButton.tsx (1)

36-37: borderRadius는 truthy 체크 대신 명시적 undefined 체크를 권장합니다.

Line 36, Line 46의 borderRadius ? ...0을 유효값으로 처리하지 못합니다.

개선 diff
-        borderRadius: borderRadius ? `${borderRadius}px` : undefined,
+        borderRadius: borderRadius !== undefined ? `${borderRadius}px` : undefined,
...
-          borderRadius: borderRadius ? `${borderRadius}px` : undefined,
+          borderRadius: borderRadius !== undefined ? `${borderRadius}px` : undefined,

Also applies to: 46-47

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/components/common/GradientButton.tsx` around lines 36 - 37, The component
GradientButton uses a truthy check for borderRadius which treats 0 as falsy;
update the checks in GradientButton (where you set style.borderRadius) to use an
explicit undefined check (e.g., borderRadius !== undefined) so a value of 0 is
preserved, and apply the same change to the other occurrence that sets
borderRadius (the second style block around lines 46-47) to ensure consistent
behavior.
src/page/Policy/components/UserInfoCard.tsx (1)

162-164: 불필요한 JSX 공백 노드를 제거해주세요.

Line 163{" "}는 가독성만 떨어뜨리고 실질적인 UI 이점이 없습니다.

정리 제안 diff
-        <div className="flex flex-col tablet-lg:flex-row desktop:flex-col gap-2">
-          {" "}
+        <div className="flex flex-col tablet-lg:flex-row desktop:flex-col gap-2">
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/page/Policy/components/UserInfoCard.tsx` around lines 162 - 164, In
UserInfoCard.tsx remove the unnecessary JSX whitespace node {" "} that appears
before the GradientButton (the fragment around the GradientButton with
navigate("/shared-data")), i.e. delete the {" "} token so the JSX reads without
the redundant space and retains the existing <div className="flex..."> and
GradientButton usage unchanged.
src/page/Main/MainPage.tsx (1)

189-193: 불필요한 공백 텍스트 노드를 제거하는 편이 좋습니다.

Line 193{" "}는 렌더 결과에 의미가 없고 JSX 노이즈만 증가시킵니다.

정리 제안 diff
-        <PieChart
-          sharedPoolData={sharedPoolData}
-          size={pieSize}
-          strokeWidth={pieStrokeWidth}
-        />{" "}
+        <PieChart
+          sharedPoolData={sharedPoolData}
+          size={pieSize}
+          strokeWidth={pieStrokeWidth}
+        />
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/page/Main/MainPage.tsx` around lines 189 - 193, Remove the unnecessary
JSX whitespace text node after the PieChart component in MainPage.tsx — locate
the <PieChart ... /> usage (props: sharedPoolData, size=pieSize,
strokeWidth=pieStrokeWidth) and delete the trailing {" "} so the component is
rendered without the stray text node; then reformat the surrounding JSX to
ensure no extra whitespace remains.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@src/hooks/usePieChartSize.ts`:
- Around line 5-14: The calc function in usePieChartSize currently accesses
window.innerWidth directly causing ReferenceError in SSR/hydration; update calc
(and any callers) to guard access by checking typeof window !== "undefined"
before reading window.innerWidth or accept an optional width parameter (e.g.,
calc(width?: number)) and use a sensible default fallback (like 1024) when
window is not available, then compute size/strokeWidth the same way; ensure
usePieChartSize calls the guarded/parameterized calc during server render to
avoid direct window access.

In `@src/index.css`:
- Around line 196-237: There is a duplicated `@media` (max-width: 400px) block
that repeats the same class overrides (.text-xs, .text-sm, .text-base, .text-lg,
.text-xl, .text-2xl, .text-3xl, .gap-3, .gap-4, .mb-4, .p-4, .px-6); remove one
of the duplicate blocks so only a single `@media` (max-width: 400px) block
remains, keeping the intended font-size and spacing overrides, and scan for any
other identical media-query duplicates to collapse into that single block (use
the existing selectors like .text-base and .px-6 to locate the duplicates).

In `@src/page/Main/components/FamilyMemberList.tsx`:
- Around line 42-44: Remove the unnecessary whitespace text node in the JSX
inside FamilyMemberList.tsx: delete the {" "} token that sits between the
wrapping div and the members.map rendering so the container div (className="grid
...") directly contains {members.map((member) => (...))}; update the JSX around
the members.map expression to eliminate that stray text node and ensure
formatting/indentation remains correct.

In `@src/page/Policy/components/DataRemainingCard.tsx`:
- Around line 34-38: The img elements in the DataRemainingCard component are
missing alt attributes; update the JSX that checks icon === "share" (using
shareIcon and personIcon) to include explicit alt attributes — if these images
are purely decorative, add alt=""; otherwise provide descriptive text like
"share icon" and "person icon" to improve accessibility.

In `@src/page/Support/Support.tsx`:
- Line 136: Remove the stray JSX text node `{" "}` in the Support component
render (the extraneous whitespace inside the Support.tsx JSX) — locate the
`Support` component/JSX block that contains `{" "}` and delete that token so no
unnecessary text node is emitted; ensure surrounding JSX still renders correctly
and spacing is handled via CSS or proper JSX elements instead of `{" "}`.

In `@tailwind.config.js`:
- Around line 63-69: The custom fontSize utilities "responsive-xs",
"responsive-sm", "responsive-base", "responsive-lg", and "responsive-xl" in
tailwind.config.js are unused; either remove them from the fontSize section or
update components to use these utilities. Locate the fontSize declaration (the
keys responsive-*) in tailwind.config.js and either delete those entries to
avoid dead CSS or replace existing class usage in your components (e.g., update
className strings or template literals to use "text-responsive-sm" etc.) so the
utilities are actually applied across the codebase.

---

Outside diff comments:
In `@src/components/common/GradientButton.tsx`:
- Around line 3-16: The GradientButton API removed width/height props but
callers (AdminLoginPage.tsx and FamilyDetailModal.tsx) still pass them; restore
backward-compatibility by reintroducing optional width?: number | string and
height?: number | string to the Props in GradientButton and map them into the
rendered element's style (or translate numeric values into appropriate CSS
units) while marking them deprecated in a comment; update the component's prop
handling in GradientButton to prefer explicit className/buttonClassName behavior
but apply width/height to the element style when provided so existing callers
keep working without migrating immediately.

---

Nitpick comments:
In `@src/components/common/GradientButton.tsx`:
- Around line 36-37: The component GradientButton uses a truthy check for
borderRadius which treats 0 as falsy; update the checks in GradientButton (where
you set style.borderRadius) to use an explicit undefined check (e.g.,
borderRadius !== undefined) so a value of 0 is preserved, and apply the same
change to the other occurrence that sets borderRadius (the second style block
around lines 46-47) to ensure consistent behavior.

In `@src/hooks/usePieChartSize.ts`:
- Line 11: 주석과 실제 계산이 불일치합니다: usePieChartSize.ts에서 strokeWidth를 계산하는 식이 vw *
0.04(4%)인데 주석은 "vw의 3%"라고 돼 있습니다; 일관성을 위해 둘 중 하나를 고치세요 — 주석이 옳다면 strokeWidth 계산을
vw * 0.03으로 변경하고, 계산이 옳다면 주석을 "vw의 4%" 또는 "vw * 0.04"로 수정하세요 (참조: 변수 vw 및 속성
strokeWidth).

In `@src/index.css`:
- Around line 153-194: The media query block using `@media` (max-width: 400px)
that overrides Tailwind classes (.text-xs, .text-sm, .text-base, .text-lg,
.text-xl, .text-2xl, .text-3xl, .gap-3, .gap-4, .mb-4, .p-4, .px-6) with
!important should be removed and replaced by Tailwind-native solutions: either
add a small-screen breakpoint (e.g., "xs": "400px") in tailwind.config.js and
use responsive prefixes like xs:text-sm, xs:gap-3 in your templates, or define
custom utilities/components in tailwind.config.js (theme.extend or plugins) that
encapsulate the desired sizes so you no longer need the global !important
overrides in the CSS.

In `@src/page/Main/MainPage.tsx`:
- Around line 189-193: Remove the unnecessary JSX whitespace text node after the
PieChart component in MainPage.tsx — locate the <PieChart ... /> usage (props:
sharedPoolData, size=pieSize, strokeWidth=pieStrokeWidth) and delete the
trailing {" "} so the component is rendered without the stray text node; then
reformat the surrounding JSX to ensure no extra whitespace remains.

In `@src/page/Policy/components/UserInfoCard.tsx`:
- Around line 162-164: In UserInfoCard.tsx remove the unnecessary JSX whitespace
node {" "} that appears before the GradientButton (the fragment around the
GradientButton with navigate("/shared-data")), i.e. delete the {" "} token so
the JSX reads without the redundant space and retains the existing <div
className="flex..."> and GradientButton usage unchanged.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: e9332ce3-68c6-41e5-a468-24b39d8ed936

📥 Commits

Reviewing files that changed from the base of the PR and between 42a71a2 and d4f1f37.

📒 Files selected for processing (21)
  • src/components/Header.tsx
  • src/components/common/GradientButton.tsx
  • src/components/common/PolicyScroll.tsx
  • src/hooks/usePieChartSize.ts
  • src/index.css
  • src/layout/Layout.tsx
  • src/page/Detail/DetailPage.tsx
  • src/page/Login/LoginPage.tsx
  • src/page/Main/MainPage.tsx
  • src/page/Main/components/FamilyMemberList.tsx
  • src/page/Policy/Policy.tsx
  • src/page/Policy/components/DataRemainingCard.tsx
  • src/page/Policy/components/Permisssion.tsx
  • src/page/Policy/components/UserInfoCard.tsx
  • src/page/PolicyDetail/components/AppPolicyFilters.tsx
  • src/page/PolicyDetail/components/BlockTab.tsx
  • src/page/PolicyDetail/components/LimitTab.tsx
  • src/page/SharedData/components/DataTransferCard.tsx
  • src/page/SharedData/components/SharedPoolCard.tsx
  • src/page/Support/Support.tsx
  • tailwind.config.js

Comment on lines +5 to +14
const calc = () => {
const vw = window.innerWidth;
if (vw >= 1400) return { size: 320, strokeWidth: 25 };
if (vw >= 768)
return {
size: Math.round(Math.min(vw * 0.5, 460)),
strokeWidth: Math.round(Math.min(vw * 0.04, 40)), // vw의 3%, 최대 40
};
return { size: 320, strokeWidth: 25 };
};
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

SSR/하이드레이션 환경에서 window 접근 시 오류 발생 가능

calc 함수가 window.innerWidth에 직접 접근하므로, SSR 환경이나 초기 하이드레이션 단계에서 ReferenceError가 발생할 수 있습니다.

🛠️ 제안된 수정
 const calc = () => {
+  if (typeof window === "undefined") return { size: 320, strokeWidth: 25 };
   const vw = window.innerWidth;
   if (vw >= 1400) return { size: 320, strokeWidth: 25 };
   if (vw >= 768)
     return {
       size: Math.round(Math.min(vw * 0.5, 460)),
-      strokeWidth: Math.round(Math.min(vw * 0.04, 40)), // vw의 3%, 최대 40
+      strokeWidth: Math.round(Math.min(vw * 0.04, 40)), // vw의 4%, 최대 40
     };
   return { size: 320, strokeWidth: 25 };
 };
📝 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
const calc = () => {
const vw = window.innerWidth;
if (vw >= 1400) return { size: 320, strokeWidth: 25 };
if (vw >= 768)
return {
size: Math.round(Math.min(vw * 0.5, 460)),
strokeWidth: Math.round(Math.min(vw * 0.04, 40)), // vw의 3%, 최대 40
};
return { size: 320, strokeWidth: 25 };
};
const calc = () => {
if (typeof window === "undefined") return { size: 320, strokeWidth: 25 };
const vw = window.innerWidth;
if (vw >= 1400) return { size: 320, strokeWidth: 25 };
if (vw >= 768)
return {
size: Math.round(Math.min(vw * 0.5, 460)),
strokeWidth: Math.round(Math.min(vw * 0.04, 40)), // vw의 4%, 최대 40
};
return { size: 320, strokeWidth: 25 };
};
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/hooks/usePieChartSize.ts` around lines 5 - 14, The calc function in
usePieChartSize currently accesses window.innerWidth directly causing
ReferenceError in SSR/hydration; update calc (and any callers) to guard access
by checking typeof window !== "undefined" before reading window.innerWidth or
accept an optional width parameter (e.g., calc(width?: number)) and use a
sensible default fallback (like 1024) when window is not available, then compute
size/strokeWidth the same way; ensure usePieChartSize calls the
guarded/parameterized calc during server render to avoid direct window access.

Comment thread src/index.css
Comment thread src/page/Main/components/FamilyMemberList.tsx
Comment on lines +34 to +38
{icon === "share" ? (
<img src={shareIcon} />
) : (
<img src={personIcon} />
)}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

접근성: alt 속성 누락

<img> 태그에 alt 속성이 없습니다. 장식용 이미지라면 빈 alt=""를 명시적으로 추가하는 것이 접근성 모범 사례입니다.

♿ 제안된 수정
           {icon === "share" ? (
-            <img src={shareIcon} />
+            <img src={shareIcon} alt="" />
           ) : (
-            <img src={personIcon} />
+            <img src={personIcon} alt="" />
           )}
📝 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
{icon === "share" ? (
<img src={shareIcon} />
) : (
<img src={personIcon} />
)}
{icon === "share" ? (
<img src={shareIcon} alt="" />
) : (
<img src={personIcon} alt="" />
)}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@src/page/Policy/components/DataRemainingCard.tsx` around lines 34 - 38, The
img elements in the DataRemainingCard component are missing alt attributes;
update the JSX that checks icon === "share" (using shareIcon and personIcon) to
include explicit alt attributes — if these images are purely decorative, add
alt=""; otherwise provide descriptive text like "share icon" and "person icon"
to improve accessibility.

Comment thread src/page/Support/Support.tsx Outdated
Comment thread tailwind.config.js
Comment on lines +63 to +69
fontSize: {
"responsive-xs": ["0.65rem", { lineHeight: "1rem" }],
"responsive-sm": ["0.75rem", { lineHeight: "1.25rem" }],
"responsive-base": ["0.8rem", { lineHeight: "1.5rem" }],
"responsive-lg": ["0.9rem", { lineHeight: "1.75rem" }],
"responsive-xl": ["1rem", { lineHeight: "1.75rem" }],
},
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Description: Check if responsive-* font size utilities are actually used in the codebase

# Search for usage of responsive-xs, responsive-sm, etc. in source files
rg -n "responsive-(xs|sm|base|lg|xl)" --type-add 'web:*.{tsx,jsx,ts,js,css,html}' --type web

Repository: pooli-dev/pooli-fe

Length of output: 489


미사용 responsive-* 폰트 사이즈 유틸리티 정리 필요

responsive-xs부터 responsive-xl까지의 폰트 사이즈 유틸리티가 정의되어 있지만, 현재 코드베이스 어디에서도 사용되지 않고 있습니다. 이 유틸리티들을 제거하거나 실제로 활용되도록 변경해야 합니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@tailwind.config.js` around lines 63 - 69, The custom fontSize utilities
"responsive-xs", "responsive-sm", "responsive-base", "responsive-lg", and
"responsive-xl" in tailwind.config.js are unused; either remove them from the
fontSize section or update components to use these utilities. Locate the
fontSize declaration (the keys responsive-*) in tailwind.config.js and either
delete those entries to avoid dead CSS or replace existing class usage in your
components (e.g., update className strings or template literals to use
"text-responsive-sm" etc.) so the utilities are actually applied across the
codebase.

@haeni82 haeni82 merged commit 8e0f1c6 into develop Mar 23, 2026
1 check passed
@coderabbitai coderabbitai Bot mentioned this pull request Mar 23, 2026
1 task
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.

1 participant