Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TabView: previousicon slot doesn't work #5264

Closed
yellowgiraffe opened this issue Feb 12, 2024 · 0 comments
Closed

TabView: previousicon slot doesn't work #5264

yellowgiraffe opened this issue Feb 12, 2024 · 0 comments
Assignees
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@yellowgiraffe
Copy link

yellowgiraffe commented Feb 12, 2024

Bug description

I have encountered an issue with previousicon slot (link to docs) for TabView component. While the nexticon slot successfully replaces the icon with a different type and changes the color to purple, the previousicon slot remains unchaged.

Example: StackBlitz Example


Upon further investigation, I noticed that the interface TabViewSlots has a slot name - previousicon. In contrary the source code of the TabView component, available on GitHub (line 16), indeed defines the previcon slot.

So when I changed the slot from <template #previousicon></template> to <template #previcon></template> it updated the icon.

Example: StackBlitz Example

However, this modification leads to a TypeScript error, stating "Propterty 'previcon' does not exist on type 'TabViewSlots. ts(2339)'"

Therefore, adjusting the name in the TabViewSlots interface or changing the name of the slot in TabView.vue would resolve the icon replacement issue.

Reproducer

https://stackblitz.com/edit/primevue-create-vue-typescript-issue-template-ylqyl9?file=src%2FApp.vue

PrimeVue version

3.47.2

Vue version

3.x

Language

TypeScript

Build / Runtime

Vue CLI App

Browser(s)

No response

Steps to reproduce the behavior

  1. Click on "arrow-right" button to scroll and see more tabs
  2. When the "arrow-left" button appears we can't see any expected changes

Expected behavior

The "arrow-left" button updates according to the content in the slot previousicon

@yellowgiraffe yellowgiraffe added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Feb 12, 2024
@tugcekucukoglu tugcekucukoglu added Type: Bug Issue contains a bug related to a specific component. Something about the component is not working and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Feb 16, 2024
@tugcekucukoglu tugcekucukoglu added this to the 3.49.0 milestone Feb 16, 2024
@tugcekucukoglu tugcekucukoglu self-assigned this Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Projects
None yet
Development

No branches or pull requests

2 participants