From 9b5e4ca31a21a858c26c712f73021504ab99b019 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 21:45:54 +0200 Subject: [PATCH 01/17] Refactor: Move Hyde facade methods to traits --- src/Hyde.php | 158 ++----------------------- src/Services/Internal/AssetManager.php | 35 ++++++ src/Services/Internal/FileHelpers.php | 126 ++++++++++++++++++++ 3 files changed, 173 insertions(+), 146 deletions(-) create mode 100644 src/Services/Internal/AssetManager.php create mode 100644 src/Services/Internal/FileHelpers.php diff --git a/src/Hyde.php b/src/Hyde.php index db831445..60d45867 100644 --- a/src/Hyde.php +++ b/src/Hyde.php @@ -3,14 +3,25 @@ namespace Hyde\Framework; use Composer\InstalledVersions; +use Hyde\Framework\Services\Internal\AssetManager; +use Hyde\Framework\Services\Internal\FileHelpers; use Illuminate\Support\Collection; use Illuminate\Support\Str; /** * General interface for Hyde services. + * + * @package Hyde\Framework + * @author Caen De Silva + * @copyright 2022 Caen De Silva + * @license MIT License + * @link https://hydephp.github.io/ */ class Hyde { + use FileHelpers; + use AssetManager; + /** * Return the Composer Package Version. * @@ -21,148 +32,6 @@ public static function version(): string return InstalledVersions::getPrettyVersion('hyde/framework') ?: 'unreleased'; } - /** - * Return the Tailwind CDN if enabled. - */ - public static function tailwind(): string|false - { - return config('hyde.loadTailwindFromCDN') - ? 'https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.3.1/dist/app.css' - : false; - } - - /** - * Return the Hyde stylesheet. - */ - public static function styles(): string - { - return 'https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.3.1/dist/hyde.css'; - } - - /** - * Return the Hyde scripts. - */ - public static function scripts(): string - { - return 'https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.3.1/dist/hyde.js'; - } - - /** - * Get the subdirectory compiled documentation files are stored in. - * - * @return string - */ - public static function docsDirectory(): string - { - return trim(config('hyde.docsDirectory', 'docs'), '/\\'); - } - - /** - * Get the path to the frontpage for the documentation. - * - * @return string|false returns false if no frontpage is found - */ - public static function docsIndexPath(): string|false - { - if (file_exists(Hyde::path('_docs/index.md'))) { - return Hyde::docsDirectory().'/index.html'; - } - - if (file_exists(Hyde::path('_docs/readme.md'))) { - return Hyde::docsDirectory().'/readme.html'; - } - - return false; - } - - /** - * Get an absolute file path from a supplied relative path. - * - * The function returns the fully qualified path to your site's root directory. - * - * You may also use the function to generate a fully qualified path to a given file - * relative to the project root directory when supplying the path argument. - * - * @param string $path - * @return string - */ - public static function path(string $path = ''): string - { - if (empty($path)) { - return getcwd(); - } - - $path = trim($path, '/\\'); - - return getcwd().DIRECTORY_SEPARATOR.$path; - } - - /** - * Works similarly to the path() function, but returns a file in the Framework package. - * - * @param string $path - * @return string - */ - public static function vendorPath(string $path = ''): string - { - return static::path('vendor/hyde/framework/'.trim($path, '/\\')); - } - - /** - * Inject the proper number of `../` before the links in Blade templates. - * - * @param string $destination the route to format - * @param string $current the current route - * @return string - */ - public static function relativePath(string $destination, string $current = ''): string - { - $nestCount = substr_count($current, '/'); - $route = ''; - if ($nestCount > 0) { - $route .= str_repeat('../', $nestCount); - } - $route .= $destination; - - return $route; - } - - /** - * Return a qualified URI path, if SITE_URL is set in .env, else return false. - * - * @param string|null $path optional relative path suffix. Omit to return base url. - * @return string|false - */ - public static function uriPath(?string $path = ''): string|false - { - if (config('hyde.site_url', false)) { - return rtrim(config('hyde.site_url'), '/').'/'.(trim($path, '/') ?? ''); - } - - return false; - } - - /** - * Wrapper for the copy function, but allows choosing if files may be overwritten. - * - * @param string $from The source file path. - * @param string $to The destination file path. - * @param bool $force If true, existing files will be overwritten. - * @return bool|int Returns true|false on copy() success|failure, or an error code on failure - */ - public static function copy(string $from, string $to, bool $force = false): bool|int - { - if (! file_exists($from)) { - return 404; - } - - if (file_exists($to) && ! $force) { - return 409; - } - - return copy($from, $to); - } - /** * Create a title from a kebab-case slug. * @@ -177,11 +46,8 @@ public static function titleFromSlug(string $slug): string /** * Get a Laravel Collection of all Posts as MarkdownPost objects. * - * Serves as a static shorthand for \Hyde\Framework\Models\MarkdownPost::getCollection() - * * @return \Illuminate\Support\Collection - * - * @throws \Exception + * @throws \Exception if the posts' directory does not exist */ public static function getLatestPosts(): Collection { diff --git a/src/Services/Internal/AssetManager.php b/src/Services/Internal/AssetManager.php new file mode 100644 index 00000000..78c1f774 --- /dev/null +++ b/src/Services/Internal/AssetManager.php @@ -0,0 +1,35 @@ + 0) { + $route .= str_repeat('../', $nestCount); + } + $route .= $destination; + + return $route; + } + + /** + * Return a qualified URI path, if SITE_URL is set in .env, else return false. + * + * @param string|null $path optional relative path suffix. Omit to return base url. + * @return string|false + */ + public static function uriPath(?string $path = ''): string|false + { + if (config('hyde.site_url', false)) { + return rtrim(config('hyde.site_url'), '/').'/'.(trim($path, '/') ?? ''); + } + + return false; + } + + /** + * Wrapper for the copy function, but allows choosing if files may be overwritten. + * + * @param string $from The source file path. + * @param string $to The destination file path. + * @param bool $force If true, existing files will be overwritten. + * @return bool|int Returns true|false on copy() success|failure, or an error code on failure + */ + public static function copy(string $from, string $to, bool $force = false): bool|int + { + if (! file_exists($from)) { + return 404; + } + + if (file_exists($to) && ! $force) { + return 409; + } + + return copy($from, $to); + } +} \ No newline at end of file From f9fcb1778e63a31a303a230f7354f754620cfe9f Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 27 Apr 2022 19:46:04 +0000 Subject: [PATCH 02/17] Apply fixes from StyleCI [ci skip] [skip ci] --- src/Hyde.php | 3 ++- src/Services/Internal/AssetManager.php | 2 +- src/Services/Internal/FileHelpers.php | 3 +-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Hyde.php b/src/Hyde.php index 60d45867..7bd6ae00 100644 --- a/src/Hyde.php +++ b/src/Hyde.php @@ -11,10 +11,10 @@ /** * General interface for Hyde services. * - * @package Hyde\Framework * @author Caen De Silva * @copyright 2022 Caen De Silva * @license MIT License + * * @link https://hydephp.github.io/ */ class Hyde @@ -47,6 +47,7 @@ public static function titleFromSlug(string $slug): string * Get a Laravel Collection of all Posts as MarkdownPost objects. * * @return \Illuminate\Support\Collection + * * @throws \Exception if the posts' directory does not exist */ public static function getLatestPosts(): Collection diff --git a/src/Services/Internal/AssetManager.php b/src/Services/Internal/AssetManager.php index 78c1f774..90d7b7ac 100644 --- a/src/Services/Internal/AssetManager.php +++ b/src/Services/Internal/AssetManager.php @@ -32,4 +32,4 @@ public static function scripts(): string { return 'https://cdn.jsdelivr.net/gh/hydephp/hydefront@v1.3.1/dist/hyde.js'; } -} \ No newline at end of file +} diff --git a/src/Services/Internal/FileHelpers.php b/src/Services/Internal/FileHelpers.php index 915970f8..4e6e1da3 100644 --- a/src/Services/Internal/FileHelpers.php +++ b/src/Services/Internal/FileHelpers.php @@ -7,7 +7,6 @@ */ trait FileHelpers { - /** * Get the subdirectory compiled documentation files are stored in. * @@ -123,4 +122,4 @@ public static function copy(string $from, string $to, bool $force = false): bool return copy($from, $to); } -} \ No newline at end of file +} From 3b2f7cf10181057473e353bcbf093d9fcbcd92b9 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 21:55:01 +0200 Subject: [PATCH 03/17] Refactor: Move traits into Concerns/ --- src/{Models => Concerns}/HasAuthor.php | 0 src/{Models => Concerns}/HasDateString.php | 0 src/{Models => Concerns}/HasDynamicTitle.php | 0 src/{Models => Concerns}/HasFeaturedImage.php | 0 src/{Models => Concerns}/HasMetadata.php | 0 src/{Models => Concerns}/HasTableOfContents.php | 0 6 files changed, 0 insertions(+), 0 deletions(-) rename src/{Models => Concerns}/HasAuthor.php (100%) rename src/{Models => Concerns}/HasDateString.php (100%) rename src/{Models => Concerns}/HasDynamicTitle.php (100%) rename src/{Models => Concerns}/HasFeaturedImage.php (100%) rename src/{Models => Concerns}/HasMetadata.php (100%) rename src/{Models => Concerns}/HasTableOfContents.php (100%) diff --git a/src/Models/HasAuthor.php b/src/Concerns/HasAuthor.php similarity index 100% rename from src/Models/HasAuthor.php rename to src/Concerns/HasAuthor.php diff --git a/src/Models/HasDateString.php b/src/Concerns/HasDateString.php similarity index 100% rename from src/Models/HasDateString.php rename to src/Concerns/HasDateString.php diff --git a/src/Models/HasDynamicTitle.php b/src/Concerns/HasDynamicTitle.php similarity index 100% rename from src/Models/HasDynamicTitle.php rename to src/Concerns/HasDynamicTitle.php diff --git a/src/Models/HasFeaturedImage.php b/src/Concerns/HasFeaturedImage.php similarity index 100% rename from src/Models/HasFeaturedImage.php rename to src/Concerns/HasFeaturedImage.php diff --git a/src/Models/HasMetadata.php b/src/Concerns/HasMetadata.php similarity index 100% rename from src/Models/HasMetadata.php rename to src/Concerns/HasMetadata.php diff --git a/src/Models/HasTableOfContents.php b/src/Concerns/HasTableOfContents.php similarity index 100% rename from src/Models/HasTableOfContents.php rename to src/Concerns/HasTableOfContents.php From 96c73aa01946e5f6b862dbf66ffd974d65a3b97f Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 21:55:18 +0200 Subject: [PATCH 04/17] Refactor: Update namespaces --- src/Concerns/HasAuthor.php | 3 ++- src/Concerns/HasDateString.php | 4 +++- src/Concerns/HasDynamicTitle.php | 3 ++- src/Concerns/HasFeaturedImage.php | 5 ++++- src/Concerns/HasMetadata.php | 3 ++- src/Concerns/HasTableOfContents.php | 3 ++- 6 files changed, 15 insertions(+), 6 deletions(-) diff --git a/src/Concerns/HasAuthor.php b/src/Concerns/HasAuthor.php index 9cc892ff..b65ef311 100644 --- a/src/Concerns/HasAuthor.php +++ b/src/Concerns/HasAuthor.php @@ -1,7 +1,8 @@ Date: Wed, 27 Apr 2022 21:55:31 +0200 Subject: [PATCH 05/17] Refactor: Update trait namespaces --- src/Models/DocumentationPage.php | 1 + src/Models/MarkdownDocument.php | 2 ++ src/Models/MarkdownPost.php | 4 ++++ 3 files changed, 7 insertions(+) diff --git a/src/Models/DocumentationPage.php b/src/Models/DocumentationPage.php index 61905b45..81012431 100644 --- a/src/Models/DocumentationPage.php +++ b/src/Models/DocumentationPage.php @@ -2,6 +2,7 @@ namespace Hyde\Framework\Models; +use Hyde\Framework\Concerns\HasTableOfContents; use Hyde\Framework\DocumentationPageParser; class DocumentationPage extends MarkdownDocument diff --git a/src/Models/MarkdownDocument.php b/src/Models/MarkdownDocument.php index 0c3ae826..03cbd5d3 100644 --- a/src/Models/MarkdownDocument.php +++ b/src/Models/MarkdownDocument.php @@ -2,6 +2,8 @@ namespace Hyde\Framework\Models; +use Hyde\Framework\Concerns\HasDynamicTitle; + /** * The base class for all Markdown-based Page Models. * diff --git a/src/Models/MarkdownPost.php b/src/Models/MarkdownPost.php index 280387df..443216d1 100644 --- a/src/Models/MarkdownPost.php +++ b/src/Models/MarkdownPost.php @@ -2,6 +2,10 @@ namespace Hyde\Framework\Models; +use Hyde\Framework\Concerns\HasAuthor; +use Hyde\Framework\Concerns\HasDateString; +use Hyde\Framework\Concerns\HasFeaturedImage; +use Hyde\Framework\Concerns\HasMetadata; use Hyde\Framework\MarkdownPostParser; class MarkdownPost extends MarkdownDocument From 06719bec7b7725e1e69df04f0290c0e64f8bb7f0 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 21:58:10 +0200 Subject: [PATCH 06/17] Fix PHPStorm being crazy --- src/Concerns/HasDynamicTitle.php | 1 - src/Concerns/HasFeaturedImage.php | 1 - 2 files changed, 2 deletions(-) diff --git a/src/Concerns/HasDynamicTitle.php b/src/Concerns/HasDynamicTitle.php index 39c6e21d..074c416c 100644 --- a/src/Concerns/HasDynamicTitle.php +++ b/src/Concerns/HasDynamicTitle.php @@ -3,7 +3,6 @@ namespace Hyde\Framework\Concerns; use Hyde\Framework\Hyde; -use function Hyde\Framework\Models\str_starts_with; /** * Find and return the title to use for a Markdown Document. diff --git a/src/Concerns/HasFeaturedImage.php b/src/Concerns/HasFeaturedImage.php index 483dc675..93cc98d6 100644 --- a/src/Concerns/HasFeaturedImage.php +++ b/src/Concerns/HasFeaturedImage.php @@ -3,7 +3,6 @@ namespace Hyde\Framework\Concerns; use Hyde\Framework\Models\Image; -use function Hyde\Framework\Models\str_starts_with; trait HasFeaturedImage { From 9b4e3ff50238189536c9a0253ec2eb947d024a1c Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 22:05:56 +0200 Subject: [PATCH 07/17] Refactor: Move traits into Concerns --- src/{Services => Concerns}/Internal/AssetManager.php | 0 src/{Services => Concerns}/Internal/FileHelpers.php | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename src/{Services => Concerns}/Internal/AssetManager.php (100%) rename src/{Services => Concerns}/Internal/FileHelpers.php (100%) diff --git a/src/Services/Internal/AssetManager.php b/src/Concerns/Internal/AssetManager.php similarity index 100% rename from src/Services/Internal/AssetManager.php rename to src/Concerns/Internal/AssetManager.php diff --git a/src/Services/Internal/FileHelpers.php b/src/Concerns/Internal/FileHelpers.php similarity index 100% rename from src/Services/Internal/FileHelpers.php rename to src/Concerns/Internal/FileHelpers.php From 57f7c6a07969ba58597968f3cdd67355326f9fe8 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 22:06:12 +0200 Subject: [PATCH 08/17] Refactor: Update namespace --- src/Concerns/Internal/AssetManager.php | 4 +++- src/Concerns/Internal/FileHelpers.php | 4 +++- src/Hyde.php | 4 ++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/Concerns/Internal/AssetManager.php b/src/Concerns/Internal/AssetManager.php index 90d7b7ac..58b7717e 100644 --- a/src/Concerns/Internal/AssetManager.php +++ b/src/Concerns/Internal/AssetManager.php @@ -1,6 +1,8 @@ Date: Wed, 27 Apr 2022 22:10:28 +0200 Subject: [PATCH 09/17] Docs: Remove PHPDocs --- src/Hyde.php | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/src/Hyde.php b/src/Hyde.php index f2bc6bd7..a5d30897 100644 --- a/src/Hyde.php +++ b/src/Hyde.php @@ -22,34 +22,16 @@ class Hyde use FileHelpers; use AssetManager; - /** - * Return the Composer Package Version. - * - * @return string - */ public static function version(): string { return InstalledVersions::getPrettyVersion('hyde/framework') ?: 'unreleased'; } - /** - * Create a title from a kebab-case slug. - * - * @param string $slug - * @return string $title - */ public static function titleFromSlug(string $slug): string { return Str::title(str_replace('-', ' ', ($slug))); } - /** - * Get a Laravel Collection of all Posts as MarkdownPost objects. - * - * @return \Illuminate\Support\Collection - * - * @throws \Exception if the posts' directory does not exist - */ public static function getLatestPosts(): Collection { $collection = new Collection(); From 31d4ce9d16205b62a705e732e0e8a4595c1e509a Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Wed, 27 Apr 2022 20:10:46 +0000 Subject: [PATCH 10/17] Apply fixes from StyleCI [ci skip] [skip ci] --- src/Concerns/HasTableOfContents.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Concerns/HasTableOfContents.php b/src/Concerns/HasTableOfContents.php index 1550b731..17605110 100644 --- a/src/Concerns/HasTableOfContents.php +++ b/src/Concerns/HasTableOfContents.php @@ -2,8 +2,8 @@ namespace Hyde\Framework\Concerns; -use Hyde\Framework\Actions\GeneratesTableOfContents; use function config; +use Hyde\Framework\Actions\GeneratesTableOfContents; /** * Trait HasTableOfContents. From 192a085b2ed680897c8685f77a73d0dd43fb416f Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 22:16:38 +0200 Subject: [PATCH 11/17] Move AbstractPage into Contracts namespace --- src/AbstractPageParser.php | 2 +- src/{Models => Contracts}/AbstractPage.php | 2 +- src/Models/BladePage.php | 2 ++ src/Models/MarkdownDocument.php | 1 + src/PageParserContract.php | 2 +- 5 files changed, 6 insertions(+), 3 deletions(-) rename src/{Models => Contracts}/AbstractPage.php (90%) diff --git a/src/AbstractPageParser.php b/src/AbstractPageParser.php index a9e85968..ac13b7b5 100644 --- a/src/AbstractPageParser.php +++ b/src/AbstractPageParser.php @@ -3,7 +3,7 @@ namespace Hyde\Framework; use Hyde\Framework\Actions\ValidatesExistence; -use Hyde\Framework\Models\AbstractPage; +use Hyde\Framework\Contracts\AbstractPage; /** * Abstract base class for all page parsers. diff --git a/src/Models/AbstractPage.php b/src/Contracts/AbstractPage.php similarity index 90% rename from src/Models/AbstractPage.php rename to src/Contracts/AbstractPage.php index 91d6fd81..c17c577e 100644 --- a/src/Models/AbstractPage.php +++ b/src/Contracts/AbstractPage.php @@ -1,6 +1,6 @@ Date: Wed, 27 Apr 2022 22:17:16 +0200 Subject: [PATCH 12/17] Move AbstractPageParser into Contracts --- src/{ => Contracts}/AbstractPageParser.php | 4 ++-- src/DocumentationPageParser.php | 1 + src/MarkdownPageParser.php | 1 + src/MarkdownPostParser.php | 1 + 4 files changed, 5 insertions(+), 2 deletions(-) rename src/{ => Contracts}/AbstractPageParser.php (93%) diff --git a/src/AbstractPageParser.php b/src/Contracts/AbstractPageParser.php similarity index 93% rename from src/AbstractPageParser.php rename to src/Contracts/AbstractPageParser.php index ac13b7b5..31318dff 100644 --- a/src/AbstractPageParser.php +++ b/src/Contracts/AbstractPageParser.php @@ -1,9 +1,9 @@ Date: Wed, 27 Apr 2022 22:17:59 +0200 Subject: [PATCH 13/17] Move the PageParserContract into Contracts --- src/Contracts/AbstractPageParser.php | 1 - src/{ => Contracts}/PageParserContract.php | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) rename src/{ => Contracts}/PageParserContract.php (80%) diff --git a/src/Contracts/AbstractPageParser.php b/src/Contracts/AbstractPageParser.php index 31318dff..a7a44446 100644 --- a/src/Contracts/AbstractPageParser.php +++ b/src/Contracts/AbstractPageParser.php @@ -3,7 +3,6 @@ namespace Hyde\Framework\Contracts; use Hyde\Framework\Actions\ValidatesExistence; -use Hyde\Framework\PageParserContract; /** * Abstract base class for all page parsers. diff --git a/src/PageParserContract.php b/src/Contracts/PageParserContract.php similarity index 80% rename from src/PageParserContract.php rename to src/Contracts/PageParserContract.php index 97eb1493..4e2b7bc2 100644 --- a/src/PageParserContract.php +++ b/src/Contracts/PageParserContract.php @@ -1,8 +1,6 @@ Date: Wed, 27 Apr 2022 22:19:32 +0200 Subject: [PATCH 14/17] Move ActionContract into Contracts --- src/Actions/GeneratesTableOfContents.php | 1 + src/Actions/PublishesHomepageView.php | 1 + src/Actions/PublishesHydeViews.php | 1 + src/{Actions => Contracts}/ActionContract.php | 2 +- 4 files changed, 4 insertions(+), 1 deletion(-) rename src/{Actions => Contracts}/ActionContract.php (80%) diff --git a/src/Actions/GeneratesTableOfContents.php b/src/Actions/GeneratesTableOfContents.php index 71764cb6..66b6bd42 100644 --- a/src/Actions/GeneratesTableOfContents.php +++ b/src/Actions/GeneratesTableOfContents.php @@ -2,6 +2,7 @@ namespace Hyde\Framework\Actions; +use Hyde\Framework\Contracts\ActionContract; use League\CommonMark\Environment\Environment; use League\CommonMark\Extension\CommonMark\CommonMarkCoreExtension; use League\CommonMark\Extension\HeadingPermalink\HeadingPermalinkExtension; diff --git a/src/Actions/PublishesHomepageView.php b/src/Actions/PublishesHomepageView.php index 9f4e7968..24249017 100644 --- a/src/Actions/PublishesHomepageView.php +++ b/src/Actions/PublishesHomepageView.php @@ -2,6 +2,7 @@ namespace Hyde\Framework\Actions; +use Hyde\Framework\Contracts\ActionContract; use Hyde\Framework\Hyde; class PublishesHomepageView implements ActionContract diff --git a/src/Actions/PublishesHydeViews.php b/src/Actions/PublishesHydeViews.php index b7b7f485..ff52ee7f 100644 --- a/src/Actions/PublishesHydeViews.php +++ b/src/Actions/PublishesHydeViews.php @@ -2,6 +2,7 @@ namespace Hyde\Framework\Actions; +use Hyde\Framework\Contracts\ActionContract; use Hyde\Framework\Hyde; use Illuminate\Support\Facades\File; diff --git a/src/Actions/ActionContract.php b/src/Contracts/ActionContract.php similarity index 80% rename from src/Actions/ActionContract.php rename to src/Contracts/ActionContract.php index 16cceb41..64e97fcc 100644 --- a/src/Actions/ActionContract.php +++ b/src/Contracts/ActionContract.php @@ -1,6 +1,6 @@ Date: Wed, 27 Apr 2022 22:20:41 +0200 Subject: [PATCH 15/17] Move ValidatesExistence into Concerns --- src/{Actions => Concerns}/ValidatesExistence.php | 2 +- src/Contracts/AbstractPageParser.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename src/{Actions => Concerns}/ValidatesExistence.php (93%) diff --git a/src/Actions/ValidatesExistence.php b/src/Concerns/ValidatesExistence.php similarity index 93% rename from src/Actions/ValidatesExistence.php rename to src/Concerns/ValidatesExistence.php index 6e4445e3..aadab160 100644 --- a/src/Actions/ValidatesExistence.php +++ b/src/Concerns/ValidatesExistence.php @@ -1,6 +1,6 @@ Date: Wed, 27 Apr 2022 22:25:41 +0200 Subject: [PATCH 16/17] Move Markdown traits into Concerns --- .../Markdown}/HasConfigurableMarkdownFeatures.php | 0 .../ServiceActions => Concerns/Markdown}/HasMarkdownFeatures.php | 0 .../Markdown}/HasTorchlightIntegration.php | 0 3 files changed, 0 insertions(+), 0 deletions(-) rename src/{Actions/ServiceActions => Concerns/Markdown}/HasConfigurableMarkdownFeatures.php (100%) rename src/{Actions/ServiceActions => Concerns/Markdown}/HasMarkdownFeatures.php (100%) rename src/{Actions/ServiceActions => Concerns/Markdown}/HasTorchlightIntegration.php (100%) diff --git a/src/Actions/ServiceActions/HasConfigurableMarkdownFeatures.php b/src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php similarity index 100% rename from src/Actions/ServiceActions/HasConfigurableMarkdownFeatures.php rename to src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php diff --git a/src/Actions/ServiceActions/HasMarkdownFeatures.php b/src/Concerns/Markdown/HasMarkdownFeatures.php similarity index 100% rename from src/Actions/ServiceActions/HasMarkdownFeatures.php rename to src/Concerns/Markdown/HasMarkdownFeatures.php diff --git a/src/Actions/ServiceActions/HasTorchlightIntegration.php b/src/Concerns/Markdown/HasTorchlightIntegration.php similarity index 100% rename from src/Actions/ServiceActions/HasTorchlightIntegration.php rename to src/Concerns/Markdown/HasTorchlightIntegration.php From 34754f22f8728cf3ac0038542f98d65223479927 Mon Sep 17 00:00:00 2001 From: Caen De Silva Date: Wed, 27 Apr 2022 22:25:53 +0200 Subject: [PATCH 17/17] Update Markdown Concern namespaces --- src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php | 2 +- src/Concerns/Markdown/HasMarkdownFeatures.php | 4 +++- src/Concerns/Markdown/HasTorchlightIntegration.php | 4 +++- src/Markdown.php | 2 +- src/Services/MarkdownConverterService.php | 4 ++-- 5 files changed, 10 insertions(+), 6 deletions(-) diff --git a/src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php b/src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php index 8fb47152..32cb3b26 100644 --- a/src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php +++ b/src/Concerns/Markdown/HasConfigurableMarkdownFeatures.php @@ -1,6 +1,6 @@