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

feat: portal framework #781

Draft
wants to merge 25 commits into
base: main
Choose a base branch
from
Draft

feat: portal framework #781

wants to merge 25 commits into from

Conversation

Noggling
Copy link
Contributor

Description

  • PR title and description are to the point and understandable
  • I have performed a self-review of my own code'

Please select version type the purposed change:

  • major
  • minor
  • patch
  • none

External Relations

  • database migration

Changeset

Noggling and others added 13 commits September 2, 2024 08:55
The useAppLoader hook in the core package was updated to handle cases where the basename is missing from the window location pathname. Previously, if the basename was not found, an empty string was used. Now, if the basename is not found, the entire location pathname is used as a fallback.

This change ensures that the createAppElement function is called correctly and that the basename is generated accurately for application regex extraction.
The portal configuration types in the core package were updated to include two new properties: portalKey and origin. These properties are required for the type 'app-portal' and will be used to provide additional information about the portal. This change ensures that the portal configuration is accurately represented in the codebase.
The code changes in `ProjectPage.tsx` update the logic to handle cases where the `contextId` is missing or does not match the expected format. Instead of returning the string 'hello', the code now returns `null`. This change ensures that the `ProjectPage` component behaves correctly when the contextId is invalid or missing.
Copy link

changeset-bot bot commented Sep 24, 2024

🦋 Changeset detected

Latest commit: 7ef957b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 0 packages

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added frontend Frontend specific size-xl labels Sep 24, 2024
- In the `initialize` function of the `module.ts` file, added an optional `args.ref` parameter to the `createConfigAsync` function call.
- Modified the return statement to use the `args.ref?.portalConfig` if it exists, otherwise create a new `PortalConfigProvider` with the `config`.
- In the `provider.ts` file, updated the `routes$` getter to handle the case when `portal` is null or undefined.
- Added a new getter `config` to the `PortalConfigProvider` class to expose the configuration.

This commit refactors the `portal-config` module to handle an optional `ref` parameter and improves the handling of the `routes$` getter. It also adds a new getter to expose the configuration. These changes improve the flexibility and reliability of the `portal-config` module.
@Noggling Noggling linked an issue Sep 30, 2024 that may be closed by this pull request
Remove unused import and unnecessary code in portal-framework package

Remove unused import and unnecessary code in portal-framework-config.tsx

Add PortalSelector component for portal selection

Update FusionFramework component to import ModulesInstance from fusion-framework-module

Update PortalRouter component to include PortalSelector component

Update portal-framework-config.tsx to remove console.log statement

Update main.tsx to use localStorage for portalId if available

Add PortalSelector component for portal selection
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
frontend Frontend specific size-xl
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Portal Framework
1 participant