@ariakit/solid-components 0.1.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.
Files changed (94) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/dist/as/as.d.ts +30 -0
  3. package/dist/as/as.d.ts.map +1 -0
  4. package/dist/as/as.js +40 -0
  5. package/dist/as/as.js.map +1 -0
  6. package/dist/focus-trap/focus-trap-region.d.ts +42 -0
  7. package/dist/focus-trap/focus-trap-region.d.ts.map +1 -0
  8. package/dist/focus-trap/focus-trap-region.js +71 -0
  9. package/dist/focus-trap/focus-trap-region.js.map +1 -0
  10. package/dist/focus-trap/focus-trap.d.ts +31 -0
  11. package/dist/focus-trap/focus-trap.d.ts.map +1 -0
  12. package/dist/focus-trap/focus-trap.js +42 -0
  13. package/dist/focus-trap/focus-trap.js.map +1 -0
  14. package/dist/group/group-label-context.d.ts +7 -0
  15. package/dist/group/group-label-context.d.ts.map +1 -0
  16. package/dist/group/group-label-context.js +7 -0
  17. package/dist/group/group-label-context.js.map +1 -0
  18. package/dist/group/group-label.d.ts +37 -0
  19. package/dist/group/group-label.d.ts.map +1 -0
  20. package/dist/group/group-label.js +51 -0
  21. package/dist/group/group-label.js.map +1 -0
  22. package/dist/group/group.d.ts +32 -0
  23. package/dist/group/group.d.ts.map +1 -0
  24. package/dist/group/group.js +49 -0
  25. package/dist/group/group.js.map +1 -0
  26. package/dist/heading/heading-context.d.ts +8 -0
  27. package/dist/heading/heading-context.d.ts.map +1 -0
  28. package/dist/heading/heading-context.js +7 -0
  29. package/dist/heading/heading-context.js.map +1 -0
  30. package/dist/heading/heading-level.d.ts +32 -0
  31. package/dist/heading/heading-level.d.ts.map +1 -0
  32. package/dist/heading/heading-level.js +34 -0
  33. package/dist/heading/heading-level.js.map +1 -0
  34. package/dist/heading/heading.d.ts +42 -0
  35. package/dist/heading/heading.d.ts.map +1 -0
  36. package/dist/heading/heading.js +57 -0
  37. package/dist/heading/heading.js.map +1 -0
  38. package/dist/heading/utils.d.ts +5 -0
  39. package/dist/heading/utils.d.ts.map +1 -0
  40. package/dist/heading/utils.js +0 -0
  41. package/dist/role/role.d.ts +34 -0
  42. package/dist/role/role.d.ts.map +1 -0
  43. package/dist/role/role.js +67 -0
  44. package/dist/role/role.js.map +1 -0
  45. package/dist/separator/separator.d.ts +36 -0
  46. package/dist/separator/separator.d.ts.map +1 -0
  47. package/dist/separator/separator.js +36 -0
  48. package/dist/separator/separator.js.map +1 -0
  49. package/dist/visually-hidden/visually-hidden.d.ts +37 -0
  50. package/dist/visually-hidden/visually-hidden.d.ts.map +1 -0
  51. package/dist/visually-hidden/visually-hidden.js +48 -0
  52. package/dist/visually-hidden/visually-hidden.js.map +1 -0
  53. package/index.ts +1 -0
  54. package/license +21 -0
  55. package/package.json +113 -0
  56. package/readme.md +19 -0
  57. package/solid/as/as.jsx +38 -0
  58. package/solid/as/as.jsx.map +1 -0
  59. package/solid/focus-trap/focus-trap-region.jsx +65 -0
  60. package/solid/focus-trap/focus-trap-region.jsx.map +1 -0
  61. package/solid/focus-trap/focus-trap.jsx +42 -0
  62. package/solid/focus-trap/focus-trap.jsx.map +1 -0
  63. package/solid/group/group-label-context.jsx +7 -0
  64. package/solid/group/group-label-context.jsx.map +1 -0
  65. package/solid/group/group-label.jsx +51 -0
  66. package/solid/group/group-label.jsx.map +1 -0
  67. package/solid/group/group.jsx +43 -0
  68. package/solid/group/group.jsx.map +1 -0
  69. package/solid/heading/heading-context.jsx +7 -0
  70. package/solid/heading/heading-context.jsx.map +1 -0
  71. package/solid/heading/heading-level.jsx +30 -0
  72. package/solid/heading/heading-level.jsx.map +1 -0
  73. package/solid/heading/heading.jsx +57 -0
  74. package/solid/heading/heading.jsx.map +1 -0
  75. package/solid/heading/utils.jsx +0 -0
  76. package/solid/role/role.jsx +67 -0
  77. package/solid/role/role.jsx.map +1 -0
  78. package/solid/separator/separator.jsx +36 -0
  79. package/solid/separator/separator.jsx.map +1 -0
  80. package/solid/visually-hidden/visually-hidden.jsx +48 -0
  81. package/solid/visually-hidden/visually-hidden.jsx.map +1 -0
  82. package/src/as/as.tsx +62 -0
  83. package/src/focus-trap/focus-trap-region.tsx +108 -0
  84. package/src/focus-trap/focus-trap.tsx +61 -0
  85. package/src/group/group-label-context.tsx +4 -0
  86. package/src/group/group-label.tsx +76 -0
  87. package/src/group/group.tsx +68 -0
  88. package/src/heading/heading-context.tsx +5 -0
  89. package/src/heading/heading-level.tsx +43 -0
  90. package/src/heading/heading.tsx +87 -0
  91. package/src/heading/utils.ts +1 -0
  92. package/src/role/role.tsx +91 -0
  93. package/src/separator/separator.tsx +66 -0
  94. package/src/visually-hidden/visually-hidden.tsx +63 -0
