diff --git a/Parts/Button.js b/Parts/Button.js index b2c7633..111ef91 100644 --- a/Parts/Button.js +++ b/Parts/Button.js @@ -1,6 +1,6 @@ import React from "react" import tw, { styled } from "twin.macro" -import "styled-components/macro" + import { colors, colorsDisabled, colorsHover } from "./Colors" const BtnCreator = function ({ children, type, ...props }) { diff --git a/Parts/Card.js b/Parts/Card.js index 62bc23f..9e18c07 100644 --- a/Parts/Card.js +++ b/Parts/Card.js @@ -1,6 +1,6 @@ import React from "react"; import tw, {styled} from "twin.macro" -import "styled-components/macro" + let Card = styled.div(tw`relative flex flex-col min-w-0 break-words bg-primary w-full shadow-xl rounded-2xl`) diff --git a/Parts/Colors.js b/Parts/Colors.js index 92039b5..fc970d8 100644 --- a/Parts/Colors.js +++ b/Parts/Colors.js @@ -1,6 +1,6 @@ import tw, {styled} from "twin.macro" -import "styled-components/macro" + export let colors = { diff --git a/Parts/DropDown.js b/Parts/DropDown.js index e109d23..6371e00 100644 --- a/Parts/DropDown.js +++ b/Parts/DropDown.js @@ -3,7 +3,7 @@ import { createPopper } from "@popperjs/core"; import { usePopper } from 'react-popper'; import tw, { styled } from "twin.macro" -import "styled-components/macro" + import { colors, colorsDisabled, colorsHover, textColors, textColorsHover } from "./Colors"; diff --git a/Parts/Input.js b/Parts/Input.js index dbc150f..41a5a92 100644 --- a/Parts/Input.js +++ b/Parts/Input.js @@ -1,8 +1,9 @@ import React from "react"; import tw, { styled } from "twin.macro"; -import "styled-components/macro"; -import { useField as useFormikField, useFormikContext } from "formik"; +//import { useField as useFormikField, useFormikContext } from "formik"; +const useFormikField = null; +const useFormikContext = ()=>{}; export function useField(props){ let getField = useFormikField; @@ -15,7 +16,7 @@ export function useField(props){ return getField(props); } -export default function Input({ label, title, className, children, ...props }) { +export default function Input({ label, title, children, className, ...props }) { /*name, id*/ props.id = props.id ?? props.name ?? title; @@ -48,15 +49,14 @@ export default function Input({ label, title, className, children, ...props }) { export function TextArea({ label, title, - className, - children, + children, ...props }) { const [field, meta, helpers] = useField(props); return ( -
+
{title && (