Skip to content

Conversation

@miroslavstastny
Copy link
Member

Current Behavior

  1. colorPalette*Background1 was white in High Contrast
  2. colorPalette*Foreground1 was black in High Contrast
  3. colorPalette* colors used hardcoded white and black instead of hcCanvas and hcCanvasText in High Contrast
  4. colorPalette*Foreground1 used Shade 10 for all Status shared colors in Light Theme

New Behavior

  1. colorPalette*Background1 is hcCanvas (resolves to black in default windows HC theme) in High Contrast
  2. colorPalette*Foreground1 is hcCanvasText (resolves to white in default windows HC theme) in High Contrast
  3. colorPalette* colors now use hcCanvas, hcCanvasTest or hcHighlight instead of white and black for all status and persona Color Palette colors
  4. colorPaletteYellowForeground1 uses Shade 30 in Light Theme, all other Status shared colors remained unchanged, using Shade 10

Related Issue(s)

Fixes #24256

@codesandbox-ci
Copy link

codesandbox-ci bot commented Aug 24, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 8abfe37:

Sandbox Source
@fluentui/react 8 starter Configuration
@fluentui/react-components 9 starter Configuration

@fabricteam
Copy link
Collaborator

fabricteam commented Aug 24, 2022

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-components
react-components: FluentProvider & webLightTheme
33.19 kB
10.921 kB
33.259 kB
10.952 kB
69 B
31 B
react-theme
Teams: all themes
29.479 kB
6.396 kB
29.548 kB
6.435 kB
69 B
39 B
react-theme
Teams: Light theme
17.385 kB
5.024 kB
17.452 kB
5.054 kB
67 B
30 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-accordion
Accordion (including children components)
79.349 kB
24.053 kB
react-alert
Alert
83.79 kB
20.841 kB
react-avatar
Avatar
48.283 kB
13.644 kB
react-avatar
AvatarGroup
14.85 kB
5.942 kB
react-avatar
AvatarGroupItem
68.251 kB
18.987 kB
react-badge
Badge
22.503 kB
7.153 kB
react-badge
CounterBadge
23.406 kB
7.449 kB
react-badge
PresenceBadge
23.947 kB
7.022 kB
react-button
Button
36.396 kB
9.579 kB
react-button
CompoundButton
43.469 kB
10.812 kB
react-button
MenuButton
39.014 kB
10.456 kB
react-button
SplitButton
46.544 kB
11.84 kB
react-button
ToggleButton
51.91 kB
11.003 kB
react-card
Card - All
67.458 kB
19.264 kB
react-card
Card
63.14 kB
18.176 kB
react-card
CardFooter
8.461 kB
3.555 kB
react-card
CardHeader
9.504 kB
3.896 kB
react-card
CardPreview
8.562 kB
3.61 kB
react-combobox
Combobox (including child components)
72.549 kB
23.686 kB
react-combobox
Dropdown (including child components)
71.741 kB
23.559 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
188.818 kB
51.901 kB
react-dialog
Dialog (including children components)
85.361 kB
25.458 kB
react-divider
Divider
16.359 kB
5.853 kB
react-image
Image
10.68 kB
4.215 kB
react-input
Input
23.498 kB
7.617 kB
react-label
Label
9.238 kB
3.815 kB
react-link
Link
12.231 kB
4.925 kB
react-menu
Menu (including children components)
115.697 kB
35.316 kB
react-menu
Menu (including selectable components)
118.896 kB
35.806 kB
react-overflow
hooks only
10.685 kB
4.104 kB
react-popover
Popover
102.837 kB
31.496 kB
react-portal
Portal
10.576 kB
3.875 kB
react-positioning
usePositioning
19.7 kB
7.404 kB
react-provider
FluentProvider
15.655 kB
5.835 kB
react-radio
Radio
36.025 kB
11.914 kB
react-radio
RadioGroup
14.148 kB
5.654 kB
react-select
Select
20.746 kB
7.299 kB
react-slider
Slider
32.07 kB
10.033 kB
react-spinbutton
SpinButton
43.843 kB
12.336 kB
react-spinner
Spinner
19.855 kB
6.384 kB
react-switch
Switch
32.562 kB
10.253 kB
react-text
Text - Default
11.682 kB
4.561 kB
react-text
Text - Wrappers
14.992 kB
4.995 kB
react-textarea
Textarea
23.674 kB
7.83 kB
react-theme
Single theme token import
69 B
89 B
react-tooltip
Tooltip
41.504 kB
14.622 kB
🤖 This report was generated against 9e7682f713135742648c4a6144bce5135048d990

@size-auditor
Copy link

size-auditor bot commented Aug 24, 2022

Asset size changes

Size Auditor did not detect a change in bundle size for any component!

Baseline commit: 9e7682f713135742648c4a6144bce5135048d990 (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Aug 24, 2022

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 1302 1317 5000
Button mount 955 954 5000
FluentProvider mount 1601 1572 5000
FluentProviderWithTheme mount 640 633 10
FluentProviderWithTheme virtual-rerender 595 600 10
FluentProviderWithTheme virtual-rerender-with-unmount 628 633 10
MakeStyles mount 1917 1900 50000
SpinButton mount 2478 2549 5000

@layershifter
Copy link
Member

image

Screener regressions for Spinner don't look great...

@miroslavstastny miroslavstastny requested review from a team and tomi-msft as code owners August 24, 2022 17:15
@miroslavstastny
Copy link
Member Author

Screener regressions for Spinner don't look great...

This was actually a problem with the stories, not the component itself.

@miroslavstastny
Copy link
Member Author

Another changed screenshot is Badge:

BEFORE

image

AFTER

image

The change fixes warning but brand and important remain "inverted" which does not match the spec in #24256.
@daisygeng is this ok?

@miroslavstastny miroslavstastny merged commit 018509c into microsoft:master Aug 30, 2022
@miroslavstastny miroslavstastny deleted the fix/react-theme-color-palette-hc branch August 30, 2022 08:33
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Sep 1, 2022
* master: (99 commits)
  applying package updates
  add coastal to @fluentui/react package and components (microsoft#24599)
  fix(react-18-tests-v9): extend correct tsconfig.json (microsoft#24626)
  feat(react-18-tests-v9): Add cypress setup to enable writing cypress tests (microsoft#24619)
  chore: Removing CompoundButtonAsToggleButton story since it was importing non-exported functions (microsoft#24620)
  Update PeoplePicker focus styles for the close button - Add borderRadius to getFocusStyle (microsoft#24596)
  fix(react-theme): Rename colorNeutralForegroundInvertedStatic token to colorNeutralForegroundStaticInverted (microsoft#24611)
  Website fabric core (microsoft#24613)
  fix(react-theme) update react theme colors mapping (microsoft#24608)
  Remove downloaded artifact file after using it (microsoft#24606)
  Fix artifact downloading race condition (microsoft#24607)
  chore(deps): bump moment-timezone from 0.5.34 to 0.5.37 (microsoft#24604)
  Remove check for commit existence and make it optional (microsoft#24587)
  Update "screener-build.yml" to include lage's output (microsoft#24586)
  fix(react-theme): Change colorBrandForeground2 mapping in teamsDark theme (microsoft#24579)
  Add scoping for workflow (microsoft#24466)
  fix(react-theme): Swap Background1 and Foreground1 in HC color palette (microsoft#24498)
  applying package updates
  Add support for javascript date localization (microsoft#24577)
  fix: Combobox and Dropdown hover/active borders and padding style fixes (microsoft#24362)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Shared color, high contrast slot assignment update

7 participants