Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/development' into chore/semantic…
Browse files Browse the repository at this point in the history
…-release
  • Loading branch information
kudyniuk committed Oct 4, 2023
2 parents 0e4a2fb + d7c90e8 commit ee49889
Show file tree
Hide file tree
Showing 6 changed files with 1,399 additions and 1,229 deletions.
118 changes: 118 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
<img src="header.svg" width="100%" alt="css-in-readme">

# Tetrisly React

🧩 Tetrisly offers user-friendly components designed for effortless integration. Plus, it's fully compatible with fully compatible with Tetrisly for Figma with a seamless design and development experience in mind.

If you want to know more about Tetrisly, check out our website: [tetrisly.com](https://tetrisly.com/)

## Tech Stack

- [React 18](https://react.dev/)
- [xstyled](https://xstyled.dev/)

We've desided to use `xstyled` for styling our components. If you are interested in our reasoning, check out our article on this topic: [Style Wars: Tailwind vs. CSS-in-JS in Design Systems Implementation](https://medium.com/tetrisly/style-wars-tailwind-vs-css-in-js-in-design-systems-implementation-de6015ee2695)

## Installation

Install tetrisly-react with npm (you can do the same with yarn, pnpm or any other package manager)

```bash
npm install @virtuslab/tetrisly-react
```

## Setup

After installing the package, you need to wrap your application in the `TetrislyProvider` component. This will provide the theme and other context to your application.

```typescript
import { TetrislyProvider } from '@virtuslab/tetrisly-react';

function App() {
return (
<TetrislyProvider>
<YourApp />
</TetrislyProvider>
)
}
```

TetrislyProvider accepts optional prop `theme` which can be used to override default theme.

You can check out how this object looks like here: [Tetrisly Theme](src/theme/theme.ts)

```typescript
import { TetrislyProvider } from '@virtuslab/tetrisly-react';

function App() {
return (
<TetrislyProvider theme={{ colors: { primary: 'red' } }}>
<YourApp />
</TetrislyProvider>
)
}
```

## Usage/Examples

```typescript
import { Button } from '@virtuslab/tetrisly-react';

function App() {
return <Button label="Hello Tetrisly" />
}
```

## Run Locally

Clone the project

```bash
git clone https://github.com/VirtusLab/tetrisly-react
```

Go to the project directory

```bash
cd tetrisly-react
```

Install dependencies

```bash
yarn install
```

Start the storybook server

```bash
yarn storybook
```

## Running Tests

To run tests, run the following command

```bash
yarn test
```

## Documentation

<img src="public/logo_docs.svg" />

If you want to dive deeper into the components Tetrisly offers, check out our official documentation: [Tetrisly Docs](https://docs.tetrisly.com/)

You can also check out our Storybook, which is our Documentation for React components (now in progress): [Tetrisly Storybook](https://virtuslab.github.io/tetrisly-react/?path=/docs/alertbanner--docs)

## Getting Help

If at any point you need help, feel lost, or have some feedback for us, you can create issues on our GitHub repository, or reach out to us on out Discord Server: [Tetrisly Discord](https://discord.gg/MPefZwUZUu)

## Testimonials

If you want to share with us your thoughts on Tetrisly, or showcase what you have built with it (it could be any aspect of our product, not only the React library), you can do it here: [Tetrisly Testimonials Form](https://senja.io/p/tetrisly/r/NfsRmn)

## License

We are using the [Apache License 2.0](https://choosealicense.com/licenses/apache-2.0/) for our library of components
94 changes: 94 additions & 0 deletions header.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.2",
"eslint-plugin-storybook": "^0.6.12",
"husky": "^8.0.0",
"husky": "^8.0.3",
"jsdom": "^22.1.0",
"lint-staged": ">=10",
"prettier": "^3.0.2",
Expand Down
Binary file added public/VLLogo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
17 changes: 17 additions & 0 deletions public/logo_docs.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit ee49889

Please sign in to comment.