Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "patch",
"comment": "feat: Add *Field components to @fluentui/react-components/unstable",
"packageName": "@fluentui/react-components",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "prerelease",
"comment": "Initial release",
"packageName": "@fluentui/react-field",
"email": "[email protected]",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,15 @@ import { CardPreviewState } from '@fluentui/react-card';
import { CardProps } from '@fluentui/react-card';
import { CardSlots } from '@fluentui/react-card';
import { CardState } from '@fluentui/react-card';
import { CheckboxField } from '@fluentui/react-field';
import { checkboxFieldClassNames } from '@fluentui/react-field';
import { CheckboxFieldProps } from '@fluentui/react-field';
import { Combobox } from '@fluentui/react-combobox';
import { comboboxClassNames } from '@fluentui/react-combobox';
import { ComboboxContextValues } from '@fluentui/react-combobox';
import { ComboboxField } from '@fluentui/react-field';
import { comboboxFieldClassNames } from '@fluentui/react-field';
import { ComboboxFieldProps } from '@fluentui/react-field';
import { ComboboxOpenChangeData } from '@fluentui/react-combobox';
import { ComboboxOpenEvents } from '@fluentui/react-combobox';
import { ComboboxProps } from '@fluentui/react-combobox';
Expand Down Expand Up @@ -92,6 +98,14 @@ import { DropdownOpenEvents } from '@fluentui/react-combobox';
import { DropdownProps } from '@fluentui/react-combobox';
import { DropdownSlots } from '@fluentui/react-combobox';
import { DropdownState } from '@fluentui/react-combobox';
import { FieldConfig } from '@fluentui/react-field';
import { FieldProps } from '@fluentui/react-field';
import { FieldSlots } from '@fluentui/react-field';
import { FieldState } from '@fluentui/react-field';
import { getFieldClassNames } from '@fluentui/react-field';
import { InputField } from '@fluentui/react-field';
import { inputFieldClassNames } from '@fluentui/react-field';
import { InputFieldProps } from '@fluentui/react-field';
import { Listbox } from '@fluentui/react-combobox';
import { listboxClassNames } from '@fluentui/react-combobox';
import { ListboxContextValues } from '@fluentui/react-combobox';
Expand All @@ -112,6 +126,9 @@ import { Overflow } from '@fluentui/react-overflow';
import { OverflowItem } from '@fluentui/react-overflow';
import { OverflowItemProps } from '@fluentui/react-overflow';
import { OverflowProps } from '@fluentui/react-overflow';
import { RadioGroupField } from '@fluentui/react-field';
import { radioGroupFieldClassNames } from '@fluentui/react-field';
import { RadioGroupFieldProps } from '@fluentui/react-field';
import { renderAlert_unstable } from '@fluentui/react-alert';
import { renderAvatarGroup_unstable } from '@fluentui/react-avatar';
import { renderAvatarGroupItem_unstable } from '@fluentui/react-avatar';
Expand All @@ -127,6 +144,7 @@ import { renderDialogSurface_unstable } from '@fluentui/react-dialog';
import { renderDialogTitle_unstable } from '@fluentui/react-dialog';
import { renderDialogTrigger_unstable } from '@fluentui/react-dialog';
import { renderDropdown_unstable } from '@fluentui/react-combobox';
import { renderField_unstable } from '@fluentui/react-field';
import { renderListbox_unstable } from '@fluentui/react-combobox';
import { renderOption_unstable } from '@fluentui/react-combobox';
import { renderOptionGroup_unstable } from '@fluentui/react-combobox';
Expand All @@ -143,10 +161,22 @@ import { renderTableSelectionCell_unstable } from '@fluentui/react-table';
import { renderToolbar_unstable } from '@fluentui/react-toolbar';
import { Select } from '@fluentui/react-select';
import { selectClassNames } from '@fluentui/react-select';
import { SelectField } from '@fluentui/react-field';
import { selectFieldClassNames } from '@fluentui/react-field';
import { SelectFieldProps } from '@fluentui/react-field';
import { SelectProps } from '@fluentui/react-select';
import { SelectSlots } from '@fluentui/react-select';
import { SelectState } from '@fluentui/react-select';
import { SliderField } from '@fluentui/react-field';
import { sliderFieldClassNames } from '@fluentui/react-field';
import { SliderFieldProps } from '@fluentui/react-field';
import { SortDirection } from '@fluentui/react-table';
import { SpinButtonField } from '@fluentui/react-field';
import { spinButtonFieldClassNames } from '@fluentui/react-field';
import { SpinButtonFieldProps } from '@fluentui/react-field';
import { SwitchField } from '@fluentui/react-field';
import { switchFieldClassNames } from '@fluentui/react-field';
import { SwitchFieldProps } from '@fluentui/react-field';
import { Table } from '@fluentui/react-table';
import { TableBody } from '@fluentui/react-table';
import { tableBodyClassName } from '@fluentui/react-table';
Expand Down Expand Up @@ -199,6 +229,9 @@ import { TableSelectionCellSlots } from '@fluentui/react-table';
import { TableSelectionCellState } from '@fluentui/react-table';
import { TableSlots } from '@fluentui/react-table';
import { TableState } from '@fluentui/react-table';
import { TextareaField } from '@fluentui/react-field';
import { textareaFieldClassNames } from '@fluentui/react-field';
import { TextareaFieldProps } from '@fluentui/react-field';
import { Toolbar } from '@fluentui/react-toolbar';
import { ToolbarButton } from '@fluentui/react-toolbar';
import { ToolbarButtonProps } from '@fluentui/react-toolbar';
Expand Down Expand Up @@ -243,6 +276,8 @@ import { useDialogTitleStyles_unstable } from '@fluentui/react-dialog';
import { useDialogTrigger_unstable } from '@fluentui/react-dialog';
import { useDropdown_unstable } from '@fluentui/react-combobox';
import { useDropdownStyles_unstable } from '@fluentui/react-combobox';
import { useField_unstable } from '@fluentui/react-field';
import { useFieldStyles_unstable } from '@fluentui/react-field';
import { useIsOverflowGroupVisible } from '@fluentui/react-overflow';
import { useIsOverflowItemVisible } from '@fluentui/react-overflow';
import { useListbox_unstable } from '@fluentui/react-combobox';
Expand Down Expand Up @@ -351,12 +386,24 @@ export { CardSlots }

