Skip to content

Commit

Permalink
improve #688 (#687, #677, #678, #681, #682)
Browse files Browse the repository at this point in the history
  • Loading branch information
josStorer committed May 8, 2024
1 parent b494193 commit 6fcb5c9
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 16 deletions.
4 changes: 2 additions & 2 deletions src/_locales/de/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,11 @@
"Please login at https://chatgpt.com first": "Bitte zuerst bei https://chatgpt.com anmelden",
"Please login at https://claude.ai first": "Bitte zuerst bei https://claude.ai anmelden",
"Please login at https://bing.com first": "Bitte zuerst bei https://bing.com anmelden",
"Then open https://chatgpt.com/api/auth/session": "Dann öffne https://chatgpt.com/api/auth/sitzung",
"Then open https://chatgpt.com/api/auth/session": "Dann öffne https://chatgpt.com/api/auth/session",
"And refresh this page or type you question again": "Klicken Sie anschließend auf die Schaltfläche Wiederholen in der oberen rechten Ecke",
"Consider creating an api key at https://platform.openai.com/account/api-keys": "Erwägen Sie ein API-Schlüssel unter https://platform.openai.com/account/api-keys zu erstellen",
"OpenAI Security Check Required": "OpenAI-Sicherheitscheck erforderlich",
"Please open https://chatgpt.com/api/auth/session": "Bitte öffne https://chatgpt.com/api/auth/sitzung",
"Please open https://chatgpt.com/api/auth/session": "Bitte öffne https://chatgpt.com/api/auth/session",
"Please open https://chatgpt.com": "Bitte öffne https://chatgpt.com",
"New Chat": "Neuer Chat",
"Summarize Page": "Seite zusammenfassen",
Expand Down
10 changes: 5 additions & 5 deletions src/_locales/ja/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@
"Please login at https://chatgpt.com first": "最初に https://chatgpt.com にログインしてください",
"Please login at https://claude.ai first": "最初に https://claude.ai にログインしてください",
"Please login at https://bing.com first": "最初に https://bing.com にログインしてください",
"Then open https://chatgpt.com/api/auth/session": "次にhttps://chatgpt.com/api/auth/sessionにアクセス",
"Then open https://chatgpt.com/api/auth/session": "次に https://chatgpt.com/api/auth/session にアクセス",
"And refresh this page or type you question again": "次に、右上の「再試行」ボタンをクリックします",
"Consider creating an api key at https://platform.openai.com/account/api-keys": "https://platform.openai.com/account/api-keysでAPIキーを作成してください",
"Consider creating an api key at https://platform.openai.com/account/api-keys": "https://platform.openai.com/account/api-keys でAPIキーを作成してください",
"OpenAI Security Check Required": "OpenAIのセキュリティチェックが必要です",
"Please open https://chatgpt.com/api/auth/session": "https://chatgpt.com/api/auth/sessionにアクセスしてください",
"Please open https://chatgpt.com": "https://chatgpt.comにアクセスしてください",
"Please open https://chatgpt.com/api/auth/session": "https://chatgpt.com/api/auth/session にアクセスしてください",
"Please open https://chatgpt.com": "https://chatgpt.com にアクセスしてください",
"New Chat": "新しいチャット",
"Summarize Page": "ページをまとめる",
"Translate": "翻訳",
Expand Down Expand Up @@ -131,7 +131,7 @@
"Please keep https://chatgpt.com open and try again. If it still doesn't work, type some characters in the input box of chatgpt web page and try again.": "https://chatgpt.com を開いたままにして、もう一度試してください。それでもうまくいかない場合は、chatgpt webページの入力ボックスにいくつかの文字を入力してからもう一度試してください。",
"Open Side Panel": "サイドパネルを開く",
"Generating...": "生成中...",
"moonshot token required, please login at https://kimi.moonshot.cn first": "moonshotトークンが必要です。最初にhttps://kimi.moonshot.cnにログインしてください",
"moonshot token required, please login at https://kimi.moonshot.cn first": "moonshotトークンが必要です。最初に https://kimi.moonshot.cn にログインしてください",
"Hide context menu of this extension": "この拡張機能のコンテキストメニューを非表示",
"Custom Claude API Url": "カスタムClaude APIのURL"
}
8 changes: 4 additions & 4 deletions src/_locales/ko/main.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@
"Please login at https://chatgpt.com first": "https://chatgpt.com 에서 로그인하세요.",
"Please login at https://claude.ai first": "https://claude.ai 에서 로그인하세요.",
"Please login at https://bing.com first": "https://bing.com 에서 로그인하세요.",
"Then open https://chatgpt.com/api/auth/session": "그런 다음 https://chatgpt.com/api/auth/session을 열거나 다시 질문을 입력하세요.",
"Then open https://chatgpt.com/api/auth/session": "그런 다음 https://chatgpt.com/api/auth/session 을 열거나 다시 질문을 입력하세요.",
"And refresh this page or type you question again": "그런 다음 오른쪽 상단의 재시도 버튼을 클릭합니다.",
"Consider creating an api key at https://platform.openai.com/account/api-keys": "https://platform.openai.com/account/api-keys에서 API 키를 생성하는 것을 고려하세요.",
"Consider creating an api key at https://platform.openai.com/account/api-keys": "https://platform.openai.com/account/api-keys 에서 API 키를 생성하는 것을 고려하세요.",
"OpenAI Security Check Required": "OpenAI 보안 검사 필요",
"Please open https://chatgpt.com/api/auth/session": "https://chatgpt.com/api/auth/session을 열어주세요.",
"Please open https://chatgpt.com": "https://chatgpt.com을 열어주세요.",
"Please open https://chatgpt.com/api/auth/session": "https://chatgpt.com/api/auth/session 을 열어주세요.",
"Please open https://chatgpt.com": "https://chatgpt.com 을 열어주세요.",
"New Chat": "새로운 대화",
"Summarize Page": "페이지 요약",
"Translate": "번역",
Expand Down
2 changes: 1 addition & 1 deletion src/background/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ try {
}
},
{
urls: ['https://*.openai.com/*'],
urls: ['https://*.openai.com/*', 'https://*.chatgpt.com/*'],
types: ['xmlhttprequest'],
},
['requestBody'],
Expand Down
2 changes: 2 additions & 0 deletions src/config/index.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -389,6 +389,8 @@ export async function getPreferredLanguageKey() {
*/
export async function getUserConfig() {
const options = await Browser.storage.local.get(Object.keys(defaultConfig))
if (options.customChatGptWebApiUrl === 'https://chat.openai.com')
options.customChatGptWebApiUrl = 'https://chatgpt.com'
return defaults(options, defaultConfig)
}

Expand Down
1 change: 1 addition & 0 deletions src/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"128": "logo.png"
},
"host_permissions": [
"https://*.chatgpt.com/*",
"https://*.openai.com/*",
"https://*.bing.com/*",
"https://*.poe.com/*",
Expand Down
1 change: 1 addition & 0 deletions src/manifest.v2.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"unlimitedStorage",
"tabs",
"webRequest",
"https://*.chatgpt.com/*",
"https://*.openai.com/",
"https://*.bing.com/",
"wss://*.bing.com/*",
Expand Down
6 changes: 3 additions & 3 deletions src/rules.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,17 @@
{
"operation": "set",
"header": "origin",
"value": "https://tcr9i.chatgpt.com"
"value": "https://tcr9i.chat.openai.com"
},
{
"operation": "set",
"header": "referer",
"value": "https://tcr9i.chatgpt.com/v2/2.4.5/enforcement.6c9d6e9be9aa044cc5ce9548b4abe1b0.html"
"value": "https://tcr9i.chat.openai.com/v2/2.4.5/enforcement.6c9d6e9be9aa044cc5ce9548b4abe1b0.html"
}
]
},
"condition": {
"requestDomains": ["tcr9i.chatgpt.com"],
"requestDomains": ["https://tcr9i.chat.openai.com"],
"resourceTypes": ["xmlhttprequest"]
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/services/apis/chatgpt-web.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ export async function generateAnswersWithChatgptWebApi(port, question, session,
.join('; ')
oaiDeviceId = (
await Browser.cookies.get({
url: 'https://openai.com/',
url: 'https://chatgpt.com/',
name: 'oai-did',
})
).value
Expand Down

0 comments on commit 6fcb5c9

Please sign in to comment.