From 70bc8ba246e349f9829ea7da7369bd7bd3a88ec9 Mon Sep 17 00:00:00 2001 From: Kipruto <43873157+kelvinkipruto@users.noreply.github.com> Date: Wed, 31 Jul 2024 14:40:01 +0300 Subject: [PATCH] Add stories --- .../stories/HURUmap/core/Action.stories.js | 38 +++++++++++++++++++ .../stories/HURUmap/core/Share.stories.js | 5 ++- 2 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 apps/uibook/stories/HURUmap/core/Action.stories.js diff --git a/apps/uibook/stories/HURUmap/core/Action.stories.js b/apps/uibook/stories/HURUmap/core/Action.stories.js new file mode 100644 index 000000000..c8a8a1615 --- /dev/null +++ b/apps/uibook/stories/HURUmap/core/Action.stories.js @@ -0,0 +1,38 @@ +import { Action } from "@hurumap/core"; +import { Add as AddIcon } from "@mui/icons-material"; +import React from "react"; + +export default { + title: "@hurumap/core/Action", + component: Action, + argTypes: { + title: { + control: { + type: "text", + }, + }, + header: { + control: { + type: "text", + }, + }, + icon: { + control: { + type: "element", + }, + }, + }, +}; + +function Template(args) { + return ; +} + +export const Default = Template.bind({}); +Default.args = { + id: "1", + title: "Action", + icon: , + header: "Header", + children:
Children
, +}; diff --git a/apps/uibook/stories/HURUmap/core/Share.stories.js b/apps/uibook/stories/HURUmap/core/Share.stories.js index 2cfda99b5..6099aab86 100644 --- a/apps/uibook/stories/HURUmap/core/Share.stories.js +++ b/apps/uibook/stories/HURUmap/core/Share.stories.js @@ -102,7 +102,10 @@ Default.args = { shareData, title: "Area of agricultural land in hectares", chartType: "treemap", - code: "

code

", + codeData: { + src: "http://localhost:3001/embed/ke/1087", + className: "chart", + }, geoCode: "KE", indicatorId: 1087, isCompare: false,