Skip to content

Commit 76d77a7

Browse files
authored
Fix CSP violation in Carousel drag-scroll helper (#1289)
* Fix CSP violation is Carousel drag-scroll helper * remove dependance on tailwind layers/global
1 parent d0dc810 commit 76d77a7

File tree

4 files changed

+399
-24
lines changed

4 files changed

+399
-24
lines changed

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,11 @@
5555
},
5656
"dependencies": {
5757
"@floating-ui/react": "^0.26.2",
58+
"classnames": "^2.5.1",
5859
"contentlayer": "^0.3.4",
60+
"debounce": "^2.0.0",
5961
"flowbite": "^2.0.0",
6062
"react-icons": "^4.11.0",
61-
"react-indiana-drag-scroll": "^2.2.0",
6263
"tailwind-merge": "^2.0.0"
6364
},
6465
"devDependencies": {

src/components/Carousel/Carousel.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import type { ComponentProps, FC, ReactElement, ReactNode } from 'react';
44
import { Children, cloneElement, useCallback, useEffect, useMemo, useRef, useState } from 'react';
55
import { HiOutlineChevronLeft, HiOutlineChevronRight } from 'react-icons/hi';
6-
import ScrollContainer from 'react-indiana-drag-scroll';
6+
import ScrollContainer from '../../helpers/drag-scroll';
77
import { twMerge } from 'tailwind-merge';
88
import { isClient } from '../../helpers/is-client';
99
import { mergeDeep } from '../../helpers/merge-deep';

0 commit comments

Comments
 (0)