From edc23b854f9e45c0e03b280cef158970499f99e3 Mon Sep 17 00:00:00 2001 From: Aakansha Doshi Date: Sat, 20 Mar 2021 13:41:12 +0530 Subject: [PATCH] minor fixes --- src/packages/excalidraw/CHANGELOG.md | 2 +- src/packages/excalidraw/README.md | 2 +- src/tests/excalidrawPackage.test.tsx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/packages/excalidraw/CHANGELOG.md b/src/packages/excalidraw/CHANGELOG.md index fdcd1a815..647927541 100644 --- a/src/packages/excalidraw/CHANGELOG.md +++ b/src/packages/excalidraw/CHANGELOG.md @@ -18,7 +18,7 @@ Please add the latest change on the top under the correct section. ### Features -- Add `name` prop which allows changing the export name. When this prop is passed, the name is fully controlled by host and will become unediable in the export modal [#3273](https://github.com/excalidraw/excalidraw/pull/3273). +- Add `name` prop which indicates the name of the drawing which will be used when exporting the drawing. When supplied, the value takes precedence over `intialData.appState.name`, the `name` will be fully controlled by host app and the users won't be able to edit from within Excalidraw [#3273](https://github.com/excalidraw/excalidraw/pull/3273). - Export API to export the drawing to canvas, svg and blob [#3258](https://github.com/excalidraw/excalidraw/pull/3258). For more info you can check the [readme](https://github.com/excalidraw/excalidraw/tree/master/src/packages/excalidraw/README.md#user-content-export-utils) - Add a `theme` prop to indicate Excalidraw's theme. [#3228](https://github.com/excalidraw/excalidraw/pull/3228). When this prop is passed, the theme is fully controlled by host app. - Support `libraryReturnUrl` prop to indicate what URL to install libraries to [#3227](https://github.com/excalidraw/excalidraw/pull/3227). diff --git a/src/packages/excalidraw/README.md b/src/packages/excalidraw/README.md index 309c5119c..8e9702c76 100644 --- a/src/packages/excalidraw/README.md +++ b/src/packages/excalidraw/README.md @@ -546,7 +546,7 @@ This prop controls Excalidraw's theme. When supplied, the value takes precedence ### `name` -This prop sets the export name of the drawing. When supplied, the value takes precedence over `intialData.appState.name`. +This prop sets the name of the drawing which will be used when exporting the drawing. When supplied, the value takes precedence over `intialData.appState.name`, the `name` will be fully controlled by host app and the users won't be able to edit from within Excalidraw. ### Extra API's diff --git a/src/tests/excalidrawPackage.test.tsx b/src/tests/excalidrawPackage.test.tsx index d8dc83661..b2dcbe198 100644 --- a/src/tests/excalidrawPackage.test.tsx +++ b/src/tests/excalidrawPackage.test.tsx @@ -116,7 +116,7 @@ describe("", () => { expect(name?.hasAttribute("data-type")).toBe(true); }); - it('should not allow editing the export name when the name prop is not "undefined"', async () => { + it('should not allow editing the export name when the name prop is present"', async () => { const { container } = await render(); fireEvent.click(queryByTestId(container, "export-button")!);