From 0c880def5e99ae339a8cc03e1d753fce70231b66 Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Sun, 18 Apr 2021 22:12:26 +0100 Subject: [PATCH 1/5] Fixed response JSON detection when charset existed Fixes #2684 --- resources/js/services/http.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/js/services/http.js b/resources/js/services/http.js index b05dd23bf..00865e69b 100644 --- a/resources/js/services/http.js +++ b/resources/js/services/http.js @@ -149,8 +149,8 @@ async function getResponseContent(response) { return null; } - const responseContentType = response.headers.get('Content-Type'); - const subType = responseContentType.split('/').pop(); + const responseContentType = response.headers.get('Content-Type') || ''; + const subType = responseContentType.split(';')[0].split('/').pop(); if (subType === 'javascript' || subType === 'json') { return await response.json(); From 60ffe6a993b6ef3c241966a94d1d23b5324f3e8b Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Mon, 19 Apr 2021 20:16:49 +0100 Subject: [PATCH 2/5] Updated packages and added better upload failure logging To fix #2689 Updates all packages but mainly focused on aws-sdk --- app/Uploads/AttachmentService.php | 1 + app/Uploads/ImageService.php | 1 + composer.lock | 466 ++++++++++++++++-------------- 3 files changed, 255 insertions(+), 213 deletions(-) diff --git a/app/Uploads/AttachmentService.php b/app/Uploads/AttachmentService.php index b14f49473..4437897c7 100644 --- a/app/Uploads/AttachmentService.php +++ b/app/Uploads/AttachmentService.php @@ -202,6 +202,7 @@ class AttachmentService try { $storage->put($attachmentPath, $attachmentData); } catch (Exception $e) { + \Log::error('Error when attempting file upload:' . $e->getMessage()); throw new FileUploadException(trans('errors.path_not_writable', ['filePath' => $attachmentPath])); } diff --git a/app/Uploads/ImageService.php b/app/Uploads/ImageService.php index 02fe2e8ef..010b531f1 100644 --- a/app/Uploads/ImageService.php +++ b/app/Uploads/ImageService.php @@ -109,6 +109,7 @@ class ImageService $storage->put($fullPath, $imageData); $storage->setVisibility($fullPath, 'public'); } catch (Exception $e) { + \Log::error('Error when attempting image upload:' . $e->getMessage()); throw new ImageUploadException(trans('errors.path_not_writable', ['filePath' => $fullPath])); } diff --git a/composer.lock b/composer.lock index 0a14f0d77..52e0aab74 100644 --- a/composer.lock +++ b/composer.lock @@ -8,16 +8,16 @@ "packages": [ { "name": "aws/aws-sdk-php", - "version": "3.175.0", + "version": "3.178.6", "source": { "type": "git", "url": "https://github.com/aws/aws-sdk-php.git", - "reference": "31baa9e0c4330f01eb74b8a7ef086e9d34f8391e" + "reference": "0aa83b522d5ffa794c02e7411af87a0e241a3082" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/31baa9e0c4330f01eb74b8a7ef086e9d34f8391e", - "reference": "31baa9e0c4330f01eb74b8a7ef086e9d34f8391e", + "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/0aa83b522d5ffa794c02e7411af87a0e241a3082", + "reference": "0aa83b522d5ffa794c02e7411af87a0e241a3082", "shasum": "" }, "require": { @@ -92,9 +92,9 @@ "support": { "forum": "https://forums.aws.amazon.com/forum.jspa?forumID=80", "issues": "https://github.com/aws/aws-sdk-php/issues", - "source": "https://github.com/aws/aws-sdk-php/tree/3.175.0" + "source": "https://github.com/aws/aws-sdk-php/tree/3.178.6" }, - "time": "2021-03-19T18:13:22+00:00" + "time": "2021-04-19T18:13:17+00:00" }, { "name": "barryvdh/laravel-dompdf", @@ -329,32 +329,33 @@ }, { "name": "doctrine/dbal", - "version": "2.12.1", + "version": "2.13.1", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "adce7a954a1c2f14f85e94aed90c8489af204086" + "reference": "c800380457948e65bbd30ba92cc17cda108bf8c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/adce7a954a1c2f14f85e94aed90c8489af204086", - "reference": "adce7a954a1c2f14f85e94aed90c8489af204086", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/c800380457948e65bbd30ba92cc17cda108bf8c9", + "reference": "c800380457948e65bbd30ba92cc17cda108bf8c9", "shasum": "" }, "require": { "doctrine/cache": "^1.0", + "doctrine/deprecations": "^0.5.3", "doctrine/event-manager": "^1.0", "ext-pdo": "*", - "php": "^7.3 || ^8" + "php": "^7.1 || ^8" }, "require-dev": { - "doctrine/coding-standard": "^8.1", - "jetbrains/phpstorm-stubs": "^2019.1", - "phpstan/phpstan": "^0.12.40", - "phpunit/phpunit": "^9.4", - "psalm/plugin-phpunit": "^0.10.0", + "doctrine/coding-standard": "8.2.0", + "jetbrains/phpstorm-stubs": "2020.2", + "phpstan/phpstan": "0.12.81", + "phpunit/phpunit": "^7.5.20|^8.5|9.5.0", + "squizlabs/php_codesniffer": "3.6.0", "symfony/console": "^2.0.5|^3.0|^4.0|^5.0", - "vimeo/psalm": "^3.17.2" + "vimeo/psalm": "4.6.4" }, "suggest": { "symfony/console": "For helpful console commands such as SQL execution and import of files." @@ -363,11 +364,6 @@ "bin/doctrine-dbal" ], "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.0.x-dev" - } - }, "autoload": { "psr-4": { "Doctrine\\DBAL\\": "lib/Doctrine/DBAL" @@ -420,7 +416,7 @@ ], "support": { "issues": "https://github.com/doctrine/dbal/issues", - "source": "https://github.com/doctrine/dbal/tree/2.12.1" + "source": "https://github.com/doctrine/dbal/tree/2.13.1" }, "funding": [ { @@ -436,7 +432,50 @@ "type": "tidelift" } ], - "time": "2020-11-14T20:26:58+00:00" + "time": "2021-04-17T17:30:19+00:00" + }, + { + "name": "doctrine/deprecations", + "version": "v0.5.3", + "source": { + "type": "git", + "url": "https://github.com/doctrine/deprecations.git", + "reference": "9504165960a1f83cc1480e2be1dd0a0478561314" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/9504165960a1f83cc1480e2be1dd0a0478561314", + "reference": "9504165960a1f83cc1480e2be1dd0a0478561314", + "shasum": "" + }, + "require": { + "php": "^7.1|^8.0" + }, + "require-dev": { + "doctrine/coding-standard": "^6.0|^7.0|^8.0", + "phpunit/phpunit": "^7.0|^8.0|^9.0", + "psr/log": "^1.0" + }, + "suggest": { + "psr/log": "Allows logging deprecations via PSR-3 logger implementation" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A small layer on top of trigger_error(E_USER_DEPRECATED) or PSR-3 logging with options to disable all deprecations or selectively for packages.", + "homepage": "https://www.doctrine-project.org/", + "support": { + "issues": "https://github.com/doctrine/deprecations/issues", + "source": "https://github.com/doctrine/deprecations/tree/v0.5.3" + }, + "time": "2021-03-21T12:59:47+00:00" }, { "name": "doctrine/event-manager", @@ -913,16 +952,16 @@ }, { "name": "facade/flare-client-php", - "version": "1.4.0", + "version": "1.7.0", "source": { "type": "git", "url": "https://github.com/facade/flare-client-php.git", - "reference": "ef0f5bce23b30b32d98fd9bb49c6fa37b40eb546" + "reference": "6bf380035890cb0a09b9628c491ae3866b858522" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/facade/flare-client-php/zipball/ef0f5bce23b30b32d98fd9bb49c6fa37b40eb546", - "reference": "ef0f5bce23b30b32d98fd9bb49c6fa37b40eb546", + "url": "https://api.github.com/repos/facade/flare-client-php/zipball/6bf380035890cb0a09b9628c491ae3866b858522", + "reference": "6bf380035890cb0a09b9628c491ae3866b858522", "shasum": "" }, "require": { @@ -966,7 +1005,7 @@ ], "support": { "issues": "https://github.com/facade/flare-client-php/issues", - "source": "https://github.com/facade/flare-client-php/tree/1.4.0" + "source": "https://github.com/facade/flare-client-php/tree/1.7.0" }, "funding": [ { @@ -974,7 +1013,7 @@ "type": "github" } ], - "time": "2021-02-16T12:42:06+00:00" + "time": "2021-04-12T09:30:36+00:00" }, { "name": "facade/ignition", @@ -1165,16 +1204,16 @@ }, { "name": "filp/whoops", - "version": "2.11.0", + "version": "2.12.0", "source": { "type": "git", "url": "https://github.com/filp/whoops.git", - "reference": "f6e14679f948d8a5cfb866fa7065a30c66bd64d3" + "reference": "d501fd2658d55491a2295ff600ae5978eaad7403" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/filp/whoops/zipball/f6e14679f948d8a5cfb866fa7065a30c66bd64d3", - "reference": "f6e14679f948d8a5cfb866fa7065a30c66bd64d3", + "url": "https://api.github.com/repos/filp/whoops/zipball/d501fd2658d55491a2295ff600ae5978eaad7403", + "reference": "d501fd2658d55491a2295ff600ae5978eaad7403", "shasum": "" }, "require": { @@ -1224,7 +1263,7 @@ ], "support": { "issues": "https://github.com/filp/whoops/issues", - "source": "https://github.com/filp/whoops/tree/2.11.0" + "source": "https://github.com/filp/whoops/tree/2.12.0" }, "funding": [ { @@ -1232,26 +1271,26 @@ "type": "github" } ], - "time": "2021-03-19T12:00:00+00:00" + "time": "2021-03-30T12:00:00+00:00" }, { "name": "guzzlehttp/guzzle", - "version": "7.2.0", + "version": "7.3.0", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79" + "reference": "7008573787b430c1c1f650e3722d9bba59967628" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/0aa74dfb41ae110835923ef10a9d803a22d50e79", - "reference": "0aa74dfb41ae110835923ef10a9d803a22d50e79", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/7008573787b430c1c1f650e3722d9bba59967628", + "reference": "7008573787b430c1c1f650e3722d9bba59967628", "shasum": "" }, "require": { "ext-json": "*", "guzzlehttp/promises": "^1.4", - "guzzlehttp/psr7": "^1.7", + "guzzlehttp/psr7": "^1.7 || ^2.0", "php": "^7.2.5 || ^8.0", "psr/http-client": "^1.0" }, @@ -1259,6 +1298,7 @@ "psr/http-client-implementation": "1.0" }, "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", "ext-curl": "*", "php-http/client-integration-tests": "^3.0", "phpunit/phpunit": "^8.5.5 || ^9.3.5", @@ -1272,7 +1312,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.1-dev" + "dev-master": "7.3-dev" } }, "autoload": { @@ -1314,7 +1354,7 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/7.2.0" + "source": "https://github.com/guzzle/guzzle/tree/7.3.0" }, "funding": [ { @@ -1334,7 +1374,7 @@ "type": "github" } ], - "time": "2020-10-10T11:47:56+00:00" + "time": "2021-03-23T11:33:13+00:00" }, { "name": "guzzlehttp/promises", @@ -1393,16 +1433,16 @@ }, { "name": "guzzlehttp/psr7", - "version": "1.7.0", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3" + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/53330f47520498c0ae1f61f7e2c90f55690c06a3", - "reference": "53330f47520498c0ae1f61f7e2c90f55690c06a3", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/35ea11d335fd638b5882ff1725228b3d35496ab1", + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1", "shasum": "" }, "require": { @@ -1462,9 +1502,9 @@ ], "support": { "issues": "https://github.com/guzzle/psr7/issues", - "source": "https://github.com/guzzle/psr7/tree/1.7.0" + "source": "https://github.com/guzzle/psr7/tree/1.8.1" }, - "time": "2020-09-30T07:37:11+00:00" + "time": "2021-03-21T16:25:00+00:00" }, { "name": "intervention/image", @@ -1612,16 +1652,16 @@ }, { "name": "laravel/framework", - "version": "v6.20.19", + "version": "v6.20.23", "source": { "type": "git", "url": "https://github.com/laravel/framework.git", - "reference": "c25308a00c7bbd38401a6254ab403146da9cfd69" + "reference": "d94c07d72c14f07e7d2027458e7f0a76f9ceb0d9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/framework/zipball/c25308a00c7bbd38401a6254ab403146da9cfd69", - "reference": "c25308a00c7bbd38401a6254ab403146da9cfd69", + "url": "https://api.github.com/repos/laravel/framework/zipball/d94c07d72c14f07e7d2027458e7f0a76f9ceb0d9", + "reference": "d94c07d72c14f07e7d2027458e7f0a76f9ceb0d9", "shasum": "" }, "require": { @@ -1761,20 +1801,20 @@ "issues": "https://github.com/laravel/framework/issues", "source": "https://github.com/laravel/framework" }, - "time": "2021-03-16T14:18:55+00:00" + "time": "2021-04-13T13:49:28+00:00" }, { "name": "laravel/socialite", - "version": "v5.2.2", + "version": "v5.2.3", "source": { "type": "git", "url": "https://github.com/laravel/socialite.git", - "reference": "8d25d574b4f2005411c0b9cb527ef5e745c1b07d" + "reference": "1960802068f81e44b2ae9793932181cf1cb91b5c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laravel/socialite/zipball/8d25d574b4f2005411c0b9cb527ef5e745c1b07d", - "reference": "8d25d574b4f2005411c0b9cb527ef5e745c1b07d", + "url": "https://api.github.com/repos/laravel/socialite/zipball/1960802068f81e44b2ae9793932181cf1cb91b5c", + "reference": "1960802068f81e44b2ae9793932181cf1cb91b5c", "shasum": "" }, "require": { @@ -1830,20 +1870,20 @@ "issues": "https://github.com/laravel/socialite/issues", "source": "https://github.com/laravel/socialite" }, - "time": "2021-03-02T16:50:47+00:00" + "time": "2021-04-06T14:38:16+00:00" }, { "name": "league/commonmark", - "version": "1.5.7", + "version": "1.5.8", "source": { "type": "git", "url": "https://github.com/thephpleague/commonmark.git", - "reference": "11df9b36fd4f1d2b727a73bf14931d81373b9a54" + "reference": "08fa59b8e4e34ea8a773d55139ae9ac0e0aecbaf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/commonmark/zipball/11df9b36fd4f1d2b727a73bf14931d81373b9a54", - "reference": "11df9b36fd4f1d2b727a73bf14931d81373b9a54", + "url": "https://api.github.com/repos/thephpleague/commonmark/zipball/08fa59b8e4e34ea8a773d55139ae9ac0e0aecbaf", + "reference": "08fa59b8e4e34ea8a773d55139ae9ac0e0aecbaf", "shasum": "" }, "require": { @@ -1931,7 +1971,7 @@ "type": "tidelift" } ], - "time": "2020-10-31T13:49:32+00:00" + "time": "2021-03-28T18:51:39+00:00" }, { "name": "league/flysystem", @@ -2598,16 +2638,16 @@ }, { "name": "opis/closure", - "version": "3.6.1", + "version": "3.6.2", "source": { "type": "git", "url": "https://github.com/opis/closure.git", - "reference": "943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5" + "reference": "06e2ebd25f2869e54a306dda991f7db58066f7f6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opis/closure/zipball/943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5", - "reference": "943b5d70cc5ae7483f6aff6ff43d7e34592ca0f5", + "url": "https://api.github.com/repos/opis/closure/zipball/06e2ebd25f2869e54a306dda991f7db58066f7f6", + "reference": "06e2ebd25f2869e54a306dda991f7db58066f7f6", "shasum": "" }, "require": { @@ -2657,9 +2697,9 @@ ], "support": { "issues": "https://github.com/opis/closure/issues", - "source": "https://github.com/opis/closure/tree/3.6.1" + "source": "https://github.com/opis/closure/tree/3.6.2" }, - "time": "2020-11-07T02:01:34+00:00" + "time": "2021-04-09T13:42:10+00:00" }, { "name": "paragonie/random_compat", @@ -2969,23 +3009,22 @@ }, { "name": "predis/predis", - "version": "v1.1.6", + "version": "v1.1.7", "source": { "type": "git", "url": "https://github.com/predis/predis.git", - "reference": "9930e933c67446962997b05201c69c2319bf26de" + "reference": "b240daa106d4e02f0c5b7079b41e31ddf66fddf8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/predis/predis/zipball/9930e933c67446962997b05201c69c2319bf26de", - "reference": "9930e933c67446962997b05201c69c2319bf26de", + "url": "https://api.github.com/repos/predis/predis/zipball/b240daa106d4e02f0c5b7079b41e31ddf66fddf8", + "reference": "b240daa106d4e02f0c5b7079b41e31ddf66fddf8", "shasum": "" }, "require": { "php": ">=5.3.9" }, "require-dev": { - "cweagans/composer-patches": "^1.6", "phpunit/phpunit": "~4.8" }, "suggest": { @@ -2993,18 +3032,6 @@ "ext-phpiredis": "Allows faster serialization and deserialization of the Redis protocol" }, "type": "library", - "extra": { - "composer-exit-on-patch-failure": true, - "patches": { - "phpunit/phpunit-mock-objects": { - "Fix PHP 7 and 8 compatibility": "./tests/phpunit_mock_objects.patch" - }, - "phpunit/phpunit": { - "Fix PHP 7 compatibility": "./tests/phpunit_php7.patch", - "Fix PHP 8 compatibility": "./tests/phpunit_php8.patch" - } - } - }, "autoload": { "psr-4": { "Predis\\": "src/" @@ -3036,7 +3063,7 @@ ], "support": { "issues": "https://github.com/predis/predis/issues", - "source": "https://github.com/predis/predis/tree/v1.1.6" + "source": "https://github.com/predis/predis/tree/v1.1.7" }, "funding": [ { @@ -3044,7 +3071,7 @@ "type": "github" } ], - "time": "2020-09-11T19:18:05+00:00" + "time": "2021-04-04T19:34:46+00:00" }, { "name": "psr/container", @@ -3837,21 +3864,21 @@ }, { "name": "socialiteproviders/slack", - "version": "4.1.0", + "version": "4.1.1", "source": { "type": "git", "url": "https://github.com/SocialiteProviders/Slack.git", - "reference": "8efb25c71d98bedf4010a829d1e41ff9fe449bcc" + "reference": "2b781c95daf06ec87a8f3deba2ab613d6bea5e8d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/SocialiteProviders/Slack/zipball/8efb25c71d98bedf4010a829d1e41ff9fe449bcc", - "reference": "8efb25c71d98bedf4010a829d1e41ff9fe449bcc", + "url": "https://api.github.com/repos/SocialiteProviders/Slack/zipball/2b781c95daf06ec87a8f3deba2ab613d6bea5e8d", + "reference": "2b781c95daf06ec87a8f3deba2ab613d6bea5e8d", "shasum": "" }, "require": { "ext-json": "*", - "php": "^7.2|^8.0", + "php": "^7.2 || ^8.0", "socialiteproviders/manager": "~4.0" }, "type": "library", @@ -3872,9 +3899,9 @@ ], "description": "Slack OAuth2 Provider for Laravel Socialite", "support": { - "source": "https://github.com/SocialiteProviders/Slack/tree/4.1.0" + "source": "https://github.com/SocialiteProviders/Slack/tree/4.1.1" }, - "time": "2020-11-26T17:57:15+00:00" + "time": "2021-03-26T04:10:10+00:00" }, { "name": "socialiteproviders/twitch", @@ -4046,16 +4073,16 @@ }, { "name": "symfony/console", - "version": "v4.4.20", + "version": "v4.4.21", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "c98349bda966c70d6c08b4cd8658377c94166492" + "reference": "1ba4560dbbb9fcf5ae28b61f71f49c678086cf23" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/c98349bda966c70d6c08b4cd8658377c94166492", - "reference": "c98349bda966c70d6c08b4cd8658377c94166492", + "url": "https://api.github.com/repos/symfony/console/zipball/1ba4560dbbb9fcf5ae28b61f71f49c678086cf23", + "reference": "1ba4560dbbb9fcf5ae28b61f71f49c678086cf23", "shasum": "" }, "require": { @@ -4115,7 +4142,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.20" + "source": "https://github.com/symfony/console/tree/v4.4.21" }, "funding": [ { @@ -4131,7 +4158,7 @@ "type": "tidelift" } ], - "time": "2021-02-22T18:44:15+00:00" + "time": "2021-03-26T09:23:24+00:00" }, { "name": "symfony/css-selector", @@ -4269,16 +4296,16 @@ }, { "name": "symfony/deprecation-contracts", - "version": "v2.2.0", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "5fa56b4074d1ae755beb55617ddafe6f5d78f665" + "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5fa56b4074d1ae755beb55617ddafe6f5d78f665", - "reference": "5fa56b4074d1ae755beb55617ddafe6f5d78f665", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", + "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", "shasum": "" }, "require": { @@ -4287,7 +4314,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.2-dev" + "dev-main": "2.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -4316,7 +4343,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/master" + "source": "https://github.com/symfony/deprecation-contracts/tree/v2.4.0" }, "funding": [ { @@ -4332,20 +4359,20 @@ "type": "tidelift" } ], - "time": "2020-09-07T11:33:47+00:00" + "time": "2021-03-23T23:28:01+00:00" }, { "name": "symfony/error-handler", - "version": "v4.4.20", + "version": "v4.4.21", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "a191550d46b73a527b9d244f185fef439d41cf15" + "reference": "48e81a375525872e788c2418430f54150d935810" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/a191550d46b73a527b9d244f185fef439d41cf15", - "reference": "a191550d46b73a527b9d244f185fef439d41cf15", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/48e81a375525872e788c2418430f54150d935810", + "reference": "48e81a375525872e788c2418430f54150d935810", "shasum": "" }, "require": { @@ -4385,7 +4412,7 @@ "description": "Provides tools to manage errors and ease debugging PHP code", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/error-handler/tree/v4.4.20" + "source": "https://github.com/symfony/error-handler/tree/v4.4.21" }, "funding": [ { @@ -4401,7 +4428,7 @@ "type": "tidelift" } ], - "time": "2021-02-11T08:19:35+00:00" + "time": "2021-03-08T10:28:40+00:00" }, { "name": "symfony/event-dispatcher", @@ -4628,16 +4655,16 @@ }, { "name": "symfony/http-client-contracts", - "version": "v2.3.1", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/symfony/http-client-contracts.git", - "reference": "41db680a15018f9c1d4b23516059633ce280ca33" + "reference": "7e82f6084d7cae521a75ef2cb5c9457bbda785f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/41db680a15018f9c1d4b23516059633ce280ca33", - "reference": "41db680a15018f9c1d4b23516059633ce280ca33", + "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/7e82f6084d7cae521a75ef2cb5c9457bbda785f4", + "reference": "7e82f6084d7cae521a75ef2cb5c9457bbda785f4", "shasum": "" }, "require": { @@ -4648,9 +4675,8 @@ }, "type": "library", "extra": { - "branch-version": "2.3", "branch-alias": { - "dev-main": "2.3-dev" + "dev-main": "2.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -4687,7 +4713,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/http-client-contracts/tree/v2.3.1" + "source": "https://github.com/symfony/http-client-contracts/tree/v2.4.0" }, "funding": [ { @@ -4703,7 +4729,7 @@ "type": "tidelift" } ], - "time": "2020-10-14T17:08:19+00:00" + "time": "2021-04-11T23:07:08+00:00" }, { "name": "symfony/http-foundation", @@ -4775,16 +4801,16 @@ }, { "name": "symfony/http-kernel", - "version": "v4.4.20", + "version": "v4.4.21", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "4f36548465489f293b05406f1770492f6efb8adb" + "reference": "0248214120d00c5f44f1cd5d9ad65f0b38459333" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/4f36548465489f293b05406f1770492f6efb8adb", - "reference": "4f36548465489f293b05406f1770492f6efb8adb", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/0248214120d00c5f44f1cd5d9ad65f0b38459333", + "reference": "0248214120d00c5f44f1cd5d9ad65f0b38459333", "shasum": "" }, "require": { @@ -4859,7 +4885,7 @@ "description": "Provides a structured process for converting a Request into a Response", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-kernel/tree/v4.4.20" + "source": "https://github.com/symfony/http-kernel/tree/v4.4.21" }, "funding": [ { @@ -4875,20 +4901,20 @@ "type": "tidelift" } ], - "time": "2021-03-04T18:00:27+00:00" + "time": "2021-03-29T05:11:04+00:00" }, { "name": "symfony/mime", - "version": "v5.2.5", + "version": "v5.2.6", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "554ba128f1955038b45db5e1fa7e93bfc683b139" + "reference": "1b2092244374cbe48ae733673f2ca0818b37197b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/554ba128f1955038b45db5e1fa7e93bfc683b139", - "reference": "554ba128f1955038b45db5e1fa7e93bfc683b139", + "url": "https://api.github.com/repos/symfony/mime/zipball/1b2092244374cbe48ae733673f2ca0818b37197b", + "reference": "1b2092244374cbe48ae733673f2ca0818b37197b", "shasum": "" }, "require": { @@ -4942,7 +4968,7 @@ "mime-type" ], "support": { - "source": "https://github.com/symfony/mime/tree/v5.2.5" + "source": "https://github.com/symfony/mime/tree/v5.2.6" }, "funding": [ { @@ -4958,7 +4984,7 @@ "type": "tidelift" } ], - "time": "2021-03-07T16:08:20+00:00" + "time": "2021-03-12T13:18:39+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5759,21 +5785,21 @@ }, { "name": "symfony/service-contracts", - "version": "v2.2.0", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "d15da7ba4957ffb8f1747218be9e1a121fd298a1" + "reference": "f040a30e04b57fbcc9c6cbcf4dbaa96bd318b9bb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/d15da7ba4957ffb8f1747218be9e1a121fd298a1", - "reference": "d15da7ba4957ffb8f1747218be9e1a121fd298a1", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/f040a30e04b57fbcc9c6cbcf4dbaa96bd318b9bb", + "reference": "f040a30e04b57fbcc9c6cbcf4dbaa96bd318b9bb", "shasum": "" }, "require": { "php": ">=7.2.5", - "psr/container": "^1.0" + "psr/container": "^1.1" }, "suggest": { "symfony/service-implementation": "" @@ -5781,7 +5807,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.2-dev" + "dev-main": "2.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -5818,7 +5844,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/master" + "source": "https://github.com/symfony/service-contracts/tree/v2.4.0" }, "funding": [ { @@ -5834,20 +5860,20 @@ "type": "tidelift" } ], - "time": "2020-09-07T11:33:47+00:00" + "time": "2021-04-01T10:43:52+00:00" }, { "name": "symfony/translation", - "version": "v4.4.20", + "version": "v4.4.21", "source": { "type": "git", "url": "https://github.com/symfony/translation.git", - "reference": "2271b6d577018a7dea75a9162a08ac84f8234deb" + "reference": "eb8f5428cc3b40d6dffe303b195b084f1c5fbd14" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation/zipball/2271b6d577018a7dea75a9162a08ac84f8234deb", - "reference": "2271b6d577018a7dea75a9162a08ac84f8234deb", + "url": "https://api.github.com/repos/symfony/translation/zipball/eb8f5428cc3b40d6dffe303b195b084f1c5fbd14", + "reference": "eb8f5428cc3b40d6dffe303b195b084f1c5fbd14", "shasum": "" }, "require": { @@ -5906,7 +5932,7 @@ "description": "Provides tools to internationalize your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/translation/tree/v4.4.20" + "source": "https://github.com/symfony/translation/tree/v4.4.21" }, "funding": [ { @@ -5922,20 +5948,20 @@ "type": "tidelift" } ], - "time": "2021-02-26T13:53:48+00:00" + "time": "2021-03-23T16:25:01+00:00" }, { "name": "symfony/translation-contracts", - "version": "v2.3.0", + "version": "v2.4.0", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "e2eaa60b558f26a4b0354e1bbb25636efaaad105" + "reference": "95c812666f3e91db75385749fe219c5e494c7f95" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/e2eaa60b558f26a4b0354e1bbb25636efaaad105", - "reference": "e2eaa60b558f26a4b0354e1bbb25636efaaad105", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/95c812666f3e91db75385749fe219c5e494c7f95", + "reference": "95c812666f3e91db75385749fe219c5e494c7f95", "shasum": "" }, "require": { @@ -5947,7 +5973,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.3-dev" + "dev-main": "2.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -5984,7 +6010,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/translation-contracts/tree/v2.3.0" + "source": "https://github.com/symfony/translation-contracts/tree/v2.4.0" }, "funding": [ { @@ -6000,20 +6026,20 @@ "type": "tidelift" } ], - "time": "2020-09-28T13:05:58+00:00" + "time": "2021-03-23T23:28:01+00:00" }, { "name": "symfony/var-dumper", - "version": "v4.4.20", + "version": "v4.4.21", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "a1eab2f69906dc83c5ddba4632180260d0ab4f7f" + "reference": "0da0e174f728996f5d5072d6a9f0a42259dbc806" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/a1eab2f69906dc83c5ddba4632180260d0ab4f7f", - "reference": "a1eab2f69906dc83c5ddba4632180260d0ab4f7f", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/0da0e174f728996f5d5072d6a9f0a42259dbc806", + "reference": "0da0e174f728996f5d5072d6a9f0a42259dbc806", "shasum": "" }, "require": { @@ -6073,7 +6099,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v4.4.20" + "source": "https://github.com/symfony/var-dumper/tree/v4.4.21" }, "funding": [ { @@ -6089,7 +6115,7 @@ "type": "tidelift" } ], - "time": "2021-01-27T09:09:26+00:00" + "time": "2021-03-27T19:49:03+00:00" }, { "name": "tijsverkoyen/css-to-inline-styles", @@ -6225,16 +6251,16 @@ "packages-dev": [ { "name": "barryvdh/laravel-debugbar", - "version": "v3.5.2", + "version": "v3.5.5", "source": { "type": "git", "url": "https://github.com/barryvdh/laravel-debugbar.git", - "reference": "cae0a8d1cb89b0f0522f65e60465e16d738e069b" + "reference": "6420113d90bb746423fa70b9940e9e7c26ebc121" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/cae0a8d1cb89b0f0522f65e60465e16d738e069b", - "reference": "cae0a8d1cb89b0f0522f65e60465e16d738e069b", + "url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/6420113d90bb746423fa70b9940e9e7c26ebc121", + "reference": "6420113d90bb746423fa70b9940e9e7c26ebc121", "shasum": "" }, "require": { @@ -6294,7 +6320,7 @@ ], "support": { "issues": "https://github.com/barryvdh/laravel-debugbar/issues", - "source": "https://github.com/barryvdh/laravel-debugbar/tree/v3.5.2" + "source": "https://github.com/barryvdh/laravel-debugbar/tree/v3.5.5" }, "funding": [ { @@ -6302,7 +6328,7 @@ "type": "github" } ], - "time": "2021-01-06T14:21:44+00:00" + "time": "2021-04-07T11:19:20+00:00" }, { "name": "barryvdh/laravel-ide-helper", @@ -6520,16 +6546,16 @@ }, { "name": "composer/composer", - "version": "2.0.11", + "version": "2.0.12", "source": { "type": "git", "url": "https://github.com/composer/composer.git", - "reference": "a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9" + "reference": "6c12ce263da71641903e399c3ce8ecb08fd375fb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/composer/zipball/a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9", - "reference": "a5a5632da0b1c2d6fa9a3b65f1f4e90d1f04abb9", + "url": "https://api.github.com/repos/composer/composer/zipball/6c12ce263da71641903e399c3ce8ecb08fd375fb", + "reference": "6c12ce263da71641903e399c3ce8ecb08fd375fb", "shasum": "" }, "require": { @@ -6597,7 +6623,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/composer/issues", - "source": "https://github.com/composer/composer/tree/2.0.11" + "source": "https://github.com/composer/composer/tree/2.0.12" }, "funding": [ { @@ -6613,7 +6639,7 @@ "type": "tidelift" } ], - "time": "2021-02-24T13:57:23+00:00" + "time": "2021-04-01T08:14:59+00:00" }, { "name": "composer/semver", @@ -6777,16 +6803,16 @@ }, { "name": "composer/xdebug-handler", - "version": "1.4.5", + "version": "1.4.6", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "f28d44c286812c714741478d968104c5e604a1d4" + "reference": "f27e06cd9675801df441b3656569b328e04aa37c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f28d44c286812c714741478d968104c5e604a1d4", - "reference": "f28d44c286812c714741478d968104c5e604a1d4", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f27e06cd9675801df441b3656569b328e04aa37c", + "reference": "f27e06cd9675801df441b3656569b328e04aa37c", "shasum": "" }, "require": { @@ -6794,7 +6820,8 @@ "psr/log": "^1.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" + "phpstan/phpstan": "^0.12.55", + "symfony/phpunit-bridge": "^4.2 || ^5" }, "type": "library", "autoload": { @@ -6820,7 +6847,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/1.4.5" + "source": "https://github.com/composer/xdebug-handler/tree/1.4.6" }, "funding": [ { @@ -6836,7 +6863,7 @@ "type": "tidelift" } ], - "time": "2020-11-13T08:04:11+00:00" + "time": "2021-03-25T17:01:18+00:00" }, { "name": "doctrine/instantiator", @@ -6909,20 +6936,22 @@ }, { "name": "fakerphp/faker", - "version": "v1.13.0", + "version": "v1.14.1", "source": { "type": "git", "url": "https://github.com/FakerPHP/Faker.git", - "reference": "ab3f5364d01f2c2c16113442fb987d26e4004913" + "reference": "ed22aee8d17c7b396f74a58b1e7fefa4f90d5ef1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/ab3f5364d01f2c2c16113442fb987d26e4004913", - "reference": "ab3f5364d01f2c2c16113442fb987d26e4004913", + "url": "https://api.github.com/repos/FakerPHP/Faker/zipball/ed22aee8d17c7b396f74a58b1e7fefa4f90d5ef1", + "reference": "ed22aee8d17c7b396f74a58b1e7fefa4f90d5ef1", "shasum": "" }, "require": { - "php": "^7.1 || ^8.0" + "php": "^7.1 || ^8.0", + "psr/container": "^1.0", + "symfony/deprecation-contracts": "^2.2" }, "conflict": { "fzaninotto/faker": "*" @@ -6930,9 +6959,20 @@ "require-dev": { "bamarni/composer-bin-plugin": "^1.4.1", "ext-intl": "*", - "phpunit/phpunit": "^7.5.20 || ^8.5.8 || ^9.4.2" + "symfony/phpunit-bridge": "^4.4 || ^5.2" + }, + "suggest": { + "ext-curl": "Required by Faker\\Provider\\Image to download images.", + "ext-dom": "Required by Faker\\Provider\\HtmlLorem for generating random HTML.", + "ext-iconv": "Required by Faker\\Provider\\ru_RU\\Text::realText() for generating real Russian text.", + "ext-mbstring": "Required for multibyte Unicode string functionality." }, "type": "library", + "extra": { + "branch-alias": { + "dev-main": "v1.15-dev" + } + }, "autoload": { "psr-4": { "Faker\\": "src/Faker/" @@ -6955,9 +6995,9 @@ ], "support": { "issues": "https://github.com/FakerPHP/Faker/issues", - "source": "https://github.com/FakerPHP/Faker/tree/v1.13.0" + "source": "https://github.com/FakerPHP/Faker/tree/v.1.14.1" }, - "time": "2020-12-18T16:50:48+00:00" + "time": "2021-03-30T06:27:33+00:00" }, { "name": "hamcrest/hamcrest-php", @@ -7734,16 +7774,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.5", + "version": "9.2.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1" + "reference": "f6293e1b30a2354e8428e004689671b83871edde" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f3e026641cc91909d421802dd3ac7827ebfd97e1", - "reference": "f3e026641cc91909d421802dd3ac7827ebfd97e1", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", + "reference": "f6293e1b30a2354e8428e004689671b83871edde", "shasum": "" }, "require": { @@ -7799,7 +7839,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.5" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" }, "funding": [ { @@ -7807,7 +7847,7 @@ "type": "github" } ], - "time": "2020-11-28T06:44:49+00:00" + "time": "2021-03-28T07:26:59+00:00" }, { "name": "phpunit/php-file-iterator", @@ -8052,16 +8092,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.3", + "version": "9.5.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "27241ac75fc37ecf862b6e002bf713b6566cbe41" + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/27241ac75fc37ecf862b6e002bf713b6566cbe41", - "reference": "27241ac75fc37ecf862b6e002bf713b6566cbe41", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c73c6737305e779771147af66c96ca6a7ed8a741", + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741", "shasum": "" }, "require": { @@ -8139,7 +8179,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.3" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.4" }, "funding": [ { @@ -8151,7 +8191,7 @@ "type": "github" } ], - "time": "2021-03-17T07:30:34+00:00" + "time": "2021-03-23T07:16:29+00:00" }, { "name": "react/promise", @@ -9280,16 +9320,16 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.5.8", + "version": "3.6.0", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "9d583721a7157ee997f235f327de038e7ea6dac4" + "reference": "ffced0d2c8fa8e6cdc4d695a743271fab6c38625" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/9d583721a7157ee997f235f327de038e7ea6dac4", - "reference": "9d583721a7157ee997f235f327de038e7ea6dac4", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ffced0d2c8fa8e6cdc4d695a743271fab6c38625", + "reference": "ffced0d2c8fa8e6cdc4d695a743271fab6c38625", "shasum": "" }, "require": { @@ -9332,7 +9372,7 @@ "source": "https://github.com/squizlabs/PHP_CodeSniffer", "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" }, - "time": "2020-10-23T02:01:07+00:00" + "time": "2021-04-09T00:54:41+00:00" }, { "name": "symfony/dom-crawler", @@ -9409,16 +9449,16 @@ }, { "name": "symfony/filesystem", - "version": "v5.2.4", + "version": "v5.2.6", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "710d364200997a5afde34d9fe57bd52f3cc1e108" + "reference": "8c86a82f51658188119e62cff0a050a12d09836f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/710d364200997a5afde34d9fe57bd52f3cc1e108", - "reference": "710d364200997a5afde34d9fe57bd52f3cc1e108", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/8c86a82f51658188119e62cff0a050a12d09836f", + "reference": "8c86a82f51658188119e62cff0a050a12d09836f", "shasum": "" }, "require": { @@ -9451,7 +9491,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v5.2.4" + "source": "https://github.com/symfony/filesystem/tree/v5.2.6" }, "funding": [ { @@ -9467,7 +9507,7 @@ "type": "tidelift" } ], - "time": "2021-02-12T10:38:38+00:00" + "time": "2021-03-28T14:30:26+00:00" }, { "name": "theseer/tokenizer", From 9df4dee1b2db6abeb25a4b36226aa1c3ee20eba5 Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Mon, 19 Apr 2021 21:41:13 +0100 Subject: [PATCH 3/5] Improved header element accessibility when at mobile sizes Intended to fix issues raised in #2681. Changes up the tri-layout tabs, and the main header menu toggle, to be buttons while adding better text and keyboard controls. Updated the component format of a few elements along the way. --- resources/js/components/dropdown.js | 5 +++- .../js/components/header-mobile-toggle.js | 22 ++++++++++++----- resources/js/components/tri-layout.js | 24 +++++++++---------- resources/lang/en/common.php | 3 +++ resources/sass/_header.scss | 7 +++++- resources/views/base.blade.php | 2 +- resources/views/common/header.blade.php | 12 ++++++---- resources/views/tri-layout.blade.php | 22 ++++++++++++----- 8 files changed, 66 insertions(+), 31 deletions(-) diff --git a/resources/js/components/dropdown.js b/resources/js/components/dropdown.js index 22402d483..f761ecf01 100644 --- a/resources/js/components/dropdown.js +++ b/resources/js/components/dropdown.js @@ -12,6 +12,7 @@ class DropDown { this.menu = this.$refs.menu; this.toggle = this.$refs.toggle; this.moveMenu = this.$opts.moveMenu; + this.bubbleEscapes = this.$opts.bubbleEscapes === 'true'; this.direction = (document.dir === 'rtl') ? 'right' : 'left'; this.body = document.body; @@ -137,7 +138,9 @@ class DropDown { } else if (event.key === 'Escape') { this.hide(); this.toggle.focus(); - event.stopPropagation(); + if (!this.bubbleEscapes) { + event.stopPropagation(); + } } }; this.container.addEventListener('keydown', keyboardNavigation); diff --git a/resources/js/components/header-mobile-toggle.js b/resources/js/components/header-mobile-toggle.js index eccd4b8f0..99737bfb8 100644 --- a/resources/js/components/header-mobile-toggle.js +++ b/resources/js/components/header-mobile-toggle.js @@ -1,31 +1,41 @@ class HeaderMobileToggle { - constructor(elem) { - this.elem = elem; - this.toggleButton = elem.querySelector('.mobile-menu-toggle'); - this.menu = elem.querySelector('.header-links'); - this.open = false; + setup() { + this.elem = this.$el; + this.toggleButton = this.$refs.toggle; + this.menu = this.$refs.menu; + this.open = false; this.toggleButton.addEventListener('click', this.onToggle.bind(this)); this.onWindowClick = this.onWindowClick.bind(this); + this.onKeyDown = this.onKeyDown.bind(this); } onToggle(event) { this.open = !this.open; this.menu.classList.toggle('show', this.open); + this.toggleButton.setAttribute('aria-expanded', this.open ? 'true' : 'false'); if (this.open) { + this.elem.addEventListener('keydown', this.onKeyDown); window.addEventListener('click', this.onWindowClick) } else { + this.elem.removeEventListener('keydown', this.onKeyDown); window.removeEventListener('click', this.onWindowClick) } event.stopPropagation(); } + onKeyDown(event) { + if (event.code === 'Escape') { + this.onToggle(event); + } + } + onWindowClick(event) { this.onToggle(event); } } -module.exports = HeaderMobileToggle; \ No newline at end of file +export default HeaderMobileToggle; \ No newline at end of file diff --git a/resources/js/components/tri-layout.js b/resources/js/components/tri-layout.js index 905ca03b1..f801e52a1 100644 --- a/resources/js/components/tri-layout.js +++ b/resources/js/components/tri-layout.js @@ -1,8 +1,9 @@ class TriLayout { - constructor(elem) { - this.elem = elem; + setup() { + this.container = this.$refs.container; + this.tabs = this.$manyRefs.tab; this.lastLayoutType = 'none'; this.onDestroy = null; @@ -43,13 +44,12 @@ class TriLayout { } setupMobile() { - const layoutTabs = document.querySelectorAll('[tri-layout-mobile-tab]'); - for (let tab of layoutTabs) { + for (const tab of this.tabs) { tab.addEventListener('click', this.mobileTabClick); } this.onDestroy = () => { - for (let tab of layoutTabs) { + for (const tab of this.tabs) { tab.removeEventListener('click', this.mobileTabClick); } } @@ -65,7 +65,7 @@ class TriLayout { * @param event */ mobileTabClick(event) { - const tab = event.target.getAttribute('tri-layout-mobile-tab'); + const tab = event.target.dataset.tab; this.showTab(tab); } @@ -79,21 +79,21 @@ class TriLayout { /** * Show the given tab - * @param tabName + * @param {String} tabName + * @param {Boolean }scroll */ showTab(tabName, scroll = true) { this.scrollCache[this.lastTabShown] = document.documentElement.scrollTop; // Set tab status - const tabs = document.querySelectorAll('.tri-layout-mobile-tab'); - for (let tab of tabs) { - const isActive = (tab.getAttribute('tri-layout-mobile-tab') === tabName); - tab.classList.toggle('active', isActive); + for (const tab of this.tabs) { + const isActive = (tab.dataset.tab === tabName); + tab.setAttribute('aria-selected', isActive ? 'true' : 'false'); } // Toggle section const showInfo = (tabName === 'info'); - this.elem.classList.toggle('show-info', showInfo); + this.container.classList.toggle('show-info', showInfo); // Set the scroll position from cache if (scroll) { diff --git a/resources/lang/en/common.php b/resources/lang/en/common.php index 3b003c64a..855c1c807 100644 --- a/resources/lang/en/common.php +++ b/resources/lang/en/common.php @@ -65,6 +65,7 @@ return [ 'breadcrumb' => 'Breadcrumb', // Header + 'header_menu_expand' => 'Expand Header Menu', 'profile_menu' => 'Profile Menu', 'view_profile' => 'View Profile', 'edit_profile' => 'Edit Profile', @@ -73,7 +74,9 @@ return [ // Layout tabs 'tab_info' => 'Info', + 'tab_info_label' => 'Tab: Show Secondary Information', 'tab_content' => 'Content', + 'tab_content_label' => 'Tab: Show Primary Content', // Email Content 'email_action_help' => 'If you’re having trouble clicking the ":actionText" button, copy and paste the URL below into your web browser:', diff --git a/resources/sass/_header.scss b/resources/sass/_header.scss index f371e0410..e06dcde6f 100644 --- a/resources/sass/_header.scss +++ b/resources/sass/_header.scss @@ -191,6 +191,11 @@ header .search-box { @include lightDark(color, #000, #fff); text-decoration: none; } + &:focus { + @include lightDark(background-color, #eee, #333); + outline-color: var(--color-primary); + color: var(--color-primary); + } } header .dropdown-container { display: block; @@ -225,7 +230,7 @@ header .search-box { &:first-child { border-inline-end: 1px solid #DDD; } - &.active { + &[aria-selected="true"] { border-bottom-color: currentColor; } } diff --git a/resources/views/base.blade.php b/resources/views/base.blade.php index 29e4acee7..66604345f 100644 --- a/resources/views/base.blade.php +++ b/resources/views/base.blade.php @@ -31,7 +31,7 @@ @include('partials.notifications') @include('common.header') -
+
@yield('content')
diff --git a/resources/views/common/header.blade.php b/resources/views/common/header.blade.php index 52f6b8cbb..4799aba24 100644 --- a/resources/views/common/header.blade.php +++ b/resources/views/common/header.blade.php @@ -1,4 +1,4 @@ -