PromucFlow_constructor/app/client/src/widgets/BaseInputWidget
Jacques Ikot 641e4192a6
feat: remove isFocus from meta state in InputWidgetV2 (#36843)
## Description

**Problem**
A redundant evaluation cycle is run every time a user focuses on an
InputWidget component and the isFocused meta state is updated

**Root Cause**
`isFocus` property of InputWidgetV2 is a meta property and updated
through `this.updateWidgetMetaProperty`, thereby changes to these
property triggers an evaluation cycle run

**Solution**
Implement the `isFocus` property as a local state of the InputWidgetV2
component


Fixes #36446

## Automation

/ok-to-test tags="@tag.Widget, @tag.Input"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/11362334893>
> Commit: 80e9089681456b7b3547cc4781abf719c561d27d
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=11362334893&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Widget, @tag.Input`
> Spec:
> <hr>Wed, 16 Oct 2024 10:22:00 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Enhanced focus management for the InputWidget, allowing for improved
internal state handling.
- Multi-line text input now supports submitting with keyboard shortcuts
for a more streamlined user experience.

- **Bug Fixes**
- Resolved issues with widget metadata by excluding the `isFocused`
property from the meta properties.
- Improved internal state management for input changes, reducing
reliance on external properties.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-10-16 16:01:07 +05:30
..
component chore: remove console errors on dev (#36639) 2024-10-15 00:23:51 +05:30
widget feat: remove isFocus from meta state in InputWidgetV2 (#36843) 2024-10-16 16:01:07 +05:30
constants.ts feat: multi-line input and auto-resize textarea (#19141) 2023-01-17 18:46:35 +05:30
icon.svg feat: Widget Discoverability (#24934) 2023-07-22 11:27:18 +05:30
index.ts chore: Move the widget config to widget class (#26073) 2023-09-06 17:45:04 +05:30
utils.ts chore: upgrade to prettier v2 + enforce import types (#21013)Co-authored-by: Satish Gandham <hello@satishgandham.com> Co-authored-by: Satish Gandham <satish.iitg@gmail.com> 2023-03-16 17:11:47 +05:30