enso/app/gui2/stories/ComponentBrowser.story.vue
Paweł Grabarz b286adaae4
Split ydoc server into separate module (#10735)
# Important Notes
The command to run the gui dev environment has been changed. Invoking the old command will print a message about that.
From now on, use `pnpm dev:gui2` in repository root.
2024-08-08 12:12:05 +00:00

44 lines
1.2 KiB
Vue

<script setup lang="ts">
import { logEvent } from 'histoire/client'
import ComponentBrowser from '@/components/ComponentBrowser.vue'
import { Usage } from '@/components/ComponentBrowser/input'
import { useSuggestionDbStore } from '@/stores/suggestionDatabase'
import { Vec2 } from '@/util/data/vec2'
import GroupColorsWrapper from './GroupColorsWrapper.vue'
import NavigatorWrapper from './NavigatorWrapper.vue'
const position = new Vec2(-329.5, 0)
const usage: Usage = { type: 'newNode' }
</script>
<template>
<Story
title="Component Browser"
group="graph"
:layout="{ type: 'single', iframe: false }"
:setupApp="
() => {
useSuggestionDbStore()
}
"
responsiveDisabled
autoPropsDisabled
>
<NavigatorWrapper style="height: 100%">
<template #default="{ navigator }">
<GroupColorsWrapper>
<ComponentBrowser
:nodePosition="position"
:navigator="navigator"
:usage="usage"
:sourcePort="null"
:initialCaretPosition="[0, 0]"
@finished="logEvent('finished', [])"
/>
</GroupColorsWrapper>
</template>
</NavigatorWrapper>
</Story>
</template>