roamjs-components 0.86.0-alpha.3 → 0.86.1
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/LICENSE +21 -21
- package/README.md +29 -29
- package/components/AutocompleteInput.d.ts +29 -28
- package/components/AutocompleteInput.js +132 -120
- package/components/AutocompleteInput.js.map +1 -1
- package/components/BlockErrorBoundary.d.ts +15 -16
- package/components/BlockErrorBoundary.js +27 -27
- package/components/BlockErrorBoundary.js.map +1 -1
- package/components/BlockInput.d.ts +13 -13
- package/components/BlockInput.js +55 -55
- package/components/ComponentContainer.d.ts +10 -11
- package/components/ComponentContainer.js +37 -37
- package/components/ComponentContainer.js.map +1 -1
- package/components/ConfigPage.d.ts +35 -35
- package/components/ConfigPage.js +159 -159
- package/components/ConfigPanels/BlockPanel.d.ts +3 -3
- package/components/ConfigPanels/BlockPanel.js +42 -42
- package/components/ConfigPanels/BlockPanel.js.map +1 -1
- package/components/ConfigPanels/BlocksPanel.d.ts +3 -3
- package/components/ConfigPanels/BlocksPanel.js +58 -58
- package/components/ConfigPanels/BlocksPanel.js.map +1 -1
- package/components/ConfigPanels/CustomPanel.d.ts +3 -3
- package/components/ConfigPanels/CustomPanel.js +24 -24
- package/components/ConfigPanels/FlagPanel.d.ts +3 -3
- package/components/ConfigPanels/FlagPanel.js +31 -31
- package/components/ConfigPanels/MultiChildPanel.d.ts +9 -9
- package/components/ConfigPanels/MultiChildPanel.js +58 -58
- package/components/ConfigPanels/MultiTextPanel.d.ts +3 -3
- package/components/ConfigPanels/MultiTextPanel.js +14 -14
- package/components/ConfigPanels/NumberPanel.d.ts +3 -3
- package/components/ConfigPanels/NumberPanel.js +25 -25
- package/components/ConfigPanels/OauthPanel.d.ts +3 -3
- package/components/ConfigPanels/OauthPanel.js +81 -81
- package/components/ConfigPanels/OauthPanel.js.map +1 -1
- package/components/ConfigPanels/PagesPanel.d.ts +3 -3
- package/components/ConfigPanels/PagesPanel.js +11 -11
- package/components/ConfigPanels/SelectPanel.d.ts +3 -3
- package/components/ConfigPanels/SelectPanel.js +27 -27
- package/components/ConfigPanels/TextPanel.d.ts +3 -3
- package/components/ConfigPanels/TextPanel.js +28 -28
- package/components/ConfigPanels/TimePanel.d.ts +3 -3
- package/components/ConfigPanels/TimePanel.js +34 -34
- package/components/ConfigPanels/getBrandColors.d.ts +7 -7
- package/components/ConfigPanels/getBrandColors.js +28 -28
- package/components/ConfigPanels/types.d.ts +84 -84
- package/components/ConfigPanels/types.js +2 -2
- package/components/ConfigPanels/types.js.map +1 -1
- package/components/ConfigPanels/useSingleChildValue.d.ts +13 -13
- package/components/ConfigPanels/useSingleChildValue.js +43 -43
- package/components/CursorMenu.d.ts +21 -21
- package/components/CursorMenu.js +181 -181
- package/components/CursorMenu.js.map +1 -1
- package/components/Description.d.ts +5 -5
- package/components/Description.js +16 -16
- package/components/ExtensionApiContext.d.ts +31 -31
- package/components/ExtensionApiContext.js +16 -16
- package/components/ExternalLogin.d.ts +18 -18
- package/components/ExternalLogin.js +141 -141
- package/components/Filter.d.ts +15 -15
- package/components/Filter.js +142 -142
- package/components/FormDialog.d.ts +55 -55
- package/components/FormDialog.js +220 -217
- package/components/FormDialog.js.map +1 -1
- package/components/Loading.d.ts +4 -4
- package/components/Loading.js +35 -35
- package/components/MenuItemSelect.d.ts +17 -17
- package/components/MenuItemSelect.js +23 -23
- package/components/MenuItemSelect.js.map +1 -1
- package/components/OauthPanel.d.ts +7 -7
- package/components/OauthPanel.js +30 -30
- package/components/OauthSelect.d.ts +5 -5
- package/components/OauthSelect.js +25 -25
- package/components/PageInput.d.ts +6 -6
- package/components/PageInput.js +13 -13
- package/components/PageLink.d.ts +6 -6
- package/components/PageLink.js +31 -31
- package/components/ProgressDialog.d.ts +11 -11
- package/components/ProgressDialog.js +48 -48
- package/components/SimpleAlert.d.ts +15 -15
- package/components/SimpleAlert.js +47 -47
- package/components/Toast.d.ts +15 -15
- package/components/Toast.js +50 -50
- package/components/index.js +4 -4
- package/components/index.js.map +1 -1
- package/components.d.ts +5 -5
- package/components.js +172 -201
- package/components.js.map +1 -1
- package/date/constants.d.ts +3 -3
- package/date/constants.js +19 -19
- package/date/constants.js.map +1 -1
- package/date/index.d.ts +3 -3
- package/date/index.js +9 -9
- package/date/index.js.map +1 -1
- package/date/parseNlpDate.d.ts +5 -5
- package/date/parseNlpDate.js +226 -226
- package/date/parseNlpDate.js.map +1 -1
- package/date/parseRoamDateUid.d.ts +2 -2
- package/date/parseRoamDateUid.js +7 -7
- package/date/parseRoamDateUid.js.map +1 -1
- package/dom/addBlockCommand.d.ts +5 -5
- package/dom/addBlockCommand.js +53 -53
- package/dom/addBlockCommand.js.map +1 -1
- package/dom/addKeyboardTriggers.d.ts +11 -11
- package/dom/addKeyboardTriggers.js +38 -38
- package/dom/addKeyboardTriggers.js.map +1 -1
- package/dom/addOldRoamJSDependency.d.ts +2 -2
- package/dom/addOldRoamJSDependency.js +10 -10
- package/dom/addOldRoamJSDependency.js.map +1 -1
- package/dom/addRoamJSDependency.d.ts +2 -2
- package/dom/addRoamJSDependency.js +8 -8
- package/dom/addRoamJSDependency.js.map +1 -1
- package/dom/addScriptAsDependency.d.ts +6 -6
- package/dom/addScriptAsDependency.js +16 -16
- package/dom/addScriptAsDependency.js.map +1 -1
- package/dom/addStyle.d.ts +2 -2
- package/dom/addStyle.js +14 -14
- package/dom/addStyle.js.map +1 -1
- package/dom/constants.d.ts +1 -1
- package/dom/constants.js +4 -4
- package/dom/constants.js.map +1 -1
- package/dom/createBlockObserver.d.ts +7 -7
- package/dom/createBlockObserver.js +43 -43
- package/dom/createBlockObserver.js.map +1 -1
- package/dom/createButtonObserver.d.ts +6 -6
- package/dom/createButtonObserver.js +21 -21
- package/dom/createButtonObserver.js.map +1 -1
- package/dom/createDivObserver.d.ts +2 -2
- package/dom/createDivObserver.js +13 -13
- package/dom/createDivObserver.js.map +1 -1
- package/dom/createHTMLObserver.d.ts +8 -8
- package/dom/createHTMLObserver.js +24 -24
- package/dom/createHTMLObserver.js.map +1 -1
- package/dom/createHashtagObserver.d.ts +5 -5
- package/dom/createHashtagObserver.js +16 -16
- package/dom/createHashtagObserver.js.map +1 -1
- package/dom/createIconButton.d.ts +2 -2
- package/dom/createIconButton.js +12 -12
- package/dom/createIconButton.js.map +1 -1
- package/dom/createObserver.d.ts +2 -2
- package/dom/createObserver.js +9 -9
- package/dom/createObserver.js.map +1 -1
- package/dom/createOverlayObserver.d.ts +2 -2
- package/dom/createOverlayObserver.js +6 -6
- package/dom/createOverlayObserver.js.map +1 -1
- package/dom/createPageObserver.d.ts +2 -2
- package/dom/createPageObserver.js +34 -34
- package/dom/createPageObserver.js.map +1 -1
- package/dom/createPageTitleObserver.d.ts +6 -6
- package/dom/createPageTitleObserver.js +31 -31
- package/dom/createPageTitleObserver.js.map +1 -1
- package/dom/elToTitle.d.ts +2 -2
- package/dom/elToTitle.js +22 -22
- package/dom/elToTitle.js.map +1 -1
- package/dom/genericError.d.ts +3 -3
- package/dom/genericError.js +11 -11
- package/dom/genericError.js.map +1 -1
- package/dom/getActiveUids.d.ts +3 -3
- package/dom/getActiveUids.js +6 -6
- package/dom/getActiveUids.js.map +1 -1
- package/dom/getBlockUidFromTarget.d.ts +2 -2
- package/dom/getBlockUidFromTarget.js +33 -33
- package/dom/getBlockUidFromTarget.js.map +1 -1
- package/dom/getCurrentPageUid.d.ts +2 -2
- package/dom/getCurrentPageUid.js +8 -8
- package/dom/getCurrentPageUid.js.map +1 -1
- package/dom/getDomRefs.d.ts +2 -2
- package/dom/getDomRefs.js +12 -12
- package/dom/getDomRefs.js.map +1 -1
- package/dom/getDropUidOffset.d.ts +5 -5
- package/dom/getDropUidOffset.js +27 -27
- package/dom/getDropUidOffset.js.map +1 -1
- package/dom/getMutatedNodes.d.ts +7 -7
- package/dom/getMutatedNodes.js +11 -11
- package/dom/getMutatedNodes.js.map +1 -1
- package/dom/getPageTitleByHtmlElement.d.ts +2 -2
- package/dom/getPageTitleByHtmlElement.js +12 -12
- package/dom/getPageTitleByHtmlElement.js.map +1 -1
- package/dom/getPageTitleValueByHtmlElement.d.ts +2 -2
- package/dom/getPageTitleValueByHtmlElement.js +9 -9
- package/dom/getPageTitleValueByHtmlElement.js.map +1 -1
- package/dom/getReferenceBlockUid.d.ts +2 -2
- package/dom/getReferenceBlockUid.js +18 -18
- package/dom/getReferenceBlockUid.js.map +1 -1
- package/dom/getRoamUrl.d.ts +2 -2
- package/dom/getRoamUrl.js +4 -4
- package/dom/getRoamUrl.js.map +1 -1
- package/dom/getRoamUrlByPage.d.ts +2 -2
- package/dom/getRoamUrlByPage.js +10 -10
- package/dom/getRoamUrlByPage.js.map +1 -1
- package/dom/getUids.d.ts +3 -3
- package/dom/getUids.js +8 -8
- package/dom/getUids.js.map +1 -1
- package/dom/getUidsFromButton.d.ts +3 -3
- package/dom/getUidsFromButton.js +8 -8
- package/dom/getUidsFromButton.js.map +1 -1
- package/dom/getUidsFromId.d.ts +5 -5
- package/dom/getUidsFromId.js +15 -15
- package/dom/getUidsFromId.js.map +1 -1
- package/dom/index.d.ts +30 -30
- package/dom/index.js +63 -63
- package/dom/index.js.map +1 -1
- package/dom/parseRoamBlocksToHtml.d.ts +11 -11
- package/dom/parseRoamBlocksToHtml.js +79 -79
- package/dom/parseRoamBlocksToHtml.js.map +1 -1
- package/dom/resolveRefs.d.ts +2 -2
- package/dom/resolveRefs.js +24 -24
- package/dom/resolveRefs.js.map +1 -1
- package/events/index.d.ts +1 -1
- package/events/index.js +8 -8
- package/events/index.js.map +1 -1
- package/events/watchOnce.d.ts +3 -3
- package/events/watchOnce.js +12 -12
- package/events/watchOnce.js.map +1 -1
- package/hooks/index.d.ts +2 -2
- package/hooks/index.js +10 -10
- package/hooks/index.js.map +1 -1
- package/hooks/useArrowKeyDown.d.ts +10 -10
- package/hooks/useArrowKeyDown.js +54 -54
- package/hooks/useArrowKeyDown.js.map +1 -1
- package/hooks/useSubTree.d.ts +3 -3
- package/hooks/useSubTree.js +11 -11
- package/hooks/useSubTree.js.map +1 -1
- package/marked/index.d.ts +25 -25
- package/marked/index.js +567 -567
- package/marked/index.js.map +1 -1
- package/package.json +120 -125
- package/queries/compileDatalog.d.ts +3 -3
- package/queries/compileDatalog.js +63 -63
- package/queries/compileDatalog.js.map +1 -1
- package/queries/getAllBlockUids.d.ts +2 -2
- package/queries/getAllBlockUids.js +6 -6
- package/queries/getAllBlockUids.js.map +1 -1
- package/queries/getAllBlockUidsAndTexts.d.ts +5 -5
- package/queries/getAllBlockUidsAndTexts.js +6 -6
- package/queries/getAllBlockUidsAndTexts.js.map +1 -1
- package/queries/getAllPageNames.d.ts +2 -2
- package/queries/getAllPageNames.js +6 -6
- package/queries/getAllPageNames.js.map +1 -1
- package/queries/getAttributeValueByBlockAndName.d.ts +5 -5
- package/queries/getAttributeValueByBlockAndName.js +11 -11
- package/queries/getAttributeValueByBlockAndName.js.map +1 -1
- package/queries/getBasicTreeByParentUid.d.ts +3 -3
- package/queries/getBasicTreeByParentUid.js +13 -13
- package/queries/getBasicTreeByParentUid.js.map +1 -1
- package/queries/getBlockUidAndTextIncludingText.d.ts +5 -5
- package/queries/getBlockUidAndTextIncludingText.js +7 -7
- package/queries/getBlockUidAndTextIncludingText.js.map +1 -1
- package/queries/getBlockUidByTextOnPage.d.ts +5 -5
- package/queries/getBlockUidByTextOnPage.js +7 -7
- package/queries/getBlockUidByTextOnPage.js.map +1 -1
- package/queries/getBlockUidsAndTextsReferencingPage.d.ts +5 -5
- package/queries/getBlockUidsAndTextsReferencingPage.js +9 -9
- package/queries/getBlockUidsAndTextsReferencingPage.js.map +1 -1
- package/queries/getBlockUidsByPageTitle.d.ts +2 -2
- package/queries/getBlockUidsByPageTitle.js +8 -8
- package/queries/getBlockUidsByPageTitle.js.map +1 -1
- package/queries/getBlockUidsReferencingBlock.d.ts +2 -2
- package/queries/getBlockUidsReferencingBlock.js +4 -4
- package/queries/getBlockUidsReferencingBlock.js.map +1 -1
- package/queries/getBlockUidsReferencingPage.d.ts +2 -2
- package/queries/getBlockUidsReferencingPage.js +6 -6
- package/queries/getBlockUidsReferencingPage.js.map +1 -1
- package/queries/getBlockUidsWithParentUid.d.ts +2 -2
- package/queries/getBlockUidsWithParentUid.js +6 -6
- package/queries/getBlockUidsWithParentUid.js.map +1 -1
- package/queries/getChildrenLengthByPageUid.d.ts +2 -2
- package/queries/getChildrenLengthByPageUid.js +8 -8
- package/queries/getChildrenLengthByPageUid.js.map +1 -1
- package/queries/getChildrenLengthByParentUid.d.ts +2 -2
- package/queries/getChildrenLengthByParentUid.js +7 -7
- package/queries/getChildrenLengthByParentUid.js.map +1 -1
- package/queries/getCreateTimeByBlockUid.d.ts +2 -2
- package/queries/getCreateTimeByBlockUid.js +7 -7
- package/queries/getCreateTimeByBlockUid.js.map +1 -1
- package/queries/getCurrentUser.d.ts +2 -2
- package/queries/getCurrentUser.js +11 -11
- package/queries/getCurrentUser.js.map +1 -1
- package/queries/getCurrentUserDisplayName.d.ts +2 -2
- package/queries/getCurrentUserDisplayName.js +10 -10
- package/queries/getCurrentUserDisplayName.js.map +1 -1
- package/queries/getCurrentUserEmail.d.ts +2 -2
- package/queries/getCurrentUserEmail.js +13 -13
- package/queries/getCurrentUserEmail.js.map +1 -1
- package/queries/getCurrentUserUid.d.ts +2 -2
- package/queries/getCurrentUserUid.js +13 -13
- package/queries/getCurrentUserUid.js.map +1 -1
- package/queries/getDisplayNameByEmail.d.ts +2 -2
- package/queries/getDisplayNameByEmail.js +7 -7
- package/queries/getDisplayNameByEmail.js.map +1 -1
- package/queries/getDisplayNameByUid.d.ts +2 -2
- package/queries/getDisplayNameByUid.js +7 -7
- package/queries/getDisplayNameByUid.js.map +1 -1
- package/queries/getEditTimeByBlockUid.d.ts +2 -2
- package/queries/getEditTimeByBlockUid.js +7 -7
- package/queries/getEditTimeByBlockUid.js.map +1 -1
- package/queries/getEditedUserEmailByBlockUid.d.ts +2 -2
- package/queries/getEditedUserEmailByBlockUid.js +7 -7
- package/queries/getEditedUserEmailByBlockUid.js.map +1 -1
- package/queries/getFirstChildTextByBlockUid.d.ts +2 -2
- package/queries/getFirstChildTextByBlockUid.js +7 -7
- package/queries/getFirstChildTextByBlockUid.js.map +1 -1
- package/queries/getFirstChildUidByBlockUid.d.ts +2 -2
- package/queries/getFirstChildUidByBlockUid.js +6 -6
- package/queries/getFirstChildUidByBlockUid.js.map +1 -1
- package/queries/getFullTreeByParentUid.d.ts +3 -3
- package/queries/getFullTreeByParentUid.js +51 -51
- package/queries/getFullTreeByParentUid.js.map +1 -1
- package/queries/getLinkedPageTitlesUnderUid.d.ts +2 -2
- package/queries/getLinkedPageTitlesUnderUid.js +6 -6
- package/queries/getLinkedPageTitlesUnderUid.js.map +1 -1
- package/queries/getNthChildUidByBlockUid.d.ts +5 -5
- package/queries/getNthChildUidByBlockUid.js +7 -7
- package/queries/getNthChildUidByBlockUid.js.map +1 -1
- package/queries/getOrderByBlockUid.d.ts +2 -2
- package/queries/getOrderByBlockUid.js +7 -7
- package/queries/getOrderByBlockUid.js.map +1 -1
- package/queries/getPageTitleByBlockUid.d.ts +2 -2
- package/queries/getPageTitleByBlockUid.js +7 -7
- package/queries/getPageTitleByBlockUid.js.map +1 -1
- package/queries/getPageTitleByPageUid.d.ts +2 -2
- package/queries/getPageTitleByPageUid.js +12 -12
- package/queries/getPageTitleByPageUid.js.map +1 -1
- package/queries/getPageTitleReferencesByPageTitle.d.ts +2 -2
- package/queries/getPageTitleReferencesByPageTitle.js +6 -6
- package/queries/getPageTitleReferencesByPageTitle.js.map +1 -1
- package/queries/getPageTitlesAndBlockUidsReferencingPage.d.ts +5 -5
- package/queries/getPageTitlesAndBlockUidsReferencingPage.js +9 -9
- package/queries/getPageTitlesAndBlockUidsReferencingPage.js.map +1 -1
- package/queries/getPageTitlesAndUidsDirectlyReferencingPage.d.ts +5 -5
- package/queries/getPageTitlesAndUidsDirectlyReferencingPage.js +9 -9
- package/queries/getPageTitlesAndUidsDirectlyReferencingPage.js.map +1 -1
- package/queries/getPageTitlesReferencingBlockUid.d.ts +2 -2
- package/queries/getPageTitlesReferencingBlockUid.js +4 -4
- package/queries/getPageTitlesReferencingBlockUid.js.map +1 -1
- package/queries/getPageTitlesStartingWithPrefix.d.ts +2 -2
- package/queries/getPageTitlesStartingWithPrefix.js +6 -6
- package/queries/getPageTitlesStartingWithPrefix.js.map +1 -1
- package/queries/getPageUidByBlockUid.d.ts +2 -2
- package/queries/getPageUidByBlockUid.js +7 -7
- package/queries/getPageUidByBlockUid.js.map +1 -1
- package/queries/getPageUidByPageTitle.d.ts +2 -2
- package/queries/getPageUidByPageTitle.js +9 -9
- package/queries/getPageUidByPageTitle.js.map +1 -1
- package/queries/getPageViewType.d.ts +3 -3
- package/queries/getPageViewType.js +9 -9
- package/queries/getPageViewType.js.map +1 -1
- package/queries/getParentTextByBlockUid.d.ts +2 -2
- package/queries/getParentTextByBlockUid.js +7 -7
- package/queries/getParentTextByBlockUid.js.map +1 -1
- package/queries/getParentTextByBlockUidAndTag.d.ts +5 -5
- package/queries/getParentTextByBlockUidAndTag.js +7 -7
- package/queries/getParentTextByBlockUidAndTag.js.map +1 -1
- package/queries/getParentUidByBlockUid.d.ts +2 -2
- package/queries/getParentUidByBlockUid.js +7 -7
- package/queries/getParentUidByBlockUid.js.map +1 -1
- package/queries/getParentUidsOfBlockUid.d.ts +2 -2
- package/queries/getParentUidsOfBlockUid.js +4 -4
- package/queries/getParentUidsOfBlockUid.js.map +1 -1
- package/queries/getSettingsByEmail.d.ts +3 -3
- package/queries/getSettingsByEmail.js +7 -7
- package/queries/getSettingsByEmail.js.map +1 -1
- package/queries/getShallowTreeByParentUid.d.ts +5 -5
- package/queries/getShallowTreeByParentUid.js +9 -9
- package/queries/getShallowTreeByParentUid.js.map +1 -1
- package/queries/getTextByBlockUid.d.ts +2 -2
- package/queries/getTextByBlockUid.js +9 -9
- package/queries/getTextByBlockUid.js.map +1 -1
- package/queries/index.js +4 -4
- package/queries/index.js.map +1 -1
- package/queries/isLiveBlock.d.ts +2 -2
- package/queries/isLiveBlock.js +4 -4
- package/queries/isLiveBlock.js.map +1 -1
- package/queries/isTagOnPage.d.ts +5 -5
- package/queries/isTagOnPage.js +9 -9
- package/queries/isTagOnPage.js.map +1 -1
- package/queries/normalizePageTitle.d.ts +2 -2
- package/queries/normalizePageTitle.js +4 -4
- package/queries/normalizePageTitle.js.map +1 -1
- package/scripts/index.d.ts +1 -1
- package/scripts/index.js +26 -26
- package/scripts/index.js.map +1 -1
- package/scripts/publishToRoamDepot.d.ts +7 -7
- package/scripts/publishToRoamDepot.js +113 -113
- package/scripts/publishToRoamDepot.js.map +1 -1
- package/testing/mockRoamEnvironment.d.ts +2 -2
- package/testing/mockRoamEnvironment.js +1253 -1253
- package/testing/mockRoamEnvironment.js.map +1 -1
- package/types/index.d.ts +393 -250
- package/types/index.js +4 -4
- package/types/index.js.map +1 -1
- package/types/native.d.ts +405 -402
- package/types/native.js +4 -4
- package/types/native.js.map +1 -1
- package/types/query-builder.d.ts +10 -10
- package/types/query-builder.js +2 -2
- package/types/query-builder.js.map +1 -1
- package/types/smartblocks.d.ts +35 -35
- package/types/smartblocks.js +2 -2
- package/types/smartblocks.js.map +1 -1
- package/util/addInputSetting.d.ts +7 -7
- package/util/addInputSetting.js +25 -25
- package/util/addInputSetting.js.map +1 -1
- package/util/apiDelete.d.ts +2 -2
- package/util/apiDelete.js +6 -6
- package/util/apiDelete.js.map +1 -1
- package/util/apiGet.d.ts +2 -2
- package/util/apiGet.js +6 -6
- package/util/apiGet.js.map +1 -1
- package/util/apiPost.d.ts +2 -2
- package/util/apiPost.js +6 -6
- package/util/apiPost.js.map +1 -1
- package/util/apiPut.d.ts +2 -2
- package/util/apiPut.js +6 -6
- package/util/apiPut.js.map +1 -1
- package/util/createOverlayRender.d.ts +4 -4
- package/util/createOverlayRender.js +6 -6
- package/util/createOverlayRender.js.map +1 -1
- package/util/createTagRegex.d.ts +2 -2
- package/util/createTagRegex.js +7 -7
- package/util/createTagRegex.js.map +1 -1
- package/util/dispatchToRegistry.d.ts +3 -3
- package/util/dispatchToRegistry.js +7 -7
- package/util/dispatchToRegistry.js.map +1 -1
- package/util/env.d.ts +4 -4
- package/util/env.js +47 -47
- package/util/env.js.map +1 -1
- package/util/extensionApiContext.d.ts +29 -29
- package/util/extensionApiContext.js +17 -17
- package/util/extensionApiContext.js.map +1 -1
- package/util/extensionDeprecatedWarning.d.ts +5 -5
- package/util/extensionDeprecatedWarning.js +39 -39
- package/util/extensionDeprecatedWarning.js.map +1 -1
- package/util/extractRef.d.ts +2 -2
- package/util/extractRef.js +8 -8
- package/util/extractRef.js.map +1 -1
- package/util/extractTag.d.ts +2 -2
- package/util/extractTag.js +15 -15
- package/util/extractTag.js.map +1 -1
- package/util/focusMainWindowBlock.d.ts +2 -2
- package/util/focusMainWindowBlock.js +12 -12
- package/util/focusMainWindowBlock.js.map +1 -1
- package/util/getAuthorizationHeader.d.ts +2 -2
- package/util/getAuthorizationHeader.js +12 -12
- package/util/getAuthorizationHeader.js.map +1 -1
- package/util/getLocalStorageKey.d.ts +2 -2
- package/util/getLocalStorageKey.js +4 -4
- package/util/getLocalStorageKey.js.map +1 -1
- package/util/getOauth.d.ts +2 -2
- package/util/getOauth.js +52 -52
- package/util/getOauth.js.map +1 -1
- package/util/getOauthAccounts.d.ts +2 -2
- package/util/getOauthAccounts.js +22 -22
- package/util/getOauthAccounts.js.map +1 -1
- package/util/getRenderRoot.d.ts +2 -2
- package/util/getRenderRoot.js +18 -18
- package/util/getRenderRoot.js.map +1 -1
- package/util/getSettingIntFromTree.d.ts +7 -7
- package/util/getSettingIntFromTree.js +11 -11
- package/util/getSettingIntFromTree.js.map +1 -1
- package/util/getSettingValueFromTree.d.ts +8 -8
- package/util/getSettingValueFromTree.js +14 -14
- package/util/getSettingValueFromTree.js.map +1 -1
- package/util/getSettingValuesFromTree.d.ts +7 -7
- package/util/getSettingValuesFromTree.js +12 -12
- package/util/getSettingValuesFromTree.js.map +1 -1
- package/util/getSubTree.d.ts +8 -8
- package/util/getSubTree.js +19 -19
- package/util/getSubTree.js.map +1 -1
- package/util/getToken.d.ts +2 -2
- package/util/getToken.js +10 -10
- package/util/getToken.js.map +1 -1
- package/util/getTokenFromTree.d.ts +3 -3
- package/util/getTokenFromTree.js +4 -4
- package/util/getTokenFromTree.js.map +1 -1
- package/util/getWorkerClient.d.ts +12 -12
- package/util/getWorkerClient.js +41 -41
- package/util/getWorkerClient.js.map +1 -1
- package/util/handleBodyFetch.d.ts +3 -3
- package/util/handleBodyFetch.js +21 -21
- package/util/handleBodyFetch.js.map +1 -1
- package/util/handleFetch.d.ts +13 -13
- package/util/handleFetch.js +40 -40
- package/util/handleFetch.js.map +1 -1
- package/util/handleUrlFetch.d.ts +3 -3
- package/util/handleUrlFetch.js +19 -19
- package/util/handleUrlFetch.js.map +1 -1
- package/util/idToTitle.d.ts +2 -2
- package/util/idToTitle.js +8 -8
- package/util/idToTitle.js.map +1 -1
- package/util/index.d.ts +24 -24
- package/util/index.js +54 -54
- package/util/index.js.map +1 -1
- package/util/isControl.d.ts +2 -2
- package/util/isControl.js +4 -4
- package/util/isControl.js.map +1 -1
- package/util/localStorageGet.d.ts +2 -2
- package/util/localStorageGet.js +8 -8
- package/util/localStorageGet.js.map +1 -1
- package/util/localStorageRemove.d.ts +2 -2
- package/util/localStorageRemove.js +6 -6
- package/util/localStorageRemove.js.map +1 -1
- package/util/localStorageSet.d.ts +2 -2
- package/util/localStorageSet.js +8 -8
- package/util/localStorageSet.js.map +1 -1
- package/util/registerExperimentalMode.d.ts +6 -6
- package/util/registerExperimentalMode.js +65 -65
- package/util/registerExperimentalMode.js.map +1 -1
- package/util/registerSmartBlocksCommand.d.ts +3 -3
- package/util/registerSmartBlocksCommand.js +23 -23
- package/util/registerSmartBlocksCommand.js.map +1 -1
- package/util/removeFromRegistry.d.ts +3 -3
- package/util/removeFromRegistry.js +7 -7
- package/util/removeFromRegistry.js.map +1 -1
- package/util/renderOverlay.d.ts +12 -12
- package/util/renderOverlay.js +48 -48
- package/util/renderOverlay.js.map +1 -1
- package/util/renderWithUnmount.d.ts +4 -4
- package/util/renderWithUnmount.js +44 -44
- package/util/renderWithUnmount.js.map +1 -1
- package/util/runExtension.d.ts +11 -11
- package/util/runExtension.js +174 -174
- package/util/runExtension.js.map +1 -1
- package/util/setInputSetting.d.ts +7 -7
- package/util/setInputSetting.js +37 -37
- package/util/setInputSetting.js.map +1 -1
- package/util/setInputSettings.d.ts +7 -7
- package/util/setInputSettings.js +28 -28
- package/util/setInputSettings.js.map +1 -1
- package/util/stripUid.d.ts +3 -3
- package/util/stripUid.js +10 -10
- package/util/stripUid.js.map +1 -1
- package/util/toConfigPageName.d.ts +2 -2
- package/util/toConfigPageName.js +4 -4
- package/util/toConfigPageName.js.map +1 -1
- package/util/toFlexRegex.d.ts +2 -2
- package/util/toFlexRegex.js +4 -4
- package/util/toFlexRegex.js.map +1 -1
- package/writes/clearBlockById.d.ts +2 -2
- package/writes/clearBlockById.js +17 -17
- package/writes/clearBlockById.js.map +1 -1
- package/writes/clearBlockByUid.d.ts +2 -2
- package/writes/clearBlockByUid.js +16 -16
- package/writes/clearBlockByUid.js.map +1 -1
- package/writes/createBlock.d.ts +8 -8
- package/writes/createBlock.js +28 -28
- package/writes/createBlock.js.map +1 -1
- package/writes/createPage.d.ts +7 -7
- package/writes/createPage.js +20 -20
- package/writes/createPage.js.map +1 -1
- package/writes/deleteBlock.d.ts +2 -2
- package/writes/deleteBlock.js +10 -10
- package/writes/deleteBlock.js.map +1 -1
- package/writes/index.d.ts +8 -8
- package/writes/index.js +22 -22
- package/writes/index.js.map +1 -1
- package/writes/openBlockInSidebar.d.ts +2 -2
- package/writes/openBlockInSidebar.js +13 -13
- package/writes/openBlockInSidebar.js.map +1 -1
- package/writes/submitActions.d.ts +8 -8
- package/writes/submitActions.js +36 -36
- package/writes/submitActions.js.map +1 -1
- package/writes/updateActiveBlock.d.ts +2 -2
- package/writes/updateActiveBlock.js +17 -17
- package/writes/updateActiveBlock.js.map +1 -1
- package/writes/updateBlock.d.ts +5 -5
- package/writes/updateBlock.js +23 -23
- package/writes/updateBlock.js.map +1 -1
package/types/index.d.ts
CHANGED
|
@@ -1,250 +1,393 @@
|
|
|
1
|
-
import { AddPullWatch, PullBlock, SidebarAction, SidebarWindow, SidebarWindowInput, WriteAction } from "./native";
|
|
2
|
-
import { RunQuery, ListActiveQueries, RunQuerySync, IsDiscourseNode } from "./query-builder";
|
|
3
|
-
import { RegisterCommand, UnregisterCommand } from "./smartblocks";
|
|
4
|
-
import type marked from "marked";
|
|
5
|
-
import type Markdown from "marked-react";
|
|
6
|
-
import type JSZip from "jszip";
|
|
7
|
-
import type cytoscape from "cytoscape";
|
|
8
|
-
export * from "./native";
|
|
9
|
-
export declare type Registry = {
|
|
10
|
-
elements: HTMLElement[];
|
|
11
|
-
reactRoots: HTMLElement[];
|
|
12
|
-
observers: MutationObserver[];
|
|
13
|
-
domListeners: ({
|
|
14
|
-
el: Window;
|
|
15
|
-
type: keyof WindowEventMap;
|
|
16
|
-
listener: (this: Window, ev: WindowEventMap[keyof WindowEventMap]) => void;
|
|
17
|
-
} | {
|
|
18
|
-
el: Document;
|
|
19
|
-
type: keyof DocumentEventMap;
|
|
20
|
-
listener: (this: Document, ev: DocumentEventMap[keyof DocumentEventMap]) => void;
|
|
21
|
-
} | {
|
|
22
|
-
el: HTMLElement;
|
|
23
|
-
type: keyof HTMLElementEventMap | `roamjs:${string}`;
|
|
24
|
-
listener: (this: HTMLElement, ev: HTMLElementEventMap[keyof HTMLElementEventMap]) => void;
|
|
25
|
-
})[];
|
|
26
|
-
commands: string[];
|
|
27
|
-
timeouts: {
|
|
28
|
-
timeout: number;
|
|
29
|
-
}[];
|
|
30
|
-
};
|
|
31
|
-
declare global {
|
|
32
|
-
interface Window {
|
|
33
|
-
RoamLazy?: {
|
|
34
|
-
JSZip: () => Promise<typeof JSZip>;
|
|
35
|
-
Marked: () => Promise<typeof marked>;
|
|
36
|
-
MarkedReact: () => Promise<typeof Markdown>;
|
|
37
|
-
Cytoscape: () => Promise<typeof cytoscape>;
|
|
38
|
-
Insect: () => Promise<{
|
|
39
|
-
commands: string[];
|
|
40
|
-
fmtConsole: (M: unknown) => unknown;
|
|
41
|
-
fmtJqueryTerminal: (M: unknown) => unknown;
|
|
42
|
-
fmtPlain: (M: unknown) => unknown;
|
|
43
|
-
functions: (M: unknown) => unknown;
|
|
44
|
-
identifiers: (M: unknown) => unknown;
|
|
45
|
-
initialEnvironment: {
|
|
46
|
-
values: unknown;
|
|
47
|
-
functions: unknown;
|
|
48
|
-
};
|
|
49
|
-
repl: (fmt: (M: unknown) => unknown) => (env: {
|
|
50
|
-
values: unknown;
|
|
51
|
-
functions: unknown;
|
|
52
|
-
}) => (s: string) => {
|
|
53
|
-
msg: string;
|
|
54
|
-
};
|
|
55
|
-
}>;
|
|
56
|
-
};
|
|
57
|
-
roamAlphaAPI: {
|
|
58
|
-
q: (query: string, ...params: unknown[]) => unknown[][];
|
|
59
|
-
pull: (selector: string, id: number | string | [string, string]) => PullBlock;
|
|
60
|
-
createBlock: WriteAction;
|
|
61
|
-
updateBlock: WriteAction;
|
|
62
|
-
createPage: WriteAction;
|
|
63
|
-
moveBlock: WriteAction;
|
|
64
|
-
deleteBlock: WriteAction;
|
|
65
|
-
updatePage: WriteAction;
|
|
66
|
-
deletePage: WriteAction;
|
|
67
|
-
util: {
|
|
68
|
-
generateUID: () => string;
|
|
69
|
-
dateToPageTitle: (date: Date) => string;
|
|
70
|
-
dateToPageUid: (date: Date) => string;
|
|
71
|
-
pageTitleToDate: (title: string) => Date | null;
|
|
72
|
-
uploadFile: (args: {
|
|
73
|
-
file: File;
|
|
74
|
-
}) => string;
|
|
75
|
-
};
|
|
76
|
-
data: {
|
|
77
|
-
addPullWatch: AddPullWatch;
|
|
78
|
-
block: {
|
|
79
|
-
create: WriteAction;
|
|
80
|
-
update: WriteAction;
|
|
81
|
-
move: WriteAction;
|
|
82
|
-
delete: WriteAction;
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
};
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
1
|
+
import { AddPullWatch, PullBlock, SidebarAction, SidebarWindow, SidebarWindowInput, WriteAction } from "./native";
|
|
2
|
+
import { RunQuery, ListActiveQueries, RunQuerySync, IsDiscourseNode } from "./query-builder";
|
|
3
|
+
import { RegisterCommand, UnregisterCommand } from "./smartblocks";
|
|
4
|
+
import type marked from "marked";
|
|
5
|
+
import type Markdown from "marked-react";
|
|
6
|
+
import type JSZip from "jszip";
|
|
7
|
+
import type cytoscape from "cytoscape";
|
|
8
|
+
export * from "./native";
|
|
9
|
+
export declare type Registry = {
|
|
10
|
+
elements: HTMLElement[];
|
|
11
|
+
reactRoots: HTMLElement[];
|
|
12
|
+
observers: MutationObserver[];
|
|
13
|
+
domListeners: ({
|
|
14
|
+
el: Window;
|
|
15
|
+
type: keyof WindowEventMap;
|
|
16
|
+
listener: (this: Window, ev: WindowEventMap[keyof WindowEventMap]) => void;
|
|
17
|
+
} | {
|
|
18
|
+
el: Document;
|
|
19
|
+
type: keyof DocumentEventMap;
|
|
20
|
+
listener: (this: Document, ev: DocumentEventMap[keyof DocumentEventMap]) => void;
|
|
21
|
+
} | {
|
|
22
|
+
el: HTMLElement;
|
|
23
|
+
type: keyof HTMLElementEventMap | `roamjs:${string}`;
|
|
24
|
+
listener: (this: HTMLElement, ev: HTMLElementEventMap[keyof HTMLElementEventMap]) => void;
|
|
25
|
+
})[];
|
|
26
|
+
commands: string[];
|
|
27
|
+
timeouts: {
|
|
28
|
+
timeout: number;
|
|
29
|
+
}[];
|
|
30
|
+
};
|
|
31
|
+
declare global {
|
|
32
|
+
interface Window {
|
|
33
|
+
RoamLazy?: {
|
|
34
|
+
JSZip: () => Promise<typeof JSZip>;
|
|
35
|
+
Marked: () => Promise<typeof marked>;
|
|
36
|
+
MarkedReact: () => Promise<typeof Markdown>;
|
|
37
|
+
Cytoscape: () => Promise<typeof cytoscape>;
|
|
38
|
+
Insect: () => Promise<{
|
|
39
|
+
commands: string[];
|
|
40
|
+
fmtConsole: (M: unknown) => unknown;
|
|
41
|
+
fmtJqueryTerminal: (M: unknown) => unknown;
|
|
42
|
+
fmtPlain: (M: unknown) => unknown;
|
|
43
|
+
functions: (M: unknown) => unknown;
|
|
44
|
+
identifiers: (M: unknown) => unknown;
|
|
45
|
+
initialEnvironment: {
|
|
46
|
+
values: unknown;
|
|
47
|
+
functions: unknown;
|
|
48
|
+
};
|
|
49
|
+
repl: (fmt: (M: unknown) => unknown) => (env: {
|
|
50
|
+
values: unknown;
|
|
51
|
+
functions: unknown;
|
|
52
|
+
}) => (s: string) => {
|
|
53
|
+
msg: string;
|
|
54
|
+
};
|
|
55
|
+
}>;
|
|
56
|
+
};
|
|
57
|
+
roamAlphaAPI: {
|
|
58
|
+
q: (query: string, ...params: unknown[]) => unknown[][];
|
|
59
|
+
pull: (selector: string, id: number | string | [string, string]) => PullBlock;
|
|
60
|
+
createBlock: WriteAction;
|
|
61
|
+
updateBlock: WriteAction;
|
|
62
|
+
createPage: WriteAction;
|
|
63
|
+
moveBlock: WriteAction;
|
|
64
|
+
deleteBlock: WriteAction;
|
|
65
|
+
updatePage: WriteAction;
|
|
66
|
+
deletePage: WriteAction;
|
|
67
|
+
util: {
|
|
68
|
+
generateUID: () => string;
|
|
69
|
+
dateToPageTitle: (date: Date) => string;
|
|
70
|
+
dateToPageUid: (date: Date) => string;
|
|
71
|
+
pageTitleToDate: (title: string) => Date | null;
|
|
72
|
+
uploadFile: (args: {
|
|
73
|
+
file: File;
|
|
74
|
+
}) => string;
|
|
75
|
+
};
|
|
76
|
+
data: {
|
|
77
|
+
addPullWatch: AddPullWatch;
|
|
78
|
+
block: {
|
|
79
|
+
create: WriteAction;
|
|
80
|
+
update: WriteAction;
|
|
81
|
+
move: WriteAction;
|
|
82
|
+
delete: WriteAction;
|
|
83
|
+
reorderBlocks: (args: {
|
|
84
|
+
location: {
|
|
85
|
+
"parent-uid": string;
|
|
86
|
+
};
|
|
87
|
+
blocks: string[];
|
|
88
|
+
}) => Promise<void>;
|
|
89
|
+
};
|
|
90
|
+
fast: {
|
|
91
|
+
q: (query: string, ...params: unknown[]) => unknown[][];
|
|
92
|
+
};
|
|
93
|
+
async: {
|
|
94
|
+
q: (query: string, ...params: unknown[]) => Promise<unknown[][]>;
|
|
95
|
+
pull: (selector: string, id: number | string | [string, string]) => Promise<PullBlock>;
|
|
96
|
+
pull_many: (pattern: string, eids: string[][]) => Promise<PullBlock[]>;
|
|
97
|
+
fast: {
|
|
98
|
+
q: (query: string, ...params: unknown[]) => Promise<unknown[][]>;
|
|
99
|
+
};
|
|
100
|
+
};
|
|
101
|
+
backend: {
|
|
102
|
+
q: (query: string, ...params: unknown[]) => Promise<unknown[][]>;
|
|
103
|
+
};
|
|
104
|
+
page: {
|
|
105
|
+
create: WriteAction;
|
|
106
|
+
update: WriteAction;
|
|
107
|
+
delete: WriteAction;
|
|
108
|
+
};
|
|
109
|
+
pull: (selector: string, id: number | string | [string, string]) => PullBlock;
|
|
110
|
+
pull_many: (pattern: string, eids: string[][]) => PullBlock[];
|
|
111
|
+
q: (query: string, ...params: unknown[]) => unknown[][];
|
|
112
|
+
removePullWatch: (pullPattern: string, entityId: string, callback?: (before: PullBlock, after: PullBlock) => void) => boolean;
|
|
113
|
+
redo: () => void;
|
|
114
|
+
undo: () => void;
|
|
115
|
+
user: {
|
|
116
|
+
upsert: () => void;
|
|
117
|
+
};
|
|
118
|
+
};
|
|
119
|
+
ui: {
|
|
120
|
+
leftSidebar: {
|
|
121
|
+
open: () => Promise<void>;
|
|
122
|
+
close: () => Promise<void>;
|
|
123
|
+
};
|
|
124
|
+
rightSidebar: {
|
|
125
|
+
open: () => Promise<void>;
|
|
126
|
+
close: () => Promise<void>;
|
|
127
|
+
getWindows: () => SidebarWindow[];
|
|
128
|
+
addWindow: SidebarAction;
|
|
129
|
+
setWindowOrder: SidebarAction;
|
|
130
|
+
collapseWindow: SidebarAction;
|
|
131
|
+
pinWindow: (action: {
|
|
132
|
+
window: SidebarWindowInput;
|
|
133
|
+
"pin-to-top?"?: boolean;
|
|
134
|
+
}) => Promise<void>;
|
|
135
|
+
expandWindow: SidebarAction;
|
|
136
|
+
removeWindow: SidebarAction;
|
|
137
|
+
unpinWindow: SidebarAction;
|
|
138
|
+
};
|
|
139
|
+
commandPalette: {
|
|
140
|
+
addCommand: (action: {
|
|
141
|
+
label: string;
|
|
142
|
+
callback: () => void;
|
|
143
|
+
"disable-hotkey"?: boolean;
|
|
144
|
+
"default-hotkey"?: string | string[];
|
|
145
|
+
}) => Promise<void>;
|
|
146
|
+
removeCommand: (action: {
|
|
147
|
+
label: string;
|
|
148
|
+
}) => Promise<void>;
|
|
149
|
+
};
|
|
150
|
+
blockContextMenu: {
|
|
151
|
+
addCommand: (action: {
|
|
152
|
+
label: string;
|
|
153
|
+
callback: (props: {
|
|
154
|
+
"block-string": string;
|
|
155
|
+
"block-uid": string;
|
|
156
|
+
heading: 0 | 1 | 2 | 3 | null;
|
|
157
|
+
"page-uid": string;
|
|
158
|
+
"read-only?": boolean;
|
|
159
|
+
"window-id": string;
|
|
160
|
+
}) => void;
|
|
161
|
+
}) => void;
|
|
162
|
+
removeCommand: (action: {
|
|
163
|
+
label: string;
|
|
164
|
+
}) => void;
|
|
165
|
+
};
|
|
166
|
+
individualMultiselect: {
|
|
167
|
+
getSelectedUids: () => string[];
|
|
168
|
+
};
|
|
169
|
+
msContextMenu: {
|
|
170
|
+
addCommand: (action: {
|
|
171
|
+
label: string;
|
|
172
|
+
callback: () => void;
|
|
173
|
+
"display-conditional"?: () => boolean;
|
|
174
|
+
}) => void;
|
|
175
|
+
removeCommand: (action: {
|
|
176
|
+
label: string;
|
|
177
|
+
}) => void;
|
|
178
|
+
};
|
|
179
|
+
filters: {
|
|
180
|
+
addGlobalFilter: (args: {
|
|
181
|
+
title: string;
|
|
182
|
+
type: "includes" | "removes";
|
|
183
|
+
}) => Promise<void>;
|
|
184
|
+
removeGlobalFilter: (args: {
|
|
185
|
+
title: string;
|
|
186
|
+
type: "includes" | "removes";
|
|
187
|
+
}) => Promise<void>;
|
|
188
|
+
getGlobalFilters: () => {
|
|
189
|
+
includes: string[];
|
|
190
|
+
removes: string[];
|
|
191
|
+
};
|
|
192
|
+
getPageFilters: (args: {
|
|
193
|
+
page: {
|
|
194
|
+
uid?: string;
|
|
195
|
+
title?: string;
|
|
196
|
+
};
|
|
197
|
+
}) => {
|
|
198
|
+
includes: string[];
|
|
199
|
+
removes: string[];
|
|
200
|
+
};
|
|
201
|
+
getPageLinkedRefsFilters: (args: {
|
|
202
|
+
page: {
|
|
203
|
+
uid?: string;
|
|
204
|
+
title?: string;
|
|
205
|
+
};
|
|
206
|
+
}) => {
|
|
207
|
+
includes: string[];
|
|
208
|
+
removes: string[];
|
|
209
|
+
};
|
|
210
|
+
getSidebarWindowFilters: (args: {
|
|
211
|
+
window: SidebarWindowInput;
|
|
212
|
+
}) => {
|
|
213
|
+
includes: string[];
|
|
214
|
+
removes: string[];
|
|
215
|
+
};
|
|
216
|
+
setPageFilters: (args: {
|
|
217
|
+
page: {
|
|
218
|
+
uid?: string;
|
|
219
|
+
title?: string;
|
|
220
|
+
};
|
|
221
|
+
filters: {
|
|
222
|
+
includes?: string[];
|
|
223
|
+
removes?: string[];
|
|
224
|
+
};
|
|
225
|
+
}) => Promise<void>;
|
|
226
|
+
setPageLinkedRefsFilters: (args: {
|
|
227
|
+
page: {
|
|
228
|
+
uid?: string;
|
|
229
|
+
title?: string;
|
|
230
|
+
};
|
|
231
|
+
filters: {
|
|
232
|
+
includes?: string[];
|
|
233
|
+
removes?: string[];
|
|
234
|
+
};
|
|
235
|
+
}) => Promise<void>;
|
|
236
|
+
setSidebarWindowFilters: (args: {
|
|
237
|
+
window: SidebarWindowInput;
|
|
238
|
+
filters: {
|
|
239
|
+
includes?: string[];
|
|
240
|
+
removes?: string[];
|
|
241
|
+
};
|
|
242
|
+
}) => Promise<void>;
|
|
243
|
+
};
|
|
244
|
+
getFocusedBlock: () => null | {
|
|
245
|
+
"window-id": string;
|
|
246
|
+
"block-uid": string;
|
|
247
|
+
};
|
|
248
|
+
components: {
|
|
249
|
+
renderBlock: (args: {
|
|
250
|
+
uid: string;
|
|
251
|
+
el: HTMLElement;
|
|
252
|
+
"zoom-path?"?: boolean;
|
|
253
|
+
}) => Promise<null>;
|
|
254
|
+
renderPage: (args: {
|
|
255
|
+
uid: string;
|
|
256
|
+
el: HTMLElement;
|
|
257
|
+
"hide-mentions?"?: boolean;
|
|
258
|
+
}) => Promise<null>;
|
|
259
|
+
renderSearch: (args: {
|
|
260
|
+
"search-query-str": string;
|
|
261
|
+
el: HTMLElement;
|
|
262
|
+
"closed?"?: boolean;
|
|
263
|
+
"group-by-page?"?: boolean;
|
|
264
|
+
"hide-paths?"?: boolean;
|
|
265
|
+
"config-changed-callback"?: (config: unknown) => void;
|
|
266
|
+
}) => Promise<null>;
|
|
267
|
+
renderString: (args: {
|
|
268
|
+
string: string;
|
|
269
|
+
el: HTMLElement;
|
|
270
|
+
}) => Promise<null>;
|
|
271
|
+
unmountNode: (args: {
|
|
272
|
+
el: HTMLElement;
|
|
273
|
+
}) => Promise<null>;
|
|
274
|
+
};
|
|
275
|
+
graphView: {
|
|
276
|
+
addCallback: (props: {
|
|
277
|
+
label: string;
|
|
278
|
+
callback: (context: {
|
|
279
|
+
cytoscape: unknown;
|
|
280
|
+
elements: unknown[];
|
|
281
|
+
type: "page" | "all-pages";
|
|
282
|
+
}) => void;
|
|
283
|
+
type?: "page" | "all-pages";
|
|
284
|
+
}) => Promise<void>;
|
|
285
|
+
removeCallback: (props: {
|
|
286
|
+
label: string;
|
|
287
|
+
}) => Promise<void>;
|
|
288
|
+
wholeGraph: {
|
|
289
|
+
addCallback: (props: {
|
|
290
|
+
label: string;
|
|
291
|
+
callback: (arg: {
|
|
292
|
+
"sigma-renderer": unknown;
|
|
293
|
+
}) => void;
|
|
294
|
+
}) => any;
|
|
295
|
+
removeCallback: (props: {
|
|
296
|
+
label: string;
|
|
297
|
+
}) => void;
|
|
298
|
+
setExplorePages: (pages: string[]) => void;
|
|
299
|
+
getExplorePages: () => string[];
|
|
300
|
+
setMode: (mode: "Whole Graph" | "Explore") => void;
|
|
301
|
+
};
|
|
302
|
+
};
|
|
303
|
+
mainWindow: {
|
|
304
|
+
focusFirstBlock: () => Promise<void>;
|
|
305
|
+
openBlock: (p: {
|
|
306
|
+
block: {
|
|
307
|
+
uid: string;
|
|
308
|
+
};
|
|
309
|
+
}) => Promise<void>;
|
|
310
|
+
openPage: (p: {
|
|
311
|
+
page: {
|
|
312
|
+
uid: string;
|
|
313
|
+
} | {
|
|
314
|
+
title: string;
|
|
315
|
+
};
|
|
316
|
+
}) => Promise<void>;
|
|
317
|
+
getOpenPageOrBlockUid: () => Promise<string | null>;
|
|
318
|
+
openDailyNotes: () => Promise<void>;
|
|
319
|
+
};
|
|
320
|
+
setBlockFocusAndSelection: (a: {
|
|
321
|
+
location?: {
|
|
322
|
+
"block-uid": string;
|
|
323
|
+
"window-id": string;
|
|
324
|
+
};
|
|
325
|
+
selection?: {
|
|
326
|
+
start: number;
|
|
327
|
+
end?: number;
|
|
328
|
+
};
|
|
329
|
+
}) => Promise<void>;
|
|
330
|
+
};
|
|
331
|
+
platform: {
|
|
332
|
+
isDesktop: boolean;
|
|
333
|
+
isIOS: boolean;
|
|
334
|
+
isMobile: boolean;
|
|
335
|
+
isMobileApp: boolean;
|
|
336
|
+
isPC: boolean;
|
|
337
|
+
isTouchDevice: boolean;
|
|
338
|
+
};
|
|
339
|
+
graph: {
|
|
340
|
+
name: string;
|
|
341
|
+
type: "hosted" | "offline";
|
|
342
|
+
isEncrypted: boolean;
|
|
343
|
+
};
|
|
344
|
+
file: {
|
|
345
|
+
upload: (args: {
|
|
346
|
+
file: File;
|
|
347
|
+
toast?: {
|
|
348
|
+
hide: boolean;
|
|
349
|
+
};
|
|
350
|
+
}) => Promise<string>;
|
|
351
|
+
get: (args: {
|
|
352
|
+
url: string;
|
|
353
|
+
}) => Promise<File>;
|
|
354
|
+
delete: (args: {
|
|
355
|
+
url: string;
|
|
356
|
+
}) => Promise<void>;
|
|
357
|
+
};
|
|
358
|
+
user: {
|
|
359
|
+
uid: () => string | null;
|
|
360
|
+
};
|
|
361
|
+
constants: {
|
|
362
|
+
corsAnywhereProxyUrl: string;
|
|
363
|
+
};
|
|
364
|
+
};
|
|
365
|
+
roamjs: {
|
|
366
|
+
loaded: Set<string>;
|
|
367
|
+
extension: {
|
|
368
|
+
queryBuilder?: {
|
|
369
|
+
runQuery: RunQuery;
|
|
370
|
+
runQuerySync: RunQuerySync;
|
|
371
|
+
listActiveQueries: ListActiveQueries;
|
|
372
|
+
isDiscourseNode: IsDiscourseNode;
|
|
373
|
+
};
|
|
374
|
+
smartblocks?: {
|
|
375
|
+
registerCommand: RegisterCommand;
|
|
376
|
+
unregisterCommand: UnregisterCommand;
|
|
377
|
+
triggerSmartblock: (args: {
|
|
378
|
+
srcName?: string;
|
|
379
|
+
srcUid?: string;
|
|
380
|
+
targetName?: string;
|
|
381
|
+
targetUid?: string;
|
|
382
|
+
variables?: Record<string, string>;
|
|
383
|
+
}) => Promise<unknown>;
|
|
384
|
+
};
|
|
385
|
+
[id: string]: Record<string, unknown> | undefined;
|
|
386
|
+
};
|
|
387
|
+
version: {
|
|
388
|
+
[id: string]: string;
|
|
389
|
+
};
|
|
390
|
+
actions: Record<string, number>;
|
|
391
|
+
};
|
|
392
|
+
}
|
|
393
|
+
}
|
package/types/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const tslib_1 = require("tslib");
|
|
4
|
-
tslib_1.__exportStar(require("./native"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const tslib_1 = require("tslib");
|
|
4
|
+
tslib_1.__exportStar(require("./native"), exports);
|
|
5
5
|
//# sourceMappingURL=index.js.map
|