Skip to content
Snippets Groups Projects
Commit 9374568a authored by Julian's avatar Julian
Browse files

Write docs for the multipleItemsY feature

parent cc4c5998
No related branches found
No related tags found
1 merge request!11Overlapping items in a column
Pipeline #141882 passed
......@@ -15,6 +15,7 @@ module.exports = {
"/examples/Disabled.md",
"/examples/DisabledItems.md",
"/examples/Responsive.md",
"/examples/MultipleItemsY.md",
],
},
],
......
# Example 9: Multiple Items per field
Grid with multiple items per slot (overlaps only in y direction possible,
width of every item has to be `1`). The items are placed in the grid automatically.
To allow this behaviour, the grid component has to receive the prop `multiple-items-y` with the value `true`.
<ClientOnly>
<script setup>
import Example9MultipleItemsY from "../../example/src/Example9MultipleItemsY.vue";
</script>
<Example9MultipleItemsY />
</ClientOnly>
......@@ -244,3 +244,17 @@ Examples for such a mechanism can be found in Examples 4 and 5.
:::
To handle movements from one grid to another, the attributes `gridId` and `originGridId` of the event will help.
## Overlapping grid items
If two items overlap, the one which is defined later in the array will be on top of the other one.
They cannot be dragged.
If you want to have overlapping items which can be dragged, there exists the `multipleItemsY` prop.
If this is set to `true`, items can be dragged on top of each other. The items will be stacked horizontally.
This is useful for e.g. a calendar-like frontend.
::: danger
If `multipleItemsY` is set to `true`, the `w` property of all items has to be set to `1`.
Otherwise, this will lead to unexpected behaviour.
:::
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment