Skip to content

Commit

Permalink
fix(UI): Remove rasterizing of items in draggable lists (#1231)
Browse files Browse the repository at this point in the history
As `DraggableList` now use another strategy to move item and presents
the drag feedback, it occurs that raster of all items is not needed
anymore.

Indeed this leads to a nice optimisation in responsiveness especially
when using large table reports.

Closes #1177.
  • Loading branch information
rouk1 authored Jan 27, 2025
1 parent 8428d91 commit 6c19822
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions skore-ui/src/components/DraggableList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import interact from "interactjs";
import Simplebar from "simplebar-core";
import { onBeforeUnmount, onMounted, ref, useTemplateRef } from "vue";
import DynamicContentRasterizer from "@/components/DynamicContentRasterizer.vue";
interface Item {
name: string;
[key: string]: any;
Expand Down Expand Up @@ -208,9 +206,7 @@ onBeforeUnmount(() => {
:style="topDropIndicatorStyles()"
/>
<div class="content" :class="{ moving: movingItemIndex === index }">
<DynamicContentRasterizer :isRasterized="movingItemIndex !== -1">
<slot name="item" v-bind="item"></slot>
</DynamicContentRasterizer>
<slot name="item" v-bind="item"></slot>
</div>
<div class="drop-indicator bottom" :class="{ visible: dropIndicatorPosition === index }" />
</div>
Expand Down

0 comments on commit 6c19822

Please sign in to comment.