text cell view

This commit is contained in:
Jan Prochazka 2021-03-25 20:17:25 +01:00
parent 6c5f5a7cfb
commit 4c87ad50b1
4 changed files with 12 additions and 4 deletions

View File

@ -0,0 +1,6 @@
<script lang="ts">
export let selection;
export let wrap;
</script>
<textarea class="flex1" {wrap} readonly value={selection.map(cell => cell.value).join('\n')} />

View File

@ -1,5 +1,6 @@
<script lang="ts">
import TextCellView from './TextCellView.svelte';
export let selection;
</script>
<textarea class="flex1" wrap="no" readonly value={selection[0].value} />
<TextCellView wrap="no" {selection} />

View File

@ -1,5 +1,6 @@
<script lang="ts">
import TextCellView from './TextCellView.svelte';
export let selection;
</script>
<textarea class="flex1" wrap="hard" readonly value={selection[0].value} />
<TextCellView wrap="hard" {selection} />

View File

@ -4,13 +4,13 @@
type: 'textWrap',
title: 'Text (wrap)',
component: TextCellViewWrap,
single: true,
single: false,
},
{
type: 'text',
title: 'Text (no wrap)',
component: TextCellViewNoWrap,
single: true,
single: false,
},
{
type: 'json',