From d6e75eaede65054697fa95ccf42f9924f59173d7 Mon Sep 17 00:00:00 2001 From: fish Date: Sun, 19 Jul 2026 22:35:44 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8A=E4=B9=89=E6=90=9C=E7=B4=A2=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E8=B7=B3=E8=BD=AC=E7=99=BE=E5=BA=A6=E7=99=BE=E7=A7=91?= =?UTF-8?q?=E8=AF=8D=E6=9D=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 4.7 --- .../LearnEnglish/Views/WordDetailViewController.swift | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/LearnEnglish/LearnEnglish/Views/WordDetailViewController.swift b/LearnEnglish/LearnEnglish/Views/WordDetailViewController.swift index 31510d1..a877df6 100644 --- a/LearnEnglish/LearnEnglish/Views/WordDetailViewController.swift +++ b/LearnEnglish/LearnEnglish/Views/WordDetailViewController.swift @@ -188,9 +188,8 @@ final class WordDetailViewController: UIViewController { private func searchMeaning() { Haptics.selection() - let text = "\(word.word) 是什么意思" - guard let query = text.addingPercentEncoding(withAllowedCharacters: .urlQueryAllowed), - let url = URL(string: "https://www.google.com/search?q=\(query)") else { return } + guard let encoded = word.meaning.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed), + let url = URL(string: "https://baike.baidu.com/item/\(encoded)") else { return } present(SFSafariViewController(url: url), animated: true) }