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

🧪 [Experiment] Ribbon #545

Open
5 of 19 tasks
vgromfeld opened this issue May 24, 2024 · 0 comments
Open
5 of 19 tasks

🧪 [Experiment] Ribbon #545

vgromfeld opened this issue May 24, 2024 · 0 comments
Labels
experiment 🧪 Used to track issues that are experiments (or their linked discussions)

Comments

@vgromfeld
Copy link
Contributor

vgromfeld commented May 24, 2024

Approved from Discussion

#544

Problem Statement

Office and applications like Paint are using a "large" ribbon to display all their available commands. Those ribbons display all the available commands in groups. Those groups can automatically be collapsed if there is not enough space available to display them all based on a priority order.

The toolkit already provides a "small" ribbon through the TabbedCommandBar (See #500 and CommunityToolkit/Windows#243) but does not have any way to display the "large" ribbon.

Overview

This experiment adds the following components:

  • Ribbon the ribbon control.
  • RibbonGroup an always displayed group container.
  • RibbonCollapsibleGroup a group container which can be collapsed based on a priority order if there is not enough space available to fully display the group.
  • RibbonPanel a custom panel for the Ribbon to automatically expand or collapse the RibbonCollapsibleGroups

Using

You can try it out via the NuGet Packages here:

Read more about Preview Packages here.

Code

<Ribbon>
   <RibbonGroup Label="Selection" />
    <RibbonCollapsibleGroup Label="Edit" Style="{StaticResource RibbonLeftCollapsibleGroupStyle}" Priority="1">
        <!-- group content -->
    </RibbonCollapsibleGroup>
    <RibbonCollapsibleGroup Label="Shapes" Style="{StaticResource RibbonLeftCollapsibleGroupStyle}" Priority="2">
        <!-- group content -->
    </RibbonCollapsibleGroup>
</Ribbon>

Result

image
image

Additional info

The control comes with a list of predefined styles from its RibbonStyle.xaml file. All the different parts of the Ribbon should support light templating.

The RibbonLeftGroupStyle/RibbonRightGroupStyle and RibbonLeftCollapsibleGroupStyle/ RibbonRightCollapsibleGroupStyle can be used to add a separator before or after the group.

Implementation Requirements

  • Working Prototype
  • Feature Complete
  • Documentation
  • Samples
  • Unit Tests
  • Community Feedback / Usage Testimonies

Tested Platforms

  • UWP
  • WinAppSDK / WinUI 3
  • Web Assembly (WASM)
  • Android
  • iOS
  • MacOS
  • Linux / GTK

Technical Review

  • Accessibility Audit
  • API/Naming Review
  • Code Quality/Style
  • Dependency Review
  • Design/Style Review
  • Final Approval

Community Help?

Yes

@vgromfeld vgromfeld added the experiment 🧪 Used to track issues that are experiments (or their linked discussions) label May 24, 2024
@vgromfeld vgromfeld mentioned this issue May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
experiment 🧪 Used to track issues that are experiments (or their linked discussions)
Projects
None yet
Development

No branches or pull requests

1 participant