/** * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ import React, { useRef, useState } from 'react'; import { theme, useConfig } from 'docz'; import { Link } from 'gatsby'; import { ThemeProvider } from 'theme-ui'; import { Button, Col, Row, Carousel, } from 'antd'; import { css } from '@emotion/core'; import { supersetTheme } from '@superset-ui/style'; import { DeploymentUnitOutlined, FireOutlined, DotChartOutlined, DatabaseOutlined, } from '@ant-design/icons'; import GitHubButton from 'react-github-btn'; import { Databases } from '../resources/data'; import Layout from '../components/layout'; import DbImage from '../components/DbImage'; import 'antd/dist/antd.css'; import SEO from '../components/seo'; import logo from '../images/superset-logo-horiz-apache.svg'; import { mq } from '../utils'; const { colors } = supersetTheme; const mainPageStyle = css` text-align: center; .alert { color: ${colors.alert.base}; } .error { color: ${colors.error.base}; } .warning { color: ${colors.warning.base}; } .info { color: ${colors.info.base}; } .success { color: ${colors.success.base}; } .secondary { color: ${colors.secondary.base}; } .info-text { font-size: 32px; font-weight: normal; max-width: 600px; margin: auto; } .info-text-smaller { font-size: 24px; max-width: 800px; } `; const titleContainer = css` position: relative; padding-top: 131px; padding-bottom: 80px; padding-left: 20px; padding-right: 20px; background-image: url('/images/data-point.jpg'); background-size: cover; background-position-x: right; .github-section { margin-bottom: 40px; margin-top: 40px; .github-button { margin: 5px; } } .logo-horiz { margin-top: 20px; margin-bottom: 20px; width: 600px; max-width: 100%; ${[mq[3]]} { width: 550px; } ${[mq[2]]} { width: 450px; } ${[mq[1]]} { width: 425px; } ${[mq[0]]} { width: 400px; } } .alert { color: #0c5460; background-color: #d1ecf1; border-color: #bee5eb; max-width: 600px; margin: 0 auto; padding: 0.75rem 1.25rem; margin-top: 83px; border: 1px solid transparent; border-radius: 0.25rem; } `; const secondaryHeading = css` font-size: 55px; text-align: center; `; const featureSectionStyle = css` background: #fff; padding: 5vw 0; margin-top: 0px; margin-bottom: 30px; .featureList { padding: 40px; width: 100%; list-style-type: none; margin: 0 auto; max-width: 1000px; .feature { padding: 20px; text-align: center; margin-bottom: 40px; .imagePlaceHolder { svg { width: 70px; height: 70px; } margin-bottom: 15px; } .featureText { color: ${colors.grayscale.dark2}; font-size: 16px; strong { font-size: 22px; } } } } .heading { font-size: 22px; margin: 0 auto; text-align: center; } `; const integrationSection = css` background: white; margin-bottom: 64px; .databaseSub { text-align: center; display: block; margin-bottom: 40px; font-size: 18px; } .database-list { margin-top: 100px; list-style-type: none; padding: 0px; max-width: 1000px; margin: 0 auto; display: flex; flex-wrap: wrap; justify-content: space-around; margin-bottom: 50px; li { padding: 15px; } } `; const linkCarousel = css` .toggleContainer { display: flex; flex-direction: column; margin-bottom: 100px; position: relative; .toggleBtns { display: flex; flex-direction: row; /* ${[mq[0]]} { flex-direction: column; } */ justify-content: center; .toggle { margin: 10px; color: #666; border: 1px solid #888; background-color: #20a7c911; border-radius: 3px; padding: 16px; transition: all 0.25s; overflow: visible; ${[mq[0]]} { > span { display: none; position: absolute; bottom: 0px; left: 50%; width: 100%; transform: translate(-50%, 100%); } h2 { font-size: 14px; margin: 0; } } &:hover { cursor: pointer; color: ${colors.primary.base}; border: 1px solid ${colors.primary.base}; } &.active { background: red; background: #20a7c933; ${[mq[0]]} { > span { display: block; } } } } } .imageContainer { img { margin: 0 auto; width: 80%; box-shadow: 0 0 3px #aaa; margin-top: 5px; margin-bottom: 5px; } } } `; interface featureProps { icon: React.ReactNode, title: string, descr: string, } const Feature = ({ icon, title, descr }: featureProps) => (