@@ -0,0 +1,34 @@
1
+ import { HeadingContext } from "./heading-context.js";
2
+ import { createComponent } from "solid-js/web";
3
+ import { useContext } from "solid-js";
4
+ //#region src/heading/heading-level.tsx
5
+ /**
6
+ * A component that sets the heading level for its children. It doesn't render
7
+ * any HTML element, just sets the
8
+ * [`level`](https://solid.ariakit.com/reference/heading-level#level) prop on the
9
+ * context.
10
+ * @see https://solid.ariakit.com/components/heading
11
+ * @example
12
+ * ```jsx
13
+ * <HeadingLevel>
14
+ * <Heading>Heading 1</Heading>
15
+ * <HeadingLevel>
16
+ * <Heading>Heading 2</Heading>
17
+ * </HeadingLevel>
18
+ * </HeadingLevel>
19
+ * ```
20
+ */
21
+ function HeadingLevel(props) {
22
+ const contextLevel = useContext(HeadingContext);
23
+ const nextLevel = () => Math.max(Math.min(props.level || (contextLevel?.() ?? 0) + 1, 6), 1);
24
+ return createComponent(HeadingContext.Provider, {
25
+ value: nextLevel,
26
+ get children() {
27
+ return props.children;
28
+ }
29
+ });
30
+ }
31
+ //#endregion
32
+ export { HeadingLevel };
33
+
34
+ //# sourceMappingURL=heading-level.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"heading-level.js","names":["JSX","useContext","HeadingContext","HeadingLevels","HeadingLevel","props","HeadingLevelProps","contextLevel","nextLevel","Math","max","min","level","_$createComponent","Provider","value","children","Element"],"sources":["../../src/heading/heading-level.tsx"],"sourcesContent":["import type { JSX } from \"solid-js\";\nimport { useContext } from \"solid-js\";\nimport { HeadingContext } from \"./heading-context.tsx\";\nimport type { HeadingLevels } from \"./utils.ts\";\n\n/**\n * A component that sets the heading level for its children. It doesn't render\n * any HTML element, just sets the\n * [`level`](https://solid.ariakit.com/reference/heading-level#level) prop on the\n * context.\n * @see https://solid.ariakit.com/components/heading\n * @example\n * ```jsx\n * <HeadingLevel>\n * <Heading>Heading 1</Heading>\n * <HeadingLevel>\n * <Heading>Heading 2</Heading>\n * </HeadingLevel>\n * </HeadingLevel>\n * ```\n */\nexport function HeadingLevel(props: HeadingLevelProps) {\n const contextLevel = useContext(HeadingContext);\n const nextLevel = () =>\n Math.max(\n Math.min(props.level || (contextLevel?.() ?? 0) + 1, 6),\n 1,\n ) as HeadingLevels;\n return (\n <HeadingContext.Provider value={nextLevel}>\n {props.children}\n </HeadingContext.Provider>\n );\n}\n\nexport interface HeadingLevelProps {\n /**\n * The heading level. By default, it'll increase the level by 1 based on the\n * context.\n */\n level?: HeadingLevels;\n children?: JSX.Element;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAqBA,SAAgBI,aAAaC,OAA0B;CACrD,MAAME,eAAeN,WAAWC,cAAc;CAC9C,MAAMM,kBACJC,KAAKC,IACHD,KAAKE,IAAIN,MAAMO,UAAUL,eAAe,KAAK,KAAK,GAAG,CAAC,GACtD,CACF;CACF,OAAAM,gBACGX,eAAeY,UAAQ;EAACC,OAAOP;EAAS,IAAAQ,WAAA;GAAA,OACtCX,MAAMW;EAAQ;CAAA,CAAA;AAGrB"}
@@ -0,0 +1,42 @@
1
+ import { HeadingLevels } from "./utils.js";
2
+ import { ValidComponent } from "solid-js";
3
+ import { Options, Props } from "@ariakit/solid-utils";
4
+
5
+ //#region src/heading/heading.d.ts
6
+ type HeadingElements = `h${HeadingLevels}`;
7
+ declare const TagName = "h1";
8
+ type TagName = HeadingElements;
9
+ /**
10
+ * Returns props to create a `Heading` component. The element type (or the
11
+ * `aria-level` prop, if the element type is not a native heading) is determined
12
+ * by the context level provided by the parent `HeadingLevel` component.
13
+ * @see https://solid.ariakit.com/components/heading
14
+ * @example
15
+ * ```jsx
16
+ * const props = useHeading();
17
+ * <Role {...props}>Heading</Role>
18
+ * ```
19
+ */
20
+ declare const useHeading: import("@ariakit/solid-utils").Hook<"h1" | "h2" | "h3" | "h4" | "h5" | "h6", HeadingOptions<"h1" | "h2" | "h3" | "h4" | "h5" | "h6">>;
21
+ /**
22
+ * Renders a heading element. The element type (or the `aria-level` attribute,
23
+ * if the element type is not a native heading) is determined by the context
24
+ * level provided by the closest
25
+ * [`HeadingLevel`](https://solid.ariakit.com/reference/heading-level) ancestor.
26
+ * @see https://solid.ariakit.com/components/heading
27
+ * @example
28
+ * ```jsx
29
+ * <HeadingLevel>
30
+ * <Heading>Heading 1</Heading>
31
+ * <HeadingLevel>
32
+ * <Heading>Heading 2</Heading>
33
+ * </HeadingLevel>
34
+ * </HeadingLevel>
35
+ * ```
36
+ */
37
+ declare const Heading: (props: HeadingProps) => import("solid-js").JSX.Element;
38
+ interface HeadingOptions<_T extends ValidComponent = TagName> extends Options {}
39
+ type HeadingProps<T extends ValidComponent = TagName> = Props<T, HeadingOptions<T>>;
40
+ //#endregion
41
+ export { Heading, HeadingOptions, HeadingProps, useHeading };
42
+ //# sourceMappingURL=heading.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"heading.d.ts","names":["Options","Props","ValidComponent","HeadingLevels","HeadingElements","TagName","useHeading","HeadingOptions","Hook","Heading","HeadingProps","props","JSX","Element","_T","T"],"sources":["../../src/heading/heading.d.ts"],"mappings":";;;;;KAGKI,eAAAA,OAAsBD,aAAa;AAAA,cAC1BE,OAAAA;AAAAA,KACTA,OAAAA,GAAUD,eAAe;;;;AAFU;AAAA;;;;AACnB;AAAA;;cAaAE,UAAAA,iCAA2CE,IAAAA,0CAA8CD,cAAc;;AAZ9F;AAY9B;;;;AAA4H;AAiB5H;;;;;;;;;cAAqBE,OAAAA,GAAUE,KAAAA,EAAOD,YAAY,wBAAwBE,GAAAA,CAAIC,OAAAA;AAAAA,UAC7DN,cAAAA,YAA0BL,cAAAA,GAAiBG,OAAAA,UAAiBL,OAAAA;AAAAA,KAEjEU,YAAAA,WAAuBR,cAAAA,GAAiBG,OAAAA,IAAWJ,KAAAA,CAAMc,CAAAA,EAAGR,cAAAA,CAAeQ,CAAAA"}
@@ -0,0 +1,57 @@
1
+ import { HeadingContext } from "./heading-context.js";
2
+ import { createHook, createInstance, createRef, extractTagName, mergeProps } from "@ariakit/solid-utils";
3
+ import { createMemo, useContext } from "solid-js";
4
+ //#region src/heading/heading.tsx
5
+ const TagName = "h1";
6
+ /**
7
+ * Returns props to create a `Heading` component. The element type (or the
8
+ * `aria-level` prop, if the element type is not a native heading) is determined
9
+ * by the context level provided by the parent `HeadingLevel` component.
10
+ * @see https://solid.ariakit.com/components/heading
11
+ * @example
12
+ * ```jsx
13
+ * const props = useHeading();
14
+ * <Role {...props}>Heading</Role>
15
+ * ```
16
+ */
17
+ const useHeading = createHook(function useHeading(props) {
18
+ const ref = createRef();
19
+ const level = useContext(HeadingContext) || (() => 1);
20
+ const Element = () => `h${level()}`;
21
+ const tagName = extractTagName(ref.get);
22
+ const isNativeHeading = createMemo(() => !!tagName() && /^h\d$/.test(tagName()));
23
+ props = mergeProps({
24
+ render: Element(),
25
+ get role() {
26
+ return !isNativeHeading() ? "heading" : void 0;
27
+ },
28
+ get "aria-level"() {
29
+ return !isNativeHeading() ? level() : void 0;
30
+ },
31
+ ref: ref.set
32
+ }, props);
33
+ return props;
34
+ });
35
+ /**
36
+ * Renders a heading element. The element type (or the `aria-level` attribute,
37
+ * if the element type is not a native heading) is determined by the context
38
+ * level provided by the closest
39
+ * [`HeadingLevel`](https://solid.ariakit.com/reference/heading-level) ancestor.
40
+ * @see https://solid.ariakit.com/components/heading
41
+ * @example
42
+ * ```jsx
43
+ * <HeadingLevel>
44
+ * <Heading>Heading 1</Heading>
45
+ * <HeadingLevel>
46
+ * <Heading>Heading 2</Heading>
47
+ * </HeadingLevel>
48
+ * </HeadingLevel>
49
+ * ```
50
+ */
51
+ const Heading = function Heading(props) {
52
+ return createInstance(TagName, useHeading(props));
53
+ };
54
+ //#endregion
55
+ export { Heading, useHeading };
56
+
57
+ //# sourceMappingURL=heading.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"heading.js","names":["extractTagName","createRef","mergeProps","createHook","createInstance","Options","Props","ValidComponent","createMemo","useContext","HeadingContext","HeadingLevels","HeadingElements","TagName","HTMLType","HTMLElementTagNameMap","useHeading","HeadingOptions","props","ref","level","Element","const","tagName","get","isNativeHeading","test","render","role","undefined","aria-level","set","Heading","HeadingProps","htmlProps","T"],"sources":["../../src/heading/heading.tsx"],"sourcesContent":["import {\n extractTagName,\n createRef,\n mergeProps,\n createHook,\n createInstance,\n} from \"@ariakit/solid-utils\";\nimport type { Options, Props } from \"@ariakit/solid-utils\";\nimport type { ValidComponent } from \"solid-js\";\nimport { createMemo, useContext } from \"solid-js\";\nimport { HeadingContext } from \"./heading-context.tsx\";\nimport type { HeadingLevels } from \"./utils.ts\";\n\ntype HeadingElements = `h${HeadingLevels}`;\nconst TagName = \"h1\" satisfies ValidComponent;\ntype TagName = HeadingElements;\ntype HTMLType = HTMLElementTagNameMap[TagName];\n\n/**\n * Returns props to create a `Heading` component. The element type (or the\n * `aria-level` prop, if the element type is not a native heading) is determined\n * by the context level provided by the parent `HeadingLevel` component.\n * @see https://solid.ariakit.com/components/heading\n * @example\n * ```jsx\n * const props = useHeading();\n * <Role {...props}>Heading</Role>\n * ```\n */\nexport const useHeading = createHook<TagName, HeadingOptions>(\n function useHeading(props) {\n const ref = createRef<HTMLType>();\n const level = useContext(HeadingContext) || (() => 1);\n const Element = () => `h${level()}` as const;\n const tagName = extractTagName(ref.get);\n const isNativeHeading = createMemo(\n () => !!tagName() && /^h\\d$/.test(tagName()!),\n );\n\n props = mergeProps(\n {\n // TODO: replace with LazyDynamic\n render: Element(),\n get role() {\n return !isNativeHeading() ? \"heading\" : undefined;\n },\n get \"aria-level\"() {\n return !isNativeHeading() ? level() : undefined;\n },\n ref: ref.set,\n },\n props,\n );\n\n return props;\n },\n);\n\n/**\n * Renders a heading element. The element type (or the `aria-level` attribute,\n * if the element type is not a native heading) is determined by the context\n * level provided by the closest\n * [`HeadingLevel`](https://solid.ariakit.com/reference/heading-level) ancestor.\n * @see https://solid.ariakit.com/components/heading\n * @example\n * ```jsx\n * <HeadingLevel>\n * <Heading>Heading 1</Heading>\n * <HeadingLevel>\n * <Heading>Heading 2</Heading>\n * </HeadingLevel>\n * </HeadingLevel>\n * ```\n */\nexport const Heading = function Heading(props: HeadingProps) {\n const htmlProps = useHeading(props);\n return createInstance(TagName, htmlProps);\n};\n\nexport interface HeadingOptions<\n _T extends ValidComponent = TagName,\n> extends Options {}\n\nexport type HeadingProps<T extends ValidComponent = TagName> = Props<\n T,\n HeadingOptions<T>\n>;\n"],"mappings":";;;;AAcA,MAAMa,UAAU;;;;;;;;;;;;AAehB,MAAaG,aAAab,WACxB,SAASa,WAAWE,OAAO;CACzB,MAAMC,MAAMlB,UAAoB;CAChC,MAAMmB,QAAQX,WAAWC,cAAc,YAAY;CACnD,MAAMW,gBAAgB,IAAID,MAAM;CAChC,MAAMG,UAAUvB,eAAemB,IAAIK,GAAG;CACtC,MAAMC,kBAAkBjB,iBAChB,CAAC,CAACe,QAAQ,KAAK,QAAQG,KAAKH,QAAQ,CAAE,CAC9C;CAEAL,QAAQhB,WACN;EAEEyB,QAAQN,QAAQ;EAChB,IAAIO,OAAO;GACT,OAAO,CAACH,gBAAgB,IAAI,YAAYI,KAAAA;EAC1C;EACA,IAAI,eAAe;GACjB,OAAO,CAACJ,gBAAgB,IAAIL,MAAM,IAAIS,KAAAA;EACxC;EACAV,KAAKA,IAAIY;CACX,GACAb,KACF;CAEA,OAAOA;AACT,CACF;;;;;;;;;;;;;;;;;AAkBA,MAAac,UAAU,SAASA,QAAQd,OAAqB;CAE3D,OAAOd,eAAeS,SADJG,WAAWE,KACEgB,CAAS;AAC1C"}
@@ -0,0 +1,5 @@
1
+ //#region src/heading/utils.d.ts
2
+ type HeadingLevels = 1 | 2 | 3 | 4 | 5 | 6;
3
+ //#endregion
4
+ export { HeadingLevels };
5
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","names":["HeadingLevels"],"sources":["../../src/heading/utils.d.ts"],"mappings":";KAAYA,aAAAA"}
File without changes
@@ -0,0 +1,34 @@
1
+ import { Component, ValidComponent } from "solid-js";
2
+ import { Options, Props } from "@ariakit/solid-utils";
3
+
4
+ //#region src/role/role.d.ts
5
+ declare const TagName = "div";
6
+ type TagName = typeof TagName;
7
+ declare const elements: readonly ["a", "button", "details", "dialog", "div", "form", "h1", "h2", "h3", "h4", "h5", "h6", "header", "img", "input", "label", "li", "nav", "ol", "p", "section", "select", "span", "summary", "textarea", "ul", "svg"];
8
+ type RoleElements = { [K in (typeof elements)[number]]: Component<RoleProps<K>> };
9
+ /**
10
+ * Returns props to create a `Role` component.
11
+ * @see https://solid.ariakit.com/components/role
12
+ * @example
13
+ * ```jsx
14
+ * const props = useRole();
15
+ * <Role {...props} />
16
+ * ```
17
+ */
18
+ declare const useRole: import("@ariakit/solid-utils").Hook<"div", RoleOptions<"div">>;
19
+ /**
20
+ * Renders an abstract element that supports the `render` prop and a
21
+ * `wrapInstance` prop that can be used to wrap the underlying component
22
+ * instance with Solid Portal, Context or other component types.
23
+ * @see https://solid.ariakit.com/components/role
24
+ * @example
25
+ * ```jsx
26
+ * <Role render={<As.div />} />
27
+ * ```
28
+ */
29
+ declare const Role: Component<RoleProps> & RoleElements;
30
+ interface RoleOptions<_T extends ValidComponent = TagName> extends Options {}
31
+ type RoleProps<T extends ValidComponent = TagName> = Props<T, RoleOptions>;
32
+ //#endregion
33
+ export { Role, RoleOptions, RoleProps, elements, useRole };
34
+ //# sourceMappingURL=role.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"role.d.ts","names":["Options","Props","Component","ValidComponent","TagName","elements","RoleElements","K","RoleProps","useRole","RoleOptions","Hook","Role","_T","T"],"sources":["../../src/role/role.d.ts"],"mappings":";;;;cAEcI,OAAAA;AAAAA,KACTA,OAAAA,UAAiBA,OAAO;AAAA,cACRC,QAAAA;AAAAA,KAChBC,YAAAA,mBACaD,QAAAA,YAAoBH,SAAAA,CAAUM,SAAAA,CAAUD,CAAAA;AAJrC;AAAA;;;;AACQ;AAC7B;;;AAFqB,cAeAE,OAAAA,iCAAwCE,IAAAA,QAAYD,WAAW;AAbuK;AAAC;;;;;;;;;AAAD,cAwBtOE,IAAAA,EAAMV,SAAAA,CAAUM,SAAAA,IAAaF,YAAAA;AAAAA,UACjCI,WAAAA,YAAuBP,cAAAA,GAAiBC,OAAAA,UAAiBJ,OAAAA;AAAAA,KAE9DQ,SAAAA,WAAoBL,cAAAA,GAAiBC,OAAAA,IAAWH,KAAAA,CAAMa,CAAAA,EAAGJ,WAAAA"}
@@ -0,0 +1,67 @@
1
+ import { createHook, createInstance } from "@ariakit/solid-utils";
2
+ //#region src/role/role.tsx
3
+ const TagName = "div";
4
+ const elements = [
5
+ "a",
6
+ "button",
7
+ "details",
8
+ "dialog",
9
+ "div",
10
+ "form",
11
+ "h1",
12
+ "h2",
13
+ "h3",
14
+ "h4",
15
+ "h5",
16
+ "h6",
17
+ "header",
18
+ "img",
19
+ "input",
20
+ "label",
21
+ "li",
22
+ "nav",
23
+ "ol",
24
+ "p",
25
+ "section",
26
+ "select",
27
+ "span",
28
+ "summary",
29
+ "textarea",
30
+ "ul",
31
+ "svg"
32
+ ];
33
+ /**
34
+ * Returns props to create a `Role` component.
35
+ * @see https://solid.ariakit.com/components/role
36
+ * @example
37
+ * ```jsx
38
+ * const props = useRole();
39
+ * <Role {...props} />
40
+ * ```
41
+ */
42
+ const useRole = createHook(function useRole(props) {
43
+ return props;
44
+ });
45
+ /**
46
+ * Renders an abstract element that supports the `render` prop and a
47
+ * `wrapInstance` prop that can be used to wrap the underlying component
48
+ * instance with Solid Portal, Context or other component types.
49
+ * @see https://solid.ariakit.com/components/role
50
+ * @example
51
+ * ```jsx
52
+ * <Role render={<As.div />} />
53
+ * ```
54
+ */
55
+ const Role = function Role(props) {
56
+ return createInstance(TagName, props);
57
+ };
58
+ Object.assign(Role, elements.reduce((acc, element) => {
59
+ acc[element] = function Role(props) {
60
+ return createInstance(element, props);
61
+ };
62
+ return acc;
63
+ }, {}));
64
+ //#endregion
65
+ export { Role, elements, useRole };
66
+
67
+ //# sourceMappingURL=role.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"role.js","names":["createHook","createInstance","Options","Props","Component","JSX","ValidComponent","TagName","elements","const","RoleElements","RoleProps","K","useRole","RoleOptions","props","Role","Element","Object","assign","reduce","acc","element","T"],"sources":["../../src/role/role.tsx"],"sourcesContent":["import { createHook, createInstance } from \"@ariakit/solid-utils\";\nimport type { Options, Props } from \"@ariakit/solid-utils\";\nimport type { Component, JSX, ValidComponent } from \"solid-js\";\n\nconst TagName = \"div\" satisfies ValidComponent;\ntype TagName = typeof TagName;\n\nexport const elements = [\n \"a\",\n \"button\",\n \"details\",\n \"dialog\",\n \"div\",\n \"form\",\n \"h1\",\n \"h2\",\n \"h3\",\n \"h4\",\n \"h5\",\n \"h6\",\n \"header\",\n \"img\",\n \"input\",\n \"label\",\n \"li\",\n \"nav\",\n \"ol\",\n \"p\",\n \"section\",\n \"select\",\n \"span\",\n \"summary\",\n \"textarea\",\n \"ul\",\n \"svg\",\n] as const;\n\ntype RoleElements = {\n [K in (typeof elements)[number]]: Component<RoleProps<K>>;\n};\n\n/**\n * Returns props to create a `Role` component.\n * @see https://solid.ariakit.com/components/role\n * @example\n * ```jsx\n * const props = useRole();\n * <Role {...props} />\n * ```\n */\nexport const useRole = createHook<TagName, RoleOptions>(\n function useRole(props) {\n return props;\n },\n);\n\n// TODO: adapt docs wording to be more accurate for Solid\n/**\n * Renders an abstract element that supports the `render` prop and a\n * `wrapInstance` prop that can be used to wrap the underlying component\n * instance with Solid Portal, Context or other component types.\n * @see https://solid.ariakit.com/components/role\n * @example\n * ```jsx\n * <Role render={<As.div />} />\n * ```\n */\nexport const Role = function Role(props: RoleProps): JSX.Element {\n return createInstance(TagName, props);\n} as Component<RoleProps> & RoleElements;\n\nObject.assign(\n Role,\n elements.reduce((acc, element) => {\n acc[element] = function Role(\n props: RoleProps<typeof element>,\n ): JSX.Element {\n return createInstance(element, props);\n };\n return acc;\n }, {} as RoleElements),\n);\n\nexport interface RoleOptions<\n _T extends ValidComponent = TagName,\n> extends Options {}\n\nexport type RoleProps<T extends ValidComponent = TagName> = Props<\n T,\n RoleOptions\n>;\n"],"mappings":";;AAIA,MAAMO,UAAU;AAGhB,MAAaC,WAAW;CACtB;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AAAK;;;;;;;;;;AAgBP,MAAaK,UAAUb,WACrB,SAASa,QAAQE,OAAO;CACtB,OAAOA;AACT,CACF;;;;;;;;;;;AAaA,MAAaC,OAAO,SAASA,KAAKD,OAA+B;CAC/D,OAAOd,eAAeM,SAASQ,KAAK;AACtC;AAEAG,OAAOC,OACLH,MACAR,SAASY,QAAQC,KAAKC,YAAY;CAChCD,IAAIC,WAAW,SAASN,KACtBD,OACa;EACb,OAAOd,eAAeqB,SAASP,KAAK;CACtC;CACA,OAAOM;AACT,GAAG,CAAC,CAAiB,CACvB"}
@@ -0,0 +1,36 @@
1
+ import { ValidComponent } from "solid-js";
2
+ import { Options, Props } from "@ariakit/solid-utils";
3
+
4
+ //#region src/separator/separator.d.ts
5
+ declare const TagName = "hr";
6
+ type TagName = typeof TagName;
7
+ /**
8
+ * Returns props to create a `Separator` component.
9
+ * @see https://solid.ariakit.com/components/separator
10
+ * @example
11
+ * ```jsx
12
+ * const props = useSeparator({ orientation: "horizontal" });
13
+ * <Role {...props} />
14
+ * ```
15
+ */
16
+ declare const useSeparator: import("@ariakit/solid-utils").Hook<"hr", SeparatorOptions<"hr">>;
17
+ /**
18
+ * Renders a separator element.
19
+ * @see https://solid.ariakit.com/components/separator
20
+ * @example
21
+ * ```jsx
22
+ * <Separator orientation="horizontal" />
23
+ * ```
24
+ */
25
+ declare const Separator: (props: SeparatorProps) => import("solid-js").JSX.Element;
26
+ interface SeparatorOptions<_T extends ValidComponent = TagName> extends Options {
27
+ /**
28
+ * The orientation of the separator.
29
+ * @default "horizontal"
30
+ */
31
+ orientation?: "horizontal" | "vertical";
32
+ }
33
+ type SeparatorProps<T extends ValidComponent = TagName> = Props<T, SeparatorOptions<T>>;
34
+ //#endregion
35
+ export { Separator, SeparatorOptions, SeparatorProps, useSeparator };
36
+ //# sourceMappingURL=separator.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"separator.d.ts","names":["Options","Props","ValidComponent","TagName","useSeparator","SeparatorOptions","Hook","Separator","SeparatorProps","props","JSX","Element","_T","orientation","T"],"sources":["../../src/separator/separator.d.ts"],"mappings":";;;;cAEcG,OAAAA;AAAAA,KACTA,OAAAA,UAAiBA,OAAO;AAFkB;;;;AAC1B;AAAA;;;;AAD0B,cAY1BC,YAAAA,iCAA6CE,IAAAA,OAAWD,gBAAgB;AAA7F;;;;AAA6F;AAS7F;;;AATA,cASqBE,SAAAA,GAAYE,KAAAA,EAAOD,cAAc,wBAAwBE,GAAAA,CAAIC,OAAAA;AAAAA,UACjEN,gBAAAA,YAA4BH,cAAAA,GAAiBC,OAAAA,UAAiBH,OAAAA;EAD9CS;;;;EAM7BI,WAAAA;AAAAA;AAAAA,KAEQL,cAAAA,WAAyBN,cAAAA,GAAiBC,OAAAA,IAAWF,KAAAA,CAAMa,CAAAA,EAAGT,gBAAAA,CAAiBS,CAAAA"}
@@ -0,0 +1,36 @@
1
+ import { createHook, createInstance, mergeProps, withOptions } from "@ariakit/solid-utils";
2
+ //#region src/separator/separator.tsx
3
+ const TagName = "hr";
4
+ /**
5
+ * Returns props to create a `Separator` component.
6
+ * @see https://solid.ariakit.com/components/separator
7
+ * @example
8
+ * ```jsx
9
+ * const props = useSeparator({ orientation: "horizontal" });
10
+ * <Role {...props} />
11
+ * ```
12
+ */
13
+ const useSeparator = createHook(withOptions({ orientation: "horizontal" }, function useSeparator(props, options) {
14
+ props = mergeProps({
15
+ role: "separator",
16
+ get "aria-orientation"() {
17
+ return options.orientation;
18
+ }
19
+ }, props);
20
+ return props;
21
+ }));
22
+ /**
23
+ * Renders a separator element.
24
+ * @see https://solid.ariakit.com/components/separator
25
+ * @example
26
+ * ```jsx
27
+ * <Separator orientation="horizontal" />
28
+ * ```
29
+ */
30
+ const Separator = function Separator(props) {
31
+ return createInstance(TagName, useSeparator(props));
32
+ };
33
+ //#endregion
34
+ export { Separator, useSeparator };
35
+
36
+ //# sourceMappingURL=separator.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"separator.js","names":["mergeProps","createHook","createInstance","withOptions","Options","Props","ValidComponent","TagName","useSeparator","SeparatorOptions","orientation","props","options","role","const","aria-orientation","Separator","SeparatorProps","htmlProps","T"],"sources":["../../src/separator/separator.tsx"],"sourcesContent":["import {\n mergeProps,\n createHook,\n createInstance,\n withOptions,\n} from \"@ariakit/solid-utils\";\nimport type { Options, Props } from \"@ariakit/solid-utils\";\nimport type { ValidComponent } from \"solid-js\";\n\nconst TagName = \"hr\" satisfies ValidComponent;\ntype TagName = typeof TagName;\n\n/**\n * Returns props to create a `Separator` component.\n * @see https://solid.ariakit.com/components/separator\n * @example\n * ```jsx\n * const props = useSeparator({ orientation: \"horizontal\" });\n * <Role {...props} />\n * ```\n */\nexport const useSeparator = createHook<TagName, SeparatorOptions>(\n withOptions(\n { orientation: \"horizontal\" },\n function useSeparator(props, options) {\n props = mergeProps(\n {\n role: \"separator\" as const,\n get \"aria-orientation\"() {\n return options.orientation;\n },\n },\n props,\n );\n return props;\n },\n ),\n);\n\n/**\n * Renders a separator element.\n * @see https://solid.ariakit.com/components/separator\n * @example\n * ```jsx\n * <Separator orientation=\"horizontal\" />\n * ```\n */\nexport const Separator = function Separator(props: SeparatorProps) {\n const htmlProps = useSeparator(props);\n return createInstance(TagName, htmlProps);\n};\n\nexport interface SeparatorOptions<\n _T extends ValidComponent = TagName,\n> extends Options {\n /**\n * The orientation of the separator.\n * @default \"horizontal\"\n */\n orientation?: \"horizontal\" | \"vertical\";\n}\n\nexport type SeparatorProps<T extends ValidComponent = TagName> = Props<\n T,\n SeparatorOptions<T>\n>;\n"],"mappings":";;AASA,MAAMO,UAAU;;;;;;;;;;AAYhB,MAAaC,eAAeP,WAC1BE,YACE,EAAEO,aAAa,aAAa,GAC5B,SAASF,aAAaG,OAAOC,SAAS;CACpCD,QAAQX,WACN;EACEa,MAAM;EACN,IAAI,qBAAqB;GACvB,OAAOD,QAAQF;EACjB;CACF,GACAC,KACF;CACA,OAAOA;AACT,CACF,CACF;;;;;;;;;AAUA,MAAaK,YAAY,SAASA,UAAUL,OAAuB;CAEjE,OAAOT,eAAeK,SADJC,aAAaG,KACAO,CAAS;AAC1C"}
@@ -0,0 +1,37 @@
1
+ import { ValidComponent } from "solid-js";
2
+ import { Options, Props } from "@ariakit/solid-utils";
3
+
4
+ //#region src/visually-hidden/visually-hidden.d.ts
5
+ declare const TagName = "span";
6
+ type TagName = typeof TagName;
7
+ /**
8
+ * Returns props to create a `VisuallyHidden` component. When applying the props
9
+ * returned by this hook to a component, the component will be visually hidden,
10
+ * but still accessible to screen readers.
11
+ * @see https://solid.ariakit.com/components/visually-hidden
12
+ * @example
13
+ * ```jsx
14
+ * const props = useVisuallyHidden();
15
+ * <a href="#">
16
+ * Learn more<Role {...props}> about the Solar System</Role>.
17
+ * </a>
18
+ * ```
19
+ */
20
+ declare const useVisuallyHidden: import("@ariakit/solid-utils").Hook<"span", VisuallyHiddenOptions<"span">>;
21
+ /**
22
+ * Renders an element that's visually hidden, but still accessible to screen
23
+ * readers.
24
+ * @see https://solid.ariakit.com/components/visually-hidden
25
+ * @example
26
+ * ```jsx
27
+ * <a href="#">
28
+ * Learn more<VisuallyHidden> about the Solar System</VisuallyHidden>.
29
+ * </a>
30
+ * ```
31
+ */
32
+ declare function VisuallyHidden(props: VisuallyHiddenProps): import("solid-js").JSX.Element;
33
+ interface VisuallyHiddenOptions<_T extends ValidComponent = TagName> extends Options {}
34
+ type VisuallyHiddenProps = Props<TagName, VisuallyHiddenOptions>;
35
+ //#endregion
36
+ export { VisuallyHidden, VisuallyHiddenOptions, VisuallyHiddenProps, useVisuallyHidden };
37
+ //# sourceMappingURL=visually-hidden.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"visually-hidden.d.ts","names":["Options","Props","ValidComponent","TagName","useVisuallyHidden","VisuallyHiddenOptions","Hook","VisuallyHidden","VisuallyHiddenProps","props","JSX","Element","_T"],"sources":["../../src/visually-hidden/visually-hidden.d.ts"],"mappings":";;;;cAEcG,OAAAA;AAAAA,KACTA,OAAAA,UAAiBA,OAAO;AAFkB;;;;AAC1B;AAAA;;;;AACQ;AAc7B;;;AAhB+C,cAgB1BC,iBAAAA,iCAAkDE,IAAAA,SAAaD,qBAAqB;AAAA;AAYzG;;;;;;;;;AAAkG;AAZO,iBAYjFE,cAAAA,CAAeE,KAAAA,EAAOD,mBAAmB,sBAAsBE,GAAAA,CAAIC,OAAAA;AAAAA,UAC1EN,qBAAAA,YAAiCH,cAAAA,GAAiBC,OAAAA,UAAiBH,OAAAA;AAAAA,KAExEQ,mBAAAA,GAAsBP,KAAAA,CAAME,OAAAA,EAASE,qBAAAA"}
@@ -0,0 +1,48 @@
1
+ import { createHook, createInstance, mergeProps } from "@ariakit/solid-utils";
2
+ //#region src/visually-hidden/visually-hidden.tsx
3
+ const TagName = "span";
4
+ /**
5
+ * Returns props to create a `VisuallyHidden` component. When applying the props
6
+ * returned by this hook to a component, the component will be visually hidden,
7
+ * but still accessible to screen readers.
8
+ * @see https://solid.ariakit.com/components/visually-hidden
9
+ * @example
10
+ * ```jsx
11
+ * const props = useVisuallyHidden();
12
+ * <a href="#">
13
+ * Learn more<Role {...props}> about the Solar System</Role>.
14
+ * </a>
15
+ * ```
16
+ */
17
+ const useVisuallyHidden = createHook(function useVisuallyHidden(props) {
18
+ props = mergeProps({ style: {
19
+ border: 0,
20
+ clip: "rect(0 0 0 0)",
21
+ height: "1px",
22
+ margin: "-1px",
23
+ overflow: "hidden",
24
+ padding: 0,
25
+ position: "absolute",
26
+ "white-space": "nowrap",
27
+ width: "1px"
28
+ } }, props);
29
+ return props;
30
+ });
31
+ /**
32
+ * Renders an element that's visually hidden, but still accessible to screen
33
+ * readers.
34
+ * @see https://solid.ariakit.com/components/visually-hidden
35
+ * @example
36
+ * ```jsx
37
+ * <a href="#">
38
+ * Learn more<VisuallyHidden> about the Solar System</VisuallyHidden>.
39
+ * </a>
40
+ * ```
41
+ */
42
+ function VisuallyHidden(props) {
43
+ return createInstance(TagName, useVisuallyHidden(props));
44
+ }
45
+ //#endregion
46
+ export { VisuallyHidden, useVisuallyHidden };
47
+
48
+ //# sourceMappingURL=visually-hidden.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"visually-hidden.js","names":["mergeProps","createHook","createInstance","Options","Props","ValidComponent","TagName","useVisuallyHidden","VisuallyHiddenOptions","props","style","border","clip","height","margin","overflow","padding","position","width","VisuallyHidden","VisuallyHiddenProps","htmlProps"],"sources":["../../src/visually-hidden/visually-hidden.tsx"],"sourcesContent":["import { mergeProps, createHook, createInstance } from \"@ariakit/solid-utils\";\nimport type { Options, Props } from \"@ariakit/solid-utils\";\nimport type { ValidComponent } from \"solid-js\";\n\nconst TagName = \"span\" satisfies ValidComponent;\ntype TagName = typeof TagName;\n\n/**\n * Returns props to create a `VisuallyHidden` component. When applying the props\n * returned by this hook to a component, the component will be visually hidden,\n * but still accessible to screen readers.\n * @see https://solid.ariakit.com/components/visually-hidden\n * @example\n * ```jsx\n * const props = useVisuallyHidden();\n * <a href=\"#\">\n * Learn more<Role {...props}> about the Solar System</Role>.\n * </a>\n * ```\n */\nexport const useVisuallyHidden = createHook<TagName, VisuallyHiddenOptions>(\n function useVisuallyHidden(props) {\n props = mergeProps(\n {\n style: {\n border: 0,\n clip: \"rect(0 0 0 0)\",\n height: \"1px\",\n margin: \"-1px\",\n overflow: \"hidden\",\n padding: 0,\n position: \"absolute\",\n \"white-space\": \"nowrap\",\n width: \"1px\",\n },\n },\n props,\n );\n return props;\n },\n);\n\n/**\n * Renders an element that's visually hidden, but still accessible to screen\n * readers.\n * @see https://solid.ariakit.com/components/visually-hidden\n * @example\n * ```jsx\n * <a href=\"#\">\n * Learn more<VisuallyHidden> about the Solar System</VisuallyHidden>.\n * </a>\n * ```\n */\nexport function VisuallyHidden(props: VisuallyHiddenProps) {\n const htmlProps = useVisuallyHidden(props);\n return createInstance(TagName, htmlProps);\n}\n\nexport interface VisuallyHiddenOptions<\n _T extends ValidComponent = TagName,\n> extends Options {}\n\nexport type VisuallyHiddenProps = Props<TagName, VisuallyHiddenOptions>;\n"],"mappings":";;AAIA,MAAMM,UAAU;;;;;;;;;;;;;;AAgBhB,MAAaC,oBAAoBN,WAC/B,SAASM,kBAAkBE,OAAO;CAChCA,QAAQT,WACN,EACEU,OAAO;EACLC,QAAQ;EACRC,MAAM;EACNC,QAAQ;EACRC,QAAQ;EACRC,UAAU;EACVC,SAAS;EACTC,UAAU;EACV,eAAe;EACfC,OAAO;CACT,EACF,GACAT,KACF;CACA,OAAOA;AACT,CACF;;;;;;;;;;;;AAaA,SAAgBU,eAAeV,OAA4B;CAEzD,OAAOP,eAAeI,SADJC,kBAAkBE,KACLY,CAAS;AAC1C"}
package/index.ts ADDED
@@ -0,0 +1 @@
1
+ export default {};
package/license ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025-present Ariakit FZ-LLC, Dani Guardiola
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/package.json ADDED
@@ -0,0 +1,113 @@
1
+ {
2
+ "name": "@ariakit/solid-components",
3
+ "version": "0.1.0",
4
+ "description": "Ariakit Solid components",
5
+ "keywords": [
6
+ "ariakit",
7
+ "solid",
8
+ "components"
9
+ ],
10
+ "homepage": "https://ariakit.com",
11
+ "license": "MIT",
12
+ "author": {
13
+ "name": "Dani Guardiola",
14
+ "email": "hi@daniguardio.la",
15
+ "url": "https://dio.la"
16
+ },
17
+ "contributors": [
18
+ {
19
+ "name": "Diego Haz",
20
+ "email": "hazdiego@gmail.com",
21
+ "url": "https://github.com/diegohaz"
22
+ }
23
+ ],
24
+ "repository": {
25
+ "type": "git",
26
+ "url": "https://github.com/ariakit/ariakit.git",
27
+ "directory": "packages/ariakit-solid-components"
28
+ },
29
+ "type": "module",
30
+ "sideEffects": false,
31
+ "dependencies": {
32
+ "@ariakit/solid-utils": "0.1.0",
33
+ "@ariakit/utils": "0.1.0"
34
+ },
35
+ "devDependencies": {
36
+ "@ariakit/scripts": "0.0.0"
37
+ },
38
+ "peerDependencies": {
39
+ "solid-js": "^1.8"
40
+ },
41
+ "exports": {
42
+ "./as/as": {
43
+ "types": "./dist/as/as.d.ts",
44
+ "solid": "./solid/as/as.jsx",
45
+ "import": "./dist/as/as.js"
46
+ },
47
+ "./focus-trap/focus-trap": {
48
+ "types": "./dist/focus-trap/focus-trap.d.ts",
49
+ "solid": "./solid/focus-trap/focus-trap.jsx",
50
+ "import": "./dist/focus-trap/focus-trap.js"
51
+ },
52
+ "./focus-trap/focus-trap-region": {
53
+ "types": "./dist/focus-trap/focus-trap-region.d.ts",
54
+ "solid": "./solid/focus-trap/focus-trap-region.jsx",
55
+ "import": "./dist/focus-trap/focus-trap-region.js"
56
+ },
57
+ "./group/group": {
58
+ "types": "./dist/group/group.d.ts",
59
+ "solid": "./solid/group/group.jsx",
60
+ "import": "./dist/group/group.js"
61
+ },
62
+ "./group/group-label": {
63
+ "types": "./dist/group/group-label.d.ts",
64
+ "solid": "./solid/group/group-label.jsx",
65
+ "import": "./dist/group/group-label.js"
66
+ },
67
+ "./group/group-label-context": {
68
+ "types": "./dist/group/group-label-context.d.ts",
69
+ "solid": "./solid/group/group-label-context.jsx",
70
+ "import": "./dist/group/group-label-context.js"
71
+ },
72
+ "./heading/heading": {
73
+ "types": "./dist/heading/heading.d.ts",
74
+ "solid": "./solid/heading/heading.jsx",
75
+ "import": "./dist/heading/heading.js"
76
+ },
77
+ "./heading/heading-context": {
78
+ "types": "./dist/heading/heading-context.d.ts",
79
+ "solid": "./solid/heading/heading-context.jsx",
80
+ "import": "./dist/heading/heading-context.js"
81
+ },
82
+ "./heading/heading-level": {
83
+ "types": "./dist/heading/heading-level.d.ts",
84
+ "solid": "./solid/heading/heading-level.jsx",
85
+ "import": "./dist/heading/heading-level.js"
86
+ },
87
+ "./heading/utils": {
88
+ "types": "./dist/heading/utils.d.ts",
89
+ "solid": "./solid/heading/utils.jsx",
90
+ "import": "./dist/heading/utils.js"
91
+ },
92
+ "./role/role": {
93
+ "types": "./dist/role/role.d.ts",
94
+ "solid": "./solid/role/role.jsx",
95
+ "import": "./dist/role/role.js"
96
+ },
97
+ "./separator/separator": {
98
+ "types": "./dist/separator/separator.d.ts",
99
+ "solid": "./solid/separator/separator.jsx",
100
+ "import": "./dist/separator/separator.js"
101
+ },
102
+ "./visually-hidden/visually-hidden": {
103
+ "types": "./dist/visually-hidden/visually-hidden.d.ts",
104
+ "solid": "./solid/visually-hidden/visually-hidden.jsx",
105
+ "import": "./dist/visually-hidden/visually-hidden.js"
106
+ },
107
+ "./package.json": "./package.json"
108
+ },
109
+ "scripts": {
110
+ "build": "ariakit build",
111
+ "clean": "ariakit clean"
112
+ }
113
+ }
package/readme.md ADDED
@@ -0,0 +1,19 @@
1
+ # Ariakit Solid Components
2
+
3
+ **Important:** This package is an internal dependency of Ariakit and does not follow semantic versioning, meaning breaking changes may occur in patch and minor versions.
4
+
5
+ ## Installation
6
+
7
+ ```
8
+ npm i @ariakit/solid-components
9
+ ```
10
+
11
+ ## Core Team
12
+
13
+ - [Diego Haz](https://bsky.app/profile/haz.dev)
14
+ - [Ben Rodri](https://bsky.app/profile/ben.ariakit.org)
15
+ - [Dani Guardiola](https://bsky.app/profile/dio.la)
16
+
17
+ ## Contributing
18
+
19
+ Follow the instructions on the [contributing guide](https://github.com/ariakit/ariakit/blob/main/contributing.md).