Browse Source

react-landing/src: better imports

pull/3/head
remorses 1 year ago
parent
commit
a9ac6ad8f5
14 changed files with 66 additions and 97 deletions
  1. +3
    -1
      react-landing/src/Banner.tsx
  2. +7
    -11
      react-landing/src/Countdown.tsx
  3. +5
    -13
      react-landing/src/Faqs.tsx
  4. +5
    -5
      react-landing/src/Feature.tsx
  5. +4
    -2
      react-landing/src/FeaturesGrid.tsx
  6. +6
    -7
      react-landing/src/FeaturesList.tsx
  7. +1
    -1
      react-landing/src/Footer.tsx
  8. +5
    -7
      react-landing/src/HowItWorks.tsx
  9. +1
    -1
      react-landing/src/NavBar.tsx
  10. +6
    -31
      react-landing/src/Pricing.tsx
  11. +12
    -10
      react-landing/src/SectionTitle.tsx
  12. +6
    -6
      react-landing/src/TestimonialsLogos.tsx
  13. +3
    -1
      react-landing/src/TestimonialsTweets.tsx
  14. +2
    -1
      react-landing/src/TopBanner.tsx

+ 3
- 1
react-landing/src/Banner.tsx View File

@ -1,9 +1,11 @@
import { Heading as H, HeadingProps, Stack, Box } from '@chakra-ui/core'
import React, { FC, ReactNode } from 'react'
import { Col, Row, Heading, Spacer, PageContainer, Subheading, Button } from '.'
import { Text } from '@chakra-ui/core'
import { removeUndefined } from './support'
import { PageContainer, Col } from './layout'
import { Heading } from './Heading'
import { Subheading } from './Subheading'
export function Banner({
heading = '',

+ 7
- 11
react-landing/src/Countdown.tsx View File

@ -1,16 +1,12 @@
import { Box, Stack, StackProps } from '@chakra-ui/core'
import React, { ReactNode, cloneElement, useState, useEffect } from 'react'
import { Row, Subheading, Heading, Button, Bullet } from '.'
import {
PageContainer,
Col,
FloatingElement,
PageContainerProps,
} from './layout'
import { Box, Stack } from '@chakra-ui/core'
import React, { ReactNode, useEffect, useState } from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { GradientRect } from './decorations'
import { Col, PageContainer, PageContainerProps } from './layout'
import { Subheading } from './Subheading'
import { clone } from './support'
import { Bullet } from './Bullet'
export type SectionTitleProps = {
heading?: ReactNode

+ 5
- 13
react-landing/src/Faqs.tsx View File

@ -1,16 +1,8 @@
import React, { ReactNode, useContext } from 'react'
import Color from 'color-js'
import { Box, Text, Stack, Heading, Button } from '@chakra-ui/core'
import {
Accordion,
AccordionItem,
AccordionHeader,
AccordionPanel,
AccordionIcon,
} from '@chakra-ui/core'
import { Row, Subheading } from '.'
import { PageContainer, Col } from './layout'
import { useFaded } from './hooks'
import { Accordion, AccordionHeader, AccordionIcon, AccordionItem, AccordionPanel, Box, Heading, Stack } from '@chakra-ui/core'
import React from 'react'
import { useFaded } from './hooks'
import { PageContainer } from './layout'
import { Subheading } from './Subheading'
export function Faqs({

+ 5
- 5
react-landing/src/Feature.tsx View File

@ -1,8 +1,8 @@
import { Heading as H, HeadingProps, Stack, Box } from '@chakra-ui/core'
import React, { FC } from 'react'
import { Col, Row, Heading, Spacer, PageContainer } from '.'
import { Text } from '@chakra-ui/core'
import { useFaded } from './hooks'
import { Stack } from '@chakra-ui/core'
import React from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { Col, PageContainer } from './layout'
import { Subheading } from './Subheading'

+ 4
- 2
react-landing/src/FeaturesGrid.tsx View File

@ -6,10 +6,12 @@ import {
SimpleGrid,
} from '@chakra-ui/core'
import React, { FC } from 'react'
import { Col, Row, Heading, Spacer } from '.'
import { Text } from '@chakra-ui/core'
import { removeUndefined } from './support'
import { PageContainer, Col } from './layout'
import { Heading } from './Heading'
import { Subheading } from './Subheading'
import { PageContainer } from './layout'
import { useFaded } from './hooks'

+ 6
- 7
react-landing/src/FeaturesList.tsx View File

@ -1,10 +1,10 @@
import { Heading as H, HeadingProps, Stack, Box } from '@chakra-ui/core'
import React, { FC } from 'react'
import { Col, Row, Heading, Spacer } from '.'
import { Text } from '@chakra-ui/core'
import { Stack, Text } from '@chakra-ui/core'
import React from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { Col, PageContainer } from './layout'
import { Subheading } from './Subheading'
import { PageContainer } from './layout'
import { useFaded } from './hooks'
export function FeaturesList({
@ -58,7 +58,6 @@ export function FeaturesList({
}
const Feature = ({ heading, subheading, icon, centerText, ...rest }) => {
return (
<Stack
textAlign={centerText ? 'center' : 'left'}

+ 1
- 1
react-landing/src/Footer.tsx View File

@ -1,7 +1,7 @@
import React, { ReactNode, useContext } from 'react'
import Color from 'color-js'
import { Box, Text, Stack } from '@chakra-ui/core'
import { Row } from '.'
import { Row } from './layout'
import { PageContainer } from './layout'
export function Footer({

+ 5
- 7
react-landing/src/HowItWorks.tsx View File

@ -1,10 +1,8 @@
import { Heading as H, HeadingProps, Stack, Box } from '@chakra-ui/core'
import React, { FC } from 'react'
import { Col, Row, Heading, Spacer } from '.'
import { Text } from '@chakra-ui/core'
import { Subheading } from './Subheading'
import { PageContainer } from './layout'
import { useFaded } from './hooks'
import { Box, Stack, Text } from '@chakra-ui/core'
import React from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { PageContainer, Col } from './layout'
export function HowItWorks({

+ 1
- 1
react-landing/src/NavBar.tsx View File

@ -10,7 +10,7 @@ import {
Button,
} from '@chakra-ui/core'
import React, { cloneElement } from 'react'
import { Row } from '.'
import { Row } from './layout'
import { PageContainer, darkStyles } from './layout'
import { FiMenu as Menu } from 'react-icons/fi'
import { useMyColorMode } from './hooks'

+ 6
- 31
react-landing/src/Pricing.tsx View File

@ -1,35 +1,10 @@
import {
Heading as H,
HeadingProps,
Stack,
Box,
StackProps,
Divider,
DarkMode,
} from '@chakra-ui/core'
import React, {
FC,
ReactElement,
ElementType,
ReactNode,
Fragment,
} from 'react'
import {
Col,
Row,
Heading,
Spacer,
PageContainer,
Subheading,
Button,
PageContainerProps,
} from '.'
import { Text } from '@chakra-ui/core'
import { useMyColorMode } from './hooks'
import { removeUndefined, useColor } from './support'
import { Box, DarkMode, Divider, Stack, StackProps } from '@chakra-ui/core'
import Color from 'color-js'
import { darkStyles } from './layout'
import React, { Fragment, ReactNode } from 'react'
import { useMyColorMode } from './hooks'
import { darkStyles, PageContainer, PageContainerProps } from './layout'
import { useColor } from './support'
const featureLineMinH = '36px'
const featuresWidth = '370px'

+ 12
- 10
react-landing/src/SectionTitle.tsx View File

@ -1,11 +1,11 @@
import { Box, Stack, StackProps } from '@chakra-ui/core'
import React, { ReactNode, cloneElement } from 'react'
import { Row, Subheading, Heading, Button, Bullet } from '.'
import { PageContainer, Col, FloatingElement, PageContainerProps } from './layout'
import { Stack } from '@chakra-ui/core'
import React, { ReactNode } from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { GradientRect } from './decorations'
import { Col, PageContainer, PageContainerProps } from './layout'
import { Subheading } from './Subheading'
import { clone } from './support'
import { Bullet } from './Bullet'
export type SectionTitleProps = {
heading?: ReactNode
@ -36,10 +36,12 @@ export function SectionTitle({
>
<Bullet>{bullet}</Bullet>
<Heading fontSize='32px'>{heading}</Heading>
<Subheading fontSize='18px'>
{subheading}
</Subheading>
{cta && <Col justify='center' align='center'>{clone(cta)}</Col>}
<Subheading fontSize='18px'>{subheading}</Subheading>
{cta && (
<Col justify='center' align='center'>
{clone(cta)}
</Col>
)}
</Stack>
</PageContainer>
)

+ 6
- 6
react-landing/src/TestimonialsLogos.tsx View File

@ -1,9 +1,9 @@
import React, { ReactNode, useContext } from 'react'
import Color from 'color-js'
import { Box, Text, Stack } from '@chakra-ui/core'
import { Row, Heading, Subheading } from '.'
import { PageContainer, Col } from './layout'
import { useFaded } from './hooks'
import { Stack } from '@chakra-ui/core'
import React from 'react'
import { Heading } from './Heading'
import { useFaded } from './hooks'
import { Col, PageContainer } from './layout'
import { Subheading } from './Subheading'
export function TestimonialsLogos({

+ 3
- 1
react-landing/src/TestimonialsTweets.tsx View File

@ -1,7 +1,9 @@
import React, { ReactNode, useContext } from 'react'
import Color from 'color-js'
import { Box, Text, Stack, Flex } from '@chakra-ui/core'
import { Row, Heading, Subheading } from '.'
import { removeUndefined } from './support'
import { Heading } from './Heading'
import { Subheading } from './Subheading'
import { PageContainer, Col } from './layout'
import { TwitterTweetEmbed } from 'react-twitter-embed'

+ 2
- 1
react-landing/src/TopBanner.tsx View File

@ -1,7 +1,8 @@
import { Box, Stack, Text, Button } from '@chakra-ui/core'
import React from 'react'
import { Row, Bullet } from '.'
import { Row } from './layout'
import { PageContainer } from './layout'
import { Bullet } from './Bullet'
export function TopBanner({ heading, cta, bullet, ...rest }) {
return (

Loading…
Cancel
Save