@k8o/arte-odyssey 10.2.0 → 10.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/buttons/icon-button/icon-button.d.mts +1 -1
- package/dist/components/buttons/icon-button/icon-button.mjs +1 -1
- package/dist/components/feedback/toast/toast.mjs +2 -2
- package/dist/components/form/autocomplete/autocomplete.mjs +20 -28
- package/dist/components/form/checkbox/checkbox.mjs +1 -1
- package/dist/components/form/checkbox-card/checkbox-card.mjs +1 -1
- package/dist/components/form/checkbox-group/index.d.mts +3 -3
- package/dist/components/form/file-field/file-field.mjs +1 -1
- package/dist/components/form/number-field/number-field.mjs +1 -1
- package/dist/components/icons/lucide-deep.d.mts +9 -0
- package/dist/components/icons/lucide-imports.d.mts +58 -0
- package/dist/components/icons/lucide-imports.mjs +58 -0
- package/dist/components/icons/lucide.mjs +1 -1
- package/dist/components/index.mjs +9 -9
- package/dist/components/navigation/tabs/tabs.mjs +1 -1
- package/dist/components/overlays/_internal/use-list-navigation.d.mts +40 -0
- package/dist/components/overlays/_internal/use-list-navigation.mjs +95 -0
- package/dist/components/overlays/dialog/dialog.mjs +1 -1
- package/dist/components/overlays/drawer/drawer.mjs +1 -1
- package/dist/components/overlays/dropdown-menu/dropdown-menu.d.mts +2 -1
- package/dist/components/overlays/dropdown-menu/dropdown-menu.mjs +39 -52
- package/dist/components/overlays/dropdown-menu/hooks.d.mts +14 -294
- package/dist/components/overlays/dropdown-menu/hooks.mjs +7 -18
- package/dist/components/overlays/list-box/hooks.d.mts +12 -292
- package/dist/components/overlays/list-box/hooks.mjs +7 -16
- package/dist/components/overlays/list-box/list-box.d.mts +1 -1
- package/dist/components/overlays/list-box/list-box.mjs +25 -32
- package/dist/components/overlays/popover/anchor-positioning.d.mts +26 -0
- package/dist/components/overlays/popover/anchor-positioning.mjs +44 -0
- package/dist/components/overlays/popover/hooks.d.mts +10 -13
- package/dist/components/overlays/popover/hooks.mjs +7 -14
- package/dist/components/overlays/popover/popover.d.mts +2 -3
- package/dist/components/overlays/popover/popover.mjs +31 -59
- package/dist/components/overlays/tooltip/tooltip.d.mts +1 -1
- package/dist/components/overlays/tooltip/tooltip.mjs +2 -23
- package/dist/helpers/index.mjs +2 -2
- package/dist/hooks/focus-trap/index.d.mts +19 -0
- package/dist/hooks/focus-trap/index.mjs +51 -0
- package/dist/hooks/index.mjs +4 -4
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +33 -33
- package/dist/integrations/_shared/renderers.mjs +6 -6
- package/dist/integrations/_shared/schemas.d.mts +30 -30
- package/dist/integrations/json-render/catalog.d.mts +26 -31
- package/dist/integrations/openui/form-views.d.mts +0 -9
- package/dist/integrations/openui/form-views.mjs +0 -9
- package/dist/styles/base.css +39 -1
- package/dist/styles/tokens.css +0 -1
- package/dist/types/variables.d.mts +6 -1
- package/package.json +4 -4
|
@@ -4,13 +4,6 @@ import { useClickAway } from "../../../hooks/click-away/index.mjs";
|
|
|
4
4
|
import { useMemo, useRef } from "react";
|
|
5
5
|
//#region src/components/overlays/popover/hooks.ts
|
|
6
6
|
const [PopoverProvider, usePopoverContext] = createSafeContext("usePopoverContext must be used within a Popover.Root");
|
|
7
|
-
const useFloatingUIContext = () => {
|
|
8
|
-
const popover = usePopoverContext();
|
|
9
|
-
return useMemo(() => popover.context, [popover]);
|
|
10
|
-
};
|
|
11
|
-
const usePlacement = () => {
|
|
12
|
-
return usePopoverContext().placement;
|
|
13
|
-
};
|
|
14
7
|
const useOpenContext = () => {
|
|
15
8
|
const popover = usePopoverContext();
|
|
16
9
|
return useMemo(() => ({
|
|
@@ -64,16 +57,16 @@ const usePopoverContent = () => {
|
|
|
64
57
|
ref,
|
|
65
58
|
isOpen: popover.isOpen,
|
|
66
59
|
trapFocus: popover.trapFocus,
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
60
|
+
anchorName: popover.anchorName,
|
|
61
|
+
placement: popover.placement,
|
|
62
|
+
flipDisabled: popover.flipDisabled,
|
|
70
63
|
itemProps
|
|
71
64
|
}), [
|
|
72
65
|
popover.rootId,
|
|
73
66
|
popover.isOpen,
|
|
74
|
-
popover.
|
|
75
|
-
popover.
|
|
76
|
-
popover.
|
|
67
|
+
popover.anchorName,
|
|
68
|
+
popover.placement,
|
|
69
|
+
popover.flipDisabled,
|
|
77
70
|
ref,
|
|
78
71
|
popover.trapFocus,
|
|
79
72
|
itemProps
|
|
@@ -145,4 +138,4 @@ const usePopoverTrigger = () => {
|
|
|
145
138
|
}, [popover]);
|
|
146
139
|
};
|
|
147
140
|
//#endregion
|
|
148
|
-
export { PopoverProvider,
|
|
141
|
+
export { PopoverProvider, useOpenContext, usePopoverContent, usePopoverContext, usePopoverTrigger };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
+
import { Placement } from "../../../types/variables.mjs";
|
|
1
2
|
import { PopoverContentProps, PopoverTriggerProps, useOpenContext } from "./hooks.mjs";
|
|
2
3
|
import { FC, PropsWithChildren, ReactElement } from "react";
|
|
3
|
-
import { Placement } from "@floating-ui/react";
|
|
4
|
-
import { Variants } from "motion/react";
|
|
5
4
|
|
|
6
5
|
//#region src/components/overlays/popover/popover.d.ts
|
|
7
6
|
declare const Popover: {
|
|
@@ -14,7 +13,7 @@ declare const Popover: {
|
|
|
14
13
|
}>>;
|
|
15
14
|
readonly Content: FC<{
|
|
16
15
|
renderItem: (props: PopoverContentProps) => ReactElement;
|
|
17
|
-
|
|
16
|
+
animation?: "scale" | "fade";
|
|
18
17
|
}>;
|
|
19
18
|
readonly Trigger: FC<{
|
|
20
19
|
renderItem: (props: PopoverTriggerProps) => ReactElement;
|
|
@@ -2,28 +2,21 @@
|
|
|
2
2
|
import { cn } from "../../../helpers/cn.mjs";
|
|
3
3
|
import { useDisclosure } from "../../../hooks/disclosure/index.mjs";
|
|
4
4
|
import { useWritingMode } from "../../../hooks/writing-mode/index.mjs";
|
|
5
|
-
import {
|
|
5
|
+
import { useFocusTrap } from "../../../hooks/focus-trap/index.mjs";
|
|
6
|
+
import { getContentAnchorStyle, toAnchorName } from "./anchor-positioning.mjs";
|
|
6
7
|
import { PopoverProvider, useOpenContext, usePopoverContent, usePopoverContext, usePopoverTrigger } from "./hooks.mjs";
|
|
7
|
-
import { useEffect, useId } from "react";
|
|
8
|
+
import { useCallback, useEffect, useId, useRef } from "react";
|
|
8
9
|
import { jsx } from "react/jsx-runtime";
|
|
9
|
-
import { FloatingFocusManager, FloatingPortal, autoUpdate, flip, offset, useFloating } from "@floating-ui/react";
|
|
10
|
-
import { AnimatePresence } from "motion/react";
|
|
11
|
-
import * as motion$1 from "motion/react-client";
|
|
12
10
|
//#region src/components/overlays/popover/popover.tsx
|
|
13
11
|
const Root = ({ children, type = "menu", placement = "bottom-start", flipDisabled = false, closeOnClickAway = true, trapFocus = true }) => {
|
|
14
12
|
const id = useId();
|
|
15
13
|
const { isOpen, open, close, toggle } = useDisclosure();
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
fallbackAxisSideDirection: "end",
|
|
23
|
-
padding: 8
|
|
24
|
-
})],
|
|
25
|
-
transform: false
|
|
26
|
-
});
|
|
14
|
+
const anchorName = toAnchorName(id);
|
|
15
|
+
const triggerRef = useRef(null);
|
|
16
|
+
const setTriggerRef = useCallback((node) => {
|
|
17
|
+
triggerRef.current = node;
|
|
18
|
+
if (node) node.style.setProperty("anchor-name", anchorName);
|
|
19
|
+
}, [anchorName]);
|
|
27
20
|
useEffect(() => {
|
|
28
21
|
const handleKeyDown = (e) => {
|
|
29
22
|
if (e.key === "Escape") close();
|
|
@@ -43,55 +36,34 @@ const Root = ({ children, type = "menu", placement = "bottom-start", flipDisable
|
|
|
43
36
|
toggleOpen: toggle,
|
|
44
37
|
onOpen: open,
|
|
45
38
|
onClose: close,
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
contentStyles: floatingStyles
|
|
39
|
+
placement,
|
|
40
|
+
anchorName,
|
|
41
|
+
flipDisabled,
|
|
42
|
+
triggerRef,
|
|
43
|
+
setTriggerRef
|
|
52
44
|
},
|
|
53
45
|
children
|
|
54
46
|
});
|
|
55
47
|
};
|
|
56
|
-
const
|
|
57
|
-
|
|
58
|
-
scale: 0,
|
|
59
|
-
transition: { delay: .1 }
|
|
60
|
-
},
|
|
61
|
-
open: {
|
|
62
|
-
scale: 1,
|
|
63
|
-
transition: {
|
|
64
|
-
type: "spring",
|
|
65
|
-
duration: .2
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
};
|
|
69
|
-
const Content = ({ renderItem, motionVariants = contentMotionVariants }) => {
|
|
70
|
-
const { isOpen, trapFocus, context, setContentRef, contentStyles, itemProps } = usePopoverContent();
|
|
48
|
+
const Content = ({ renderItem, animation = "scale" }) => {
|
|
49
|
+
const { isOpen, trapFocus, anchorName, placement, flipDisabled, itemProps } = usePopoverContent();
|
|
71
50
|
const { triggerRef } = usePopoverContext();
|
|
72
|
-
const root = usePortalRoot();
|
|
73
|
-
const protalProps = root ? { root } : {};
|
|
74
51
|
const writingClass = useWritingMode(triggerRef) === "vertical" ? "writing-v" : void 0;
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
children: renderItem(itemProps)
|
|
91
|
-
})
|
|
92
|
-
})
|
|
93
|
-
})
|
|
94
|
-
}) });
|
|
52
|
+
const contentWrapperRef = useRef(null);
|
|
53
|
+
useEffect(() => {
|
|
54
|
+
const el = contentWrapperRef.current;
|
|
55
|
+
if (!el) return;
|
|
56
|
+
if (isOpen && !el.matches(":popover-open")) el.showPopover();
|
|
57
|
+
else if (!isOpen && el.matches(":popover-open")) el.hidePopover();
|
|
58
|
+
}, [isOpen]);
|
|
59
|
+
useFocusTrap(contentWrapperRef, triggerRef, isOpen && trapFocus);
|
|
60
|
+
return /* @__PURE__ */ jsx("div", {
|
|
61
|
+
className: cn("z-overlay outline-hidden", animation === "fade" ? "ao-anim-fade" : "ao-anim-scale", writingClass),
|
|
62
|
+
popover: "manual",
|
|
63
|
+
ref: contentWrapperRef,
|
|
64
|
+
style: getContentAnchorStyle(anchorName, placement, flipDisabled),
|
|
65
|
+
children: renderItem(itemProps)
|
|
66
|
+
});
|
|
95
67
|
};
|
|
96
68
|
const Trigger = ({ renderItem }) => renderItem(usePopoverTrigger());
|
|
97
69
|
const Popover = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { Placement } from "../../../types/variables.mjs";
|
|
1
2
|
import { FC, FocusEventHandler, MouseEventHandler, PropsWithChildren, ReactElement, RefCallback } from "react";
|
|
2
|
-
import { Placement } from "@floating-ui/react";
|
|
3
3
|
|
|
4
4
|
//#region src/components/overlays/tooltip/tooltip.d.ts
|
|
5
5
|
type TooltipTriggerProps = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
2
|
+
import { usePopoverContext } from "../popover/hooks.mjs";
|
|
3
3
|
import { Popover } from "../popover/popover.mjs";
|
|
4
4
|
import { useCallback, useMemo, useSyncExternalStore } from "react";
|
|
5
5
|
import { jsx } from "react/jsx-runtime";
|
|
@@ -38,31 +38,10 @@ const Root = ({ children, placement = "bottom" }) => /* @__PURE__ */ jsx(Popover
|
|
|
38
38
|
});
|
|
39
39
|
const Trigger = ({ renderItem }) => renderItem(useTooltipTriggerProps());
|
|
40
40
|
const Content = ({ children }) => {
|
|
41
|
-
const placement = usePlacement();
|
|
42
41
|
const popover = usePopoverContext();
|
|
43
42
|
const canHover = useCanHover();
|
|
44
|
-
const translate = {
|
|
45
|
-
top: { translateY: 5 },
|
|
46
|
-
bottom: { translateY: -5 },
|
|
47
|
-
left: { translateX: 5 },
|
|
48
|
-
right: { translateX: -5 }
|
|
49
|
-
}[placement.includes("-") ? placement.split("-")[0] ?? "bottom" : placement];
|
|
50
43
|
return /* @__PURE__ */ jsx(Popover.Content, {
|
|
51
|
-
|
|
52
|
-
closed: {
|
|
53
|
-
...translate,
|
|
54
|
-
opacity: 0,
|
|
55
|
-
transition: { duration: .3 }
|
|
56
|
-
},
|
|
57
|
-
open: {
|
|
58
|
-
translate: 0,
|
|
59
|
-
opacity: 1,
|
|
60
|
-
transition: {
|
|
61
|
-
duration: .4,
|
|
62
|
-
ease: "easeOut"
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
},
|
|
44
|
+
animation: "fade",
|
|
66
45
|
renderItem: ({ id, ref }) => /* @__PURE__ */ jsx("div", {
|
|
67
46
|
className: "bg-bg-inverse text-fg-inverse rounded-lg px-4 py-2 shadow-md",
|
|
68
47
|
id,
|
package/dist/helpers/index.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { cn } from "./cn.mjs";
|
|
2
|
-
import { createSafeContext } from "./create-safe-context.mjs";
|
|
3
2
|
import { chain } from "./chain.mjs";
|
|
4
|
-
import {
|
|
3
|
+
import { createSafeContext } from "./create-safe-context.mjs";
|
|
5
4
|
import { mergeProps } from "./merge-props.mjs";
|
|
5
|
+
import { mergeRefs } from "./merge-refs.mjs";
|
|
6
6
|
export { chain, cn, createSafeContext, mergeProps, mergeRefs };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { RefObject } from "react";
|
|
2
|
+
|
|
3
|
+
//#region src/hooks/focus-trap/index.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* 非モーダルなポップアップのフォーカス管理。
|
|
6
|
+
*
|
|
7
|
+
* floating-ui の `<FloatingFocusManager modal={false}>` 相当を自前で再現する:
|
|
8
|
+
* - 開いたとき、ポップアップ内へ初期フォーカスを移す
|
|
9
|
+
* (内部に roving tabindex のリストがある場合は、そのリストナビゲーション側の
|
|
10
|
+
* フォーカスが後で上書きするため、ここではコンテナ/先頭要素に当てるだけでよい)
|
|
11
|
+
* - 閉じたとき、フォーカスがまだポップアップ内(または喪失)していればトリガーへ戻す。
|
|
12
|
+
* 外側を意図的にクリック/フォーカスした場合は奪い返さない。
|
|
13
|
+
*
|
|
14
|
+
* ハードな Tab トラップや close-on-focus-out は行わない(元実装が modal=false のため)。
|
|
15
|
+
* 外側クリック / Escape による dismiss は呼び出し側が担う。
|
|
16
|
+
*/
|
|
17
|
+
declare const useFocusTrap: (contentRef: RefObject<HTMLElement | null>, triggerRef: RefObject<Element | null>, enabled: boolean) => void;
|
|
18
|
+
//#endregion
|
|
19
|
+
export { useFocusTrap };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useEffect } from "react";
|
|
3
|
+
//#region src/hooks/focus-trap/index.ts
|
|
4
|
+
const FOCUSABLE_SELECTOR = [
|
|
5
|
+
"a[href]",
|
|
6
|
+
"button:not([disabled])",
|
|
7
|
+
"input:not([disabled])",
|
|
8
|
+
"select:not([disabled])",
|
|
9
|
+
"textarea:not([disabled])",
|
|
10
|
+
"[tabindex]:not([tabindex=\"-1\"])",
|
|
11
|
+
"[contenteditable=\"true\"]"
|
|
12
|
+
].join(",");
|
|
13
|
+
/**
|
|
14
|
+
* 非モーダルなポップアップのフォーカス管理。
|
|
15
|
+
*
|
|
16
|
+
* floating-ui の `<FloatingFocusManager modal={false}>` 相当を自前で再現する:
|
|
17
|
+
* - 開いたとき、ポップアップ内へ初期フォーカスを移す
|
|
18
|
+
* (内部に roving tabindex のリストがある場合は、そのリストナビゲーション側の
|
|
19
|
+
* フォーカスが後で上書きするため、ここではコンテナ/先頭要素に当てるだけでよい)
|
|
20
|
+
* - 閉じたとき、フォーカスがまだポップアップ内(または喪失)していればトリガーへ戻す。
|
|
21
|
+
* 外側を意図的にクリック/フォーカスした場合は奪い返さない。
|
|
22
|
+
*
|
|
23
|
+
* ハードな Tab トラップや close-on-focus-out は行わない(元実装が modal=false のため)。
|
|
24
|
+
* 外側クリック / Escape による dismiss は呼び出し側が担う。
|
|
25
|
+
*/
|
|
26
|
+
const useFocusTrap = (contentRef, triggerRef, enabled) => {
|
|
27
|
+
useEffect(() => {
|
|
28
|
+
if (!enabled) return;
|
|
29
|
+
const content = contentRef.current;
|
|
30
|
+
if (!content) return;
|
|
31
|
+
const trigger = triggerRef.current;
|
|
32
|
+
if (!content.contains(document.activeElement)) {
|
|
33
|
+
const first = content.querySelector(FOCUSABLE_SELECTOR);
|
|
34
|
+
if (first) first.focus();
|
|
35
|
+
else {
|
|
36
|
+
content.tabIndex = -1;
|
|
37
|
+
content.focus();
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
return () => {
|
|
41
|
+
const active = document.activeElement;
|
|
42
|
+
if ((active === null || active === document.body || content.contains(active)) && trigger instanceof HTMLElement) trigger.focus();
|
|
43
|
+
};
|
|
44
|
+
}, [
|
|
45
|
+
contentRef,
|
|
46
|
+
triggerRef,
|
|
47
|
+
enabled
|
|
48
|
+
]);
|
|
49
|
+
};
|
|
50
|
+
//#endregion
|
|
51
|
+
export { useFocusTrap };
|
package/dist/hooks/index.mjs
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import { useDisclosure } from "./disclosure/index.mjs";
|
|
2
|
-
import { useWritingMode } from "./writing-mode/index.mjs";
|
|
3
|
-
import { useTimeout } from "./timeout/index.mjs";
|
|
4
1
|
import { useClickAway } from "./click-away/index.mjs";
|
|
5
|
-
import { useControllableState } from "./controllable-state/index.mjs";
|
|
6
2
|
import { useClient } from "./client/index.mjs";
|
|
7
3
|
import { useClipboard } from "./clipboard/index.mjs";
|
|
4
|
+
import { useControllableState } from "./controllable-state/index.mjs";
|
|
8
5
|
import { useDebouncedTransition } from "./debounced-transition/index.mjs";
|
|
9
6
|
import { useDeferredDebounce } from "./deferred-debounce/index.mjs";
|
|
7
|
+
import { useDisclosure } from "./disclosure/index.mjs";
|
|
10
8
|
import { useHash } from "./hash/index.mjs";
|
|
11
9
|
import { useHover } from "./hover/index.mjs";
|
|
12
10
|
import { useIntersectionObserver } from "./intersection-observer/use-intersection-observer.mjs";
|
|
@@ -19,6 +17,8 @@ import { useScrollDirection } from "./scroll-direction/index.mjs";
|
|
|
19
17
|
import { useScrollLock } from "./scroll-lock/index.mjs";
|
|
20
18
|
import { useSessionStorage } from "./session-storage/index.mjs";
|
|
21
19
|
import { useStep } from "./step/index.mjs";
|
|
20
|
+
import { useTimeout } from "./timeout/index.mjs";
|
|
22
21
|
import { useWindowResize } from "./window-resize/index.mjs";
|
|
23
22
|
import { useWindowSize } from "./window-size/index.mjs";
|
|
23
|
+
import { useWritingMode } from "./writing-mode/index.mjs";
|
|
24
24
|
export { useBreakpoint, useClickAway, useClient, useClipboard, useControllableState, useDebouncedTransition, useDeferredDebounce, useDisclosure, useHash, useHover, useInView, useIntersectionObserver, useInterval, useLocalStorage, useResize, useScrollDirection, useScrollLock, useSessionStorage, useStep, useTimeout, useWindowResize, useWindowSize, useWritingMode };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Button } from "./components/buttons/button/button.mjs";
|
|
2
|
+
import { Direction, Option, Status } from "./types/variables.mjs";
|
|
2
3
|
import { Tooltip } from "./components/overlays/tooltip/tooltip.mjs";
|
|
3
4
|
import { IconButton } from "./components/buttons/icon-button/icon-button.mjs";
|
|
4
5
|
import { Accordion } from "./components/data-display/accordion/index.mjs";
|
|
@@ -9,7 +10,6 @@ import { Card } from "./components/data-display/card/card.mjs";
|
|
|
9
10
|
import { Code } from "./components/data-display/code/code.mjs";
|
|
10
11
|
import { Heading } from "./components/data-display/heading/heading.mjs";
|
|
11
12
|
import { Table } from "./components/data-display/table/table.mjs";
|
|
12
|
-
import { Direction, Option, Status } from "./types/variables.mjs";
|
|
13
13
|
import { Alert } from "./components/feedback/alert/alert.mjs";
|
|
14
14
|
import { Progress } from "./components/feedback/progress/progress.mjs";
|
|
15
15
|
import { Skeleton } from "./components/feedback/skeleton/skeleton.mjs";
|
package/dist/index.mjs
CHANGED
|
@@ -1,44 +1,17 @@
|
|
|
1
1
|
import { cn } from "./helpers/cn.mjs";
|
|
2
2
|
import { Spinner } from "./components/feedback/spinner/spinner.mjs";
|
|
3
3
|
import { Button } from "./components/buttons/button/button.mjs";
|
|
4
|
-
import { useDisclosure } from "./hooks/disclosure/index.mjs";
|
|
5
|
-
import { useWritingMode } from "./hooks/writing-mode/index.mjs";
|
|
6
|
-
import { createSafeContext } from "./helpers/create-safe-context.mjs";
|
|
7
|
-
import { useToast } from "./components/feedback/toast/context.mjs";
|
|
8
|
-
import { ArteOdyssey } from "./components/icons/arte-odyssey.mjs";
|
|
9
|
-
import { GitHubIcon } from "./components/icons/github-mark.mjs";
|
|
10
|
-
import { Logo, LogoIcon } from "./components/icons/logo.mjs";
|
|
11
|
-
import { AIIcon, AccessibilityIcon, AlertIcon, AtomIcon, BadIcon, BlogIcon, BoringIcon, CheckIcon, ChevronIcon, CloseIcon, ColorContrastIcon, ColorInfoIcon, CopyIcon, DarkModeIcon, DifficultIcon, EasyIcon, ExternalLinkIcon, FlaskIcon, FormIcon, GoodIcon, HistoryIcon, HorizontalWritingIcon, InformativeIcon, InterestingIcon, LightModeIcon, LinkIcon, ListIcon, LocationIcon, MailIcon, MinusIcon, MixedColorIcon, NavigationMenuIcon, NewsIcon, PackageIcon, PaletteIcon, PlusIcon, PrepareIcon, PublishDateIcon, RSSIcon, SendIcon, ShallowIcon, ShieldCheckIcon, SlideIcon, SparklesIcon, SquircleIcon, SubscribeIcon, TableIcon, TagIcon, UpdateDateIcon, ViewIcon, ViewOffIcon } from "./components/icons/lucide.mjs";
|
|
12
|
-
import { QiitaIcon } from "./components/icons/qiita.mjs";
|
|
13
|
-
import { TwitterIcon } from "./components/icons/twitter.mjs";
|
|
14
|
-
import { VerticalWritingIcon } from "./components/icons/vertical-writing.mjs";
|
|
15
|
-
import { Alert } from "./components/feedback/alert/alert.mjs";
|
|
16
|
-
import { useTimeout } from "./hooks/timeout/index.mjs";
|
|
17
|
-
import { ToastProvider } from "./components/feedback/toast/provider.mjs";
|
|
18
|
-
import { ArteOdysseyProvider } from "./components/providers/arte-odyssey-provider.mjs";
|
|
19
|
-
import { PortalRootProvider, usePortalRoot } from "./components/providers/portal-root.mjs";
|
|
20
|
-
import { useClickAway } from "./hooks/click-away/index.mjs";
|
|
21
|
-
import { useOpenContext } from "./components/overlays/popover/hooks.mjs";
|
|
22
|
-
import { Popover } from "./components/overlays/popover/popover.mjs";
|
|
23
|
-
import { Tooltip } from "./components/overlays/tooltip/tooltip.mjs";
|
|
24
4
|
import { chain } from "./helpers/chain.mjs";
|
|
5
|
+
import { createSafeContext } from "./helpers/create-safe-context.mjs";
|
|
6
|
+
import { mergeProps } from "./helpers/merge-props.mjs";
|
|
25
7
|
import { mergeRefs } from "./helpers/merge-refs.mjs";
|
|
26
|
-
import {
|
|
27
|
-
import { useControllableState } from "./hooks/controllable-state/index.mjs";
|
|
28
|
-
import { Accordion } from "./components/data-display/accordion/index.mjs";
|
|
29
|
-
import { Avatar } from "./components/data-display/avatar/avatar.mjs";
|
|
30
|
-
import { Badge } from "./components/data-display/badge/badge.mjs";
|
|
8
|
+
import { useClickAway } from "./hooks/click-away/index.mjs";
|
|
31
9
|
import { useClient } from "./hooks/client/index.mjs";
|
|
32
|
-
import { BaselineStatus } from "./components/data-display/baseline-status/baseline-status.mjs";
|
|
33
|
-
import { Card } from "./components/data-display/card/card.mjs";
|
|
34
|
-
import { Code } from "./components/data-display/code/code.mjs";
|
|
35
|
-
import { Heading } from "./components/data-display/heading/heading.mjs";
|
|
36
|
-
import { Table } from "./components/data-display/table/table.mjs";
|
|
37
|
-
import { Progress } from "./components/feedback/progress/progress.mjs";
|
|
38
|
-
import { Skeleton } from "./components/feedback/skeleton/skeleton.mjs";
|
|
39
10
|
import { useClipboard } from "./hooks/clipboard/index.mjs";
|
|
11
|
+
import { useControllableState } from "./hooks/controllable-state/index.mjs";
|
|
40
12
|
import { useDebouncedTransition } from "./hooks/debounced-transition/index.mjs";
|
|
41
13
|
import { useDeferredDebounce } from "./hooks/deferred-debounce/index.mjs";
|
|
14
|
+
import { useDisclosure } from "./hooks/disclosure/index.mjs";
|
|
42
15
|
import { useHash } from "./hooks/hash/index.mjs";
|
|
43
16
|
import { useHover } from "./hooks/hover/index.mjs";
|
|
44
17
|
import { useIntersectionObserver } from "./hooks/intersection-observer/use-intersection-observer.mjs";
|
|
@@ -51,8 +24,34 @@ import { useScrollDirection } from "./hooks/scroll-direction/index.mjs";
|
|
|
51
24
|
import { useScrollLock } from "./hooks/scroll-lock/index.mjs";
|
|
52
25
|
import { useSessionStorage } from "./hooks/session-storage/index.mjs";
|
|
53
26
|
import { useStep } from "./hooks/step/index.mjs";
|
|
27
|
+
import { useTimeout } from "./hooks/timeout/index.mjs";
|
|
54
28
|
import { useWindowResize } from "./hooks/window-resize/index.mjs";
|
|
55
29
|
import { useWindowSize } from "./hooks/window-size/index.mjs";
|
|
30
|
+
import { useWritingMode } from "./hooks/writing-mode/index.mjs";
|
|
31
|
+
import { useOpenContext } from "./components/overlays/popover/hooks.mjs";
|
|
32
|
+
import { Popover } from "./components/overlays/popover/popover.mjs";
|
|
33
|
+
import { Tooltip } from "./components/overlays/tooltip/tooltip.mjs";
|
|
34
|
+
import { IconButton } from "./components/buttons/icon-button/icon-button.mjs";
|
|
35
|
+
import { ArteOdyssey } from "./components/icons/arte-odyssey.mjs";
|
|
36
|
+
import { GitHubIcon } from "./components/icons/github-mark.mjs";
|
|
37
|
+
import { Logo, LogoIcon } from "./components/icons/logo.mjs";
|
|
38
|
+
import { AIIcon, AccessibilityIcon, AlertIcon, AtomIcon, BadIcon, BlogIcon, BoringIcon, CheckIcon, ChevronIcon, CloseIcon, ColorContrastIcon, ColorInfoIcon, CopyIcon, DarkModeIcon, DifficultIcon, EasyIcon, ExternalLinkIcon, FlaskIcon, FormIcon, GoodIcon, HistoryIcon, HorizontalWritingIcon, InformativeIcon, InterestingIcon, LightModeIcon, LinkIcon, ListIcon, LocationIcon, MailIcon, MinusIcon, MixedColorIcon, NavigationMenuIcon, NewsIcon, PackageIcon, PaletteIcon, PlusIcon, PrepareIcon, PublishDateIcon, RSSIcon, SendIcon, ShallowIcon, ShieldCheckIcon, SlideIcon, SparklesIcon, SquircleIcon, SubscribeIcon, TableIcon, TagIcon, UpdateDateIcon, ViewIcon, ViewOffIcon } from "./components/icons/lucide.mjs";
|
|
39
|
+
import { QiitaIcon } from "./components/icons/qiita.mjs";
|
|
40
|
+
import { TwitterIcon } from "./components/icons/twitter.mjs";
|
|
41
|
+
import { VerticalWritingIcon } from "./components/icons/vertical-writing.mjs";
|
|
42
|
+
import { Accordion } from "./components/data-display/accordion/index.mjs";
|
|
43
|
+
import { Avatar } from "./components/data-display/avatar/avatar.mjs";
|
|
44
|
+
import { Badge } from "./components/data-display/badge/badge.mjs";
|
|
45
|
+
import { BaselineStatus } from "./components/data-display/baseline-status/baseline-status.mjs";
|
|
46
|
+
import { Card } from "./components/data-display/card/card.mjs";
|
|
47
|
+
import { Code } from "./components/data-display/code/code.mjs";
|
|
48
|
+
import { Heading } from "./components/data-display/heading/heading.mjs";
|
|
49
|
+
import { Table } from "./components/data-display/table/table.mjs";
|
|
50
|
+
import { Alert } from "./components/feedback/alert/alert.mjs";
|
|
51
|
+
import { Progress } from "./components/feedback/progress/progress.mjs";
|
|
52
|
+
import { Skeleton } from "./components/feedback/skeleton/skeleton.mjs";
|
|
53
|
+
import { useToast } from "./components/feedback/toast/context.mjs";
|
|
54
|
+
import { ToastProvider } from "./components/feedback/toast/provider.mjs";
|
|
56
55
|
import { Autocomplete } from "./components/form/autocomplete/autocomplete.mjs";
|
|
57
56
|
import { Checkbox } from "./components/form/checkbox/checkbox.mjs";
|
|
58
57
|
import { CheckboxCard } from "./components/form/checkbox-card/checkbox-card.mjs";
|
|
@@ -78,9 +77,10 @@ import { Breadcrumb } from "./components/navigation/breadcrumb/breadcrumb.mjs";
|
|
|
78
77
|
import { Pagination } from "./components/navigation/pagination/pagination.mjs";
|
|
79
78
|
import { Tabs } from "./components/navigation/tabs/tabs.mjs";
|
|
80
79
|
import { Dialog } from "./components/overlays/dialog/dialog.mjs";
|
|
80
|
+
import { ArteOdysseyProvider } from "./components/providers/arte-odyssey-provider.mjs";
|
|
81
|
+
import { PortalRootProvider, usePortalRoot } from "./components/providers/portal-root.mjs";
|
|
81
82
|
import { Modal } from "./components/overlays/modal/modal.mjs";
|
|
82
83
|
import { Drawer } from "./components/overlays/drawer/drawer.mjs";
|
|
83
84
|
import { DropdownMenu } from "./components/overlays/dropdown-menu/dropdown-menu.mjs";
|
|
84
85
|
import { ListBox } from "./components/overlays/list-box/list-box.mjs";
|
|
85
|
-
import { mergeProps } from "./helpers/merge-props.mjs";
|
|
86
86
|
export { AIIcon, AccessibilityIcon, Accordion, Alert, AlertIcon, Anchor, ArteOdyssey, ArteOdysseyProvider, AtomIcon, Autocomplete, Avatar, BadIcon, Badge, BaselineStatus, BlogIcon, BoringIcon, Breadcrumb, Button, Card, CheckIcon, Checkbox, CheckboxCard, CheckboxGroup, ChevronIcon, CloseIcon, Code, ColorContrastIcon, ColorInfoIcon, CopyIcon, DarkModeIcon, Dialog, DifficultIcon, Drawer, DropdownMenu, EasyIcon, ExternalLinkIcon, FileField, FlaskIcon, Form, FormControl, FormIcon, GitHubIcon, GoodIcon, Grid, Heading, HistoryIcon, HorizontalWritingIcon, IconButton, InformativeIcon, InterestingIcon, LightModeIcon, LinkIcon, ListBox, ListIcon, LocationIcon, Logo, LogoIcon, MailIcon, MinusIcon, MixedColorIcon, Modal, NavigationMenuIcon, NewsIcon, NumberField, PackageIcon, Pagination, PaletteIcon, PasswordInput, PlusIcon, Popover, PortalRootProvider, PrepareIcon, Progress, PublishDateIcon, QiitaIcon, RSSIcon, Radio, RadioCard, ScrollLinked, Select, SendIcon, Separator, ShallowIcon, ShieldCheckIcon, Skeleton, SlideIcon, Slider, SparklesIcon, Spinner, SquircleIcon, Stack, SubscribeIcon, Switch, Table, TableIcon, Tabs, TagIcon, TextField, Textarea, ToastProvider, Tooltip, TwitterIcon, UpdateDateIcon, VerticalWritingIcon, ViewIcon, ViewOffIcon, chain, cn, createSafeContext, mergeProps, mergeRefs, useBreakpoint, useClickAway, useClient, useClipboard, useControllableState, useDebouncedTransition, useDeferredDebounce, useDisclosure, useHash, useHover, useInView, useIntersectionObserver, useInterval, useLocalStorage, useOpenContext, usePortalRoot, useResize, useScrollDirection, useScrollLock, useSessionStorage, useStep, useTimeout, useToast, useWindowResize, useWindowSize, useWritingMode };
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { Spinner } from "../../components/feedback/spinner/spinner.mjs";
|
|
3
3
|
import { Button } from "../../components/buttons/button/button.mjs";
|
|
4
|
-
import {
|
|
4
|
+
import { Popover } from "../../components/overlays/popover/popover.mjs";
|
|
5
|
+
import { Tooltip } from "../../components/overlays/tooltip/tooltip.mjs";
|
|
6
|
+
import { IconButton } from "../../components/buttons/icon-button/icon-button.mjs";
|
|
5
7
|
import { ArteOdyssey } from "../../components/icons/arte-odyssey.mjs";
|
|
6
8
|
import { GitHubIcon } from "../../components/icons/github-mark.mjs";
|
|
7
9
|
import { LogoIcon } from "../../components/icons/logo.mjs";
|
|
@@ -9,11 +11,6 @@ import { AIIcon, AccessibilityIcon, AlertIcon, AtomIcon, BadIcon, BlogIcon, Bori
|
|
|
9
11
|
import { QiitaIcon } from "../../components/icons/qiita.mjs";
|
|
10
12
|
import { TwitterIcon } from "../../components/icons/twitter.mjs";
|
|
11
13
|
import { VerticalWritingIcon } from "../../components/icons/vertical-writing.mjs";
|
|
12
|
-
import { Alert } from "../../components/feedback/alert/alert.mjs";
|
|
13
|
-
import { ToastProvider } from "../../components/feedback/toast/provider.mjs";
|
|
14
|
-
import { Popover } from "../../components/overlays/popover/popover.mjs";
|
|
15
|
-
import { Tooltip } from "../../components/overlays/tooltip/tooltip.mjs";
|
|
16
|
-
import { IconButton } from "../../components/buttons/icon-button/icon-button.mjs";
|
|
17
14
|
import { Accordion } from "../../components/data-display/accordion/index.mjs";
|
|
18
15
|
import { Avatar } from "../../components/data-display/avatar/avatar.mjs";
|
|
19
16
|
import { Badge } from "../../components/data-display/badge/badge.mjs";
|
|
@@ -22,8 +19,11 @@ import { Card } from "../../components/data-display/card/card.mjs";
|
|
|
22
19
|
import { Code } from "../../components/data-display/code/code.mjs";
|
|
23
20
|
import { Heading } from "../../components/data-display/heading/heading.mjs";
|
|
24
21
|
import { Table } from "../../components/data-display/table/table.mjs";
|
|
22
|
+
import { Alert } from "../../components/feedback/alert/alert.mjs";
|
|
25
23
|
import { Progress } from "../../components/feedback/progress/progress.mjs";
|
|
26
24
|
import { Skeleton } from "../../components/feedback/skeleton/skeleton.mjs";
|
|
25
|
+
import { useToast } from "../../components/feedback/toast/context.mjs";
|
|
26
|
+
import { ToastProvider } from "../../components/feedback/toast/provider.mjs";
|
|
27
27
|
import { Autocomplete } from "../../components/form/autocomplete/autocomplete.mjs";
|
|
28
28
|
import { Checkbox } from "../../components/form/checkbox/checkbox.mjs";
|
|
29
29
|
import { CheckboxCard } from "../../components/form/checkbox-card/checkbox-card.mjs";
|