diff --git a/.changeset/shy-bottles-agree.md b/.changeset/shy-bottles-agree.md deleted file mode 100644 index 8e31e876c..000000000 --- a/.changeset/shy-bottles-agree.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@qwik-ui/styled': patch ---- - -FIX: onChange not accepting regular functions diff --git a/.changeset/tender-pens-run.md b/.changeset/tender-pens-run.md deleted file mode 100644 index 57a8db21a..000000000 --- a/.changeset/tender-pens-run.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@qwik-ui/headless': patch ---- - -FIX: types for multiple values diff --git a/apps/website/public/_headers b/apps/website/public/_headers index 0690cb420..555fe4134 100644 --- a/apps/website/public/_headers +++ b/apps/website/public/_headers @@ -2,3 +2,6 @@ /build/* Cache-Control: public, max-age=31536000, s-maxage=31536000, immutable + +/docs/* + Cache-Control: public, max-age=3600, s-maxage=3600 \ No newline at end of file diff --git a/apps/website/src/routes/docs/styled/accordion/examples/hero.tsx b/apps/website/src/routes/docs/styled/accordion/examples/hero.tsx index 3b80e8cc5..7aa564730 100644 --- a/apps/website/src/routes/docs/styled/accordion/examples/hero.tsx +++ b/apps/website/src/routes/docs/styled/accordion/examples/hero.tsx @@ -5,7 +5,7 @@ export default component$(() => { return ( - Is it accessible? + Is it accessible? Yes. It adheres to the WAI-ARIA design pattern. diff --git a/apps/website/src/routes/docs/styled/accordion/index.mdx b/apps/website/src/routes/docs/styled/accordion/index.mdx index e8f40e295..4e8288429 100644 --- a/apps/website/src/routes/docs/styled/accordion/index.mdx +++ b/apps/website/src/routes/docs/styled/accordion/index.mdx @@ -1,9 +1,11 @@ --- title: Qwik UI | Styled Accordion Component +description: A vertically stacked set of interactive headings that each reveal a section of content. Copy/paste into your project from the documentation or by using the CLI. Easily customize the CVA variants according to your brand requirements. --- import { statusByComponent } from '~/_state/component-statuses'; + # Accordion diff --git a/packages/kit-headless/src/components/modal/modal-panel.tsx b/packages/kit-headless/src/components/modal/modal-panel.tsx index 98adc38f1..a62c76de7 100644 --- a/packages/kit-headless/src/components/modal/modal-panel.tsx +++ b/packages/kit-headless/src/components/modal/modal-panel.tsx @@ -53,11 +53,9 @@ export const HModalPanel = component$((props: PropsOf<'dialog'>) => { await showModal(panelRef.value); window.requestAnimationFrame = storedRequestAnimationFrame; - await context.onShow$?.(); activateFocusTrap(focusTrap); } else { await closeModal(panelRef.value); - await context.onClose$?.(); } cleanup(async () => { @@ -65,6 +63,16 @@ export const HModalPanel = component$((props: PropsOf<'dialog'>) => { }); }); + useTask$(async ({ track }) => { + track(() => context.showSig.value); + + if (context.showSig.value) { + await context.onShow$?.(); + } else { + await context.onClose$?.(); + } + }); + const closeOnBackdropClick$ = $(async (e: MouseEvent) => { if (context.alert === true || context.closeOnBackdropClick === false) { return; diff --git a/packages/kit-headless/src/components/modal/modal-trigger.tsx b/packages/kit-headless/src/components/modal/modal-trigger.tsx index 5b3dc37f5..113b4bf3c 100644 --- a/packages/kit-headless/src/components/modal/modal-trigger.tsx +++ b/packages/kit-headless/src/components/modal/modal-trigger.tsx @@ -11,6 +11,7 @@ export const HModalTrigger = component$((props: PropsOf<'button'>) => { return (