diff --git a/composer.lock b/composer.lock index e7631c7..ecf7b1a 100644 --- a/composer.lock +++ b/composer.lock @@ -2491,16 +2491,16 @@ }, { "name": "symfony/cache", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/cache.git", - "reference": "fc822951dd360a593224bb2cef90a087d0dff60f" + "reference": "2d0d3f92c74c445410d05374908b03e0a1131e2b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/cache/zipball/fc822951dd360a593224bb2cef90a087d0dff60f", - "reference": "fc822951dd360a593224bb2cef90a087d0dff60f", + "url": "https://api.github.com/repos/symfony/cache/zipball/2d0d3f92c74c445410d05374908b03e0a1131e2b", + "reference": "2d0d3f92c74c445410d05374908b03e0a1131e2b", "shasum": "" }, "require": { @@ -2567,7 +2567,7 @@ "psr6" ], "support": { - "source": "https://github.com/symfony/cache/tree/v7.0.4" + "source": "https://github.com/symfony/cache/tree/v7.0.6" }, "funding": [ { @@ -2583,20 +2583,20 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-03-27T19:55:25+00:00" }, { "name": "symfony/cache-contracts", - "version": "v3.4.0", + "version": "v3.4.2", "source": { "type": "git", "url": "https://github.com/symfony/cache-contracts.git", - "reference": "1d74b127da04ffa87aa940abe15446fa89653778" + "reference": "2c9db6509a1b21dad229606897639d3284f54b2a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/cache-contracts/zipball/1d74b127da04ffa87aa940abe15446fa89653778", - "reference": "1d74b127da04ffa87aa940abe15446fa89653778", + "url": "https://api.github.com/repos/symfony/cache-contracts/zipball/2c9db6509a1b21dad229606897639d3284f54b2a", + "reference": "2c9db6509a1b21dad229606897639d3284f54b2a", "shasum": "" }, "require": { @@ -2643,7 +2643,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/cache-contracts/tree/v3.4.0" + "source": "https://github.com/symfony/cache-contracts/tree/v3.4.2" }, "funding": [ { @@ -2659,7 +2659,7 @@ "type": "tidelift" } ], - "time": "2023-09-25T12:52:38+00:00" + "time": "2024-01-23T14:51:35+00:00" }, { "name": "symfony/clock", @@ -2737,16 +2737,16 @@ }, { "name": "symfony/config", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/config.git", - "reference": "44deeba7233f08f383185ffa37dace3b3bc87364" + "reference": "7fc7e18a73ec8125fd95928c0340470d64760deb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/44deeba7233f08f383185ffa37dace3b3bc87364", - "reference": "44deeba7233f08f383185ffa37dace3b3bc87364", + "url": "https://api.github.com/repos/symfony/config/zipball/7fc7e18a73ec8125fd95928c0340470d64760deb", + "reference": "7fc7e18a73ec8125fd95928c0340470d64760deb", "shasum": "" }, "require": { @@ -2792,7 +2792,7 @@ "description": "Helps you find, load, combine, autofill and validate configuration values of any kind", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/config/tree/v7.0.4" + "source": "https://github.com/symfony/config/tree/v7.0.6" }, "funding": [ { @@ -2808,20 +2808,20 @@ "type": "tidelift" } ], - "time": "2024-02-26T07:52:39+00:00" + "time": "2024-03-27T19:55:25+00:00" }, { "name": "symfony/console", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "6b099f3306f7c9c2d2786ed736d0026b2903205f" + "reference": "fde915cd8e7eb99b3d531d3d5c09531429c3f9e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/6b099f3306f7c9c2d2786ed736d0026b2903205f", - "reference": "6b099f3306f7c9c2d2786ed736d0026b2903205f", + "url": "https://api.github.com/repos/symfony/console/zipball/fde915cd8e7eb99b3d531d3d5c09531429c3f9e5", + "reference": "fde915cd8e7eb99b3d531d3d5c09531429c3f9e5", "shasum": "" }, "require": { @@ -2885,7 +2885,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v7.0.4" + "source": "https://github.com/symfony/console/tree/v7.0.6" }, "funding": [ { @@ -2901,20 +2901,20 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-04-01T11:04:53+00:00" }, { "name": "symfony/dependency-injection", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "47f37af245df8457ea63409fc242b3cc825ce5eb" + "reference": "ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/47f37af245df8457ea63409fc242b3cc825ce5eb", - "reference": "47f37af245df8457ea63409fc242b3cc825ce5eb", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9", + "reference": "ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9", "shasum": "" }, "require": { @@ -2965,7 +2965,7 @@ "description": "Allows you to standardize and centralize the way objects are constructed in your application", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/dependency-injection/tree/v7.0.4" + "source": "https://github.com/symfony/dependency-injection/tree/v7.0.6" }, "funding": [ { @@ -2981,7 +2981,7 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/deprecation-contracts", @@ -3052,16 +3052,16 @@ }, { "name": "symfony/doctrine-bridge", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/doctrine-bridge.git", - "reference": "e3cf34996df541c62acc1bd5f187aacc18a204d2" + "reference": "929527febf8e134eaba620de1f9396da1db0df85" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/doctrine-bridge/zipball/e3cf34996df541c62acc1bd5f187aacc18a204d2", - "reference": "e3cf34996df541c62acc1bd5f187aacc18a204d2", + "url": "https://api.github.com/repos/symfony/doctrine-bridge/zipball/929527febf8e134eaba620de1f9396da1db0df85", + "reference": "929527febf8e134eaba620de1f9396da1db0df85", "shasum": "" }, "require": { @@ -3078,7 +3078,7 @@ "doctrine/orm": "<2.15", "symfony/cache": "<6.4", "symfony/dependency-injection": "<6.4", - "symfony/form": "<6.4", + "symfony/form": "<6.4.6|>=7,<7.0.6", "symfony/http-foundation": "<6.4", "symfony/http-kernel": "<6.4", "symfony/lock": "<6.4", @@ -3099,7 +3099,7 @@ "symfony/dependency-injection": "^6.4|^7.0", "symfony/doctrine-messenger": "^6.4|^7.0", "symfony/expression-language": "^6.4|^7.0", - "symfony/form": "^6.4|^7.0", + "symfony/form": "^6.4.6|^7.0.6", "symfony/http-kernel": "^6.4|^7.0", "symfony/lock": "^6.4|^7.0", "symfony/messenger": "^6.4|^7.0", @@ -3138,7 +3138,7 @@ "description": "Provides integration for Doctrine with various Symfony components", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/doctrine-bridge/tree/v7.0.5" + "source": "https://github.com/symfony/doctrine-bridge/tree/v7.0.6" }, "funding": [ { @@ -3154,20 +3154,20 @@ "type": "tidelift" } ], - "time": "2024-02-27T12:34:35+00:00" + "time": "2024-03-19T09:29:21+00:00" }, { "name": "symfony/doctrine-messenger", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/doctrine-messenger.git", - "reference": "5a9ebba1b0be17af7b1e6b6433ad2cb6e35e97ca" + "reference": "227cbb2cda296d724a8e08376ad6db73a0335538" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/doctrine-messenger/zipball/5a9ebba1b0be17af7b1e6b6433ad2cb6e35e97ca", - "reference": "5a9ebba1b0be17af7b1e6b6433ad2cb6e35e97ca", + "url": "https://api.github.com/repos/symfony/doctrine-messenger/zipball/227cbb2cda296d724a8e08376ad6db73a0335538", + "reference": "227cbb2cda296d724a8e08376ad6db73a0335538", "shasum": "" }, "require": { @@ -3210,7 +3210,7 @@ "description": "Symfony Doctrine Messenger Bridge", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/doctrine-messenger/tree/v7.0.4" + "source": "https://github.com/symfony/doctrine-messenger/tree/v7.0.6" }, "funding": [ { @@ -3226,7 +3226,7 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-03-19T09:26:35+00:00" }, { "name": "symfony/dotenv", @@ -3304,16 +3304,16 @@ }, { "name": "symfony/error-handler", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "677b24759decff69e65b1e9d1471d90f95ced880" + "reference": "46a4cc138f799886d4bd70477c55c699d3e9dfc8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/677b24759decff69e65b1e9d1471d90f95ced880", - "reference": "677b24759decff69e65b1e9d1471d90f95ced880", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/46a4cc138f799886d4bd70477c55c699d3e9dfc8", + "reference": "46a4cc138f799886d4bd70477c55c699d3e9dfc8", "shasum": "" }, "require": { @@ -3359,7 +3359,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/v7.0.4" + "source": "https://github.com/symfony/error-handler/tree/v7.0.6" }, "funding": [ { @@ -3375,7 +3375,7 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-03-19T11:57:22+00:00" }, { "name": "symfony/event-dispatcher", @@ -3459,16 +3459,16 @@ }, { "name": "symfony/event-dispatcher-contracts", - "version": "v3.4.0", + "version": "v3.4.2", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher-contracts.git", - "reference": "a76aed96a42d2b521153fb382d418e30d18b59df" + "reference": "4e64b49bf370ade88e567de29465762e316e4224" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/a76aed96a42d2b521153fb382d418e30d18b59df", - "reference": "a76aed96a42d2b521153fb382d418e30d18b59df", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/4e64b49bf370ade88e567de29465762e316e4224", + "reference": "4e64b49bf370ade88e567de29465762e316e4224", "shasum": "" }, "require": { @@ -3515,7 +3515,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.4.0" + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.4.2" }, "funding": [ { @@ -3531,7 +3531,7 @@ "type": "tidelift" } ], - "time": "2023-05-23T14:45:45+00:00" + "time": "2024-01-23T14:51:35+00:00" }, { "name": "symfony/expression-language", @@ -3598,16 +3598,16 @@ }, { "name": "symfony/filesystem", - "version": "v7.0.3", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12" + "reference": "408105dff4c104454100730bdfd1a9cdd993f04d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/2890e3a825bc0c0558526c04499c13f83e1b6b12", - "reference": "2890e3a825bc0c0558526c04499c13f83e1b6b12", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/408105dff4c104454100730bdfd1a9cdd993f04d", + "reference": "408105dff4c104454100730bdfd1a9cdd993f04d", "shasum": "" }, "require": { @@ -3641,7 +3641,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v7.0.3" + "source": "https://github.com/symfony/filesystem/tree/v7.0.6" }, "funding": [ { @@ -3657,7 +3657,7 @@ "type": "tidelift" } ], - "time": "2024-01-23T15:02:46+00:00" + "time": "2024-03-21T19:37:36+00:00" }, { "name": "symfony/finder", @@ -3790,16 +3790,16 @@ }, { "name": "symfony/form", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/form.git", - "reference": "5cfe85c74caf924c7cec2134e169320b464ede84" + "reference": "d5db6599775a563792391d0045decc240e7ebd1e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/form/zipball/5cfe85c74caf924c7cec2134e169320b464ede84", - "reference": "5cfe85c74caf924c7cec2134e169320b464ede84", + "url": "https://api.github.com/repos/symfony/form/zipball/d5db6599775a563792391d0045decc240e7ebd1e", + "reference": "d5db6599775a563792391d0045decc240e7ebd1e", "shasum": "" }, "require": { @@ -3866,7 +3866,7 @@ "description": "Allows to easily create, process and reuse HTML forms", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/form/tree/v7.0.4" + "source": "https://github.com/symfony/form/tree/v7.0.6" }, "funding": [ { @@ -3882,20 +3882,20 @@ "type": "tidelift" } ], - "time": "2024-02-12T11:15:03+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/framework-bundle", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/framework-bundle.git", - "reference": "b58bcb2f9c32405b8fbaa24a1e38c8a10bad7b21" + "reference": "5ebf6771f92d135c2bdbda7133998feb74713658" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/framework-bundle/zipball/b58bcb2f9c32405b8fbaa24a1e38c8a10bad7b21", - "reference": "b58bcb2f9c32405b8fbaa24a1e38c8a10bad7b21", + "url": "https://api.github.com/repos/symfony/framework-bundle/zipball/5ebf6771f92d135c2bdbda7133998feb74713658", + "reference": "5ebf6771f92d135c2bdbda7133998feb74713658", "shasum": "" }, "require": { @@ -4012,7 +4012,7 @@ "description": "Provides a tight integration between Symfony components and the Symfony full-stack framework", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/framework-bundle/tree/v7.0.4" + "source": "https://github.com/symfony/framework-bundle/tree/v7.0.6" }, "funding": [ { @@ -4028,26 +4028,26 @@ "type": "tidelift" } ], - "time": "2024-02-26T07:52:39+00:00" + "time": "2024-03-27T19:55:25+00:00" }, { "name": "symfony/http-client", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/http-client.git", - "reference": "425f462a59d8030703ee04a9e1c666575ed5db3b" + "reference": "6e70473909f46fe5dd3b994a0f1b20ecb6b2f858" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-client/zipball/425f462a59d8030703ee04a9e1c666575ed5db3b", - "reference": "425f462a59d8030703ee04a9e1c666575ed5db3b", + "url": "https://api.github.com/repos/symfony/http-client/zipball/6e70473909f46fe5dd3b994a0f1b20ecb6b2f858", + "reference": "6e70473909f46fe5dd3b994a0f1b20ecb6b2f858", "shasum": "" }, "require": { "php": ">=8.2", "psr/log": "^1|^2|^3", - "symfony/http-client-contracts": "^3", + "symfony/http-client-contracts": "^3.4.1", "symfony/service-contracts": "^2.5|^3" }, "conflict": { @@ -4065,7 +4065,7 @@ "amphp/http-client": "^4.2.1", "amphp/http-tunnel": "^1.0", "amphp/socket": "^1.1", - "guzzlehttp/promises": "^1.4", + "guzzlehttp/promises": "^1.4|^2.0", "nyholm/psr7": "^1.0", "php-http/httplug": "^1.0|^2.0", "psr/http-client": "^1.0", @@ -4104,7 +4104,7 @@ "http" ], "support": { - "source": "https://github.com/symfony/http-client/tree/v7.0.5" + "source": "https://github.com/symfony/http-client/tree/v7.0.6" }, "funding": [ { @@ -4120,20 +4120,20 @@ "type": "tidelift" } ], - "time": "2024-03-02T12:46:12+00:00" + "time": "2024-04-01T20:49:44+00:00" }, { "name": "symfony/http-client-contracts", - "version": "v3.4.0", + "version": "v3.4.2", "source": { "type": "git", "url": "https://github.com/symfony/http-client-contracts.git", - "reference": "1ee70e699b41909c209a0c930f11034b93578654" + "reference": "b6b5c876b3a4ed74460e2c5ac53bbce2f12e2a7e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/1ee70e699b41909c209a0c930f11034b93578654", - "reference": "1ee70e699b41909c209a0c930f11034b93578654", + "url": "https://api.github.com/repos/symfony/http-client-contracts/zipball/b6b5c876b3a4ed74460e2c5ac53bbce2f12e2a7e", + "reference": "b6b5c876b3a4ed74460e2c5ac53bbce2f12e2a7e", "shasum": "" }, "require": { @@ -4182,7 +4182,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/http-client-contracts/tree/v3.4.0" + "source": "https://github.com/symfony/http-client-contracts/tree/v3.4.2" }, "funding": [ { @@ -4198,20 +4198,20 @@ "type": "tidelift" } ], - "time": "2023-07-30T20:28:31+00:00" + "time": "2024-04-01T18:51:09+00:00" }, { "name": "symfony/http-foundation", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/http-foundation.git", - "reference": "439fdfdd344943254b1ef6278613e79040548045" + "reference": "8789625dcf36e5fbf753014678a1e090f1bc759c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-foundation/zipball/439fdfdd344943254b1ef6278613e79040548045", - "reference": "439fdfdd344943254b1ef6278613e79040548045", + "url": "https://api.github.com/repos/symfony/http-foundation/zipball/8789625dcf36e5fbf753014678a1e090f1bc759c", + "reference": "8789625dcf36e5fbf753014678a1e090f1bc759c", "shasum": "" }, "require": { @@ -4259,7 +4259,7 @@ "description": "Defines an object-oriented layer for the HTTP specification", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/http-foundation/tree/v7.0.4" + "source": "https://github.com/symfony/http-foundation/tree/v7.0.6" }, "funding": [ { @@ -4275,20 +4275,20 @@ "type": "tidelift" } ], - "time": "2024-02-08T19:22:56+00:00" + "time": "2024-03-19T11:46:48+00:00" }, { "name": "symfony/http-kernel", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "37c24ca28f65e3121a68f3dd4daeb36fb1fa2a72" + "reference": "34c872391046d59af804af62d4573b829cfe4824" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/37c24ca28f65e3121a68f3dd4daeb36fb1fa2a72", - "reference": "37c24ca28f65e3121a68f3dd4daeb36fb1fa2a72", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/34c872391046d59af804af62d4573b829cfe4824", + "reference": "34c872391046d59af804af62d4573b829cfe4824", "shasum": "" }, "require": { @@ -4371,7 +4371,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/v7.0.5" + "source": "https://github.com/symfony/http-kernel/tree/v7.0.6" }, "funding": [ { @@ -4387,7 +4387,7 @@ "type": "tidelift" } ], - "time": "2024-03-04T21:05:24+00:00" + "time": "2024-04-03T06:12:25+00:00" }, { "name": "symfony/intl", @@ -4473,16 +4473,16 @@ }, { "name": "symfony/mailer", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/mailer.git", - "reference": "72e16d87bf50a3ce195b9470c06bb9d7b816ea85" + "reference": "eb0c3187c7ddfde12d8aa0e1fa5fb29e730a41e0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mailer/zipball/72e16d87bf50a3ce195b9470c06bb9d7b816ea85", - "reference": "72e16d87bf50a3ce195b9470c06bb9d7b816ea85", + "url": "https://api.github.com/repos/symfony/mailer/zipball/eb0c3187c7ddfde12d8aa0e1fa5fb29e730a41e0", + "reference": "eb0c3187c7ddfde12d8aa0e1fa5fb29e730a41e0", "shasum": "" }, "require": { @@ -4533,7 +4533,7 @@ "description": "Helps sending emails", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/mailer/tree/v7.0.4" + "source": "https://github.com/symfony/mailer/tree/v7.0.6" }, "funding": [ { @@ -4549,20 +4549,20 @@ "type": "tidelift" } ], - "time": "2024-02-03T21:34:19+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/messenger", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/messenger.git", - "reference": "804a8997f93313a8f7ed19e8cca3b44fdd18bdec" + "reference": "4e281ef8bf5397be36fe14d64eb665fa12a945ad" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/messenger/zipball/804a8997f93313a8f7ed19e8cca3b44fdd18bdec", - "reference": "804a8997f93313a8f7ed19e8cca3b44fdd18bdec", + "url": "https://api.github.com/repos/symfony/messenger/zipball/4e281ef8bf5397be36fe14d64eb665fa12a945ad", + "reference": "4e281ef8bf5397be36fe14d64eb665fa12a945ad", "shasum": "" }, "require": { @@ -4619,7 +4619,7 @@ "description": "Helps applications send and receive messages to/from other applications or via message queues", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/messenger/tree/v7.0.4" + "source": "https://github.com/symfony/messenger/tree/v7.0.6" }, "funding": [ { @@ -4635,20 +4635,20 @@ "type": "tidelift" } ], - "time": "2024-02-26T07:52:39+00:00" + "time": "2024-03-19T11:57:22+00:00" }, { "name": "symfony/mime", - "version": "v7.0.3", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/mime.git", - "reference": "c1ffe24ba6fdc3e3f0f3fcb93519103b326a3716" + "reference": "99362408c9abdf8c7cadcf0529b6fc8b16f5ace2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/mime/zipball/c1ffe24ba6fdc3e3f0f3fcb93519103b326a3716", - "reference": "c1ffe24ba6fdc3e3f0f3fcb93519103b326a3716", + "url": "https://api.github.com/repos/symfony/mime/zipball/99362408c9abdf8c7cadcf0529b6fc8b16f5ace2", + "reference": "99362408c9abdf8c7cadcf0529b6fc8b16f5ace2", "shasum": "" }, "require": { @@ -4668,6 +4668,7 @@ "league/html-to-markdown": "^5.0", "phpdocumentor/reflection-docblock": "^3.0|^4.0|^5.0", "symfony/dependency-injection": "^6.4|^7.0", + "symfony/process": "^6.4|^7.0", "symfony/property-access": "^6.4|^7.0", "symfony/property-info": "^6.4|^7.0", "symfony/serializer": "^6.4|^7.0" @@ -4702,7 +4703,7 @@ "mime-type" ], "support": { - "source": "https://github.com/symfony/mime/tree/v7.0.3" + "source": "https://github.com/symfony/mime/tree/v7.0.6" }, "funding": [ { @@ -4718,7 +4719,7 @@ "type": "tidelift" } ], - "time": "2024-01-30T08:34:29+00:00" + "time": "2024-03-21T19:37:36+00:00" }, { "name": "symfony/monolog-bridge", @@ -5643,16 +5644,16 @@ }, { "name": "symfony/property-access", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/property-access.git", - "reference": "44e3746d4de8d0961a44ee332c74dd0918266127" + "reference": "1c268ba954ccc5e78cf035b391abb67759e24423" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/property-access/zipball/44e3746d4de8d0961a44ee332c74dd0918266127", - "reference": "44e3746d4de8d0961a44ee332c74dd0918266127", + "url": "https://api.github.com/repos/symfony/property-access/zipball/1c268ba954ccc5e78cf035b391abb67759e24423", + "reference": "1c268ba954ccc5e78cf035b391abb67759e24423", "shasum": "" }, "require": { @@ -5699,7 +5700,7 @@ "reflection" ], "support": { - "source": "https://github.com/symfony/property-access/tree/v7.0.4" + "source": "https://github.com/symfony/property-access/tree/v7.0.6" }, "funding": [ { @@ -5715,20 +5716,20 @@ "type": "tidelift" } ], - "time": "2024-02-16T13:44:10+00:00" + "time": "2024-03-19T11:57:22+00:00" }, { "name": "symfony/property-info", - "version": "v7.0.3", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/property-info.git", - "reference": "e160f92ea827243abf2dbf36b8460b1377194406" + "reference": "b8844ddce7d53f78b57ec9be59da80fceddf3167" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/property-info/zipball/e160f92ea827243abf2dbf36b8460b1377194406", - "reference": "e160f92ea827243abf2dbf36b8460b1377194406", + "url": "https://api.github.com/repos/symfony/property-info/zipball/b8844ddce7d53f78b57ec9be59da80fceddf3167", + "reference": "b8844ddce7d53f78b57ec9be59da80fceddf3167", "shasum": "" }, "require": { @@ -5782,7 +5783,7 @@ "validator" ], "support": { - "source": "https://github.com/symfony/property-info/tree/v7.0.3" + "source": "https://github.com/symfony/property-info/tree/v7.0.6" }, "funding": [ { @@ -5798,20 +5799,20 @@ "type": "tidelift" } ], - "time": "2024-01-23T15:02:46+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/routing", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/routing.git", - "reference": "ba6bf07d43289c6a4b4591ddb75bc3bc5f069c19" + "reference": "cded64e5bbf9f31786f1055fcc76718fdd77519c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/routing/zipball/ba6bf07d43289c6a4b4591ddb75bc3bc5f069c19", - "reference": "ba6bf07d43289c6a4b4591ddb75bc3bc5f069c19", + "url": "https://api.github.com/repos/symfony/routing/zipball/cded64e5bbf9f31786f1055fcc76718fdd77519c", + "reference": "cded64e5bbf9f31786f1055fcc76718fdd77519c", "shasum": "" }, "require": { @@ -5863,7 +5864,7 @@ "url" ], "support": { - "source": "https://github.com/symfony/routing/tree/v7.0.5" + "source": "https://github.com/symfony/routing/tree/v7.0.6" }, "funding": [ { @@ -5879,7 +5880,7 @@ "type": "tidelift" } ], - "time": "2024-02-27T12:34:35+00:00" + "time": "2024-03-28T21:02:11+00:00" }, { "name": "symfony/runtime", @@ -5962,16 +5963,16 @@ }, { "name": "symfony/security-bundle", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/security-bundle.git", - "reference": "5d620bd5493d62d8016b2383d8690fade66163c1" + "reference": "96a9e4eaf76514674d8ffd6127d8ec1204b72e7f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/security-bundle/zipball/5d620bd5493d62d8016b2383d8690fade66163c1", - "reference": "5d620bd5493d62d8016b2383d8690fade66163c1", + "url": "https://api.github.com/repos/symfony/security-bundle/zipball/96a9e4eaf76514674d8ffd6127d8ec1204b72e7f", + "reference": "96a9e4eaf76514674d8ffd6127d8ec1204b72e7f", "shasum": "" }, "require": { @@ -6053,7 +6054,7 @@ "description": "Provides a tight integration of the Security component into the Symfony full-stack framework", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/security-bundle/tree/v7.0.5" + "source": "https://github.com/symfony/security-bundle/tree/v7.0.6" }, "funding": [ { @@ -6069,7 +6070,7 @@ "type": "tidelift" } ], - "time": "2024-03-02T12:46:12+00:00" + "time": "2024-03-15T12:53:12+00:00" }, { "name": "symfony/security-core", @@ -6312,16 +6313,16 @@ }, { "name": "symfony/serializer", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/serializer.git", - "reference": "c71d61c6c37804e10981960e5f5ebc2c8f0a4fbb" + "reference": "dbdc0c04c28ac53de1fa35f92fca26e9b1345d98" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/serializer/zipball/c71d61c6c37804e10981960e5f5ebc2c8f0a4fbb", - "reference": "c71d61c6c37804e10981960e5f5ebc2c8f0a4fbb", + "url": "https://api.github.com/repos/symfony/serializer/zipball/dbdc0c04c28ac53de1fa35f92fca26e9b1345d98", + "reference": "dbdc0c04c28ac53de1fa35f92fca26e9b1345d98", "shasum": "" }, "require": { @@ -6387,7 +6388,7 @@ "description": "Handles serializing and deserializing data structures, including object graphs, into array structures or other formats like XML and JSON.", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/serializer/tree/v7.0.4" + "source": "https://github.com/symfony/serializer/tree/v7.0.6" }, "funding": [ { @@ -6403,20 +6404,20 @@ "type": "tidelift" } ], - "time": "2024-02-22T20:27:20+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/service-contracts", - "version": "v3.4.1", + "version": "v3.4.2", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0" + "reference": "11bbf19a0fb7b36345861e85c5768844c552906e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/fe07cbc8d837f60caf7018068e350cc5163681a0", - "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/11bbf19a0fb7b36345861e85c5768844c552906e", + "reference": "11bbf19a0fb7b36345861e85c5768844c552906e", "shasum": "" }, "require": { @@ -6469,7 +6470,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v3.4.1" + "source": "https://github.com/symfony/service-contracts/tree/v3.4.2" }, "funding": [ { @@ -6485,7 +6486,7 @@ "type": "tidelift" } ], - "time": "2023-12-26T14:02:43+00:00" + "time": "2023-12-19T21:51:00+00:00" }, { "name": "symfony/stopwatch", @@ -6731,16 +6732,16 @@ }, { "name": "symfony/translation-contracts", - "version": "v3.4.1", + "version": "v3.4.2", "source": { "type": "git", "url": "https://github.com/symfony/translation-contracts.git", - "reference": "06450585bf65e978026bda220cdebca3f867fde7" + "reference": "43810bdb2ddb5400e5c5e778e27b210a0ca83b6b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/06450585bf65e978026bda220cdebca3f867fde7", - "reference": "06450585bf65e978026bda220cdebca3f867fde7", + "url": "https://api.github.com/repos/symfony/translation-contracts/zipball/43810bdb2ddb5400e5c5e778e27b210a0ca83b6b", + "reference": "43810bdb2ddb5400e5c5e778e27b210a0ca83b6b", "shasum": "" }, "require": { @@ -6789,7 +6790,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/translation-contracts/tree/v3.4.1" + "source": "https://github.com/symfony/translation-contracts/tree/v3.4.2" }, "funding": [ { @@ -6805,20 +6806,20 @@ "type": "tidelift" } ], - "time": "2023-12-26T14:02:43+00:00" + "time": "2024-01-23T14:51:35+00:00" }, { "name": "symfony/twig-bridge", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/twig-bridge.git", - "reference": "d16aa4eb5bdaeb6e7407782431dc70530f3b1df5" + "reference": "1d5745dac2e043553177a3b88a76b99c2a2f6c2e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/twig-bridge/zipball/d16aa4eb5bdaeb6e7407782431dc70530f3b1df5", - "reference": "d16aa4eb5bdaeb6e7407782431dc70530f3b1df5", + "url": "https://api.github.com/repos/symfony/twig-bridge/zipball/1d5745dac2e043553177a3b88a76b99c2a2f6c2e", + "reference": "1d5745dac2e043553177a3b88a76b99c2a2f6c2e", "shasum": "" }, "require": { @@ -6897,7 +6898,7 @@ "description": "Provides integration for Twig with various Symfony components", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/twig-bridge/tree/v7.0.4" + "source": "https://github.com/symfony/twig-bridge/tree/v7.0.6" }, "funding": [ { @@ -6913,7 +6914,7 @@ "type": "tidelift" } ], - "time": "2024-02-15T11:33:06+00:00" + "time": "2024-03-28T21:02:11+00:00" }, { "name": "symfony/twig-bundle", @@ -7001,16 +7002,16 @@ }, { "name": "symfony/validator", - "version": "v7.0.5", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/validator.git", - "reference": "6a73d479191a0bbbd9ffa3886af6e6ff6e79fb86" + "reference": "a2df2c63b7944a162dee86ab8065f2f91b7d6e36" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/validator/zipball/6a73d479191a0bbbd9ffa3886af6e6ff6e79fb86", - "reference": "6a73d479191a0bbbd9ffa3886af6e6ff6e79fb86", + "url": "https://api.github.com/repos/symfony/validator/zipball/a2df2c63b7944a162dee86ab8065f2f91b7d6e36", + "reference": "a2df2c63b7944a162dee86ab8065f2f91b7d6e36", "shasum": "" }, "require": { @@ -7075,7 +7076,7 @@ "description": "Provides tools to validate values", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/validator/tree/v7.0.5" + "source": "https://github.com/symfony/validator/tree/v7.0.6" }, "funding": [ { @@ -7091,20 +7092,20 @@ "type": "tidelift" } ], - "time": "2024-02-27T12:53:56+00:00" + "time": "2024-03-28T09:20:36+00:00" }, { "name": "symfony/var-dumper", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/var-dumper.git", - "reference": "e03ad7c1535e623edbb94c22cc42353e488c6670" + "reference": "66d13dc207d5dab6b4f4c2b5460efe1bea29dbfb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/e03ad7c1535e623edbb94c22cc42353e488c6670", - "reference": "e03ad7c1535e623edbb94c22cc42353e488c6670", + "url": "https://api.github.com/repos/symfony/var-dumper/zipball/66d13dc207d5dab6b4f4c2b5460efe1bea29dbfb", + "reference": "66d13dc207d5dab6b4f4c2b5460efe1bea29dbfb", "shasum": "" }, "require": { @@ -7158,7 +7159,7 @@ "dump" ], "support": { - "source": "https://github.com/symfony/var-dumper/tree/v7.0.4" + "source": "https://github.com/symfony/var-dumper/tree/v7.0.6" }, "funding": [ { @@ -7174,26 +7175,28 @@ "type": "tidelift" } ], - "time": "2024-02-15T11:33:06+00:00" + "time": "2024-03-19T11:57:22+00:00" }, { "name": "symfony/var-exporter", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/var-exporter.git", - "reference": "dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41" + "reference": "c74c568d2a15a1d407cf40d61ea82bc2d521e27b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/var-exporter/zipball/dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41", - "reference": "dfb0acb6803eb714f05d97dd4c5abe6d5fa9fe41", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/c74c568d2a15a1d407cf40d61ea82bc2d521e27b", + "reference": "c74c568d2a15a1d407cf40d61ea82bc2d521e27b", "shasum": "" }, "require": { "php": ">=8.2" }, "require-dev": { + "symfony/property-access": "^6.4|^7.0", + "symfony/serializer": "^6.4|^7.0", "symfony/var-dumper": "^6.4|^7.0" }, "type": "library", @@ -7232,7 +7235,7 @@ "serialize" ], "support": { - "source": "https://github.com/symfony/var-exporter/tree/v7.0.4" + "source": "https://github.com/symfony/var-exporter/tree/v7.0.6" }, "funding": [ { @@ -7248,7 +7251,7 @@ "type": "tidelift" } ], - "time": "2024-02-26T10:35:24+00:00" + "time": "2024-03-20T21:25:22+00:00" }, { "name": "symfony/web-link", @@ -7612,16 +7615,16 @@ "packages-dev": [ { "name": "masterminds/html5", - "version": "2.8.1", + "version": "2.9.0", "source": { "type": "git", "url": "https://github.com/Masterminds/html5-php.git", - "reference": "f47dcf3c70c584de14f21143c55d9939631bc6cf" + "reference": "f5ac2c0b0a2eefca70b2ce32a5809992227e75a6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/f47dcf3c70c584de14f21143c55d9939631bc6cf", - "reference": "f47dcf3c70c584de14f21143c55d9939631bc6cf", + "url": "https://api.github.com/repos/Masterminds/html5-php/zipball/f5ac2c0b0a2eefca70b2ce32a5809992227e75a6", + "reference": "f5ac2c0b0a2eefca70b2ce32a5809992227e75a6", "shasum": "" }, "require": { @@ -7629,7 +7632,7 @@ "php": ">=5.3.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7.21 || ^6 || ^7 || ^8" + "phpunit/phpunit": "^4.8.35 || ^5.7.21 || ^6 || ^7 || ^8 || ^9" }, "type": "library", "extra": { @@ -7673,9 +7676,9 @@ ], "support": { "issues": "https://github.com/Masterminds/html5-php/issues", - "source": "https://github.com/Masterminds/html5-php/tree/2.8.1" + "source": "https://github.com/Masterminds/html5-php/tree/2.9.0" }, - "time": "2023-05-10T11:58:31+00:00" + "time": "2024-03-31T07:05:07+00:00" }, { "name": "myclabs/deep-copy", @@ -9665,16 +9668,16 @@ }, { "name": "symfony/phpunit-bridge", - "version": "v7.0.4", + "version": "v7.0.6", "source": { "type": "git", "url": "https://github.com/symfony/phpunit-bridge.git", - "reference": "54ca13ec990a40411ad978e08d994fca6cdd865f" + "reference": "a014167aa1f66cb9990675840da65609d3e61612" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/phpunit-bridge/zipball/54ca13ec990a40411ad978e08d994fca6cdd865f", - "reference": "54ca13ec990a40411ad978e08d994fca6cdd865f", + "url": "https://api.github.com/repos/symfony/phpunit-bridge/zipball/a014167aa1f66cb9990675840da65609d3e61612", + "reference": "a014167aa1f66cb9990675840da65609d3e61612", "shasum": "" }, "require": { @@ -9726,7 +9729,7 @@ "description": "Provides utilities for PHPUnit, especially user deprecation notices management", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/phpunit-bridge/tree/v7.0.4" + "source": "https://github.com/symfony/phpunit-bridge/tree/v7.0.6" }, "funding": [ { @@ -9742,7 +9745,7 @@ "type": "tidelift" } ], - "time": "2024-02-08T19:22:56+00:00" + "time": "2024-03-19T11:57:22+00:00" }, { "name": "symfony/web-profiler-bundle", diff --git a/public/scripts/chart.js b/public/scripts/chart.js new file mode 100755 index 0000000..3e88533 --- /dev/null +++ b/public/scripts/chart.js @@ -0,0 +1,528 @@ +function Rect(value, name, x, y, w, h){ + this.value = value; + this.name = name; + this.x = x; + this.y = y; + this.w = w; + this.h = h; + this.checkHit = function (mouseX, mouseY) { + return (mouseX >= x && mouseX <= x + w && mouseY >= y && mouseY <= y + h); + } +} + +function Circle(value, name, x, y, r){ + this.value = value; + this.name = name; + this.x = x; + this.y = y; + this.r = r; + this.checkHit = function (mouseX, mouseY) { + return Math.pow((mouseX - x),2) + Math.pow((mouseY - y),2) <= Math.pow(r, 2); + } +} + +function PieSlice(value, name, x, y, r, sAngle, eAngle){ + this.value = value; + this.name = name; + this.x = x; + this.y = y; + this.r = r; + this.sAngle = sAngle; + this.eAngle = eAngle; + this.checkHit = function (mouseX, mouseY) { + if (Math.pow((mouseX - x),2) + Math.pow((mouseY - y),2) <= Math.pow(r, 2)){ + var dy = mouseY - y; + var dx = mouseX - x; + var theta = Math.atan2(dy, dx); // range (-PI, PI] + if (theta < 0) theta += 2*Math.PI; + + return (theta > sAngle && theta < eAngle); + } + } +} + +let objects = []; + +function checkHit(pos) { + for (let i = 0; i < objects.length; i++){ + if (objects[i].checkHit(pos.x, pos.y)){ + return objects[i]; + } + } + return null; +} + +function getLargest(data) { + let largest = data[0].values[0]; + + data.forEach(function (categ) { + for (let i = 0; i < categ.values.length; i++) + if (categ.values[i] > largest) { + largest = categ.values[i]; + } + }); + + return largest; +} + +function getSmallest(data) { + let smallest = data[0].values[0]; + + data.forEach(function (categ) { + for (let i = 0; i < categ.values.length; i++) + if (categ.values[i] < smallest) { + smallest = categ.values[i]; + } + }); + + return smallest; +} + +function drawAxis(bounds, largest, smallest, arrayLen, ctx, graphSettings, drawValues = true) { + ctx.font = "16px Arial"; + if (graphSettings.y_step <= 0) graphSettings.y_step = 1; + + ctx.beginPath(); + for (let i = (smallest < 0)?smallest:0; i <= ((largest>=0)?largest:0); i += parseFloat(graphSettings.y_step)){ + + ctx.strokeStyle = "#BBB"; + ctx.lineWidth = 1; + let scale = bounds.height - ((largest >= 0)?(bounds.bottom - bounds.xAxis):0); + let extreme = (largest<=0)?Math.abs(smallest):Math.abs(largest); + let yPos = Math.round((bounds.xAxis - i * scale / extreme)); + + //support line + if (graphSettings.display_support_lines) { + + ctx.moveTo( bounds.left, yPos ); + ctx.lineTo( bounds.right, yPos ); + } + + //Y axis value + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + ctx.textAlign = "end"; + ctx.fillText( i, bounds.left - 3, yPos); + ctx.stroke(); + } + + //X axis value + if (drawValues) { + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + for (let i = 0; i < arrayLen; i++){ + let x = bounds.left + bounds.width / (arrayLen - 1) * i; + let text = (i + 1).toString(); + if (graphSettings.custom_x_values !== "") + text = graphSettings.custom_x_values.split(';')[i]; + ctx.fillText(text, x, bounds.bottom + 18); + } + ctx.closePath(); + } + + //X and Y axis + ctx.strokeStyle = "black"; + ctx.lineWidth = "2px"; + ctx.beginPath(); + ctx.moveTo( bounds.left, bounds.top ); + ctx.lineTo( bounds.left, bounds.bottom ); + ctx.moveTo( bounds.left, bounds.xAxis); + ctx.lineTo( bounds.right, bounds.xAxis ); + ctx.stroke(); + + //Axis labels + //X axis text + ctx.beginPath(); + ctx.font = "20px Arial"; + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + ctx.fillText(graphSettings.x_label, bounds.width/2 + bounds.left, bounds.height + 2*bounds.top - 5); + + //Y axis text + ctx.save(); + ctx.rotate(-Math.PI / 2); + ctx.textAlign = "center"; + ctx.fillText(graphSettings.y_label, -(bounds.left + bounds.height/2), 18); + ctx.restore(); + ctx.stroke(); +} + +function drawTitle(canvas, graphSettings) { + let ctx = canvas.getContext("2d"); + let x = canvas.width / 2; + let y = 25; + + ctx.font = "30px Arial"; + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + ctx.fillText( graphSettings.title, x, y); +} + +function drawPoints(ctx, bounds, values, name, arrayLen, largest, color) { + ctx.fillStyle = color; + let radius = 3; + + for( let i = 0; i < arrayLen; i++ ){ + ctx.beginPath(); + if(values[i] === null) continue; + let scale = bounds.height - ((largest >= 0)?(bounds.bottom - bounds.xAxis):0); + let extreme = (largest<=0)?Math.abs(smallest):Math.abs(largest); + let x = bounds.left + bounds.width / (arrayLen - 1) * i; + let y = (bounds.xAxis - values[i] / extreme * scale); + ctx.arc(x, y, radius, 0, 2 * Math.PI); + ctx.fill(); + ctx.stroke(); + ctx.closePath(); + + let new_object = new Circle(values[i], name, x, y, radius); + objects.push(new_object); + } +} + +function drawSlice(ctx, centerX, centerY, radius, startAngle, endAngle, color ){ + ctx.fillStyle = color; + ctx.beginPath(); + ctx.moveTo(centerX,centerY); + ctx.arc(centerX, centerY, radius, startAngle, endAngle); + ctx.fill(); + ctx.closePath(); +} + +function getBounds(canvas, graphMargin) { + return { + top: graphMargin, + bottom: canvas.height - graphMargin, + left: graphMargin, + right: canvas.width - graphMargin, + height: canvas.height - 2*graphMargin, + width: canvas.width - 2*graphMargin, + xAxis: canvas.height - graphMargin + }; +} + +function drawPieChart(canvas, data, graphSettings) { + + let ctx = canvas.getContext("2d"); + let index = 0; + let start_angle = 0; + let total_value = 0; + let bounds = getBounds(canvas, graphSettings.margin); + + + data.forEach(function (categ) { + let val = categ.values[0]; + if (val !== null) + total_value += val; + }); + + data.forEach(function (categ) { + let val = categ.values[0]; + let slice_angle = 2 * Math.PI * val / total_value; + + let x = canvas.width/2; + let y = canvas.height/2; + let r = Math.min(bounds.width/2, bounds.height/2); + let end_angle = start_angle + slice_angle; + + drawSlice(ctx, x, y, r, start_angle, end_angle, categ.color); + let new_object = new PieSlice(val + " (" + Math.round(val/total_value*100) + "%)", categ.name, x, y, r, start_angle, end_angle); + objects.push(new_object); + + start_angle = end_angle; + index++; + }); + + +} + +function drawPointChart(canvas, data, graphSettings){ + let ctx = canvas.getContext( "2d" ); + + let bounds = getBounds(canvas, graphSettings.margin); + let largest = getLargest(data); + let smallest = getSmallest(data); + + if (smallest < 0) + bounds.xAxis = bounds.bottom - (bounds.height / (((largest<=0)?0:Math.abs(largest)) + Math.abs(smallest)) * Math.abs(smallest)); + let arrayLen = data[0].values.length; + + drawAxis(bounds, largest, smallest, arrayLen, ctx, graphSettings); + + data.display_points = true; + data.forEach(function (categ) { + //Points + if (graphSettings.display_points) + drawPoints(ctx, bounds, categ.values, categ.name, arrayLen, largest, categ.color); + }); +} + +function drawLineChart(canvas, data, graphSettings){ + let ctx = canvas.getContext( "2d" ); + + let bounds = getBounds(canvas, graphSettings.margin); + let largest = getLargest(data); + let smallest = getSmallest(data); + + if (smallest < 0) + bounds.xAxis = bounds.bottom - (bounds.height / (((largest<=0)?0:Math.abs(largest)) + Math.abs(smallest)) * Math.abs(smallest)); + let arrayLen = data[0].values.length; + + drawAxis(bounds, largest, smallest, arrayLen, ctx, graphSettings); + + data.forEach(function (categ) { + //Lines + ctx.beginPath(); + ctx.lineJoin = "round"; + ctx.strokeStyle = categ.color; + + for (let i = 0; i < arrayLen; i++) { + if (categ.values[i] === null) continue; + + let scale = bounds.height - ((largest >= 0)?(bounds.bottom - bounds.xAxis):0); + let extreme = (largest<=0)?Math.abs(smallest):Math.abs(largest); + let x = bounds.left + bounds.width / (arrayLen - 1) * i; + let y = (bounds.xAxis - categ.values[i] / extreme * scale); + + ctx.lineTo(x, y); + } + ctx.stroke(); + ctx.closePath(); + + //Points + if (graphSettings.display_points) + drawPoints(ctx, bounds, categ.values, categ.name, arrayLen, largest, categ.color); + }); +} + +function drawAreaChart(canvas, data, graphSettings){ + let ctx = canvas.getContext( "2d" ); + + let bounds = getBounds(canvas, graphSettings.margin); + let largest = getLargest(data); + let smallest = getSmallest(data); + + if (smallest < 0) + bounds.xAxis = bounds.bottom - (bounds.height / (((largest<=0)?0:Math.abs(largest)) + Math.abs(smallest)) * Math.abs(smallest)); + let arrayLen = data[0].values.length; + + drawAxis(bounds, largest, smallest, arrayLen, ctx, graphSettings); + + data.forEach(function (categ) { + //Lines + ctx.beginPath(); + ctx.lineJoin = "round"; + ctx.strokeStyle = categ.color; + + let xmax = 0; + for (let i = 0; i < arrayLen; i++) { + if (categ.values[i] === null) continue; + let scale = bounds.height - ((largest >= 0)?(bounds.bottom - bounds.xAxis):0); + let extreme = (largest<=0)?Math.abs(smallest):Math.abs(largest); + let x = bounds.left + bounds.width / (arrayLen - 1) * i; + let y = (bounds.xAxis - categ.values[i] / extreme * scale); + xmax = x; + + ctx.lineTo(x, y); + } + ctx.stroke(); + + ctx.lineTo(xmax, bounds.xAxis); + ctx.lineTo(bounds.left, bounds.xAxis); + ctx.globalAlpha = 0.5; + ctx.fillStyle = categ.color; + ctx.closePath(); + ctx.fill(); + + ctx.globalAlpha = 1; + + //Points + if (graphSettings.display_points) + drawPoints(ctx, bounds, categ.values, categ.name, arrayLen, largest, categ.color); + }); +} + +function drawBarChart(canvas, data, graphSettings) { + let ctx = canvas.getContext( "2d" ); + + let bounds = getBounds(canvas, graphSettings.margin); + ctx.shadowOffsetX = 15; + ctx.shadowOffsetY = 15; + ctx.shadowBlur = 4; + + let largest = getLargest(data); + let barCount = data.length; + let dataCount = data[0].values.length; + + let smallest = getSmallest(data); + + if (smallest < 0) + bounds.xAxis = bounds.bottom - (bounds.height / (((largest<=0)?0:Math.abs(largest)) + Math.abs(smallest)) * Math.abs(smallest)); + + drawAxis(bounds, largest, smallest, dataCount, ctx, graphSettings, false); + + let size = bounds.width / dataCount; + let innerSize = size * 0.8; + let bar_width = innerSize * 0.7 / barCount; + + for (let i = 0; i < dataCount; i++) { + let num = 0; + data.forEach(function (categ) { + ctx.beginPath(); + let value = categ.values[i]; + let left = bounds.left + (size * (i + 0.15) + (innerSize * num / barCount)); + let scale = bounds.height - ((largest >= 0)?(bounds.bottom - bounds.xAxis):0); + let extreme = (largest<=0)?Math.abs(smallest):Math.abs(largest); + let bar_height = value / extreme * scale; + let top = (bounds.xAxis - categ.values[i] / extreme * scale); + + ctx.fillStyle = categ.color; + ctx.fillRect(left, top, bar_width, bar_height); + + //x value + if (num === 0){ + let text = (i + 1).toString(); + if (graphSettings.custom_x_values !== ""){ + text = graphSettings.custom_x_values.split(';')[i]; + } + ctx.font = "16px Arial"; + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + ctx.fillText(text, bounds.width / dataCount * i + size / 2 + bounds.left, bounds.bottom + 15); + ctx.stroke(); + } + + num++; + let new_object = new Rect(value, categ.name, left, top, bar_width, bar_height); + objects.push(new_object); + }); + } +} + +function stackedChart(canvas, data, graphSettings) { + let ctx = canvas.getContext( "2d" ); + + let bounds = getBounds(canvas, graphSettings.margin); + ctx.shadowOffsetX = 15; + ctx.shadowOffsetY = 15; + ctx.shadowBlur = 4; + + let dataCount = data[0].values.length; + + let largest = 0; + for (let i = 0; i < dataCount; i++){ + let sum = 0; + data.forEach(function (categ) { + categ.values[i] = Math.abs(categ.values[i]); + sum += categ.values[i]; + }); + if (sum > largest) largest = sum; + } + + let smallest = getSmallest(data); + if (smallest < 0) + bounds.xAxis = bounds.bottom - (bounds.height / (((largest<=0)?0:Math.abs(largest)) + Math.abs(smallest)) * Math.abs(smallest)); + + drawAxis(bounds, largest, smallest, dataCount, ctx, graphSettings, false); + + let size = bounds.width / dataCount; + let bar_width = size * 0.7; + + for (let i = 0; i < dataCount; i++) { + let last_top = bounds.xAxis; + let num = 0; + data.forEach(function (categ) { + ctx.beginPath(); + + let value = categ.values[i]; + let bar_height = value / largest * bounds.height; + let left = bounds.left + (size * (i + 0.15)); + let top = last_top - bar_height; + + ctx.fillStyle = categ.color; + ctx.fillRect(left, top, bar_width, bar_height); + + last_top = top; + + //x value + if (num === 0){ + let text = (i + 1).toString(); + if (graphSettings.custom_x_values !== ""){ + text = graphSettings.custom_x_values.split(';')[i]; + } + ctx.font = "16px Arial"; + ctx.fillStyle = "black"; + ctx.textAlign = "center"; + ctx.fillText(text, bounds.width / dataCount * i + size / 2 + bounds.left, bounds.bottom + 15); + ctx.stroke(); + } + num++; + + let new_object = new Rect(value, categ.name, left, top, bar_width, bar_height); + objects.push(new_object); + }); + } +} + +function resizeCanvas(canvas, parent, legendHeight = 0, bgColor) { + + if (legendHeight > 0) legendHeight += 3.1; + //set size + canvas.style.width = parent.clientWidth.toString(); + canvas.style.height = (parent.clientHeight - legendHeight).toString(); + canvas.width = parent.clientWidth; + canvas.height = parent.clientHeight - legendHeight; + + //reset canvas color + let ctx = canvas.getContext( "2d" ); + if (bgColor == null){ + ctx.clearRect(0, 0, canvas.width, canvas.height); + } else { + ctx.fillStyle = bgColor; + ctx.fillRect(0, 0, canvas.width, canvas.height); + } +} + +function updateLegend(displayLegend, data) { + if (displayLegend){ + let legendHTML = ""; + data.forEach(function (categ) { + legendHTML += "