summaryrefslogtreecommitdiff
path: root/packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2022-12-19 12:23:39 -0300
committerSebastian <sebasjm@gmail.com>2022-12-19 12:23:39 -0300
commit72b429321553841ac1ff48cf974bfc65da01bb06 (patch)
tree7db9a4462f02de6cb86de695a1e64772b00ead5f /packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx
parent770ab6f01dc81a16f384f314982bd761540f8e65 (diff)
downloadwallet-core-72b429321553841ac1ff48cf974bfc65da01bb06.tar.gz
wallet-core-72b429321553841ac1ff48cf974bfc65da01bb06.tar.bz2
wallet-core-72b429321553841ac1ff48cf974bfc65da01bb06.zip
pretty
Diffstat (limited to 'packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx')
-rw-r--r--packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx59
1 files changed, 31 insertions, 28 deletions
diff --git a/packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx b/packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx
index ac22960b2..c2c4d548c 100644
--- a/packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx
+++ b/packages/merchant-backoffice-ui/src/paths/instance/products/list/List.stories.tsx
@@ -15,44 +15,47 @@
*/
/**
-*
-* @author Sebastian Javier Marchano (sebasjm)
-*/
+ *
+ * @author Sebastian Javier Marchano (sebasjm)
+ */
-import { h, VNode, FunctionalComponent } from 'preact';
+import { h, VNode, FunctionalComponent } from "preact";
import { CardTable as TestedComponent } from "./Table.js";
-
export default {
- title: 'Pages/Product/List',
+ title: "Pages/Product/List",
component: TestedComponent,
argTypes: {
- onCreate: { action: 'onCreate' },
- onSelect: { action: 'onSelect' },
- onDelete: { action: 'onDelete' },
- onUpdate: { action: 'onUpdate' },
+ onCreate: { action: "onCreate" },
+ onSelect: { action: "onSelect" },
+ onDelete: { action: "onDelete" },
+ onUpdate: { action: "onUpdate" },
},
};
-function createExample<Props>(Component: FunctionalComponent<Props>, props: Partial<Props>) {
- const r = (args: any) => <Component {...args} />
- r.args = props
- return r
+function createExample<Props>(
+ Component: FunctionalComponent<Props>,
+ props: Partial<Props>,
+) {
+ const r = (args: any) => <Component {...args} />;
+ r.args = props;
+ return r;
}
-
export const Example = createExample(TestedComponent, {
- instances: [{
- id: 'orderid',
- description: 'description1',
- description_i18n: {} as any,
- image: '',
- price: 'TESTKUDOS:10',
- taxes: [],
- total_lost: 10,
- total_sold: 5,
- total_stock: 15,
- unit: 'bar',
- address: {}
- }]
+ instances: [
+ {
+ id: "orderid",
+ description: "description1",
+ description_i18n: {} as any,
+ image: "",
+ price: "TESTKUDOS:10",
+ taxes: [],
+ total_lost: 10,
+ total_sold: 5,
+ total_stock: 15,
+ unit: "bar",
+ address: {},
+ },
+ ],
});