Skip to content

Commit cec7c0a

Browse files
AshuKharbandarluders
authored andcommitted
fix(pagination theme file): added enabled attribute for pagination base theme
hover class was getting applied even when button is disabled. so, added enabled: attribute to each hover class of pagination base theme. Now it will only show hover if button is enabled. fix #849
1 parent bd4ad89 commit cec7c0a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/components/Pagination/theme.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,15 @@ export const paginationTheme: FlowbitePaginationTheme = {
1212
base: 'xs:mt-0 mt-2 inline-flex items-center -space-x-px',
1313
showIcon: 'inline-flex',
1414
previous: {
15-
base: 'ml-0 rounded-l-lg border border-gray-300 bg-white py-2 px-3 leading-tight text-gray-500 hover:bg-gray-100 hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white',
15+
base: 'ml-0 rounded-l-lg border border-gray-300 bg-white py-2 px-3 leading-tight text-gray-500 enabled:hover:bg-gray-100 enabled:hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 enabled:dark:hover:bg-gray-700 enabled:dark:hover:text-white',
1616
icon: 'h-5 w-5',
1717
},
1818
next: {
19-
base: 'rounded-r-lg border border-gray-300 bg-white py-2 px-3 leading-tight text-gray-500 hover:bg-gray-100 hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white',
19+
base: 'rounded-r-lg border border-gray-300 bg-white py-2 px-3 leading-tight text-gray-500 enabled:hover:bg-gray-100 enabled:hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 enabled:dark:hover:bg-gray-700 enabled:dark:hover:text-white',
2020
icon: 'h-5 w-5',
2121
},
2222
selector: {
23-
base: 'w-12 border border-gray-300 bg-white py-2 leading-tight text-gray-500 hover:bg-gray-100 hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white',
23+
base: 'w-12 border border-gray-300 bg-white py-2 leading-tight text-gray-500 enabled:hover:bg-gray-100 enabled:hover:text-gray-700 dark:border-gray-700 dark:bg-gray-800 dark:text-gray-400 enabled:dark:hover:bg-gray-700 enabled:dark:hover:text-white',
2424
active:
2525
'bg-cyan-50 text-cyan-600 hover:bg-cyan-100 hover:text-cyan-700 dark:border-gray-700 dark:bg-gray-700 dark:text-white',
2626
disabled: 'opacity-50 cursor-normal',

0 commit comments

Comments
 (0)