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

Tree : Some Selection example code(options API) of document not included selecedKey data #6390

Closed
kimhanui opened this issue Sep 12, 2024 · 0 comments · May be fixed by jjlim7/tournament-management-system#42 or jjlim7/tournament-management-system#43
Labels
Component: Documentation Issue or pull request is related to Documentation

Comments

@kimhanui
Copy link
Contributor

kimhanui commented Sep 12, 2024

Describe the bug

Selection example code(options API) not included selecedKey data
So, the example components cannot express 'selected' css

see the below example code of https://primevue.org/tree/#single.
This also appears at https://primevue.org/tree/#checkbox

<template>
    <ThemeSwitcher />
    <div class="card flex justify-center">
        <Toast />
        <Tree v-model:selectionKeys="selectedKey" :value="nodes" selectionMode="single" class="w-full md:w-[30rem]"></Tree>
    </div>
</template>

<script>
import { NodeService } from '@/service/NodeService';

export default {
    data() {
        return {
            nodes: null // <- HERE. NO 'selectedKey' data
        };
    },
    //ellipsis
}
</script>

Reproducer

.

PrimeVue version

4.0.6

Vue version

3.x

Language

ES6

Build / Runtime

Vue CLI App

Browser(s)

No response

Steps to reproduce the behavior

  1. Go to below link
    https://primevue.org/tree/#single
    https://primevue.org/tree/#checkbox

  2. And see the example code by Options API version

Expected behavior

In Options API version, selectedKey data should be included

@kimhanui kimhanui added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Sep 12, 2024
@kimhanui kimhanui changed the title Tree : Selection example code(options API) of document not included selecedKey data Tree : Some Selection example code(options API) of document not included selecedKey data Sep 12, 2024
@tugcekucukoglu tugcekucukoglu added Component: Documentation Issue or pull request is related to Documentation and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Sep 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Documentation Issue or pull request is related to Documentation
Projects
None yet
2 participants