Skip to content

Commit

Permalink
refactor(badge): optimize code
Browse files Browse the repository at this point in the history
  • Loading branch information
chouchouji committed Jul 24, 2024
1 parent a42d75b commit e06ed47
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/badge/badge.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { usePrefixClass } from '../hooks/useConfig';
export default defineComponent({
name: 'TBadge',
inheritAttrs: false,
props: { ...props },
props,
setup(props, { attrs }) {
const renderContent = useContent();
const renderTNodeJSX = useTNodeJSX();
Expand Down Expand Up @@ -52,7 +52,7 @@ export default defineComponent({
const inlineStyle = computed(() => {
const { xOffset, yOffset } = getOffset();
return {
background: `${props.color}`,
background: props.color,
right: xOffset,
top: yOffset,
};
Expand Down

0 comments on commit e06ed47

Please sign in to comment.