Skip to content

Commit

Permalink
chore(react-badge): adopt custom JSX pragma
Browse files Browse the repository at this point in the history
  • Loading branch information
bsunderhus committed Apr 18, 2023
1 parent d340ff4 commit 8821b69
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "patch",
"comment": "chore: adopt custom JSX pragma",
"packageName": "@fluentui/react-badge",
"email": "bernardo.sunderhus@gmail.com",
"dependentChangeType": "patch"
}
1 change: 1 addition & 0 deletions packages/react-components/react-badge/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
},
"dependencies": {
"@fluentui/react-icons": "^2.0.196",
"@fluentui/react-jsx-runtime": "9.0.0-alpha.1",
"@fluentui/react-shared-contexts": "^9.3.3",
"@fluentui/react-theme": "^9.1.7",
"@fluentui/react-utilities": "^9.8.0",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
import * as React from 'react';
import { getSlots } from '@fluentui/react-utilities';
/** @jsxRuntime classic */
/** @jsx createElement */

import { createElement } from '@fluentui/react-jsx-runtime';

import { getSlotsNext } from '@fluentui/react-utilities';
import type { BadgeState, BadgeSlots } from './Badge.types';

export const renderBadge_unstable = (state: BadgeState) => {
const { slots, slotProps } = getSlots<BadgeSlots>(state);
const { slots, slotProps } = getSlotsNext<BadgeSlots>(state);

return (
<slots.root {...slotProps.root}>
Expand Down

0 comments on commit 8821b69

Please sign in to comment.