Skip to content

Conversation

@doersa
Copy link

@doersa doersa commented Feb 12, 2026

Description

Screencast

Checklist

- feat: 改进 README.md,增加详细描述、功能、用法和截图,并更新 package.json 中的类别和图标。
- feat: 引入“自动”语言选项,根据IP位置自动切换显示语言。
- feat: 为 IP Geo 命令添加多语言支持,包括语言偏好设置和 UI 文本国际化。
- feat: 改进 IP 地址列表项的显示,包括更简洁的来源标记和详细的副标题。
- refactor: 移除 `ipSource` 偏好设置,并优化 IP 地址获取逻辑以支持多源显示。
- feat: 增加偏好设置以选择 IP 源(ip-api.com 或 cip.cc)
- feat: 实现 IP 地理位置查询功能,包括搜索、历史记录和详细显示,并更新扩展元数据。
- Initial commit
@raycastbot
Copy link
Collaborator

Congratulations on your new Raycast extension! 🚀

We're currently experiencing a high volume of incoming requests. As a result, the initial review may take up to 10-15 business days.

Once the PR is approved and merged, the extension will be available on our Store.

@doersa
Copy link
Author

doersa commented Feb 12, 2026

Description

This extension allows users to query IP address geolocation data and view it on a map. It supports both automatic detection of the current public IP and manual searching for specific IP addresses.

Features

  • Auto Detection: Automatically checks and displays your current public IP address details.
  • Search: Enter any IP address to query its location, ISP, and other details.
  • Map View: Visualizes the IP location on a static map.
  • History: Keeps track of your search history for quick access.
  • Multi-language: Supports English and Simplified Chinese (auto-detected or manually set).

Author

Ryan.L

@doersa doersa marked this pull request as ready for review February 12, 2026 09:58
@greptile-apps
Copy link
Contributor

greptile-apps bot commented Feb 12, 2026

Greptile Overview

Greptile Summary

This PR adds a new IP Geolocation extension that allows users to query IP address information and display locations on a map. The extension includes automatic current IP detection, search functionality, history tracking, and map visualization.

Key Changes:

  • New extension with IP geolocation lookup using ip-api.com
  • Dual-source IP detection (myip.ipip.net and direct connection)
  • History management with LocalStorage
  • Map visualization using Yandex static maps API

Issues Found:

  • Custom localization system violates Raycast's US English-only policy - the extension implements automatic language detection and Chinese translation which creates unnecessary complexity
  • Screenshots are placed in assets/ folder instead of required metadata/ folder
  • Language preference with auto-detection based on IP location should be removed or redesigned as a manual preference

The core functionality is well-implemented with proper error handling and state management, but the localization approach needs to be revised to align with Raycast guidelines.

Confidence Score: 2/5

  • This PR has architectural issues that violate Raycast guidelines regarding localization
  • The extension implements a custom localization system with automatic language detection, which directly violates Raycast's policy of supporting only US English. Additionally, screenshots are incorrectly placed in the assets folder instead of metadata. The core IP geolocation functionality is well-implemented, but these guideline violations need to be addressed before merging.
  • Pay close attention to src/utils/i18n.ts and package.json for the localization system that needs to be removed or redesigned

Important Files Changed

Filename Overview
extensions/ip-geo/package.json Valid configuration with proper dependencies and scripts, but includes problematic language preference with auto-detection that violates Raycast guidelines
extensions/ip-geo/src/ip.tsx Well-structured IP geolocation lookup with history management, uses custom localization which should be reconsidered per Raycast guidelines
extensions/ip-geo/src/utils/i18n.ts Implements custom localization system that violates Raycast's US English-only policy
extensions/ip-geo/README.md Clear documentation, but screenshots are incorrectly placed in assets/ instead of metadata/

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

13 files reviewed, 3 comments

Edit Code Review Agent Settings | Greptile

Comment on lines +1 to +59
import { getPreferenceValues } from "@raycast/api";

