refactor(tooling): [MOD-PLUGIN-01] generate typed plugins with safe output handling

This commit is contained in:
Harvey Zhao committed 2026-09-14 10:19:19 +08:00
1 parent 07d5bfef2e
commit 28c7abb2bb
32 files changed
+958 -161

No files matched your search

@@ -0,0 +1,12 @@
import css from './style.less?inline'
// The stylesheet belongs to the module, not individual player instances.
if (typeof document !== 'undefined') {
const id = 'artplayer-plugin-{{name}}'
if (!document.getElementById(id)) {
const style = document.createElement('style')
style.id = id
style.textContent = css
;(document.head || document.documentElement).appendChild(style)
}
}