Skip to content
This repository was archived by the owner on Sep 20, 2024. It is now read-only.

Commit 12000a1

Browse files
committed
feat(layout): export Badge with theming props
1 parent ab8c90b commit 12000a1

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

packages/layout/src/badge.ts

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import {
55
HTMLChakraProps,
66
ThemingProps,
77
useStyleConfig,
8+
ComponentWithProps,
9+
DeepPartial,
810
} from '@chakra-ui/vue-system'
911
import { filterUndefined } from '@chakra-ui/utils'
1012
import { vueThemingProps } from '@chakra-ui/vue-utils'
@@ -13,13 +15,7 @@ export interface BadgeProps
1315
extends HTMLChakraProps<'span'>,
1416
ThemingProps<'Badge'> {}
1517

16-
/**
17-
* Vue component used to display notifications, messages, or
18-
* statuses in different shapes and sizes.
19-
*
20-
* @see Docs https://vue.chakra-ui.com/docs/data-display/badge
21-
*/
22-
export const CBadge = defineComponent({
18+
const CBadgeImpl = defineComponent({
2319
props: {
2420
as: {
2521
type: [Object, String] as PropType<DOMElements>,
@@ -54,3 +50,11 @@ export const CBadge = defineComponent({
5450
}
5551
},
5652
})
53+
54+
/**
55+
* Vue component used to display notifications, messages, or
56+
* statuses in different shapes and sizes.
57+
*
58+
* @see Docs https://vue.chakra-ui.com/docs/data-display/badge
59+
*/
60+
export const CBadge = CBadgeImpl as ComponentWithProps<DeepPartial<BadgeProps>>

0 commit comments

Comments
 (0)