-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
displaying Rows & Columns as a grid / grid-area with content (#81)
- Loading branch information
1 parent
62d5e9e
commit 9ba1299
Showing
6 changed files
with
98 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,20 @@ | ||
<script> | ||
import { gridDataStore } from "../store/gridDataStore"; | ||
export let height; | ||
console.log('Row height: ',height); | ||
console.log('Row: height: ',height); | ||
</script> | ||
|
||
<!-- <div class="container"> --> | ||
<h1>ROW</h1> | ||
<slot/> | ||
<!-- </div> --> | ||
|
||
<slot><h1>ROW</h1></slot> | ||
|
||
{#each $gridDataStore.rows as row, rowIndex} | ||
{#each row.columns as column, columnIndex} | ||
<div id={column.id} class="section" style="grid-area: { `${rowIndex + 1}/${columnIndex + 1}/${rowIndex+1+row.height}/${columnIndex+1+column.width}` } ;"></div> | ||
{/each} | ||
{/each} | ||
|
||
<style> | ||
h1 { | ||
color: darkred; | ||
} | ||
/* .container { | ||
padding: 10px; | ||
background-color: #edf1f7; | ||
border: 1px solid #3d5f99; | ||
min-height: 50vh; | ||
display: grid; | ||
grid-auto-columns: 1fr 1fr; | ||
grid-auto-rows: 1fr 1fr; | ||
gap: 0.6rem 0.6rem; | ||
} */ | ||
</style> |