@linkdesk/contracts 0.1.27 → 0.1.29

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/linkdesk.d.ts +13 -5
  2. package/package.json +1 -1
package/linkdesk.d.ts CHANGED
@@ -403,8 +403,7 @@ export interface TitleBarLayout {
403
403
  unpin: string;
404
404
  };
405
405
  }
406
- /** 池侧图标——壳序列化(池不 import pluginLoader,Lucide 名由池映射组件渲染)。
407
- * 图标栏 + 标签栏共用(标签栏视图标签 / 文件标签走同一联合) */
406
+ /** 池侧图标——壳序列化(池不 import pluginLoader,Lucide 名由池映射组件渲染);图标栏与标签栏共用 */
408
407
  export type IconBarIcon = {
409
408
  kind: "lucide";
410
409
  name: string;
@@ -413,7 +412,7 @@ export type IconBarIcon = {
413
412
  kind: "codicon";
414
413
  name: string;
415
414
  color?: string;
416
- } // codicon CSS 类(可选每图标色——文件图标主题数据)
415
+ } // codicon CSS 类(可选每图标色)
417
416
  | {
418
417
  kind: "img";
419
418
  src: string;
@@ -429,12 +428,21 @@ export interface IconBarItem {
429
428
  icon: IconBarIcon;
430
429
  /** tooltip / aria-label——壳 t(manifest.name) */
431
430
  label: string;
432
- /** 图标位置——getIconLocation:顶部活动图标 / 底部齿轮 */
433
- location: "top" | "bottom";
431
+ location: "top" | "bottom"; // 主列 / 底部固定组——纯几何,⛔ 与「是不是齿轮」无关(齿轮见 owned)
432
+ }
433
+ /** 壳自带按钮——归属壳,不来自任何插件(今天只有齿轮)。 */
434
+ export interface IconBarOwnedButton {
435
+ id: string; // 稳定身份——池渲染成 data-owned-id(⛔ 不是 data-plugin-id,那会被当拖拽落点)
436
+ icon: IconBarIcon; // 壳自带资产(壳 getAssetPath 解析后下发)
437
+ label: string; // tooltip / aria-label——壳 t() 解析
438
+ location: "bottom";
439
+ menuId: string; // 点击要弹的菜单槽位 id(池哑渲染,菜单项仍由壳 MenuRegistry 推送)
434
440
  }
435
441
  /** 图标栏布局——IconBarZone 消费 */
436
442
  export interface IconBarLayout {
437
443
  icons: IconBarItem[];
444
+ /** 壳自带按钮——池在底部组末位渲染,恒可见/不可拖/不进 iconOrder。⛔ 别塞进 `icons`(那条数组整条在拖拽与持久化路径上,子夹 01-设计 §四);必填:漏补即 tsc 红 */
445
+ owned: IconBarOwnedButton[];
438
446
  /** 激活图标——当前侧栏容器所属插件(侧栏折叠/无容器时不亮,壳 isActive 同款双重守卫) */
439
447
  activePluginId?: string;
440
448
  /** ☰ 汉堡可见——menuStyle hamburger/both */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@linkdesk/contracts",
3
- "version": "0.1.27",
3
+ "version": "0.1.29",
4
4
  "description": "LinkDesk 插件契约类型——window.linkdesk.* 全量类型定义(E5.8 契约生成产物)。第三方插件作者唯一合法类型消费路径。",
5
5
  "type": "module",
6
6
  "types": "./linkdesk.d.ts",