File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
docs/.vitepress/theme/upgrading Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -57,8 +57,8 @@ function update() {
5757 to: nowTo .value
5858 };
5959 window .location .hash = ` #${nowUpgradingInfo .value .from }-${nowUpgradingInfo .value .to } ` ;
60- fromOptions .value = getVersionsBefore (nowUpgradingInfo .value .to );
61- toOptions .value = getVersionsAfter (nowUpgradingInfo .value .from );
60+ fromOptions .value = getVersionsBefore (nowUpgradingInfo .value .to ). reverse () ;
61+ toOptions .value = getVersionsAfter (nowUpgradingInfo .value .from ). reverse () ;
6262 nowChanges .value = getChanges (nowUpgradingInfo .value );
6363 const changes = nowChanges .value .map (change => ` ${change .from }-to-${change .to } ` );
6464 document .querySelectorAll (' .upgrading-parts-container div' ).forEach (ele => {
Original file line number Diff line number Diff line change @@ -12,7 +12,8 @@ export const injectUpgradingPartsPlugin = (md: MarkdownIt) => {
1212${ state . src . replace ( INJECT_UPGRADING_PARTS , upgradingInfos
1313 . map ( info => {
1414 const targetPartFile = `./docs/en/upgrading-parts/${ info . from } -to-${ info . to } .md` ;
15- const targetPartContent = fs . readFileSync ( targetPartFile , 'utf-8' ) ;
15+ const targetPartContent = fs . readFileSync ( targetPartFile , 'utf-8' )
16+ . replace ( new RegExp ( "]\\(\\.\\./" , 'g' ) , "](./" ) ;
1617 return `
1718<div id="${ info . from } -to-${ info . to } " class="default-hide">
1819
You can’t perform that action at this time.
0 commit comments