export { CardState }

export { CheckboxField }

export { checkboxFieldClassNames }

export { CheckboxFieldProps }

export { Combobox }

export { comboboxClassNames }

export { ComboboxContextValues }

export { ComboboxField }

export { comboboxFieldClassNames }

export { ComboboxFieldProps }

export { ComboboxOpenChangeData }

export { ComboboxOpenEvents }
Expand Down Expand Up @@ -453,6 +500,22 @@ export { DropdownSlots }

export { DropdownState }

export { FieldConfig }

export { FieldProps }

export { FieldSlots }

export { FieldState }

export { getFieldClassNames }

export { InputField }

export { inputFieldClassNames }

export { InputFieldProps }

export { Listbox }

export { listboxClassNames }
Expand Down Expand Up @@ -493,6 +556,12 @@ export { OverflowItemProps }

export { OverflowProps }

export { RadioGroupField }

export { radioGroupFieldClassNames }

export { RadioGroupFieldProps }

export { renderAlert_unstable }

export { renderAvatarGroup_unstable }
Expand Down Expand Up @@ -523,6 +592,8 @@ export { renderDialogTrigger_unstable }

export { renderDropdown_unstable }

export { renderField_unstable }

export { renderListbox_unstable }

export { renderOption_unstable }
Expand Down Expand Up @@ -555,14 +626,38 @@ export { Select }

export { selectClassNames }

export { SelectField }

export { selectFieldClassNames }

export { SelectFieldProps }

export { SelectProps }

export { SelectSlots }

export { SelectState }

export { SliderField }

export { sliderFieldClassNames }

export { SliderFieldProps }

export { SortDirection }

export { SpinButtonField }

export { spinButtonFieldClassNames }

export { SpinButtonFieldProps }

export { SwitchField }

export { switchFieldClassNames }

export { SwitchFieldProps }

export { Table }

export { TableBody }
Expand Down Expand Up @@ -667,6 +762,12 @@ export { TableSlots }

export { TableState }

export { TextareaField }

export { textareaFieldClassNames }

export { TextareaFieldProps }

export { Toolbar }

export { ToolbarButton }
Expand Down Expand Up @@ -755,6 +856,10 @@ export { useDropdown_unstable }

export { useDropdownStyles_unstable }

export { useField_unstable }

export { useFieldStyles_unstable }

