Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Edgaras Benediktavicius edgarasben

🏠
Working from home
View GitHub Profile
@edgarasben
edgarasben / SelectMultiple.tsx
Last active May 8, 2022
SelectMultiple.tsx component bug
View SelectMultiple.tsx
import { useEffect, useState } from 'react'
import Badge from '@/components/Badge'
interface SelectProps {
className?: string
id?: string
label?: string
hint?: string
options: any
defaultPlaceholder?: string
View figma-tokens-radix-colors.json
{
"color": {
"amber": {
"amber1": {
"value": "hsl(39, 70.0%, 99.0%)",
"type": "color"
},
"amber2": {
"value": "hsl(40, 100%, 96.5%)",
"type": "color"
View design-system-as-a-code-template.json
{
"theme": {
"fontFamily": {
"display": {
"family": "DM Serif Display",
"fontWeight": {
"normal": "400"
}
},
"sans": {
View test.js
const test = "hello world 3";
@edgarasben
edgarasben / figma-color-styles-from-json-scripter.js
Last active Mar 31, 2022
Figma Color Styles from JSON (For Scripter plugin)
View figma-color-styles-from-json-scripter.js
// A script which creates Figma Color Styles from a JSON object (e.g. Tailwind colors config)
// From https://github.com/tailwindlabs/tailwindcss/blob/master/src/public/colors.js
const colorsObject = {
black: '#000000',
white: '#ffffff',
slate: {
50: '#f8fafc',
100: '#f1f5f9',
200: '#e2e8f0',