import * as _ from 'lodash';
import * as React from 'react';
import DocumentTitle from 'react-document-title';
import styled from 'styled-components';
import { Hero } from 'ts/components/hero';
import { Banner } from 'ts/components/banner';
import { Button } from 'ts/components/button';
import { Icon } from 'ts/components/icon';
import { SiteWrap } from 'ts/components/siteWrap';
import { Card, LinkProps } from 'ts/components/card';
import { constants } from 'ts/utils/constants';
import { ModalContact } from '../components/modals/modal_contact';
interface Extension {
    icon: string;
    title: string;
    description: string;
    links?: LinkProps[];
}
const extensionData: Extension[] = [
    {
        icon: 'dutchAuction',
        title: 'Dutch Auction',
        description: `Dutch Auctions continually reduce prices until a buyer is found. They're perfect for new or rare assets, and with 0x's off-chain model, they're gas-efficient as well.`,
        links: [
            {
                text: 'Learn More',
                url: 'https://github.com/0xProject/0x-monorepo/blob/development/contracts/extensions/contracts/src/DutchAuction/DutchAuction.sol',
            },
        ],
    },
    {
        icon: 'forwarderContract',
        title: 'Forwarder Contract',
        description: `Say goodbye to WETH! The Forwarder Contract will automatically wrap ETH and fill orders, making buying assets on 0x one step simpler.`,
        links: [
            {
                text: 'Learn More',
                url: 'https://github.com/0xProject/0x-protocol-specification/blob/master/v2/forwarder-specification.md',
            },
        ],
    },
    {
        icon: 'whitelistFilter',
        title: 'Whitelist Filter',
        description: `Restrict access to your relayer with a Whitelist of approved traders. Bring your own list of addresses, or use Wyre's KYC list for free.`,
        links: [
            {
                text: 'Learn More',
                url: 'https://github.com/0xProject/0x-protocol-specification/blob/master/v2/v2-specification.md#whitelist',
            },
        ],
    },
];
export class Extensions extends React.Component {
    public state = {
        isContactModalOpen: false,
    };
    public render(): React.ReactNode {
        return (
            
                
                }
                    actions={}
                />
                
                    
                        {_.map(extensionData, (item, index) => (
                            
                        ))}
                    
                
                
                
            
        );
    }
    public _onOpenContactModal = (): void => {
        this.setState({ isContactModalOpen: true });
    };
    public _onDismissContactModal = (): void => {
        this.setState({ isContactModalOpen: false });
    };
}
const HeroActions = () => (
    
        
        
    
);
const CustomSection = styled.div`
    width: calc(100% - 60px);
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 0 60px;
    position: relative;
    @media (max-width: 768px) {
        padding: 0 0 40px;
    }
`;
const Grid = styled.div`
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    grid-column-gap: 30px;
    grid-row-gap: 30px;
    @media (min-width: 500px) {
        grid-template-columns: repeat(2, 1fr);
    }
    @media (min-width: 900px) {
        grid-template-columns: repeat(3, 1fr);
    }
    @media (min-width: 1560px) {
        padding: 0;
    }
`;