iachat/app/javascript
Sivin Varghese 207933ed70
fix: TypeError cannot read properties of undefined (reading '$el') (#9951)
# Pull Request Template

## Description

This PR will fix an error `TypeError cannot read properties of undefined
(reading '$el')` with the keyboard shortcut `Alt+KeyA` for triggering
the file picker.

**Issue**
I couldn't able reproduce this issue. It might be because `$children`
was unavailable at the time of access.

**Solution**
Previously, it relied on `$children`. Now, it uses the more reliable
`querySelector` method to find the target element.

Fixes
https://chatwoot-p3.sentry.io/issues/5708410274/?alert_rule_id=15157525&alert_timestamp=1723552508790&alert_type=email&environment=production&notification_uuid=be5966b2-f17d-4273-8709-98e3322f1f6f&project=4507182691975168&referrer=alert_email

## Type of change

- [x] Bug fix (non-breaking change which fixes an issue)

## How Has This Been Tested?

**Test cases**
1. Open a conversation
2. And click `Alt+KeyA` to trigger the file picker.
3. See if there is any issue or errors.


## Checklist:

- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my code
- [x] I have commented on my code, particularly in hard-to-understand
areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [ ] Any dependent changes have been merged and published in downstream
modules
2024-08-14 11:22:51 +05:30
..
dashboard fix: TypeError cannot read properties of undefined (reading '$el') (#9951) 2024-08-14 11:22:51 +05:30
packs chore: Migrate all instances of old vuelidate to new v2 syntax [CW-3274] (#9623) 2024-07-30 15:08:22 +05:30
portal feat: Replace the use of mentionSelectionKeyboard mixin to a composable (#9904) 2024-08-07 14:14:41 +05:30
sdk fix: Avoid overflow caused by the empty span element (#9753) 2024-07-10 19:56:46 -07:00
shared feat: Replace rtlMixin to a composable (#9924) 2024-08-12 15:50:21 +05:30
superadmin_pages feat: Replace the use of keyboardEventListener mixin to a composable (Part -3) (#9897) 2024-08-08 12:40:56 +05:30
survey feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
v3 feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
widget chore: Replace messageMixing with useMessage composable [CW-3475] (#9942) 2024-08-13 09:21:54 +05:30