export const preferences = getPreferenceValues<Preferences>();

export const availableLanguages = ["en", "zh"] as const;
export type Language = (typeof availableLanguages)[number];

export const dictionary = {
en: {
searchPlaceholder: "Enter IP address (leave empty for current IP)",
searchResult: "Search Result",
yourIp: "Your IP Address",
unknownIp: "Unknown IP",
fetching: "Fetching IP information...",
history: "History",
error: "Error",
errorFetch: "Failed to fetch IP information.",
copyIp: "Copy IP",
copyJson: "Copy Full JSON",
removeFromHistory: "Remove from History",
clearHistory: "Clear All History",
failedSaveHistory: "Failed to save history",
viaIpip: "Via myip.ipip.net",
viaLocal: "Via Local Connection",
ipAddress: "IP Address",
city: "City",
region: "Region",
country: "Country",
isp: "ISP",
timezone: "Timezone",
latitude: "Latitude",
longitude: "Longitude",
},
zh: {
searchPlaceholder: "输入 IP 地址 (留空查询当前 IP)",
searchResult: "搜索结果",
yourIp: "您的 IP 地址",
unknownIp: "未知 IP",
fetching: "正在获取 IP 信息...",
history: "历史记录",
error: "错误",
errorFetch: "获取 IP 信息失败。",
copyIp: "复制 IP",
copyJson: "复制完整 JSON",
removeFromHistory: "从历史记录移除",
clearHistory: "清空历史记录",
failedSaveHistory: "保存历史记录失败",
viaIpip: "通过 myip.ipip.net",
viaLocal: "通过本地连接",
ipAddress: "IP 地址",
city: "城市",
region: "地区",
country: "国家",
isp: "运营商",
timezone: "时区",
latitude: "纬度",
longitude: "经度",
},
};
Copy link
Contributor

Choose a reason for hiding this comment

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

Custom localization logic should not be implemented in Raycast extensions. Raycast only supports US English, and implementing custom language switching creates unnecessary complexity. If you need locale-dependent features (like unit systems), use the preferences API instead.

Consider removing this custom i18n system entirely and using only English strings, or use preferences for language selection if this is truly needed as a user preference rather than automatic locale detection.

Context Used: Rule from dashboard - What: Do not implement custom localization logic in Raycast extensions; use the preferences API for ... (source)

Comment on lines 26 to 47
{
"name": "language",
"type": "dropdown",
"required": false,
"title": "Language",
"description": "Select the display language.",
"default": "auto",
"data": [
{
"title": "Auto",
"value": "auto"
},
{
"title": "English",
"value": "en"
},
{
"title": "简体中文",
"value": "zh"
}
]
}
Copy link
Contributor

Choose a reason for hiding this comment

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

The language preference with auto-detection based on IP location violates Raycast's guidelines. Raycast only supports US English. If language selection is necessary as a user preference, it should be a manual choice, not auto-detected based on locale.

Context Used: Rule from dashboard - What: Do not implement custom localization logic in Raycast extensions; use the preferences API for ... (source)

Comment on lines 5 to 6
![Screenshot 1](assets/screenshot-1.png)
![Screenshot 2](assets/screenshot-2.png)
Copy link
Contributor

Choose a reason for hiding this comment

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

Screenshots should be in a metadata/ folder, not in assets/. The assets/ folder should only contain files used by the extension itself (like the icon).

Move screenshot-1.png and screenshot-2.png to metadata/ and update the README references to point to metadata/screenshot-1.png and metadata/screenshot-2.png.

Context Used: Rule from dashboard - What: Extensions with view-type commands must include a metadata/ folder containing Raycast-styled... (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@doersa
Copy link
Author

doersa commented Feb 12, 2026

Thanks for the review!

I've addressed the feedback:

  • Localization: Removed the auto-detection based on IP. The extension now defaults to English and respects the manual language preference.
  • Metadata: Moved the screenshots to the metadata/ directory and updated the README.

Ready for another look!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants