Skip to content

Commit

Permalink
fix(storybook): increase clickable area (#1130)
Browse files Browse the repository at this point in the history
  • Loading branch information
bar-tay authored Jul 8, 2024
1 parent 2f9be81 commit 35fc644
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions packages/ui-library/src/components/input-field-text/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,19 @@ export class BlrInputFieldText extends LitElementCustom {
}
};

protected firstUpdated(): void {
const inputWrapper = this.shadowRoot?.querySelector('.blr-input-wrapper');
if (inputWrapper) {
inputWrapper.addEventListener('click', this.handleWrapperClick);
}
}

protected handleWrapperClick = (): void => {
if (!this.disabled) {
this._inputFieldTextNode.focus();
}
};

protected handleIconClick: BlrIconEventHandlers['blrClick'] = () => {
if (this.disabled) {
return;
Expand Down

0 comments on commit 35fc644

Please sign in to comment.