@flatbiz/pro-layout 4.4.31 → 4.4.32

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.
package/index.d.ts CHANGED
@@ -741,6 +741,11 @@ export type IframeApiProps = {
741
741
  isInIframe: () => boolean;
742
742
  /** 判断iframe链路上一级是否存在 */
743
743
  isExistPrevLink: () => boolean;
744
+ /** 更新菜单徽标 */
745
+ updateMenuBadge: (data: {
746
+ menuLink: string;
747
+ badgeCount: number;
748
+ }[]) => void;
744
749
  };
745
750
  /**
746
751
  * 使用Iframe通讯的API
@@ -782,5 +787,20 @@ export declare const proLayoutModels: import("@dimjs/model").APIs<{
782
787
  * 获取iframeTab下的唯一值,iframeTab未删除时,唯一值不变,iframeTab删除后再打开,唯一值变化
783
788
  */
784
789
  export declare const getIframeTabUid: (prefix: string) => string;
790
+ export interface MenuPubSubMap {
791
+ changeMenuBadge: {
792
+ menuLink: string;
793
+ badgeCount: number;
794
+ }[];
795
+ }
796
+ export type IframeMainEvent = keyof MenuPubSubMap;
797
+ export declare const menuPubSub: {
798
+ /** 发布 */
799
+ publish<K extends IframeMainEvent>(event: K, data: MenuPubSubMap[K]): void;
800
+ /** 订阅 */
801
+ subscribe<K extends IframeMainEvent>(event: K, callback: (data: MenuPubSubMap[K]) => void): void;
802
+ /** 取消订阅 */
803
+ unsubscribe<K extends IframeMainEvent>(event: K, callback: (data: MenuPubSubMap[K]) => void): void;
804
+ };
785
805
 
786
806
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flatbiz/pro-layout",
3
- "version": "4.4.31",
3
+ "version": "4.4.32",
4
4
  "description": "WEB菜单布局",
5
5
  "main": "index.js",
6
6
  "typings": "index.d.ts",