// @flow import * as React from "react"; import styled from "styled-components"; import Abstract from "./Abstract"; import Airtable from "./Airtable"; import Bilibili from "./Bilibili"; import Cawemo from "./Cawemo"; import ClickUp from "./ClickUp"; import Codepen from "./Codepen"; import Descript from "./Descript"; import Diagrams from "./Diagrams"; import Figma from "./Figma"; import Framer from "./Framer"; import Gist from "./Gist"; import GoogleCalendar from "./GoogleCalendar"; import GoogleDataStudio from "./GoogleDataStudio"; import GoogleDocs from "./GoogleDocs"; import GoogleDrawings from "./GoogleDrawings"; import GoogleDrive from "./GoogleDrive"; import GoogleSheets from "./GoogleSheets"; import GoogleSlides from "./GoogleSlides"; import InVision from "./InVision"; import Loom from "./Loom"; import Lucidchart from "./Lucidchart"; import Marvel from "./Marvel"; import Mindmeister from "./Mindmeister"; import Miro from "./Miro"; import ModeAnalytics from "./ModeAnalytics"; import Prezi from "./Prezi"; import Spotify from "./Spotify"; import Trello from "./Trello"; import Typeform from "./Typeform"; import Vimeo from "./Vimeo"; import YouTube from "./YouTube"; import Image from "./components/Image"; function matcher(Component) { return (url: string) => { const regexes = Component.ENABLED; for (const regex of regexes) { const result = url.match(regex); if (result) { return result; } } }; } const Img = styled(Image)` margin: 4px; width: 18px; height: 18px; `; export default [ { title: "Abstract", keywords: "design", icon: () => , component: Abstract, matcher: matcher(Abstract), }, { title: "Airtable", keywords: "spreadsheet", icon: () => , component: Airtable, matcher: matcher(Airtable), }, { title: "Bilibili", keywords: "video", defaultHidden: true, icon: () => , component: Bilibili, matcher: matcher(Bilibili), }, { title: "Cawemo", keywords: "bpmn process", defaultHidden: true, icon: () => , component: Cawemo, matcher: matcher(Cawemo), }, { title: "ClickUp", keywords: "project", defaultHidden: true, icon: () => , component: ClickUp, matcher: matcher(ClickUp), }, { title: "Codepen", keywords: "code editor", icon: () => , component: Codepen, matcher: matcher(Codepen), }, { title: "Descript", keywords: "audio", icon: () => , component: Descript, matcher: matcher(Descript), }, { title: "Figma", keywords: "design svg vector", icon: () => , component: Figma, matcher: matcher(Figma), }, { title: "Framer", keywords: "design prototyping", icon: () => , component: Framer, matcher: matcher(Framer), }, { title: "GitHub Gist", keywords: "code", icon: () => , component: Gist, matcher: matcher(Gist), }, { title: "Diagrams.net", keywords: "diagrams drawio", icon: () => , component: Diagrams, matcher: matcher(Diagrams), }, { title: "Google Drawings", keywords: "drawings", icon: () => , component: GoogleDrawings, matcher: matcher(GoogleDrawings), }, { title: "Google Drive", keywords: "drive", icon: () => , component: GoogleDrive, matcher: matcher(GoogleDrive), }, { title: "Google Docs", icon: () => , component: GoogleDocs, matcher: matcher(GoogleDocs), }, { title: "Google Sheets", keywords: "excel spreadsheet", icon: () => , component: GoogleSheets, matcher: matcher(GoogleSheets), }, { title: "Google Slides", keywords: "presentation slideshow", icon: () => , component: GoogleSlides, matcher: matcher(GoogleSlides), }, { title: "Google Calendar", keywords: "calendar", icon: () => , component: GoogleCalendar, matcher: matcher(GoogleCalendar), }, { title: "Google Data Studio", keywords: "business intelligence", icon: () => , component: GoogleDataStudio, matcher: matcher(GoogleDataStudio), }, { title: "InVision", keywords: "design prototype", defaultHidden: true, icon: () => , component: InVision, matcher: matcher(InVision), }, { title: "Loom", keywords: "video screencast", icon: () => , component: Loom, matcher: matcher(Loom), }, { title: "Lucidchart", keywords: "chart", icon: () => , component: Lucidchart, matcher: matcher(Lucidchart), }, { title: "Marvel", keywords: "design prototype", icon: () => , component: Marvel, matcher: matcher(Marvel), }, { title: "Mindmeister", keywords: "mindmap", icon: () => , component: Mindmeister, matcher: matcher(Mindmeister), }, { title: "Miro", keywords: "whiteboard", icon: () => , component: Miro, matcher: matcher(Miro), }, { title: "Mode", keywords: "analytics", defaultHidden: true, icon: () => , component: ModeAnalytics, matcher: matcher(ModeAnalytics), }, { title: "Prezi", keywords: "presentation", icon: () => , component: Prezi, matcher: matcher(Prezi), }, { title: "Spotify", keywords: "music", icon: () => , component: Spotify, matcher: matcher(Spotify), }, { title: "Trello", keywords: "kanban", icon: () => , component: Trello, matcher: matcher(Trello), }, { title: "Typeform", keywords: "form survey", icon: () => , component: Typeform, matcher: matcher(Typeform), }, { title: "Vimeo", keywords: "video", icon: () => , component: Vimeo, matcher: matcher(Vimeo), }, { title: "YouTube", keywords: "google video", icon: () => , component: YouTube, matcher: matcher(YouTube), }, ];