chatwoot/app/javascript/dashboard/components
Sivin Varghese 7b6195f28b
fix: Component <woot-tabs /> reactivity issue. (#10476)
# Pull Request Template

## Description

This PR will fix reactivity issue with `<woot-tabs />` component.

**Cause of issue**
The `<woot-tabs />` component used an internal ref,
`internalActiveIndex` to track the `active` tab. However, it didn’t sync
with the `index` prop when updated by the parent, causing mismatched tab
selections.

**Solution**
The component now directly uses `props.index` to ensure it always
reflects the latest value from the parent. The unnecessary
`internalActiveIndex` ref has been removed. Changes to the active tab
emit a `change` event to update the parent.


## Type of change

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

## How Has This Been Tested?

**Loom video**

**Before**

https://www.loom.com/share/76eb32f1e7f7422f84055a102bf80951?sid=bc28c6ff-9640-4d3b-956c-99c1ec164971

**After**

https://www.loom.com/share/6bd8125ede5d43dc8fe115c3f1fb159b?sid=c376617a-94fb-4f71-8664-e0bd9e7af0b4

## 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-11-21 16:25:13 +05:30
..
Accordion feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
app style: apply fixes for eslint issues [cw-3590] (#10210) 2024-10-03 15:02:12 +05:30
base feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
buttons feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
layout feat: Add dropdown component (#10358) 2024-11-18 17:29:27 -08:00
specs feat: Add new sidebar for Chatwoot V4 (#10291) 2024-10-23 18:32:37 -07:00
table feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
ui fix: Component <woot-tabs /> reactivity issue. (#10476) 2024-11-21 16:25:13 +05:30
widgets fix: Update the translation for the text used in isTyping method (#10384) 2024-11-04 20:04:08 -08:00
ChannelSelector.vue feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
ChatList.vue fix: Agents list in bulk action is not loading (#10347) 2024-10-24 11:51:40 +05:30
ChatListHeader.vue style: apply fixes for eslint issues [cw-3590] (#10210) 2024-10-03 15:02:12 +05:30
Code.vue feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
ConversationItem.vue style: apply fixes for eslint issues [cw-3590] (#10210) 2024-10-03 15:02:12 +05:30
CustomAttribute.vue style: apply fixes for eslint issues [cw-3590] (#10210) 2024-10-03 15:02:12 +05:30
CustomBrandPolicyWrapper.vue style: apply fixes for eslint issues [cw-3590] (#10210) 2024-10-03 15:02:12 +05:30
CustomSnoozeModal.vue fix: Update the styles for the datepicker in custom snooze modal (#10207) 2024-10-03 22:06:51 -07:00
FormSection.vue feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
index.js feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
IntersectionObserver.vue feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
MaskedText.vue feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
Modal.vue feat: remove usage of .sync and define explicitly emits (#10209) 2024-10-03 12:44:18 +05:30
ModalHeader.vue chore: fix circleci on vite build (#10214) 2024-10-07 15:27:41 +05:30
NetworkNotification.vue feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00
policy.vue feat: Add new sidebar for Chatwoot V4 (#10291) 2024-10-23 18:32:37 -07:00
SettingsSection.vue feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
SidemenuIcon.vue feat: Add new sidebar for Chatwoot V4 (#10291) 2024-10-23 18:32:37 -07:00
Snackbar.vue feat: Eslint rules (#9839) 2024-08-05 14:02:16 +05:30
SnackbarContainer.vue feat: Vite + vue 3 💚 (#10047) 2024-10-02 00:36:30 -07:00