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
924
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-nightlyf3ce1fbe1d20211110.1 to 0.0.0-nightlyf6116328d620220124.1

174

CHANGELOG.json

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

{
"date": "Wed, 10 Nov 2021 04:16:48 GMT",
"tag": "@fluentui/react-label_v0.0.0-nightlyf3ce1fbe1d20211110.1",
"version": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"date": "Mon, 24 Jan 2022 04:14:07 GMT",
"tag": "@fluentui/react-label_v0.0.0-nightlyf6116328d620220124.1",
"version": "0.0.0-nightlyf6116328d620220124.1",
"comments": {

@@ -14,22 +14,28 @@ "prerelease": [

"package": "@fluentui/react-label",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941",
"comment": "Release nightly v9"
},
{
"author": "gcox@microsoft.com",
"author": "Humberto.Morimoto@microsoft.com",
"package": "@fluentui/react-label",
"commit": "c9bd5b5a02ae94a8239ce1b56cac2f0d0dbd3586",
"comment": "Updated beta and RC components to ES2019"
"commit": "a052fbc9204600669d32b0ac346032d2cd8d9204",
"comment": "react-label: Replacing use of functions in makeStyles with direct use of tokens."
},
{
"author": "olfedias@microsoft.com",
"author": "behowell@microsoft.com",
"package": "@fluentui/react-label",
"commit": "9186578324773f95f4d61be3d70e67752159d843",
"comment": "export static classes for components"
"commit": "7cc28ed8320b00f42d91c63882f10316db2205c5",
"comment": "Remove component's shorthandProps array"
},
{
"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-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a"
"comment": "Bump @fluentui/react-make-styles to v0.0.0-nightlyf6116328d620220124.1",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941"
},

@@ -39,4 +45,4 @@ {

"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightlyf3ce1fbe1d20211110.1",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a"
"comment": "Bump @fluentui/react-utilities to v0.0.0-nightlyf6116328d620220124.1",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941"
},

@@ -46,4 +52,4 @@ {

"package": "@fluentui/react-label",
"comment": "Bump @fluentui/babel-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a"
"comment": "Bump @fluentui/babel-make-styles to v0.0.0-nightlyf6116328d620220124.1",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941"
},

@@ -53,4 +59,4 @@ {

"package": "@fluentui/react-label",
"comment": "Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a"
"comment": "Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyf6116328d620220124.1",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941"
},

@@ -60,4 +66,4 @@ {

"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1",
"commit": "c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a"
"comment": "Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyf6116328d620220124.1",
"commit": "7e40e770b133f0e9b5a0ba356e78ea25a8647941"
}

@@ -67,2 +73,80 @@ ],

{
"author": "martinhochel@microsoft.com",
"package": "@fluentui/react-label",
"commit": "8dfa712156b70414205b87b5b6d099367b0c297d",
"comment": "chore: use storybook runner for all vNext packages"
},
{
"author": "elcraig@microsoft.com",
"package": "@fluentui/react-label",
"commit": "d892c7f79c543b6008634ecd669b75b5108cad46",
"comment": "Relocate comment about props to the correct type, and update spec to accurately reflect props"
},
{
"author": "andredias@microsoft.com",
"package": "@fluentui/react-label",
"commit": "084a7183511bae60a43e57fbd57979349c4736a4",
"comment": "Migrate package to use solution tsconfigs"
},
{
"author": "olfedias@microsoft.com",
"package": "@fluentui/react-label",
"commit": "c061e98be4b4a718c72a144a1f60bb5515824612",
"comment": "remove inline-style-expand-shorthand from tsconfigs"
}
]
}
},
{
"date": "Thu, 25 Nov 2021 08:34:14 GMT",
"tag": "@fluentui/react-label_v9.0.0-beta.4",
"version": "9.0.0-beta.4",
"comments": {
"prerelease": [
{
"author": "ololubek@microsoft.com",
"package": "@fluentui/react-label",
"commit": "a683ee69b17c667227acb71c59f609b4f1ca1ef9",
"comment": "Add aria-hidden to Label required field"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-make-styles to v9.0.0-beta.4",
"commit": "48d236ac53a4950fabc3ddd52f91dac93ca0195b"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-utilities to v9.0.0-beta.4",
"commit": "48d236ac53a4950fabc3ddd52f91dac93ca0195b"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/babel-make-styles to v9.0.0-beta.4",
"commit": "48d236ac53a4950fabc3ddd52f91dac93ca0195b"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/jest-serializer-make-styles to v9.0.0-beta.4",
"commit": "48d236ac53a4950fabc3ddd52f91dac93ca0195b"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-conformance-make-styles to v9.0.0-beta.4",
"commit": "48d236ac53a4950fabc3ddd52f91dac93ca0195b"
}
]
}
},
{
"date": "Fri, 12 Nov 2021 13:25:25 GMT",
"tag": "@fluentui/react-label_v9.0.0-beta.3",
"version": "9.0.0-beta.3",
"comments": {
"none": [
{
"author": "lingfangao@hotmail.com",

@@ -72,3 +156,53 @@ "package": "@fluentui/react-label",

"comment": "chore(Label): Rework documentation to desired format"
},
{
"author": "lingfangao@hotmail.com",
"package": "@fluentui/react-label",
"commit": "00f70581480b536e723fb69edf0ae617beac4807",
"comment": "Remove beta release tag"
}
],
"prerelease": [
{
"author": "gcox@microsoft.com",
"package": "@fluentui/react-label",
"commit": "c9bd5b5a02ae94a8239ce1b56cac2f0d0dbd3586",
"comment": "Updated beta and RC components to ES2019"
},
{
"author": "olfedias@microsoft.com",
"package": "@fluentui/react-label",
"commit": "9186578324773f95f4d61be3d70e67752159d843",
"comment": "export static classes for components"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-make-styles to v9.0.0-beta.3",
"commit": "742342e52c65066f779232e4e1302fedf0dd460d"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-utilities to v9.0.0-beta.3",
"commit": "742342e52c65066f779232e4e1302fedf0dd460d"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/babel-make-styles to v9.0.0-beta.3",
"commit": "742342e52c65066f779232e4e1302fedf0dd460d"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/jest-serializer-make-styles to v9.0.0-beta.3",
"commit": "742342e52c65066f779232e4e1302fedf0dd460d"
},
{
"author": "beachball",
"package": "@fluentui/react-label",
"comment": "Bump @fluentui/react-conformance-make-styles to v9.0.0-beta.3",
"commit": "742342e52c65066f779232e4e1302fedf0dd460d"
}
]

@@ -75,0 +209,0 @@ }

50

CHANGELOG.md
# Change Log - @fluentui/react-label
This log was last generated on Wed, 10 Nov 2021 04:16:48 GMT and should not be manually modified.
This log was last generated on Mon, 24 Jan 2022 04:14:07 GMT and should not be manually modified.
<!-- Start content -->
## [0.0.0-nightlyf3ce1fbe1d20211110.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v0.0.0-nightlyf3ce1fbe1d20211110.1)
## [0.0.0-nightlyf6116328d620220124.1](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v0.0.0-nightlyf6116328d620220124.1)
Wed, 10 Nov 2021 04:16:48 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.2..@fluentui/react-label_v0.0.0-nightlyf3ce1fbe1d20211110.1)
Mon, 24 Jan 2022 04:14:07 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.4..@fluentui/react-label_v0.0.0-nightlyf6116328d620220124.1)
### Changes
- Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by email not defined)
- Release nightly v9 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by email not defined)
- 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)
- 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-nightlyf6116328d620220124.1 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by beachball)
- Bump @fluentui/react-utilities to v0.0.0-nightlyf6116328d620220124.1 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by beachball)
- Bump @fluentui/babel-make-styles to v0.0.0-nightlyf6116328d620220124.1 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by beachball)
- Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyf6116328d620220124.1 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by beachball)
- Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyf6116328d620220124.1 ([commit](https://github.com/microsoft/fluentui/commit/7e40e770b133f0e9b5a0ba356e78ea25a8647941) by beachball)
## [9.0.0-beta.4](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v9.0.0-beta.4)
Thu, 25 Nov 2021 08:34:14 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.3..@fluentui/react-label_v9.0.0-beta.4)
### Changes
- Add aria-hidden to Label required field ([PR #20680](https://github.com/microsoft/fluentui/pull/20680) by ololubek@microsoft.com)
- Bump @fluentui/react-make-styles to v9.0.0-beta.4 ([PR #20762](https://github.com/microsoft/fluentui/pull/20762) by beachball)
- Bump @fluentui/react-utilities to v9.0.0-beta.4 ([PR #20762](https://github.com/microsoft/fluentui/pull/20762) by beachball)
- Bump @fluentui/babel-make-styles to v9.0.0-beta.4 ([PR #20762](https://github.com/microsoft/fluentui/pull/20762) by beachball)
- Bump @fluentui/jest-serializer-make-styles to v9.0.0-beta.4 ([PR #20762](https://github.com/microsoft/fluentui/pull/20762) by beachball)
- Bump @fluentui/react-conformance-make-styles to v9.0.0-beta.4 ([PR #20762](https://github.com/microsoft/fluentui/pull/20762) by beachball)
## [9.0.0-beta.3](https://github.com/microsoft/fluentui/tree/@fluentui/react-label_v9.0.0-beta.3)
Fri, 12 Nov 2021 13:25:25 GMT
[Compare changes](https://github.com/microsoft/fluentui/compare/@fluentui/react-label_v9.0.0-beta.2..@fluentui/react-label_v9.0.0-beta.3)
### Changes
- Updated beta and RC components to ES2019 ([PR #20405](https://github.com/microsoft/fluentui/pull/20405) by gcox@microsoft.com)
- export static classes for components ([PR #20456](https://github.com/microsoft/fluentui/pull/20456) by olfedias@microsoft.com)
- Bump @fluentui/react-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by beachball)
- Bump @fluentui/react-utilities to v0.0.0-nightlyf3ce1fbe1d20211110.1 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by beachball)
- Bump @fluentui/babel-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by beachball)
- Bump @fluentui/jest-serializer-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by beachball)
- Bump @fluentui/react-conformance-make-styles to v0.0.0-nightlyf3ce1fbe1d20211110.1 ([commit](https://github.com/microsoft/fluentui/commit/c7a7f2302f3cfcbc6cd026f4d0ee4d5a2810371a) by beachball)
- Bump @fluentui/react-make-styles to v9.0.0-beta.3 ([PR #20583](https://github.com/microsoft/fluentui/pull/20583) by beachball)
- Bump @fluentui/react-utilities to v9.0.0-beta.3 ([PR #20583](https://github.com/microsoft/fluentui/pull/20583) by beachball)
- Bump @fluentui/babel-make-styles to v9.0.0-beta.3 ([PR #20583](https://github.com/microsoft/fluentui/pull/20583) by beachball)
- Bump @fluentui/jest-serializer-make-styles to v9.0.0-beta.3 ([PR #20583](https://github.com/microsoft/fluentui/pull/20583) by beachball)
- Bump @fluentui/react-conformance-make-styles to v9.0.0-beta.3 ([PR #20583](https://github.com/microsoft/fluentui/pull/20583) by beachball)

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

@@ -15,5 +15,2 @@ import type { ComponentProps } from '@fluentui/react-utilities';

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

@@ -37,2 +34,5 @@ /**

/**
* Label Props
*/
export declare type LabelProps = Omit<ComponentProps<LabelSlots>, 'required'> & Partial<LabelCommons> & {

@@ -47,8 +47,2 @@ /**

/**
* Array of all shorthand properties listed in LabelShorthandProps
* {@docCatergory Label}
*/
export declare const labelShorthandProps: Array<keyof LabelSlots>;
export declare type LabelSlots = {

@@ -55,0 +49,0 @@ root: IntrinsicShorthandProps<'label'>;

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

@@ -31,2 +28,5 @@ /**

export declare type LabelState = ComponentState<LabelSlots> & LabelCommons;
/**
* Label Props
*/
export declare type LabelProps = Omit<ComponentProps<LabelSlots>, 'required'> & Partial<LabelCommons> & {

@@ -33,0 +33,0 @@ /**

@@ -11,4 +11,2 @@ "use strict";

const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");
const useLabel_1 = /*#__PURE__*/require("./useLabel");
/**

@@ -23,4 +21,6 @@ * Render the final JSX of Label

slotProps
} = react_utilities_1.getSlots(state, useLabel_1.labelShorthandProps);
return React.createElement(slots.root, Object.assign({}, slotProps.root), state.root.children, React.createElement(slots.required, Object.assign({}, slotProps.required)));
} = react_utilities_1.getSlots(state);
return React.createElement(slots.root, { ...slotProps.root
}, state.root.children, React.createElement(slots.required, { ...slotProps.required
}));
};

@@ -27,0 +27,0 @@

import * as React from 'react';
import type { LabelProps, LabelSlots, LabelState } from './Label.types';
import type { LabelProps, LabelState } from './Label.types';
/**
* Array of all shorthand properties listed in LabelShorthandProps
* {@docCatergory Label}
*/
export declare const labelShorthandProps: Array<keyof LabelSlots>;
/**
* Create the state required to render Label.

@@ -10,0 +5,0 @@ *

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

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

@@ -13,9 +13,2 @@ const react_utilities_1 = /*#__PURE__*/require("@fluentui/react-utilities");

/**
* Array of all shorthand properties listed in LabelShorthandProps
* {@docCatergory Label}
*/
exports.labelShorthandProps = ['root', 'required'];
/**
* Create the state required to render Label.

@@ -30,2 +23,3 @@ *

const useLabel = (props, ref) => {

@@ -43,3 +37,4 @@ const {

defaultProps: {
children: '*'
children: '*',
'aria-hidden': 'true'
}

@@ -46,0 +41,0 @@ }),

@@ -10,2 +10,4 @@ "use strict";

const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
exports.labelClassName = 'fui-Label';

@@ -12,0 +14,0 @@ /**

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

@@ -31,2 +28,5 @@ /**

export declare type LabelState = ComponentState<LabelSlots> & LabelCommons;
/**
* Label Props
*/
export declare type LabelProps = Omit<ComponentProps<LabelSlots>, 'required'> & Partial<LabelCommons> & {

@@ -33,0 +33,0 @@ /**

import * as React from 'react';
import { getSlots } from '@fluentui/react-utilities';
import { labelShorthandProps } from './useLabel';
/**

@@ -12,5 +11,7 @@ * Render the final JSX of Label

slotProps
} = getSlots(state, labelShorthandProps);
return /*#__PURE__*/React.createElement(slots.root, Object.assign({}, slotProps.root), state.root.children, /*#__PURE__*/React.createElement(slots.required, Object.assign({}, slotProps.required)));
} = getSlots(state);
return /*#__PURE__*/React.createElement(slots.root, { ...slotProps.root
}, state.root.children, /*#__PURE__*/React.createElement(slots.required, { ...slotProps.required
}));
};
//# sourceMappingURL=renderLabel.js.map
import * as React from 'react';
import type { LabelProps, LabelSlots, LabelState } from './Label.types';
import type { LabelProps, LabelState } from './Label.types';
/**
* Array of all shorthand properties listed in LabelShorthandProps
* {@docCatergory Label}
*/
export declare const labelShorthandProps: Array<keyof LabelSlots>;
/**
* Create the state required to render Label.

@@ -10,0 +5,0 @@ *

import { getNativeElementProps } from '@fluentui/react-utilities';
import { resolveShorthand } from '@fluentui/react-utilities';
/**
* Array of all shorthand properties listed in LabelShorthandProps
* {@docCatergory Label}
*/
export const labelShorthandProps = ['root', 'required'];
/**
* Create the state required to render Label.

@@ -31,3 +25,4 @@ *

defaultProps: {
children: '*'
children: '*',
'aria-hidden': 'true'
}

@@ -34,0 +29,0 @@ }),

import { __styles, mergeClasses } from '@fluentui/react-make-styles';
import { tokens } from '@fluentui/react-theme';
export const labelClassName = 'fui-Label';

@@ -3,0 +4,0 @@ /**

{
"name": "@fluentui/react-label",
"version": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"version": "0.0.0-nightlyf6116328d620220124.1",
"description": "Label component for FluentUI library.",

@@ -22,13 +22,14 @@ "main": "lib-commonjs/index.js",

"start": "yarn storybook",
"test": "jest",
"test": "jest --passWithNoTests",
"docs": "api-extractor run --config=config/api-extractor.local.json --local",
"build:local": "tsc -p . --module esnext --emitDeclarationOnly && node ../../scripts/typescript/normalize-import --output dist/packages/react-label/src && yarn docs",
"storybook": "start-storybook"
"build:local": "tsc -p ./tsconfig.lib.json --module esnext --emitDeclarationOnly && node ../../scripts/typescript/normalize-import --output ./dist/packages/react-label/src && yarn docs",
"storybook": "node ../../scripts/storybook/runner",
"type-check": "tsc -b tsconfig.json"
},
"devDependencies": {
"@fluentui/babel-make-styles": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"@fluentui/babel-make-styles": "0.0.0-nightlyf6116328d620220124.1",
"@fluentui/eslint-plugin": "*",
"@fluentui/jest-serializer-make-styles": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"@fluentui/jest-serializer-make-styles": "0.0.0-nightlyf6116328d620220124.1",
"@fluentui/react-conformance": "*",
"@fluentui/react-conformance-make-styles": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"@fluentui/react-conformance-make-styles": "0.0.0-nightlyf6116328d620220124.1",
"@fluentui/scripts": "^1.0.0",

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

"dependencies": {
"@fluentui/react-make-styles": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"@fluentui/react-utilities": "0.0.0-nightlyf3ce1fbe1d20211110.1",
"@fluentui/react-make-styles": "0.0.0-nightlyf6116328d620220124.1",
"@fluentui/react-utilities": "0.0.0-nightlyf6116328d620220124.1",
"tslib": "^2.1.0"

@@ -59,3 +60,2 @@ },

"beachball": {
"tag": "beta",
"disallowedChangeTypes": [

@@ -62,0 +62,0 @@ "major",

@@ -78,51 +78,44 @@ # @fluentui/react-label Spec

```ts
/**
* Label Props
*/
export type LabelProps = ComponentProps &
React.LabelHTMLAttributes<HTMLElement> & {
/**
* Renders the label as disabled
* @defaultvalue false
*/
disabled?: boolean;
export type LabelCommons = {
/**
* Renders the label as disabled
* @defaultvalue false
*/
disabled: boolean;
/**
* Whether the associated form field is required or not. If true it will be an asterisk, otherwise it will be what is provided.
* @defaultvalue false
*/
required?: boolean | ShorthandProps<ComponentProps>;
/**
* A label supports different sizes.
* @defaultvalue 'medium'
*/
size: 'small' | 'medium' | 'large';
/**
* A label supports different font sizes, see tokens for reference.
* @defaultvalue 'medium'
*/
size?: 'small' | 'medium' | 'large';
/**
* A label supports semibold/strong fontweight.
* @defaultvalue false
*/
strong: boolean;
};
/**
* A label supports semibold/strong fontweight. When size is set to large, label strong will be set by default.
* @defaultvalue false
*/
strong?: boolean;
};
export type LabelSlots = {
root: IntrinsicShorthandProps<'label'>;
required?: IntrinsicShorthandProps<'span'>;
};
/**
* Names of the shorthand properties in LabelProps
* State used in rendering Label
*/
export type LabelShorthandProps = 'required';
export type LabelState = ComponentState<LabelSlots> & LabelCommons;
/**
* Names of LabelProps that have a default value in useLabel
* Label Props
*/
export type LabelDefaultedProps = never;
/**
* State used in rendering Label
*/
export type LabelState = ComponentState<LabelProps, LabelShorthandProps, LabelDefaultedProps> & {
/**
* Ref to the root element
*/
ref: React.Ref<HTMLElement>;
};
export type LabelProps = Omit<ComponentProps<LabelSlots>, 'required'> &
Partial<LabelCommons> & {
/**
* Displays and indicator that the label is for a required field. The required prop can be set to true to display
* an asterisk (*). Or it can be set to a string or jsx content to display a different indicator.
* @defaultvalue false
*/
required?: boolean | ObjectShorthandProps<React.HTMLAttributes<HTMLElement>> | React.ReactNode;
};
```

@@ -129,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

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