Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

Commit 054a9d1

Browse files
committed
Merge branches 'feat/use-accessibility' and 'master' of https://github.com/stardust-ui/react into feat/use-accessibility
# Conflicts: # packages/react/src/components/Tooltip/Tooltip.tsx # packages/react/src/utils/createComponent.tsx # packages/react/src/utils/factories.ts
2 parents 54af40a + b4c2aaa commit 054a9d1

File tree

259 files changed

+5400
-1028
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

259 files changed

+5400
-1028
lines changed

.circleci/config.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,9 @@ jobs:
8989
if [ ! -z $CIRCLE_PULL_REQUEST ] && [ ! -z $DANGER_GITHUB_API_TOKEN ]; then
9090
yarn danger ci
9191
fi
92+
- store_artifacts:
93+
path: dist/artifacts
94+
destination: artifacts
9295
- run:
9396
name: Publish npm package (master only)
9497
command: |

.github/CONTRIBUTING.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
44
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
55

6+
67
- [Getting started](#getting-started)
78
- [Useful Commands](#useful-commands)
89
- [Workflow](#workflow)
@@ -25,7 +26,7 @@
2526

2627
Make sure you have [Node.js][1] version v8 or later installed.
2728

28-
You can contribute to Stardust by being an official [contributor](setup-local-development.md#contributors) or without permissions, as a [collaborator](setup-local-development.md#collaborators)
29+
You can contribute to Fluent UI by being an official [contributor](setup-local-development.md#contributors) or without permissions, as a [collaborator](setup-local-development.md#collaborators)
2930

3031
### Useful Commands
3132

@@ -64,7 +65,7 @@ These guides will walk your through various activities for contributing:
6465

6566
## Accessibility
6667

67-
Stardust implements accessibility using accessibility behaviors. The behaviors add attributes to the DOM elements (mainly role and aria-\* properties) as well as handle keyboard interaction and focus. Every accessible component has a default behavior, which can be overriden using the `accessibility` prop. You can choose a behavior from the ones provided by Stardust or you can implement a new behavior.
68+
Fluent UI implements accessibility using accessibility behaviors. The behaviors add attributes to the DOM elements (mainly role and aria-\* properties) as well as handle keyboard interaction and focus. Every accessible component has a default behavior, which can be overridden using the `accessibility` prop. You can choose a behavior from the ones provided by Fluent UI or you can implement a new behavior.
6869

6970
Behaviors apply properties, focus handling and keyboard handlers to the component slots. When developing a component, the properties and keyboard handlers need to be spread to the corresponding slots.
7071

@@ -94,9 +95,9 @@ An application should always have an element with [focus][7] when in use. The us
9495
- pressing arrow keys to navigate through children (for example menu items in menu)
9596
- using the screen reader with or without virtual cursor
9697

97-
Stardust uses Office UI Fabric [FocusZone][8] for basic TAB and arrow key focus handling. To use the focus zone, you can use the `focusZone` configuration in the behavior (for example see [MenuItemBehavior][9]).
98+
Fluent UI uses Office UI Fabric [FocusZone][8] for basic TAB and arrow key focus handling. To use the focus zone, you can use the `focusZone` configuration in the behavior (for example see [MenuItemBehavior][9]).
9899

99-
Focused component needs to be clearly visible. This is handled in Stardust by focus indicator functionality. Focus indicator will be displayed only if the application is in keyboard mode. Application switches to keyboard mode when a key relevant to navigation is pressed. It disables keyboard mode on mouse click events.
100+
Focused component needs to be clearly visible. This is handled in Fluent UI by focus indicator functionality. Focus indicator will be displayed only if the application is in keyboard mode. Application switches to keyboard mode when a key relevant to navigation is pressed. It disables keyboard mode on mouse click events.
100101

101102
To style the focused component, you can use the `isFromKeyboard` utility and prop. See [Button component][10] and [Button style][11] for reference.
102103

@@ -118,7 +119,7 @@ You should to run `lerna create` command to create a new package
118119
- the directory name should not contain any namespace prefix and can be prefixed with the library name if the
119120
implementation is not framework agnostic
120121
- please provide a meaningful description to a package in the matched field
121-
- use `https://github.com/stardust-ui/react/tree/master/packages/__DIRECTORY_NAME__` as `homepage`
122+
- use `https://github.com/microsoft/fluent-ui-react/tree/master/packages/__DIRECTORY_NAME__` as `homepage`
122123
- our packages are currently published with MIT license, please follow it until you will have specific legal requirements
123124

124125
```sh
@@ -133,10 +134,10 @@ package name: (@fluentui/react-proptypes)
133134
version: (0.21.1)
134135
description: Set of custom reusable PropTypes for React components.
135136
keywords:
136-
homepage: https://github.com/stardust-ui/react/tree/master/packages/react-proptypes
137+
homepage: https://github.com/microsoft/fluent-ui-react/tree/master/packages/react-proptypes
137138
license: (ISC) MIT
138139
entry point: (lib/react-proptypes.js)
139-
git repository: (https://github.com/stardust-ui/react.git)
140+
git repository: (https://github.com/microsoft/fluent-ui-react.git)
140141
```
141142

142143
#### Update `package.json`
@@ -223,11 +224,11 @@ lerna add @fluentui/react-proptypes packages/react
223224
[6]: https://www.w3.org/TR/wai-aria-1.1/#namecalculation
224225
[7]: https://www.w3.org/TR/wai-aria-1.1/#managingfocus
225226
[8]: https://developer.microsoft.com/en-us/fabric#/components/focuszone
226-
[9]: https://github.com/stardust-ui/react/blob/master/packages/react/src/utils/accessibility/Behaviors/Menu/MenuBehavior.ts
227-
[10]: https://github.com/stardust-ui/react/blob/master/src/components/Button/Button.tsx
228-
[11]: https://github.com/stardust-ui/react/blob/master/src/themes/teams/components/Button/buttonStyles.ts
229-
[12]: https://github.com/stardust-ui/react/blob/master/packages/react/src/utils/accessibility/Behaviors/Menu/MenuItemBehavior.ts
230-
[13]: https://github.com/stardust-ui/react/blob/master/src/components/Menu/MenuItem.tsx
227+
[9]: https://github.com/microsoft/fluent-ui-react/blob/master/packages/react/src/utils/accessibility/Behaviors/Menu/MenuBehavior.ts
228+
[10]: https://github.com/microsoft/fluent-ui-react/blob/master/src/components/Button/Button.tsx
229+
[11]: https://github.com/microsoft/fluent-ui-react/blob/master/src/themes/teams/components/Button/buttonStyles.ts
230+
[12]: https://github.com/microsoft/fluent-ui-react/blob/master/packages/react/src/utils/accessibility/Behaviors/Menu/MenuItemBehavior.ts
231+
[13]: https://github.com/microsoft/fluent-ui-react/blob/master/src/components/Menu/MenuItem.tsx
231232
[14]: https://lernajs.io/
232233
[15]: https://yarnpkg.com/en/docs/workspaces
233234
[16]: https://github.com/lerna/lerna/tree/master/commands/add

.github/ISSUE_TEMPLATE/Support_question.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@ We primarily use GitHub as an issue tracker; for usage and support questions, pl
99

1010
---
1111

12-
* Gitter Community Chat: https://gitter.im/stardust-ui/react
13-
* Also have a look at our docs: https://stardust-ui.github.io/react
12+
* Gitter Community Chat: https://gitter.im/microsoft/fluent-ui-react
13+
* Also have a look at our docs: https://microsoft.github.io/fluent-ui-react

.github/add-a-feature.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
<!-- START doctoc generated TOC please keep comment here to allow auto update -->
44
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
55

6+
67
- [Propose feature](#propose-feature)
78
- [Prototype](#prototype)
89
- [Spec out the API](#spec-out-the-api)
@@ -31,7 +32,7 @@ Build a minimal prototype showcasing the proposed feature. Do not worry about te
3132

3233
## Spec out the API
3334

34-
Review the documentation for the component. Spec out the component's proposed API. The spec should demonstrate how component's API you are proposing will be used by Stardust consumer. You can reference this [API proposal][2] for the Menu Icons.
35+
Review the documentation for the component. Spec out the component's proposed API. The spec should demonstrate how component's API you are proposing will be used by Fluent UI consumer. You can reference this [API proposal][2] for the Menu Icons.
3536

3637
Once the component spec is solidified, it's time to write some code. The following sections cover everything you'll need to spec and build your awesome component.
3738

@@ -190,11 +191,11 @@ After iterating on the feature with the maintainers, you will add full test cove
190191
- [Test a component](test-a-feature.md)
191192
- [Writing documentation](document-a-feature.md)
192193

193-
[1]: https://github.com/stardust-ui/react/issues
194-
[2]: https://github.com/stardust-ui/react/pull/73
195-
[3]: https://github.com/stardust-ui/react/blob/master/packages/react/src/utils/AutoControlledComponent.tsx
194+
[1]: https://github.com/microsoft/fluent-ui-react/issues
195+
[2]: https://github.com/microsoft/fluent-ui-react/pull/73
196+
[3]: https://github.com/microsoft/fluent-ui-react/blob/master/packages/react/src/utils/AutoControlledComponent.tsx
196197
[4]: https://facebook.github.io/react/docs/forms.html#controlled-components
197198
[5]: https://facebook.github.io/react/docs/forms.html#uncontrolled-components
198199
[6]: https://github.com/angular/angular/blob/master/CONTRIBUTING.md#commit
199-
[7]: https://stardust-ui.github.io/react/glossary
200+
[7]: https://microsoft.github.io/fluent-ui-react/glossary
200201
[8]: https://github.com/Semantic-Org/Semantic-UI-React/issues/607

.github/document-a-feature.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,4 +82,4 @@ Usage examples for a component live in `docs/src/examples`. The examples follow
8282
Adding documentation for new components is a bit tedious. The best way to do this (for now) is to copy an existing
8383
component's and update it.
8484

85-
[1]: https://stardust-ui.github.io/react/components/button
85+
[1]: https://microsoft.github.io/fluent-ui-react/components/button

.github/release-a-package.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# How to release a new library version
22

3-
This documentation is intended for core Stardust contributors and describes `@fluentui/react` NPM package release process.
3+
This documentation is intended for core Fluent UI contributors and describes `@fluentui/react` NPM package release process.
44

5-
## Prerequisities
5+
## Prerequisites
66

77
1. You need NPM account and npm configured with your token.
8-
2. You must be a member of stardust-ui organization on [npmjs.com](https://www.npmjs.com).
8+
2. You must be a member of `@fluentui` organization on [npmjs.com](https://www.npmjs.com).
99
3. You must have access rights to commit changes directly to `master` (be an admin).
1010

1111
## Define new version number
@@ -31,4 +31,4 @@ The release command in step 4 will handle tagging and releasing flow entirely. J
3131

3232
## Verification after release
3333
1. Verify NPM package has been released: https://www.npmjs.com/package/@fluentui/react
34-
2. Verify new docsite version has been published: https://stardust-ui.github.io/react/
34+
2. Verify new docsite version has been published: https://microsoft.github.io/fluent-ui-react/

.github/setup-local-development.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ node -v
2424
v8.11.3
2525
```
2626

27-
`yarn` is used for Stardust because of its [benefits][2].
27+
`yarn` is used for Fluent UI because of its [benefits][2].
2828

2929
```sh
3030
yarn -v
@@ -38,40 +38,40 @@ If you do not yet have access to the repo as a contributor, ask one of the maint
3838

3939
### Clone
4040

41-
Start by cloning Stardust UI React and installing dependencies:
41+
Start by cloning Fluent UI React and installing dependencies:
4242

4343
SSH ([learn more][3])
4444

4545
```sh
46-
git clone git@github.com:stardust-ui/react.git stardust-ui-react
46+
git clone git@github.com:microsoft/fluent-ui-react.git
4747
```
4848

4949
HTTPS
5050

5151
```sh
52-
git clone https://github.com/stardust-ui/react.git
52+
git clone https://github.com/microsoft/fluent-ui-react.git
5353
```
5454

5555
Continue to [Start](#start).
5656

5757
## Collaborators
5858

59-
If you are not part of the Stardust UI team, use these instructions. If you are, or should be, use the [Contributor](#contributors) instructions.
59+
If you are not part of the Fluent UI team, use these instructions. If you are, or should be, use the [Contributor](#contributors) instructions.
6060

6161
### Fork
6262

63-
Start by `forking Stardust UI React` to your GitHub account. Then clone your fork and install dependencies:
63+
Start by forking Fluent UI React to your GitHub account. Then clone your fork and install dependencies:
6464

6565
```sh
66-
git clone git@github.com:<your-user>/react.git stardust-ui-react
67-
cd stardust-ui-react
66+
git clone git@github.com:<your-user>/fluent-ui-react.git
67+
cd fluent-ui-react
6868
yarn
6969
```
7070

7171
Add our repo as a git remote so you can pull/rebase your fork with our latest updates:
7272

7373
```
74-
git remote add upstream git@github.com:stardust-ui/react.git
74+
git remote add upstream git@github.com:microsoft/fluent-ui-react.git
7575
```
7676

7777
Continue to [Start](#start).
@@ -81,7 +81,7 @@ Continue to [Start](#start).
8181
Now, enter the directory and install dependencies:
8282

8383
```
84-
cd stardust-ui-react
84+
cd fluent-ui-react
8585
yarn
8686
```
8787

.github/test-a-feature.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ yarn test
120120
yarn test:watch
121121
```
122122

123-
[1]: https://github.com/stardust-ui/react/tree/master/test/specs/commonTests
123+
[1]: https://github.com/microsoft/fluent-ui-react/tree/master/test/specs/commonTests
124124

125125
## Screener Tests
126126

CHANGELOG.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,32 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
1717

1818
## [Unreleased]
1919

20+
### BREAKING CHANGES
21+
- Use `tooltipAsLabelBehavior` as default `Tooltip` behavior @silviuavram ([#2195](https://github.com/microsoft/fluent-ui-react/pull/2195))
22+
23+
### Features
24+
- Add `tag` icon in Teams theme @codepretty ([#2180](https://github.com/microsoft/fluent-ui-react/pull/2180))
25+
- Add `inverted` prop and style for `Button` for Teams theme @notandrew ([#2076](https://github.com/microsoft/fluent-ui-react/pull/2076))
26+
- Add `vertical` prop to `Divider` @silviuavram ([#2141](https://github.com/microsoft/fluent-ui-react/pull/2141))
27+
28+
### Fixes
29+
- Fix `toggle` changing width during animation in Teams theme @mnajdova ([#2189](https://github.com/microsoft/fluent-ui-react/pull/2189))
30+
- Fix `Popup` positioning in multiple cases @layershifter ([#2187](https://github.com/microsoft/fluent-ui-react/pull/2187))
31+
- Fix click outside in `Popup` when `trigger` is not defined @layershifter ([#2202](https://github.com/microsoft/fluent-ui-react/pull/2202))
32+
33+
<!--------------------------------[ v0.42.0 ]------------------------------- -->
34+
## [v0.42.0](https://github.com/microsoft/fluent-ui-react/tree/v0.42.0) (2019-12-12)
35+
[Compare changes](https://github.com/microsoft/fluent-ui-react/compare/v0.41.01..v0.42.0)
36+
37+
### BREAKING CHANGES
38+
- Rename all "Stardust UI" references to "Fluent UI" @levithomason ([#2165](https://github.com/microsoft/fluent-ui-react/pull/2165))
39+
2040
### Fixes
2141
- Fix colors expand for `border-color` shorthand @layershifter ([#2160](https://github.com/microsoft/fluent-ui-react/pull/2160))
2242

43+
### Features
44+
- Adding `table` navigation @kolaps33 ([#2147](https://github.com/microsoft/fluent-ui-react/pull/2147))
45+
2346
<!--------------------------------[ v0.41.1 ]------------------------------- -->
2447
## [v0.41.1](https://github.com/microsoft/fluent-ui-react/tree/v0.41.1) (2019-12-10)
2548
[Compare changes](https://github.com/microsoft/fluent-ui-react/compare/v0.41.0...v0.41.1)

README.md

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<!-- Logo -->
22
<p align="center">
33
<a href="https://microsoft.github.io/fluent-ui-react">
4-
<img height="128" width="128" src="https://github.com/microsoft/fluent-ui-react/raw/master/docs/src/logo.png">
4+
<img height="128" width="112" src="https://github.com/microsoft/fluent-ui-react/raw/master/docs/src/public/images/fluent-ui-logo.png">
55
</a>
66
</p>
77

@@ -12,17 +12,17 @@
1212

1313
<!-- Badges -->
1414
<p align="center">
15-
<a href="https://gitter.im/stardust-ui/react">
15+
<a href="https://gitter.im/microsoft/fluent-ui-react">
1616
<img alt="Gitter" src="https://img.shields.io/badge/gitter-join_chat-1dce73.svg?logo=data%3Aimage%2Fsvg%2Bxml%3Bbase64%2CPD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4NCjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cmVjdCB4PSIwIiB5PSI1IiBmaWxsPSIjZmZmIiB3aWR0aD0iMSIgaGVpZ2h0PSI1Ii8%2BPHJlY3QgeD0iMiIgeT0iNiIgZmlsbD0iI2ZmZiIgd2lkdGg9IjEiIGhlaWdodD0iNyIvPjxyZWN0IHg9IjQiIHk9IjYiIGZpbGw9IiNmZmYiIHdpZHRoPSIxIiBoZWlnaHQ9IjciLz48cmVjdCB4PSI2IiB5PSI2IiBmaWxsPSIjZmZmIiB3aWR0aD0iMSIgaGVpZ2h0PSI0Ii8%2BPC9zdmc%2B&logoWidth=8&style=flat-square&maxAge=2592000" />
1717
</a>
18-
<a href="https://circleci.com/gh/stardust-ui/react/tree/master">
19-
<img alt="Circle" src="https://img.shields.io/circleci/project/github/stardust-ui/react/master.svg?style=flat-square" />
18+
<a href="https://circleci.com/gh/microsoft/fluent-ui-react/tree/master">
19+
<img alt="Circle" src="https://img.shields.io/circleci/project/github/microsoft/fluent-ui-react/master.svg?style=flat-square" />
2020
</a>
21-
<a href="https://codecov.io/gh/stardust-ui/react">
22-
<img alt="Codecov" src="https://img.shields.io/codecov/c/github/stardust-ui/react/master.svg?style=flat-square" />
21+
<a href="https://codecov.io/gh/microsoft/fluent-ui-react">
22+
<img alt="Codecov" src="https://img.shields.io/codecov/c/github/microsoft/fluent-ui-react/master.svg?style=flat-square" />
2323
</a>
24-
<a href="https://david-dm.org/stardust-ui/react">
25-
<img alt="David" src="https://img.shields.io/david/stardust-ui/react.svg?style=flat-square" />
24+
<a href="https://david-dm.org/microsoft/fluent-ui-react">
25+
<img alt="David" src="https://img.shields.io/david/microsoft/fluent-ui-react.svg?style=flat-square" />
2626
</a>
2727
<a href="https://www.npmjs.com/package/@fluentui/react">
2828
<img alt="npm" src="https://img.shields.io/npm/v/@fluentui/react.svg?style=flat-square" />
@@ -72,27 +72,23 @@ A shared library means more great ideas and more engineering support for feature
7272

7373
## Scope
7474

75-
You can think of Stardust as the internals of a good component library. This encompasses everything that one UI library may need, starting from the common UI component available on the web, custom theming, accessibility and rtl. Currently there is an React implementation of it, available here: [stardust-ui/react](https://github.com/stardust-ui/react).
75+
You can think of Fluent UI as the internals of a good component library. This encompasses everything that one UI library may need, starting from the common UI component available on the web, custom theming, accessibility and rtl. Currently there is an React implementation of it, available here: [microsoft/fluent-ui-react](https://github.com/microsoft/fluent-ui-react).
7676

7777
## Contributing Organizations
7878

79-
Currently, these teams are actively participating in Stardust's specifications and development:
79+
Currently, these teams are actively participating in Fluent UI's specifications and development:
8080

8181
- [Semantic UI React][200]
8282
- [Office UI Fabric][300]
8383
- [Teams (Microsoft)][301]
8484

8585
If you own or are building a UI component library, we'd love to have your input. [Post an issue][2] introducing yourself and your team and join us today.
8686

87-
You can actively contribute to Stardust by referring to the [Contributing][3] documentation.
87+
You can actively contribute to Fluent UI by referring to the [Contributing][3] documentation.
8888

8989
## Usage examples
9090

91-
You can find Stardust usage examples by accessing the [doc site][5]
92-
93-
## Semantic UI React v2
94-
95-
See the [MANIFESTO.md][1] for details. SUIR v2 will be built on the specifications and tools from Stardust.
91+
You can find Fluent UI usage examples by accessing the [doc site][5]
9692

9793
<!-- REPO -->
9894

0 commit comments

Comments
 (0)