-
-
Notifications
You must be signed in to change notification settings - Fork 131
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added support for customizable tooltip
- Loading branch information
1 parent
8405b42
commit 517cb9a
Showing
9 changed files
with
245 additions
and
83 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@tailwind base; | ||
@tailwind components; | ||
@tailwind utilities; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
/** @type {import('tailwindcss').Config} */ | ||
/* eslint-disable max-len */ | ||
import plugin from 'tailwindcss/plugin'; | ||
import { colorPalette } from 'reablocks'; | ||
|
||
module.exports = { | ||
content: [ | ||
'./index.html', | ||
'./src/**/*.{js,ts,jsx,tsx}', | ||
'./node_modules/reablocks/**/*.{js,jsx,ts,tsx}', | ||
], | ||
theme: { | ||
extend: { | ||
colors: { | ||
primary: { | ||
DEFAULT: colorPalette.blue[500], | ||
active: colorPalette.blue[500], | ||
hover: colorPalette.blue[600], | ||
inactive: colorPalette.blue[200] | ||
}, | ||
secondary: { | ||
DEFAULT: colorPalette.gray[700], | ||
active: colorPalette.gray[700], | ||
hover: colorPalette.gray[800], | ||
inactive: colorPalette.gray[400] | ||
}, | ||
success: { | ||
DEFAULT: colorPalette.green[500], | ||
active: colorPalette.green[500], | ||
hover: colorPalette.green[600] | ||
}, | ||
error: { | ||
DEFAULT: colorPalette.red[500], | ||
active: colorPalette.red[500], | ||
hover: colorPalette.red[600] | ||
}, | ||
warning: { | ||
DEFAULT: colorPalette.orange[500], | ||
active: colorPalette.orange[500], | ||
hover: colorPalette.orange[600] | ||
}, | ||
info: { | ||
DEFAULT: colorPalette.blue[500], | ||
active: colorPalette.blue[500], | ||
hover: colorPalette.blue[600] | ||
}, | ||
background: { | ||
level1: colorPalette.white, | ||
level2: colorPalette.gray[950], | ||
level3: colorPalette.gray[900], | ||
level4: colorPalette.gray[800], | ||
}, | ||
panel: { | ||
DEFAULT: colorPalette['black-pearl'], | ||
accent: colorPalette['charade'] | ||
}, | ||
surface: { | ||
DEFAULT: colorPalette['charade'], | ||
accent: colorPalette.blue[500] | ||
}, | ||
typography: { | ||
DEFAULT: colorPalette['athens-gray'], | ||
}, | ||
accent: { | ||
DEFAULT: colorPalette['waterloo'], | ||
active: colorPalette['anakiwa'] | ||
}, | ||
} | ||
} | ||
}, | ||
plugins: [ | ||
plugin(({ addVariant }) => { | ||
addVariant('disabled-within', '&:has(input:is(:disabled),button:is(:disabled))'); | ||
}) | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
.base { | ||
white-space: nowrap; | ||
text-align: center; | ||
will-change: transform, opacity; | ||
background-color: rgb(196, 196, 196); | ||
color: black; | ||
border: 1px solid rgb(116, 116, 116); | ||
border-radius: 0.25rem; | ||
padding: 0.5rem; | ||
pointer-events: none; | ||
|
||
.disablePointer { | ||
cursor: not-allowed; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { PopoverTheme } from 'reablocks'; | ||
|
||
import css from './Popover.module.css'; | ||
|
||
export const popoverTheme: PopoverTheme = { | ||
base: css.base, | ||
disablePadding: css.disablePadding, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
declare module '*.module.css'; |