8000 Fix: 번역 안된 부분 수정 및 요약 이슈 해결 by guesung · Pull Request #120 · guesung/Web-Memo · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix: 번역 안된 부분 수정 및 요약 이슈 해결 #120

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

Merged
merged 4 commits into from
Dec 16, 2024

Conversation

guesung
Copy link
Owner
@guesung guesung commented Dec 16, 2024

Summary by CodeRabbit

  • 새로운 기능

    • 언어 설정 로직 간소화 및 사용자 메시지 업데이트.
    • 새로운 메시지 추가: 프롬프트 언어 설정, 언어 선택, YouTube 프롬프트 설정 등.
  • 버그 수정

    • 오류 메시지 및 확장 프로그램 이름, 설명 수정.
  • 문서화

    • 국제화 지원을 위한 사용자 인터페이스 텍스트 동적화.

Copy link
coderabbitai bot commented Dec 16, 2024

워크스루

이 풀 리퀘스트는 Chrome 확장 프로그램의 국제화(i18n) 및 언어 설정 로직을 개선합니다. 주요 변경 사항은 배경 스크립트의 언어 초기화 간소화, 영어 및 한국어 로케일 메시지 업데이트, 콘텐츠 추출 방식 변경, 그리고 옵션 페이지 컴포넌트의 국제화 지원 강화를 포함합니다.

변경 사항

파일 변경 요약
chrome-extension/lib/background/index.ts LANGUAGE_MAP 제거, 언어 설정 로직 간소화
chrome-extension/public/_locales/en/messages.json 확장 프로그램 이름, 설명 업데이트, 새로운 메시지 추가
chrome-extension/public/_locales/ko/messages.json 확장 프로그램 이름, 설명 업데이트, 새로운 메시지 추가
packages/shared/src/utils/extension/bridge/pageContent.ts 웹 페이지 콘텐츠 추출 방식 변경 (document.body.innerText 사용)
pages/options/src/components/Header.tsx 국제화를 위해 확장 프로그램 이름 동적 설정
pages/options/src/components/Option.tsx 국제화 지원 강화, 로컬라이즈된 문자열 사용

관련 가능성 있는 PR

🐰 코드의 언어,
메시지들이 춤을 추네
국제화의 마법으로
웹 메모가 더 스마트해져
토끼의 코딩 여행! 🌈✨

Tip

CodeRabbit's docstrings feature is now available as part of our Early Access Program! Simply use the command @coderabbitai generate docstrings to have CodeRabbit automatically generate docstrings for your pull request.


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.

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 (5)
pages/options/src/components/Option.tsx (2)

46-46: 디버그 로그 제거 필요

프로덕션 코드에서 console.log를 사용하는 것은 바람직하지 않습니다. 디버깅이 완료되었다면 제거해 주세요.

-      console.log(language, I18n.getUILanguage());

61-62: 언어 코드와 표시 이름 불일치

SelectItem의 value가 "en-US"인데 표시되는 텍스트는 단순히 "English"입니다. 일관성을 위해 둘 다 "English" 또는 둘 다 "English (en-US)"로 통일하는 것이 좋습니다.

-            <SelectItem value="en-US">English</SelectItem>
+            <SelectItem value="en-US">English (en-US)</SelectItem>
chrome-extension/public/_locales/en/messages.json (2)

51-51: 오류 메시지 구체성 및 마침표 누락

오류 메시지가 너무 일반적이며, 마침표가 누락되었습니다. 사용자가 취해야 할 구체적인 조치를 포함하고 일관된 구두점을 사용하는 것이 좋습니다.

-    "message": "Sorry. An error occurred. Please try again"
+    "message": "Sorry. An error occurred. Please try refreshing the page and try again."

86-102: 새로 추가된 번역 키의 일관성

새로 추가된 번역 키들의 메시지가 일관된 스타일을 유지하고 있어 좋습니다. 다만, 향후 유지보수를 위해 각 메시지에 대한 설명 주석을 추가하는 것을 고려해보세요.

각 메시지 키 위에 해당 메시지가 사용되는 컨텍스트를 설명하는 주석을 추가하면 좋을 것 같습니다.

chrome-extension/lib/background/index.ts (1)

Line range hint 16-28: 코드 주석 언어 통일성

코드베이스의 일관성을 위해 주석도 영어로 작성하는 것이 좋습니다.

-// 확장 프로그램이 설치되었을 때 옵션을 초기화한다.
+// Initialize extension options when installed
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c502637 and 43de3dc.

📒 Files selected for processing (6)
  • chrome-extension/lib/background/index.ts (2 hunks)
  • chrome-extension/public/_locales/en/messages.json (3 hunks)
  • chrome-extension/public/_locales/ko/messages.json (2 hunks)
  • packages/shared/src/utils/extension/bridge/pageContent.ts (1 hunks)
  • pages/options/src/components/Header.tsx (2 hunks)
  • pages/options/src/components/Option.tsx (4 hunks)
🔇 Additional comments (3)
pages/options/src/components/Header.tsx (1)

10-10: 국제화 구현이 잘 되었습니다!

하드코딩된 텍스트를 I18n.get()으로 대체한 것이 적절합니다.

chrome-extension/public/_locales/ko/messages.json (2)

3-6: 확장 프로그램 이름과 설명이 자연스럽게 수정되었습니다!

새로운 이름과 설명이 확장 프로그램의 목적을 더 명확하게 전달합니다.


86-102: 새로운 번역문이 잘 추가되었습니다!

프롬프트 설정 관련 메시지들이 자연스럽게 번역되었습니다.

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
0