Skip to content

Commit

Permalink
chore(react-spinner): adopt custom JSX pragma (microsoft#27622)
Browse files Browse the repository at this point in the history
  • Loading branch information
bsunderhus authored and marcosmoura committed Apr 25, 2023
1 parent 013dae8 commit 9d3f1fd
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-spinner",
"email": "bernardo.sunderhus@gmail.com",
"dependentChangeType": "patch"
}
1 change: 1 addition & 0 deletions packages/react-components/react-spinner/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
"@fluentui/scripts-tasks": "*"
},
"dependencies": {
"@fluentui/react-jsx-runtime": "9.0.0-alpha.1",
"@fluentui/react-label": "^9.1.9",
"@fluentui/react-shared-contexts": "^9.3.3",
"@fluentui/react-theme": "^9.1.7",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
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 { SpinnerState, SpinnerSlots } from './Spinner.types';

/**
* Render the final JSX of Spinner
*/
export const renderSpinner_unstable = (state: SpinnerState) => {
const { slots, slotProps } = getSlots<SpinnerSlots>(state);
const { slots, slotProps } = getSlotsNext<SpinnerSlots>(state);
const { labelPosition } = state;
return (
<slots.root {...slotProps.root}>
Expand Down

0 comments on commit 9d3f1fd

Please sign in to comment.