Repository navigation
Import legacy templates from Microsoft Whiteboard (1.7.4) - #176
Merged
Merged
Conversation
A template from the Windows 10 app is a collection: a title and the items placed on it, each a child placed from its corner holding the content of one object. The title becomes its blue bar and a bold label, and each child is read by the reader for what it holds, through an anchor composed from the template and the child. The markup comes from the web client's template conversion and CollectionComponent, because no sample holds a template. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
marcosqlbi
added a commit
that referenced
this pull request
Sep 30, 2026
Loop components (`LoopObject`, and `HostedFluidObject` or `GroupFluidObject` holding one) and apps made by Copilot (`AppIframeHost`) were reported as left out. No sample holds either, so the markup was read from the Microsoft Whiteboard web client's public code, as for #174 to #176. The export keeps neither kind of content. Its export code (`replaceLoopIFramesWithPlaceholders` and `replaceAppFrameIFramesWithPlaceholders`) does this: - **Loop component.** The export replaces the content of each `div.loopParentDiv` with an `a` to the component's `data-loop-url` around the picture `LoopExportThumbnail.svg`, which it does not embed. The importer makes it a Markdown text container titled *Loop* with a link to that address, as wide as the component, or the words *Loop component* when there is no address. `HostedFluidObject` and `GroupFluidObject` are read the same way when they hold a Loop element and are reported otherwise. - **App.** `AppIframeHost` is an app that Copilot generated, running in a sandboxed `iframe`, not a video. The export replaces the frame with a `#faf9f8` panel and keeps the `div.appFrameContainer` with its size and its header, whose title reads *App* in the board's language; the app's name, code, and state are not in the export. The importer makes it a rectangle of that size in the panel's color with the header's title as its text, so the space it took stays on the board. Both are placed by the anchor's alignment: `Anchor` now records whether its `center` class is present. A new Core smoke test builds a sized Loop component with its link, a centered one without an address or a size, an app frame, and a `HostedFluidObject` without a Loop element, which is still reported. All 19 samples still import unchanged. The solution builds clean and both harnesses pass. 1.7.4 is not released yet, so this joins its notes as a second entry and the version stays 1.7.4. The import doc and the site's export page describe both. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Templates from boards made with the Windows 10 app (
LegacyTemplate) were reported as left out. No sample holds one, so the markup was read from the Microsoft Whiteboard web client's public code, as the lists, tables, and stickers were in #174 and #175.The web client converts a legacy template into a collection, drawn by
CollectionComponent: onediv.topLeftchild per item with its ownleft,top, andtransform, holding the content of one object without the anchor around it. The first child is the title, atextbox.templateTitle; the exported stylesheet draws it as a white panel 60 pixels tall with a 4-pixel#0C34FAbar on top, 6 and 8 pixels of padding, and bold 24-pixel text. Every child is moved by the same offset so that none sits left of or above the title. When the web client'sEnableTemplatesflag is off it draws a placeholder instead, and that case stays reported.The importer reads the title as a filled rectangle for the bar and a bold label, which is what shows on a white board. Each other child is recognized by what it holds and read by the existing reader for that kind (ink, a note, a note grid, a list, a text box, a picture, or a shape including the older ellipse and polygon) through the child's anchor composed with the template's. A picture or a shape moves by half its size, because a child is placed from its corner while those are centered on their anchor at the top level. A child of any other kind is counted as a template item in the message after the import.
A new Core smoke test builds a template with a title, a note, a picture, scaled ink, an older polygon, and a child of an unknown kind, plus a template drawn as a placeholder, and checks every position and count. The page was also drawn through the application's renderer. All 19 samples still import unchanged. The solution builds clean and both harnesses pass.
1.7.3 is released, so the version goes to 1.7.4, with a CHANGELOG entry; the import doc and the site's export page describe templates.
🤖 Generated with Claude Code