{"id":17949126,"url":"https://github.com/0x8f701/LayoutGrid","last_synced_at":"2025-08-16T04:30:46.620Z","repository":{"id":32432165,"uuid":"127810877","full_name":"GopherJ/LayoutGrid","owner":"GopherJ","description":"Vue Layout Gridster","archived":false,"fork":false,"pushed_at":"2022-12-11T02:47:25.000Z","size":7778,"stargazers_count":6,"open_issues_count":13,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-11-30T11:07:05.510Z","etag":null,"topics":["layout-grid"],"latest_commit_sha":null,"homepage":null,"language":"Vue","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GopherJ.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-02T20:49:28.000Z","updated_at":"2023-01-31T16:58:38.000Z","dependencies_parsed_at":"2023-01-14T21:15:18.684Z","dependency_job_id":null,"html_url":"https://github.com/GopherJ/LayoutGrid","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherJ%2FLayoutGrid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherJ%2FLayoutGrid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherJ%2FLayoutGrid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GopherJ%2FLayoutGrid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GopherJ","download_url":"https://codeload.github.com/GopherJ/LayoutGrid/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230004072,"owners_count":18158239,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["layout-grid"],"created_at":"2024-10-29T09:11:30.548Z","updated_at":"2025-08-16T04:30:41.121Z","avatar_url":"https://github.com/GopherJ.png","language":"Vue","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LayoutGrid\n\nLayout grid system in VueJs, see also:\n\n- [vue-grid-layout](https://github.com/jbaysolutions/vue-grid-layout)\n- [Vs](https://github.com/GopherJ/Vs)\n\n\n## Introduction\n\nThis component is for creating a dashboard more simply. All config of the dashboard will be saved in the vuex module `LayoutGrid`. In any component of\nyour SPA, you can add a new item or delete one. I've also added some new features:\n\n- `table mode`\n- `json/csv download`\n- `UI design`\n\nThis component use `jbaysolutions/vue-grid-layout` internally and makes it simpler to use, that means the layout is controlled in vuex and every time\nwhen we need to add a new item. We just need to specify the `title`, `is`, `w`, `h` and `data`. It will calculate automatically the next position and\nalso the identifier `i` .\n\n\n## Installation\n\n```\nnpm i -S vue-layout-grid\n```\n\n## Usage\n\n`main.js`\n```\nimport Vue from 'vue';\nimport Vuex from 'vuex';\nimport LayoutGrid from 'vue-layout-grid';\nimport Buefy from 'buefy';\nimport 'buefy/lib/buefy.min.css';\n\nconst store = new Vuex.Store();\n\nVue.use(Vuex);\nVue.use(LayoutGrid, { store });\n\nnew Vue({\n    store,\n    ...\n});\n```\n\n`index.html`\n\n```html\n\u003clink rel=\"stylesheet\" href=\"//cdn.materialdesignicons.com/2.0.46/css/materialdesignicons.min.css\"\u003e\n```\n\n`template`\n\n```vue\n\u003clayout-grid\n    :editable=\"editable\"\n    :margin=\"margin\"\n    :row-height=\"rowHeight\"\n    :min-w=\"minW\"\u003e\n\u003c/layout-grid\u003e\n```\n\n\n## Props\n\n|prop|description|type|default|\n|:---|:---|:---|:---|\n|`editable`|`show border or not`|`boolean`|`true`|\n|`margin`|`margin between layout grid item`|`[number, number]`|`[0, 0]`|\n|`row-height`|`layout grid item height unit`|`number`|`100`|\n|`min-w`|`min w`|`number`|`1`|\n\n\n\n## Vuex Module\n\nThis component has a vuex module which is registered as `LayoutGrid`.\n\n`store`\n\n```javascript\nthis.$store.state.LayoutGrid.layout\n```\n\n`mutations`\n\n```javascript\n// For example, here I need to add a new item to the layout\n// This item is the `d3-timeline` component of [Vs](https://github.com/GopherJ/Vs)\n// I just need to do:\nthis.$store.commit('LayoutGrid/ADD_LAYOUT_ITEM', {\n    title: 'Alerts',\n    is: 'd3-timeline',\n    w: 12,\n    h: 3,\n    data: {\n        // props of d3-timeline\n        data: [...],\n        options: {...},\n        width: '100%',\n        height: '100%'\n    }\n});\n\n\n// EDIT\n// This is used to replace/update an item\n// For example we change the d3-timeline to d3-timelion\nthis.$store.commit('LayoutGrid/EDIT_LAYOUT_ITEM', {\n    i: '0', // indentifier of d3-timeline, it's generated automatically\n    title: 'Entries Over Time',\n    is: 'd3-timelion',\n    w: 12,\n    h: 3,\n    data: {\n        // props of d3-timelion\n        data: [...],\n        options: {...},\n        width: '100%',\n        height: '100%'\n    }\n});\n```\n\n\n## Special Thanks\n\n[jbaysolutions](https://github.com/jbaysolutions)\n\n\n\n## Screen Shots\n\n*###UI*\n![Alerts](./images/Alerts.PNG)\n![Table](./images/Table.PNG)\n\n\n*###Dashboard*\n![Dashboard](./images/Dashboard.PNG)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x8f701%2FLayoutGrid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0x8f701%2FLayoutGrid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x8f701%2FLayoutGrid/lists"}