aboutsummaryrefslogtreecommitdiff
path: root/app/i18n/ko
diff options
context:
space:
mode:
authorGravatar Inverle <inverle@proton.me> 2025-06-30 12:01:56 +0200
committerGravatar GitHub <noreply@github.com> 2025-06-30 12:01:56 +0200
commit7915abd833e1ab7a72ad27b3ec52020ac9ab7051 (patch)
tree293bb99058186a541cb8f6e97ad404de25653f9e /app/i18n/ko
parent7d9fc0ce0c31f22457485a9ff33e0839aaca1254 (diff)
Implement custom feed favicons (#7646)
Closes #3789, #6503 Icon setting when no custom icon is set yet: ![image](https://github.com/user-attachments/assets/28b07dd0-7dac-4c76-b1d7-77035f91a87a) - `Change...` button opens a file dialog, and after selecting a file shows the chosen icon in the preview on the left. `Submit` must be clicked after selecting the icon. - `Reset to default` changes the preview icon to the default one, and also requires `Submit` to be clicked to apply the changes. Full list of changes: - CSP now includes `blob:` in `img-src` for - `indexAction()` and `feedAction()` in `subscriptionController.php` - all of the view actions in `indexController.php` - Introduce new attribute `customFavicon (boolean)` for feeds that indicates if the feed has a custom favicon - `hashFavicon()` in `Feed.php` is dependent on this attribute - `hashFavicon()` has a new parameter called `skipCache (boolean)` that allows the reset of the favicon hash for the Feed object - `resetFaviconHash()` just calls `hashFavicon(skipCache: true)` - `f.php` URLs now have the format of `/f.php?h=XXXXX&t=cachebuster`, where the `t` parameter is only used for serving custom favicons - if `t` parameter is set, `f.php` returns a `Cache-Control: immutable` header - `stripos` and `strpos` were changed to `str_contains` in various places (refactor) - JS for handling the custom favicon configuration logic is in `extra.js` inside `init_update_feed()` which is called when feed configuration is opened from the aside or when the subscription management page with the feed is loaded - Server-side code for uploading the icon in `subscriptionController.php` under `feedAction()` - Errors that may occur during the setting of a custom favicon: - Unsupported image file type (handled only server-side with `isImgMime()`) - When the file is bigger than 1 MiB (default), handled both client-side and server-side - Standard feed error when `updateFeed()` fails - JS vars `javascript_vars.phtml` are no longer escaped with `htmlspecialchars()`, instead with json encoding, - CSS for disabled buttons was added - Max favicon file size is configurable with the `max_favicon_upload_size` option in `config.php` (not exposed via UI) - Custom favicons are currently deleted only when they are either reset to the default icon, or the feed gets deleted. They do not get deleted when the user deletes their account without removing their feeds first. - ` faviconPrepare()` and `faviconRebuild()` are not allowed to be called when the `customFavicon` attribute is `true` - New i18n strings: - `'sub.feed.icon' => 'Icon'` - `'sub.feed.change_favicon' => 'Change…'` - `'sub.feed.reset_favicon' => 'Reset to default'` - `'sub.feed.favicon_changed_by_ext' => 'The icon has been set by the <b>%s</b> extension.'` - `'feedback.sub.feed.favicon.too_large' => 'Uploaded icon is too large. The maximum file size is <em>%s</em>.'` - `'feedback.sub.feed.favicon.unsupported_format' => 'Unsupported image file format!'` - Extension hook `custom_favicon_hash` - `setCustomFavicon()` method - `resetCustomFavicon()` method - `customFaviconExt` and `customFaviconDisallowDel` attributes - example of usage: https://github.com/FreshRSS/Extensions/pull/337 - Extension hook `custom_favicon_btn_url` - Allows extensions to implement a button for setting a custom favicon for individual feeds by providing an URL. The URL will be sent a POST request with the `extAction` field set to either `query_icon_info` or `update_icon`, along with an `id` field which describes the feed's ID.
Diffstat (limited to 'app/i18n/ko')
-rw-r--r--app/i18n/ko/feedback.php4
-rw-r--r--app/i18n/ko/sub.php5
2 files changed, 9 insertions, 0 deletions
diff --git a/app/i18n/ko/feedback.php b/app/i18n/ko/feedback.php
index 457731a97..63d05c02c 100644
--- a/app/i18n/ko/feedback.php
+++ b/app/i18n/ko/feedback.php
@@ -95,6 +95,10 @@ return array(
'cache_cleared' => '<em>%s</em> 캐쉬 지움',
'deleted' => '피드가 삭제되었습니다',
'error' => '피드를 변경할 수 없습니다',
+ 'favicon' => array(
+ 'too_large' => 'Uploaded icon is too large. The maximum file size is <em>%s</em>.', // TODO
+ 'unsupported_format' => 'Unsupported image file format!', // TODO
+ ),
'internal_problem' => 'RSS 피드를 추가할 수 없습니다. 자세한 내용은 <a href="%s">FreshRSS 로그</a>를 참고하세요. <code>#force_feed</code>를 URL에 추가하여 강제로 추가 시도 할 수 있습니다.',
'invalid_url' => 'URL (<em>%s</em>)이 유효하지 않습니다',
'n_actualized' => '%d 개의 피드에서 새 글을 가져왔습니다',
diff --git a/app/i18n/ko/sub.php b/app/i18n/ko/sub.php
index d2f993d38..41d06dc19 100644
--- a/app/i18n/ko/sub.php
+++ b/app/i18n/ko/sub.php
@@ -50,6 +50,7 @@ return array(
'password' => 'HTTP 암호',
'username' => 'HTTP 사용자 이름',
),
+ 'change_favicon' => 'Change…', // TODO
'clear_cache' => '항상 캐시 지우기',
'content_action' => array(
'_' => '글 콘텐츠를 가져올 때의 동작',
@@ -74,12 +75,15 @@ return array(
'help' => 'XML 파일 (data subset. <a href="https://freshrss.github.io/FreshRSS/en/developers/OPML.html" target="_blank">See documentation</a>)', // DIRTY
'label' => 'OPML로 내보내기',
),
+ 'ext_favicon' => 'Set automatically', // TODO
+ 'favicon_changed_by_ext' => 'The icon has been set by the <b>%s</b> extension.', // TODO
'filteractions' => array(
'_' => '필터 동작',
'help' => '한 줄에 한 검색 필터를 작성해 주세요. 실행시 <a href="https://freshrss.github.io/FreshRSS/en/users/10_filter.html#with-the-search-field" target="_blank">문서 참고</a>.',
),
'http_headers' => 'HTTP Headers', // TODO
'http_headers_help' => 'Headers are separated by a newline, and the name and value of a header are separated by a colon (e.g: <kbd><code>Accept: application/atom+xml<br />Authorization: Bearer some-token</code></kbd>).', // TODO
+ 'icon' => 'Icon', // TODO
'information' => '정보',
'keep_min' => '최소 유지 글 개수',
'kind' => array(
@@ -212,6 +216,7 @@ return array(
),
'proxy' => '이 피드를 가져올 때 사용할 프록시 설정',
'proxy_help' => '프로토콜 선택 (예: SOCKS5) 그리고 프록시 주소 입력 (예: <kbd>127.0.0.1:1080</kbd> 혹은 <kbd>username:password@127.0.0.1:1080</kbd>)',
+ 'reset_favicon' => 'Reset to default', // TODO
'selector_preview' => array(
'show_raw' => '소스코드 표시',
'show_rendered' => '콘텐츠 표시',