@budibase/frontend-core 2.7.34-alpha.4 → 2.7.34-alpha.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/api/analytics.js +2 -2
- package/src/api/index.js +16 -2
- package/src/api/rows.js +3 -1
- package/src/components/grid/cells/AttachmentCell.svelte +3 -1
- package/src/components/grid/cells/GridCell.svelte +1 -1
- package/src/components/grid/cells/GutterCell.svelte +9 -14
- package/src/components/grid/cells/HeaderCell.svelte +7 -5
- package/src/components/grid/cells/LongFormCell.svelte +1 -1
- package/src/components/grid/cells/OptionsCell.svelte +4 -5
- package/src/components/grid/cells/RelationshipCell.svelte +22 -11
- package/src/components/grid/controls/AddColumnButton.svelte +1 -1
- package/src/components/grid/controls/BulkDeleteHandler.svelte +2 -8
- package/src/components/grid/controls/HideColumnsButton.svelte +9 -4
- package/src/components/grid/controls/SizeButton.svelte +135 -0
- package/src/components/grid/controls/SortButton.svelte +3 -4
- package/src/components/grid/layout/Grid.svelte +66 -59
- package/src/components/grid/layout/GridBody.svelte +3 -2
- package/src/components/grid/layout/GridRow.svelte +3 -2
- package/src/components/grid/layout/GridScrollWrapper.svelte +6 -0
- package/src/components/grid/layout/HeaderRow.svelte +3 -3
- package/src/components/grid/layout/NewRow.svelte +37 -5
- package/src/components/grid/layout/StickyColumn.svelte +10 -8
- package/src/components/grid/lib/constants.js +4 -3
- package/src/components/grid/lib/websocket.js +3 -2
- package/src/components/grid/overlays/KeyboardManager.svelte +6 -0
- package/src/components/grid/overlays/MenuOverlay.svelte +3 -1
- package/src/components/grid/overlays/ReorderOverlay.svelte +1 -1
- package/src/components/grid/overlays/ResizeOverlay.svelte +1 -1
- package/src/components/grid/overlays/ScrollOverlay.svelte +25 -2
- package/src/components/grid/stores/columns.js +37 -6
- package/src/components/grid/stores/config.js +27 -0
- package/src/components/grid/stores/filter.js +19 -0
- package/src/components/grid/stores/index.js +6 -0
- package/src/components/grid/stores/menu.js +15 -9
- package/src/components/grid/stores/rows.js +18 -16
- package/src/components/grid/stores/scroll.js +5 -7
- package/src/components/grid/stores/sort.js +27 -0
- package/src/components/grid/stores/ui.js +19 -4
- package/src/components/grid/stores/viewport.js +17 -6
- package/src/fetch/DataFetch.js +4 -2
- package/src/utils/index.js +1 -0
- package/src/utils/memo.js +43 -0
- package/src/components/grid/controls/ColumnWidthButton.svelte +0 -92
- package/src/components/grid/controls/RowHeightButton.svelte +0 -71
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
<script>
|
|
2
|
-
import { getContext } from "svelte"
|
|
3
|
-
import { ActionButton, Popover } from "@budibase/bbui"
|
|
4
|
-
import {
|
|
5
|
-
LargeRowHeight,
|
|
6
|
-
MediumRowHeight,
|
|
7
|
-
SmallRowHeight,
|
|
8
|
-
} from "../lib/constants"
|
|
9
|
-
|
|
10
|
-
const { rowHeight, columns, table, compact } = getContext("grid")
|
|
11
|
-
const sizeOptions = [
|
|
12
|
-
{
|
|
13
|
-
label: "Small",
|
|
14
|
-
size: SmallRowHeight,
|
|
15
|
-
},
|
|
16
|
-
{
|
|
17
|
-
label: "Medium",
|
|
18
|
-
size: MediumRowHeight,
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
label: "Large",
|
|
22
|
-
size: LargeRowHeight,
|
|
23
|
-
},
|
|
24
|
-
]
|
|
25
|
-
|
|
26
|
-
let open = false
|
|
27
|
-
let anchor
|
|
28
|
-
|
|
29
|
-
const changeRowHeight = height => {
|
|
30
|
-
columns.actions.saveTable({
|
|
31
|
-
...$table,
|
|
32
|
-
rowHeight: height,
|
|
33
|
-
})
|
|
34
|
-
}
|
|
35
|
-
</script>
|
|
36
|
-
|
|
37
|
-
<div bind:this={anchor}>
|
|
38
|
-
<ActionButton
|
|
39
|
-
icon="MoveUpDown"
|
|
40
|
-
quiet
|
|
41
|
-
size="M"
|
|
42
|
-
on:click={() => (open = !open)}
|
|
43
|
-
selected={open}
|
|
44
|
-
tooltip={$compact ? "Height" : null}
|
|
45
|
-
>
|
|
46
|
-
{$compact ? "" : "Height"}
|
|
47
|
-
</ActionButton>
|
|
48
|
-
</div>
|
|
49
|
-
|
|
50
|
-
<Popover bind:open {anchor} align={$compact ? "right" : "left"}>
|
|
51
|
-
<div class="content">
|
|
52
|
-
{#each sizeOptions as option}
|
|
53
|
-
<ActionButton
|
|
54
|
-
quiet
|
|
55
|
-
selected={$rowHeight === option.size}
|
|
56
|
-
on:click={() => changeRowHeight(option.size)}
|
|
57
|
-
>
|
|
58
|
-
{option.label}
|
|
59
|
-
</ActionButton>
|
|
60
|
-
{/each}
|
|
61
|
-
</div>
|
|
62
|
-
</Popover>
|
|
63
|
-
|
|
64
|
-
<style>
|
|
65
|
-
.content {
|
|
66
|
-
padding: 12px;
|
|
67
|
-
display: flex;
|
|
68
|
-
align-items: center;
|
|
69
|
-
gap: 8px;
|
|
70
|
-
}
|
|
71
|
-
</style>
|