feat(unify): removing prism and adding infrastructure for shiki (#18514)

* feat: use shikijs for highlighting code

* add line numbers

* fix Jess's remarks

* remove last instances of prism

* fix: remove unused prism packages

* fix broken build

* remove prism

* remnove prism one last time

* remove the last piece of prism in tests

* remove prism and refactor

* restore proper fe-shared test

* use windi to color shiki

* rename theme and create test

* cosmetic fixes

* avoid the jank

* fix image imports in typescript

* restore mistake

* make the shiki theme generator

* gitignore the shiki-heme generated

* add the shiki theme generation to yarn build

* make shiki theme look good

* last colors to update

* styling fixes

* styling fixes

* styling fixes

* styling fixes

* theme

* fix relative positioning

* Update .gitignore

* Update packages/frontend-shared/src/components/ShikiHighlight.vue

* remove conflicting copy button

* dont top level await

* add a readme for theme generation

* ignore generated theme

* fix integration test in launchpad

* fix other integration test

* bring back the cypress theme

* fixing public path issue

* make e2e work

* fix yarn dev (remove the double slash)

* review theme with ryan

* make copy on click optional

* adjust viewports

* move generation of theme before vite build

Co-authored-by: Jessica Sachs <jess@jessicasachs.io>
Co-authored-by: Lachlan Miller <lachlan.miller.1990@outlook.com>
This commit is contained in:
Barthélémy Ledoux
2021-10-19 17:00:32 -05:00
committed by GitHub
parent 395504c7af
commit 9a2e55071d
51 changed files with 31732 additions and 342 deletions
+6
View File
@@ -124,6 +124,12 @@ export function viteBuildAndWatchLaunchpad () {
})
}
export function generateShikiTheme () {
return spawned('vite:build-generate-shiki-theme', `yarn generate-shiki-theme`, {
cwd: monorepoPaths.pkgFrontendShared,
})
}
export function viteCleanApp () {
return spawned('vite-clean', `yarn clean`, {
cwd: monorepoPaths.pkgApp,