1
0
Fork 0
mirror of synced 2024-06-25 17:40:38 +12:00

Replace old usage of 'editable' manifest setting with 'static'

This commit is contained in:
Andrew Kingston 2021-11-16 18:33:14 +00:00
parent 53c7da348b
commit c309db623e
2 changed files with 8 additions and 2 deletions

View file

@ -13,6 +13,12 @@
$: noChildrenAllowed = !component || !definition?.hasChildren
$: noPaste = !$store.componentToPaste
// "editable" has been repurposed for inline text editing.
// It remains here for legacy compatibility.
// Future components should define "static": true for indicate they should
// not show a context menu.
$: showMenu = definition?.editable !== false && definition?.static !== true
const moveUpComponent = () => {
const asset = get(currentAsset)
const parent = findComponentParent(asset.props, component._id)
@ -69,7 +75,7 @@
}
</script>
{#if definition?.editable !== false}
{#if showMenu}
<ActionMenu>
<div slot="control" class="icon">
<Icon size="S" hoverable name="MoreSmallList" />

View file

@ -240,7 +240,7 @@
"name": "Screenslot",
"icon": "WebPage",
"description": "Contains your app screens",
"editable": false
"static": true
},
"button": {
"name": "Button",