From 2784a078d9f40c9a3a7277ddf801f1f1178837e1 Mon Sep 17 00:00:00 2001 From: callmeroot Date: Mon, 3 Jun 2024 21:03:59 +0530 Subject: [PATCH] added ktable to playground --- docs/pages/playground.vue | 27 +++- lib/KTable/KTable.vue | 289 +++++++++++++++++++------------------- 2 files changed, 169 insertions(+), 147 deletions(-) diff --git a/docs/pages/playground.vue b/docs/pages/playground.vue index 686423285..cce540ba7 100644 --- a/docs/pages/playground.vue +++ b/docs/pages/playground.vue @@ -21,6 +21,8 @@ { text: 'Level 2 ', link: { path: '#' } }, ]" /> --> + + @@ -36,12 +38,29 @@ so you can also use `data`, `methods`, etc. as usual if helpful */ + import KTable from '../../lib/KTable/KTable.vue'; + export default { name: 'Playground', - data() { - return {}; - }, - methods: {}, + components: { + KTable, + }, + data() { + return { + tableHeaders: [ + { label: 'Name', dataType: 'string' }, + { label: 'Age', dataType: 'numeric' }, + { label: 'Birth Date', dataType: 'date' }, + { label: 'City', dataType: 'string' }, + { label: 'Misc', dataType: 'others' }, + ], + tableRows: [ + ['Alice', 25, '1999-05-12', 'New York', 'Example'], + ['Bob', 30, '1994-02-22', 'San Francisco', 'Example'], + ['Charlie', 35, '1989-12-15', 'Chicago', 'Example'], + ], + }; + }, }; diff --git a/lib/KTable/KTable.vue b/lib/KTable/KTable.vue index 1ada93645..5cb0bc3c0 100644 --- a/lib/KTable/KTable.vue +++ b/lib/KTable/KTable.vue @@ -1,4 +1,5 @@