Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed Overflow component when there's more then one children element #27402

Conversation

ValentinaKozlova
Copy link
Contributor

When there's more than one child component for the Overflow element then overflow items are still displayed.
Example:

<Overflow>
  <div>
    <div className={mergeClasses(styles.container, styles.resizableArea)}>
      {itemIds.map((i) => (
        <OverflowItem key={i} id={i}>
          <Button>Item {i}</Button>
        </OverflowItem>
      ))}

      <OverflowMenu itemIds={itemIds} />
    </div>
  </div>
</Overflow>

Previous Behavior

image

New Behavior

image

Related Issue(s)

  • Fixes #

@ValentinaKozlova ValentinaKozlova self-assigned this Mar 31, 2023
@ValentinaKozlova ValentinaKozlova force-pushed the fix/overflow-all-children-elements branch from 19d993b to f3504f3 Compare March 31, 2023 15:27
@ValentinaKozlova ValentinaKozlova marked this pull request as ready for review March 31, 2023 15:27
@ValentinaKozlova ValentinaKozlova requested a review from a team as a code owner March 31, 2023 15:27
@codesandbox-ci
Copy link

codesandbox-ci bot commented Mar 31, 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 fbaa26b:

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

@size-auditor
Copy link

size-auditor bot commented Mar 31, 2023

Asset size changes

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

Baseline commit: 2bea5b29844ac124b923a40e20e135e5b25668c6 (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 31, 2023

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-components
react-components: Button, FluentProvider & webLightTheme
67.994 kB
18.395 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
207.4 kB
57.516 kB
react-components
react-components: FluentProvider & webLightTheme
38.819 kB
12.351 kB
react-overflow
hooks only
11.214 kB
4.271 kB
react-portal-compat
PortalCompatProvider
6.446 kB
2.185 kB
🤖 This report was generated against 2bea5b29844ac124b923a40e20e135e5b25668c6

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 31, 2023

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 921 911 5000
Button mount 576 568 5000
Field mount 1614 1639 5000
FluentProvider mount 1179 1160 5000
FluentProviderWithTheme mount 297 303 10
FluentProviderWithTheme virtual-rerender 281 283 10
FluentProviderWithTheme virtual-rerender-with-unmount 279 288 10
InfoButton mount 201 206 5000
MakeStyles mount 1293 1301 50000
Persona mount 2286 2204 5000
SpinButton mount 2004 1996 5000

@ValentinaKozlova ValentinaKozlova merged commit 3412485 into microsoft:master Apr 3, 2023
@ValentinaKozlova ValentinaKozlova deleted the fix/overflow-all-children-elements branch April 3, 2023 10:28
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Apr 4, 2023
* master: (39 commits)
  Added merge tests for custom styles (microsoft#27086)
  fix: make Option's checkIcon slot render conditionally (microsoft#27409)
  docs: add subcomponents to Combobox and Dropdown docs (microsoft#27410)
  Breadcrumb spec (microsoft#26742)
  bugfix(react-utilities): increments SlotRenderFunction signature to include children (microsoft#27377)
  fix: Menu should not steal focus on close (microsoft#27414)
  Fixed Overflow component when there's more then one children element (microsoft#27402)
  feat(scripts-executors): support custom base and printing all affected packages for checkIfPackagesAffected (microsoft#27364)
  applying package updates
  feat(scripts-tasks): make perf test setup generic (microsoft#26920)
  fix: ColorPicker preview color updated to ignore forced colors (microsoft#27394)
  fix: Fix babel build error on windows (microsoft#27406)
  chore(react-datepicker-compat): Add vr-tests and bundle-size fixtures for DatePicker (microsoft#27351)
  fix(react-dialog): DialogContent scrollbar always visible (microsoft#27367)
  docs: Add tokens search (microsoft#27265)
  chore(scripts-tasks): remove not needed api-extractor task logs (microsoft#27094)
  chore(react-tree): adds e2e flat tree tests (microsoft#27318)
  applying package updates
  Accessibility fix for empty vertical bar chart (microsoft#26254)
  fix(react-datepicker-compat): Fix theming issues with all themes and WHCM (microsoft#27361)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants