feat: add BlockVariant for named widget block styles#95
Merged
Conversation
|
To preview the documentation for this pull request, visit the following URL:
|
|
Visit the preview URL for this PR (updated for commit da2d9f7): https://superdeck-dev--pr95-feat-block-variant-s-h1rvy6c7.web.app (expires Sun, 09 Aug 2026 15:06:35 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: bd68fc230762285849207e7e120aaf87cd4ca2f9 |
Adds a default BlockVariant('webview') rule to the base SlideStyle so
webview blocks get zero padding and margin without any stylesheet. Uses
BlockVariant rather than NamedVariant because a plain NamedVariant does
not activate for a rendered widget block.
Regenerated by pod install: adds irondash_engine_context and super_native_extensions pods and the Embed Pods Frameworks build phase so the macOS demo builds without a manual pod install.
SlideParts.background defaults to a transparent BackgroundPart, so a slide with no background (e.g. a chrome-less template) rendered see-through and bled adjacent slides through during cross-fade transitions. Always paint an opaque base color beneath the background part, sourced from a shared constant reused by the app shell letterbox.
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.
Adds
BlockVariant, an opt-in Mix context selector that lets Dart stylesheets target a namedWidgetBlock(e.g.@webview,@chart) without adding style fields to Markdown, block arguments, or frontmatter. Each widget block now resolves its container style inside an internalBlockVariantScope, so a matching variant affects both the rendered container and the child's calculated size together. ExistingNamedVariantrules and default image/gist spacing are unaffected unless a stylesheet explicitly adds aBlockVariantrule. Includes docs updates fordeck-optionsandmarkdown-syntax, a CHANGELOG entry, and new widget/rendering tests covering matching, sibling isolation, and layout sizing.