From f745dcdbe22e7d278a2ef7b0e29af7e86b48ca4b Mon Sep 17 00:00:00 2001
From: eug-vs <eug-vs@keemail.me>
Date: Sun, 14 Mar 2021 03:25:13 +0300
Subject: feat: create initial ProductForm

---
 src/containers/Page.tsx | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

(limited to 'src/containers/Page.tsx')

diff --git a/src/containers/Page.tsx b/src/containers/Page.tsx
index 0c8269e..f6ae814 100644
--- a/src/containers/Page.tsx
+++ b/src/containers/Page.tsx
@@ -1,10 +1,9 @@
 import React from 'react';
 import Paper from '../components/Paper';
-import Button from '../components/Button';
+import Button, { Props as ButtonProps } from '../components/Button';
 
-interface Action {
+export interface Action extends ButtonProps {
   name: string;
-  route: string;
 }
 
 interface Props {
@@ -16,7 +15,9 @@ const Page: React.FC<Props> = ({ title, actions, children }) => (
   <Paper>
     <div className="mb-2 flex justify-between items-center">
       <span className="text-2xl font-bold">{title}</span>
-      {actions?.map(action => (<Button size="sm" route={action.route}>{action.name}</Button>))}
+      <div>
+        {actions?.map(action => (<Button {...action} size="sm">{action.name}</Button>))}
+      </div>
     </div>
     {children}
   </Paper>
-- 
cgit v1.2.3

