From 7d9c982cf5f754e6658ab198967d5e66f0c14d8f Mon Sep 17 00:00:00 2001 From: James Collins Date: Mon, 17 Apr 2023 07:16:31 +1000 Subject: [PATCH] bug fixes and updates --- .nova/Configuration.json | 3 + app/Conductors/Conductor.php | 11 +- composer.lock | 110 +-- package-lock.json | 141 ++-- resources/css/app.scss | 38 +- resources/css/variables.scss | 17 +- resources/depreciated/ProgressStore.ts | 124 +++ resources/depreciated/SMCarousel.vue | 280 +++++++ resources/depreciated/SMCarouselSlide.vue | 194 +++++ resources/depreciated/SMProgress.vue | 86 ++ resources/js/components/SMArticleCard.vue | 59 ++ resources/js/components/SMButton-copy.vue | 369 +++++++++ resources/js/components/SMButton.vue | 296 ++----- resources/js/components/SMCard.vue | 22 + resources/js/components/SMContainer.vue | 5 +- resources/js/components/SMForm.vue | 8 +- resources/js/components/SMFormCard.vue | 148 +--- resources/js/components/SMHero.vue | 57 +- resources/js/components/SMInput.vue | 578 +++---------- resources/js/components/SMInputGroup.vue | 11 + resources/js/components/SMLoadingIcon.vue | 23 +- resources/js/components/SMMastHead.vue | 3 + resources/js/components/SMNavbar.vue | 168 ++-- resources/js/components/SMPagination.vue | 150 ++-- .../dialogs/SMDialogChangePassword.vue | 2 +- resources/js/depreciated/SMInput-old.vue | 541 ++++++++++++ resources/js/directives/body-class.ts | 12 + resources/js/helpers/api.types.ts | 12 + resources/js/helpers/form.ts | 8 +- resources/js/router/index.js | 40 +- resources/js/views/App.vue | 5 +- .../js/views/{PostView.vue => Article.vue} | 0 resources/js/views/Blog.vue | 142 ++++ resources/js/views/Contact.vue | 2 +- resources/js/views/EmailVerify.vue | 2 +- resources/js/views/EventList.vue | 2 +- resources/js/views/ForgotPassword.vue | 2 +- resources/js/views/ForgotUsername.vue | 2 +- resources/js/views/Home.vue | 784 +++++++++--------- resources/js/views/Login.vue | 39 +- resources/js/views/PostList.vue | 98 --- resources/js/views/Register.vue | 125 ++- resources/js/views/ResendEmailVerify.vue | 2 +- resources/js/views/ResetPassword.vue | 2 +- resources/js/views/Unsubscribe.vue | 2 +- resources/js/views/dashboard/CreatePost.vue | 2 +- resources/js/views/dashboard/EventEdit.vue | 2 +- resources/js/views/dashboard/EventList.vue | 2 +- resources/js/views/dashboard/MediaEdit.vue | 2 +- resources/js/views/dashboard/MediaList.vue | 2 +- resources/js/views/dashboard/PostEdit.vue | 2 +- resources/js/views/dashboard/PostList.vue | 2 +- resources/js/views/dashboard/UserEdit.vue | 2 +- 53 files changed, 3040 insertions(+), 1701 deletions(-) create mode 100644 .nova/Configuration.json create mode 100644 resources/depreciated/ProgressStore.ts create mode 100644 resources/depreciated/SMCarousel.vue create mode 100644 resources/depreciated/SMCarouselSlide.vue create mode 100644 resources/depreciated/SMProgress.vue create mode 100644 resources/js/components/SMArticleCard.vue create mode 100644 resources/js/components/SMButton-copy.vue create mode 100644 resources/js/components/SMCard.vue create mode 100644 resources/js/components/SMInputGroup.vue create mode 100644 resources/js/depreciated/SMInput-old.vue create mode 100644 resources/js/directives/body-class.ts rename resources/js/views/{PostView.vue => Article.vue} (100%) create mode 100644 resources/js/views/Blog.vue delete mode 100644 resources/js/views/PostList.vue diff --git a/.nova/Configuration.json b/.nova/Configuration.json new file mode 100644 index 0000000..0db3279 --- /dev/null +++ b/.nova/Configuration.json @@ -0,0 +1,3 @@ +{ + +} diff --git a/app/Conductors/Conductor.php b/app/Conductors/Conductor.php index 7df1a4d..6c5cfbe 100644 --- a/app/Conductors/Conductor.php +++ b/app/Conductors/Conductor.php @@ -435,9 +435,10 @@ class Conductor * * @param integer $page The current page to return. * @param integer $limit The limit of items to include or use default. + * @param integer $after Start the page count after this count of rows. * @return void */ - final public function paginate(int $page = 1, int $limit = -1) + final public function paginate(int $page = 1, int $limit = -1, int $after = 0) { // Limit if ($limit < 1) { @@ -451,7 +452,13 @@ class Conductor if ($page < 1) { $page = 1; } - $this->query->offset(($page - 1) * $limit); + + // After + if ($after < 0) { + $after = 0; + } + + $this->query->offset((($page - 1) * $limit) + $after); } /** diff --git a/composer.lock b/composer.lock index 95cff92..588b303 100644 --- a/composer.lock +++ b/composer.lock @@ -62,16 +62,16 @@ }, { "name": "aws/aws-sdk-php", - "version": "3.263.8", + "version": "3.263.11", "source": { "type": "git", "url": "https://github.com/aws/aws-sdk-php.git", - "reference": "bf8a3d90eecbe66405a0598d6423d897e917f66c" + "reference": "4ac444fd1dfabe18714d05d2603e92468c00a28b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/bf8a3d90eecbe66405a0598d6423d897e917f66c", - "reference": "bf8a3d90eecbe66405a0598d6423d897e917f66c", + "url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/4ac444fd1dfabe18714d05d2603e92468c00a28b", + "reference": "4ac444fd1dfabe18714d05d2603e92468c00a28b", "shasum": "" }, "require": { @@ -150,9 +150,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.263.8" + "source": "https://github.com/aws/aws-sdk-php/tree/3.263.11" }, - "time": "2023-04-11T19:32:30+00:00" + "time": "2023-04-14T18:22:01+00:00" }, { "name": "brick/math", @@ -448,16 +448,16 @@ }, { "name": "doctrine/dbal", - "version": "3.6.1", + "version": "3.6.2", "source": { "type": "git", "url": "https://github.com/doctrine/dbal.git", - "reference": "57815c7bbcda3cd18871d253c1dd8cbe56f8526e" + "reference": "b4bd1cfbd2b916951696d82e57d054394d84864c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/dbal/zipball/57815c7bbcda3cd18871d253c1dd8cbe56f8526e", - "reference": "57815c7bbcda3cd18871d253c1dd8cbe56f8526e", + "url": "https://api.github.com/repos/doctrine/dbal/zipball/b4bd1cfbd2b916951696d82e57d054394d84864c", + "reference": "b4bd1cfbd2b916951696d82e57d054394d84864c", "shasum": "" }, "require": { @@ -473,9 +473,9 @@ "doctrine/coding-standard": "11.1.0", "fig/log-test": "^1", "jetbrains/phpstorm-stubs": "2022.3", - "phpstan/phpstan": "1.10.3", + "phpstan/phpstan": "1.10.9", "phpstan/phpstan-strict-rules": "^1.5", - "phpunit/phpunit": "9.6.4", + "phpunit/phpunit": "9.6.6", "psalm/plugin-phpunit": "0.18.4", "squizlabs/php_codesniffer": "3.7.2", "symfony/cache": "^5.4|^6.0", @@ -540,7 +540,7 @@ ], "support": { "issues": "https://github.com/doctrine/dbal/issues", - "source": "https://github.com/doctrine/dbal/tree/3.6.1" + "source": "https://github.com/doctrine/dbal/tree/3.6.2" }, "funding": [ { @@ -556,7 +556,7 @@ "type": "tidelift" } ], - "time": "2023-03-02T19:26:24+00:00" + "time": "2023-04-14T07:25:38+00:00" }, { "name": "doctrine/deprecations", @@ -3887,16 +3887,16 @@ }, { "name": "ramsey/uuid", - "version": "4.x-dev", + "version": "4.7.4", "source": { "type": "git", "url": "https://github.com/ramsey/uuid.git", - "reference": "8e955307d32dc9b6992440ff81321d3cb09db75a" + "reference": "60a4c63ab724854332900504274f6150ff26d286" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ramsey/uuid/zipball/8e955307d32dc9b6992440ff81321d3cb09db75a", - "reference": "8e955307d32dc9b6992440ff81321d3cb09db75a", + "url": "https://api.github.com/repos/ramsey/uuid/zipball/60a4c63ab724854332900504274f6150ff26d286", + "reference": "60a4c63ab724854332900504274f6150ff26d286", "shasum": "" }, "require": { @@ -3937,7 +3937,6 @@ "paragonie/random-lib": "Provides RandomLib for use with the RandomLibAdapter", "ramsey/uuid-doctrine": "Allows the use of Ramsey\\Uuid\\Uuid as Doctrine field type." }, - "default-branch": true, "type": "library", "extra": { "captainhook": { @@ -3964,7 +3963,7 @@ ], "support": { "issues": "https://github.com/ramsey/uuid/issues", - "source": "https://github.com/ramsey/uuid/tree/4.x" + "source": "https://github.com/ramsey/uuid/tree/4.7.4" }, "funding": [ { @@ -3976,7 +3975,7 @@ "type": "tidelift" } ], - "time": "2023-03-27T22:05:11+00:00" + "time": "2023-04-15T23:01:58+00:00" }, { "name": "spatie/image-optimizer", @@ -4563,16 +4562,16 @@ }, { "name": "symfony/error-handler", - "version": "v6.2.7", + "version": "v6.2.9", "source": { "type": "git", "url": "https://github.com/symfony/error-handler.git", - "reference": "61e90f94eb014054000bc902257d2763fac09166" + "reference": "e95f1273b3953c3b5e5341172dae838bacee11ee" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/error-handler/zipball/61e90f94eb014054000bc902257d2763fac09166", - "reference": "61e90f94eb014054000bc902257d2763fac09166", + "url": "https://api.github.com/repos/symfony/error-handler/zipball/e95f1273b3953c3b5e5341172dae838bacee11ee", + "reference": "e95f1273b3953c3b5e5341172dae838bacee11ee", "shasum": "" }, "require": { @@ -4614,7 +4613,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/v6.2.7" + "source": "https://github.com/symfony/error-handler/tree/v6.2.9" }, "funding": [ { @@ -4630,7 +4629,7 @@ "type": "tidelift" } ], - "time": "2023-02-14T08:44:56+00:00" + "time": "2023-04-11T16:03:19+00:00" }, { "name": "symfony/event-dispatcher", @@ -4938,16 +4937,16 @@ }, { "name": "symfony/http-kernel", - "version": "v6.2.8", + "version": "v6.2.9", "source": { "type": "git", "url": "https://github.com/symfony/http-kernel.git", - "reference": "9563229e56076070d92ca30c089e801e8a4629a3" + "reference": "02246510cf7031726f7237138d61b796b95799b3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/http-kernel/zipball/9563229e56076070d92ca30c089e801e8a4629a3", - "reference": "9563229e56076070d92ca30c089e801e8a4629a3", + "url": "https://api.github.com/repos/symfony/http-kernel/zipball/02246510cf7031726f7237138d61b796b95799b3", + "reference": "02246510cf7031726f7237138d61b796b95799b3", "shasum": "" }, "require": { @@ -5029,7 +5028,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/v6.2.8" + "source": "https://github.com/symfony/http-kernel/tree/v6.2.9" }, "funding": [ { @@ -5045,7 +5044,7 @@ "type": "tidelift" } ], - "time": "2023-03-31T12:00:10+00:00" + "time": "2023-04-13T16:41:43+00:00" }, { "name": "symfony/mailer", @@ -7107,16 +7106,16 @@ }, { "name": "filp/whoops", - "version": "2.15.1", + "version": "2.15.2", "source": { "type": "git", "url": "https://github.com/filp/whoops.git", - "reference": "e864ac957acd66e1565f25efda61e37791a5db0b" + "reference": "aac9304c5ed61bf7b1b7a6064bf9806ab842ce73" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/filp/whoops/zipball/e864ac957acd66e1565f25efda61e37791a5db0b", - "reference": "e864ac957acd66e1565f25efda61e37791a5db0b", + "url": "https://api.github.com/repos/filp/whoops/zipball/aac9304c5ed61bf7b1b7a6064bf9806ab842ce73", + "reference": "aac9304c5ed61bf7b1b7a6064bf9806ab842ce73", "shasum": "" }, "require": { @@ -7166,7 +7165,7 @@ ], "support": { "issues": "https://github.com/filp/whoops/issues", - "source": "https://github.com/filp/whoops/tree/2.15.1" + "source": "https://github.com/filp/whoops/tree/2.15.2" }, "funding": [ { @@ -7174,7 +7173,7 @@ "type": "github" } ], - "time": "2023-03-06T18:09:13+00:00" + "time": "2023-04-12T12:00:00+00:00" }, { "name": "hamcrest/hamcrest-php", @@ -8008,16 +8007,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.6.6", + "version": "9.6.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "b65d59a059d3004a040c16a82e07bbdf6cfdd115" + "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/b65d59a059d3004a040c16a82e07bbdf6cfdd115", - "reference": "b65d59a059d3004a040c16a82e07bbdf6cfdd115", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", + "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", "shasum": "" }, "require": { @@ -8091,7 +8090,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.6" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.7" }, "funding": [ { @@ -8107,7 +8106,7 @@ "type": "tidelift" } ], - "time": "2023-03-27T11:43:46+00:00" + "time": "2023-04-14T08:58:40+00:00" }, { "name": "sebastian/cli-parser", @@ -9206,33 +9205,42 @@ }, { "name": "spatie/ignition", - "version": "1.4.5", + "version": "1.5.0", "source": { "type": "git", "url": "https://github.com/spatie/ignition.git", - "reference": "cc09114b7057bd217b676f047544b33f5b6247e6" + "reference": "4db9c9626e4d7745efbe0b512157326190b41b65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/ignition/zipball/cc09114b7057bd217b676f047544b33f5b6247e6", - "reference": "cc09114b7057bd217b676f047544b33f5b6247e6", + "url": "https://api.github.com/repos/spatie/ignition/zipball/4db9c9626e4d7745efbe0b512157326190b41b65", + "reference": "4db9c9626e4d7745efbe0b512157326190b41b65", "shasum": "" }, "require": { "ext-json": "*", "ext-mbstring": "*", "php": "^8.0", + "spatie/backtrace": "^1.4", "spatie/flare-client-php": "^1.1", "symfony/console": "^5.4|^6.0", "symfony/var-dumper": "^5.4|^6.0" }, "require-dev": { + "illuminate/cache": "^9.52", "mockery/mockery": "^1.4", "pestphp/pest": "^1.20", "phpstan/extension-installer": "^1.1", "phpstan/phpstan-deprecation-rules": "^1.0", "phpstan/phpstan-phpunit": "^1.0", - "symfony/process": "^5.4|^6.0" + "psr/simple-cache-implementation": "*", + "symfony/cache": "^6.2", + "symfony/process": "^5.4|^6.0", + "vlucas/phpdotenv": "^5.5" + }, + "suggest": { + "openai-php/client": "Require get solutions from OpenAI", + "simple-cache-implementation": "To cache solutions from OpenAI" }, "type": "library", "extra": { @@ -9276,7 +9284,7 @@ "type": "github" } ], - "time": "2023-02-28T16:49:47+00:00" + "time": "2023-04-12T09:07:50+00:00" }, { "name": "spatie/laravel-ignition", diff --git a/package-lock.json b/package-lock.json index a496dc4..40cee47 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1607,9 +1607,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001478", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001478.tgz", - "integrity": "sha512-gMhDyXGItTHipJj2ApIvR+iVB5hd0KP3svMWWXDvZOmjzJJassGLMfxRkQCSYgGd2gtdL/ReeiyvMSFD1Ss6Mw==", + "version": "1.0.30001479", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001479.tgz", + "integrity": "sha512-6nuRFim5dx8Eu2tO+KJ9PiBdPHs7WB5Hdf+klDcyefyEuOAcfhihIv7pS+JFknJLUiNQbm1AJYKm0c9QOlQS/Q==", "funding": [ { "type": "opencollective", @@ -1917,9 +1917,9 @@ } }, "node_modules/dompurify": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.0.1.tgz", - "integrity": "sha512-60tsgvPKwItxZZdfLmamp0MTcecCta3avOhsLgPZ0qcWt96OasFfhkeIRbJ6br5i0fQawT1/RBGB5L58/Jpwuw==" + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/dompurify/-/dompurify-3.0.2.tgz", + "integrity": "sha512-B8c6JdiEpxAKnd8Dm++QQxJL4lfuc757scZtcapj6qjTjrQzyq5iAyznLKVvK+77eYNiFblHBlt7MM0fOeqoKw==" }, "node_modules/dotenv": { "version": "16.0.3", @@ -1936,9 +1936,9 @@ "dev": true }, "node_modules/electron-to-chromium": { - "version": "1.4.359", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.359.tgz", - "integrity": "sha512-OoVcngKCIuNXtZnsYoqlCvr0Cf3NIPzDIgwUfI9bdTFjXCrr79lI0kwQstLPZ7WhCezLlGksZk/BFAzoXC7GDw==", + "version": "1.4.365", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.365.tgz", + "integrity": "sha512-FRHZO+1tUNO4TOPXmlxetkoaIY8uwHzd1kKopK/Gx2SKn1L47wJXWD44wxP5CGRyyP98z/c8e1eBzJrgPeiBOg==", "peer": true }, "node_modules/emoji-regex": { @@ -1969,9 +1969,9 @@ } }, "node_modules/es-module-lexer": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-0.9.3.tgz", - "integrity": "sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ==", + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-1.2.1.tgz", + "integrity": "sha512-9978wrXM50Y4rTMmW5kXIC09ZdXQZqkE4mxhwkd8VbzsGkXGPgV4zWuqQJgCEzYngdo2dYDa0l8xhX4fkSwJSg==", "peer": true }, "node_modules/esbuild": { @@ -2122,9 +2122,9 @@ } }, "node_modules/eslint-plugin-vue": { - "version": "9.10.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-vue/-/eslint-plugin-vue-9.10.0.tgz", - "integrity": "sha512-2MgP31OBf8YilUvtakdVMc8xVbcMp7z7/iQj8LHVpXrSXHPXSJRUIGSPFI6b6pyCx/buKaFJ45ycqfHvQRiW2g==", + "version": "9.11.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-vue/-/eslint-plugin-vue-9.11.0.tgz", + "integrity": "sha512-bBCJAZnkBV7ATH4Z1E7CvN3nmtS4H7QUU3UBxPdo8WohRU+yHjnQRALpTbxMVcz0e4Mx3IyxIdP5HYODMxK9cQ==", "dev": true, "dependencies": { "@eslint-community/eslint-utils": "^4.3.0", @@ -2167,9 +2167,9 @@ } }, "node_modules/eslint/node_modules/eslint-scope": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz", - "integrity": "sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", "dev": true, "dependencies": { "esrecurse": "^4.3.0", @@ -2177,6 +2177,9 @@ }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/eslint/node_modules/estraverse": { @@ -3276,6 +3279,31 @@ "pinia": "^2.0.0" } }, + "node_modules/pinia/node_modules/vue-demi": { + "version": "0.14.0", + "resolved": "https://registry.npmjs.org/vue-demi/-/vue-demi-0.14.0.tgz", + "integrity": "sha512-gt58r2ogsNQeVoQ3EhoUAvUsH9xviydl0dWJj7dabBC/2L4uBId7ujtCwDRD0JhkGsV1i0CtfLAeyYKBht9oWg==", + "hasInstallScript": true, + "bin": { + "vue-demi-fix": "bin/vue-demi-fix.js", + "vue-demi-switch": "bin/vue-demi-switch.js" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/antfu" + }, + "peerDependencies": { + "@vue/composition-api": "^1.0.0-rc.1", + "vue": "^3.0.0-0 || ^2.6.0" + }, + "peerDependenciesMeta": { + "@vue/composition-api": { + "optional": true + } + } + }, "node_modules/pkg-types": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/pkg-types/-/pkg-types-1.0.2.tgz", @@ -3288,9 +3316,9 @@ } }, "node_modules/postcss": { - "version": "8.4.21", - "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.21.tgz", - "integrity": "sha512-tP7u/Sn/dVxK2NnruI4H9BG+x+Wxz6oeZ1cJ8P6G/PZY0IKk4k/63TDsQf2kQq3+qoJeLm2kIBUNlZe3zgb4Zg==", + "version": "8.4.22", + "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.22.tgz", + "integrity": "sha512-XseknLAfRHzVWjCEtdviapiBtfLdgyzExD50Rg2ePaucEesyh8Wv4VPdW0nbyDa1ydbrAxV19jvMT4+LFmcNUA==", "funding": [ { "type": "opencollective", @@ -3299,10 +3327,14 @@ { "type": "tidelift", "url": "https://tidelift.com/funding/github/npm/postcss" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" } ], "dependencies": { - "nanoid": "^3.3.4", + "nanoid": "^3.3.6", "picocolors": "^1.0.0", "source-map-js": "^1.0.2" }, @@ -3433,11 +3465,11 @@ "integrity": "sha512-aGTxYSk3FFNKnXeKDbLpgRDRyIHRZNBF5HyaXXAN1Aj4TSyyZvmoAn9CylvpqLV3pYpIQavwc+2rzhNFn5SsLQ==" }, "node_modules/resolve": { - "version": "1.22.2", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.2.tgz", - "integrity": "sha512-Sb+mjNHOULsBv818T40qSPeRiuWLyaGMa5ewydRLFimneixmVy2zdivRl+AF6jaYPC8ERxGDmFSiqui6SfPd+g==", + "version": "1.22.3", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.3.tgz", + "integrity": "sha512-P8ur/gp/AmbEzjr729bZnLjXK5Z+4P0zhIJgBgzqRih7hL7BOukHGtSTA3ACMY467GRFz3duQsi0bDZdR7DKdw==", "dependencies": { - "is-core-module": "^2.11.0", + "is-core-module": "^2.12.0", "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" }, @@ -3489,9 +3521,9 @@ } }, "node_modules/rollup": { - "version": "3.20.2", - "resolved": "https://registry.npmjs.org/rollup/-/rollup-3.20.2.tgz", - "integrity": "sha512-3zwkBQl7Ai7MFYQE0y1MeQ15+9jsi7XxfrqwTb/9EK8D9C9+//EBR4M+CuA1KODRaNbFez/lWxA5vhEGZp4MUg==", + "version": "3.20.3", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-3.20.3.tgz", + "integrity": "sha512-u6/O1X42CAZ79rbk+smyONJQLTpwFBL7InpRa/AVWia5lq60w5J/PUsVHCOgSolN0X9R2GjQ41fZm3x28Hk1lA==", "bin": { "rollup": "dist/bin/rollup" }, @@ -3572,9 +3604,9 @@ } }, "node_modules/schema-utils": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.1.tgz", - "integrity": "sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==", + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/schema-utils/-/schema-utils-3.1.2.tgz", + "integrity": "sha512-pvjEHOgWc9OWA/f/DE3ohBWTD6EleVLf7iFUkoSwAxttdBhB9QUebQgxER2kWueOvRJXPHNnyrvvh9eZINB8Eg==", "peer": true, "dependencies": { "@types/json-schema": "^7.0.8", @@ -4143,9 +4175,9 @@ } }, "node_modules/update-browserslist-db": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.10.tgz", - "integrity": "sha512-OztqDenkfFkbSG+tRxBeAnCVPckDBcvibKd35yDONx6OU8N7sqgwc7rCbkJ/WcYtVRZ4ba68d6byhC21GFh7sQ==", + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz", + "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==", "funding": [ { "type": "opencollective", @@ -4154,6 +4186,10 @@ { "type": "tidelift", "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" } ], "peer": true, @@ -4162,7 +4198,7 @@ "picocolors": "^1.0.0" }, "bin": { - "browserslist-lint": "cli.js" + "update-browserslist-db": "cli.js" }, "peerDependencies": { "browserslist": ">= 4.21.0" @@ -4262,9 +4298,9 @@ } }, "node_modules/vite-plugin-compression2": { - "version": "0.8.3", - "resolved": "https://registry.npmjs.org/vite-plugin-compression2/-/vite-plugin-compression2-0.8.3.tgz", - "integrity": "sha512-wri+73Pa8Lf31utYXWg2xdCgEY7Y9is5jGphbT2tfKF2d6GzdRwG44zuHA0GmrzAoablCHj6qCpDG4gHPhQwcw==", + "version": "0.8.4", + "resolved": "https://registry.npmjs.org/vite-plugin-compression2/-/vite-plugin-compression2-0.8.4.tgz", + "integrity": "sha512-/AEvCzKDmazIJUzyBvFxDuXcwi/x5RH2WpJXoiiRslzvIb5qiB5/1PUKxGv/YqhCq2mxhmXwfLywWDNYXrlPZg==", "dev": true, "dependencies": { "@rollup/pluginutils": "^5.0.2" @@ -4427,9 +4463,9 @@ } }, "node_modules/vue-eslint-parser/node_modules/eslint-scope": { - "version": "7.1.1", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.1.1.tgz", - "integrity": "sha512-QKQM/UXpIiHcLqJ5AOyIW7XZmzjkzQXYE54n1++wb0u9V/abW3l9uQnxX8Z5Xd18xyKIMTUAyQ0k1e8pz6LUrw==", + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", "dev": true, "dependencies": { "esrecurse": "^4.3.0", @@ -4437,6 +4473,9 @@ }, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/vue-eslint-parser/node_modules/estraverse": { @@ -4527,13 +4566,13 @@ "dev": true }, "node_modules/webpack": { - "version": "5.78.0", - "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.78.0.tgz", - "integrity": "sha512-gT5DP72KInmE/3azEaQrISjTvLYlSM0j1Ezhht/KLVkrqtv10JoP/RXhwmX/frrutOPuSq3o5Vq0ehR/4Vmd1g==", + "version": "5.79.0", + "resolved": "https://registry.npmjs.org/webpack/-/webpack-5.79.0.tgz", + "integrity": "sha512-3mN4rR2Xq+INd6NnYuL9RC9GAmc1ROPKJoHhrZ4pAjdMFEkJJWrsPw8o2JjCIyQyTu7rTXYn4VG6OpyB3CobZg==", "peer": true, "dependencies": { "@types/eslint-scope": "^3.7.3", - "@types/estree": "^0.0.51", + "@types/estree": "^1.0.0", "@webassemblyjs/ast": "1.11.1", "@webassemblyjs/wasm-edit": "1.11.1", "@webassemblyjs/wasm-parser": "1.11.1", @@ -4542,7 +4581,7 @@ "browserslist": "^4.14.5", "chrome-trace-event": "^1.0.2", "enhanced-resolve": "^5.10.0", - "es-module-lexer": "^0.9.0", + "es-module-lexer": "^1.2.1", "eslint-scope": "5.1.1", "events": "^3.2.0", "glob-to-regexp": "^0.4.1", @@ -4553,7 +4592,7 @@ "neo-async": "^2.6.2", "schema-utils": "^3.1.0", "tapable": "^2.1.1", - "terser-webpack-plugin": "^5.1.3", + "terser-webpack-plugin": "^5.3.7", "watchpack": "^2.4.0", "webpack-sources": "^3.2.3" }, @@ -4587,12 +4626,6 @@ "integrity": "sha512-kyDivFZ7ZM0BVOUteVbDFhlRt7Ah/CSPwJdi8hBpkK7QLumUqdLtVfm/PX/hkcnrvr0i77fO5+TjZ94Pe+C9iw==", "dev": true }, - "node_modules/webpack/node_modules/@types/estree": { - "version": "0.0.51", - "resolved": "https://registry.npmjs.org/@types/estree/-/estree-0.0.51.tgz", - "integrity": "sha512-CuPgU6f3eT/XgKKPqKd/gLZV1Xmvf1a2R5POBOGQa6uv82xpls89HU5zKeVoyR8XzHd1RGNOlQlvUe3CFkjWNQ==", - "peer": true - }, "node_modules/whatwg-url": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", diff --git a/resources/css/app.scss b/resources/css/app.scss index 0cda958..b15671b 100644 --- a/resources/css/app.scss +++ b/resources/css/app.scss @@ -36,11 +36,16 @@ h4, h5, h6 { font-family: var(--header-font-family); + font-weight: 800; + margin-bottom: 0; +} + +h1 { + font-size: 42px; } h2 { font-size: 36px; - margin-bottom: 0; } a, @@ -70,37 +75,6 @@ small, padding: 0 16px; } -.card { - background-color: var(--card-color); - border-radius: 10px; - box-shadow: 0 11px 10px -10px rgba(0, 0, 0, 0.2); - margin: 48px auto 48px auto; - - .card-header { - text-align: center; - padding: 24px 48px 0; - - p { - opacity: 0.6; - } - } - - .card-body { - padding: 0 48px; - } - - .card-footer { - display: flex; - align-items: center; - justify-content: space-between; - padding: 0 48px 24px 48px; - } - - .btn { - background-color: var(--base-color-dark); - } -} - .btn { cursor: pointer; position: relative; diff --git a/resources/css/variables.scss b/resources/css/variables.scss index b39edbe..e306bec 100644 --- a/resources/css/variables.scss +++ b/resources/css/variables.scss @@ -5,6 +5,7 @@ --base-color-text: rgba(0, 0, 0, 0.8); --base-color-light: #fff; --base-color-dark: #ddd; + --base-color-darker: #999; --base-shadow: 0 0 4px rgba(0, 0, 0, 0.2); --default-font-size: 18px; @@ -19,10 +20,16 @@ --primary-color-dark: #0e80ce; --primary-color-darker: #095589; + --danger-color-lighter: #f3c8c8; + --danger-color-light: #db5c5a; + --danger-color: #c82e2b; + --danger-color-dark: #952220; + --danger-color-darker: #641715; + --header-font-family: "Montserrat", "Montserrat override", "Arial", "Helvetica", sans-serif; - --navbar-color: rgba(255, 255, 255, 0.1); + --navbar-color: var(--base-color-light); --navbar-color-dropdown: var(--base-color-light); --card-color: var(--base-color-light); @@ -38,7 +45,7 @@ --base-color-text: rgba(255, 255, 255, 0.9); --base-color-light: #333; --base-color-dark: #444; - --base-color-darker: #555; + --base-color-darker: #999; --footer-color-text: #999; --footer-color-border: rgba(255, 255, 255, 0.1); @@ -48,6 +55,12 @@ --primary-color: #35a5f1; --primary-color-dark: #67bbf4; --primary-color-darker: #cce8fb; + + --danger-color-lighter: #f3c8c8; + --danger-color-light: #db5c5a; + --danger-color: #db5c5a; + --danger-color-dark: #952220; + --danger-color-darker: #641715; } } diff --git a/resources/depreciated/ProgressStore.ts b/resources/depreciated/ProgressStore.ts new file mode 100644 index 0000000..d03cb97 --- /dev/null +++ b/resources/depreciated/ProgressStore.ts @@ -0,0 +1,124 @@ +import { defineStore } from "pinia"; +import { clamp } from "../helpers/utils"; + +export interface ProgressStore { + spinner: number; + status: number; + opacity: number; + queue: number; + timeoutID: number | null; +} + +export const useProgressStore = defineStore({ + id: "progress", + state: (): ProgressStore => ({ + spinner: 0, + status: 0, + opacity: 0, + queue: 0, + timeoutID: null, + }), + + actions: { + start() { + if (this.queue == 0 && this.opacity == 0) { + this.set(0); + + const work = () => { + window.setTimeout(() => { + if (this.status < 1) { + this._trickle(); + work(); + } + }, 200); + }; + + work(); + + if (this.opacity == 0) { + if (this.timeoutID != null) { + window.clearTimeout(this.timeoutID); + } + + this.timeoutID = window.setTimeout(() => { + this._show(); + this.timeoutID = null; + }, 2000); + } + + if (this.spinner == 0) { + this.spinner = 1; + } + } + + ++this.queue; + }, + + set(number: number) { + const n = clamp(number, 0.08, 1); + this.status = n; + }, + + finish() { + if (this.queue > 0) { + --this.queue; + } + }, + + _trickle() { + const n = this.status; + + if (this.queue == 0) { + if (this.opacity == 0 && this.timeoutID != null) { + this._hide(); + window.clearTimeout(this.timeoutID); + this.timeoutID = null; + } else if (this.timeoutID == null) { + this.timeoutID = window.setTimeout(() => { + this.set(1); + this.timeoutID = null; + + this.timeoutID = window.setTimeout(() => { + this._hide(); + this.timeoutID = null; + + window.setTimeout(() => { + this.status = 0; + }, 150); + }, 500); + }, 500); + } + } + + if (n > 0 && n < 1) { + let amount = 0; + + if (n >= 0 && n < 0.2) { + amount = 0.1; + } else if (n >= 0.2 && n < 0.5) { + amount = 0.04; + } else if (n >= 0.5 && n < 0.8) { + amount = 0.02; + } else if (n >= 0.8 && n < 0.99) { + amount = 0.005; + } else { + amount = 0; + } + + this.set(clamp(n + amount, 0, 0.994)); + } + }, + + _show() { + this.opacity = 1; + }, + + _hide() { + this.opacity = 0; + + if (this.spinner == 1) { + this.spinner = 0; + } + }, + }, +}); diff --git a/resources/depreciated/SMCarousel.vue b/resources/depreciated/SMCarousel.vue new file mode 100644 index 0000000..461699c --- /dev/null +++ b/resources/depreciated/SMCarousel.vue @@ -0,0 +1,280 @@ + + + + + diff --git a/resources/depreciated/SMCarouselSlide.vue b/resources/depreciated/SMCarouselSlide.vue new file mode 100644 index 0000000..5e0f175 --- /dev/null +++ b/resources/depreciated/SMCarouselSlide.vue @@ -0,0 +1,194 @@ + + + + + diff --git a/resources/depreciated/SMProgress.vue b/resources/depreciated/SMProgress.vue new file mode 100644 index 0000000..19a9115 --- /dev/null +++ b/resources/depreciated/SMProgress.vue @@ -0,0 +1,86 @@ + + + + + diff --git a/resources/js/components/SMArticleCard.vue b/resources/js/components/SMArticleCard.vue new file mode 100644 index 0000000..5097455 --- /dev/null +++ b/resources/js/components/SMArticleCard.vue @@ -0,0 +1,59 @@ + + + + + diff --git a/resources/js/components/SMButton-copy.vue b/resources/js/components/SMButton-copy.vue new file mode 100644 index 0000000..e6803a2 --- /dev/null +++ b/resources/js/components/SMButton-copy.vue @@ -0,0 +1,369 @@ + + + + + diff --git a/resources/js/components/SMButton.vue b/resources/js/components/SMButton.vue index e6803a2..d561a27 100644 --- a/resources/js/components/SMButton.vue +++ b/resources/js/components/SMButton.vue @@ -3,27 +3,20 @@ v-if="isEmpty(to)" :disabled="disabled" :class="[ - 'sm-button', + 'button', classType, - { 'sm-button-small': small }, - { 'sm-button-block': block }, - { 'sm-dropdown-button': dropdown }, + { 'button-small': small }, + { 'button-block': block }, + { 'dropdown-button': dropdown }, ]" + ref="buttonRef" + :style="{ minWidth: minWidth }" :type="buttonType" @click="handleClick"> - - {{ label }} -
+ {{ props.label }} + - {{ label }} - + {{ label }} {{ label }} @@ -68,12 +62,13 @@ diff --git a/resources/js/components/SMCard.vue b/resources/js/components/SMCard.vue new file mode 100644 index 0000000..76d777b --- /dev/null +++ b/resources/js/components/SMCard.vue @@ -0,0 +1,22 @@ + + + + + diff --git a/resources/js/components/SMContainer.vue b/resources/js/components/SMContainer.vue index 64b551b..35bc1dd 100644 --- a/resources/js/components/SMContainer.vue +++ b/resources/js/components/SMContainer.vue @@ -10,13 +10,14 @@ @@ -24,7 +25,7 @@ const slots = useSlots(); .sm-container { display: flex; width: 100%; - align-items: center; + // align-items: center; flex-direction: column; padding: 0 16px 0 16px; margin: auto; diff --git a/resources/js/components/SMForm.vue b/resources/js/components/SMForm.vue index b16757c..bd708b7 100644 --- a/resources/js/components/SMForm.vue +++ b/resources/js/components/SMForm.vue @@ -1,5 +1,5 @@