Commit Graph

45 Commits

Author SHA1 Message Date
Ryan Gossiaux
c5ed870827 Assorted fixes
Type fixes, support a couple more classes as functions for the examples, and switch TabPanels to registering ids instead of refs
2021-12-17 14:22:19 -08:00
Ryan Gossiaux
6076a60837 Fix PopoverPanel focus issue
Fixes #20
2021-12-16 23:06:36 -08:00
Ryan Gossiaux
f5130c6cc1 Add use= support to Popover
Fixes #21

Not sure it's worth doing this component by component instead of figuring out <Render> first but w/e
2021-12-16 16:35:09 -08:00
Ryan Gossiaux
3b340fbde5 Fix transition duration in popover example 2021-12-16 16:34:45 -08:00
Ryan Gossiaux
cc69cb9a93 Copy over a few more playground examples 2021-12-16 16:28:57 -08:00
Ryan Gossiaux
1e6d735537 Move dialog example over to grouped imports 2021-12-16 16:22:27 -08:00
Ryan Gossiaux
0911f5efdd Fix some imports 2021-12-16 16:22:14 -08:00
Ryan Gossiaux
4f74dd8ca9 Fix Transition undefined/null bug 2021-12-15 18:40:00 -08:00
Ryan Gossiaux
da6d2c3be6 Fix more TS errors in strict mode 2021-12-15 14:49:19 -08:00
Ryan Gossiaux
5b36ce9404 Fix various type errors with strict mode 2021-12-15 14:06:33 -08:00
Ryan Gossiaux
543c1263e3 Also fix label/description context usage 2021-12-15 10:31:14 -08:00
Ryan Gossiaux
dbfb2c227e Move contexts over to useXContext model
Fixes #4
2021-12-15 10:13:01 -08:00
Ryan Gossiaux
f1edb17609 Fix transitioning away
Fixes #17

The root problem here, which took me ages to find, was that `state` should not be reactive. It should only be set once the child has finished, via the nesting context.
2021-12-14 22:56:55 -08:00
Ryan Gossiaux
20e5360291 Remove extra open= prop in dialog example
I mistakenly added this in reaction to an error
2021-12-14 22:54:59 -08:00
Ryan Gossiaux
df96d74003 A couple fixes to Dialog
Quickfix for SSR
Let it take open from OpenClose context properly
2021-12-14 22:54:06 -08:00
Ryan Gossiaux
47c6918fd2 Fix PortalGroup context 2021-12-14 16:01:47 -08:00
Ryan Gossiaux
7de1e35524 Add index.ts files 2021-12-14 15:28:26 -08:00
Ryan Gossiaux
4fb49c546a Add wrapper for TransitionChild 2021-12-14 15:28:05 -08:00
Ryan Gossiaux
a5fac38a7a Add svelte2tsx 2021-12-14 15:27:26 -08:00
Ryan Gossiaux
b0e2c3d619 Remove busted tailwind button focus classes
The examples repo is using an old version of tailwind + a plugin. shadow-outline-foo doesn't exist in base Tailwind and I cba to find the equivalent right now.
2021-12-14 13:55:21 -08:00
Ryan Gossiaux
0185f9f9f6 Don't render Transition contents if they're not visible
Fixes #14
2021-12-14 13:54:34 -08:00
Ryan Gossiaux
02bb968396 Fix initial focus issues with Dialog
Fixes #15
2021-12-14 13:19:58 -08:00
Ryan Gossiaux
a647f7eb87 git rm use-effect.ts
Wasn't using this since it doesn't work
2021-12-14 12:05:17 -08:00
Ryan Gossiaux
9d7f56cdcd Minor tweaks to default values 2021-12-14 12:04:23 -08:00
Ryan Gossiaux
543a6dba3d Bind missing dialog ref
Fixes #12
Fixes #13
2021-12-14 12:03:01 -08:00
Ryan Gossiaux
5aea8065d3 Fixes to Dialog
Fix bad porting from useEffect--needs to run on destroy as well. Also fix a missing function invocation.
2021-12-14 12:01:42 -08:00
Ryan Gossiaux
5468a38a45 Add focus style back to css
Just for easier debugging of focus
2021-12-14 11:09:53 -08:00
Ryan Gossiaux
70a4a814b7 Bring back the popper & portal in dialog example 2021-12-14 11:08:36 -08:00
Ryan Gossiaux
0fe7b0ea04 Add action forwarding and add to Menu 2021-12-13 22:08:22 -08:00
Ryan Gossiaux
48ae497beb npm install -D svelte-popperjs 2021-12-13 21:58:17 -08:00
Ryan Gossiaux
092fdd595d Some updates to dialog example 2021-12-13 21:57:53 -08:00
Ryan Gossiaux
a4e55d7167 Fix TransitionRoot inheriting state from other components 2021-12-13 21:57:34 -08:00
Ryan Gossiaux
c265aae571 npm install 2021-12-13 21:57:05 -08:00
Ryan Gossiaux
263cbd0483 npx svelte-add tailwindcss 2021-12-13 21:05:36 -08:00
Ryan Gossiaux
53adc38513 Add initial Dialog example 2021-12-13 21:03:36 -08:00
Ryan Gossiaux
5cc50973e4 Fixes to Dialog 2021-12-13 21:03:25 -08:00
Ryan Gossiaux
a12b64faed Fix a few more misc issues (TS errors, dupe files) 2021-12-13 19:01:59 -08:00
rgossiaux
50478bd999 Change license file to MIT
To be compatible with the Headless UI license. The repo is still private so this was never distributed under Apache.
2021-12-13 18:59:22 -08:00
Ryan Gossiaux
a9b996b5ce Add .nvimrc to .gitignore 2021-12-13 18:22:59 -08:00
Ryan Gossiaux
82b138f0ae Run prettier over everything and fix some imports 2021-12-13 18:22:16 -08:00
Ryan Gossiaux
3bf974a654 Nuke the default prettierrc 2021-12-13 18:21:56 -08:00
Ryan Gossiaux
db9ec57065 Initial commit with files
Still need to fix the imports
2021-12-13 17:13:47 -08:00
Ryan Gossiaux
42aba8a158 npm init svelte@next svelte-headlessui 2021-12-13 16:46:03 -08:00
rgossiaux
e19e6dd41c Update README.md 2021-12-04 23:14:22 -08:00
rgossiaux
f6cafd857b Initial commit 2021-12-04 23:13:54 -08:00