dsh-settings-launcher 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/client.js +5 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-settings-launcher",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "description": "侧栏账号入口的两个独立开关:悬浮自动展开原版菜单、点击直达设置;可单选也可全开,全关即官方原样。",
5
5
  "type": "module",
6
6
  "main": "src/index.js",
package/src/client.js CHANGED
@@ -832,6 +832,11 @@ window.__ModuleLoader__.load({
832
832
 
833
833
  return {
834
834
  inject: ['slots', 'remote.account'],
835
+ // The switches are also readable from outside this bundle: the aggregator
836
+ // that vendors this file renders the same card (never a copy) and injects
837
+ // the same stylesheet, so the two surfaces cannot drift.
838
+ __settings: { SwitchCard },
839
+ __ui: { pluginId: NS, css: () => CSS },
835
840
  apply(ctx) {
836
841
  // ctx.effect 要的是一个 cleanup 函数;ensureStyle() 返回的是 <style>
837
842
  // 元素,直接返回会让 Cordis 在激活时拿到非函数值而把 fiber 判为 failed。