From 2a93a1fb26ec1668d2eeabb491712502bd2046e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Keviin=20=C3=85berg=20Kultalahti?= Date: Mon, 1 Mar 2021 17:37:17 +0100 Subject: [PATCH] remove unused code in NavigationPanel --- .../design/NavigationPanel/ComponentDropdownMenu.svelte | 7 ------- .../design/NavigationPanel/NewScreenModal.svelte | 1 - 2 files changed, 8 deletions(-) diff --git a/packages/builder/src/components/design/NavigationPanel/ComponentDropdownMenu.svelte b/packages/builder/src/components/design/NavigationPanel/ComponentDropdownMenu.svelte index 665f09ad61..23d9d40228 100644 --- a/packages/builder/src/components/design/NavigationPanel/ComponentDropdownMenu.svelte +++ b/packages/builder/src/components/design/NavigationPanel/ComponentDropdownMenu.svelte @@ -2,7 +2,6 @@ import { get } from "svelte/store" import { store, currentAsset } from "builderStore" import ConfirmDialog from "components/common/ConfirmDialog.svelte" - import { last } from "lodash/fp" import { findComponentParent } from "builderStore/storeUtils" import { DropdownMenu } from "@budibase/bbui" import { DropdownContainer, DropdownItem } from "components/common/Dropdowns" @@ -17,16 +16,10 @@ $: noChildrenAllowed = !component || !definition?.hasChildren $: noPaste = !$store.componentToPaste - const lastPartOfName = c => (c ? last(c._component.split("/")) : "") - const hideDropdown = () => { dropdown.hide() } - const selectComponent = component => { - store.actions.components.select(component) - } - const moveUpComponent = () => { const asset = get(currentAsset) const parent = findComponentParent(asset.props, component._id) diff --git a/packages/builder/src/components/design/NavigationPanel/NewScreenModal.svelte b/packages/builder/src/components/design/NavigationPanel/NewScreenModal.svelte index c33d12c1a1..379144367f 100644 --- a/packages/builder/src/components/design/NavigationPanel/NewScreenModal.svelte +++ b/packages/builder/src/components/design/NavigationPanel/NewScreenModal.svelte @@ -31,7 +31,6 @@ const templateChanged = newTemplateIndex => { if (newTemplateIndex === undefined) return - const template = templates[newTemplateIndex] draftScreen = templates[newTemplateIndex].create() if (draftScreen.props._instanceName) { name = draftScreen.props._instanceName