Skip to content

Commit

Permalink
Fixes liferay#1242 - Coming back with the focusable API
Browse files Browse the repository at this point in the history
  • Loading branch information
matuzalemsteles committed Nov 27, 2018
1 parent d7a1724 commit 90d66a5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
9 changes: 1 addition & 8 deletions packages/clay-icon/src/ClayIcon.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,11 @@ ClayIcon.STATE = {
/**
* Flag to indicate if the svg is focusable or not
* @default false
* @deprecated since version 2.4.x
* @instance
* @memberof ClayIcon
* @type {?bool}
*/
focusable: Config.validator(value => {
if (value) {
console.warn(
'🚨 The `focusable` API will be deprecated and removed in the next release. See more information https://goo.gl/EycJtK'
);
}
}),
focusable: Config.bool().value(false),

/**
* Id to be applied to the element.
Expand Down
7 changes: 7 additions & 0 deletions packages/clay-icon/src/ClayIcon.soy
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
{@param spritemap: string}
{@param symbol: string}
{@param? elementClasses: string}
{@param? focusable: bool}
{@param? id: string}

{let $attributes kind="attributes"}
Expand All @@ -18,6 +19,12 @@
{/if}
"

{if $focusable}
focusable="true"
{else}
focusable="false"
{/if}

{if $id}
id="{$id}"
{/if}
Expand Down

0 comments on commit 90d66a5

Please sign in to comment.