Skip to content

Commit

Permalink
Merge pull request #2459 from Codeinwp/feat/tc-connection
Browse files Browse the repository at this point in the history
chore: change Otter Patterns button order & Premium Designs appearance
  • Loading branch information
abaicus authored Nov 28, 2024
2 parents 1905666 + 82668ee commit 6ee8359
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions src/blocks/plugins/patterns-library/library.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import {
useState
} from '@wordpress/element';

import { grid } from '@wordpress/icons';
import { external, grid, Icon } from '@wordpress/icons';

/**
* Internal dependencies.
Expand Down Expand Up @@ -213,13 +213,24 @@ const Library = ({
{ __( 'My Favorites', 'otter-blocks' ) }
</Button>

{tcCategories.length < 1 && (
<Button
icon="open-folder"
isPressed={ 'cloud-empty' === selectedCategory }
onClick={ () => setSelectedCategory( CLOUD_EMPTY_CATEGORY ) }
>
{ __( 'Cloud Libraries', 'otter-blocks' ) }
</Button>
) }

{ ( ! Boolean( window.themeisleGutenberg.hasPro ) ) && (
<Button
icon="lock"
href="https://themeisle.com/plugins/otter-blocks/patterns/"
target="_blank"
>
{ __( 'Premium Designs', 'otter-blocks' ) }
<Icon icon={external} size={15} />
</Button>
) }

Expand All @@ -244,15 +255,6 @@ const Library = ({
</ul>
</>
)}
{tcCategories.length < 1 && (
<Button
icon="lock"
isPressed={ 'cloud-empty' === selectedCategory }
onClick={ () => setSelectedCategory( CLOUD_EMPTY_CATEGORY ) }
>
{ __( 'Cloud Libraries', 'otter-blocks' ) }
</Button>
) }

<p className="o-library__modal__sidebar__heading">
{ __( 'Categories', 'otter-blocks' ) }
Expand Down

0 comments on commit 6ee8359

Please sign in to comment.