Skip to content

Conversation

@sopranopillow
Copy link
Contributor

Previous Behavior

Avatar renders an image even if src is undefined <Avatar image={{ src: undefined }} />
image

New Behavior

Avatar no longer renders undefined image:
image

@size-auditor
Copy link

size-auditor bot commented Jun 5, 2023

Asset size changes

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

Baseline commit: 0eae1bc208e0d69febb4bc1e70ab1e2c7c96b623 (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 5, 2023

Perf Analysis (@fluentui/react-components)

Scenario Render type Master Ticks PR Ticks Iterations Status
FluentProviderWithTheme mount 87 90 10 Possible regression
All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 529 573 5000
Button mount 277 298 5000
Field mount 982 1024 5000
FluentProvider mount 639 636 5000
FluentProviderWithTheme mount 87 90 10 Possible regression
FluentProviderWithTheme virtual-rerender 80 89 10
FluentProviderWithTheme virtual-rerender-with-unmount 80 75 10
InfoButton mount 14 14 5000
MakeStyles mount 852 858 50000
Persona mount 1640 1604 5000
SpinButton mount 1273 1254 5000

@codesandbox-ci
Copy link

codesandbox-ci bot commented Jun 5, 2023

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 846ff6d:

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

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 5, 2023

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-alert
Alert
93.585 kB
22.546 kB
93.624 kB
22.563 kB
39 B
17 B
react-avatar
Avatar
57.833 kB
15.1 kB
57.872 kB
15.115 kB
39 B
15 B
react-avatar
AvatarGroupItem
74.009 kB
19.59 kB
74.048 kB
19.605 kB
39 B
15 B
react-persona
Persona
64.754 kB
17.021 kB
64.793 kB
17.036 kB
39 B
15 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-avatar
AvatarGroup
15.682 kB
6.306 kB
react-components
react-components: Button, FluentProvider & webLightTheme
64.935 kB
17.918 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
211.151 kB
58.715 kB
react-components
react-components: FluentProvider & webLightTheme
36.168 kB
11.964 kB
react-portal-compat
PortalCompatProvider
6.473 kB
2.196 kB
react-table
DataGrid
150.941 kB
41.535 kB
react-table
Table (Primitives only)
45.147 kB
12.577 kB
react-table
Table as DataGrid
133.392 kB
34.008 kB
react-table
Table (Selection only)
79.161 kB
19.386 kB
react-table
Table (Sort only)
78.491 kB
19.195 kB
react-tags
Tag
22.04 kB
7.94 kB
🤖 This report was generated against 0eae1bc208e0d69febb4bc1e70ab1e2c7c96b623

@fabricteam
Copy link
Collaborator

fabricteam commented Jun 5, 2023

🕵 fluentuiv9 No visual regressions between this PR and main

@sopranopillow sopranopillow merged commit 7eca299 into microsoft:master Jun 6, 2023
@sopranopillow sopranopillow deleted the avatar-image-fix branch June 6, 2023 17:12
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Jun 13, 2023
* master:
  applying package updates
  doc: Remove wrong recommendation from input (microsoft#28168)
  fix: Outline color now respects OS force colors settings (microsoft#28182)
  Datepicker onCalendarOpenStateChange prop (microsoft#28136)
  feat(react-file-type-icons): Add getFileTypeIconAsUrl utility (microsoft#27336)
  applying package updates
  [FIX] Updates selection dot and label positioning for ChoiceGroupOption when an Image or Icon is present. (microsoft#28173)
  chore(react-infobutton): Rename InfoTip to InfoIcon (microsoft#28177)
  fix(react-datepicker-compat): Make DatePicker Compat stories SSR safe (microsoft#28017)
  Added `tab` focus mode to the Breadcrumb (microsoft#28046)
  docs: Add usable documentation (microsoft#28155)
  applying package updates
  Fix up rebase code (microsoft#27864)
  fix: ContextualMenu indexing in sections (microsoft#28127)
  applying package updates
  fix: Layer sets focus visible classname for its FocusRectsProvider (microsoft#28157)
  docs(react-infobutton): Update stories to show better guidance (microsoft#28144)
  fix(react-avatar): Do not render the image when src prop is undefined (microsoft#28146)
  feat(react-datepicker-compat): Add null to value prop and handle controlled cases correctly (microsoft#28056)
@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

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.

4 participants