Merge branch 'master' into remove-ttrss
This commit is contained in:
commit
311d56101b
95 changed files with 4809 additions and 1981 deletions
|
|
@ -1,6 +0,0 @@
|
|||
.git/
|
||||
*.min.js
|
||||
node_modules/
|
||||
symbolic/
|
||||
tmp/
|
||||
vendor/
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
{
|
||||
"env": {
|
||||
"browser": true
|
||||
},
|
||||
"extends": [
|
||||
"eslint:recommended",
|
||||
"standard"
|
||||
],
|
||||
"rules": {
|
||||
"camelcase": "off",
|
||||
"comma-dangle": ["warn", {
|
||||
"arrays": "always-multiline",
|
||||
"objects": "always-multiline"
|
||||
}],
|
||||
"eqeqeq": "off",
|
||||
"indent": ["warn", "tab", { "SwitchCase": 1 }],
|
||||
"linebreak-style": ["error", "unix"],
|
||||
"max-len": ["warn", 165],
|
||||
"no-tabs": "off",
|
||||
"semi": ["warn", "always"],
|
||||
"space-before-function-paren": ["warn", {
|
||||
"anonymous": "always",
|
||||
"named": "never",
|
||||
"asyncArrow": "always"
|
||||
}],
|
||||
"yoda": "off"
|
||||
},
|
||||
"root": true
|
||||
}
|
||||
2
.github/workflows/generate.yml
vendored
2
.github/workflows/generate.yml
vendored
|
|
@ -27,7 +27,7 @@ jobs:
|
|||
id: diff
|
||||
run: |
|
||||
DIFF=$(git diff --numstat -- $FILE | wc -l)
|
||||
echo "::set-output name=DIFF::$DIFF"
|
||||
echo "DIFF=$DIFF" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Commit changes
|
||||
run: |
|
||||
|
|
|
|||
2
.github/workflows/tests.yml
vendored
2
.github/workflows/tests.yml
vendored
|
|
@ -65,7 +65,7 @@ jobs:
|
|||
# https://nodejs.org/en/about/releases/
|
||||
node-version: '18'
|
||||
cache: 'npm'
|
||||
cache-dependency-path: 'Extensions/composer.lock'
|
||||
cache-dependency-path: 'Extensions/package-lock.json'
|
||||
|
||||
- run: npm ci
|
||||
|
||||
|
|
|
|||
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -2,5 +2,6 @@
|
|||
bin/
|
||||
node_modules/
|
||||
symbolic/
|
||||
third-party/
|
||||
tmp/
|
||||
vendor/
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
.git/
|
||||
node_modules/
|
||||
symbolic/
|
||||
third-party/
|
||||
tmp/
|
||||
vendor/
|
||||
|
|
|
|||
|
|
@ -6,11 +6,12 @@
|
|||
"line-length": false,
|
||||
"no-hard-tabs": false,
|
||||
"no-inline-html": {
|
||||
"allowed_elements": ["br", "kbd"]
|
||||
"allowed_elements": ["br", "img", "kbd"]
|
||||
},
|
||||
"no-multiple-blanks": {
|
||||
"maximum": 2
|
||||
},
|
||||
"no-trailing-spaces": true,
|
||||
"ul-indent": false,
|
||||
"ul-style": {
|
||||
"style": "consistent"
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
.git/
|
||||
node_modules/
|
||||
symbolic/
|
||||
third-party/
|
||||
tmp/
|
||||
vendor/
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
.git/
|
||||
node_modules/
|
||||
symbolic/
|
||||
third-party/
|
||||
tmp/
|
||||
vendor/
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
"plugins": [
|
||||
"stylelint-order",
|
||||
"stylelint-scss",
|
||||
"stylelint-stylistic"
|
||||
"@stylistic/stylelint-plugin"
|
||||
],
|
||||
"rules": {
|
||||
"at-rule-empty-line-before": [
|
||||
|
|
@ -11,27 +11,27 @@
|
|||
"ignoreAtRules": [ "after-comment", "else" ]
|
||||
}
|
||||
],
|
||||
"stylistic/at-rule-name-space-after": [
|
||||
"@stylistic/at-rule-name-space-after": [
|
||||
"always", {
|
||||
"ignoreAtRules": [ "after-comment" ]
|
||||
}
|
||||
],
|
||||
"stylistic/block-closing-brace-newline-after": [
|
||||
"@stylistic/block-closing-brace-newline-after": [
|
||||
"always", {
|
||||
"ignoreAtRules": [ "if", "else" ]
|
||||
}
|
||||
],
|
||||
"stylistic/block-closing-brace-newline-before": "always-multi-line",
|
||||
"stylistic/block-opening-brace-newline-after": "always-multi-line",
|
||||
"stylistic/block-opening-brace-space-before": "always",
|
||||
"stylistic/color-hex-case": "lower",
|
||||
"@stylistic/block-closing-brace-newline-before": "always-multi-line",
|
||||
"@stylistic/block-opening-brace-newline-after": "always-multi-line",
|
||||
"@stylistic/block-opening-brace-space-before": "always",
|
||||
"@stylistic/color-hex-case": "lower",
|
||||
"color-hex-length": "short",
|
||||
"color-no-invalid-hex": true,
|
||||
"stylistic/declaration-colon-space-after": "always",
|
||||
"stylistic/declaration-colon-space-before": "never",
|
||||
"stylistic/indentation": "tab",
|
||||
"@stylistic/declaration-colon-space-after": "always",
|
||||
"@stylistic/declaration-colon-space-before": "never",
|
||||
"@stylistic/indentation": "tab",
|
||||
"no-descending-specificity": null,
|
||||
"stylistic/no-eol-whitespace": true,
|
||||
"@stylistic/no-eol-whitespace": true,
|
||||
"property-no-vendor-prefix": true,
|
||||
"rule-empty-line-before": [
|
||||
"always", {
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@ extend-exclude = [
|
|||
"bin/",
|
||||
"node_modules/",
|
||||
"symbolic/",
|
||||
"third-party/",
|
||||
"tmp/",
|
||||
"vendor/",
|
||||
"xExtension-ReadingTime/README.md"
|
||||
|
|
|
|||
36
README.md
36
README.md
|
|
@ -6,15 +6,24 @@ To install an extension, download [the extension archive](https://github.com/Fre
|
|||
Then, upload the specific extension(s) you want on your server.
|
||||
Extensions must be in the `./extensions` directory of your FreshRSS installation.
|
||||
|
||||
## Commands for developers
|
||||
|
||||
```sh
|
||||
# Test this repository and its extensions
|
||||
make test-all
|
||||
|
||||
# Test compatibility between `../FreshRSS/` core and all known extensions from `./repositories.json`
|
||||
./generate.php
|
||||
composer run-script phpstan-third-party
|
||||
```
|
||||
|
||||
## Third-party extensions
|
||||
|
||||
There are some FreshRSS extensions out there, developed by community members:
|
||||
|
||||
### By [@kevinpapst](https://github.com/kevinpapst), [Web](https://www.kevinpapst.de/)
|
||||
|
||||
* [Dilbert](https://github.com/kevinpapst/freshrss-dilbert): Display your daily Dilbert comic in FreshRSS directly
|
||||
* [Teem](https://github.com/kevinpapst/freshrss-teem): Display videos from the skydiving website jointheteem.com inline
|
||||
|
||||
* [Youtube](xExtension-YouTube) shows YouTube videos inline in the feed
|
||||
|
||||
### By [@oYoX](https://github.com/oyox), [Web](https://oyox.de/)
|
||||
|
||||
|
|
@ -47,9 +56,13 @@ There are some FreshRSS extensions out there, developed by community members:
|
|||
|
||||
### By [@CN-Tools](https://github.com/cn-tools)
|
||||
|
||||
* [YouTube Channel 2 RSSFeed](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-YouTubeChannel2RssFeed): You can add a YouTube Channel URL and will get it as RSSFeed
|
||||
* [Feed Title Builder](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-FeedTitleBuilder): Build your own feed title based on url, the original feed title and the date the feed was added
|
||||
* [Black List](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-BlackList): Blacklist to block feeds for users
|
||||
* [Copy 2 Clipboard](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-Copy2Clipboard): Add a button in the navigation bar to copy the destination links of all visible entries into clipboard
|
||||
* [Feed Title Builder](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-FeedTitleBuilder): Build your own feed title based on url, the original feed title and the date the feed was added
|
||||
* [FilterTitle](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-FilterTitle): Filter out feed entries by keywords parsed by the feed entry title
|
||||
* [RemoveEmojis](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-RemoveEmojis): Remove emojis in the title of newly added feed entries
|
||||
* [SendToMyJD2](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-SendToMyJD2): Send links to a jDownloader2 instance with the myJDownloader2 API
|
||||
* [YouTube Channel 2 RSSFeed](https://github.com/cn-tools/cntools_FreshRssExtensions/tree/master/xExtension-YouTubeChannel2RssFeed): You can add a YouTube Channel URL and will get it as RSSFeed. Additional you can detect YouTube shorts.
|
||||
|
||||
### By [@DevonHess](https://github.com/DevonHess)
|
||||
|
||||
|
|
@ -71,6 +84,11 @@ There are some FreshRSS extensions out there, developed by community members:
|
|||
|
||||
* [Pocket Button](https://github.com/christian-putzke/freshrss-pocket-button): Add articles to Pocket with one simple button click or a keyboard shortcut.
|
||||
|
||||
### By [@Joedmin](https://github.com/Joedmin/)
|
||||
|
||||
* [Readeck Button](https://github.com/Joedmin/xExtension-readeck-button): Add articles to a selected Readeck instance with one simple button click or a keyboard shortcut.
|
||||
* [Wallabag Button](https://github.com/Joedmin/xExtension-wallabag-button): Add articles to a selected Wallabag instance with one simple button click or a keyboard shortcut.
|
||||
|
||||
### By [@printfuck](https://github.com/printfuck/)
|
||||
|
||||
* [Readable](https://github.com/printfuck/xExtension-Readable): Fetch article content for selected feeds with [Readability](https://github.com/mozilla/readability) or [Mercury](https://github.com/postlight/mercury-parser)
|
||||
|
|
@ -119,3 +137,11 @@ There are some FreshRSS extensions out there, developed by community members:
|
|||
### By [@jacob2826](https://github.com/jacob2826)
|
||||
|
||||
* [TranslateTitlesCN](https://github.com/jacob2826/FreshRSS-TranslateTitlesCN): Translate article titles of the specified feed into Chinese, using [DeepLX](https://github.com/OwO-Network/DeepLX) or Google Translate.
|
||||
|
||||
### By [@kalvn](https://github.com/kalvn)
|
||||
|
||||
* [Mark Previous as Read](https://github.com/kalvn/freshrss-mark-previous-as-read): Adds a button in the footer of each entry. Clicking this button will mark all previous entries belonging to the current feed, as read.
|
||||
|
||||
### By [@lukasMega](https://github.com/lukasMega)
|
||||
|
||||
* [Word Highlighter](https://github.com/lukasMega/Extensions-FreshRSS-): Gives you ability to highlight user-defined words (using [mark.js](https://github.com/julkue/mark.js))
|
||||
|
|
|
|||
|
|
@ -45,13 +45,13 @@
|
|||
"ext-pdo_pgsql": "*"
|
||||
},
|
||||
"require-dev": {
|
||||
"php": ">=8.0",
|
||||
"php": ">=7.4",
|
||||
"ext-phar": "*",
|
||||
"ext-tokenizer": "*",
|
||||
"ext-xmlwriter": "*",
|
||||
"phpstan/phpstan": "^1.10",
|
||||
"phpstan/phpstan-strict-rules": "^1.5",
|
||||
"squizlabs/php_codesniffer": "^3.7"
|
||||
"phpstan/phpstan": "^1.11",
|
||||
"phpstan/phpstan-strict-rules": "^1.6",
|
||||
"squizlabs/php_codesniffer": "^3.9"
|
||||
},
|
||||
"scripts": {
|
||||
"php-lint": "find . -type d -name 'vendor' -prune -o -name '*.php' -print0 | xargs -0 -n1 -P4 php -l 1>/dev/null",
|
||||
|
|
@ -59,7 +59,8 @@
|
|||
"phpcs": "phpcs . -s",
|
||||
"phpcbf": "phpcbf . -p -s",
|
||||
"phpstan": "phpstan analyse --memory-limit 512M .",
|
||||
"phpstan-next": "phpstan analyse --level 9 --memory-limit 512M $(find . -type d -name 'vendor' -prune -o -name '*.php' -o -name '*.phtml' | grep -Fxvf ./tests/phpstan-next.txt | sort | paste -s -)",
|
||||
"phpstan-next": "phpstan analyse --memory-limit 512M -c phpstan-next.neon .",
|
||||
"phpstan-third-party": "phpstan analyse --memory-limit 512M -c phpstan-third-party.neon .",
|
||||
"test": [
|
||||
"@php-lint",
|
||||
"@phtml-lint",
|
||||
|
|
|
|||
83
composer.lock
generated
83
composer.lock
generated
|
|
@ -4,21 +4,21 @@
|
|||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "2c89b2e0c08f09d94faa394270fc16a9",
|
||||
"content-hash": "52101009acffc9684a721cc20ec9e731",
|
||||
"packages": [],
|
||||
"packages-dev": [
|
||||
{
|
||||
"name": "phpstan/phpstan",
|
||||
"version": "1.10.44",
|
||||
"version": "1.11.10",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/phpstan/phpstan.git",
|
||||
"reference": "bf84367c53a23f759513985c54ffe0d0c249825b"
|
||||
"reference": "640410b32995914bde3eed26fa89552f9c2c082f"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/bf84367c53a23f759513985c54ffe0d0c249825b",
|
||||
"reference": "bf84367c53a23f759513985c54ffe0d0c249825b",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/640410b32995914bde3eed26fa89552f9c2c082f",
|
||||
"reference": "640410b32995914bde3eed26fa89552f9c2c082f",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
|
@ -61,31 +61,27 @@
|
|||
{
|
||||
"url": "https://github.com/phpstan",
|
||||
"type": "github"
|
||||
},
|
||||
{
|
||||
"url": "https://tidelift.com/funding/github/packagist/phpstan/phpstan",
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2023-11-21T16:30:46+00:00"
|
||||
"time": "2024-08-08T09:02:50+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpstan/phpstan-strict-rules",
|
||||
"version": "1.5.2",
|
||||
"version": "1.6.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/phpstan/phpstan-strict-rules.git",
|
||||
"reference": "7a50e9662ee9f3942e4aaaf3d603653f60282542"
|
||||
"reference": "363f921dd8441777d4fc137deb99beb486c77df1"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan-strict-rules/zipball/7a50e9662ee9f3942e4aaaf3d603653f60282542",
|
||||
"reference": "7a50e9662ee9f3942e4aaaf3d603653f60282542",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan-strict-rules/zipball/363f921dd8441777d4fc137deb99beb486c77df1",
|
||||
"reference": "363f921dd8441777d4fc137deb99beb486c77df1",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^7.2 || ^8.0",
|
||||
"phpstan/phpstan": "^1.10.34"
|
||||
"phpstan/phpstan": "^1.11"
|
||||
},
|
||||
"require-dev": {
|
||||
"nikic/php-parser": "^4.13.0",
|
||||
|
|
@ -114,22 +110,22 @@
|
|||
"description": "Extra strict and opinionated rules for PHPStan",
|
||||
"support": {
|
||||
"issues": "https://github.com/phpstan/phpstan-strict-rules/issues",
|
||||
"source": "https://github.com/phpstan/phpstan-strict-rules/tree/1.5.2"
|
||||
"source": "https://github.com/phpstan/phpstan-strict-rules/tree/1.6.0"
|
||||
},
|
||||
"time": "2023-10-30T14:35:06+00:00"
|
||||
"time": "2024-04-20T06:37:51+00:00"
|
||||
},
|
||||
{
|
||||
"name": "squizlabs/php_codesniffer",
|
||||
"version": "3.7.2",
|
||||
"version": "3.10.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
|
||||
"reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879"
|
||||
"url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git",
|
||||
"reference": "86e5f5dd9a840c46810ebe5ff1885581c42a3017"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879",
|
||||
"reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879",
|
||||
"url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/86e5f5dd9a840c46810ebe5ff1885581c42a3017",
|
||||
"reference": "86e5f5dd9a840c46810ebe5ff1885581c42a3017",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
|
@ -139,11 +135,11 @@
|
|||
"php": ">=5.4.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
|
||||
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.3.4"
|
||||
},
|
||||
"bin": [
|
||||
"bin/phpcs",
|
||||
"bin/phpcbf"
|
||||
"bin/phpcbf",
|
||||
"bin/phpcs"
|
||||
],
|
||||
"type": "library",
|
||||
"extra": {
|
||||
|
|
@ -158,22 +154,45 @@
|
|||
"authors": [
|
||||
{
|
||||
"name": "Greg Sherwood",
|
||||
"role": "lead"
|
||||
"role": "Former lead"
|
||||
},
|
||||
{
|
||||
"name": "Juliette Reinders Folmer",
|
||||
"role": "Current lead"
|
||||
},
|
||||
{
|
||||
"name": "Contributors",
|
||||
"homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors"
|
||||
}
|
||||
],
|
||||
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
|
||||
"homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
|
||||
"homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
|
||||
"keywords": [
|
||||
"phpcs",
|
||||
"standards",
|
||||
"static analysis"
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
|
||||
"source": "https://github.com/squizlabs/PHP_CodeSniffer",
|
||||
"wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
|
||||
"issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues",
|
||||
"security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy",
|
||||
"source": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
|
||||
"wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki"
|
||||
},
|
||||
"time": "2023-02-22T23:07:41+00:00"
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://github.com/PHPCSStandards",
|
||||
"type": "github"
|
||||
},
|
||||
{
|
||||
"url": "https://github.com/jrfnl",
|
||||
"type": "github"
|
||||
},
|
||||
{
|
||||
"url": "https://opencollective.com/php_codesniffer",
|
||||
"type": "open_collective"
|
||||
}
|
||||
],
|
||||
"time": "2024-07-21T23:26:44+00:00"
|
||||
}
|
||||
],
|
||||
"aliases": [],
|
||||
|
|
@ -205,7 +224,7 @@
|
|||
"ext-zlib": "*"
|
||||
},
|
||||
"platform-dev": {
|
||||
"php": ">=8.0",
|
||||
"php": ">=7.4",
|
||||
"ext-phar": "*",
|
||||
"ext-tokenizer": "*",
|
||||
"ext-xmlwriter": "*"
|
||||
|
|
|
|||
55
eslint.config.js
Normal file
55
eslint.config.js
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
import globals from "globals";
|
||||
import js from "@eslint/js";
|
||||
import neostandard, { resolveIgnoresFromGitignore } from 'neostandard';
|
||||
import stylistic from '@stylistic/eslint-plugin';
|
||||
|
||||
export default [
|
||||
{
|
||||
files: ["**/*.js"],
|
||||
languageOptions: {
|
||||
globals: {
|
||||
...globals.browser,
|
||||
},
|
||||
sourceType: "script",
|
||||
},
|
||||
},
|
||||
{
|
||||
ignores: [
|
||||
...resolveIgnoresFromGitignore(),
|
||||
"**/*.min.js",
|
||||
"extensions/",
|
||||
"p/scripts/vendor/",
|
||||
],
|
||||
},
|
||||
js.configs.recommended,
|
||||
// stylistic.configs['recommended-flat'],
|
||||
...neostandard(),
|
||||
{
|
||||
plugins: {
|
||||
"@stylistic": stylistic,
|
||||
},
|
||||
rules: {
|
||||
"camelcase": "off",
|
||||
"eqeqeq": "off",
|
||||
"no-empty": ["error", { "allowEmptyCatch": true }],
|
||||
"no-unused-vars": ["error", {
|
||||
"args": "none",
|
||||
"caughtErrors": "none",
|
||||
}],
|
||||
"object-shorthand": "off",
|
||||
"yoda": "off",
|
||||
"@stylistic/indent": ["warn", "tab", { "SwitchCase": 1 }],
|
||||
"@stylistic/linebreak-style": ["error", "unix"],
|
||||
"@stylistic/max-len": ["warn", 165],
|
||||
"@stylistic/no-tabs": "off",
|
||||
"@stylistic/quotes": ["off", "single", { "avoidEscape": true }],
|
||||
"@stylistic/quote-props": ["warn", "consistent"],
|
||||
"@stylistic/semi": ["warn", "always"],
|
||||
"@stylistic/space-before-function-paren": ["warn", {
|
||||
"anonymous": "always",
|
||||
"asyncArrow": "always",
|
||||
"named": "never",
|
||||
}],
|
||||
},
|
||||
},
|
||||
];
|
||||
202
extensions.json
202
extensions.json
|
|
@ -5,7 +5,7 @@
|
|||
"name": "Always togglable menu",
|
||||
"author": "nicofrand",
|
||||
"description": "This makes the icon to toggle the menu always shown, even on larger screens.",
|
||||
"version": 1.2,
|
||||
"version": "1.2",
|
||||
"entrypoint": "TogglableMenu",
|
||||
"type": "user",
|
||||
"url": "https://framagit.org/nicofrand/xextension-togglablemenu",
|
||||
|
|
@ -16,7 +16,7 @@
|
|||
"name": "Auto Refresh",
|
||||
"author": "Essa AlAwadi",
|
||||
"description": "Automatically refreshes the RSS feed when there is no activity",
|
||||
"version": 1.3,
|
||||
"version": "1.3",
|
||||
"entrypoint": "AutoRefresh",
|
||||
"type": "user",
|
||||
"url": "https://github.com/Eisa01/FreshRSS---Auto-Refresh-Extension",
|
||||
|
|
@ -27,7 +27,7 @@
|
|||
"name": "AutoTTL",
|
||||
"author": "Magnus Kokk",
|
||||
"description": "A FreshRSS extension for automatic feed refresh TTL based on the average frequency of entries.",
|
||||
"version": "0.4.1",
|
||||
"version": "0.5.8",
|
||||
"entrypoint": "AutoTTL",
|
||||
"type": "user",
|
||||
"url": "https://github.com/mgnsk/FreshRSS-AutoTTL",
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
"name": "Black List",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Blacklist to block feeds for users",
|
||||
"version": "0.1-alpha",
|
||||
"version": "0.0.1",
|
||||
"entrypoint": "BlackList",
|
||||
"type": "system",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
|
|
@ -49,7 +49,7 @@
|
|||
"name": "Clickable Links",
|
||||
"author": "Kapdap",
|
||||
"description": "Replaces non-clickable plain text URLs found in articles with clickable HTML links.",
|
||||
"version": 1.01,
|
||||
"version": "1.01",
|
||||
"entrypoint": "ClickableLink",
|
||||
"type": "user",
|
||||
"url": "https://github.com/kapdap/freshrss-extensions",
|
||||
|
|
@ -60,7 +60,7 @@
|
|||
"name": "Colorful List",
|
||||
"author": "Claud Xiao",
|
||||
"description": "Colorful Entry Title based on RSS source",
|
||||
"version": 0.3,
|
||||
"version": "0.3.1",
|
||||
"entrypoint": "ColorfulList",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -71,7 +71,7 @@
|
|||
"name": "Comics in feed",
|
||||
"author": "José Moreira",
|
||||
"description": "Embed the images from comics feeds directly.",
|
||||
"version": "1.1.0",
|
||||
"version": "1.5.1",
|
||||
"entrypoint": "ComicsInFeed",
|
||||
"type": "system",
|
||||
"url": "https://github.com/giventofly/freshrss-comicsinfeed",
|
||||
|
|
@ -82,7 +82,7 @@
|
|||
"name": "Copy2Clipboard",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Copy the destination links of all visible entries into clipboard",
|
||||
"version": 0.4,
|
||||
"version": "0.4",
|
||||
"entrypoint": "Copy2Clipboard",
|
||||
"type": "user",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
|
|
@ -93,7 +93,7 @@
|
|||
"name": "Custom CSS",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Give possibility to overwrite the CSS with a user-specific rules.",
|
||||
"version": "0.4",
|
||||
"version": "0.5.2",
|
||||
"entrypoint": "CustomCSS",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -104,7 +104,7 @@
|
|||
"name": "Custom JS",
|
||||
"author": "Frans de Jonge",
|
||||
"description": "Apply custom JS.",
|
||||
"version": "0.4",
|
||||
"version": "0.5.2",
|
||||
"entrypoint": "CustomJS",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -122,22 +122,11 @@
|
|||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Dilberts Daily Comic",
|
||||
"author": "Kevin Papst",
|
||||
"description": "Embed the images from Dilberts daily feed inside article content.",
|
||||
"version": "0.3.1",
|
||||
"entrypoint": "Dilbert",
|
||||
"type": "system",
|
||||
"url": "https://github.com/kevinpapst/freshrss-dilbert",
|
||||
"method": "git",
|
||||
"directory": "xExtension-Dilbert"
|
||||
},
|
||||
{
|
||||
"name": "Feed Priority Shortcut",
|
||||
"author": "Aidi Stan",
|
||||
"description": "Set up visibilities/priorities of your feeds easily",
|
||||
"version": "1.0.3",
|
||||
"version": "1.1.0",
|
||||
"entrypoint": "FeedPriorityShortcut",
|
||||
"type": "user",
|
||||
"url": "https://github.com/aidistan/freshrss-extensions",
|
||||
|
|
@ -148,18 +137,29 @@
|
|||
"name": "FeedTitleBuilder",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Build your own feed title based on url, the original feed title and the date the feed was added",
|
||||
"version": 0.2,
|
||||
"version": "0.2",
|
||||
"entrypoint": "FeedTitleBuilder",
|
||||
"type": "user",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-FeedTitleBuilder"
|
||||
},
|
||||
{
|
||||
"name": "FilterTitle",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Filter feed entries by filter keywords in title",
|
||||
"version": "0.1.0",
|
||||
"entrypoint": "FilterTitle",
|
||||
"type": "system",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-FilterTitle"
|
||||
},
|
||||
{
|
||||
"name": "Fixed Nav Menu",
|
||||
"author": "Marco Heizmann",
|
||||
"description": "Sets the position of the navigation menu to fixed when scrolling down.",
|
||||
"version": 0.1,
|
||||
"version": "0.1",
|
||||
"entrypoint": "FixedNavMenu",
|
||||
"type": "user",
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
|
|
@ -170,7 +170,7 @@
|
|||
"name": "FreshRss FlareSolverr",
|
||||
"author": "James Ravenscroft",
|
||||
"description": "Use a Flaresolverr instance to bypass cloudflare security checks",
|
||||
"version": 0.1,
|
||||
"version": "0.2",
|
||||
"entrypoint": "FlareSolverr",
|
||||
"type": "system",
|
||||
"url": "https://github.com/ravenscroftj/freshrss-flaresolverr-extension",
|
||||
|
|
@ -181,7 +181,7 @@
|
|||
"name": "GReader Redate",
|
||||
"author": "Julien Avérous",
|
||||
"description": "Use published date instead of fetching date.",
|
||||
"version": 1.3,
|
||||
"version": "1.3",
|
||||
"entrypoint": "GReaderRedate",
|
||||
"type": "user",
|
||||
"url": "https://github.com/javerous/freshrss-greader-redate",
|
||||
|
|
@ -192,7 +192,7 @@
|
|||
"name": "Image Cache",
|
||||
"author": "Victrid",
|
||||
"description": "Cache feed images on your own facility or Cloudflare cache.",
|
||||
"version": 0.3,
|
||||
"version": "0.4.0",
|
||||
"entrypoint": "ImageCache",
|
||||
"type": "user",
|
||||
"url": "https://github.com/Victrid/freshrss-image-cache-plugin",
|
||||
|
|
@ -203,7 +203,7 @@
|
|||
"name": "Image Proxy",
|
||||
"author": "Frans de Jonge",
|
||||
"description": "No insecure content warnings or disappearing images.",
|
||||
"version": "0.6",
|
||||
"version": "0.7.3",
|
||||
"entrypoint": "ImageProxy",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -214,18 +214,29 @@
|
|||
"name": "Invidious Video Feed",
|
||||
"author": "Korbak (forked from Kevin Papst)",
|
||||
"description": "Embed YouTube feeds inside article content, but with Invidious.",
|
||||
"version": 1.1,
|
||||
"version": "1.1",
|
||||
"entrypoint": "Invidious",
|
||||
"type": "system",
|
||||
"url": "https://github.com/Korbak/freshrss-invidious",
|
||||
"method": "git",
|
||||
"directory": "xExtension-Invidious"
|
||||
},
|
||||
{
|
||||
"name": "Invidious Video Feed",
|
||||
"author": "Paul Tunbridge (forked from Korbak and Kevin Papst)",
|
||||
"description": "Embed YouTube feeds inside article content, but with Invidious.",
|
||||
"version": "1.1",
|
||||
"entrypoint": "Invidious",
|
||||
"type": "user",
|
||||
"url": "https://github.com/tunbridgep/freshrss-invidious",
|
||||
"method": "git",
|
||||
"directory": "xExtension-Invidious"
|
||||
},
|
||||
{
|
||||
"name": "Kagi Summarizer",
|
||||
"author": "Rudis Muiznieks",
|
||||
"description": "Add buttons to summarize articles with the Kagi Universal Summarizer.",
|
||||
"version": 0.2,
|
||||
"version": "0.3",
|
||||
"entrypoint": "KagiSummarizer",
|
||||
"type": "user",
|
||||
"url": "https://code.sitosis.com/rudism/freshrss-kagi-summarizer",
|
||||
|
|
@ -236,7 +247,7 @@
|
|||
"name": "Keep Folder State",
|
||||
"author": "Marco Heizmann",
|
||||
"description": "Stores the state of the folders locally and expand them automatically if necessary.",
|
||||
"version": 0.1,
|
||||
"version": "0.1",
|
||||
"entrypoint": "KeepFolderState",
|
||||
"type": "user",
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
|
|
@ -247,18 +258,29 @@
|
|||
"name": "LaTeX support",
|
||||
"author": "Alexis Degrugillier",
|
||||
"description": "Add support for LaTeX notation rendering",
|
||||
"version": "0.1.4",
|
||||
"version": "0.1.5",
|
||||
"entrypoint": "LatexSupport",
|
||||
"type": "user",
|
||||
"url": "https://github.com/aledeg/xExtension-LatexSupport",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Mark Previous as Read",
|
||||
"author": "kalvn",
|
||||
"description": "This extension adds a button in the footer of each entry. Clicking this button will mark all previous entries as read.",
|
||||
"version": "1.1.1",
|
||||
"entrypoint": "MarkPreviousAsRead",
|
||||
"type": "user",
|
||||
"url": "https://github.com/kalvn/freshrss-mark-previous-as-read",
|
||||
"method": "git",
|
||||
"directory": "xExtension-MarkPreviousAsRead"
|
||||
},
|
||||
{
|
||||
"name": "Mobile Scroll Menu",
|
||||
"author": "Marco Heizmann",
|
||||
"description": "Automatically hides the header menu on mobile phones, when scrolling down and shows it when scrolling up.",
|
||||
"version": 0.2,
|
||||
"version": "0.2",
|
||||
"entrypoint": "MobileScrollMenu",
|
||||
"type": "user",
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
|
|
@ -268,8 +290,8 @@
|
|||
{
|
||||
"name": "News Assistant",
|
||||
"author": "Mervyn Zhan",
|
||||
"description": "Use the api of `OpenAI` to summary the news.",
|
||||
"version": 0.1,
|
||||
"description": "Using the ai api of `OpenAI`, `Anthropic`, `Groq` by [Portkey-AI/gateway](https://github.com/Portkey-AI/gateway/) to summary the news.",
|
||||
"version": "0.11.2",
|
||||
"entrypoint": "NewsAssistant",
|
||||
"type": "system",
|
||||
"url": "https://github.com/reply2future/xExtension-NewsAssistant",
|
||||
|
|
@ -280,7 +302,7 @@
|
|||
"name": "Pocket Button",
|
||||
"author": "Christian Putzke",
|
||||
"description": "Add articles to Pocket with one simple button click or a keyboard shortcut.",
|
||||
"version": 0.4,
|
||||
"version": "0.5",
|
||||
"entrypoint": "PocketButton",
|
||||
"type": "user",
|
||||
"url": "https://github.com/christian-putzke/freshrss-pocket-button",
|
||||
|
|
@ -291,7 +313,7 @@
|
|||
"name": "Quick Collapse",
|
||||
"author": "romibi and Marien Fressinaud",
|
||||
"description": "Quickly change from folded to unfolded articles",
|
||||
"version": "0.2",
|
||||
"version": "0.2.2",
|
||||
"entrypoint": "QuickCollapse",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -302,7 +324,7 @@
|
|||
"name": "RSS-Bridge",
|
||||
"author": "Devon Hess",
|
||||
"description": "Run URLs through <a href=\"https://github.com/rss-bridge/rss-bridge\">RSS-Bridge</a> detection.",
|
||||
"version": 1.1,
|
||||
"version": "1.1",
|
||||
"entrypoint": "RssBridge",
|
||||
"type": "system",
|
||||
"url": "https://github.com/DevonHess/FreshRSS-Extensions",
|
||||
|
|
@ -313,18 +335,29 @@
|
|||
"name": "Readable",
|
||||
"author": "printfuck",
|
||||
"description": "Fetch article content for selected feeds with readability or mercury",
|
||||
"version": "0.2",
|
||||
"version": "0.3",
|
||||
"entrypoint": "Readable",
|
||||
"type": "user",
|
||||
"url": "https://github.com/printfuck/xExtension-Readable",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Readeck Button",
|
||||
"author": "Joedmin",
|
||||
"description": "Add articles to Readeck with one simple button click or a keyboard shortcut.",
|
||||
"version": "0.5",
|
||||
"entrypoint": "ReadeckButton",
|
||||
"type": "user",
|
||||
"url": "https://github.com/Joedmin/xExtension-readeck-button",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Reading Time",
|
||||
"author": "Lapineige",
|
||||
"description": "Add a reading time estimation next to each article title",
|
||||
"version": 1.5,
|
||||
"version": "1.5",
|
||||
"entrypoint": "ReadingTime",
|
||||
"type": "user",
|
||||
"url": "https://framagit.org/Lapineige/FreshRSS_Extension-ReadingTime/",
|
||||
|
|
@ -335,7 +368,7 @@
|
|||
"name": "ReadingTime",
|
||||
"author": "Lapineige",
|
||||
"description": "Add a reading time estimation next to each article",
|
||||
"version": "1.5",
|
||||
"version": "1.5.1",
|
||||
"entrypoint": "ReadingTime",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -346,18 +379,40 @@
|
|||
"name": "Reddit Image",
|
||||
"author": "Alexis Degrugillier",
|
||||
"description": "Modify reddit entries by displaying known medias and easing access to the linked resource",
|
||||
"version": "1.1.1",
|
||||
"version": "1.2.0",
|
||||
"entrypoint": "RedditImage",
|
||||
"type": "user",
|
||||
"url": "https://github.com/aledeg/xExtension-RedditImage",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Remove emojis",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "remove emojis in the title of newly added feed entries",
|
||||
"version": "0.1-dev",
|
||||
"entrypoint": "RemoveEmojis",
|
||||
"type": "user",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-RemoveEmojis"
|
||||
},
|
||||
{
|
||||
"name": "SendToMyJD2",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Send links to a jDownloader2 instance with the myJDownloader2 API",
|
||||
"version": "0.0.1-alpha",
|
||||
"entrypoint": "SendToMyJD2",
|
||||
"type": "user",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-SendToMyJD2"
|
||||
},
|
||||
{
|
||||
"name": "Share By Email",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Improve the sharing by email system.",
|
||||
"version": "0.2",
|
||||
"version": "0.2.3",
|
||||
"entrypoint": "ShareByEmail",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -367,8 +422,8 @@
|
|||
{
|
||||
"name": "ShowFeedID",
|
||||
"author": "math-GH",
|
||||
"description": "Show the feed ID",
|
||||
"version": "0.2",
|
||||
"description": "Show the ID of feed and category",
|
||||
"version": "0.3.0",
|
||||
"entrypoint": "ShowFeedID",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -379,7 +434,7 @@
|
|||
"name": "Smart Mobile Menu",
|
||||
"author": "Marco Heizmann",
|
||||
"description": "Minimizes the required button space and groups buttons.",
|
||||
"version": 0.1,
|
||||
"version": "0.1",
|
||||
"entrypoint": "SmartMobileMenu",
|
||||
"type": "user",
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
|
|
@ -390,24 +445,13 @@
|
|||
"name": "Sticky Feeds",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Set the feed aside in the main stream following the window scroll.",
|
||||
"version": "0.2",
|
||||
"version": "0.2.1",
|
||||
"entrypoint": "StickyFeeds",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-StickyFeeds"
|
||||
},
|
||||
{
|
||||
"name": "Teem Video Feed",
|
||||
"author": "Kevin Papst",
|
||||
"description": "Embed video from JOINTHETEEM inside article content.",
|
||||
"version": 0.1,
|
||||
"entrypoint": "Teem",
|
||||
"type": "system",
|
||||
"url": "https://github.com/kevinpapst/freshrss-teem",
|
||||
"method": "git",
|
||||
"directory": "xExtension-Teem"
|
||||
},
|
||||
{
|
||||
"name": "Theme Mode Synchronizer",
|
||||
"author": "Aidi Stan",
|
||||
|
|
@ -423,7 +467,7 @@
|
|||
"name": "ThreePanesView",
|
||||
"author": "nicofrand",
|
||||
"description": "Adds a third vertical pane along the articles list, to display the articles content.",
|
||||
"version": 1.14,
|
||||
"version": "1.14",
|
||||
"entrypoint": "ThreePanesView",
|
||||
"type": "user",
|
||||
"url": "https://framagit.org/nicofrand/xextension-threepanesview",
|
||||
|
|
@ -434,7 +478,7 @@
|
|||
"name": "Title-Wrap",
|
||||
"author": "₣rans de Jonge, Joris Kinable",
|
||||
"description": "Applies a line-wrap to long article titles, as opposed to truncating the title when it overflows its display area.",
|
||||
"version": "0.2",
|
||||
"version": "0.3.0",
|
||||
"entrypoint": "TitleWrap",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
|
|
@ -445,7 +489,7 @@
|
|||
"name": "Touch Control",
|
||||
"author": "Marco Heizmann",
|
||||
"description": "Add touch gestures to FreshRSS.",
|
||||
"version": 0.2,
|
||||
"version": "0.2",
|
||||
"entrypoint": "TouchControl",
|
||||
"type": "user",
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
|
|
@ -468,13 +512,24 @@
|
|||
"name": "TwitchChannel2RssFeed",
|
||||
"author": "Babico",
|
||||
"description": "Transfer Twitch Channel URL into RSS Feed URL.",
|
||||
"version": 0.2,
|
||||
"version": "0.2",
|
||||
"entrypoint": "TwitchChannel2RssFeed",
|
||||
"type": "user",
|
||||
"url": "https://github.com/babico/xExtension-TwitchChannel2RssFeed",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "Wallabag Button",
|
||||
"author": "Joedmin",
|
||||
"description": "Add articles to Wallabag with one simple button click or a keyboard shortcut.",
|
||||
"version": "0.2",
|
||||
"entrypoint": "WallabagButton",
|
||||
"type": "user",
|
||||
"url": "https://github.com/Joedmin/xExtension-wallabag-button",
|
||||
"method": "git",
|
||||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "White List",
|
||||
"author": "Alexis Degrugillier",
|
||||
|
|
@ -487,21 +542,32 @@
|
|||
"directory": "."
|
||||
},
|
||||
{
|
||||
"name": "YouTube/PeerTube Video Feed",
|
||||
"name": "Word highlighter",
|
||||
"author": "Lukas Melega",
|
||||
"description": "Highlight specific words",
|
||||
"version": "0.0.2",
|
||||
"entrypoint": "WordHighlighter",
|
||||
"type": "user",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-WordHighlighter"
|
||||
},
|
||||
{
|
||||
"name": "YouTube Video Feed",
|
||||
"author": "Kevin Papst",
|
||||
"description": "Embed YouTube/PeerTube feeds inside article content.",
|
||||
"version": 0.1,
|
||||
"description": "Embed YouTube feeds inside article content.",
|
||||
"version": "0.12",
|
||||
"entrypoint": "YouTube",
|
||||
"type": "user",
|
||||
"url": "https://github.com/kevinpapst/freshrss-youtube",
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
"method": "git",
|
||||
"directory": "xExtension-YouTube"
|
||||
},
|
||||
{
|
||||
"name": "YouTubeChannel2RssFeed",
|
||||
"author": "CNTools | Clemens Neubauer",
|
||||
"description": "Transfer YouTube Channel URL into RSS Feed URL.",
|
||||
"version": 0.4,
|
||||
"description": "Transfer YouTube URL into RSS Feed URL.",
|
||||
"version": "0.6.1",
|
||||
"entrypoint": "YouTubeChannel2RssFeed",
|
||||
"type": "user",
|
||||
"url": "https://github.com/cn-tools/cntools_FreshRssExtensions",
|
||||
|
|
|
|||
|
|
@ -6,11 +6,12 @@
|
|||
// ------------------- //
|
||||
const VERSION = 0.1;
|
||||
const TYPE_GIT = 'git';
|
||||
$tempFolder = './tmp';
|
||||
$tempFolder = './third-party/';
|
||||
|
||||
$extensions = [];
|
||||
$gitRepositories = [];
|
||||
if (file_exists($tempFolder)) {
|
||||
// TODO: Improve by keeping git copy if possible (e.g. fetch + reset)
|
||||
exec("rm -rf -- {$tempFolder}");
|
||||
}
|
||||
|
||||
|
|
@ -53,6 +54,7 @@ foreach ($gitRepositories as $key => $gitRepository) {
|
|||
}
|
||||
$directory = basename(dirname($metadataFile));
|
||||
$metadata['url'] = $gitRepository;
|
||||
$metadata['version'] = strval($metadata['version']);
|
||||
$metadata['method'] = TYPE_GIT;
|
||||
$metadata['directory'] = ($directory === sha1($gitRepository)) ? '.' : $directory;
|
||||
$extensions[] = $metadata;
|
||||
|
|
|
|||
3459
package-lock.json
generated
3459
package-lock.json
generated
File diff suppressed because it is too large
Load diff
30
package.json
30
package.json
|
|
@ -1,5 +1,6 @@
|
|||
{
|
||||
"name": "freshrss-extensions",
|
||||
"type": "module",
|
||||
"description": "Extensions for FreshRSS",
|
||||
"homepage": "https://freshrss.org/",
|
||||
"readmeFilename": "README.md",
|
||||
|
|
@ -16,11 +17,11 @@
|
|||
},
|
||||
"license": "see each extension",
|
||||
"engines": {
|
||||
"node": ">=12"
|
||||
"node": ">=18"
|
||||
},
|
||||
"scripts": {
|
||||
"eslint": "eslint --ext .js .",
|
||||
"eslint_fix": "eslint --fix --ext .js .",
|
||||
"eslint": "eslint .",
|
||||
"eslint_fix": "eslint --fix .",
|
||||
"markdownlint": "markdownlint '**/*.md'",
|
||||
"markdownlint_fix": "markdownlint --fix '**/*.md'",
|
||||
"rtlcss": "npm run symbolic && rtlcss -d symbolic/ && find -L symbolic/ -type f -name '*.rtl.rtl.css' -delete",
|
||||
|
|
@ -31,18 +32,17 @@
|
|||
"fix": "npm run rtlcss && npm run stylelint_fix && npm run eslint_fix && npm run markdownlint_fix"
|
||||
},
|
||||
"devDependencies": {
|
||||
"eslint": "^8.54.0",
|
||||
"eslint-config-standard": "^17.1.0",
|
||||
"eslint-plugin-import": "^2.29.0",
|
||||
"eslint-plugin-n": "^16.3.1",
|
||||
"eslint-plugin-promise": "^6.1.1",
|
||||
"markdownlint-cli": "^0.37.0",
|
||||
"rtlcss": "^4.1.1",
|
||||
"sass": "^1.69.5",
|
||||
"stylelint": "^15.11.0",
|
||||
"stylelint-config-recommended-scss": "^13.1.0",
|
||||
"stylelint-order": "^6.0.3",
|
||||
"stylelint-stylistic": "^0.4.3"
|
||||
"eslint": "^9.8.0",
|
||||
"@eslint/js": "^9.8.0",
|
||||
"globals": "^15.9.0",
|
||||
"markdownlint-cli": "^0.41.0",
|
||||
"neostandard": "^0.11.2",
|
||||
"rtlcss": "^4.2.0",
|
||||
"sass": "^1.77.8",
|
||||
"stylelint": "^16.8.1",
|
||||
"stylelint-config-recommended-scss": "^14.1.0",
|
||||
"stylelint-order": "^6.0.4",
|
||||
"@stylistic/stylelint-plugin": "^3.0.0"
|
||||
},
|
||||
"rtlcssConfig": {}
|
||||
}
|
||||
|
|
|
|||
162
phpcs.xml
162
phpcs.xml
|
|
@ -1,119 +1,113 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ruleset name="FreshRSS Ruleset">
|
||||
<description>Created with the PHP Coding Standard Generator. https://edorian.github.com/php-coding-standard-generator/</description>
|
||||
<arg name="extensions" value="php,phtml,css,js"/>
|
||||
<ruleset name="FreshRSS">
|
||||
<arg name="extensions" value="php,phtml"/>
|
||||
<arg name="tab-width" value="4"/>
|
||||
<exclude-pattern>./lib/SimplePie/</exclude-pattern>
|
||||
<exclude-pattern>./lib/PHPMailer/</exclude-pattern>
|
||||
<exclude-pattern>./lib/http-conditional.php</exclude-pattern>
|
||||
<exclude-pattern>./lib/lib_phpQuery.php</exclude-pattern>
|
||||
<exclude-pattern>./node_modules/</exclude-pattern>
|
||||
<exclude-pattern>./.git/</exclude-pattern>
|
||||
<exclude-pattern>./data/config.php</exclude-pattern>
|
||||
<exclude-pattern>./data/update.php</exclude-pattern>
|
||||
<exclude-pattern>./data/users/*/config.php</exclude-pattern>
|
||||
<exclude-pattern>./extensions/</exclude-pattern>
|
||||
<exclude-pattern>./lib/http-conditional.php</exclude-pattern>
|
||||
<exclude-pattern>./lib/marienfressinaud/</exclude-pattern>
|
||||
<exclude-pattern>./lib/phpgt/</exclude-pattern>
|
||||
<exclude-pattern>./lib/phpmailer/</exclude-pattern>
|
||||
<exclude-pattern>./lib/simplepie/</exclude-pattern>
|
||||
<exclude-pattern>./node_modules/</exclude-pattern>
|
||||
<exclude-pattern>./p/scripts/vendor/</exclude-pattern>
|
||||
<exclude-pattern>./vendor/</exclude-pattern>
|
||||
<exclude-pattern>*.min.js$</exclude-pattern>
|
||||
<!-- Duplicate class names are not allowed -->
|
||||
<!-- Additional exclusions for Extensions: -->
|
||||
<exclude-pattern>./symbolic/</exclude-pattern>
|
||||
<exclude-pattern>./third-party/</exclude-pattern>
|
||||
<exclude-pattern>./tmp/</exclude-pattern>
|
||||
<rule ref="PSR12">
|
||||
<exclude name="Generic.ControlStructures.InlineControlStructure.NotAllowed"/>
|
||||
<exclude name="Generic.Formatting.DisallowMultipleStatements.SameLine"/>
|
||||
<exclude name="Generic.WhiteSpace.DisallowTabIndent.NonIndentTabsUsed"/>
|
||||
<exclude name="Generic.WhiteSpace.DisallowTabIndent.TabsUsed"/>
|
||||
<exclude name="Generic.WhiteSpace.DisallowTabIndent.TabsUsedHeredocCloser"/>
|
||||
<exclude name="PSR1.Classes.ClassDeclaration.MissingNamespace"/>
|
||||
<exclude name="PSR1.Classes.ClassDeclaration.MultipleClasses"/>
|
||||
<exclude name="PSR1.Files.SideEffects.FoundWithSymbols"/>
|
||||
<exclude name="PSR1.Methods.CamelCapsMethodName.NotCamelCaps"/>
|
||||
<exclude name="PSR12.Classes.OpeningBraceSpace.Found"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR12.ControlStructures.ControlStructureSpacing.CloseParenthesisLine"/>
|
||||
<exclude name="PSR12.ControlStructures.ControlStructureSpacing.FirstExpressionLine"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR12.Files.FileHeader.IncorrectOrder"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR12.Files.FileHeader.SpacingAfterBlock"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR12.Traits.UseDeclaration.MultipleImport"/>
|
||||
<exclude name="PSR2.Classes.ClassDeclaration.CloseBraceAfterBody"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR2.Classes.ClassDeclaration.OpenBraceNewLine"/><!-- Consider using PSR12 defaults instead -->
|
||||
<exclude name="PSR2.ControlStructures.SwitchDeclaration.BodyOnNextLineCASE"/>
|
||||
<exclude name="PSR2.ControlStructures.SwitchDeclaration.BreakNotNewLine"/>
|
||||
<exclude name="PSR2.Functions.FunctionCallSignature.ContentAfterOpenBracket"/>
|
||||
<exclude name="PSR2.Methods.FunctionCallSignature.CloseBracketLine"/>
|
||||
<exclude name="PSR2.Methods.FunctionCallSignature.ContentAfterOpenBracket"/>
|
||||
<exclude name="PSR2.Methods.FunctionCallSignature.Indent"/>
|
||||
<exclude name="PSR2.Methods.FunctionCallSignature.MultipleArguments"/>
|
||||
<exclude name="PSR2.Methods.MethodDeclaration.Underscore"/>
|
||||
<exclude name="Squiz.Classes.ValidClassName.NotCamelCaps"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.BraceOnSameLine"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.CloseBracketLine"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.ContentAfterBrace"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.FirstParamSpacing"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.Indent"/>
|
||||
<exclude name="Squiz.Functions.MultiLineFunctionDeclaration.OneParamPerLine"/>
|
||||
<exclude name="Squiz.WhiteSpace.ScopeClosingBrace.ContentBefore"/>
|
||||
</rule>
|
||||
<rule ref="Generic.Classes.DuplicateClassName"/>
|
||||
<!-- Statements must not be empty -->
|
||||
<rule ref="Generic.CodeAnalysis.EmptyStatement"/>
|
||||
<!-- Unconditional if-statements are not allowed -->
|
||||
<rule ref="Generic.CodeAnalysis.UnconditionalIfStatement"/>
|
||||
<!-- Do not use final statements inside final classes -->
|
||||
<rule ref="Generic.CodeAnalysis.UnnecessaryFinalModifier"/>
|
||||
<!-- Do not override methods to call their parent -->
|
||||
<rule ref="Generic.CodeAnalysis.UselessOverridingMethod"/>
|
||||
<!-- Maximum line length -->
|
||||
<rule ref="Generic.Files.LineLength">
|
||||
<!-- For language strings maximum line lengths make little sense. -->
|
||||
<exclude-pattern>./app/i18n/</exclude-pattern>
|
||||
<!-- Don’t enforce line length on the HTML; the point is to improve legibility, not reduce it -->
|
||||
<exclude-pattern>*.phtml$</exclude-pattern>
|
||||
<properties>
|
||||
<property name="lineLimit" value="165"/>
|
||||
<property name="absoluteLineLimit" value="190"/>
|
||||
</properties>
|
||||
<exclude-pattern>/app/i18n/*\.php$</exclude-pattern>
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
<!-- When calling a function: -->
|
||||
<!-- Do not add a space before the opening parenthesis -->
|
||||
<!-- Do not add a space after the opening parenthesis -->
|
||||
<!-- Do not add a space before the closing parenthesis -->
|
||||
<!-- Do not add a space before a comma -->
|
||||
<!-- Add a space after a comma -->
|
||||
<rule ref="Generic.Functions.FunctionCallArgumentSpacing"/>
|
||||
<rule ref="Generic.PHP.DisallowShortOpenTag">
|
||||
<exclude name="Generic.PHP.DisallowShortOpenTag.EchoFound"/>
|
||||
</rule>
|
||||
<rule ref="Generic.PHP.DeprecatedFunctions" />
|
||||
<!-- Use UPPERCARE for constants -->
|
||||
<rule ref="Generic.NamingConventions.UpperCaseConstantName"/>
|
||||
<!-- Use lowercase for 'true', 'false' and 'null' -->
|
||||
<rule ref="Generic.PHP.LowerCaseConstant"/>
|
||||
<!-- Use a single string instead of concatenating -->
|
||||
<rule ref="Generic.Functions.OpeningFunctionBraceKernighanRitchie"/><!-- Consider using PSR12 defaults instead -->
|
||||
<rule ref="Generic.PHP.DeprecatedFunctions"/>
|
||||
<rule ref="Generic.Strings.UnnecessaryStringConcat">
|
||||
<properties>
|
||||
<!-- Allow string concatenating across multiple lines -->
|
||||
<property name="allowMultiline" value="true"/>
|
||||
</properties>
|
||||
</rule>
|
||||
<!-- Use tabs for indentation -->
|
||||
<rule ref="Generic.WhiteSpace.DisallowSpaceIndent"/>
|
||||
<!-- Parameters with default values must appear last in functions -->
|
||||
<rule ref="PEAR.Functions.ValidDefaultValue"/>
|
||||
<!-- Use 'elseif' instead of 'else if' -->
|
||||
<rule ref="PSR2.ControlStructures.ElseIfDeclaration"/>
|
||||
<!-- Do not add spaces after opening or before closing bracket -->
|
||||
<rule ref="PSR2.ControlStructures.ControlStructureSpacing"/>
|
||||
<!-- Add a new line at the end of a file -->
|
||||
<rule ref="PSR2.Files.EndFileNewline"/>
|
||||
<!-- Use Unix newlines -->
|
||||
<rule ref="Generic.Files.LineEndings">
|
||||
<properties>
|
||||
<property name="eolChar" value="\n" />
|
||||
</properties>
|
||||
<rule ref="Generic.WhiteSpace.ScopeIndent.Incorrect">
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
<exclude-pattern>/app/install.php</exclude-pattern>
|
||||
</rule>
|
||||
<!-- Add space after closing parenthesis -->
|
||||
<!-- Add body into new line -->
|
||||
<!-- Close body in new line -->
|
||||
<rule ref="Generic.WhiteSpace.ScopeIndent.IncorrectExact">
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
<exclude-pattern>/app/install.php</exclude-pattern>
|
||||
</rule>
|
||||
<rule ref="Internal.NoCodeFound">
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
<!-- <rule ref="Squiz.Commenting.ClassComment.Missing"/> --><!-- Consider adding -->
|
||||
|
||||
<rule ref="Squiz.ControlStructures.ControlSignature">
|
||||
<!-- No space after keyword (before opening parenthesis) -->
|
||||
<exclude name="Squiz.ControlStructures.ControlSignature.SpaceAfterKeyword"/>
|
||||
</rule>
|
||||
<!-- When declaring a function: -->
|
||||
<!-- Do not add a space before a comma -->
|
||||
<!-- Add a space after a comma -->
|
||||
<!-- Add a space before and after an equal sign -->
|
||||
<rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing">
|
||||
<include-pattern>*\.phtml$</include-pattern>
|
||||
<properties>
|
||||
<property name="equalsSpacing" value="1"/>
|
||||
<property name="requiredSpacesBeforeColon" value="0" />
|
||||
</properties>
|
||||
</rule>
|
||||
<!-- Do not add spaces when casting -->
|
||||
<rule ref="Squiz.WhiteSpace.CastSpacing"/>
|
||||
<!-- Operators must have a space around them -->
|
||||
<rule ref="Squiz.ControlStructures.ControlSignature">
|
||||
<include-pattern>*\.php$</include-pattern>
|
||||
</rule>
|
||||
|
||||
<rule ref="Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace">
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.OperatorSpacing">
|
||||
<properties>
|
||||
<property name="ignoreNewlines" value="true" />
|
||||
<property name="ignoreNewlines" value="true"/>
|
||||
</properties>
|
||||
</rule>
|
||||
<!-- Do not add a whitespace before a semicolon -->
|
||||
<rule ref="Squiz.WhiteSpace.ScopeClosingBrace.Indent">
|
||||
<exclude-pattern>*\.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
<rule ref="Squiz.WhiteSpace.SemicolonSpacing"/>
|
||||
<!-- Do not add whitespace at start or end of a file or end of a line -->
|
||||
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace"/>
|
||||
<!-- Expected space after closing parenthesis -->
|
||||
<rule ref="Squiz.ControlStructures.ControlSignature.SpaceAfterCloseParenthesis">
|
||||
<exclude-pattern>.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
<!-- Opening brace on same line as function declaration -->
|
||||
<rule ref="Generic.Functions.OpeningFunctionBraceKernighanRitchie" />
|
||||
<!-- Newline required after opening brace -->
|
||||
<rule ref="Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace">
|
||||
<exclude-pattern>.phtml$</exclude-pattern>
|
||||
<exclude-pattern>.js$</exclude-pattern>
|
||||
</rule>
|
||||
<!-- No PHP code was found in this file -->
|
||||
<rule ref="Internal.NoCodeFound">
|
||||
<exclude-pattern>.phtml$</exclude-pattern>
|
||||
</rule>
|
||||
</ruleset>
|
||||
|
|
|
|||
9
phpstan-next.neon
Normal file
9
phpstan-next.neon
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
includes:
|
||||
- phpstan.neon
|
||||
|
||||
parameters:
|
||||
level: 9
|
||||
excludePaths:
|
||||
analyse:
|
||||
- xExtension-ImageProxy/configure.phtml
|
||||
- xExtension-ImageProxy/extension.php
|
||||
24
phpstan-third-party.neon
Normal file
24
phpstan-third-party.neon
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
parameters:
|
||||
level: 0
|
||||
fileExtensions:
|
||||
- php
|
||||
- phtml
|
||||
paths:
|
||||
- ../FreshRSS
|
||||
- third-party/
|
||||
excludePaths:
|
||||
analyse:
|
||||
- ../FreshRSS
|
||||
- third-party/*/vendor/*
|
||||
analyseAndScan:
|
||||
- .git/
|
||||
- node_modules/
|
||||
- symbolic/
|
||||
- third-party/*/tests/*
|
||||
- tmp/
|
||||
- vendor/
|
||||
- xExtension-*
|
||||
dynamicConstantNames:
|
||||
- TYPE_GIT
|
||||
reportMaybesInPropertyPhpDocTypes: false
|
||||
treatPhpDocTypesAsCertain: false
|
||||
16
phpstan.neon
16
phpstan.neon
|
|
@ -1,7 +1,7 @@
|
|||
parameters:
|
||||
# TODO: Increase rule-level https://phpstan.org/user-guide/rule-levels
|
||||
level: 1
|
||||
treatPhpDocTypesAsCertain: false
|
||||
phpVersion: 80399 # TODO: Remove line when moving composer.json to PHP 8+
|
||||
fileExtensions:
|
||||
- php
|
||||
- phtml
|
||||
|
|
@ -16,23 +16,33 @@ parameters:
|
|||
- .git/
|
||||
- node_modules/
|
||||
- symbolic/
|
||||
- third-party/
|
||||
- tmp/
|
||||
dynamicConstantNames:
|
||||
- TYPE_GIT
|
||||
checkMissingOverrideMethodAttribute: true
|
||||
reportMaybesInPropertyPhpDocTypes: false
|
||||
treatPhpDocTypesAsCertain: false
|
||||
strictRules:
|
||||
allRules: false
|
||||
booleansInConditions: false # TODO pass
|
||||
booleansInConditions: true
|
||||
closureUsesThis: true
|
||||
disallowedConstructs: false
|
||||
disallowedLooseComparison: false
|
||||
matchingInheritedMethodNames: true
|
||||
noVariableVariables: false # TODO pass
|
||||
noVariableVariables: true
|
||||
numericOperandsInArithmeticOperators: true
|
||||
overwriteVariablesWithLoop: true
|
||||
requireParentConstructorCall: true
|
||||
strictCalls: true
|
||||
switchConditionsMatchingType: true
|
||||
uselessCast: true
|
||||
exceptions:
|
||||
check:
|
||||
missingCheckedExceptionInThrows: false # TODO pass
|
||||
tooWideThrowType: true
|
||||
implicitThrows: false
|
||||
checkedExceptionClasses:
|
||||
- 'Minz_Exception'
|
||||
includes:
|
||||
- vendor/phpstan/phpstan-strict-rules/rules.neon
|
||||
|
|
|
|||
|
|
@ -1,15 +1,6 @@
|
|||
[{
|
||||
"url": "https://github.com/FreshRSS/Extensions",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/kevinpapst/freshrss-youtube",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/kevinpapst/freshrss-dilbert",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/kevinpapst/freshrss-teem",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/oyox/FreshRSS-extensions",
|
||||
"type": "git"
|
||||
|
|
@ -53,7 +44,7 @@
|
|||
"url": "https://github.com/babico/xExtension-TwitchChannel2RssFeed",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "thttps://github.com/tunbridgep/freshrss-invidious",
|
||||
"url": "https://github.com/tunbridgep/freshrss-invidious",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/javerous/freshrss-greader-redate",
|
||||
|
|
@ -65,6 +56,12 @@
|
|||
"url": "https://github.com/christian-putzke/freshrss-pocket-button",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/Joedmin/xExtension-readeck-button",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/Joedmin/xExtension-wallabag-button",
|
||||
"type": "git"
|
||||
},{
|
||||
"url": "https://github.com/printfuck/xExtension-Readable",
|
||||
"type": "git"
|
||||
}, {
|
||||
|
|
@ -82,12 +79,13 @@
|
|||
}, {
|
||||
"url": "https://github.com/reply2future/xExtension-NewsAssistant",
|
||||
"type": "git"
|
||||
},
|
||||
{
|
||||
}, {
|
||||
"url": "https://github.com/giventofly/freshrss-comicsinfeed",
|
||||
"type": "git"
|
||||
},
|
||||
{
|
||||
}, {
|
||||
"url": "https://code.sitosis.com/rudism/freshrss-kagi-summarizer",
|
||||
"type": "git"
|
||||
}, {
|
||||
"url": "https://github.com/kalvn/freshrss-mark-previous-as-read",
|
||||
"type": "git"
|
||||
}]
|
||||
|
|
|
|||
|
|
@ -1,7 +0,0 @@
|
|||
# List of files, which are not yet passing PHPStan level 9 https://phpstan.org/user-guide/rule-levels
|
||||
# Used for automated tests to avoid regressions in files already passing that level.
|
||||
# Can be regenerated with something like:
|
||||
# find . -type d -name 'vendor' -prune -o -name '*.php' -exec sh -c 'vendor/bin/phpstan analyse --level 9 --memory-limit 512M {} >/dev/null 2>/dev/null || echo {}' \;
|
||||
|
||||
./xExtension-ImageProxy/configure.phtml
|
||||
./xExtension-ImageProxy/extension.php
|
||||
|
|
@ -2,8 +2,9 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class ColorfulListExtension extends Minz_Extension
|
||||
final class ColorfulListExtension extends Minz_Extension
|
||||
{
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
Minz_View::appendScript($this->getFileUrl('script.js', 'js'));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Colorful List",
|
||||
"author": "Claud Xiao",
|
||||
"description": "Colorful Entry Title based on RSS source",
|
||||
"version": 0.3,
|
||||
"version": "0.3.1",
|
||||
"entrypoint": "ColorfulList",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ To use it, upload this directory in your `./extensions` directory and enable it
|
|||
|
||||
## Changelog
|
||||
|
||||
- 0.5.2 Turkish language support added
|
||||
- 0.2 added file permission check, added german translation, removed un-editable file static/style.css
|
||||
- 0.1 initial version
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
</div>
|
||||
|
||||
<div class="form-group form-actions">
|
||||
<?php if (!empty($this->permission_problem)) { ?>
|
||||
<?php if ($this->permission_problem !== '') { ?>
|
||||
<p class="alert alert-error"><?= _t('ext.custom_css.permission_problem', $this->permission_problem) ?></p>
|
||||
<?php } else { ?>
|
||||
<div class="group-controls">
|
||||
|
|
|
|||
|
|
@ -2,10 +2,11 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class CustomCSSExtension extends Minz_Extension {
|
||||
final class CustomCSSExtension extends Minz_Extension {
|
||||
public string $css_rules;
|
||||
public string $permission_problem = '';
|
||||
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
|
|
@ -18,6 +19,7 @@ class CustomCSSExtension extends Minz_Extension {
|
|||
}
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
public function handleConfigureAction(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
|
|
|
|||
8
xExtension-CustomCSS/i18n/tr/ext.php
Normal file
8
xExtension-CustomCSS/i18n/tr/ext.php
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'custom_css' => array(
|
||||
'write_css' => 'Ek CSS kuralları',
|
||||
'permission_problem' => 'CSS dosyanız yazılabilir değil, lütfen %s için dosya izinlerini değiştirin',
|
||||
),
|
||||
);
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Custom CSS",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Give possibility to overwrite the CSS with a user-specific rules.",
|
||||
"version": "0.4",
|
||||
"version": "0.5.2",
|
||||
"entrypoint": "CustomCSS",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,5 +6,6 @@ To use it, upload this directory in your `./extensions` directory and enable it
|
|||
|
||||
## Changelog
|
||||
|
||||
- 0.5.2 Turkish language support added
|
||||
- 0.2 added file permission check and german translation
|
||||
- 0.1 initial version
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
</div>
|
||||
|
||||
<div class="form-group form-actions">
|
||||
<?php if (isset($this->permission_problem)) { ?>
|
||||
<?php if ($this->permission_problem !== '') { ?>
|
||||
<p class="alert alert-error"><?= _t('ext.custom_js.permission_problem', $this->permission_problem) ?></p>
|
||||
<?php } else { ?>
|
||||
<div class="group-controls">
|
||||
|
|
|
|||
|
|
@ -2,10 +2,11 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class CustomJSExtension extends Minz_Extension {
|
||||
final class CustomJSExtension extends Minz_Extension {
|
||||
public string $js_rules;
|
||||
public string $permission_problem = '';
|
||||
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
|
|
@ -18,6 +19,7 @@ class CustomJSExtension extends Minz_Extension {
|
|||
}
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
public function handleConfigureAction(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
|
|
|
|||
8
xExtension-CustomJS/i18n/tr/ext.php
Normal file
8
xExtension-CustomJS/i18n/tr/ext.php
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'custom_js' => array(
|
||||
'write_js' => 'EK JS',
|
||||
'permission_problem' => 'JS dosyanız yazılabilir değil, lütfen %s için dosya izinlerini değiştirin',
|
||||
),
|
||||
);
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Custom JS",
|
||||
"author": "Frans de Jonge",
|
||||
"description": "Apply custom JS.",
|
||||
"version": "0.4",
|
||||
"version": "0.5.2",
|
||||
"entrypoint": "CustomJS",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,6 +4,10 @@ This FreshRSS extension allows you to get rid of insecure content warnings or di
|
|||
|
||||
To use it, upload this entire directory to the FreshRSS `./extensions` directory on your server and enable it on the extension panel in FreshRSS.
|
||||
|
||||
## Changelog
|
||||
|
||||
* 0.7.3 Turkish language support added
|
||||
|
||||
## Configuration settings
|
||||
|
||||
* `proxy_url` (default: `https://images.example.com/?url=`): the URL that is prependended to the original image URL
|
||||
|
|
@ -21,11 +25,11 @@ To use it, upload this entire directory to the FreshRSS `./extensions` directory
|
|||
|
||||
## Proxy Settings
|
||||
|
||||
By default this extension will use the [images.weserv.nl](https://images.weserv.nl) image caching and resizing proxy, but instead you can supply your own proxy URL in the settings. An example URL would look like ``https://images.example.com/?url=``.
|
||||
By default this extension will use the [wsrv.nl](https://wsrv.nl) image caching and resizing proxy, but instead you can supply your own proxy URL in the settings. An example URL would look like ``https://images.example.com/?url=``.
|
||||
|
||||
By ticking the `scheme_https` checkbox, you can also force the use of the proxy, even for images coming through an encrypted channel. This makes the server that hosts your FreshRSS instance the only point of entry for images, preventing your client from connecting directly to the RSS sources to recover them (which could be a privacy concern in extreme cases).
|
||||
|
||||
The source code for the images.weserv.nl proxy can be found at [github.com/andrieslouw/imagesweserv](https://github.com/andrieslouw/imagesweserv), but of course other methods are available. For example, in Apache you could [use `mod_rewrite` to set up a simple proxy](#apache-configuration) and similar methods are available in nginx and lighttpd. Alternatively you could use a simple PHP script, [along these lines](https://github.com/Alexxz/Simple-php-proxy-script). Keep in mind that too simple a proxy could introduce security risks, which is why the default proxy processes the images.
|
||||
The source code for the wsrv.nl proxy can be found at [github.com/weserv/images](https://github.com/weserv/images), but of course other methods are available. For example, in Apache you could [use `mod_rewrite` to set up a simple proxy](#apache-configuration) and similar methods are available in nginx and lighttpd. Alternatively you could use a simple PHP script, [along these lines](https://github.com/Alexxz/Simple-php-proxy-script). Keep in mind that too simple a proxy could introduce security risks, which is why the default proxy processes the images.
|
||||
|
||||
### Apache configuration
|
||||
|
||||
|
|
|
|||
|
|
@ -7,26 +7,26 @@
|
|||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_url"><?= _t('ext.imageproxy.proxy_url') ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="url" name="image_proxy_url" id="image_proxy_url" value="<?= FreshRSS_Context::$user_conf->image_proxy_url ?>">
|
||||
<input type="url" name="image_proxy_url" id="image_proxy_url" value="<?= FreshRSS_Context::userConf()->image_proxy_url ?>">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_scheme_http"><?= _t('ext.imageproxy.scheme_http') ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="checkbox" name="image_proxy_scheme_http" id="image_proxy_scheme_http" value="1" <?= FreshRSS_Context::$user_conf->image_proxy_scheme_http ? 'checked' : '' ?>>
|
||||
<input type="checkbox" name="image_proxy_scheme_http" id="image_proxy_scheme_http" value="1" <?= FreshRSS_Context::userConf()->image_proxy_scheme_http ? 'checked' : '' ?>>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_scheme_https"><?= _t('ext.imageproxy.scheme_https'); ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="checkbox" name="image_proxy_scheme_https" id="image_proxy_scheme_https" value="1" <?= FreshRSS_Context::$user_conf->image_proxy_scheme_https ? 'checked' : '' ?>>
|
||||
<input type="checkbox" name="image_proxy_scheme_https" id="image_proxy_scheme_https" value="1" <?= FreshRSS_Context::userConf()->image_proxy_scheme_https ? 'checked' : '' ?>>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_scheme_default"><?= _t('ext.imageproxy.scheme_default'); ?></label>
|
||||
<div class="group-controls">
|
||||
<select name="image_proxy_scheme_default" id="image_proxy_scheme_default">
|
||||
<option value="<?= htmlentities(FreshRSS_Context::$user_conf->image_proxy_scheme_default ?? '') ?>" selected="selected"><?= htmlentities(FreshRSS_Context::$user_conf->image_proxy_scheme_default ?? '') ?></option>
|
||||
<option value="<?= htmlentities(FreshRSS_Context::userConf()->image_proxy_scheme_default ?? '') ?>" selected="selected"><?= htmlentities(FreshRSS_Context::userConf()->image_proxy_scheme_default ?? '') ?></option>
|
||||
<option value="-">-</option>
|
||||
<option value="auto">auto</option>
|
||||
<option value="http">http</option>
|
||||
|
|
@ -37,13 +37,13 @@
|
|||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_scheme_include"><?= _t('ext.imageproxy.scheme_include'); ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="checkbox" name="image_proxy_scheme_include" id="image_proxy_scheme_include" value="1" <?= FreshRSS_Context::$user_conf->image_proxy_scheme_include ? 'checked' : '' ?>>
|
||||
<input type="checkbox" name="image_proxy_scheme_include" id="image_proxy_scheme_include" value="1" <?= FreshRSS_Context::userConf()->image_proxy_scheme_include ? 'checked' : '' ?>>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="group-name" for="image_proxy_url_encode"><?= _t('ext.imageproxy.url_encode'); ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="checkbox" name="image_proxy_url_encode" id="image_proxy_url_encode" value="1" <?= FreshRSS_Context::$user_conf->image_proxy_url_encode ? 'checked' : '' ?>>
|
||||
<input type="checkbox" name="image_proxy_url_encode" id="image_proxy_url_encode" value="1" <?= FreshRSS_Context::userConf()->image_proxy_url_encode ? 'checked' : '' ?>>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -4,68 +4,67 @@ declare(strict_types=1);
|
|||
|
||||
final class ImageProxyExtension extends Minz_Extension {
|
||||
// Defaults
|
||||
private const PROXY_URL = 'https://images.weserv.nl/?url=';
|
||||
private const PROXY_URL = 'https://wsrv.nl/?url=';
|
||||
private const SCHEME_HTTP = '1';
|
||||
private const SCHEME_HTTPS = '';
|
||||
private const SCHEME_DEFAULT = 'auto';
|
||||
private const SCHEME_INCLUDE = '';
|
||||
private const URL_ENCODE = '1';
|
||||
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
if (FreshRSS_Context::$system_conf === null) {
|
||||
if (!FreshRSS_Context::hasSystemConf()) {
|
||||
throw new FreshRSS_Context_Exception('System configuration not initialised!');
|
||||
}
|
||||
$this->registerHook(
|
||||
'entry_before_display',
|
||||
array('ImageProxyExtension', 'setImageProxyHook')
|
||||
);
|
||||
$this->registerHook('entry_before_display', [self::class, 'setImageProxyHook']);
|
||||
// Defaults
|
||||
$save = false;
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_url)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_url = self::PROXY_URL;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_url)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_url = self::PROXY_URL;
|
||||
$save = true;
|
||||
}
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_scheme_http)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_http = self::SCHEME_HTTP;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_scheme_http)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_http = self::SCHEME_HTTP;
|
||||
$save = true;
|
||||
}
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_scheme_https)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_https = self::SCHEME_HTTPS;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_scheme_https)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_https = self::SCHEME_HTTPS;
|
||||
// Legacy
|
||||
if (!is_null(FreshRSS_Context::$user_conf->image_proxy_force)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_https = FreshRSS_Context::$user_conf->image_proxy_force;
|
||||
FreshRSS_Context::$user_conf->image_proxy_force = null; // Minz -> unset
|
||||
if (!is_null(FreshRSS_Context::userConf()->image_proxy_force)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_https = FreshRSS_Context::userConf()->image_proxy_force;
|
||||
FreshRSS_Context::userConf()->image_proxy_force = null; // Minz -> unset
|
||||
}
|
||||
$save = true;
|
||||
}
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_scheme_default)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_default = self::SCHEME_DEFAULT;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_scheme_default)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_default = self::SCHEME_DEFAULT;
|
||||
$save = true;
|
||||
}
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_scheme_include)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_include = self::SCHEME_INCLUDE;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_scheme_include)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_include = self::SCHEME_INCLUDE;
|
||||
$save = true;
|
||||
}
|
||||
if (is_null(FreshRSS_Context::$user_conf->image_proxy_url_encode)) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_url_encode = self::URL_ENCODE;
|
||||
if (is_null(FreshRSS_Context::userConf()->image_proxy_url_encode)) {
|
||||
FreshRSS_Context::userConf()->image_proxy_url_encode = self::URL_ENCODE;
|
||||
$save = true;
|
||||
}
|
||||
if ($save) {
|
||||
FreshRSS_Context::$user_conf->save();
|
||||
FreshRSS_Context::userConf()->save();
|
||||
}
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
public function handleConfigureAction(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
if (Minz_Request::isPost()) {
|
||||
FreshRSS_Context::$user_conf->image_proxy_url = Minz_Request::paramString('image_proxy_url', true) ?: self::PROXY_URL;
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_http = Minz_Request::paramString('image_proxy_scheme_http');
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_https = Minz_Request::paramString('image_proxy_scheme_https');
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_default = Minz_Request::paramString('image_proxy_scheme_default') ?: self::SCHEME_DEFAULT;
|
||||
FreshRSS_Context::$user_conf->image_proxy_scheme_include = Minz_Request::paramString('image_proxy_scheme_include');
|
||||
FreshRSS_Context::$user_conf->image_proxy_url_encode = Minz_Request::paramString('image_proxy_url_encode');
|
||||
FreshRSS_Context::$user_conf->save();
|
||||
FreshRSS_Context::userConf()->image_proxy_url = Minz_Request::paramString('image_proxy_url', true) ?: self::PROXY_URL;
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_http = Minz_Request::paramString('image_proxy_scheme_http');
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_https = Minz_Request::paramString('image_proxy_scheme_https');
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_default = Minz_Request::paramString('image_proxy_scheme_default') ?: self::SCHEME_DEFAULT;
|
||||
FreshRSS_Context::userConf()->image_proxy_scheme_include = Minz_Request::paramString('image_proxy_scheme_include');
|
||||
FreshRSS_Context::userConf()->image_proxy_url_encode = Minz_Request::paramString('image_proxy_url_encode');
|
||||
FreshRSS_Context::userConf()->save();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -73,27 +72,27 @@ final class ImageProxyExtension extends Minz_Extension {
|
|||
$parsed_url = parse_url($url);
|
||||
$scheme = isset($parsed_url['scheme']) ? $parsed_url['scheme'] : null;
|
||||
if ($scheme === 'http') {
|
||||
if (!FreshRSS_Context::$user_conf->image_proxy_scheme_http) {
|
||||
if (!FreshRSS_Context::userConf()->image_proxy_scheme_http) {
|
||||
return $url;
|
||||
}
|
||||
if (!FreshRSS_Context::$user_conf->image_proxy_scheme_include) {
|
||||
if (!FreshRSS_Context::userConf()->image_proxy_scheme_include) {
|
||||
$url = substr($url, 7); // http://
|
||||
}
|
||||
} elseif ($scheme === 'https') {
|
||||
if (!FreshRSS_Context::$user_conf->image_proxy_scheme_https) {
|
||||
if (!FreshRSS_Context::userConf()->image_proxy_scheme_https) {
|
||||
return $url;
|
||||
}
|
||||
if (!FreshRSS_Context::$user_conf->image_proxy_scheme_include) {
|
||||
if (!FreshRSS_Context::userConf()->image_proxy_scheme_include) {
|
||||
$url = substr($url, 8); // https://
|
||||
}
|
||||
} elseif (empty($scheme)) {
|
||||
if (FreshRSS_Context::$user_conf->image_proxy_scheme_default === 'auto') {
|
||||
if (FreshRSS_Context::$user_conf->image_proxy_scheme_include) {
|
||||
if (FreshRSS_Context::userConf()->image_proxy_scheme_default === 'auto') {
|
||||
if (FreshRSS_Context::userConf()->image_proxy_scheme_include) {
|
||||
$url = ((!empty($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) !== 'off') ? 'https:' : 'http:') . $url;
|
||||
}
|
||||
} elseif (substr(FreshRSS_Context::$user_conf->image_proxy_scheme_default, 0, 4) === 'http') {
|
||||
if (FreshRSS_Context::$user_conf->image_proxy_scheme_include) {
|
||||
$url = FreshRSS_Context::$user_conf->image_proxy_scheme_default . ':' . $url;
|
||||
} elseif (substr(FreshRSS_Context::userConf()->image_proxy_scheme_default, 0, 4) === 'http') {
|
||||
if (FreshRSS_Context::userConf()->image_proxy_scheme_include) {
|
||||
$url = FreshRSS_Context::userConf()->image_proxy_scheme_default . ':' . $url;
|
||||
}
|
||||
} else { // do not proxy unschemed ("//path/...") URLs
|
||||
return $url;
|
||||
|
|
@ -101,19 +100,17 @@ final class ImageProxyExtension extends Minz_Extension {
|
|||
} else { // unknown/unsupported (non-http) scheme
|
||||
return $url;
|
||||
}
|
||||
if (FreshRSS_Context::$user_conf->image_proxy_url_encode) {
|
||||
if (FreshRSS_Context::userConf()->image_proxy_url_encode) {
|
||||
$url = rawurlencode($url);
|
||||
}
|
||||
return FreshRSS_Context::$user_conf->image_proxy_url . $url;
|
||||
return FreshRSS_Context::userConf()->image_proxy_url . $url;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<string> $matches
|
||||
* @return array<string>
|
||||
*/
|
||||
public static function getSrcSetUris(array $matches): array {
|
||||
$result = str_replace($matches[1], self::getProxyImageUri($matches[1]), $matches[0]);
|
||||
return is_array($result) ? $result : [$result];
|
||||
public static function getSrcSetUris(array $matches): string {
|
||||
return str_replace($matches[1], self::getProxyImageUri($matches[1]), $matches[0]);
|
||||
}
|
||||
|
||||
public static function swapUris(string $content): string {
|
||||
|
|
@ -131,12 +128,20 @@ final class ImageProxyExtension extends Minz_Extension {
|
|||
$img->setAttribute('src', $newSrc);
|
||||
}
|
||||
if ($img->hasAttribute('srcset')) {
|
||||
$newSrcSet = preg_replace_callback('/(?:([^\s,]+)(\s*(?:\s+\d+[wx])(?:,\s*)?))/', fn($matches) => self::getSrcSetUris($matches), $img->getAttribute('srcset'));
|
||||
$img->setAttribute('srcset', $newSrcSet);
|
||||
$newSrcSet = preg_replace_callback('/(?:([^\s,]+)(\s*(?:\s+\d+[wx])(?:,\s*)?))/', fn (array $matches) => self::getSrcSetUris($matches), $img->getAttribute('srcset'));
|
||||
if ($newSrcSet != null) {
|
||||
$img->setAttribute('srcset', $newSrcSet);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $doc->saveHTML() ?: '';
|
||||
$body = $doc->getElementsByTagName('body')->item(0);
|
||||
|
||||
$output = $doc->saveHTML($body);
|
||||
|
||||
$output = preg_replace('/^<body>|<\/body>$/', '', $output);
|
||||
|
||||
return $output;
|
||||
}
|
||||
|
||||
public static function setImageProxyHook(FreshRSS_Entry $entry): FreshRSS_Entry {
|
||||
|
|
|
|||
12
xExtension-ImageProxy/i18n/de/ext.php
Normal file
12
xExtension-ImageProxy/i18n/de/ext.php
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'imageproxy' => array(
|
||||
'proxy_url' => 'Proxy-URL',
|
||||
'scheme_http' => 'HTTP-Proxy',
|
||||
'scheme_https' => 'HTTPS-Proxy',
|
||||
'scheme_default' => 'Proxy unspezifiziert',
|
||||
'scheme_include' => 'http*:// in die URL einfügen',
|
||||
'url_encode' => 'URL-Prozentkodierung'
|
||||
),
|
||||
);
|
||||
|
|
@ -7,8 +7,6 @@ return array(
|
|||
'scheme_https' => 'Proxy HTTPS',
|
||||
'scheme_default' => 'Proxy unspecified',
|
||||
'scheme_include' => 'Include http*:// in URL',
|
||||
'url_encode' => 'Encode the URL',
|
||||
'true' => 'On',
|
||||
'false' => 'Off',
|
||||
'url_encode' => 'Encode the URL'
|
||||
),
|
||||
);
|
||||
|
|
|
|||
|
|
@ -7,8 +7,6 @@ return array(
|
|||
'scheme_https' => 'Proxy HTTPS',
|
||||
'scheme_default' => 'Proxy indéterminé',
|
||||
'scheme_include' => 'Inclure http*:// dans l\'URL',
|
||||
'url_encode' => 'Encoder l\'URL',
|
||||
'true' => 'Oui',
|
||||
'false' => 'Non',
|
||||
'url_encode' => 'Encoder l\'URL'
|
||||
),
|
||||
);
|
||||
|
|
|
|||
12
xExtension-ImageProxy/i18n/tr/ext.php
Normal file
12
xExtension-ImageProxy/i18n/tr/ext.php
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'imageproxy' => array(
|
||||
'proxy_url' => 'Vekil Bağlantısı',
|
||||
'scheme_http' => 'HTTP Vekil Sunucusu',
|
||||
'scheme_https' => 'HTTPS Vekil Sunucusu',
|
||||
'scheme_default' => 'Belirtilmemiş Vekil Sunucusu',
|
||||
'scheme_include' => 'Bağlantıya http*:// ekle',
|
||||
'url_encode' => 'Bağlantıyı kodla',
|
||||
),
|
||||
);
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Image Proxy",
|
||||
"author": "Frans de Jonge",
|
||||
"description": "No insecure content warnings or disappearing images.",
|
||||
"version": "0.6",
|
||||
"version": "0.7.3",
|
||||
"entrypoint": "ImageProxy",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
declare(strict_types=1);
|
||||
|
||||
class FreshExtension_quickCollapse_Controller extends Minz_ActionController {
|
||||
final class FreshExtension_quickCollapse_Controller extends Minz_ActionController {
|
||||
|
||||
/** @var QuickCollapse\View */
|
||||
protected $view;
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ declare(strict_types=1);
|
|||
|
||||
namespace QuickCollapse;
|
||||
|
||||
class View extends \Minz_View {
|
||||
final class View extends \Minz_View {
|
||||
|
||||
public string $icon_url_in = '';
|
||||
public string $icon_url_out = '';
|
||||
|
|
|
|||
|
|
@ -6,4 +6,5 @@ To install this extension, you must upload this directory in your `./extensions`
|
|||
|
||||
## Changelog
|
||||
|
||||
- 0.2.2 Turkish language support added
|
||||
- 0.1 initial version
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class QuickCollapseExtension extends Minz_Extension {
|
||||
final class QuickCollapseExtension extends Minz_Extension {
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
$this->registerTranslates();
|
||||
$this->registerViews();
|
||||
|
|
|
|||
7
xExtension-QuickCollapse/i18n/tr/gen.php
Normal file
7
xExtension-QuickCollapse/i18n/tr/gen.php
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'js' => [
|
||||
'toggle_collapse' => 'Daraltmayı değiştir',
|
||||
],
|
||||
];
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Quick Collapse",
|
||||
"author": "romibi and Marien Fressinaud",
|
||||
"description": "Quickly change from folded to unfolded articles",
|
||||
"version": "0.2",
|
||||
"version": "0.2.2",
|
||||
"entrypoint": "QuickCollapse",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class ReadingTimeExtension extends Minz_Extension {
|
||||
final class ReadingTimeExtension extends Minz_Extension {
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
Minz_View::appendScript($this->getFileUrl('readingtime.js', 'js'));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "ReadingTime",
|
||||
"author": "Lapineige",
|
||||
"description": "Add a reading time estimation next to each article",
|
||||
"version": "1.5",
|
||||
"version": "1.5.1",
|
||||
"entrypoint": "ReadingTime",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class FreshExtension_shareByEmail_Controller extends Minz_ActionController {
|
||||
final class FreshExtension_shareByEmail_Controller extends Minz_ActionController {
|
||||
public ?Minz_Extension $extension;
|
||||
|
||||
/** @var ShareByEmail\mailers\View */
|
||||
|
|
@ -12,6 +12,7 @@ class FreshExtension_shareByEmail_Controller extends Minz_ActionController {
|
|||
parent::__construct(ShareByEmail\mailers\View::class);
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
$this->extension = Minz_ExtensionManager::findExtension('Share By Email');
|
||||
}
|
||||
|
|
@ -34,13 +35,13 @@ class FreshExtension_shareByEmail_Controller extends Minz_ActionController {
|
|||
}
|
||||
$this->view->entry = $entry;
|
||||
|
||||
if (FreshRSS_Context::$system_conf === null) {
|
||||
if (!FreshRSS_Context::hasSystemConf()) {
|
||||
throw new FreshRSS_Context_Exception('System configuration not initialised!');
|
||||
}
|
||||
|
||||
$username = Minz_Session::paramString('currentUser') ?: '_';
|
||||
$service_name = FreshRSS_Context::$system_conf->title;
|
||||
$service_url = FreshRSS_Context::$system_conf->base_url;
|
||||
$service_name = FreshRSS_Context::systemConf()->title;
|
||||
$service_url = FreshRSS_Context::systemConf()->base_url;
|
||||
|
||||
Minz_View::prependTitle(_t('shareByEmail.share.title') . ' · ');
|
||||
if ($this->extension !== null) {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@ declare(strict_types=1);
|
|||
|
||||
namespace ShareByEmail\mailers;
|
||||
|
||||
class View extends \Minz_View {
|
||||
final class View extends \Minz_View {
|
||||
|
||||
public ?\FreshRSS_Entry $entry = null;
|
||||
public string $content = '';
|
||||
|
|
|
|||
|
|
@ -8,4 +8,5 @@ You’ll have to configure the mailing system in FreshRSS. [See the documentatio
|
|||
|
||||
## Changelog
|
||||
|
||||
- 0.2.3 Turkish language support added
|
||||
- 0.1 initial version
|
||||
|
|
|
|||
|
|
@ -2,8 +2,9 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class ShareByEmailExtension extends Minz_Extension {
|
||||
final class ShareByEmailExtension extends Minz_Extension {
|
||||
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
$this->registerTranslates();
|
||||
|
||||
|
|
|
|||
22
xExtension-ShareByEmail/i18n/de/shareByEmail.php
Executable file
22
xExtension-ShareByEmail/i18n/de/shareByEmail.php
Executable file
|
|
@ -0,0 +1,22 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'share' => [
|
||||
'feedback' => [
|
||||
'failed' => 'Die Mail konnte nicht gesendet werden. Bitte kontaktiere deinen Administrator.',
|
||||
'fields_required' => 'Alle Felder sind Pflichtfelder.',
|
||||
'sent' => 'Die Mail wurde gesendet.',
|
||||
],
|
||||
'form' => [
|
||||
'cancel' => 'Abbrechen',
|
||||
'content' => 'Inhalt',
|
||||
'content_default' => "Hi,\n\nIch glaube dieser Artikel ist interessant für dich!\n\n%s – %s\n\n---\n\nDiese Mail wurde von %s gesendet über %s ( %s )",
|
||||
'send' => 'Senden',
|
||||
'subject' => 'Betreff',
|
||||
'subject_default' => 'Interessanter Artikel für dich!',
|
||||
'to' => 'An',
|
||||
],
|
||||
'intro' => 'Diesen Artikel per Mail versenden: “<strong>%s</strong>”',
|
||||
'title' => 'Einen Artikel per Mail teilen.',
|
||||
],
|
||||
];
|
||||
22
xExtension-ShareByEmail/i18n/tr/shareByEmail.php
Normal file
22
xExtension-ShareByEmail/i18n/tr/shareByEmail.php
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
'share' => [
|
||||
'feedback' => [
|
||||
'failed' => 'E-posta gönderilemiyor, lütfen yöneticinizle iletişime geçin.',
|
||||
'fields_required' => 'Tüm alanların doldurulması zorunludur.',
|
||||
'sent' => 'E-posta gönderildi.',
|
||||
],
|
||||
'form' => [
|
||||
'cancel' => 'İptal',
|
||||
'content' => 'İçerik',
|
||||
'content_default' => "Merhaba,\n\nBu makaleyi oldukça ilginç bulabilirsiniz!\n\n%s – %s\n\n---\n\nBu e-posta %s tarafından %s ( %s ) aracılığıyla gönderildi",
|
||||
'send' => 'Gönder',
|
||||
'subject' => 'Konu',
|
||||
'subject_default' => 'Bu makaleyi ilginç buldum!',
|
||||
'to' => 'Kime',
|
||||
],
|
||||
'intro' => 'Bu makaleyi e-posta yoluyla paylaşmak üzeresiniz: “<strong>%s</strong>”',
|
||||
'title' => 'Bir makaleyi e-posta ile paylaşın',
|
||||
],
|
||||
];
|
||||
|
|
@ -18,8 +18,8 @@ final class Share extends \Minz_Mailer {
|
|||
|
||||
$this->view->content = $content;
|
||||
|
||||
if (isset(\FreshRSS_Context::$system_conf)) {
|
||||
$subject_prefix = '[' . \FreshRSS_Context::$system_conf->title . ']';
|
||||
if (\FreshRSS_Context::hasSystemConf()) {
|
||||
$subject_prefix = '[' . \FreshRSS_Context::systemConf()->title . ']';
|
||||
} else {
|
||||
$subject_prefix = '';
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Share By Email",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Improve the sharing by email system.",
|
||||
"version": "0.2",
|
||||
"version": "0.2.3",
|
||||
"entrypoint": "ShareByEmail",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class StickyFeedsExtension extends Minz_Extension {
|
||||
final class StickyFeedsExtension extends Minz_Extension {
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
Minz_View::appendStyle($this->getFileUrl('style.css', 'css'));
|
||||
Minz_View::appendScript($this->getFileUrl('script.js', 'js'));
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Sticky Feeds",
|
||||
"author": "Marien Fressinaud",
|
||||
"description": "Set the feed aside in the main stream following the window scroll.",
|
||||
"version": "0.2",
|
||||
"version": "0.2.1",
|
||||
"entrypoint": "StickyFeeds",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,8 +5,9 @@ this extension applies a line-wrap to long article titles.
|
|||
|
||||
To use it, upload this directory in your `./extensions` directory and enable it on the extension panel in FreshRSS. If you need more control, use the xExtension-CustomCSS instead to specify your own css rules.
|
||||
|
||||
The css code used to wrap long titles was originally [proposed](https://github.com/FreshRSS/FreshRSS/issues/2344) by ₣rans de Jonge.
|
||||
The CSS code (since 0.3 legacy) used to wrap long titles was originally [proposed](https://github.com/FreshRSS/FreshRSS/issues/2344) by ₣rans de Jonge.
|
||||
|
||||
## Changelog
|
||||
|
||||
- 0.3 ready for FreshRSS 1.23.2-dev (April 2023) / upcoming 1.24.0
|
||||
- 0.1 initial version
|
||||
|
|
|
|||
|
|
@ -2,8 +2,14 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class TitleWrapExtension extends Minz_Extension {
|
||||
final class TitleWrapExtension extends Minz_Extension {
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
Minz_View::appendStyle($this->getFileUrl('title_wrap.css', 'css'));
|
||||
if (version_compare(FRESHRSS_VERSION, "1.23.1") > 0) {
|
||||
Minz_View::appendStyle($this->getFileUrl('title_wrap.css', 'css'));
|
||||
} else {
|
||||
// legacy <1.24.0 (= 1.23.2-dev)
|
||||
Minz_View::appendStyle($this->getFileUrl('title_wrap_legacy.css', 'css'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "Title-Wrap",
|
||||
"author": "₣rans de Jonge, Joris Kinable",
|
||||
"description": "Applies a line-wrap to long article titles, as opposed to truncating the title when it overflows its display area.",
|
||||
"version": "0.2",
|
||||
"version": "0.3.0",
|
||||
"entrypoint": "TitleWrap",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,26 +1,33 @@
|
|||
.horizontal-list {
|
||||
display: flex;
|
||||
.flux .flux_header .item {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.horizontal-list.bottom {
|
||||
display: table;
|
||||
}
|
||||
|
||||
.flux .item {
|
||||
flex-shrink: 0;
|
||||
line-height: normal;
|
||||
padding: .3em 0;
|
||||
}
|
||||
|
||||
.flux .item > a {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .item.title {
|
||||
.flux .flux_header .item .title {
|
||||
position: relative;
|
||||
max-width: inherit;
|
||||
}
|
||||
|
||||
.flux_header .title {
|
||||
flex: auto;
|
||||
.flux .flux_header .item.website .websiteName,
|
||||
.flux .flux_header .item .title {
|
||||
white-space: wrap;
|
||||
}
|
||||
|
||||
.flux .flux_header .item .summary {
|
||||
margin-top: -0.5rem;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item .date {
|
||||
opacity: inherit;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item .title:has(~ .date) {
|
||||
padding-right: 155px;
|
||||
z-index: auto;
|
||||
}
|
||||
|
||||
@media (max-width: 840px) {
|
||||
.flux:not(.current) .flux_header .item.titleAuthorSummaryDate .title:has(~ .date),
|
||||
.flux:not(.current):hover .flux_header .item.titleAuthorSummaryDate .title:has(~ .date) {
|
||||
padding-right: 0;
|
||||
padding-left: 0;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,26 +1,33 @@
|
|||
.horizontal-list {
|
||||
display: flex;
|
||||
.flux .flux_header .item {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.horizontal-list.bottom {
|
||||
display: table;
|
||||
}
|
||||
|
||||
.flux .item {
|
||||
flex-shrink: 0;
|
||||
line-height: normal;
|
||||
padding: .3em 0;
|
||||
}
|
||||
|
||||
.flux .item > a {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .item.title {
|
||||
.flux .flux_header .item .title {
|
||||
position: relative;
|
||||
max-width: inherit;
|
||||
}
|
||||
|
||||
.flux_header .title {
|
||||
flex: auto;
|
||||
.flux .flux_header .item.website .websiteName,
|
||||
.flux .flux_header .item .title {
|
||||
white-space: wrap;
|
||||
}
|
||||
|
||||
.flux .flux_header .item .summary {
|
||||
margin-top: -0.5rem;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item .date {
|
||||
opacity: inherit;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item .title:has(~ .date) {
|
||||
padding-left: 155px;
|
||||
z-index: auto;
|
||||
}
|
||||
|
||||
@media (max-width: 840px) {
|
||||
.flux:not(.current) .flux_header .item.titleAuthorSummaryDate .title:has(~ .date),
|
||||
.flux:not(.current):hover .flux_header .item.titleAuthorSummaryDate .title:has(~ .date) {
|
||||
padding-left: 0;
|
||||
padding-right: 0;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
25
xExtension-TitleWrap/static/title_wrap_legacy.css
Normal file
25
xExtension-TitleWrap/static/title_wrap_legacy.css
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
.horizontal-list {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.horizontal-list.bottom {
|
||||
display: table;
|
||||
}
|
||||
|
||||
.flux .flux_header .item {
|
||||
flex-shrink: 0;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.flux .flux_header .item > a {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item.title {
|
||||
position: relative;
|
||||
max-width: inherit;
|
||||
}
|
||||
|
||||
.flux .flux_header .title {
|
||||
flex: auto;
|
||||
}
|
||||
25
xExtension-TitleWrap/static/title_wrap_legacy.rtl.css
Normal file
25
xExtension-TitleWrap/static/title_wrap_legacy.rtl.css
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
.horizontal-list {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.horizontal-list.bottom {
|
||||
display: table;
|
||||
}
|
||||
|
||||
.flux .flux_header .item {
|
||||
flex-shrink: 0;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.flux .flux_header .item > a {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
.flux:not(.current):hover .flux_header .item.title {
|
||||
position: relative;
|
||||
max-width: inherit;
|
||||
}
|
||||
|
||||
.flux .flux_header .title {
|
||||
flex: auto;
|
||||
}
|
||||
662
xExtension-WordHighlighter/LICENSE
Normal file
662
xExtension-WordHighlighter/LICENSE
Normal file
|
|
@ -0,0 +1,662 @@
|
|||
GNU AFFERO GENERAL PUBLIC LICENSE
|
||||
Version 3, 19 November 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU Affero General Public License is a free, copyleft license for
|
||||
software and other kinds of works, specifically designed to ensure
|
||||
cooperation with the community in the case of network server software.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
our General Public Licenses are intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
Developers that use our General Public Licenses protect your rights
|
||||
with two steps: (1) assert copyright on the software, and (2) offer
|
||||
you this License which gives you legal permission to copy, distribute
|
||||
and/or modify the software.
|
||||
|
||||
A secondary benefit of defending all users' freedom is that
|
||||
improvements made in alternate versions of the program, if they
|
||||
receive widespread use, become available for other developers to
|
||||
incorporate. Many developers of free software are heartened and
|
||||
encouraged by the resulting cooperation. However, in the case of
|
||||
software used on network servers, this result may fail to come about.
|
||||
The GNU General Public License permits making a modified version and
|
||||
letting the public access it on a server without ever releasing its
|
||||
source code to the public.
|
||||
|
||||
The GNU Affero General Public License is designed specifically to
|
||||
ensure that, in such cases, the modified source code becomes available
|
||||
to the community. It requires the operator of a network server to
|
||||
provide the source code of the modified version running there to the
|
||||
users of that server. Therefore, public use of a modified version, on
|
||||
a publicly accessible server, gives the public access to the source
|
||||
code of the modified version.
|
||||
|
||||
An older license, called the Affero General Public License and
|
||||
published by Affero, was designed to accomplish similar goals. This is
|
||||
a different license, not a version of the Affero GPL, but Affero has
|
||||
released a new version of the Affero GPL which permits relicensing under
|
||||
this license.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU Affero General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Remote Network Interaction; Use with the GNU General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, if you modify the
|
||||
Program, your modified version must prominently offer all users
|
||||
interacting with it remotely through a computer network (if your version
|
||||
supports such interaction) an opportunity to receive the Corresponding
|
||||
Source of your version by providing access to the Corresponding Source
|
||||
from a network server at no charge, through some standard or customary
|
||||
means of facilitating copying of software. This Corresponding Source
|
||||
shall include the Corresponding Source for any work covered by version 3
|
||||
of the GNU General Public License that is incorporated pursuant to the
|
||||
following paragraph.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the work with which it is combined will remain governed by version
|
||||
3 of the GNU General Public License.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU Affero General Public License from time to time. Such new versions
|
||||
will be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU Affero General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU Affero General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU Affero General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published
|
||||
by the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If your software can interact with users remotely through a computer
|
||||
network, you should also make sure that it provides a way for users to
|
||||
get its source. For example, if your program is a web application, its
|
||||
interface could display a "Source" link that leads users to an archive
|
||||
of the code. There are many ways you could offer source, and different
|
||||
solutions will be better for different programs; see section 13 for the
|
||||
specific requirements.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU AGPL, see
|
||||
<http://www.gnu.org/licenses/>.
|
||||
|
||||
30
xExtension-WordHighlighter/README.md
Normal file
30
xExtension-WordHighlighter/README.md
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
# WordHighlighter extension
|
||||
|
||||
A FreshRSS extension which give ability to highlight user-defined words.
|
||||
|
||||
## Usage
|
||||
|
||||
To use it, upload this directory in your `./extensions` directory and enable it on the extension panel in FreshRSS. You can add words to be highlighted by clicking on the manage button ⚙️.
|
||||
See also official docs at freshrss.github.io/FreshRSS/en/admins/15_extensions.html
|
||||
|
||||
## Preview
|
||||
|
||||
Light theme:
|
||||
|
||||

|
||||
|
||||
<!-- markdownlint-disable -->
|
||||
<details>
|
||||
<summary>click to see example screenshot in dark theme</summary>
|
||||
|
||||

|
||||
|
||||
</details>
|
||||
<!-- markdownlint-enable -->
|
||||
|
||||
## Changelog
|
||||
|
||||
- 0.0.2 use `json` for storing configuration, add more configuration options
|
||||
(enable_in_article, enable_logs, case_sensitive, separate_word_search)
|
||||
and refactored & simplified code
|
||||
- 0.0.1 initial version (as a proper FreshRSS extension)
|
||||
88
xExtension-WordHighlighter/configure.phtml
Normal file
88
xExtension-WordHighlighter/configure.phtml
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
<?php
|
||||
declare(strict_types=1);
|
||||
/** @var WordHighlighterExtension $this */
|
||||
?>
|
||||
<form action="<?= _url('extension', 'configure', 'e', urlencode($this->getName())) ?>" method="post">
|
||||
<input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" />
|
||||
|
||||
<div class="form-group">
|
||||
<label class="group-name" for="words_list">
|
||||
<?= _t('ext.word_highlighter.write_words') ?> <br />
|
||||
<?= _t('ext.word_highlighter.write_words_more') ?>
|
||||
</label>
|
||||
<div class="group-controls">
|
||||
<textarea name="words_list"
|
||||
id="words_list"><?= $this->word_highlighter_conf ?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="enable-in-article" class="group-name">
|
||||
<?= _t('ext.word_highlighter.enable_in_article') ?>
|
||||
</label>
|
||||
<div class="group-controls">
|
||||
<?php if ($this->enable_in_article == '') { ?>
|
||||
<input type="checkbox" name="enable-in-article" id="enable-in-article"></input>
|
||||
<?php } else { ?>
|
||||
<input type="checkbox" name="enable-in-article" id="enable-in-article" checked="true"></input>
|
||||
<?php } ?>
|
||||
<i><?= _t('ext.word_highlighter.enable_in_article_more') ?></i>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<details>
|
||||
<summary>Click to see more advanced options</summary>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="case_sensitive" class="group-name">
|
||||
<?= _t('ext.word_highlighter.case_sensitive') ?>
|
||||
</label>
|
||||
<div class="group-controls">
|
||||
<?php if ($this->case_sensitive == '') { ?>
|
||||
<input type="checkbox" name="case_sensitive" id="case_sensitive"></input>
|
||||
<?php } else { ?>
|
||||
<input type="checkbox" name="case_sensitive" id="case_sensitive" checked="true"></input>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="separate_word_search" class="group-name">
|
||||
<?= _t('ext.word_highlighter.separate_word_search') ?>
|
||||
</label>
|
||||
<div class="group-controls">
|
||||
<?php if ($this->separate_word_search == '') { ?>
|
||||
<input type="checkbox" name="separate_word_search" id="separate_word_search"></input>
|
||||
<?php } else { ?>
|
||||
<input type="checkbox" name="separate_word_search" id="separate_word_search" checked="true"></input>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="enable_logs" class="group-name">
|
||||
<?= _t('ext.word_highlighter.enable_logs') ?>
|
||||
</label>
|
||||
<div class="group-controls">
|
||||
<?php if ($this->enable_logs == '') { ?>
|
||||
<input type="checkbox" name="enable_logs" id="enable_logs"></input>
|
||||
<?php } else { ?>
|
||||
<input type="checkbox" name="enable_logs" id="enable_logs" checked="true"></input>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</details>
|
||||
|
||||
<div class="form-group form-actions">
|
||||
<?php if ($this->permission_problem !== '') { ?>
|
||||
<p class="alert alert-error"><?= _t('ext.word_highlighter.permission_problem', $this->permission_problem) ?></p>
|
||||
<?php } else { ?>
|
||||
<div class="group-controls">
|
||||
<button type="submit" class="btn btn-important"><?= _t('gen.action.submit') ?></button>
|
||||
<button type="reset" class="btn"><?= _t('gen.action.cancel') ?></button>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
102
xExtension-WordHighlighter/extension.php
Normal file
102
xExtension-WordHighlighter/extension.php
Normal file
|
|
@ -0,0 +1,102 @@
|
|||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
final class WordHighlighterExtension extends Minz_Extension
|
||||
{
|
||||
const JSON_ENCODE_CONF = JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE | JSON_THROW_ON_ERROR;
|
||||
|
||||
public string $word_highlighter_conf = 'test';
|
||||
public string $permission_problem = '';
|
||||
public bool $enable_in_article = false;
|
||||
public bool $enable_logs = false;
|
||||
public bool $case_sensitive = false;
|
||||
public bool $separate_word_search = false;
|
||||
|
||||
#[\Override]
|
||||
public function init(): void
|
||||
{
|
||||
$this->registerTranslates();
|
||||
|
||||
// register CSS for WordHighlighter:
|
||||
Minz_View::appendStyle($this->getFileUrl('style.css', 'css'));
|
||||
|
||||
Minz_View::appendScript($this->getFileUrl('mark.min.js', 'js'), false, false, false);
|
||||
|
||||
$current_user = Minz_Session::paramString('currentUser');
|
||||
|
||||
$staticPath = join_path($this->getPath(), 'static');
|
||||
$configFileJs = join_path($staticPath, ('config.' . $current_user . '.js'));
|
||||
|
||||
if (file_exists($configFileJs)) {
|
||||
Minz_View::appendScript($this->getFileUrl(('config.' . $current_user . '.js'), 'js'));
|
||||
}
|
||||
|
||||
Minz_View::appendScript($this->getFileUrl('word-highlighter.js', 'js'));
|
||||
}
|
||||
|
||||
#[\Override]
|
||||
public function handleConfigureAction(): void
|
||||
{
|
||||
$this->registerTranslates();
|
||||
|
||||
$current_user = Minz_Session::paramString('currentUser');
|
||||
$staticPath = join_path($this->getPath(), 'static');
|
||||
|
||||
$configFileJson = join_path($staticPath, ('config.' . $current_user . '.json'));
|
||||
|
||||
if (!file_exists($configFileJson) && !is_writable($staticPath)) {
|
||||
$tmpPath = explode(EXTENSIONS_PATH . '/', $staticPath);
|
||||
$this->permission_problem = $tmpPath[1] . '/';
|
||||
|
||||
} elseif (file_exists($configFileJson) && !is_writable($configFileJson)) {
|
||||
$tmpPath = explode(EXTENSIONS_PATH . '/', $configFileJson);
|
||||
$this->permission_problem = $tmpPath[1];
|
||||
|
||||
} elseif (Minz_Request::isPost()) {
|
||||
$configWordList = html_entity_decode(Minz_Request::paramString('words_list'));
|
||||
|
||||
$this->word_highlighter_conf = $configWordList;
|
||||
$this->enable_in_article = (bool) Minz_Request::paramString('enable-in-article');
|
||||
$this->enable_logs = (bool) Minz_Request::paramString('enable_logs');
|
||||
$this->case_sensitive = (bool) Minz_Request::paramString('case_sensitive');
|
||||
$this->separate_word_search = (bool) Minz_Request::paramString('separate_word_search');
|
||||
|
||||
$configObj = [
|
||||
'enable_in_article' => $this->enable_in_article,
|
||||
'enable_logs' => $this->enable_logs,
|
||||
'case_sensitive' => $this->case_sensitive,
|
||||
'separate_word_search' => $this->separate_word_search,
|
||||
'words' => preg_split("/\r\n|\n|\r/", $configWordList),
|
||||
];
|
||||
$configJson = json_encode($configObj, WordHighlighterExtension::JSON_ENCODE_CONF);
|
||||
file_put_contents(join_path($staticPath, ('config.' . $current_user . '.json')), $configJson . PHP_EOL);
|
||||
file_put_contents(join_path($staticPath, ('config.' . $current_user . '.js')), $this->jsonToJs($configJson) . PHP_EOL);
|
||||
}
|
||||
|
||||
if (file_exists($configFileJson)) {
|
||||
try {
|
||||
$confJson = json_decode(file_get_contents($configFileJson) ?: '', true, 8, JSON_THROW_ON_ERROR);
|
||||
if (json_last_error() !== JSON_ERROR_NONE || !is_array($confJson)) {
|
||||
return;
|
||||
}
|
||||
$this->enable_in_article = (bool) ($confJson['enable_in_article'] ?? false);
|
||||
$this->enable_logs = (bool) ($confJson['enable_logs'] ?? false);
|
||||
$this->case_sensitive = (bool) ($confJson['case_sensitive'] ?? false);
|
||||
$this->separate_word_search = (bool) ($confJson['separate_word_search'] ?? false);
|
||||
$this->word_highlighter_conf = implode("\n", (array) ($confJson['words'] ?? []));
|
||||
|
||||
} catch (Exception $exception) {
|
||||
// probably nothing to do needed
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private function jsonToJs(string $jsonStr): string
|
||||
{
|
||||
$js = "window.WordHighlighterConf = " .
|
||||
$jsonStr . ";\n" .
|
||||
"window.WordHighlighterConf.enable_logs && console.log('WordHighlighter: loaded user config:', window.WordHighlighterConf);";
|
||||
return $js;
|
||||
}
|
||||
}
|
||||
15
xExtension-WordHighlighter/i18n/en/ext.php
Normal file
15
xExtension-WordHighlighter/i18n/en/ext.php
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'word_highlighter' => array(
|
||||
'write_words' => 'Words to highlight',
|
||||
'write_words_more' => '(separated by newline)',
|
||||
'enable_in_article' => 'Enable highlighting also in article',
|
||||
'enable_in_article_more' => '(⚠️ may be slower with a lot of words)',
|
||||
'enable_logs' => 'Enable logs',
|
||||
'case_sensitive' => 'Case sensitive',
|
||||
'separate_word_search' => 'Separate word search',
|
||||
'test_highlighting_word' => 'highlight',
|
||||
'permission_problem' => 'Your config file is not writable, please change the file permissions for %s',
|
||||
),
|
||||
);
|
||||
15
xExtension-WordHighlighter/i18n/fr/ext.php
Normal file
15
xExtension-WordHighlighter/i18n/fr/ext.php
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'word_highlighter' => array(
|
||||
'write_words' => 'Mots à surligner',
|
||||
'write_words_more' => '(séparés par une nouvelle ligne)',
|
||||
'enable_in_article' => 'Activer la mise en évidence également dans l’article',
|
||||
'enable_in_article_more' => '(⚠️ peut être plus lent avec beaucoup de mots)',
|
||||
'enable_logs' => 'Activer les journaux',
|
||||
'case_sensitive' => 'Sensible à la casse',
|
||||
'separate_word_search' => 'Recherche de mots séparés',
|
||||
'test_highlighting_word' => 'surligner',
|
||||
'permission_problem' => 'Votre fichier de configuration n’est pas accessible en écriture, veuillez modifier les permissions du fichier %s',
|
||||
),
|
||||
);
|
||||
8
xExtension-WordHighlighter/metadata.json
Normal file
8
xExtension-WordHighlighter/metadata.json
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"name": "Word highlighter",
|
||||
"author": "Lukas Melega",
|
||||
"description": "Highlight specific words",
|
||||
"version": "0.0.2",
|
||||
"entrypoint": "WordHighlighter",
|
||||
"type": "user"
|
||||
}
|
||||
BIN
xExtension-WordHighlighter/snapshot-dark.png
Normal file
BIN
xExtension-WordHighlighter/snapshot-dark.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 227 KiB |
BIN
xExtension-WordHighlighter/snapshot.png
Normal file
BIN
xExtension-WordHighlighter/snapshot.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 210 KiB |
2
xExtension-WordHighlighter/static/.gitignore
vendored
Normal file
2
xExtension-WordHighlighter/static/.gitignore
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
config-words.*.js
|
||||
config-words.*.txt
|
||||
13
xExtension-WordHighlighter/static/mark.min.js
vendored
Normal file
13
xExtension-WordHighlighter/static/mark.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
14
xExtension-WordHighlighter/static/style.css
Normal file
14
xExtension-WordHighlighter/static/style.css
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
/* WordHighlighter v0.0.2 (FreshRSS Extension) CSS */
|
||||
#stream mark {
|
||||
padding: 2px;
|
||||
padding-right: 0; /* because in case when part of word is highlighted */
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
#stream mark.mark-secondary {
|
||||
background-color: rgba(255, 255, 0, 0.3) !important;
|
||||
}
|
||||
|
||||
html[class*="darkMode"] #stream mark.mark-secondary {
|
||||
background-color: rgba(255, 255, 0, 0.5) !important;
|
||||
}
|
||||
89
xExtension-WordHighlighter/static/word-highlighter.js
Normal file
89
xExtension-WordHighlighter/static/word-highlighter.js
Normal file
|
|
@ -0,0 +1,89 @@
|
|||
'use strict';
|
||||
|
||||
/* WordHighlighter v0.0.2 (FreshRSS Extension) */
|
||||
|
||||
function wordHighlighter(c /* console */, Mark, context, OPTIONS) {
|
||||
const markConf = (done, counter) => ({
|
||||
caseSensitive: OPTIONS.case_sensitive || false,
|
||||
separateWordSearch: OPTIONS.separate_word_search || false,
|
||||
ignoreJoiners: OPTIONS.ignore_joiners || false,
|
||||
exclude: [
|
||||
'mark',
|
||||
...(OPTIONS.enable_in_article ? [] : ['article *']),
|
||||
],
|
||||
done: (n) => (counter.value += n) && done(),
|
||||
noMatch: done,
|
||||
});
|
||||
|
||||
const m = new Mark(context);
|
||||
const changePageListener = debounce(200, (x) => {
|
||||
OPTIONS.enable_logs && c.group('WordHighlighter: page change');
|
||||
stopObserving();
|
||||
highlightWords(m, startObserving);
|
||||
});
|
||||
|
||||
const mo = new MutationObserver(changePageListener);
|
||||
mo.observe(context, { subtree: true, childList: true });
|
||||
|
||||
function startObserving() {
|
||||
mo.observe(context, { subtree: true, childList: true });
|
||||
}
|
||||
|
||||
function stopObserving() {
|
||||
mo.disconnect();
|
||||
}
|
||||
|
||||
function highlightWords(m, done) {
|
||||
const start = performance.now();
|
||||
const hCounter = { value: 0 };
|
||||
|
||||
new Promise((resolve) =>
|
||||
m.mark(OPTIONS.words || [], { ...markConf(resolve, hCounter) })
|
||||
)
|
||||
.finally(() => {
|
||||
if (OPTIONS.enable_logs) {
|
||||
c.log(`WordHighlighter: ${hCounter.value} new highlights added in ${performance.now() - start}ms.`);
|
||||
c.groupEnd();
|
||||
}
|
||||
typeof done === 'function' && done();
|
||||
});
|
||||
}
|
||||
|
||||
highlightWords(m);
|
||||
}
|
||||
|
||||
// MAIN:
|
||||
|
||||
(function main() {
|
||||
try {
|
||||
const confName = 'WordHighlighterConf';
|
||||
const OPTIONS = window[confName] || { };
|
||||
const onMainPage = !(new URL(window.location)).searchParams.get('c');
|
||||
if (onMainPage) {
|
||||
console.log('WordHighlighter: script load...');
|
||||
const context = document.querySelector('#stream');
|
||||
wordHighlighter(console, window.Mark || (Error('mark.js library is not loaded ❗️')), context, OPTIONS);
|
||||
console.log('WordHighlighter: script loaded.✅');
|
||||
} else {
|
||||
OPTIONS.enable_logs && console.log('WordHighlighter: ❗️ paused outside of feed page');
|
||||
}
|
||||
return Promise.resolve();
|
||||
} catch (error) {
|
||||
console.error('WordHighlighter: ❌', error);
|
||||
return Promise.reject(error);
|
||||
}
|
||||
})();
|
||||
|
||||
// Util functions:
|
||||
|
||||
function debounce(duration, func) {
|
||||
let timeout;
|
||||
return function (...args) {
|
||||
const effect = () => {
|
||||
timeout = null;
|
||||
return func.apply(this, args);
|
||||
};
|
||||
clearTimeout(timeout);
|
||||
timeout = setTimeout(effect, duration);
|
||||
};
|
||||
}
|
||||
674
xExtension-YouTube/LICENSE
Normal file
674
xExtension-YouTube/LICENSE
Normal file
|
|
@ -0,0 +1,674 @@
|
|||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU General Public License is a free, copyleft license for
|
||||
software and other kinds of works.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
the GNU General Public License is intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users. We, the Free Software Foundation, use the
|
||||
GNU General Public License for most of our software; it applies also to
|
||||
any other work released this way by its authors. You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to prevent others from denying you
|
||||
these rights or asking you to surrender the rights. Therefore, you have
|
||||
certain responsibilities if you distribute copies of the software, or if
|
||||
you modify it: responsibilities to respect the freedom of others.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must pass on to the recipients the same
|
||||
freedoms that you received. You must make sure that they, too, receive
|
||||
or can get the source code. And you must show them these terms so they
|
||||
know their rights.
|
||||
|
||||
Developers that use the GNU GPL protect your rights with two steps:
|
||||
(1) assert copyright on the software, and (2) offer you this License
|
||||
giving you legal permission to copy, distribute and/or modify it.
|
||||
|
||||
For the developers' and authors' protection, the GPL clearly explains
|
||||
that there is no warranty for this free software. For both users' and
|
||||
authors' sake, the GPL requires that modified versions be marked as
|
||||
changed, so that their problems will not be attributed erroneously to
|
||||
authors of previous versions.
|
||||
|
||||
Some devices are designed to deny users access to install or run
|
||||
modified versions of the software inside them, although the manufacturer
|
||||
can do so. This is fundamentally incompatible with the aim of
|
||||
protecting users' freedom to change the software. The systematic
|
||||
pattern of such abuse occurs in the area of products for individuals to
|
||||
use, which is precisely where it is most unacceptable. Therefore, we
|
||||
have designed this version of the GPL to prohibit the practice for those
|
||||
products. If such problems arise substantially in other domains, we
|
||||
stand ready to extend this provision to those domains in future versions
|
||||
of the GPL, as needed to protect the freedom of users.
|
||||
|
||||
Finally, every program is threatened constantly by software patents.
|
||||
States should not allow patents to restrict development and use of
|
||||
software on general-purpose computers, but in those that do, we wish to
|
||||
avoid the special danger that patents applied to a free program could
|
||||
make it effectively proprietary. To prevent this, the GPL assures that
|
||||
patents cannot be used to render the program non-free.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Use with the GNU Affero General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU Affero General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the special requirements of the GNU Affero General Public License,
|
||||
section 13, concerning interaction through a network will apply to the
|
||||
combination as such.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
<program> Copyright (C) <year> <name of author>
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, your program's commands
|
||||
might be different; for a GUI interface, you would use an "about box".
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU GPL, see
|
||||
<http://www.gnu.org/licenses/>.
|
||||
|
||||
The GNU General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library, you
|
||||
may consider it more useful to permit linking proprietary applications with
|
||||
the library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License. But first, please read
|
||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
||||
62
xExtension-YouTube/README.md
Normal file
62
xExtension-YouTube/README.md
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
# FreshRSS - YouTube video extension
|
||||
|
||||
This FreshRSS extension allows you to directly watch YouTube/PeerTube videos from within subscribed channel feeds.
|
||||
|
||||
To use it, upload the ```xExtension-YouTube``` directory to the FreshRSS `./extensions` directory on your server and enable it on the extension panel in FreshRSS.
|
||||
|
||||
## Features
|
||||
|
||||
- Embeds Youtube videos directly in FreshRSS, instead of linking to the Youtube page
|
||||
- Simplifies the subscription to channel URLs by automatically detecting the channels feed URL
|
||||
|
||||
You can simply add Youtube video subscriptions by pasting URLs like:
|
||||
- `https://www.youtube.com/channel/UCwbjxO5qQTMkSZVueqKwxuw`
|
||||
- `https://www.youtube.com/user/AndrewTrials`
|
||||
|
||||
## Screenshots
|
||||
|
||||
With FreshRSS and an original Youtube Channel feed:
|
||||

|
||||
|
||||
With activated Youtube extension:
|
||||

|
||||
|
||||
## Changelog
|
||||
|
||||
0.12:
|
||||
- Turkish language support added
|
||||
|
||||
0.11:
|
||||
- Modernized codebase for latest FreshRSS release 1.23.1
|
||||
- Moved from [custom repo](https://github.com/kevinpapst/freshrss-youtube) to FreshRSS official extension repo
|
||||
|
||||
0.10:
|
||||
- Enhance feed content formatting when included
|
||||
- Enhance YouTube URL matching
|
||||
|
||||
0.9:
|
||||
- Set the extension level at "user" (**users must re-enable the extension**)
|
||||
- Fix calls to unset configuration variables
|
||||
- Register translations when extension is disabled
|
||||
|
||||
0.8:
|
||||
- Automatically convert channel and username URLs to feed URLs
|
||||
|
||||
0.7:
|
||||
- Support for PeerTube feed
|
||||
|
||||
0.6:
|
||||
- Support cookie-less domain [youtube-nocookie.com](https://www.youtube-nocookie.com) for embedding
|
||||
|
||||
0.5:
|
||||
- Opened "API" for external usage
|
||||
|
||||
0.4:
|
||||
- Added option to display original feed content (currently Youtube inserts a download icon link to the video file)
|
||||
- Fixed config loading
|
||||
|
||||
0.3:
|
||||
- Added installation hints
|
||||
|
||||
0.2:
|
||||
- Fixed "Use of undefined constant FreshRSS_Context"
|
||||
45
xExtension-YouTube/configure.phtml
Normal file
45
xExtension-YouTube/configure.phtml
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
<?php
|
||||
declare(strict_types=1);
|
||||
/** @var YouTubeExtension $this */
|
||||
?>
|
||||
<form action="<?php echo _url('extension', 'configure', 'e', urlencode($this->getName())); ?>" method="post">
|
||||
<input type="hidden" name="_csrf" value="<?php echo FreshRSS_Auth::csrfToken(); ?>" />
|
||||
<div class="form-group">
|
||||
|
||||
<label class="group-name" for="yt_height"><?php echo _t('ext.yt_videos.height'); ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="number" id="yt_height" name="yt_height" value="<?php echo $this->getHeight(); ?>" min="50" data-leave-validation="1">
|
||||
</div>
|
||||
|
||||
<label class="group-name" for="yt_width"><?php echo _t('ext.yt_videos.width'); ?></label>
|
||||
<div class="group-controls">
|
||||
<input type="number" id="yt_width" name="yt_width" value="<?php echo $this->getWidth(); ?>" min="100" data-leave-validation="1">
|
||||
</div>
|
||||
|
||||
<div class="group-controls">
|
||||
<label class="checkbox" for="yt_show_content">
|
||||
<input type="checkbox" id="yt_show_content" name="yt_show_content" value="1" <?php echo $this->isShowContent() ? 'checked' : ''; ?>>
|
||||
<?php echo _t('ext.yt_videos.show_content'); ?>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div class="group-controls">
|
||||
<label class="checkbox" for="yt_nocookie">
|
||||
<input type="checkbox" id="yt_nocookie" name="yt_nocookie" value="1" <?php echo $this->isUseNoCookieDomain() ? 'checked' : ''; ?>>
|
||||
<?php echo _t('ext.yt_videos.use_nocookie'); ?>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group form-actions">
|
||||
<div class="group-controls">
|
||||
<button type="submit" class="btn btn-important"><?php echo _t('gen.action.submit'); ?></button>
|
||||
<button type="reset" class="btn"><?php echo _t('gen.action.cancel'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<p>
|
||||
<?php echo _t('ext.yt_videos.updates'); ?>
|
||||
<a href="https://github.com/kevinpapst/freshrss-youtube" target="_blank">GitHub</a>.
|
||||
</p>
|
||||
261
xExtension-YouTube/extension.php
Normal file
261
xExtension-YouTube/extension.php
Normal file
|
|
@ -0,0 +1,261 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* Class YouTubeExtension
|
||||
*
|
||||
* Latest version can be found at https://github.com/kevinpapst/freshrss-youtube
|
||||
*
|
||||
* @author Kevin Papst
|
||||
*/
|
||||
final class YouTubeExtension extends Minz_Extension
|
||||
{
|
||||
/**
|
||||
* Video player width
|
||||
*/
|
||||
private int $width = 560;
|
||||
/**
|
||||
* Video player height
|
||||
*/
|
||||
private int $height = 315;
|
||||
/**
|
||||
* Whether we display the original feed content
|
||||
*/
|
||||
private bool $showContent = false;
|
||||
/**
|
||||
* Switch to enable the Youtube No-Cookie domain
|
||||
*/
|
||||
private bool $useNoCookie = false;
|
||||
|
||||
/**
|
||||
* Initialize this extension
|
||||
*/
|
||||
#[\Override]
|
||||
public function init(): void
|
||||
{
|
||||
$this->registerHook('entry_before_display', [$this, 'embedYouTubeVideo']);
|
||||
$this->registerHook('check_url_before_add', [self::class, 'convertYoutubeFeedUrl']);
|
||||
$this->registerTranslates();
|
||||
}
|
||||
|
||||
public static function convertYoutubeFeedUrl(string $url): string
|
||||
{
|
||||
$matches = [];
|
||||
|
||||
if (preg_match('#^https?://www\.youtube\.com/channel/([0-9a-zA-Z_-]{6,36})#', $url, $matches) === 1) {
|
||||
return 'https://www.youtube.com/feeds/videos.xml?channel_id=' . $matches[1];
|
||||
}
|
||||
|
||||
if (preg_match('#^https?://www\.youtube\.com/user/([0-9a-zA-Z_-]{6,36})#', $url, $matches) === 1) {
|
||||
return 'https://www.youtube.com/feeds/videos.xml?user=' . $matches[1];
|
||||
}
|
||||
|
||||
return $url;
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the extension configuration, if the user context is available.
|
||||
* Do not call that in your extensions init() method, it can't be used there.
|
||||
*/
|
||||
public function loadConfigValues(): void
|
||||
{
|
||||
if (!class_exists('FreshRSS_Context', false) || !FreshRSS_Context::hasUserConf()) {
|
||||
return;
|
||||
}
|
||||
|
||||
$width = FreshRSS_Context::userConf()->attributeInt('yt_player_width');
|
||||
if ($width !== null) {
|
||||
$this->width = $width;
|
||||
}
|
||||
|
||||
$height = FreshRSS_Context::userConf()->attributeInt('yt_player_height');
|
||||
if ($height !== null) {
|
||||
$this->height = $height;
|
||||
}
|
||||
|
||||
$showContent = FreshRSS_Context::userConf()->attributeBool('yt_show_content');
|
||||
if ($showContent !== null) {
|
||||
$this->showContent = $showContent;
|
||||
}
|
||||
|
||||
$noCookie = FreshRSS_Context::userConf()->attributeBool('yt_nocookie');
|
||||
if ($noCookie !== null) {
|
||||
$this->useNoCookie = $noCookie;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the width in pixel for the YouTube player iframe.
|
||||
* You have to call loadConfigValues() before this one, otherwise you get default values.
|
||||
*/
|
||||
public function getWidth(): int
|
||||
{
|
||||
return $this->width;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the height in pixel for the YouTube player iframe.
|
||||
* You have to call loadConfigValues() before this one, otherwise you get default values.
|
||||
*/
|
||||
public function getHeight(): int
|
||||
{
|
||||
return $this->height;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether this extension displays the content of the YouTube feed.
|
||||
* You have to call loadConfigValues() before this one, otherwise you get default values.
|
||||
*/
|
||||
public function isShowContent(): bool
|
||||
{
|
||||
return $this->showContent;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns if this extension should use youtube-nocookie.com instead of youtube.com.
|
||||
* You have to call loadConfigValues() before this one, otherwise you get default values.
|
||||
*/
|
||||
public function isUseNoCookieDomain(): bool
|
||||
{
|
||||
return $this->useNoCookie;
|
||||
}
|
||||
|
||||
/**
|
||||
* Inserts the YouTube video iframe into the content of an entry, if the entries link points to a YouTube watch URL.
|
||||
*/
|
||||
public function embedYouTubeVideo(FreshRSS_Entry $entry): FreshRSS_Entry
|
||||
{
|
||||
$link = $entry->link();
|
||||
|
||||
if (preg_match('#^https?://www\.youtube\.com/watch\?v=|/videos/watch/[0-9a-f-]{36}$#', $link) !== 1) {
|
||||
return $entry;
|
||||
}
|
||||
|
||||
$this->loadConfigValues();
|
||||
|
||||
if (stripos($entry->content(), '<iframe class="youtube-plugin-video"') !== false) {
|
||||
return $entry;
|
||||
}
|
||||
if (stripos($link, 'www.youtube.com/watch?v=') !== false) {
|
||||
$html = $this->getHtmlContentForLink($entry, $link);
|
||||
}
|
||||
else { //peertube
|
||||
$html = $this->getHtmlPeerTubeContentForLink($entry, $link);
|
||||
}
|
||||
|
||||
$entry->_content($html);
|
||||
|
||||
return $entry;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an HTML <iframe> for a given Youtube watch URL (www.youtube.com/watch?v=)
|
||||
*/
|
||||
public function getHtmlContentForLink(FreshRSS_Entry $entry, string $link): string
|
||||
{
|
||||
$domain = 'www.youtube.com';
|
||||
if ($this->useNoCookie) {
|
||||
$domain = 'www.youtube-nocookie.com';
|
||||
}
|
||||
$url = str_replace('//www.youtube.com/watch?v=', '//'.$domain.'/embed/', $link);
|
||||
$url = str_replace('http://', 'https://', $url);
|
||||
|
||||
return $this->getHtml($entry, $url);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an HTML <iframe> for a given PeerTube watch URL
|
||||
*/
|
||||
public function getHtmlPeerTubeContentForLink(FreshRSS_Entry $entry, string $link): string
|
||||
{
|
||||
$url = str_replace('/watch', '/embed', $link);
|
||||
|
||||
return $this->getHtml($entry, $url);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an HTML <iframe> for a given URL for the configured width and height, with content ignored, appended or formatted.
|
||||
*/
|
||||
public function getHtml(FreshRSS_Entry $entry, string $url): string
|
||||
{
|
||||
$content = '';
|
||||
|
||||
$iframe = '<iframe class="youtube-plugin-video"
|
||||
style="height: ' . $this->height . 'px; width: ' . $this->width . 'px;"
|
||||
width="' . $this->width . '"
|
||||
height="' . $this->height . '"
|
||||
src="' . $url . '"
|
||||
frameborder="0"
|
||||
allowFullScreen></iframe>';
|
||||
|
||||
if ($this->showContent) {
|
||||
$doc = new DOMDocument();
|
||||
$doc->encoding = 'UTF-8';
|
||||
$doc->recover = true;
|
||||
$doc->strictErrorChecking = false;
|
||||
|
||||
if ($doc->loadHTML('<?xml encoding="utf-8" ?>' . $entry->content()))
|
||||
{
|
||||
$xpath = new DOMXPath($doc);
|
||||
|
||||
/** @var DOMNodeList<DOMElement> $titles */
|
||||
$titles = $xpath->evaluate("//*[@class='enclosure-title']");
|
||||
/** @var DOMNodeList<DOMElement> $thumbnails */
|
||||
$thumbnails = $xpath->evaluate("//*[@class='enclosure-thumbnail']/@src");
|
||||
/** @var DOMNodeList<DOMElement> $descriptions */
|
||||
$descriptions = $xpath->evaluate("//*[@class='enclosure-description']");
|
||||
|
||||
$content = '<div class="enclosure">';
|
||||
|
||||
// We hide the title so it doesn't appear in the final article, which would be redundant with the RSS article title,
|
||||
// but we keep it in the content anyway, so RSS clients can extract it if needed.
|
||||
if ($titles->length > 0) {
|
||||
$content .= '<p class="enclosure-title" hidden>' . $titles[0]->nodeValue . '</p>';
|
||||
}
|
||||
|
||||
// We hide the thumbnail so it doesn't appear in the final article, which would be redundant with the YouTube player preview,
|
||||
// but we keep it in the content anyway, so RSS clients can extract it to display a preview where it wants (in article listing,
|
||||
// by example, like with Reeder).
|
||||
if ($thumbnails->length > 0) {
|
||||
$content .= '<p hidden><img class="enclosure-thumbnail" src="' . $thumbnails[0]->nodeValue . '" alt=""/></p>';
|
||||
}
|
||||
|
||||
$content .= $iframe;
|
||||
|
||||
if ($descriptions->length > 0) {
|
||||
$content .= '<p class="enclosure-description">' . nl2br(htmlentities($descriptions[0]->nodeValue)) . '</p>';
|
||||
}
|
||||
|
||||
$content .= "</div>\n";
|
||||
}
|
||||
else {
|
||||
$content = $iframe . $entry->content();
|
||||
}
|
||||
}
|
||||
else {
|
||||
$content = $iframe;
|
||||
}
|
||||
|
||||
return $content;
|
||||
}
|
||||
|
||||
/**
|
||||
* This function is called by FreshRSS when the configuration page is loaded, and when configuration is saved.
|
||||
* - We save configuration in case of a post.
|
||||
* - We (re)load configuration in all case, so they are in-sync after a save and before a page load.
|
||||
*/
|
||||
#[\Override]
|
||||
public function handleConfigureAction(): void
|
||||
{
|
||||
$this->registerTranslates();
|
||||
|
||||
if (Minz_Request::isPost()) {
|
||||
FreshRSS_Context::userConf()->_attribute('yt_player_height', Minz_Request::paramInt('yt_height'));
|
||||
FreshRSS_Context::userConf()->_attribute('yt_player_width', Minz_Request::paramInt('yt_width'));
|
||||
FreshRSS_Context::userConf()->_attribute('yt_show_content', Minz_Request::paramBoolean('yt_show_content'));
|
||||
FreshRSS_Context::userConf()->_attribute('yt_nocookie', Minz_Request::paramInt('yt_nocookie'));
|
||||
FreshRSS_Context::userConf()->save();
|
||||
}
|
||||
|
||||
$this->loadConfigValues();
|
||||
}
|
||||
}
|
||||
11
xExtension-YouTube/i18n/de/ext.php
Normal file
11
xExtension-YouTube/i18n/de/ext.php
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'yt_videos' => array(
|
||||
'height' => 'Höhe des Players',
|
||||
'width' => 'Breite des Players',
|
||||
'updates' => 'Die neueste Version des Plugins findest Du bei',
|
||||
'show_content' => 'Zeige den Inhalt des Feeds an',
|
||||
'use_nocookie' => 'Verwende die Cookie-freie Domain www.youtube-nocookie.com',
|
||||
),
|
||||
);
|
||||
11
xExtension-YouTube/i18n/en/ext.php
Normal file
11
xExtension-YouTube/i18n/en/ext.php
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'yt_videos' => array(
|
||||
'height' => 'Player height',
|
||||
'width' => 'Player width',
|
||||
'updates' => 'You can find the latest extension version at',
|
||||
'show_content' => 'Display the feeds content',
|
||||
'use_nocookie' => 'Use the cookie-free domain www.youtube-nocookie.com',
|
||||
),
|
||||
);
|
||||
11
xExtension-YouTube/i18n/fr/ext.php
Normal file
11
xExtension-YouTube/i18n/fr/ext.php
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'yt_videos' => array(
|
||||
'height' => 'Hauteur du lecteur',
|
||||
'width' => 'Largeur du lecteur',
|
||||
'updates' => 'Vous pouvez trouver la dernière mise à jour de l’extension sur ',
|
||||
'show_content' => 'Afficher le contenu du flux',
|
||||
'use_nocookie' => 'Utiliser le domaine www.youtube-nocookie.com pour éviter les cookies',
|
||||
),
|
||||
);
|
||||
11
xExtension-YouTube/i18n/tr/ext.php
Normal file
11
xExtension-YouTube/i18n/tr/ext.php
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
<?php
|
||||
|
||||
return array(
|
||||
'yt_videos' => array(
|
||||
'height' => 'Oynatıcı yükseklik',
|
||||
'width' => 'Oynatıcı genişlik',
|
||||
'updates' => 'En son uzantı sürümünü şu adreste bulabilirsiniz:',
|
||||
'show_content' => 'Yayın içeriğini görüntüle',
|
||||
'use_nocookie' => 'Çerezsiz olan "www.youtube-nocookie.com" alan adını kullanın',
|
||||
),
|
||||
);
|
||||
8
xExtension-YouTube/metadata.json
Normal file
8
xExtension-YouTube/metadata.json
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"name": "YouTube Video Feed",
|
||||
"author": "Kevin Papst",
|
||||
"description": "Embed YouTube feeds inside article content.",
|
||||
"version": "0.12",
|
||||
"entrypoint": "YouTube",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
declare(strict_types=1);
|
||||
|
||||
class ShowFeedIdExtension extends Minz_Extension {
|
||||
final class ShowFeedIdExtension extends Minz_Extension {
|
||||
#[\Override]
|
||||
public function init(): void {
|
||||
Minz_View::appendScript($this->getFileUrl('showfeedid.js', 'js'));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"name": "ShowFeedID",
|
||||
"author": "math-GH",
|
||||
"description": "Show the feed ID",
|
||||
"version": "0.2",
|
||||
"description": "Show the ID of feed and category",
|
||||
"version": "0.3.0",
|
||||
"entrypoint": "ShowFeedID",
|
||||
"type": "user"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ if (url.searchParams.get('c') === 'subscription') {
|
|||
|
||||
button.classList.add('btn');
|
||||
button.id = 'showFeedId';
|
||||
button.innerHTML = '<img class="icon" src="../themes/icons/look.svg" /> FeedID';
|
||||
button.innerHTML = '<img class="icon" src="../themes/icons/look.svg" /> Show IDs';
|
||||
div.appendChild(button);
|
||||
|
||||
document.getElementById('showFeedId').addEventListener('click', function (e) {
|
||||
|
|
@ -22,5 +22,17 @@ if (url.searchParams.get('c') === 'subscription') {
|
|||
feedname_elem.innerHTML = feedname_elem.textContent + ' (ID: ' + feedId + ')';
|
||||
}
|
||||
});
|
||||
|
||||
const cats = document.querySelectorAll('div.box > ul.box-content');
|
||||
|
||||
let catId;
|
||||
let catname_elem;
|
||||
cats.forEach(function (cat) {
|
||||
catId = cat.dataset.catId;
|
||||
catname_elem = cat.parentElement.querySelectorAll('div.box-title > h2')[0];
|
||||
if (catname_elem) {
|
||||
catname_elem.innerHTML = catname_elem.textContent + ' (ID: ' + catId + ')';
|
||||
}
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue