@kvell-group/ui 1.18.13 → 1.18.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/ActionIcon/ActionIcon.tsx +0 -2
- package/src/components/Button/Button.tsx +0 -2
- package/src/components/Pagination/Pagination.module.css +44 -0
- package/src/components/Pagination/Pagination.tsx +10 -0
- package/src/components/Pagination/index.ts +1 -0
- package/src/index.ts +1 -0
package/package.json
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { createPolymorphicComponent, ActionIcon as MantineActionIcon } from '@mantine/core'
|
|
2
2
|
import type { ActionIconProps as BaseActionIconProps } from '@mantine/core'
|
|
3
|
-
import '@mantine/core/styles/UnstyledButton.layer.css'
|
|
4
|
-
import '@mantine/core/styles/Button.layer.css'
|
|
5
3
|
import classNames from './ActionIcon.module.css'
|
|
6
4
|
import { forwardRef } from 'react'
|
|
7
5
|
import type { ExtendedActionIconVariant } from './types'
|
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { createPolymorphicComponent, Button as MantineButton } from '@mantine/core'
|
|
2
2
|
import type { ButtonProps as BaseButtonProps } from '@mantine/core'
|
|
3
|
-
import '@mantine/core/styles/UnstyledButton.layer.css'
|
|
4
|
-
import '@mantine/core/styles/Button.layer.css'
|
|
5
3
|
import classNames from './Button.module.css'
|
|
6
4
|
import { forwardRef } from 'react'
|
|
7
5
|
import type { ExtendedButtonVariant } from './types'
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
.root {
|
|
2
|
+
--pagination-active-bg: var(--color-background-button-tertiary);
|
|
3
|
+
--pagination-active-color: var(--color-text-base-primary);
|
|
4
|
+
|
|
5
|
+
--pagination-control-size-sm: rem(32px);
|
|
6
|
+
--pagination-control-size-md: rem(40px);
|
|
7
|
+
|
|
8
|
+
color: var(--color-text-base-secondary);
|
|
9
|
+
font-weight: 500;
|
|
10
|
+
|
|
11
|
+
&[data-size='sm'] {
|
|
12
|
+
--pagination-control-radius: var(--mantine-radius-lg);
|
|
13
|
+
|
|
14
|
+
& .control {
|
|
15
|
+
--pagination-control-fz: var(--mantine-font-size-caption-l);
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&[data-size='md'] {
|
|
20
|
+
--pagination-control-radius: var(--mantine-radius-xl);
|
|
21
|
+
|
|
22
|
+
& .control {
|
|
23
|
+
--pagination-control-fz: var(--mantine-font-size-body-s);
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.control {
|
|
29
|
+
border-color: transparent;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.control:not([data-active]) {
|
|
33
|
+
color: var(--color-text-base-secondary);
|
|
34
|
+
background: none;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.control:hover:not(:disabled, [data-disabled]) {
|
|
38
|
+
background: var(--color-background-button-tertiary);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.control:focus-visible {
|
|
42
|
+
border-color: var(--color-border-action-focus-light);
|
|
43
|
+
box-shadow: var(--shadow-focus-ring-light);
|
|
44
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Pagination as MantinePagination } from '@mantine/core'
|
|
2
|
+
import { RiArrowLeftLine, RiArrowRightLine } from '@remixicon/react'
|
|
3
|
+
import classNames from './Pagination.module.css'
|
|
4
|
+
|
|
5
|
+
export const Pagination = MantinePagination.withProps({
|
|
6
|
+
classNames,
|
|
7
|
+
previousIcon: () => <RiArrowLeftLine size={16} />,
|
|
8
|
+
nextIcon: () => <RiArrowRightLine size={16} />,
|
|
9
|
+
dotsIcon: () => '...',
|
|
10
|
+
})
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Pagination'
|
package/src/index.ts
CHANGED
|
@@ -28,6 +28,7 @@ export { Badge } from './components/Badge'
|
|
|
28
28
|
export { Carousel } from './components/Carousel'
|
|
29
29
|
export { Card } from './components/Card'
|
|
30
30
|
export * from './components/ActionIcon'
|
|
31
|
+
export * from './components/Pagination'
|
|
31
32
|
|
|
32
33
|
// core-components ------------------------------------------------------
|
|
33
34
|
|