Initial framework for NHSN App UI integration/component - #1699
Draft
seanmcilvenna wants to merge 23 commits into
Draft
Initial framework for NHSN App UI integration/component#1699seanmcilvenna wants to merge 23 commits into
seanmcilvenna wants to merge 23 commits into
Conversation
- UI and Server services/components - UI can be built as a standalone framework/service for lower-env testing - UI can also be built as a webpack'd set of components resulting in a single .js file for delivery to NHSN App - BFF has basic RBAC tables, has support for JWT validation, and requires that authorization bearer be passed into (with the JWT) for the user. Has a userinfo endpoint that the UI uses to determine their role (according to the BFF).
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Comment on lines
+17
to
+19
| app.get('*', (_req, res) => { | ||
| res.sendFile(path.join(root, 'index.html')); | ||
| }); |
…duce notifications framework to UI.
…users and access request handling.
…rove modularity and reuse.
…onent and enhance related documentation.
…Link and UserInfoService, and update relevant documentation.
…nent HTML template
- Replace Roles and UserRoles with `IsAdmin` flag for simplified RBAC. - Add facility-related administrative functionalities. - Extend middleware, services, and endpoints to support facility onboarding management. - Implement frontend components for onboarding and facility administration. - Update database schema with migrations for groups-based RBAC and facility table addition.
… simulated header logic: - Added JWT signing with private key PEM in the UI shell for lower-env requests. - Updated BFF to validate and log JWTs, replacing simulated header support. - Removed SimulatedUserHeaderPayload model and related logic. - Extended UI TestUserProfile model for JWT signing fields. - Introduced `/shell-config.js` for UI JWT defaults in Docker. - Enhanced middleware and configuration for stricter auth handling.
… ui/spec exposure.
…tTestingMode` logic; implement token renewal and max token age validation.
…egration Framework
| var filePath = BuildFilePath(resourceDirectory, candidateLocale, namespaceName); | ||
| if (filePath is null || !File.Exists(filePath)) | ||
| { | ||
| _logger.LogDebug("Localization resource not found for locale/namespace. Locale={Locale}; Namespace={Namespace}", candidateLocale, namespaceName); |
| var filePath = BuildFilePath(resourceDirectory, candidateLocale, namespaceName); | ||
| if (filePath is null || !File.Exists(filePath)) | ||
| { | ||
| _logger.LogDebug("Localization resource not found for locale/namespace. Locale={Locale}; Namespace={Namespace}", candidateLocale, namespaceName); |
| var rootNode = JsonNode.Parse(json) as JsonObject; | ||
| if (rootNode is null) | ||
| { | ||
| _logger.LogWarning("Localization resource file does not contain a JSON object. File={File}", filePath); |
| } | ||
| catch (JsonException ex) | ||
| { | ||
| _logger.LogWarning(ex, "Localization resource JSON is malformed. File={File}", filePath); |
| } | ||
| catch (IOException ex) | ||
| { | ||
| _logger.LogError(ex, "Localization resource file could not be read. File={File}", filePath); |
|
|
||
| if (!resourceByLocale.ContainsKey(DefaultLocale)) | ||
| { | ||
| _logger.LogError("Default English localization was not found for namespace. Namespace={Namespace}", namespaceName); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🛠️ Description of Changes
🧪 Testing Performed
Launched using
docker composeand the UI fundamentally works, with the BFF🧑🔬 Unit Testing
📓 Documentation Updated
READMEs created in each project folder