소스 검색

enhance(apis): add note for setBlockIcon method

charlie 1 주 전
부모
커밋
dc4c712089
2개의 변경된 파일4개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      libs/src/LSPlugin.core.ts
  2. 3 0
      libs/src/LSPlugin.ts

+ 1 - 1
libs/src/LSPlugin.core.ts

@@ -54,7 +54,7 @@ const DIR_PLUGINS = 'plugins'
 declare global {
   interface Window {
     LSPluginCore: LSPluginCore
-    DOMPurify: typeof DOMPurify
+    DOMPurify: any
     $$callerPluginID: string | undefined
   }
 }

+ 3 - 0
libs/src/LSPlugin.ts

@@ -789,6 +789,9 @@ export interface IEditorProxy extends Record<string, any> {
   removeTagExtends: (tagId: BlockIdentity, parentTagIdOrName: BlockIdentity) => Promise<void>
   addBlockTag: (blockId: BlockIdentity, tagId: BlockIdentity) => Promise<void>
   removeBlockTag: (blockId: BlockIdentity, tagId: BlockIdentity) => Promise<void>
+  /**
+   * @note Emoji icon name from https://learn.missiveapp.com/open/emoji-mart
+   * */
   setBlockIcon: (blockId: BlockIdentity, iconType: 'tabler-icon' | 'emoji', iconName: string) => Promise<void>
   removeBlockIcon: (blockId: BlockIdentity) => Promise<void>