Commit Graph

120 Commits

Author SHA1 Message Date
Charlie
3c2359a79e enhance(plugins): libs improvements (#12588)
* enhance(libs): add Commands proxy and unified command APIs

* enhance(plugin): improve unregistering of simple and palette commands

* enhance(plugin): add unregister functionality for plugin commands

* chore(libs): add logseq.Commands API guide and implementation

* enhance(libs): introduce LSPluginNet for HTTP client functionality

* fix(ipc): ensure proper handling of IPC messages and improve plugin call structure

* enhance(libs): add HTTP methods (GET, HEAD, POST, PUT, PATCH, DELETE) and error handling

* enhance(api): support additional identifier types for opening blocks in sidebar

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Tienson Qin <tiensonqin@gmail.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-05-07 15:21:48 +08:00
Charlie
a95483655b refactor: plugin libs (#12395)
This pull request refactors the plugin library infrastructure and adds new experimental features for hosted/sidebar renderers. The main changes include:

Purpose: Refactor plugin communication library (Postmate) to support MessageChannel for improved performance, add support for hosted/sidebar renderers in plugins, add new debug APIs, and consolidate helper functions.

Changes:

Added MessageChannel support to Postmate for optimized plugin-host communication with backward compatibility
Introduced hosted renderer and sidebar renderer APIs for plugins to register custom UI components
Added new app APIs: get_current_route, export_debug_log_db, reset_debug_log_db
Refactored helper functions from helpers.ts to common.ts and updated all import paths
Extended block property APIs to include class properties with default values
Added comprehensive documentation for experiments APIs and plugin development
Added E2E test for plugin marketplace installation
Version bump from 0.2.12 to 0.3.1
2026-04-14 14:29:22 +08:00
charlie
110084e4ba enhance(apis): add today page 2026-01-19 15:35:05 +08:00
charlie
af51223ff6 enhance(apis): add setPropertyNodeTags function for managing property tags 2026-01-17 15:05:35 +08:00
charlie
e94959690d enhance(api): managing property choice values 2026-01-16 18:16:16 +08:00
charlie
23c6f81010 enhance(libs): add get_file_content function for retrieving file content 2026-01-06 12:42:29 +08:00
charlie
74bfe36d8f enhance(libs): update IDBProxy interface and improve documentation 2026-01-06 11:05:08 +08:00
charlie
8d7aaa791e enhance(apis): add setFileContent method for built-in file paths 2026-01-06 10:49:31 +08:00
charlie
baff8a4cc1 enhance(apis): add support for tag properties in createTag API 2026-01-03 21:51:23 +08:00
charlie
460eefb960 enhance(apis): add reset option to upsertBlockProperty for block properties 2026-01-01 17:49:24 +08:00
Tienson Qin
bcc478b5f7 refactor: separate og and db version (#12276)
separate og and new version apps

remove file sync, tldraw, excalidraw and zotero
2025-12-29 15:39:32 +08:00
Charlie
fbe6b998b6 enhance(plugins): apis related improvements (#12266) 2025-12-25 13:25:12 +08:00
charlie
dc4c712089 enhance(apis): add note for setBlockIcon method 2025-12-10 14:49:29 +08:00
charlie
e5903e1c21 enhance(apis): add tag related apis 2025-12-09 16:31:25 +08:00
Sal Rahman
2dd0193166 Fix: update logseq.Editor.getPageBlocksTree's return type. (#12212)
Changes the logseq.Editor.getPageBlocksTree's return type from
Promise<Array<BlockEntity>> to Promise<Array<BlockEntity> | null>.

Closes #12211.

Co-authored-by: Charlie <xyhp915@qq.com>
2025-11-25 09:57:07 +08:00
Tienson Qin
0a54e807bb enhance(api): plugin class with ident like plugin.class.id/class-name (#12200)
* enhance(api): plugin class with ident like `plugin.class.id/class-name`
* enhance(apis): remove support for namespace separator in create tag
* enhance(apis): get tag with ident or uuid
* fix(lint): remove unused vars
* fix(apis): sanitize user property name
* enhance(apis): get tag ex info
* chore: bump libs version
---------
Co-authored-by: charlie <xyhp915@qq.com>
2025-11-14 10:48:08 +08:00
charlie
bd4b022a08 enhance(apis): enhance createTag function to accept options for custom UUID 2025-11-06 15:46:31 +08:00
charlie
96ffb4d16d enhance(apis): rename tag property functions for consistency 2025-11-06 14:12:00 +08:00
charlie
0046fff9a2 enhance(apis): types 2025-11-06 11:46:04 +08:00
charlie
9eb65b473e enhance(apis): rename tag functions to block tag for clarity and update version 2025-11-05 17:02:38 +08:00
charlie
51fbc705de enhance(apis): add create, add, and remove tag functions 2025-11-05 15:43:33 +08:00
charlie
28bc28ecd3 enhance(apis): support custom uuid to create page 2025-10-30 21:38:04 +08:00
charlie
501230b0d3 enhance(plugin): support development entry for plugins 2025-10-29 18:36:01 +08:00
Tienson Qin
8efd79ece9 add new apis to js sdk 2025-10-20 18:33:01 +08:00
Tienson Qin
3cc530a16f refactor(plugins): separate file graph apis 2025-10-07 21:26:23 +08:00
Charlie
2809f78574 fix(plugin): api types 2025-09-25 13:22:17 +08:00
charlie
2236f3fc14 enhance(api): add get_page_properties function and update related tests 2025-09-05 11:48:42 +08:00
charlie
89c5e61daf fix(apis): types & incorrect property key for plugin caller 2025-06-26 17:15:38 +08:00
charlie
e362cfa0ae enhance(plugins): types 2025-03-20 10:44:23 +08:00
charlie
03592a26b6 chore: typo 2025-01-14 17:51:53 +08:00
charlie
9224df59cc enhance(apis): add remove property & types 2025-01-14 17:51:15 +08:00
charlie
99998e25e9 enhance(libs): utils apis 2025-01-09 17:35:55 +08:00
charlie
72c09e5c30 enhance(libs): types 2025-01-09 14:22:30 +08:00
charlie
25adb80b96 enhance(plugin): app proxy call 2025-01-06 17:34:03 +08:00
charlie
87e01f116b enhance(apis): add types 2025-01-06 15:54:21 +08:00
charlie
27b9f6b5c6 enhance(api): WIP adjust property related APIs 2024-09-14 16:05:38 +08:00
charlie
e05dc085a2 fix(plugin): incorrect normalize data case for the hashmap value 2024-09-05 20:12:45 +08:00
charlie
fccef5e904 enhance(plugin): api types for the property entity 2024-09-05 17:12:17 +08:00
charlie
35a2c8ec40 enhance(plugin): api types 2024-09-03 11:14:21 +08:00
charlie
b755369a0b enhance(apis): get blocks from batch blocks insertion 2024-08-15 17:26:51 +08:00
charlie
7209540fe2 fix(api): compatible block content/title for the classic APIs 2024-07-31 12:05:44 +08:00
charlie
73757c0f21 enhance(api): enhancements & types 2024-06-21 09:57:05 +08:00
charlie
bdfda0b9db enhance(api): block related types 2024-06-04 15:32:09 +08:00
charlie
de9940dc9b enhance(plugin): more args extensible for the exported editor component 2024-04-09 23:30:36 +08:00
Charlie
7db164ab47 Enhance: APIs related issues (#10782)
* fix(plugins): load unpacked package for the existed plugin

* enhance(plugin): increase timeout time for the plugin handshake

* enhance(api): support option to insert block with auto ordered list

* fix(api): skip empty target for the batch insertion blocks

* fix(api): before option for the batch blocks insertion

* enhance(api): types

* chore: bump minor version

* fix(apis): Empty `payload.uuid` when executing onMacroRendererSlotted inside query table
2024-01-16 15:47:56 +08:00
Charlie
036df25a17 Enhance: plugin APIs (#10399)
* enhance(plugin): call apis with the sdk ns

* enhance(plugin): types

* enhance(api): get value from the computed style

* enhance(api): types

* enhance(plugin): types

* enhance(plugin): types

* fix: lint

* fix(apis): incorrect shortcut command registion for block editing mode #10392

* fix(api): types

* enhance(apis): support register shortcuts with multi binding vals

* fix(plugins): normalize command key to make the internal keyword legal

* chore(plugin): build libs core

* chore(plugin): bump version

* enhance(apis): normalize apis cljs data

* chore(plugin): update libs user sdk

* chore(plugin): CHANGELOG.md

* fix: typo

* fix(ux): support querying plugins with right space chars
2023-12-13 15:42:21 +08:00
Tienson Qin
88acf53303 fix: lint warnings 2023-11-13 22:59:34 +08:00
Tienson Qin
b91fd4e6c8 Remove old cmdk && command palette 2023-11-06 15:25:35 +08:00
hkgnp
1c0e18daaa chore: add marker prop to BlockEntity interface 2023-10-05 11:08:53 +09:00
Charlie
331afbc04f Enhance/plugins apis (#10127)
* enhance(api): add page to recent for route api

* enhance(api): support open block in right sidebar with entity id
2023-09-06 14:49:18 +00:00