Skip to content

Conversation

@emmadesilva
Copy link
Member

@emmadesilva emmadesilva commented Nov 6, 2023

Previously, documentation pages supported the following for setting navigation priorities in the config:

'foo', // Gets priority 500
'bar', // Gets priority 501
'baz', // Gets priority 502

And the main navigation menu supported the following syntax:

'foo' => 10,
'bar' => 50,
'baz' => 75,

This PR makes it so both menu types support both config syntaxes, and even a combination of both:

'foo',        // Gets priority 500
'bar' => 100, // Gets priority 100
'baz',        // Gets priority 501

@codecov
Copy link

codecov bot commented Nov 6, 2023

Codecov Report

Merging #1431 (ad97ba7) into master (96b1232) will not change coverage.
The diff coverage is 100.00%.

@@              Coverage Diff              @@
##              master     #1431     +/-   ##
=============================================
  Coverage     100.00%   100.00%             
- Complexity      1707      3420   +1713     
=============================================
  Files            180       360    +180     
  Lines           4633      9280   +4647     
=============================================
+ Hits            4633      9280   +4647     
Files Coverage Δ
.../src/Framework/Factories/NavigationDataFactory.php 100.00% <100.00%> (ø)

... and 180 files with indirect coverage changes

@emmadesilva emmadesilva changed the title Improve navigation priority discovery to allow both sidebars and main navigation to support both list and keyed config syntax Improve navigation priority discovery to allow sidebars and main navigation to support both list and keyed config syntax Nov 6, 2023
@emmadesilva emmadesilva merged commit ed14ee3 into master Nov 6, 2023
@emmadesilva emmadesilva deleted the navigation-discovery-improvements branch November 8, 2023 16:18
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.

2 participants