mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
Refactor: e -> event or error, err -> error, p -> pointer (#831)
* Refactor: e -> event or error, err -> error, p -> pointer * simplify
This commit is contained in:
parent
d2827aa40b
commit
097c5dfad7
14 changed files with 190 additions and 185 deletions
|
@ -31,9 +31,7 @@ export const actionChangeExportBackground: Action = {
|
|||
<input
|
||||
type="checkbox"
|
||||
checked={appState.exportBackground}
|
||||
onChange={e => {
|
||||
updateData(e.target.checked);
|
||||
}}
|
||||
onChange={event => updateData(event.target.checked)}
|
||||
/>{" "}
|
||||
{t("labels.withBackground")}
|
||||
</label>
|
||||
|
@ -43,7 +41,7 @@ export const actionChangeExportBackground: Action = {
|
|||
export const actionSaveScene: Action = {
|
||||
name: "saveScene",
|
||||
perform: (elements, appState, value) => {
|
||||
saveAsJSON(elements, appState).catch(err => console.error(err));
|
||||
saveAsJSON(elements, appState).catch(error => console.error(error));
|
||||
return {};
|
||||
},
|
||||
PanelComponent: ({ updateData }) => (
|
||||
|
@ -79,7 +77,7 @@ export const actionLoadScene: Action = {
|
|||
.then(({ elements, appState }) => {
|
||||
updateData({ elements: elements, appState: appState });
|
||||
})
|
||||
.catch(err => console.error(err));
|
||||
.catch(error => console.error(error));
|
||||
}}
|
||||
/>
|
||||
),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue