Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@fluentui/react-label

Package Overview
Dependencies
Maintainers
13
Versions
933
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@fluentui/react-label - npm Package Compare versions

Comparing version 0.0.0-nightlyd514b3e0ee20220121.1 to 0.0.0-nightlyd80c90385320220216.1

141

CHANGELOG.json

@@ -5,5 +5,5 @@ {

{
"date": "Fri, 21 Jan 2022 04:16:21 GMT",
"tag": "@fluentui/react-label_v0.0.0-nightlyd514b3e0ee20220121.1",
"version": "0.0.0-nightlyd514b3e0ee20220121.1",
"date": "Wed, 16 Feb 2022 04:14:19 GMT",
"tag": "@fluentui/react-label_v0.0.0-nightlyd80c90385320220216.1",
"version": "0.0.0-nightlyd80c90385320220216.1",
"comments": {

@@ -14,78 +14,135 @@ "prerelease": [

"package": "@fluentui/react-label",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090",
"commit": "685891ff65eff67542456c5908f5ee1c2f121f4c",
"comment": "Release nightly v9"
},
{
"author": "Humberto.Morimoto@microsoft.com",
"author": "beachball",
"package": "@fluentui/react-label",
"commit": "a052fbc9204600669d32b0ac346032d2cd8d9204",
"comment": "react-label: Replacing use of functions in makeStyles with direct use of tokens."
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightlyd80c90385320220216.1",
"commit": "685891ff65eff67542456c5908f5ee1c2f121f4c"
},
{
"author": "behowell@microsoft.com",
"author": "beachball",
"package": "@fluentui/react-label",
"commit": "7cc28ed8320b00f42d91c63882f10316db2205c5",
"comment": "Remove component's shorthandProps array"
},
"comment": "Bump @fluentui/react-conformance-griffel to v0.0.0-nightlyd80c90385320220216.1",
"commit": "685891ff65eff67542456c5908f5ee1c2f121f4c"
}
]
}
},
{
"date": "Thu, 10 Feb 2022 08:51:22 GMT",
"tag": "@fluentui/react-label_v9.0.0-beta.5",
"version": "9.0.0-beta.5",
"comments": {
"none": [
{
"author": "Humberto.Morimoto@microsoft.com",
"author": "martinhochel@microsoft.com",
"package": "@fluentui/react-label",
"commit": "00a5d945904c896a0664de6ba72c145a255f0848",
"comment": "Updating use of tokens.fontWeight now that we don't need to use casting."
"commit": "8dfa712156b70414205b87b5b6d099367b0c297d",
"comment": "chore: use storybook runner for all vNext packages"
},
{
"author": "beachball",
"author": "elcraig@microsoft.com",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090"
"commit": "d892c7f79c543b6008634ecd669b75b5108cad46",
"comment": "Relocate comment about props to the correct type, and update spec to accurately reflect props"
},
{
"author": "beachball",
"author": "bsunderhus@microsoft.com",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightlyd514b3e0ee20220121.1",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090"
"commit": "c0d4e63ee58e60e2c6674efbacc0783cd520984e",
"comment": "Updates components with nullRender changes"
},
{
"author": "beachball",
"author": "elcraig@microsoft.com",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/babel-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090"
"commit": "96d9c93544464bcc5ec36b7c5d724b77ae499c73",
"comment": "Update docs description"
},
{
"author": "beachball",
"author": "andredias@microsoft.com",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090"
"commit": "084a7183511bae60a43e57fbd57979349c4736a4",
"comment": "Migrate package to use solution tsconfigs"
},
{
"author": "beachball",
"author": "olfedias@microsoft.com",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1",
"commit": "89feafb688fbb160fb8519724479b3c68a79d090"
"commit": "c061e98be4b4a718c72a144a1f60bb5515824612",
"comment": "remove inline-style-expand-shorthand from tsconfigs"
}
],
"none": [
"prerelease": [
{
"author": "martinhochel@microsoft.com",
"author": "lingfangao@hotmail.com",
"package": "@fluentui/react-label",
"commit": "8dfa712156b70414205b87b5b6d099367b0c297d",
"comment": "chore: use storybook runner for all vNext packages"
"commit": "c00913d50e2dd15bbfbb0757cefe43b192ff1d7f",
"comment": "Bump Fluent UI dependencies to 9.0.0-rc"
},
{
"author": "elcraig@microsoft.com",
"author": "olfedias@microsoft.com",
"package": "@fluentui/react-label",
"commit": "d892c7f79c543b6008634ecd669b75b5108cad46",
"comment": "Relocate comment about props to the correct type, and update spec to accurately reflect props"
"commit": "742c191b7f2ea28505e49304117c090f9f36386c",
"comment": "Replace make-styles packages with griffel equivalents."
},
{
"author": "andredias@microsoft.com",
"author": "mgodbolt@microsoft.com",
"package": "@fluentui/react-label",
"commit": "084a7183511bae60a43e57fbd57979349c4736a4",
"comment": "Migrate package to use solution tsconfigs"
"commit": "839ec14849e112b85aa321d034739ec421199141",
"comment": "remove export of commons types"
},
{
"author": "olfedias@microsoft.com",
"author": "Humberto.Morimoto@microsoft.com",
"package": "@fluentui/react-label",
"commit": "c061e98be4b4a718c72a144a1f60bb5515824612",
"comment": "remove inline-style-expand-shorthand from tsconfigs"
"commit": "e0b8e1fa6980077e7b311fd1c72c28d3e4305db0",
"comment": "Updating based on changes to composition types."
},
{
"author": "Humberto.Morimoto@microsoft.com",
"package": "@fluentui/react-label",
"commit": "0bc161458eae5ae8d387172430496ce9829b1bb1",
"comment": "Using ComponentSlotProps instead of ObjectShorthandProps."
},
{
"author": "behowell@microsoft.com",
"package": "@fluentui/react-label",
"commit": "53b01d71e335715fda91b33e3d7bbd9d471d5ed3",
"comment": "Refactor component Slot typings"
},
{
"author": "Humberto.Morimoto@microsoft.com",
"package": "@fluentui/react-label",
"commit": "a052fbc9204600669d32b0ac346032d2cd8d9204",
"comment": "react-label: Replacing use of functions in makeStyles with direct use of tokens."
},
{
"author": "behowell@microsoft.com",
"package": "@fluentui/react-label",
"commit": "7cc28ed8320b00f42d91c63882f10316db2205c5",
"comment": "Remove component's shorthandProps array"
},
{
"author": "behowell@microsoft.com",
"package": "@fluentui/react-label",
"commit": "317209bb5cd57c40f35bc42060acb7e3cce5ec95",
"comment": "BREAKING: Rename component hooks add the suffix _unstable, as their API has not been finalized yet"
},
{
"author": "Humberto.Morimoto@microsoft.com",
"package": "@fluentui/react-label",
"commit": "00a5d945904c896a0664de6ba72c145a255f0848",
"comment": "Updating use of tokens.fontWeight now that we don't need to use casting."
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-utilities to v9.0.0-rc.1",
"commit": "e6c855f6d9019d6c73668d15fc9bc3a13291a6c8"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-conformance-griffel to v9.0.0-beta.1",
"commit": "e6c855f6d9019d6c73668d15fc9bc3a13291a6c8"
}

@@ -92,0 +149,0 @@ ]

# Change Log - @fluentui/react-label
This log was last generated on Fri, 21 Jan 2022 04:16:21 GMT and should not be manually modified.
This log was last generated on Wed, 16 Feb 2022 04:14:19 GMT and should not be manually modified.
<!-- Start content -->
## [0.0.0-nightlyd514b3e0ee20220121.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v0.0.0-nightlyd514b3e0ee20220121.1)
## [0.0.0-nightlyd80c90385320220216.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v0.0.0-nightlyd80c90385320220216.1)
Fri, 21 Jan 2022 04:16:21 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.4..@fluentui/react-label_v0.0.0-nightlyd514b3e0ee20220121.1)
Wed, 16 Feb 2022 04:14:19 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.5..@fluentui/react-label_v0.0.0-nightlyd80c90385320220216.1)
### Changes
- Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by email not defined)
- Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/685891ff65eff67542456c5908f5ee1c2f121f4c) by email not defined)
- Bump @fluentui/react-utilities to v0.0.0-nightlyd80c90385320220216.1 ([commit](https://github.com/microsoft/fluentui/commit/685891ff65eff67542456c5908f5ee1c2f121f4c) by beachball)
- Bump @fluentui/react-conformance-griffel to v0.0.0-nightlyd80c90385320220216.1 ([commit](https://github.com/microsoft/fluentui/commit/685891ff65eff67542456c5908f5ee1c2f121f4c) by beachball)
## [9.0.0-beta.5](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v9.0.0-beta.5)
Thu, 10 Feb 2022 08:51:22 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.4..@fluentui/react-label_v9.0.0-beta.5)
### Changes
- Bump Fluent UI dependencies to 9.0.0-rc ([PR #21623](https://github.com/microsoft/fluentui/pull/21623) by lingfangao@hotmail.com)
- Replace make-styles packages with griffel equivalents. ([PR #21430](https://github.com/microsoft/fluentui/pull/21430) by olfedias@microsoft.com)
- remove export of commons types ([PR #21660](https://github.com/microsoft/fluentui/pull/21660) by mgodbolt@microsoft.com)
- Updating based on changes to composition types. ([PR #20891](https://github.com/microsoft/fluentui/pull/20891) by Humberto.Morimoto@microsoft.com)
- Using ComponentSlotProps instead of ObjectShorthandProps. ([PR #20890](https://github.com/microsoft/fluentui/pull/20890) by Humberto.Morimoto@microsoft.com)
- Refactor component Slot typings ([PR #21518](https://github.com/microsoft/fluentui/pull/21518) by behowell@microsoft.com)
- react-label: Replacing use of functions in makeStyles with direct use of tokens. ([PR #21046](https://github.com/microsoft/fluentui/pull/21046) by Humberto.Morimoto@microsoft.com)
- Remove component's shorthandProps array ([PR #21134](https://github.com/microsoft/fluentui/pull/21134) by behowell@microsoft.com)
- BREAKING: Rename component hooks add the suffix _unstable, as their API has not been finalized yet ([PR #21365](https://github.com/microsoft/fluentui/pull/21365) by behowell@microsoft.com)
- Updating use of tokens.fontWeight now that we don't need to use casting. ([PR #21217](https://github.com/microsoft/fluentui/pull/21217) by Humberto.Morimoto@microsoft.com)
- Bump @fluentui/react-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by beachball)
- Bump @fluentui/react-utilities to v0.0.0-nightlyd514b3e0ee20220121.1 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by beachball)
- Bump @fluentui/babel-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by beachball)
- Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by beachball)
- Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyd514b3e0ee20220121.1 ([commit](https://github.com/microsoft/fluentui/commit/89feafb688fbb160fb8519724479b3c68a79d090) by beachball)
- Bump @fluentui/react-utilities to v9.0.0-rc.1 ([commit](https://github.com/microsoft/fluentui/commit/e6c855f6d9019d6c73668d15fc9bc3a13291a6c8) by beachball)
- Bump @fluentui/react-conformance-griffel to v9.0.0-beta.1 ([commit](https://github.com/microsoft/fluentui/commit/e6c855f6d9019d6c73668d15fc9bc3a13291a6c8) by beachball)

@@ -24,0 +38,0 @@ ## [9.0.0-beta.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v9.0.0-beta.4)

import type { ComponentProps } from '@fluentui/react-utilities';
import type { ComponentState } from '@fluentui/react-utilities';
import type { ForwardRefComponent } from '@fluentui/react-utilities';
import type { IntrinsicShorthandProps } from '@fluentui/react-utilities';
import type { ObjectShorthandProps } from '@fluentui/react-utilities';
import * as React_2 from 'react';
import type { Slot } from '@fluentui/react-utilities';

@@ -15,3 +14,3 @@ /**

export declare type LabelCommons = {
declare type LabelCommons = {
/**

@@ -43,8 +42,8 @@ * Renders the label as disabled

*/
required?: boolean | ObjectShorthandProps<React_2.HTMLAttributes<HTMLElement>> | React_2.ReactNode;
required?: boolean | Slot<'span'>;
};
export declare type LabelSlots = {
root: IntrinsicShorthandProps<'label'>;
required?: IntrinsicShorthandProps<'span'>;
root: Slot<'label'>;
required?: Slot<'span'>;
};

@@ -60,3 +59,3 @@

*/
export declare const renderLabel: (state: LabelState) => JSX.Element;
export declare const renderLabel_unstable: (state: LabelState) => JSX.Element;

@@ -66,4 +65,4 @@ /**

*
* The returned state can be modified with hooks such as useLabelStyles,
* before being passed to renderLabel.
* The returned state can be modified with hooks such as useLabelStyles_unstable,
* before being passed to renderLabel_unstable.
*

@@ -73,3 +72,3 @@ * @param props - props from this instance of Label

*/
export declare const useLabel: (props: LabelProps, ref: React_2.Ref<HTMLElement>) => LabelState;
export declare const useLabel_unstable: (props: LabelProps, ref: React_2.Ref<HTMLElement>) => LabelState;

@@ -79,4 +78,4 @@ /**

*/
export declare const useLabelStyles: (state: LabelState) => LabelState;
export declare const useLabelStyles_unstable: (state: LabelState) => LabelState;
export { }

@@ -21,7 +21,7 @@ "use strict";

exports.Label = /*#__PURE__*/React.forwardRef((props, ref) => {
const state = useLabel_1.useLabel(props, ref);
useLabelStyles_1.useLabelStyles(state);
return renderLabel_1.renderLabel(state);
const state = useLabel_1.useLabel_unstable(props, ref);
useLabelStyles_1.useLabelStyles_unstable(state);
return renderLabel_1.renderLabel_unstable(state);
});
exports.Label.displayName = 'Label';
//# sourceMappingURL=Label.js.map

@@ -1,4 +0,3 @@

import type { ComponentProps, ComponentState, IntrinsicShorthandProps, ObjectShorthandProps } from '@fluentui/react-utilities';
import * as React from 'react';
export declare type LabelCommons = {
import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';
declare type LabelCommons = {
/**

@@ -21,4 +20,4 @@ * Renders the label as disabled

export declare type LabelSlots = {
root: IntrinsicShorthandProps<'label'>;
required?: IntrinsicShorthandProps<'span'>;
root: Slot<'label'>;
required?: Slot<'span'>;
};

@@ -38,3 +37,4 @@ /**

*/
required?: boolean | ObjectShorthandProps<React.HTMLAttributes<HTMLElement>> | React.ReactNode;
required?: boolean | Slot<'span'>;
};
export {};

@@ -5,2 +5,2 @@ import type { LabelState } from './Label.types';

*/
export declare const renderLabel: (state: LabelState) => JSX.Element;
export declare const renderLabel_unstable: (state: LabelState) => JSX.Element;

@@ -6,3 +6,3 @@ "use strict";

});
exports.renderLabel = void 0;
exports.renderLabel_unstable = void 0;

@@ -17,3 +17,3 @@ const React = /*#__PURE__*/require("react");

const renderLabel = state => {
const renderLabel_unstable = state => {
const {

@@ -24,7 +24,7 @@ slots,

return React.createElement(slots.root, { ...slotProps.root
}, state.root.children, React.createElement(slots.required, { ...slotProps.required
}, state.root.children, slots.required && React.createElement(slots.required, { ...slotProps.required
}));
};
exports.renderLabel = renderLabel;
exports.renderLabel_unstable = renderLabel_unstable;
//# sourceMappingURL=renderLabel.js.map

@@ -6,4 +6,4 @@ import * as React from 'react';

*
* The returned state can be modified with hooks such as useLabelStyles,
* before being passed to renderLabel.
* The returned state can be modified with hooks such as useLabelStyles_unstable,
* before being passed to renderLabel_unstable.
*

@@ -13,2 +13,2 @@ * @param props - props from this instance of Label

*/
export declare const useLabel: (props: LabelProps, ref: React.Ref<HTMLElement>) => LabelState;
export declare const useLabel_unstable: (props: LabelProps, ref: React.Ref<HTMLElement>) => LabelState;

@@ -6,3 +6,3 @@ "use strict";

});
exports.useLabel = void 0;
exports.useLabel_unstable = void 0;

@@ -15,4 +15,4 @@ const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");

*
* The returned state can be modified with hooks such as useLabelStyles,
* before being passed to renderLabel.
* The returned state can be modified with hooks such as useLabelStyles_unstable,
* before being passed to renderLabel_unstable.
*

@@ -24,3 +24,3 @@ * @param props - props from this instance of Label

const useLabel = (props, ref) => {
const useLabel_unstable = (props, ref) => {
const {

@@ -34,6 +34,4 @@ disabled = false,

disabled,
required: react_utilities_2.resolveShorthand(required === false ? null : required, {
required: !!required,
required: react_utilities_2.resolveShorthand(required === true ? '*' : required || undefined, {
defaultProps: {
children: '*',
'aria-hidden': 'true'

@@ -55,3 +53,3 @@ }

exports.useLabel = useLabel;
exports.useLabel_unstable = useLabel_unstable;
//# sourceMappingURL=useLabel.js.map

@@ -6,2 +6,2 @@ import type { LabelState } from './Label.types';

*/
export declare const useLabelStyles: (state: LabelState) => LabelState;
export declare const useLabelStyles_unstable: (state: LabelState) => LabelState;

@@ -6,5 +6,5 @@ "use strict";

});
exports.useLabelStyles = exports.labelClassName = void 0;
exports.useLabelStyles_unstable = exports.labelClassName = void 0;
const react_make_styles_1 = /*#__PURE__*/require("@fluentui/react-make-styles");
const react_1 = /*#__PURE__*/require("@griffel/react");

@@ -18,3 +18,3 @@ const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");

const useStyles = /*#__PURE__*/react_make_styles_1.__styles({
const useStyles = /*#__PURE__*/react_1.__styles({
"root": {

@@ -55,8 +55,8 @@ "Bahqtrf": "fk6fouc",

const useLabelStyles = state => {
const useLabelStyles_unstable = state => {
const styles = useStyles();
state.root.className = react_make_styles_1.mergeClasses(exports.labelClassName, styles.root, state.disabled && styles.disabled, styles[state.size], state.strong && styles.strong, state.root.className);
state.root.className = react_1.mergeClasses(exports.labelClassName, styles.root, state.disabled && styles.disabled, styles[state.size], state.strong && styles.strong, state.root.className);
if (state.required) {
state.required.className = react_make_styles_1.mergeClasses(styles.required, state.required.className);
state.required.className = react_1.mergeClasses(styles.required, state.required.className);
}

@@ -67,3 +67,3 @@

exports.useLabelStyles = useLabelStyles;
exports.useLabelStyles_unstable = useLabelStyles_unstable;
//# sourceMappingURL=useLabelStyles.js.map
import * as React from 'react';
import { useLabel } from './useLabel';
import { renderLabel } from './renderLabel';
import { useLabelStyles } from './useLabelStyles';
import { useLabel_unstable } from './useLabel';
import { renderLabel_unstable } from './renderLabel';
import { useLabelStyles_unstable } from './useLabelStyles';
/**

@@ -10,7 +10,7 @@ * A label component provides a title or name to a component.

export const Label = /*#__PURE__*/React.forwardRef((props, ref) => {
const state = useLabel(props, ref);
useLabelStyles(state);
return renderLabel(state);
const state = useLabel_unstable(props, ref);
useLabelStyles_unstable(state);
return renderLabel_unstable(state);
});
Label.displayName = 'Label';
//# sourceMappingURL=Label.js.map

@@ -1,4 +0,3 @@

import type { ComponentProps, ComponentState, IntrinsicShorthandProps, ObjectShorthandProps } from '@fluentui/react-utilities';
import * as React from 'react';
export declare type LabelCommons = {
import type { ComponentProps, ComponentState, Slot } from '@fluentui/react-utilities';
declare type LabelCommons = {
/**

@@ -21,4 +20,4 @@ * Renders the label as disabled

export declare type LabelSlots = {
root: IntrinsicShorthandProps<'label'>;
required?: IntrinsicShorthandProps<'span'>;
root: Slot<'label'>;
required?: Slot<'span'>;
};

@@ -38,3 +37,4 @@ /**

*/
required?: boolean | ObjectShorthandProps<React.HTMLAttributes<HTMLElement>> | React.ReactNode;
required?: boolean | Slot<'span'>;
};
export {};

@@ -5,2 +5,2 @@ import type { LabelState } from './Label.types';

*/
export declare const renderLabel: (state: LabelState) => JSX.Element;
export declare const renderLabel_unstable: (state: LabelState) => JSX.Element;

@@ -7,3 +7,3 @@ import * as React from 'react';

export const renderLabel = state => {
export const renderLabel_unstable = state => {
const {

@@ -14,5 +14,5 @@ slots,

return /*#__PURE__*/React.createElement(slots.root, { ...slotProps.root
}, state.root.children, /*#__PURE__*/React.createElement(slots.required, { ...slotProps.required
}, state.root.children, slots.required && /*#__PURE__*/React.createElement(slots.required, { ...slotProps.required
}));
};
//# sourceMappingURL=renderLabel.js.map

@@ -6,4 +6,4 @@ import * as React from 'react';

*
* The returned state can be modified with hooks such as useLabelStyles,
* before being passed to renderLabel.
* The returned state can be modified with hooks such as useLabelStyles_unstable,
* before being passed to renderLabel_unstable.
*

@@ -13,2 +13,2 @@ * @param props - props from this instance of Label

*/
export declare const useLabel: (props: LabelProps, ref: React.Ref<HTMLElement>) => LabelState;
export declare const useLabel_unstable: (props: LabelProps, ref: React.Ref<HTMLElement>) => LabelState;

@@ -6,4 +6,4 @@ import { getNativeElementProps } from '@fluentui/react-utilities';

*
* The returned state can be modified with hooks such as useLabelStyles,
* before being passed to renderLabel.
* The returned state can be modified with hooks such as useLabelStyles_unstable,
* before being passed to renderLabel_unstable.
*

@@ -14,3 +14,3 @@ * @param props - props from this instance of Label

export const useLabel = (props, ref) => {
export const useLabel_unstable = (props, ref) => {
const {

@@ -24,6 +24,4 @@ disabled = false,

disabled,
required: resolveShorthand(required === false ? null : required, {
required: !!required,
required: resolveShorthand(required === true ? '*' : required || undefined, {
defaultProps: {
children: '*',
'aria-hidden': 'true'

@@ -30,0 +28,0 @@ }

@@ -6,2 +6,2 @@ import type { LabelState } from './Label.types';

*/
export declare const useLabelStyles: (state: LabelState) => LabelState;
export declare const useLabelStyles_unstable: (state: LabelState) => LabelState;

@@ -1,2 +0,2 @@

import { __styles, mergeClasses } from '@fluentui/react-make-styles';
import { __styles, mergeClasses } from '@griffel/react';
import { tokens } from '@fluentui/react-theme';

@@ -44,3 +44,3 @@ export const labelClassName = 'fui-Label';

export const useLabelStyles = state => {
export const useLabelStyles_unstable = state => {
const styles = useStyles();

@@ -47,0 +47,0 @@ state.root.className = mergeClasses(labelClassName, styles.root, state.disabled && styles.disabled, styles[state.size], state.strong && styles.strong, state.root.className);

{
"name": "@fluentui/react-label",
"version": "0.0.0-nightlyd514b3e0ee20220121.1",
"description": "Label component for FluentUI library.",
"version": "0.0.0-nightlyd80c90385320220216.1",
"description": "Fluent UI React Label component",
"main": "lib-commonjs/index.js",

@@ -29,7 +29,5 @@ "module": "lib/index.js",

"devDependencies": {
"@fluentui/babel-make-styles": "0.0.0-nightlyd514b3e0ee20220121.1",
"@fluentui/eslint-plugin": "*",
"@fluentui/jest-serializer-make-styles": "0.0.0-nightlyd514b3e0ee20220121.1",
"@fluentui/react-conformance": "*",
"@fluentui/react-conformance-make-styles": "0.0.0-nightlyd514b3e0ee20220121.1",
"@fluentui/react-conformance-griffel": "0.0.0-nightlyd80c90385320220216.1",
"@fluentui/scripts": "^1.0.0",

@@ -48,4 +46,4 @@ "@types/enzyme": "3.10.3",

"dependencies": {
"@fluentui/react-make-styles": "0.0.0-nightlyd514b3e0ee20220121.1",
"@fluentui/react-utilities": "0.0.0-nightlyd514b3e0ee20220121.1",
"@fluentui/react-utilities": "0.0.0-nightlyd80c90385320220216.1",
"@griffel/react": "1.0.0",
"tslib": "^2.1.0"

@@ -52,0 +50,0 @@ },

@@ -99,4 +99,4 @@ # @fluentui/react-label Spec

export type LabelSlots = {
root: IntrinsicShorthandProps<'label'>;
required?: IntrinsicShorthandProps<'span'>;
root: IntrinsicSlotProps<'label'>;
required?: IntrinsicSlotProps<'span'>;
};

@@ -119,3 +119,3 @@

*/
required?: boolean | ObjectShorthandProps<React.HTMLAttributes<HTMLElement>> | React.ReactNode;
required?: boolean | IntrinsicSlotProps<'span'> | React.ReactNode;
};

@@ -122,0 +122,0 @@ ```

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc