Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update SEO #62

Merged
merged 1 commit into from
Apr 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions Modules/CircleDocs/resources/views/profile.blade.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
@php
SEO::openGraphType('WebPage');
SEO::openGraphSiteName($account->username . ' Docs | '. setting('site_name'));
SEO::openGraphTitle($account->username . ' | '. setting('site_name'));
SEO::openGraphUrl(url()->current());
SEO::openGraphImage($account->avatar ?: setting('site_profile'));
SEO::metaByProperty('og:description',$account->bio ?: setting('site_description'));

SEO::twitterCard('summary_large_image');
SEO::twitterTitle($account->username . ' Docs | '. setting('site_name'));
SEO::twitterDescription($account->bio ?: setting('site_description'));
SEO::twitterImage($account->avatar ?: setting('site_profile'));

SEO::canonical(url()->current());
@endphp
@seoTitle($account->username . ' Docs | '. setting('site_name'))
@seoDescription($account->bio ?: setting('site_description'))
@seoKeywords(setting('site_keywords'))

<x-circle-xo-public-profile-layout :account="$account">
<div class="my-8">
<x-circle-xo-listing-filters link />
Expand Down
19 changes: 19 additions & 0 deletions Modules/CircleDocs/resources/views/show.blade.php
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
@php
SEO::openGraphType('WebPage');
SEO::openGraphSiteName(setting('site_name'));
SEO::openGraphTitle((isset($currentPage) ? $doc->name . ' | ' . $currentPage->title : $doc->name) .' | '. setting('site_name'));
SEO::openGraphUrl(url()->current());
SEO::openGraphImage((isset($currentPage) ? $currentPage->getMedia('cover')->first()?->getUrl() : $doc->getMedia('cover')->first()?->getUrl()) ?: setting('site_profile'));
SEO::metaByProperty('og:description',(isset($currentPage) ? $currentPage->description : $doc->description) ?: setting('site_description'));

SEO::twitterCard('summary_large_image');
SEO::twitterTitle((isset($currentPage) ? $doc->name . ' | ' . $currentPage->title : $doc->name) .' | '. setting('site_name'));
SEO::twitterDescription((isset($currentPage) ? $currentPage->description : $doc->description) ?: setting('site_description'));
SEO::twitterImage((isset($currentPage) ? $currentPage->getMedia('cover')->first()?->getUrl() : $doc->getMedia('cover')->first()?->getUrl()) ?: setting('site_profile'));

SEO::canonical(url()->current());
@endphp
@seoTitle((isset($currentPage) ? $doc->name . ' | ' . $currentPage->title : $doc->name) .' | '. setting('site_name'))
@seoDescription((isset($currentPage) ? $currentPage->description : $doc->description) ?: setting('site_description'))
@seoKeywords(setting('site_keywords'))

<x-circle-xo-public-profile-layout :account="$account">
<div class="w-full py-4 px-8 mt-4 border-b border-zinc-700">
<div class="flex justify-between">
Expand Down
12 changes: 6 additions & 6 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading