diff --git a/plugins/admin/.gitignore b/plugins/admin/.gitignore index 77d3944..ddab4e4 100644 --- a/plugins/admin/.gitignore +++ b/plugins/admin/.gitignore @@ -14,3 +14,4 @@ tests/_support/_generated/* tests/cache/* tests/error.log /crowdin.yaml +.vscode diff --git a/plugins/admin/CHANGELOG.md b/plugins/admin/CHANGELOG.md index da183e2..4764d22 100644 --- a/plugins/admin/CHANGELOG.md +++ b/plugins/admin/CHANGELOG.md @@ -1,8 +1,16 @@ +# v1.10.34 +## 06/22/2022 + +1. [](#improved) + * Exposed `UriToMarkdown` util (`Grav.default.Utils.UriToMarkdown`) in admin, to convert links/images +1. [](#bugfix) + * Fixed `Latest Page Updates` permissions [#2294](https://github.com/getgrav/grav-plugin-admin/pull/2294) + # v1.10.33.1 ## 04/25/2022 1. [](#bugfix) - * Reverted [PR#2265](https://github.com/getgrav/grav-plugin-admin/pull/2265) as it broke sections output. + * Reverted [PR#2265](https://github.com/getgrav/grav-plugin-admin/pull/2265) as it broke sections output # v1.10.33 ## 04/25/2022 diff --git a/plugins/admin/blueprints.yaml b/plugins/admin/blueprints.yaml index 4c7caa8..f15df94 100644 --- a/plugins/admin/blueprints.yaml +++ b/plugins/admin/blueprints.yaml @@ -1,7 +1,7 @@ name: Admin Panel slug: admin type: plugin -version: 1.10.33.1 +version: 1.10.34 description: Adds an advanced administration panel to manage your site icon: empire author: diff --git a/plugins/admin/composer.lock b/plugins/admin/composer.lock index 20272f7..4b74cde 100644 --- a/plugins/admin/composer.lock +++ b/plugins/admin/composer.lock @@ -190,16 +190,16 @@ }, { "name": "scssphp/scssphp", - "version": "v1.10.2", + "version": "v1.10.3", "source": { "type": "git", "url": "https://github.com/scssphp/scssphp.git", - "reference": "387f4f4abf5d99f16be16314c5ab856f81c82f46" + "reference": "0f1e1516ed2412ad43e42a6a319e77624ba1f713" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/scssphp/scssphp/zipball/387f4f4abf5d99f16be16314c5ab856f81c82f46", - "reference": "387f4f4abf5d99f16be16314c5ab856f81c82f46", + "url": "https://api.github.com/repos/scssphp/scssphp/zipball/0f1e1516ed2412ad43e42a6a319e77624ba1f713", + "reference": "0f1e1516ed2412ad43e42a6a319e77624ba1f713", "shasum": "" }, "require": { @@ -258,9 +258,9 @@ ], "support": { "issues": "https://github.com/scssphp/scssphp/issues", - "source": "https://github.com/scssphp/scssphp/tree/v1.10.2" + "source": "https://github.com/scssphp/scssphp/tree/v1.10.3" }, - "time": "2022-03-02T21:15:09+00:00" + "time": "2022-05-16T07:22:18+00:00" } ], "packages-dev": [ @@ -425,16 +425,16 @@ }, { "name": "codeception/phpunit-wrapper", - "version": "7.8.2", + "version": "7.8.4", "source": { "type": "git", "url": "https://github.com/Codeception/phpunit-wrapper.git", - "reference": "cafed18048826790c527843f9b85e8cc79b866f1" + "reference": "dd44fc152433d27d3de03d59b4945449b3407af0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Codeception/phpunit-wrapper/zipball/cafed18048826790c527843f9b85e8cc79b866f1", - "reference": "cafed18048826790c527843f9b85e8cc79b866f1", + "url": "https://api.github.com/repos/Codeception/phpunit-wrapper/zipball/dd44fc152433d27d3de03d59b4945449b3407af0", + "reference": "dd44fc152433d27d3de03d59b4945449b3407af0", "shasum": "" }, "require": { @@ -466,9 +466,9 @@ "description": "PHPUnit classes used by Codeception", "support": { "issues": "https://github.com/Codeception/phpunit-wrapper/issues", - "source": "https://github.com/Codeception/phpunit-wrapper/tree/7.8.2" + "source": "https://github.com/Codeception/phpunit-wrapper/tree/7.8.4" }, - "time": "2020-12-28T14:00:26+00:00" + "time": "2022-05-23T06:09:22+00:00" }, { "name": "codeception/stub", @@ -697,16 +697,16 @@ }, { "name": "guzzlehttp/guzzle", - "version": "6.5.5", + "version": "6.5.7", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e" + "reference": "724562fa861e21a4071c652c8a159934e4f05592" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", - "reference": "9d4290de1cfd701f38099ef7e183b64b4b7b0c5e", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/724562fa861e21a4071c652c8a159934e4f05592", + "reference": "724562fa861e21a4071c652c8a159934e4f05592", "shasum": "" }, "require": { @@ -743,10 +743,40 @@ "MIT" ], "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, { "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Jeremy Lindblom", + "email": "jeremeamia@gmail.com", + "homepage": "https://github.com/jeremeamia" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" } ], "description": "Guzzle is a PHP HTTP client library", @@ -762,9 +792,23 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/6.5" + "source": "https://github.com/guzzle/guzzle/tree/6.5.7" }, - "time": "2020-06-16T21:01:06+00:00" + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle", + "type": "tidelift" + } + ], + "time": "2022-06-09T21:36:50+00:00" }, { "name": "guzzlehttp/promises", @@ -1241,16 +1285,16 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.6.0", + "version": "1.6.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "93ebd0014cab80c4ea9f5e297ea48672f1b87706" + "reference": "77a32518733312af16a44300404e945338981de3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/93ebd0014cab80c4ea9f5e297ea48672f1b87706", - "reference": "93ebd0014cab80c4ea9f5e297ea48672f1b87706", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/77a32518733312af16a44300404e945338981de3", + "reference": "77a32518733312af16a44300404e945338981de3", "shasum": "" }, "require": { @@ -1285,9 +1329,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.0" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.1" }, - "time": "2022-01-04T19:58:01+00:00" + "time": "2022-03-15T21:29:03+00:00" }, { "name": "phpspec/prophecy", @@ -2618,16 +2662,16 @@ }, { "name": "symfony/console", - "version": "v4.4.38", + "version": "v4.4.42", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "5a50085bf5460f0c0d60a50b58388c1249826b8a" + "reference": "cce7a9f99e22937a71a16b23afa762558808d587" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/5a50085bf5460f0c0d60a50b58388c1249826b8a", - "reference": "5a50085bf5460f0c0d60a50b58388c1249826b8a", + "url": "https://api.github.com/repos/symfony/console/zipball/cce7a9f99e22937a71a16b23afa762558808d587", + "reference": "cce7a9f99e22937a71a16b23afa762558808d587", "shasum": "" }, "require": { @@ -2688,7 +2732,7 @@ "description": "Eases the creation of beautiful and testable command line interfaces", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/console/tree/v4.4.38" + "source": "https://github.com/symfony/console/tree/v4.4.42" }, "funding": [ { @@ -2704,7 +2748,7 @@ "type": "tidelift" } ], - "time": "2022-01-30T21:23:57+00:00" + "time": "2022-05-14T12:35:33+00:00" }, { "name": "symfony/css-selector", @@ -2774,16 +2818,16 @@ }, { "name": "symfony/deprecation-contracts", - "version": "v2.5.0", + "version": "v2.5.1", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "6f981ee24cf69ee7ce9736146d1c57c2780598a8" + "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/6f981ee24cf69ee7ce9736146d1c57c2780598a8", - "reference": "6f981ee24cf69ee7ce9736146d1c57c2780598a8", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66", + "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66", "shasum": "" }, "require": { @@ -2821,7 +2865,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.1" }, "funding": [ { @@ -2837,20 +2881,20 @@ "type": "tidelift" } ], - "time": "2021-07-12T14:48:14+00:00" + "time": "2022-01-02T09:53:40+00:00" }, { "name": "symfony/dom-crawler", - "version": "v4.4.39", + "version": "v4.4.42", "source": { "type": "git", "url": "https://github.com/symfony/dom-crawler.git", - "reference": "4e9215a8b533802ba84a3cc5bd3c43103e7a6dc3" + "reference": "be5a04618e5d44e71d013f177df80d3ec4b192a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/4e9215a8b533802ba84a3cc5bd3c43103e7a6dc3", - "reference": "4e9215a8b533802ba84a3cc5bd3c43103e7a6dc3", + "url": "https://api.github.com/repos/symfony/dom-crawler/zipball/be5a04618e5d44e71d013f177df80d3ec4b192a0", + "reference": "be5a04618e5d44e71d013f177df80d3ec4b192a0", "shasum": "" }, "require": { @@ -2895,7 +2939,7 @@ "description": "Eases DOM navigation for HTML and XML documents", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dom-crawler/tree/v4.4.39" + "source": "https://github.com/symfony/dom-crawler/tree/v4.4.42" }, "funding": [ { @@ -2911,20 +2955,20 @@ "type": "tidelift" } ], - "time": "2022-02-25T10:38:15+00:00" + "time": "2022-04-30T18:34:00+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v4.4.37", + "version": "v4.4.42", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "3ccfcfb96ecce1217d7b0875a0736976bc6e63dc" + "reference": "708e761740c16b02c86e3f0c932018a06b895d40" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/3ccfcfb96ecce1217d7b0875a0736976bc6e63dc", - "reference": "3ccfcfb96ecce1217d7b0875a0736976bc6e63dc", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/708e761740c16b02c86e3f0c932018a06b895d40", + "reference": "708e761740c16b02c86e3f0c932018a06b895d40", "shasum": "" }, "require": { @@ -2979,7 +3023,7 @@ "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/event-dispatcher/tree/v4.4.37" + "source": "https://github.com/symfony/event-dispatcher/tree/v4.4.42" }, "funding": [ { @@ -2995,20 +3039,20 @@ "type": "tidelift" } ], - "time": "2022-01-02T09:41:36+00:00" + "time": "2022-05-05T15:33:49+00:00" }, { "name": "symfony/event-dispatcher-contracts", - "version": "v1.1.11", + "version": "v1.1.12", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher-contracts.git", - "reference": "01e9a4efac0ee33a05dfdf93b346f62e7d0e998c" + "reference": "1d5cd762abaa6b2a4169d3e77610193a7157129e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/01e9a4efac0ee33a05dfdf93b346f62e7d0e998c", - "reference": "01e9a4efac0ee33a05dfdf93b346f62e7d0e998c", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/1d5cd762abaa6b2a4169d3e77610193a7157129e", + "reference": "1d5cd762abaa6b2a4169d3e77610193a7157129e", "shasum": "" }, "require": { @@ -3058,7 +3102,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v1.1.11" + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v1.1.12" }, "funding": [ { @@ -3074,20 +3118,20 @@ "type": "tidelift" } ], - "time": "2021-03-23T15:25:38+00:00" + "time": "2022-01-02T09:41:36+00:00" }, { "name": "symfony/finder", - "version": "v4.4.37", + "version": "v4.4.41", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "b17d76d7ed179f017aad646e858c90a2771af15d" + "reference": "40790bdf293b462798882ef6da72bb49a4a6633a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/b17d76d7ed179f017aad646e858c90a2771af15d", - "reference": "b17d76d7ed179f017aad646e858c90a2771af15d", + "url": "https://api.github.com/repos/symfony/finder/zipball/40790bdf293b462798882ef6da72bb49a4a6633a", + "reference": "40790bdf293b462798882ef6da72bb49a4a6633a", "shasum": "" }, "require": { @@ -3120,7 +3164,7 @@ "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/finder/tree/v4.4.37" + "source": "https://github.com/symfony/finder/tree/v4.4.41" }, "funding": [ { @@ -3136,20 +3180,20 @@ "type": "tidelift" } ], - "time": "2022-01-02T09:41:36+00:00" + "time": "2022-04-14T15:36:10+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "30885182c981ab175d4d034db0f6f469898070ab" + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/30885182c981ab175d4d034db0f6f469898070ab", - "reference": "30885182c981ab175d4d034db0f6f469898070ab", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", "shasum": "" }, "require": { @@ -3164,7 +3208,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3202,7 +3246,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.26.0" }, "funding": [ { @@ -3218,20 +3262,20 @@ "type": "tidelift" } ], - "time": "2021-10-20T20:35:02+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-idn", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-idn.git", - "reference": "749045c69efb97c70d25d7463abba812e91f3a44" + "reference": "59a8d271f00dd0e4c2e518104cc7963f655a1aa8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/749045c69efb97c70d25d7463abba812e91f3a44", - "reference": "749045c69efb97c70d25d7463abba812e91f3a44", + "url": "https://api.github.com/repos/symfony/polyfill-intl-idn/zipball/59a8d271f00dd0e4c2e518104cc7963f655a1aa8", + "reference": "59a8d271f00dd0e4c2e518104cc7963f655a1aa8", "shasum": "" }, "require": { @@ -3245,7 +3289,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3289,7 +3333,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-intl-idn/tree/v1.26.0" }, "funding": [ { @@ -3305,20 +3349,20 @@ "type": "tidelift" } ], - "time": "2021-09-14T14:02:44+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8" + "reference": "219aa369ceff116e673852dce47c3a41794c14bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8590a5f561694770bdcd3f9b5c69dde6945028e8", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/219aa369ceff116e673852dce47c3a41794c14bd", + "reference": "219aa369ceff116e673852dce47c3a41794c14bd", "shasum": "" }, "require": { @@ -3330,7 +3374,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3373,7 +3417,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.26.0" }, "funding": [ { @@ -3389,20 +3433,20 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825" + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825", - "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", "shasum": "" }, "require": { @@ -3417,7 +3461,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3456,7 +3500,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.26.0" }, "funding": [ { @@ -3472,20 +3516,20 @@ "type": "tidelift" } ], - "time": "2021-11-30T18:21:41+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c" + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/4407588e0d3f1f52efb65fbe92babe41f37fe50c", - "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace", + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace", "shasum": "" }, "require": { @@ -3494,7 +3538,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -3539,7 +3583,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0" }, "funding": [ { @@ -3555,20 +3599,20 @@ "type": "tidelift" } ], - "time": "2022-03-04T08:16:47+00:00" + "time": "2022-05-10T07:21:04+00:00" }, { "name": "symfony/process", - "version": "v4.4.37", + "version": "v4.4.41", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "b2d924e5a4cb284f293d5092b1dbf0d364cb8b67" + "reference": "9eedd60225506d56e42210a70c21bb80ca8456ce" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/b2d924e5a4cb284f293d5092b1dbf0d364cb8b67", - "reference": "b2d924e5a4cb284f293d5092b1dbf0d364cb8b67", + "url": "https://api.github.com/repos/symfony/process/zipball/9eedd60225506d56e42210a70c21bb80ca8456ce", + "reference": "9eedd60225506d56e42210a70c21bb80ca8456ce", "shasum": "" }, "require": { @@ -3601,7 +3645,7 @@ "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/process/tree/v4.4.37" + "source": "https://github.com/symfony/process/tree/v4.4.41" }, "funding": [ { @@ -3617,26 +3661,26 @@ "type": "tidelift" } ], - "time": "2022-01-27T17:14:04+00:00" + "time": "2022-04-04T10:19:07+00:00" }, { "name": "symfony/service-contracts", - "version": "v2.5.0", + "version": "v2.5.1", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc" + "reference": "24d9dc654b83e91aa59f9d167b131bc3b5bea24c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc", - "reference": "1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/24d9dc654b83e91aa59f9d167b131bc3b5bea24c", + "reference": "24d9dc654b83e91aa59f9d167b131bc3b5bea24c", "shasum": "" }, "require": { "php": ">=7.2.5", "psr/container": "^1.1", - "symfony/deprecation-contracts": "^2.1" + "symfony/deprecation-contracts": "^2.1|^3" }, "conflict": { "ext-psr": "<1.1|>=2" @@ -3684,7 +3728,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v2.5.0" + "source": "https://github.com/symfony/service-contracts/tree/v2.5.1" }, "funding": [ { @@ -3700,7 +3744,7 @@ "type": "tidelift" } ], - "time": "2021-11-04T16:48:04+00:00" + "time": "2022-03-13T20:07:29+00:00" }, { "name": "symfony/yaml", @@ -3825,21 +3869,21 @@ }, { "name": "webmozart/assert", - "version": "1.10.0", + "version": "1.11.0", "source": { "type": "git", "url": "https://github.com/webmozarts/assert.git", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991", "shasum": "" }, "require": { - "php": "^7.2 || ^8.0", - "symfony/polyfill-ctype": "^1.8" + "ext-ctype": "*", + "php": "^7.2 || ^8.0" }, "conflict": { "phpstan/phpstan": "<0.12.20", @@ -3877,9 +3921,9 @@ ], "support": { "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.10.0" + "source": "https://github.com/webmozarts/assert/tree/1.11.0" }, - "time": "2021-03-09T10:59:23+00:00" + "time": "2022-06-03T18:03:27+00:00" } ], "aliases": [], diff --git a/plugins/admin/languages/en.yaml b/plugins/admin/languages/en.yaml index 3d82bcd..87ebb0c 100644 --- a/plugins/admin/languages/en.yaml +++ b/plugins/admin/languages/en.yaml @@ -454,8 +454,11 @@ PLUGIN_ADMIN: IMAGES_DEBUG_HELP: "Show an overlay over images indicating the pixel depth of the image when working with retina for example" IMAGES_LOADING: "Image loading behavior" IMAGES_LOADING_HELP: "The loading attribute allows a browser to defer loading offscreen images and iframes until users scroll near them. loading supports three values: auto, lazy, eager" + + # Removed in Grav 1.8 IMAGES_SEOFRIENDLY: "SEO-Friendly Image names" IMAGES_SEOFRIENDLY_HELP: "When enabled, the image name is displayed first, then a smaller hash to reflect processed operations" + UPLOAD_LIMIT: "File upload limit" UPLOAD_LIMIT_HELP: "Set maximum upload size in bytes (0 is unlimited)" ENABLE_MEDIA_TIMESTAMP: "Enable timestamps on media" @@ -1142,3 +1145,7 @@ PLUGIN_ADMIN: AVATAR: "Avatar Generator" AVATAR_HELP: "Multiavatar is a locally generated avatar. Gravatar is an external service that uses your email address to pull a preconfigured Avatar remotely" AVATAR_HASH: "NOTE: Optional Avatar custom 'hash' string" + IMAGES_TITLE: "Images" + LEGACY_MEDIA_MUTATION: "Legacy Media Manipulation Compatibility" + LEGACY_MEDIA_MUTATION_HELP: "Enable this setting only if image manipulation broke after Grav update." + BACKWARD_COMPATIBILITY: "Backward Compatibility" diff --git a/plugins/admin/themes/grav/app/main.js b/plugins/admin/themes/grav/app/main.js index 820c35d..6edfca9 100644 --- a/plugins/admin/themes/grav/app/main.js +++ b/plugins/admin/themes/grav/app/main.js @@ -4,6 +4,7 @@ import '@babel/polyfill'; import $ from 'jquery'; import './utils/remodal'; import 'simplebar/dist/simplebar.min.js'; +import { UriToMarkdown } from './forms/fields/files.js'; import GPM, { Instance as gpm } from './utils/gpm'; import KeepAlive from './utils/keepalive'; import Updates, { Instance as updates, Notifications, Feed } from './updates'; @@ -68,5 +69,5 @@ export default { Instance: MediaFilterInstance }, Scrollbar: { Scrollbar: { deprecated: true }, Instance: { deprecated: true } }, - Utils: { request, toastr, Cookies } + Utils: { request, toastr, Cookies, UriToMarkdown } }; diff --git a/plugins/admin/themes/grav/js/admin.min.js b/plugins/admin/themes/grav/js/admin.min.js index a5583ba..3da9f86 100644 --- a/plugins/admin/themes/grav/js/admin.min.js +++ b/plugins/admin/themes/grav/js/admin.min.js @@ -711,6 +711,9 @@ var external_jQuery_default = /*#__PURE__*/__webpack_require__.n(external_jQuery }); // EXTERNAL MODULE: ./node_modules/simplebar/dist/simplebar.min.js var simplebar_min = __webpack_require__(85766); +// EXTERNAL MODULE: ./node_modules/dropzone/dist/dropzone.js +var dist_dropzone = __webpack_require__(32025); +var dropzone_default = /*#__PURE__*/__webpack_require__.n(dist_dropzone); // EXTERNAL MODULE: ./node_modules/toastr/toastr.js var toastr = __webpack_require__(8901); var toastr_default = /*#__PURE__*/__webpack_require__.n(toastr); @@ -847,17 +850,517 @@ function userFeedbackError(error) { external_jQuery_default()(__webpack_require__.g).on('beforeunload._ajax', function () { UNLOADING = true; }); +;// CONCATENATED MODULE: ./app/utils/request.js + + +var raw; + +var request = function request(url) { + var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; + var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : function () { + return true; + }; + + if (typeof options === 'function') { + callback = options; + options = {}; + } + + if (options.method && options.method === 'post') { + var data = new FormData(); + options.body = Object.assign({ + 'admin-nonce': external_GravAdmin_namespaceObject.config.admin_nonce + }, options.body || {}); + Object.keys(options.body).map(function (key) { + return data.append(key, options.body[key]); + }); + options.body = data; + } + + options = Object.assign({ + credentials: 'same-origin', + headers: { + 'Accept': 'application/json' + } + }, options); + return fetch(url, options).then(function (response) { + raw = response; + return response; + }).then(parseStatus).then(parseJSON).then(userFeedback).then(function (response) { + return callback(response, raw); + })["catch"](userFeedbackError); +}; + +/* harmony default export */ const utils_request = (request); +;// CONCATENATED MODULE: ./app/forms/fields/files.js +function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + +function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + +function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; } + + + // import EXIF from 'exif-js'; + + + // translations + +var Dictionary = { + dictCancelUpload: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD, + dictCancelUploadConfirmation: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD_CONFIRMATION, + dictDefaultMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_DEFAULT_MESSAGE, + dictFallbackMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_MESSAGE, + dictFallbackText: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_TEXT, + dictFileTooBig: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FILE_TOO_BIG, + dictInvalidFileType: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_INVALID_FILE_TYPE, + dictMaxFilesExceeded: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_MAX_FILES_EXCEEDED, + dictRemoveFile: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_REMOVE_FILE, + dictResponseError: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_RESPONSE_ERROR +}; +(dropzone_default()).autoDiscover = false; +(dropzone_default()).options.gravPageDropzone = {}; + +(dropzone_default()).confirm = function (question, accepted, rejected) { + var doc = external_jQuery_default()(document); + var modalSelector = '[data-remodal-id="delete-media"]'; + + var removeEvents = function removeEvents() { + doc.off('confirmation', modalSelector, accept); + doc.off('cancellation', modalSelector, reject); + external_jQuery_default()(modalSelector).find('.remodal-confirm').removeClass('pointer-events-disabled'); + }; + + var accept = function accept() { + accepted && accepted(); + removeEvents(); + }; + + var reject = function reject() { + rejected && rejected(); + removeEvents(); + }; + + (external_jQuery_default()).remodal.lookup[external_jQuery_default()(modalSelector).data('remodal')].open(); + doc.on('confirmation', modalSelector, accept); + doc.on('cancellation', modalSelector, reject); +}; + +var DropzoneMediaConfig = { + timeout: 0, + thumbnailWidth: 200, + thumbnailHeight: 150, + addRemoveLinks: false, + dictDefaultMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROP_FILES_HERE_TO_UPLOAD.replace(/</g, '<').replace(/>/g, '>'), + dictRemoveFileConfirmation: '[placeholder]', + previewTemplate: "\n
".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_ERROR_UPLOAD, " {{fileName}}
\n").concat(response.message, "") + }); + } + }, { + key: "onDropzoneComplete", + value: function onDropzoneComplete(file) { + if (!file.accepted && !file.rejected) { + var data = { + status: 'error', + message: "".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_UNSUPPORTED, ": ").concat(file.name.match(/\..+/).join('')) + }; + return this.handleError({ + file: file, + data: data, + mode: 'removeFile', + msg: "
".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_ERROR_ADD, " {{fileName}}
\n").concat(data.message, "") + }); + } + + if (this.options.reloadPage) { + __webpack_require__.g.location.reload(); + } + } + }, { + key: "b64_to_utf8", + value: function b64_to_utf8(str) { + str = str.replace(/\s/g, ''); + return decodeURIComponent(escape(window.atob(str))); + } + }, { + key: "onDropzoneAddedFile", + value: function onDropzoneAddedFile(file) { + return this.dropzone.options.addedfile(file); + } + }, { + key: "onDropzoneRemovedFile", + value: function onDropzoneRemovedFile(file) { + var _this5 = this; + + if (!file.accepted || file.rejected) { + return; + } + + var url = file.removeUrl || this.urls["delete"] || this.options.url; + var path = (url || '').match(/path:(.*)\//); + var body = { + filename: file.name, + uri: this.getURI() + }; + + if (file.sessionParams) { + body.task = 'filessessionremove'; + body.session = file.sessionParams; + } + + var customPost = this.container.data('filePostRemove') || {}; + + if (Object.keys(customPost).length) { + body = {}; + Object.keys(customPost).forEach(function (key) { + body[key] = customPost[key]; + }); + } + + body['filename'] = file.name; + body['admin-nonce'] = external_GravAdmin_namespaceObject.config.admin_nonce; + utils_request(url, { + method: 'post', + body: body + }, function () { + if (!path) { + return; + } + + path = _this5.b64_to_utf8(path[1]); + + var input = _this5.container.find('[name][type="hidden"]'); + + var data = JSON.parse(input.val() || '{}'); + delete data[path]; + input.val(JSON.stringify(data)); + }); + } + }, { + key: "onDropzoneError", + value: function onDropzoneError(file, response, xhr) { + var message = xhr ? response.error.message : response; + external_jQuery_default()(file.previewElement).find('[data-dz-errormessage]').html(message); + return this.handleError({ + file: file, + data: { + status: 'error' + }, + msg: "
".concat(message, "") + }); + } + }, { + key: "handleError", + value: function handleError(options) { + var file = options.file, + data = options.data, + mode = options.mode, + msg = options.msg; + + if (data.status !== 'error' && data.status !== 'unauthorized') { + return; + } + + switch (mode) { + case 'addBack': + if (file instanceof File) { + this.dropzone.addFile.call(this.dropzone, file); + } else { + this.dropzone.files.push(file); + this.dropzone.options.addedfile.call(this.dropzone, file); + this.dropzone.options.thumbnail.call(this.dropzone, file, file.extras.url); + } + + break; + + case 'removeFile': + default: + if (~this.dropzone.files.indexOf(file)) { + file.rejected = true; + this.dropzone.removeFile.call(this.dropzone, file, { + silent: true + }); + } + + break; + } + + var modal = external_jQuery_default()('[data-remodal-id="generic"]'); + var cleanName = file.name.replace('<', '<').replace('>', '>'); + modal.find('.error-content').html(msg.replace('{{fileName}}', cleanName)); + (external_jQuery_default()).remodal.lookup[modal.data('remodal')].open(); + } + }]); + + return FilesField; +}(); + + +function UriToMarkdown(uri) { + uri = uri.replace(/@3x|@2x|@1x/, ''); + uri = uri.replace(/\(/g, '%28'); + uri = uri.replace(/\)/g, '%29'); + var title = uri.split('.').slice(0, -1).join('.'); + return uri.match(/\.(jpe?g|png|gif|svg|webp|mp4|webm|ogv|mov)$/i) ? "![".concat(title, "](").concat(uri, " \"").concat(title, "\")") : "[".concat(decodeURI(uri), "](").concat(uri, ")"); +} +var instances = []; +var cache = external_jQuery_default()(); + +var onAddedNodes = function onAddedNodes(event, target +/* , record, instance */ +) { + var files = external_jQuery_default()(target).find('.dropzone.files-upload'); + + if (!files.length) { + return; + } + + files.each(function (index, file) { + file = external_jQuery_default()(file); + + if (!~cache.index(file)) { + addNode(file); + } + }); +}; + +var addNode = function addNode(container) { + container = external_jQuery_default()(container); + var input = container.find('input[type="file"]'); + var settings = container.data('grav-file-settings') || {}; + + if (settings.accept && ~settings.accept.indexOf('*')) { + settings.accept = ['']; + } + + var options = { + url: container.data('file-url-add') || (container.closest('form').attr('action') || external_GravAdmin_namespaceObject.config.current_url) + '.json', + paramName: settings.paramName || 'file', + dotNotation: settings.name || 'file', + acceptedFiles: settings.accept ? settings.accept.join(',') : input.attr('accept') || container.data('media-types'), + maxFilesize: typeof settings.filesize !== 'undefined' ? settings.filesize : 256, + maxFiles: settings.limit || null, + resizeWidth: settings.resizeWidth || null, + resizeHeight: settings.resizeHeight || null, + resizeQuality: settings.resizeQuality || null, + resolution: settings.resolution || null, + accept: function accept(file, done) { + ACCEPT_FUNC(file, done, settings); + } + }; + cache = cache.add(container); + container = container[0]; + instances.push(new FilesField({ + container: container, + options: options + })); +}; + +var Instance = function () { + external_jQuery_default()('.dropzone.files-upload').each(function (i, container) { + return addNode(container); + }); + external_jQuery_default()('body').on('mutation._grav', onAddedNodes); + return instances; +}(); // EXTERNAL MODULE: ./node_modules/events/events.js var events = __webpack_require__(17187); var events_default = /*#__PURE__*/__webpack_require__.n(events); ;// CONCATENATED MODULE: ./app/utils/gpm.js function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); } -function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } +function gpm_classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } -function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } +function gpm_defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } -function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; } +function gpm_createClass(Constructor, protoProps, staticProps) { if (protoProps) gpm_defineProperties(Constructor.prototype, protoProps); if (staticProps) gpm_defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; } function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); } @@ -887,7 +1390,7 @@ var GPM = /*#__PURE__*/function (_EventEmitter) { var action = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'getUpdates'; - _classCallCheck(this, GPM); + gpm_classCallCheck(this, GPM); _this = _super.call(this); _this.payload = {}; @@ -896,7 +1399,7 @@ var GPM = /*#__PURE__*/function (_EventEmitter) { return _this; } - _createClass(GPM, [{ + gpm_createClass(GPM, [{ key: "setPayload", value: function setPayload() { var payload = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; @@ -966,7 +1469,7 @@ var GPM = /*#__PURE__*/function (_EventEmitter) { }((events_default())); -var Instance = new GPM(); +var gpm_Instance = new GPM(); ;// CONCATENATED MODULE: ./app/utils/keepalive.js function keepalive_classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } @@ -1032,48 +1535,6 @@ var KeepAlive = /*#__PURE__*/function () { // EXTERNAL MODULE: ./node_modules/mout/array/unique.js var unique = __webpack_require__(79863); var unique_default = /*#__PURE__*/__webpack_require__.n(unique); -;// CONCATENATED MODULE: ./app/utils/request.js - - -var raw; - -var request = function request(url) { - var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {}; - var callback = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : function () { - return true; - }; - - if (typeof options === 'function') { - callback = options; - options = {}; - } - - if (options.method && options.method === 'post') { - var data = new FormData(); - options.body = Object.assign({ - 'admin-nonce': external_GravAdmin_namespaceObject.config.admin_nonce - }, options.body || {}); - Object.keys(options.body).map(function (key) { - return data.append(key, options.body[key]); - }); - options.body = data; - } - - options = Object.assign({ - credentials: 'same-origin', - headers: { - 'Accept': 'application/json' - } - }, options); - return fetch(url, options).then(function (response) { - raw = response; - return response; - }).then(parseStatus).then(parseJSON).then(userFeedback).then(function (response) { - return callback(response, raw); - })["catch"](userFeedbackError); -}; - -/* harmony default export */ const utils_request = (request); ;// CONCATENATED MODULE: ./app/updates/notifications.js function notifications_classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } @@ -1378,7 +1839,7 @@ external_jQuery_default()(document).on('click', '[data-refresh="feed"]', functio external_jQuery_default()('[data-gpm-checkupdates]').on('click', function () { var element = external_jQuery_default()(this); element.find('i').addClass('fa-spin'); - Instance.fetch(function (response) { + gpm_Instance.fetch(function (response) { element.find('i').removeClass('fa-spin'); var payload = response.payload; @@ -1492,7 +1953,7 @@ var Updates = /*#__PURE__*/function () { var _this = this; var force = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; - Instance.fetch(function (response) { + gpm_Instance.fetch(function (response) { return _this.setPayload(response); }, force); return this; @@ -1639,13 +2100,13 @@ var Updates = /*#__PURE__*/function () { var updates_Instance = new Updates(); // automatically refresh UI for updates (graph, sidebar, plugin/themes pages) after every fetch -Instance.on('fetched', function (response, raw) { +gpm_Instance.on('fetched', function (response, raw) { updates_Instance.setPayload(response.payload || {}); updates_Instance.grav().resources(); }); if (external_GravAdmin_namespaceObject.config.enable_auto_updates_check === '1') { - Instance.fetch(); + gpm_Instance.fetch(); } // EXTERNAL MODULE: ./node_modules/chartist/dist/chartist.js var chartist = __webpack_require__(69259); @@ -1792,7 +2253,7 @@ var UpdatesChart = /*#__PURE__*/function (_Chart) { return _this2.draw(data); }); - Instance.on('fetched', function (response) { + gpm_Instance.on('fetched', function (response) { if (!response.payload) { return; } @@ -2803,467 +3264,6 @@ var factory = function factory(window) { __webpack_require__.g.Cookies = __webpack_require__.g && cookies_typeof(__webpack_require__.g.document) === 'object' ? factory(__webpack_require__.g) : factory; /* harmony default export */ const cookies = (__webpack_require__.g.Cookies); -// EXTERNAL MODULE: ./node_modules/dropzone/dist/dropzone.js -var dist_dropzone = __webpack_require__(32025); -var dropzone_default = /*#__PURE__*/__webpack_require__.n(dist_dropzone); -;// CONCATENATED MODULE: ./app/forms/fields/files.js -function files_classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } - -function files_defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } - -function files_createClass(Constructor, protoProps, staticProps) { if (protoProps) files_defineProperties(Constructor.prototype, protoProps); if (staticProps) files_defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; } - - - // import EXIF from 'exif-js'; - - - // translations - -var Dictionary = { - dictCancelUpload: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD, - dictCancelUploadConfirmation: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_CANCEL_UPLOAD_CONFIRMATION, - dictDefaultMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_DEFAULT_MESSAGE, - dictFallbackMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_MESSAGE, - dictFallbackText: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FALLBACK_TEXT, - dictFileTooBig: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_FILE_TOO_BIG, - dictInvalidFileType: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_INVALID_FILE_TYPE, - dictMaxFilesExceeded: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_MAX_FILES_EXCEEDED, - dictRemoveFile: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_REMOVE_FILE, - dictResponseError: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROPZONE_RESPONSE_ERROR -}; -(dropzone_default()).autoDiscover = false; -(dropzone_default()).options.gravPageDropzone = {}; - -(dropzone_default()).confirm = function (question, accepted, rejected) { - var doc = external_jQuery_default()(document); - var modalSelector = '[data-remodal-id="delete-media"]'; - - var removeEvents = function removeEvents() { - doc.off('confirmation', modalSelector, accept); - doc.off('cancellation', modalSelector, reject); - external_jQuery_default()(modalSelector).find('.remodal-confirm').removeClass('pointer-events-disabled'); - }; - - var accept = function accept() { - accepted && accepted(); - removeEvents(); - }; - - var reject = function reject() { - rejected && rejected(); - removeEvents(); - }; - - (external_jQuery_default()).remodal.lookup[external_jQuery_default()(modalSelector).data('remodal')].open(); - doc.on('confirmation', modalSelector, accept); - doc.on('cancellation', modalSelector, reject); -}; - -var DropzoneMediaConfig = { - timeout: 0, - thumbnailWidth: 200, - thumbnailHeight: 150, - addRemoveLinks: false, - dictDefaultMessage: external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.DROP_FILES_HERE_TO_UPLOAD.replace(/</g, '<').replace(/>/g, '>'), - dictRemoveFileConfirmation: '[placeholder]', - previewTemplate: "\n
".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_ERROR_UPLOAD, " {{fileName}}
\n").concat(response.message, "") - }); - } - }, { - key: "onDropzoneComplete", - value: function onDropzoneComplete(file) { - if (!file.accepted && !file.rejected) { - var data = { - status: 'error', - message: "".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_UNSUPPORTED, ": ").concat(file.name.match(/\..+/).join('')) - }; - return this.handleError({ - file: file, - data: data, - mode: 'removeFile', - msg: "
".concat(external_GravAdmin_namespaceObject.translations.PLUGIN_ADMIN.FILE_ERROR_ADD, " {{fileName}}
\n").concat(data.message, "") - }); - } - - if (this.options.reloadPage) { - __webpack_require__.g.location.reload(); - } - } - }, { - key: "b64_to_utf8", - value: function b64_to_utf8(str) { - str = str.replace(/\s/g, ''); - return decodeURIComponent(escape(window.atob(str))); - } - }, { - key: "onDropzoneAddedFile", - value: function onDropzoneAddedFile(file) { - return this.dropzone.options.addedfile(file); - } - }, { - key: "onDropzoneRemovedFile", - value: function onDropzoneRemovedFile(file) { - var _this5 = this; - - if (!file.accepted || file.rejected) { - return; - } - - var url = file.removeUrl || this.urls["delete"] || this.options.url; - var path = (url || '').match(/path:(.*)\//); - var body = { - filename: file.name, - uri: this.getURI() - }; - - if (file.sessionParams) { - body.task = 'filessessionremove'; - body.session = file.sessionParams; - } - - var customPost = this.container.data('filePostRemove') || {}; - - if (Object.keys(customPost).length) { - body = {}; - Object.keys(customPost).forEach(function (key) { - body[key] = customPost[key]; - }); - } - - body['filename'] = file.name; - body['admin-nonce'] = external_GravAdmin_namespaceObject.config.admin_nonce; - utils_request(url, { - method: 'post', - body: body - }, function () { - if (!path) { - return; - } - - path = _this5.b64_to_utf8(path[1]); - - var input = _this5.container.find('[name][type="hidden"]'); - - var data = JSON.parse(input.val() || '{}'); - delete data[path]; - input.val(JSON.stringify(data)); - }); - } - }, { - key: "onDropzoneError", - value: function onDropzoneError(file, response, xhr) { - var message = xhr ? response.error.message : response; - external_jQuery_default()(file.previewElement).find('[data-dz-errormessage]').html(message); - return this.handleError({ - file: file, - data: { - status: 'error' - }, - msg: "
".concat(message, "") - }); - } - }, { - key: "handleError", - value: function handleError(options) { - var file = options.file, - data = options.data, - mode = options.mode, - msg = options.msg; - - if (data.status !== 'error' && data.status !== 'unauthorized') { - return; - } - - switch (mode) { - case 'addBack': - if (file instanceof File) { - this.dropzone.addFile.call(this.dropzone, file); - } else { - this.dropzone.files.push(file); - this.dropzone.options.addedfile.call(this.dropzone, file); - this.dropzone.options.thumbnail.call(this.dropzone, file, file.extras.url); - } - - break; - - case 'removeFile': - default: - if (~this.dropzone.files.indexOf(file)) { - file.rejected = true; - this.dropzone.removeFile.call(this.dropzone, file, { - silent: true - }); - } - - break; - } - - var modal = external_jQuery_default()('[data-remodal-id="generic"]'); - var cleanName = file.name.replace('<', '<').replace('>', '>'); - modal.find('.error-content').html(msg.replace('{{fileName}}', cleanName)); - (external_jQuery_default()).remodal.lookup[modal.data('remodal')].open(); - } - }]); - - return FilesField; -}(); - - -function UriToMarkdown(uri) { - uri = uri.replace(/@3x|@2x|@1x/, ''); - uri = uri.replace(/\(/g, '%28'); - uri = uri.replace(/\)/g, '%29'); - var title = uri.split('.').slice(0, -1).join('.'); - return uri.match(/\.(jpe?g|png|gif|svg|webp|mp4|webm|ogv|mov)$/i) ? "![".concat(title, "](").concat(uri, " \"").concat(title, "\")") : "[".concat(decodeURI(uri), "](").concat(uri, ")"); -} -var instances = []; -var cache = external_jQuery_default()(); - -var onAddedNodes = function onAddedNodes(event, target -/* , record, instance */ -) { - var files = external_jQuery_default()(target).find('.dropzone.files-upload'); - - if (!files.length) { - return; - } - - files.each(function (index, file) { - file = external_jQuery_default()(file); - - if (!~cache.index(file)) { - addNode(file); - } - }); -}; - -var addNode = function addNode(container) { - container = external_jQuery_default()(container); - var input = container.find('input[type="file"]'); - var settings = container.data('grav-file-settings') || {}; - - if (settings.accept && ~settings.accept.indexOf('*')) { - settings.accept = ['']; - } - - var options = { - url: container.data('file-url-add') || (container.closest('form').attr('action') || external_GravAdmin_namespaceObject.config.current_url) + '.json', - paramName: settings.paramName || 'file', - dotNotation: settings.name || 'file', - acceptedFiles: settings.accept ? settings.accept.join(',') : input.attr('accept') || container.data('media-types'), - maxFilesize: typeof settings.filesize !== 'undefined' ? settings.filesize : 256, - maxFiles: settings.limit || null, - resizeWidth: settings.resizeWidth || null, - resizeHeight: settings.resizeHeight || null, - resizeQuality: settings.resizeQuality || null, - resolution: settings.resolution || null, - accept: function accept(file, done) { - ACCEPT_FUNC(file, done, settings); - } - }; - cache = cache.add(container); - container = container[0]; - instances.push(new FilesField({ - container: container, - options: options - })); -}; - -var files_Instance = function () { - external_jQuery_default()('.dropzone.files-upload').each(function (i, container) { - return addNode(container); - }); - external_jQuery_default()('body').on('mutation._grav', onAddedNodes); - return instances; -}(); ;// CONCATENATED MODULE: ./app/forms/fields/editor/buttons.js @@ -9751,7 +9751,7 @@ external_jQuery_default()('[data-grav-elements] select').trigger('change'); }, FilesField: { FilesField: FilesField, - Instance: files_Instance + Instance: Instance }, FolderField: { Regenerate: fields_folder @@ -10119,7 +10119,7 @@ var Packages = /*#__PURE__*/function () { var current_version = ''; var available_version = ''; var _name = ''; - var resources = Instance.payload.payload.resources; + var resources = gpm_Instance.payload.payload.resources; if (resources.plugins[slug]) { available_version = resources.plugins[slug].available; @@ -10314,7 +10314,7 @@ var Packages = /*#__PURE__*/function () { var current_version = ''; var available_version = ''; var _name2 = ''; - var resources = Instance.payload.payload.resources; + var resources = gpm_Instance.payload.payload.resources; if (resources.plugins[slug]) { available_version = resources.plugins[slug].available; @@ -11799,6 +11799,7 @@ var sidebar_Instance = new Sidebar(); + // bootstrap jQuery extensions @@ -11823,7 +11824,7 @@ external_jQuery_default()(__webpack_require__.g).on('sidebar_state._grav', funct /* harmony default export */ const main = ({ GPM: { GPM: GPM, - Instance: Instance + Instance: gpm_Instance }, KeepAlive: keepalive, Dashboard: dashboard, @@ -11854,7 +11855,8 @@ external_jQuery_default()(__webpack_require__.g).on('sidebar_state._grav', funct Utils: { request: utils_request, toastr: utils_toastr, - Cookies: cookies + Cookies: cookies, + UriToMarkdown: UriToMarkdown } }); diff --git a/plugins/admin/themes/grav/templates/partials/dashboard-pages.html.twig b/plugins/admin/themes/grav/templates/partials/dashboard-pages.html.twig index 7f3b492..501e211 100644 --- a/plugins/admin/themes/grav/templates/partials/dashboard-pages.html.twig +++ b/plugins/admin/themes/grav/templates/partials/dashboard-pages.html.twig @@ -1,4 +1,4 @@ -{% if authorize(['admin.pages', 'admin.super']) %} +{% if authorize(['admin.pages.list', 'admin.pages', 'admin.super']) %}
+ Hi, +
++ You have been invited to join {{ site_name }}. +
++ {{ message }} +
+
+
+ Create Your Account Now
+
+
+
+ Alternatively, copy the following URL into your browser's address bar: +
++ {{ login_link }} +
+
+
+ Kind regards,
+
+
+ {{ actor.fullname }}
+