diff --git a/.codesandbox/tasks.json b/.codesandbox/tasks.json new file mode 100644 index 000000000..360636c4c --- /dev/null +++ b/.codesandbox/tasks.json @@ -0,0 +1,43 @@ +{ + // These tasks will run in order when initializing your CodeSandbox project. + "setupTasks": [ + { + "name": "Install Dependencies", + "command": "yarn install" + } + ], + + // These tasks can be run from CodeSandbox. Running one will open a log in the app. + "tasks": { + "build": { + "name": "Build", + "command": "yarn build", + "runAtStart": false + }, + "fix": { + "name": "Fix", + "command": "yarn fix", + "runAtStart": false + }, + "prettier": { + "name": "Prettify", + "command": "yarn prettier", + "runAtStart": false + }, + "start": { + "name": "Start Excalidraw", + "command": "yarn start", + "runAtStart": true + }, + "test": { + "name": "Run Tests", + "command": "yarn test", + "runAtStart": false + }, + "install-deps": { + "name": "Install Dependencies", + "command": "yarn install", + "restartOn": { "files": ["yarn.lock"] } + } + } +} diff --git a/README.md b/README.md index 51f706382..45fec41ba 100644 --- a/README.md +++ b/README.md @@ -88,7 +88,7 @@ Try out [`@excalidraw/excalidraw`](https://www.npmjs.com/package/@excalidraw/exc ### Code Sandbox -- Go to https://codesandbox.io/s/github/excalidraw/excalidraw +- Go to https://codesandbox.io/p/github/excalidraw/excalidraw - You may need to sign in with GitHub and reload the page - You can start coding instantly, and even send PRs from there! diff --git a/src/actions/actionExport.tsx b/src/actions/actionExport.tsx index 015e52162..a566e5bf9 100644 --- a/src/actions/actionExport.tsx +++ b/src/actions/actionExport.tsx @@ -244,7 +244,7 @@ export const actionLoadScene = register({ } }, keyTest: (event) => event[KEYS.CTRL_OR_CMD] && event.key === KEYS.O, - PanelComponent: ({ updateData, appState }) => ( + PanelComponent: ({ updateData }) => ( { diff --git a/src/components/ColorPicker.tsx b/src/components/ColorPicker.tsx index 76a66b5bf..22f9eb267 100644 --- a/src/components/ColorPicker.tsx +++ b/src/components/ColorPicker.tsx @@ -343,6 +343,8 @@ const ColorInput = React.forwardRef( }, ); +ColorInput.displayName = "ColorInput"; + export const ColorPicker = ({ type, color, diff --git a/src/components/Footer.tsx b/src/components/Footer.tsx index 297a2124d..420aeb6a8 100644 --- a/src/components/Footer.tsx +++ b/src/components/Footer.tsx @@ -88,6 +88,13 @@ const Footer = ({ > {renderCustomFooter?.(false, appState)} +
+ {actionManager.renderAction("toggleShortcuts")} +
{appState.isLoading && } {appState.errorMessage && ( @@ -409,84 +409,81 @@ const LayerUI = ({ } /> )} - - ); - - return device.isMobile ? ( - <> - {dialogs} - onLockToggle()} - onPenModeToggle={onPenModeToggle} - canvas={canvas} - isCollaborating={isCollaborating} - renderCustomFooter={renderCustomFooter} - showThemeBtn={showThemeBtn} - onImageAction={onImageAction} - renderTopRightUI={renderTopRightUI} - renderCustomStats={renderCustomStats} - /> - - ) : ( - <> -
- {dialogs} - {renderFixedSideContainer()} -
onLockToggle()} + onPenModeToggle={onPenModeToggle} + canvas={canvas} + isCollaborating={isCollaborating} renderCustomFooter={renderCustomFooter} - showExitZenModeBtn={showExitZenModeBtn} + showThemeBtn={showThemeBtn} + onImageAction={onImageAction} + renderTopRightUI={renderTopRightUI} + renderCustomStats={renderCustomStats} /> - {appState.showStats && ( - { - actionManager.executeAction(actionToggleStats); - }} - renderCustomStats={renderCustomStats} - /> - )} - {appState.scrolledOutside && ( - - )} -
- {appState.isLibraryOpen && ( -
{libraryMenu}
+ {renderFixedSideContainer()} +