diff --git a/change/@fluentui-react-utilities-84a6b1af-e457-4e58-b948-078b64bc46c7.json b/change/@fluentui-react-utilities-84a6b1af-e457-4e58-b948-078b64bc46c7.json new file mode 100644 index 0000000000000..7115a00222603 --- /dev/null +++ b/change/@fluentui-react-utilities-84a6b1af-e457-4e58-b948-078b64bc46c7.json @@ -0,0 +1,7 @@ +{ + "type": "prerelease", + "comment": "feat: add time element on nativeElementMap", + "packageName": "@fluentui/react-utilities", + "email": "bsunderhus@microsoft.com", + "dependentChangeType": "patch" +} diff --git a/packages/react-components/react-utilities/src/utils/getNativeElementProps.ts b/packages/react-components/react-utilities/src/utils/getNativeElementProps.ts index 5eab59ccef831..6e5b988143d4e 100644 --- a/packages/react-components/react-utilities/src/utils/getNativeElementProps.ts +++ b/packages/react-components/react-utilities/src/utils/getNativeElementProps.ts @@ -23,6 +23,7 @@ import { imgProperties, htmlElementProperties, getNativeProps, + timeProperties, } from './properties'; const nativeElementMap: Record> = { @@ -47,6 +48,7 @@ const nativeElementMap: Record> = { form: formProperties, iframe: iframeProperties, img: imgProperties, + time: timeProperties, }; /** diff --git a/packages/react-components/react-utilities/src/utils/properties.ts b/packages/react-components/react-utilities/src/utils/properties.ts index 368f924e30947..98f8e939563f1 100644 --- a/packages/react-components/react-utilities/src/utils/properties.ts +++ b/packages/react-components/react-utilities/src/utils/properties.ts @@ -198,6 +198,15 @@ export const anchorProperties = toObjectMap(htmlElementProperties, [ 'type', // a, button, input, link, menu, object, script, source, style ]); +/** + * An array of TIME tag properties and events. + * + * @public + */ +export const timeProperties = toObjectMap(htmlElementProperties, [ + 'dateTime', // time +]); + /** * An array of BUTTON tag properties and events. *