-
Notifications
You must be signed in to change notification settings - Fork 386
feat(doc-tools): add doc medium-zoom plugin #3716
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
Conversation
🦋 Changeset detectedLatest commit: b12399b The changes in this PR will be included in the next version bump. This PR includes changesets to release 207 packages
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 |
12bb415 to
ece295c
Compare
…o feat/medium-zoom-plugin
ece295c to
fa78c19
Compare
3f605a5 to
b12399b
Compare
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## main #3716 +/- ##
==========================================
+ Coverage 57.59% 58.12% +0.52%
==========================================
Files 672 643 -29
Lines 17794 17173 -621
Branches 3876 3757 -119
==========================================
- Hits 10249 9982 -267
+ Misses 6934 6589 -345
+ Partials 611 602 -9 ☔ View full report in Codecov by Sentry. |
Summary
doc.mediumZoom配置🤖 Generated by Copilot at 439880b
This pull request adds a new plugin for medium-zoom functionality in the documentation system of
@modern-js/doc-core. It refactors the plugin loading mechanism and the global UI components and styles hooks in the core package. It also updates the default theme and the doc config interface to support the new plugin. It creates a new package for@modern-js/doc-plugin-medium-zoomwith the necessary files and configuration.Details
🤖 Generated by Copilot at 439880b
@modern-js/doc-plugin-medium-zoomas a new package to provide the medium-zoom feature for doc images (F10-F19)@modern-js/doc-plugin-medium-zoomas a workspace dependency and removemedium-zoomas a direct dependency (link, link)mediumZoomoption to theDocConfiginterface to enable or disable the feature or customize the selector (link)getPluginsfunction with theloadPluginsfunction inhooks.tsto asynchronously import thepluginLastUpdatedand thepluginMediumZoombased on the config options, and also push the user-defined plugins to thedocPluginsarray (link)getPluginsin thebeforeBuild,afterBuild,extendPageData, andaddPageshooks, since thedocPluginsarray is already initialized by theloadPluginsfunction (link, link, link, link, link)globalUIComponentsandglobalStyles, to collect the global UI components and global styles from thedocPluginsarray and return them as arrays of strings (link)globalStylesandglobalUIComponentshooks in theglobalStylesVMPluginandglobalUIComponentsVMPluginfunctions in theglobalStyles.tsandglobalUIComponents.tsfiles (link, link)medium-zoomand theDocContentcomponent from theindex.tsxfile oftheme-default/layout/DocLayout, since they are now handled by the plugin (link, link)DocContentcomponent with theContentcomponent in theDocLayoutcomponent (link)base.cssfile oftheme-default/styles, since they are now provided by the plugin (link)loadPluginsfunction before the build and dev processes in thebuild.tsanddev.tsfiles (link, link)Related Issue
Checklist
pnpm run change.