Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/tohsaka888/react-animate-tab


https://github.com/tohsaka888/react-animate-tab

Last synced: 9 days ago
JSON representation

Awesome Lists containing this project

README

        

# react-anime-tab

[![GitHub license](https://img.shields.io/github/license/mashape/apistatus.svg?style=flat-square)](https://github.com/tohsaka888/create-react-swc-app/blob/master/LICENSE)
[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)

## example

```tsx
import React, { Key, useState } from "react";
import "@/style/global.css";
import { Tabs } from "@source/index";

function App() {
const [selectedKeys, setSelectedKeys] = useState([]);

return (
({
name: "item" + idx,
id: "item" + idx,
icon:

1
,
}))}
defaultSelectedKeys={["item0"]}
style={{ height: "60px" }}
itemStyle={{ padding: "0px 12px" }}
itemSelectedStyle={{ padding: "0px 12px", color: "red" }}
lineStyle={{ background: "red" }}
// selectedKeys={selectedKeys}
// onSelect={(id, item) => {
// setSelectedKeys([...selectedKeys, id]);
// }}
/>
);
}

export default App;
```