Skip to content

fix(tabs): persist active tab in manager URL - #36

Open
middleDuckAi wants to merge 1 commit into
evolution-cms:mainfrom
middleDuckAi:middleDuck/fix-module-tab-url-state
Open

middleDuckAi wants to merge 1 commit into
evolution-cms:mainfrom
middleDuckAi:middleDuck/fix-module-tab-url-state

Conversation

@middleDuckAi

Copy link
Copy Markdown
Contributor

Summary

  • add an opt-in urlParameter property to module-tab-shell
  • persist the selected tab in the embedded module URL and the Evolution Manager hash without reloading the page
  • expose the shared synchronizer as EvoUI.moduleTabs.syncUrl
  • document the component parameter and cover the URL-state contract in package tests

Why

Evolution Manager restores an embedded module from the URL stored in its parent hash. Previously, switching a module tab only changed Livewire state, so refreshing the manager could reopen the stale or default tab. Consumers can now pass url-parameter="tab" and keep both URL layers aligned with the active tab.

The behavior is opt-in, so existing module consumers are unchanged. Parent-window access is best effort and safely ignored for cross-origin embeds.

Verification

  • git diff --check origin/main...HEAD
  • module-tab state assertions pass, including the new URL synchronization contract
  • browser fixture confirmed that switching tabs updates both the iframe query and the parent manager hash and survives refresh
  • full composer test: 1,641 assertions; three existing origin/main static-contract failures remain unrelated to this PR (save-button feedback markers and one typography token)

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.

1 participant