export { useIsOverflowGroupVisible }

export { useIsOverflowItemVisible }
Expand Down
1 change: 1 addition & 0 deletions packages/react-components/react-components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
"@fluentui/react-combobox": "^9.0.0-beta.8",
"@fluentui/react-dialog": "^9.0.0-beta.7",
"@fluentui/react-divider": "^9.0.4",
"@fluentui/react-field": "9.0.0-alpha.0",
"@fluentui/react-image": "^9.0.4",
"@fluentui/react-input": "^9.0.4",
"@fluentui/react-label": "^9.0.4",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -304,3 +304,43 @@ export type {
TablePrimaryCellSlots,
TablePrimaryCellState,
} from '@fluentui/react-table';

export {
CheckboxField,
checkboxFieldClassNames,
ComboboxField,
comboboxFieldClassNames,
getFieldClassNames,
InputField,
inputFieldClassNames,
RadioGroupField,
radioGroupFieldClassNames,
renderField_unstable,
SelectField,
selectFieldClassNames,
SliderField,
sliderFieldClassNames,
SpinButtonField,
spinButtonFieldClassNames,
SwitchField,
switchFieldClassNames,
TextareaField,
textareaFieldClassNames,
useFieldStyles_unstable,
useField_unstable,
} from '@fluentui/react-field';
export type {
CheckboxFieldProps,
ComboboxFieldProps,
FieldConfig,
FieldProps,
FieldSlots,
FieldState,
InputFieldProps,
RadioGroupFieldProps,
SelectFieldProps,
SliderFieldProps,
SpinButtonFieldProps,
SwitchFieldProps,
TextareaFieldProps,
} from '@fluentui/react-field';
6 changes: 3 additions & 3 deletions packages/react-components/react-field/package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"name": "@fluentui/react-field",
"version": "9.0.0-alpha.0",
"private": true,
"description": "Fluent UI Field component",
"description": "Fluent UI Field components",
"main": "lib-commonjs/index.js",
"module": "lib/index.js",
"typings": "dist/index.d.ts",
Expand Down Expand Up @@ -58,7 +57,8 @@
"beachball": {
"disallowedChangeTypes": [
"major",
"prerelease"
"minor",
"patch"
]
}
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
CheckboxField adds a validation message and hint text to the Checkbox control.

Unlike other Field controls, the `label` appears to the right of the checkbox, as it does for the `Checkbox` control. If a standard field label is required, use the `fieldLabel` prop.

<!-- Don't allow prettier to collapse code block into single line -->
<!-- prettier-ignore -->
> **⚠️ Preview components are considered unstable:**
>
> ```jsx
>
> import { CheckboxField } from '@fluentui/react-components/unstable';
>
> ```
>
> - Features and APIs may change before final release
> - Please contact us if you intend to use this in your product
Original file line number Diff line number Diff line change
@@ -1 +1,14 @@
ComboboxField adds a Label, validation message, and hint text to the Combobox control.

<!-- Don't allow prettier to collapse code block into single line -->
<!-- prettier-ignore -->
> **⚠️ Preview components are considered unstable:**
>
> ```jsx
>
> import { ComboboxField } from '@fluentui/react-components/unstable';
>
> ```
>
> - Features and APIs may change before final release
> - Please contact us if you intend to use this in your product

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
Fields are a combination of the underlying control with a Label, validation message, and hint text.

> **⚠️ Preview components are considered unstable:**
>
> - Features and APIs may change before final release
> - Please contact us if you intend to use this in your product
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import descriptionMd from './FieldDescription.md';
import bestPracticesMd from './FieldBestPractices.md';
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#24735 tracks adding this back once the best practices have been written.


export { Default } from './FieldDefault.stories';
export { Label } from './FieldLabel.stories';
Expand All @@ -15,7 +14,7 @@ export default {
parameters: {
docs: {
description: {
component: [descriptionMd, bestPracticesMd].join('\n'),
component: descriptionMd,
},
},
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1,14 @@
InputField adds a Label, validation message, and hint text to the Input control.

<!-- Don't allow prettier to collapse code block into single line -->
<!-- prettier-ignore -->
> **⚠️ Preview components are considered unstable:**
>
> ```jsx
>
> import { InputField } from '@fluentui/react-components/unstable';
>
> ```
>
> - Features and APIs may change before final release
> - Please contact us if you intend to use this in your product
Loading