@fraczled/sdk 1.30.1 → 1.30.2

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/README.md CHANGED
@@ -72,6 +72,7 @@ interface EditorConfig {
72
72
  ui?: {
73
73
  hideDefaultPanels?: boolean;
74
74
  hiddenPanels?: PanelId[];
75
+ topbarMode?: 'default' | 'custom';
75
76
  };
76
77
  customPanels?: CustomSidebarPanel[];
77
78
  }
@@ -200,6 +201,29 @@ Notes:
200
201
  - `feature` maps to `entitlements.features[feature]` and controls visibility/access based on licensing.
201
202
  - `render` is called when the panel is active, so you can wire buttons directly to `store` methods or read from `state`.
202
203
 
204
+ ### Custom topbar actions (SDK only)
205
+
206
+ You can replace the default topbar actions (save/new/export/undo/redo/zoom) with your own UI:
207
+
208
+ ```ts
209
+ createFraczledEditor({
210
+ apiKey: "YOUR_LICENSE_KEY",
211
+ projectId: "YOUR_PROJECT_ID",
212
+ container: document.getElementById("editor"),
213
+ ui: { topbarMode: "custom" },
214
+ customToolbarItems: [
215
+ {
216
+ id: "my-topbar:action",
217
+ label: "My Action",
218
+ location: "topbar",
219
+ onClick: ({ topbar }) => topbar?.onExport?.("web")
220
+ }
221
+ ]
222
+ });
223
+ ```
224
+
225
+ Note: `ui.topbarMode = "custom"` is gated by the `topbarActions` plan feature.
226
+
203
227
  ### Hide built-in tabs (SDK only)
204
228
 
205
229
  You can hide vanilla sidebar tabs in SDK embeds:
@@ -1,6 +1,6 @@
1
1
  import "react";
2
2
  import "react-dom/client";
3
- import { S as o, b as p, a as c, d } from "./index-CXZBVuuc.js";
3
+ import { S as o, b as p, a as c, d } from "./index-H9Vygg46.js";
4
4
  export {
5
5
  o as Store,
6
6
  p as createFraczledEditor,