"use client"; import React, { useState } from "react"; import { observer } from "mobx-react"; // icons import { Search } from "lucide-react"; // plane imports import { DEFAULT_GLOBAL_VIEWS_LIST } from "@plane/constants"; import { useTranslation } from "@plane/i18n"; // ui import { Input } from "@plane/ui"; // components import { PageHead } from "@/components/core"; import { GlobalDefaultViewListItem, GlobalViewsList } from "@/components/workspace"; // constants // hooks import { useWorkspace } from "@/hooks/store"; const WorkspaceViewsPage = observer(() => { const [query, setQuery] = useState(""); // store const { currentWorkspace } = useWorkspace(); const { t } = useTranslation(); // derived values const pageTitle = currentWorkspace?.name ? `${currentWorkspace?.name} - All Views` : undefined; return ( <>
setQuery(e.target.value)} placeholder="Search" mode="true-transparent" />
{DEFAULT_GLOBAL_VIEWS_LIST.filter((v) => t(v.i18n_label).toLowerCase().includes(query.toLowerCase())).map( (option) => ( ) )}
); }); export default WorkspaceViewsPage;