Skip to content

use TransitionGroup and UI component (like el-collapse) at same time #278

@hogking

Description

@hogking

hi everyone, I use draggable and el-collapse like

const activeOrderName = ref([]);
const collapseComponentData = computed(() => ({
  modelValue: activeOrderName.value
}));
...
<draggable
                        :key="choiceIndex + draggableKey"
                        tag="el-collapse"
                        item-key="key"
                        :list="orders"
                        :component-data="collapseComponentData"
...
>

which mention in https://github.com/SortableJS/vue.draggable.next/blob/master/example/components/third-party.vue.
And it works.
But this seem like I cannot use el-collapse active name anymore.

I try:

<draggable
                        :key="choiceIndex + draggableKey"
                        tag="transition-group"
                        item-key="key"
                        :list="orders"
                        :component-data="{
                          tag: 'el-collapse'
                        }"
...
>
//const activeOrderName = ref([]);
//const collapseComponentData = computed(() => ({
//  modelValue: activeOrderName.value
//}));

But I want to use TransitionGroup for el-collapse-item when I sort them.
How can I bind them together?

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions