feat(admin-ui): make Tutorials OP facets readable (concepts/community/images) - #2096
Merged
Conversation
…/images) Three Object-Page facets on the Tutorials admin UI showed raw keys or blanks. Per Tom's feedback: - Concepts Taught: concept_ID rendered a bare GUID. Annotate the `concept` association with @Common.Text: concept.name (#TextOnly) so the FK shows the human-readable concept name. - Community: membership facet showed a numeric communityId + opaque fingerprint. Expose KgCommunityLabelInfo (projection on the existing KgCommunityLabel) + a `labelInfo` select-list association joined on communityFingerprint, and annotate communityId with @Common.Text: labelInfo.label (#TextFirst). LineItem now shows Community (labelled) + member slug + type; fingerprint dropped. Label is blank until the Louvain labeling job (#1126) runs in an env — member slug is the always-present fallback. - Images: "Bytes" looked empty on legacy rows and there was no link to the stored/served image. Add virtual thumbUrl/viewUrl to the TutorialImages projection, filled in after('READ') from sourceUrl (thumbUrl → approuter /img-cdn resize/WebP preview; viewUrl → CAP /content/image-source raw original, self-heals from the object store). LineItem now leads with an inline thumbnail (@UI.IsImageURL) + a "Image (served)" link alongside the GitHub source and the mime/bytes/hash/channel store details. Guarded by test/unit/admin-facet-readability.test.js (CSN annotation guards + served URL-enrichment check incl. null-sourceUrl skip). EDMX verified: all three annotations land on concept_ID, communityId, thumbUrl. Admin-UI change — needs a FULL deploy (no --skip-build / -m scoping) to view.
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.
What & why
Three facets on the Tutorials Object Page in the admin UI showed raw keys or blanks. Tom's feedback:
Changes
conceptassociation with@Common.Text: concept.name(#TextOnly) so the FK renders the concept name instead of a GUID.KgCommunityLabelInfo(projection on the existingKgCommunityLabel) + alabelInfoselect-list association joined oncommunityFingerprint; annotatecommunityIdwith@Common.Text: labelInfo.label(#TextFirst). LineItem now shows Community (labelled) + member slug + type (fingerprint dropped). Label is blank until the Louvain labeling job ([Leverage KG communities in learner-facing surfaces and Joule #1126]) runs in an env — the member slug is the always-present fallback.thumbUrl/viewUrlto theTutorialImagesprojection, filled inafter('READ')fromsourceUrl:thumbUrl→ approuter/img-cdn(resize/WebP preview), rendered inline via@UI.IsImageURLviewUrl→ CAP/content/image-source(raw original, self-heals from object store)byteSizeexisted); fresh ingest populates it.Tests
test/unit/admin-facet-readability.test.js— CSN annotation guards for all three + a served runtime check of the image URL enrichment (incl. null-sourceUrlskip). EDMX verified: annotations land onconcept_ID,communityId,thumbUrl. Full compile clean; related admin/community suites green.Deploy note
Admin-UI change — requires a FULL deploy (
npm run deploy -- --env <env>, no--skip-build/ no-mscoping) to view; the admin bundle is raw-copied into the approuter atmbt build.No
srv/libchange (no srv-qa cp-list impact);KgCommunityLabelInfois a projection on an already-persisted entity (no migration).