Skip to content

Commit

Permalink
refactor(list): use debounce value from common debounce module instea…
Browse files Browse the repository at this point in the history
…d of local one (#11259)
  • Loading branch information
jcfranco authored Jan 10, 2025
1 parent e878e07 commit fd7d5ec
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 3 additions & 2 deletions packages/calcite-components/src/components/list/list.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ import { useT9n } from "../../controllers/useT9n";
import type { ListItem } from "../list-item/list-item";
import type { Filter } from "../filter/filter";
import type { ListItemGroup } from "../list-item-group/list-item-group";
import { CSS, debounceTimeout, SelectionAppearance, SLOTS } from "./resources";
import { DEBOUNCE } from "../../utils/resources";
import { CSS, SelectionAppearance, SLOTS } from "./resources";
import T9nStrings from "./assets/t9n/messages.en.json";
import { ListElement } from "./interfaces";
import { ListDragDetail, ListDisplayMode, ListMoveDetail } from "./interfaces";
Expand Down Expand Up @@ -148,7 +149,7 @@ export class List
this.setActiveListItem();
this.updateSelectedItems();
this.setUpSorting();
}, debounceTimeout);
}, DEBOUNCE.nextTick);

private visibleItems: ListItem["el"][] = [];

Expand Down
2 changes: 0 additions & 2 deletions packages/calcite-components/src/components/list/resources.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ export const CSS = {
assistiveText: "assistive-text",
};

export const debounceTimeout = 0;

export type SelectionAppearance = "border" | "icon";

export const SLOTS = {
Expand Down

0 comments on commit fd7d5ec

Please sign in to comment.