@assistant-ui/react-o11y 0.0.45 → 0.0.47

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 (49) hide show
  1. package/LICENSE +1 -1
  2. package/dist/context/SpanByIndexProvider.d.ts +2 -4
  3. package/dist/context/SpanByIndexProvider.d.ts.map +1 -1
  4. package/dist/context/SpanByIndexProvider.js.map +1 -1
  5. package/dist/index.d.ts +6 -5
  6. package/dist/index.d.ts.map +1 -0
  7. package/dist/o11y-scope.d.ts +32 -33
  8. package/dist/o11y-scope.d.ts.map +1 -1
  9. package/dist/primitives/span/SpanChildren.d.ts +18 -19
  10. package/dist/primitives/span/SpanChildren.d.ts.map +1 -1
  11. package/dist/primitives/span/SpanChildren.js +1 -1
  12. package/dist/primitives/span/SpanChildren.js.map +1 -1
  13. package/dist/primitives/span/SpanCollapseToggle.d.ts +4 -6
  14. package/dist/primitives/span/SpanCollapseToggle.d.ts.map +1 -1
  15. package/dist/primitives/span/SpanCollapseToggle.js +2 -2
  16. package/dist/primitives/span/SpanCollapseToggle.js.map +1 -1
  17. package/dist/primitives/span/SpanIndent.d.ts +9 -11
  18. package/dist/primitives/span/SpanIndent.d.ts.map +1 -1
  19. package/dist/primitives/span/SpanIndent.js +2 -2
  20. package/dist/primitives/span/SpanIndent.js.map +1 -1
  21. package/dist/primitives/span/SpanName.d.ts +4 -6
  22. package/dist/primitives/span/SpanName.d.ts.map +1 -1
  23. package/dist/primitives/span/SpanName.js +2 -2
  24. package/dist/primitives/span/SpanName.js.map +1 -1
  25. package/dist/primitives/span/SpanRoot.d.ts +4 -6
  26. package/dist/primitives/span/SpanRoot.d.ts.map +1 -1
  27. package/dist/primitives/span/SpanRoot.js +2 -2
  28. package/dist/primitives/span/SpanRoot.js.map +1 -1
  29. package/dist/primitives/span/SpanStatusIndicator.d.ts +4 -6
  30. package/dist/primitives/span/SpanStatusIndicator.d.ts.map +1 -1
  31. package/dist/primitives/span/SpanStatusIndicator.js +2 -2
  32. package/dist/primitives/span/SpanStatusIndicator.js.map +1 -1
  33. package/dist/primitives/span/SpanTimeline.d.ts +29 -31
  34. package/dist/primitives/span/SpanTimeline.d.ts.map +1 -1
  35. package/dist/primitives/span/SpanTimeline.js +2 -2
  36. package/dist/primitives/span/SpanTimeline.js.map +1 -1
  37. package/dist/primitives/span/SpanTypeBadge.d.ts +4 -6
  38. package/dist/primitives/span/SpanTypeBadge.d.ts.map +1 -1
  39. package/dist/primitives/span/SpanTypeBadge.js +2 -2
  40. package/dist/primitives/span/SpanTypeBadge.js.map +1 -1
  41. package/dist/primitives/span.d.ts +9 -13
  42. package/dist/primitives/span.d.ts.map +1 -1
  43. package/dist/resources/SpanResource.d.ts +10 -12
  44. package/dist/resources/SpanResource.d.ts.map +1 -1
  45. package/dist/resources/SpanResource.js +44 -43
  46. package/dist/resources/SpanResource.js.map +1 -1
  47. package/package.json +12 -7
  48. package/src/resources/SpanResource.test.tsx +59 -1
  49. package/src/resources/SpanResource.tsx +14 -14
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2025 AgentbaseAI Inc.
3
+ Copyright (c) 2026 AgentbaseAI Inc.
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -1,7 +1,5 @@
1
- import { FC, PropsWithChildren } from "react";
2
- //#region src/context/SpanByIndexProvider.d.ts
1
+ import type { FC, PropsWithChildren } from "react";
3
2
  export declare const SpanByIndexProvider: FC<PropsWithChildren<{
4
- index: number;
3
+ index: number;
5
4
  }>>;
6
- //#endregion
7
5
  //# sourceMappingURL=SpanByIndexProvider.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanByIndexProvider.d.ts","names":[],"sources":["../../src/context/SpanByIndexProvider.tsx"],"mappings":";;qBAGa,qBAAqB,GAAG;EAAoB"}
1
+ {"version":3,"file":"SpanByIndexProvider.d.ts","sourceRoot":"","sources":["../../src/context/SpanByIndexProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAGnD,eAAO,MAAM,mBAAmB,EAAE,EAAE,CAAC,iBAAiB,CAAC;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAkBxE,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"SpanByIndexProvider.js","names":["FC","PropsWithChildren","useAui","AuiConfig","AuiProvider","Derived","SpanByIndexProvider","index","t0","$","_c","children","parentAui","t1","span","source","query","get","child","config","t2"],"sources":["../../src/context/SpanByIndexProvider.tsx"],"sourcesContent":["import type { FC, PropsWithChildren } from \"react\";\nimport { useAui, AuiConfig, AuiProvider, Derived } from \"@assistant-ui/store\";\n\nexport const SpanByIndexProvider: FC<PropsWithChildren<{ index: number }>> = ({\n index,\n children,\n}) => {\n const parentAui = useAui();\n\n const config = AuiConfig({\n span: Derived({\n source: \"span\",\n query: { index },\n get: () => parentAui.span.child({ index }),\n }),\n });\n return (\n <AuiProvider extends={parentAui} config={config}>\n {children}\n </AuiProvider>\n );\n};\n"],"mappings":";;;;AAGA,MAAaM,uBAAgEE,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAH,OAAAI,aAAAH;CAI5E,MAAAI,YAAkBV,OAAO;CAAE,IAAAW;CAAA,IAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAG,WAAA;EAEZC,KAAAV,UAAU,EAAAW,MACjBT,QAAQ;GAAAU,QACJ;GAAMC,OACP,EAAAT,MAAQ;GAACU,WACLL,UAASE,KAAKI,MAAO,EAAAX,MAAQ,CAAC;EAC3C,CAAC,EACH,CAAC;EAACE,EAAA,KAAAF;EAAAE,EAAA,KAAAG;EAAAH,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CANF,MAAAU,SAAeN;CAMZ,IAAAO;CAAA,IAAAX,EAAA,OAAAE,YAAAF,EAAA,OAAAU,UAAAV,EAAA,OAAAG,WAAA;EAEDQ,KAAA,oBAAC,aAAD;GAAsBR,SAAAA;GAAmBO;GACtCR;EADS,CAAA;EAEEF,EAAA,KAAAE;EAAAF,EAAA,KAAAU;EAAAV,EAAA,KAAAG;EAAAH,EAAA,KAAAW;CAAA,OAAAA,KAAAX,EAAA;CAAA,OAFdW;AAEc"}
1
+ {"version":3,"file":"SpanByIndexProvider.js","names":["FC","PropsWithChildren","useAui","AuiConfig","AuiProvider","Derived","SpanByIndexProvider","index","t0","$","_c","children","parentAui","t1","span","source","query","get","child","config","t2","_c"],"sources":["../../src/context/SpanByIndexProvider.tsx"],"sourcesContent":["import type { FC, PropsWithChildren } from \"react\";\nimport { useAui, AuiConfig, AuiProvider, Derived } from \"@assistant-ui/store\";\n\nexport const SpanByIndexProvider: FC<PropsWithChildren<{ index: number }>> = ({\n index,\n children,\n}) => {\n const parentAui = useAui();\n\n const config = AuiConfig({\n span: Derived({\n source: \"span\",\n query: { index },\n get: () => parentAui.span.child({ index }),\n }),\n });\n return (\n <AuiProvider extends={parentAui} config={config}>\n {children}\n </AuiProvider>\n );\n};\n"],"mappings":";;;;AAGA,MAAaM,uBAAgEE,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAH,OAAAI,aAAAH;CAI5E,MAAAI,YAAkBV,OAAO;CAAE,IAAAW;CAAA,IAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAG,WAAA;EAEZC,KAAAV,UAAU,EAAAW,MACjBT,QAAQ;GAAAU,QACJ;GAAMC,OACP,EAAAT,MAAQ;GAACU,WACLL,UAASE,KAAKI,MAAO,EAAAX,MAAQ,CAAC;EAC3C,CAAC,EACH,CAAC;EAACE,EAAA,KAAAF;EAAAE,EAAA,KAAAG;EAAAH,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CANF,MAAAU,SAAeN;CAMZ,IAAAO;CAAA,IAAAX,EAAA,OAAAE,YAAAF,EAAA,OAAAU,UAAAV,EAAA,OAAAG,WAAA;EAEDQ,KAAA,oBAAC,aAAD;GAAsBR,SAAAA;GAAmBO;GACtCR;EADS,CAAA;EAEEF,EAAA,KAAAE;EAAAF,EAAA,KAAAU;EAAAV,EAAA,KAAAG;EAAAH,EAAA,KAAAW;CAAA,OAAAA,KAAAX,EAAA;CAAA,OAFdW;AAEc"}
package/dist/index.d.ts CHANGED
@@ -1,5 +1,6 @@
1
- import { SpanByIndexProvider } from "./context/SpanByIndexProvider.js";
2
- import { SpanItemState, SpanState } from "./o11y-scope.js";
3
- import { span_d_exports } from "./primitives/span.js";
4
- import { SpanData, SpanResource } from "./resources/SpanResource.js";
5
- export { SpanByIndexProvider, type SpanData, type SpanItemState, span_d_exports as SpanPrimitive, SpanResource, type SpanState };
1
+ export * as SpanPrimitive from "./primitives/span.js";
2
+ export { SpanResource } from "./resources/SpanResource.js";
3
+ export type { SpanData } from "./resources/SpanResource.js";
4
+ export type { SpanItemState, SpanState } from "./o11y-scope.js";
5
+ export { SpanByIndexProvider } from "./context/SpanByIndexProvider.js";
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,aAAa,6BAA0B;AAEnD,OAAO,EAAE,YAAY,EAAE,oCAAiC;AACxD,YAAY,EAAE,QAAQ,EAAE,oCAAiC;AACzD,YAAY,EAAE,aAAa,EAAE,SAAS,EAAE,wBAAqB;AAE7D,OAAO,EAAE,mBAAmB,EAAE,yCAAsC"}
@@ -1,45 +1,44 @@
1
1
  import "@assistant-ui/store";
2
- //#region src/o11y-scope.d.ts
3
2
  export type SpanItemState = {
4
- id: string;
5
- parentSpanId: string | null;
6
- name: string;
7
- type: string;
8
- status: "running" | "completed" | "failed" | "skipped";
9
- startedAt: number;
10
- endedAt: number | null;
11
- latencyMs: number | null;
12
- depth: number;
13
- hasChildren: boolean;
14
- isCollapsed: boolean;
3
+ id: string;
4
+ parentSpanId: string | null;
5
+ name: string;
6
+ type: string;
7
+ status: "running" | "completed" | "failed" | "skipped";
8
+ startedAt: number;
9
+ endedAt: number | null;
10
+ latencyMs: number | null;
11
+ depth: number;
12
+ hasChildren: boolean;
13
+ isCollapsed: boolean;
15
14
  };
16
15
  export type SpanState = SpanItemState & {
17
- children: SpanItemState[];
18
- timeRange: {
19
- min: number;
20
- max: number;
21
- };
16
+ children: SpanItemState[];
17
+ timeRange: {
18
+ min: number;
19
+ max: number;
20
+ };
22
21
  };
23
22
  type SpanMethods = {
24
- getState: () => SpanState;
25
- child: (lookup: SpanMeta["query"]) => SpanMethods;
26
- toggleCollapse: () => void;
23
+ getState: () => SpanState;
24
+ child: (lookup: SpanMeta["query"]) => SpanMethods;
25
+ toggleCollapse: () => void;
27
26
  };
28
27
  type SpanMeta = {
29
- source: "span";
30
- query: {
31
- index: number;
32
- } | {
33
- key: string;
34
- };
28
+ source: "span";
29
+ query: {
30
+ index: number;
31
+ } | {
32
+ key: string;
33
+ };
35
34
  };
36
35
  declare module "@assistant-ui/store" {
37
- interface ScopeRegistry {
38
- span: {
39
- methods: SpanMethods;
40
- meta: SpanMeta;
41
- };
42
- }
36
+ interface ScopeRegistry {
37
+ span: {
38
+ methods: SpanMethods;
39
+ meta: SpanMeta;
40
+ };
41
+ }
43
42
  }
44
- //#endregion
43
+ export {};
45
44
  //# sourceMappingURL=o11y-scope.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"o11y-scope.d.ts","names":[],"sources":["../src/o11y-scope.ts"],"mappings":";;YAEY;EACV;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;YAGU,YAAY;EACtB,UAAU;EACV;IAAa;IAAa;;;KAGvB;EACH,gBAAgB;EAChB,QAAQ,QAAQ,sBAAsB;EACtC;;KAGG;EACH;EACA;IAAS;;IAAoB;;;;YAInB;IACR;MACE,SAAS;MACT,MAAM"}
1
+ {"version":3,"file":"o11y-scope.d.ts","sourceRoot":"","sources":["../src/o11y-scope.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAE7B,MAAM,MAAM,aAAa,GAAG;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,SAAS,CAAC;IACvD,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,OAAO,CAAC;IACrB,WAAW,EAAE,OAAO,CAAC;CACtB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG,aAAa,GAAG;IACtC,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,SAAS,EAAE;QAAE,GAAG,EAAE,MAAM,CAAC;QAAC,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;CACzC,CAAC;AAEF,KAAK,WAAW,GAAG;IACjB,QAAQ,EAAE,MAAM,SAAS,CAAC;IAC1B,KAAK,EAAE,CAAC,MAAM,EAAE,QAAQ,CAAC,OAAO,CAAC,KAAK,WAAW,CAAC;IAClD,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B,CAAC;AAEF,KAAK,QAAQ,GAAG;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE;QAAE,KAAK,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,GAAG,EAAE,MAAM,CAAA;KAAE,CAAC;CAC5C,CAAC;AAEF,OAAO,QAAQ,qBAAqB,CAAC;IACnC,UAAU,aAAa;QACrB,IAAI,EAAE;YACJ,OAAO,EAAE,WAAW,CAAC;YACrB,IAAI,EAAE,QAAQ,CAAC;SAChB,CAAC;KACH;CACF"}
@@ -1,28 +1,27 @@
1
- import { SpanState } from "../../o11y-scope.js";
2
- import { ComponentType, FC, ReactNode } from "react";
3
- //#region src/primitives/span/SpanChildren.d.ts
1
+ import { type ComponentType, type FC, type ReactNode } from "react";
2
+ import type { SpanState } from "../../o11y-scope.js";
4
3
  type SpanChildrenComponentConfig = {
5
- Span: ComponentType;
4
+ Span: ComponentType;
6
5
  };
7
6
  export declare namespace SpanPrimitiveChildren {
8
- type Props = {
9
- components: SpanChildrenComponentConfig;
10
- children?: never;
11
- } | {
12
- /** Render function called for each child span. Receives the span. */
13
- children: (value: {
14
- span: SpanState;
15
- }) => ReactNode;
16
- components?: never;
17
- };
7
+ type Props = {
8
+ components: SpanChildrenComponentConfig;
9
+ children?: never;
10
+ } | {
11
+ /** Render function called for each child span. Receives the span. */
12
+ children: (value: {
13
+ span: SpanState;
14
+ }) => ReactNode;
15
+ components?: never;
16
+ };
18
17
  }
19
18
  export declare namespace SpanPrimitiveChildByIndex {
20
- type Props = {
21
- index: number;
22
- components: SpanChildrenComponentConfig;
23
- };
19
+ type Props = {
20
+ index: number;
21
+ components: SpanChildrenComponentConfig;
22
+ };
24
23
  }
25
24
  export declare const SpanPrimitiveChildByIndex: FC<SpanPrimitiveChildByIndex.Props>;
26
25
  export declare const SpanPrimitiveChildren: FC<SpanPrimitiveChildren.Props>;
27
- //#endregion
26
+ export {};
28
27
  //# sourceMappingURL=SpanChildren.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanChildren.d.ts","names":[],"sources":["../../../src/primitives/span/SpanChildren.tsx"],"mappings":";;;KAWK;EACH,MAAM;;yBAGS;OACH;IAEN,YAAY;IACZ;;;IAIA,WAAW;MAAS,MAAM;UAAgB;IAC1C;;;yBAIS;OACH;IACV;IACA,YAAY;;;qBAIH,2BAA2B,GAAG,0BAA0B;qBAqDxD,uBAAuB,GAAG,sBAAsB"}
1
+ {"version":3,"file":"SpanChildren.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanChildren.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,EAAE,EACP,KAAK,SAAS,EAGf,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAAE,SAAS,EAAE,4BAAyB;AAGlD,KAAK,2BAA2B,GAAG;IACjC,IAAI,EAAE,aAAa,CAAC;CACrB,CAAC;AAEF,yBAAiB,qBAAqB,CAAC;IACrC,KAAY,KAAK,GACb;QACE,UAAU,EAAE,2BAA2B,CAAC;QACxC,QAAQ,CAAC,EAAE,KAAK,CAAC;KAClB,GACD;QACE,qEAAqE;QACrE,QAAQ,EAAE,CAAC,KAAK,EAAE;YAAE,IAAI,EAAE,SAAS,CAAA;SAAE,KAAK,SAAS,CAAC;QACpD,UAAU,CAAC,EAAE,KAAK,CAAC;KACpB,CAAC;CACP;AAED,yBAAiB,yBAAyB,CAAC;IACzC,KAAY,KAAK,GAAG;QAClB,KAAK,EAAE,MAAM,CAAC;QACd,UAAU,EAAE,2BAA2B,CAAC;KACzC,CAAC;CACH;AAED,eAAO,MAAM,yBAAyB,EAAE,EAAE,CAAC,yBAAyB,CAAC,KAAK,CAYvE,CAAC;AAyCJ,eAAO,MAAM,qBAAqB,EAAE,EAAE,CAAC,qBAAqB,CAAC,KAAK,CAQjE,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { SpanByIndexProvider } from "../../context/SpanByIndexProvider.js";
2
2
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
3
- import { memo, useMemo } from "@assistant-ui/tap/react-shim";
4
3
  import { RenderChildrenWithAccessor, useAuiState } from "@assistant-ui/store";
5
4
  import { jsx } from "react/jsx-runtime";
5
+ import { memo, useMemo } from "@assistant-ui/tap/react-shim";
6
6
  //#region src/primitives/span/SpanChildren.tsx
7
7
  const SpanPrimitiveChildByIndex = memo((t0) => {
8
8
  const $ = c(5);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanChildren.js","names":["ComponentType","FC","ReactNode","memo","useMemo","RenderChildrenWithAccessor","useAuiState","SpanState","SpanByIndexProvider","SpanChildrenComponentConfig","Span","SpanPrimitiveChildren","Props","components","children","value","span","SpanPrimitiveChildByIndex","index","t0","$","_c","t1","t2","prev","next","displayName","SpanPrimitiveChildrenInner","childrenLength","s","length","Array","from","_","aui","getState","getItem","SpanPrimitiveChildrenImpl"],"sources":["../../../src/primitives/span/SpanChildren.tsx"],"sourcesContent":["import {\n type ComponentType,\n type FC,\n type ReactNode,\n memo,\n useMemo,\n} from \"react\";\nimport { RenderChildrenWithAccessor, useAuiState } from \"@assistant-ui/store\";\nimport type { SpanState } from \"../../o11y-scope\";\nimport { SpanByIndexProvider } from \"../../context/SpanByIndexProvider\";\n\ntype SpanChildrenComponentConfig = {\n Span: ComponentType;\n};\n\nexport namespace SpanPrimitiveChildren {\n export type Props =\n | {\n components: SpanChildrenComponentConfig;\n children?: never;\n }\n | {\n /** Render function called for each child span. Receives the span. */\n children: (value: { span: SpanState }) => ReactNode;\n components?: never;\n };\n}\n\nexport namespace SpanPrimitiveChildByIndex {\n export type Props = {\n index: number;\n components: SpanChildrenComponentConfig;\n };\n}\n\nexport const SpanPrimitiveChildByIndex: FC<SpanPrimitiveChildByIndex.Props> =\n memo(\n ({ index, components }) => {\n return (\n <SpanByIndexProvider index={index}>\n <components.Span />\n </SpanByIndexProvider>\n );\n },\n (prev, next) =>\n prev.index === next.index &&\n prev.components.Span === next.components.Span,\n );\n\nSpanPrimitiveChildByIndex.displayName = \"SpanPrimitive.ChildByIndex\";\n\nconst SpanPrimitiveChildrenInner: FC<{\n children: (value: { span: SpanState }) => ReactNode;\n}> = ({ children }) => {\n const childrenLength = useAuiState((s) => s.span.children.length);\n\n return useMemo(() => {\n if (childrenLength === 0) return null;\n return Array.from({ length: childrenLength }, (_, index) => (\n <SpanByIndexProvider key={index} index={index}>\n <RenderChildrenWithAccessor getItemState={(aui) => aui.span.getState()}>\n {(getItem) =>\n children({\n get span() {\n return getItem();\n },\n })\n }\n </RenderChildrenWithAccessor>\n </SpanByIndexProvider>\n ));\n }, [childrenLength, children]);\n};\n\nconst SpanPrimitiveChildrenImpl: FC<SpanPrimitiveChildren.Props> = ({\n components,\n children,\n}) => {\n if (components) {\n return (\n <SpanPrimitiveChildrenInner>\n {() => <components.Span />}\n </SpanPrimitiveChildrenInner>\n );\n }\n return <SpanPrimitiveChildrenInner>{children}</SpanPrimitiveChildrenInner>;\n};\n\nexport const SpanPrimitiveChildren: FC<SpanPrimitiveChildren.Props> = memo(\n SpanPrimitiveChildrenImpl,\n (prev, next) => {\n if (prev.children || next.children) {\n return prev.children === next.children;\n }\n return prev.components!.Span === next.components!.Span;\n },\n);\n\nSpanPrimitiveChildren.displayName = \"SpanPrimitive.Children\";\n"],"mappings":";;;;;;AAmCA,MAAaiB,4BACXd,MACEgB,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAH,OAAAL,eAAAM;CAAqB,IAAAG;CAAA,IAAAF,EAAA,OAAAP,WAAAH,MAAA;EAGhBY,KAAA,oBAAA,WAAA,MAAA,CAAA,CAAA;EAAmBF,EAAA,KAAAP,WAAAH;EAAAU,EAAA,KAAAE;CAAA,OAAAA,KAAAF,EAAA;CAAA,IAAAG;CAAA,IAAAH,EAAA,OAAAF,SAAAE,EAAA,OAAAE,IAAA;EADrBC,KAAA,oBAAC,qBAAD;GAA4BL;GAC1BI,UAAAA;EADkB,CAAA;EAEEF,EAAA,KAAAF;EAAAE,EAAA,KAAAE;EAAAF,EAAA,KAAAG;CAAA,OAAAA,KAAAH,EAAA;CAAA,OAFtBG;AAEsB,IAGzBC,MAAMC,SACLD,KAAKN,UAAUO,KAAKP,SACpBM,KAAKX,WAAWH,SAASe,KAAKZ,WAAWH,IAC7C;AAEFO,0BAA0BS,cAAc;AAExC,MAAMC,8BAEA,EAAEb,eAAe;CACrB,MAAMc,iBAAiBtB,aAAauB,MAAMA,EAAEb,KAAKF,SAASgB,MAAM;CAEhE,OAAO1B,cAAc;EACnB,IAAIwB,mBAAmB,GAAG,OAAO;EACjC,OAAOG,MAAMC,KAAK,EAAEF,QAAQF,eAAe,IAAIK,GAAGf,UAChD,oBAAC,qBAAD;GAAwCA;GACtC,UAAA,oBAAC,4BAAD;IAA4B,eAAegB,QAAQA,IAAIlB,KAAKmB,SAAS;IACjEC,WAAAA,YACAtB,SAAS,EACP,IAAIE,OAAO;KACT,OAAOoB,QAAQ;IACjB,EACF,CAAC;GAEuB,CAAA;EACT,GAVKlB,KAUL,CACtB;CACH,GAAG,CAACU,gBAAgBd,QAAQ,CAAC;AAC/B;AAEA,MAAMuB,6BAA6DlB,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAR,YAAAC,aAAAK;CAIlE,IAAIN,YAAU;EAAA,IAAAS;EAAA,IAAAF,EAAA,OAAAP,WAAAH,MAAA;GAEVY,KAAA,oBAAC,4BAAD,EAAA,gBACS,oBAAA,WAAA,MAAA,CAAA,CAAA,EADkB,CAAA;GAEEF,EAAA,KAAAP,WAAAH;GAAAU,EAAA,KAAAE;EAAA,OAAAA,KAAAF,EAAA;EAAA,OAF7BE;CAE6B;CAEhC,IAAAA;CAAA,IAAAF,EAAA,OAAAN,UAAA;EACMQ,KAAA,oBAAC,4BAAD,EAA6BR,SAAF,CAAA;EAAwCM,EAAA,KAAAN;EAAAM,EAAA,KAAAE;CAAA,OAAAA,KAAAF,EAAA;CAAA,OAAnEE;AAAmE;AAG5E,MAAaX,wBAAyDR,KACpEkC,4BACCb,MAAMC,SAAS;CACd,IAAID,KAAKV,YAAYW,KAAKX,UACxB,OAAOU,KAAKV,aAAaW,KAAKX;CAEhC,OAAOU,KAAKX,WAAYH,SAASe,KAAKZ,WAAYH;AACpD,CACF;AAEAC,sBAAsBe,cAAc"}
1
+ {"version":3,"file":"SpanChildren.js","names":["ComponentType","FC","ReactNode","memo","useMemo","RenderChildrenWithAccessor","useAuiState","SpanState","SpanByIndexProvider","SpanChildrenComponentConfig","Span","SpanPrimitiveChildren","Props","components","children","value","span","SpanPrimitiveChildByIndex","index","t0","$","_c","t1","t2","prev","next","displayName","SpanPrimitiveChildrenInner","childrenLength","s","length","Array","from","_","aui","getState","getItem","SpanPrimitiveChildrenImpl","_c"],"sources":["../../../src/primitives/span/SpanChildren.tsx"],"sourcesContent":["import {\n type ComponentType,\n type FC,\n type ReactNode,\n memo,\n useMemo,\n} from \"react\";\nimport { RenderChildrenWithAccessor, useAuiState } from \"@assistant-ui/store\";\nimport type { SpanState } from \"../../o11y-scope\";\nimport { SpanByIndexProvider } from \"../../context/SpanByIndexProvider\";\n\ntype SpanChildrenComponentConfig = {\n Span: ComponentType;\n};\n\nexport namespace SpanPrimitiveChildren {\n export type Props =\n | {\n components: SpanChildrenComponentConfig;\n children?: never;\n }\n | {\n /** Render function called for each child span. Receives the span. */\n children: (value: { span: SpanState }) => ReactNode;\n components?: never;\n };\n}\n\nexport namespace SpanPrimitiveChildByIndex {\n export type Props = {\n index: number;\n components: SpanChildrenComponentConfig;\n };\n}\n\nexport const SpanPrimitiveChildByIndex: FC<SpanPrimitiveChildByIndex.Props> =\n memo(\n ({ index, components }) => {\n return (\n <SpanByIndexProvider index={index}>\n <components.Span />\n </SpanByIndexProvider>\n );\n },\n (prev, next) =>\n prev.index === next.index &&\n prev.components.Span === next.components.Span,\n );\n\nSpanPrimitiveChildByIndex.displayName = \"SpanPrimitive.ChildByIndex\";\n\nconst SpanPrimitiveChildrenInner: FC<{\n children: (value: { span: SpanState }) => ReactNode;\n}> = ({ children }) => {\n const childrenLength = useAuiState((s) => s.span.children.length);\n\n return useMemo(() => {\n if (childrenLength === 0) return null;\n return Array.from({ length: childrenLength }, (_, index) => (\n <SpanByIndexProvider key={index} index={index}>\n <RenderChildrenWithAccessor getItemState={(aui) => aui.span.getState()}>\n {(getItem) =>\n children({\n get span() {\n return getItem();\n },\n })\n }\n </RenderChildrenWithAccessor>\n </SpanByIndexProvider>\n ));\n }, [childrenLength, children]);\n};\n\nconst SpanPrimitiveChildrenImpl: FC<SpanPrimitiveChildren.Props> = ({\n components,\n children,\n}) => {\n if (components) {\n return (\n <SpanPrimitiveChildrenInner>\n {() => <components.Span />}\n </SpanPrimitiveChildrenInner>\n );\n }\n return <SpanPrimitiveChildrenInner>{children}</SpanPrimitiveChildrenInner>;\n};\n\nexport const SpanPrimitiveChildren: FC<SpanPrimitiveChildren.Props> = memo(\n SpanPrimitiveChildrenImpl,\n (prev, next) => {\n if (prev.children || next.children) {\n return prev.children === next.children;\n }\n return prev.components!.Span === next.components!.Span;\n },\n);\n\nSpanPrimitiveChildren.displayName = \"SpanPrimitive.Children\";\n"],"mappings":";;;;;;AAmCA,MAAaiB,4BACXd,MACEgB,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAH,OAAAL,eAAAM;CAAqB,IAAAG;CAAA,IAAAF,EAAA,OAAAP,WAAAH,MAAA;EAGhBY,KAAA,oBAAA,WAAA,MAAA,CAAA,CAAA;EAAmBF,EAAA,KAAAP,WAAAH;EAAAU,EAAA,KAAAE;CAAA,OAAAA,KAAAF,EAAA;CAAA,IAAAG;CAAA,IAAAH,EAAA,OAAAF,SAAAE,EAAA,OAAAE,IAAA;EADrBC,KAAA,oBAAC,qBAAD;GAA4BL;GAC1BI,UAAAA;EADkB,CAAA;EAEEF,EAAA,KAAAF;EAAAE,EAAA,KAAAE;EAAAF,EAAA,KAAAG;CAAA,OAAAA,KAAAH,EAAA;CAAA,OAFtBG;AAEsB,IAGzBC,MAAMC,SACLD,KAAKN,UAAUO,KAAKP,SACpBM,KAAKX,WAAWH,SAASe,KAAKZ,WAAWH,IAC7C;AAEFO,0BAA0BS,cAAc;AAExC,MAAMC,8BAEA,EAAEb,eAAe;CACrB,MAAMc,iBAAiBtB,aAAauB,MAAMA,EAAEb,KAAKF,SAASgB,MAAM;CAEhE,OAAO1B,cAAc;EACnB,IAAIwB,mBAAmB,GAAG,OAAO;EACjC,OAAOG,MAAMC,KAAK,EAAEF,QAAQF,eAAe,IAAIK,GAAGf,UAChD,oBAAC,qBAAD;GAAwCA;GACtC,UAAA,oBAAC,4BAAD;IAA4B,eAAegB,QAAQA,IAAIlB,KAAKmB,SAAS;IACjEC,WAAAA,YACAtB,SAAS,EACP,IAAIE,OAAO;KACT,OAAOoB,QAAQ;IACjB,EACF,CAAC;GAEuB,CAAA;EACT,GAVKlB,KAUL,CACtB;CACH,GAAG,CAACU,gBAAgBd,QAAQ,CAAC;AAC/B;AAEA,MAAMuB,6BAA6DlB,OAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CAAC,MAAA,EAAAR,YAAAC,aAAAK;CAIlE,IAAIN,YAAU;EAAA,IAAAS;EAAA,IAAAF,EAAA,OAAAP,WAAAH,MAAA;GAEVY,KAAA,oBAAC,4BAAD,EAAA,gBACS,oBAAA,WAAA,MAAA,CAAA,CAAA,EADkB,CAAA;GAEEF,EAAA,KAAAP,WAAAH;GAAAU,EAAA,KAAAE;EAAA,OAAAA,KAAAF,EAAA;EAAA,OAF7BE;CAE6B;CAEhC,IAAAA;CAAA,IAAAF,EAAA,OAAAN,UAAA;EACMQ,KAAA,oBAAC,4BAAD,EAA6BR,SAAF,CAAA;EAAwCM,EAAA,KAAAN;EAAAM,EAAA,KAAAE;CAAA,OAAAA,KAAAF,EAAA;CAAA,OAAnEE;AAAmE;AAG5E,MAAaX,wBAAyDR,KACpEkC,4BACCb,MAAMC,SAAS;CACd,IAAID,KAAKV,YAAYW,KAAKX,UACxB,OAAOU,KAAKV,aAAaW,KAAKX;CAEhC,OAAOU,KAAKX,WAAYH,SAASe,KAAKZ,WAAYH;AACpD,CACF;AAEAC,sBAAsBe,cAAc"}
@@ -1,12 +1,10 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanCollapseToggle.d.ts
4
3
  export declare namespace SpanPrimitiveCollapseToggle {
5
- type Element = ComponentRef<typeof Primitive.button>;
6
- type Props = ComponentPropsWithoutRef<typeof Primitive.button>;
4
+ type Element = ComponentRef<typeof Primitive.button>;
5
+ type Props = ComponentPropsWithoutRef<typeof Primitive.button>;
7
6
  }
8
7
  export declare const SpanPrimitiveCollapseToggle: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & {
9
- asChild?: boolean;
8
+ asChild?: boolean;
10
9
  }, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
11
- //#endregion
12
10
  //# sourceMappingURL=SpanCollapseToggle.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanCollapseToggle.d.ts","names":[],"sources":["../../../src/primitives/span/SpanCollapseToggle.tsx"],"mappings":";;;yBAQiB;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;;qBAGnD,6CAA2B,0BAAA,qBAAA,gBAAA,qCAAA,qBAAA;;4BAuBtC,cAAA"}
1
+ {"version":3,"file":"SpanCollapseToggle.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanCollapseToggle.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAElB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,yBAAiB,2BAA2B,CAAC;IAC3C,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,MAAM,CAAC,CAAC;IAC5D,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,MAAM,CAAC,CAAC;CACvE;AAED,eAAO,MAAM,2BAA2B;;6DAuBtC,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
2
- import { forwardRef } from "@assistant-ui/tap/react-shim";
3
- import { Primitive } from "@radix-ui/react-primitive";
4
2
  import { useAui, useAuiState } from "@assistant-ui/store";
5
3
  import { jsx } from "react/jsx-runtime";
4
+ import { forwardRef } from "@assistant-ui/tap/react-shim";
5
+ import { Primitive } from "@radix-ui/react-primitive";
6
6
  //#region src/primitives/span/SpanCollapseToggle.tsx
7
7
  const SpanPrimitiveCollapseToggle = forwardRef((props, ref) => {
8
8
  const $ = c(8);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanCollapseToggle.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAui","useAuiState","SpanPrimitiveCollapseToggle","Element","button","Props","props","ref","$","_c","hasChildren","_temp","isCollapsed","_temp2","aui","t0","span","e","stopPropagation","toggleCollapse","onClick","t1","displayName","s","s_0"],"sources":["../../../src/primitives/span/SpanCollapseToggle.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAui, useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveCollapseToggle {\n export type Element = ComponentRef<typeof Primitive.button>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.button>;\n}\n\nexport const SpanPrimitiveCollapseToggle = forwardRef<\n SpanPrimitiveCollapseToggle.Element,\n SpanPrimitiveCollapseToggle.Props\n>((props, ref) => {\n const hasChildren = useAuiState((s) => s.span.hasChildren);\n const isCollapsed = useAuiState((s) => s.span.isCollapsed);\n const aui = useAui();\n\n if (!hasChildren) return null;\n\n return (\n <Primitive.button\n type=\"button\"\n {...props}\n ref={ref}\n data-collapsed={isCollapsed}\n onClick={(e) => {\n e.stopPropagation();\n aui.span.toggleCollapse();\n props.onClick?.(e);\n }}\n />\n );\n});\n\nSpanPrimitiveCollapseToggle.displayName = \"SpanPrimitive.CollapseToggle\";\n"],"mappings":";;;;;;AAaA,MAAaM,8BAA8BJ,YAGzCQ,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,cAAoBT,YAAYU,KAAyB;CACzD,MAAAC,cAAoBX,YAAYY,MAAyB;CACzD,MAAAC,MAAYd,OAAO;CAEnB,IAAI,CAACU,aAAW,OAAS;CAAK,IAAAK;CAAA,IAAAP,EAAA,OAAAM,IAAAE,QAAAR,EAAA,OAAAF,OAAA;EAQjBS,MAAAE,MAAA;GACPA,EAACC,gBAAiB;GAClBJ,IAAGE,KAAKG,eAAgB;GACxBb,MAAKc,UAAWH,CAAC;EAAC;EACnBT,EAAA,KAAAM,IAAAE;EAAAR,EAAA,KAAAF;EAAAE,EAAA,KAAAO;CAAA,OAAAA,KAAAP,EAAA;CAAA,IAAAa;CAAA,IAAAb,EAAA,OAAAI,eAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAO,IAAA;EATHM,KAAA,oBAAA,UAAA,QAAA;GACO,MAAA;GAAQ,GACTf;GACCC;GACWK,kBAAAA;GACP,SAAAG;EAIR,CAAA;EACDP,EAAA,KAAAI;EAAAJ,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAO;EAAAP,EAAA,KAAAa;CAAA,OAAAA,KAAAb,EAAA;CAAA,OAVFa;AAUE,CAEL;AAEDnB,4BAA4BoB,cAAc;AAtBxC,SAAAX,MAAAY,GAAA;CAAA,OACuCA,EAACP,KAAKN;AAAY;AADzD,SAAAG,OAAAW,KAAA;CAAA,OAEuCD,IAACP,KAAKJ;AAAY"}
1
+ {"version":3,"file":"SpanCollapseToggle.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAui","useAuiState","SpanPrimitiveCollapseToggle","Element","button","Props","props","ref","$","_c","hasChildren","_temp","isCollapsed","_temp2","aui","t0","span","e","stopPropagation","toggleCollapse","onClick","t1","displayName","s","s_0","_c"],"sources":["../../../src/primitives/span/SpanCollapseToggle.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAui, useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveCollapseToggle {\n export type Element = ComponentRef<typeof Primitive.button>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.button>;\n}\n\nexport const SpanPrimitiveCollapseToggle = forwardRef<\n SpanPrimitiveCollapseToggle.Element,\n SpanPrimitiveCollapseToggle.Props\n>((props, ref) => {\n const hasChildren = useAuiState((s) => s.span.hasChildren);\n const isCollapsed = useAuiState((s) => s.span.isCollapsed);\n const aui = useAui();\n\n if (!hasChildren) return null;\n\n return (\n <Primitive.button\n type=\"button\"\n {...props}\n ref={ref}\n data-collapsed={isCollapsed}\n onClick={(e) => {\n e.stopPropagation();\n aui.span.toggleCollapse();\n props.onClick?.(e);\n }}\n />\n );\n});\n\nSpanPrimitiveCollapseToggle.displayName = \"SpanPrimitive.CollapseToggle\";\n"],"mappings":";;;;;;AAaA,MAAaM,8BAA8BJ,YAGzCQ,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,cAAoBT,YAAYU,KAAyB;CACzD,MAAAC,cAAoBX,YAAYY,MAAyB;CACzD,MAAAC,MAAYd,OAAO;CAEnB,IAAI,CAACU,aAAW,OAAS;CAAK,IAAAK;CAAA,IAAAP,EAAA,OAAAM,IAAAE,QAAAR,EAAA,OAAAF,OAAA;EAQjBS,MAAAE,MAAA;GACPA,EAACC,gBAAiB;GAClBJ,IAAGE,KAAKG,eAAgB;GACxBb,MAAKc,UAAWH,CAAC;EAAC;EACnBT,EAAA,KAAAM,IAAAE;EAAAR,EAAA,KAAAF;EAAAE,EAAA,KAAAO;CAAA,OAAAA,KAAAP,EAAA;CAAA,IAAAa;CAAA,IAAAb,EAAA,OAAAI,eAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAO,IAAA;EATHM,KAAA,oBAAA,UAAA,QAAA;GACO,MAAA;GAAQ,GACTf;GACCC;GACWK,kBAAAA;GACP,SAAAG;EAIR,CAAA;EACDP,EAAA,KAAAI;EAAAJ,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAO;EAAAP,EAAA,KAAAa;CAAA,OAAAA,KAAAb,EAAA;CAAA,OAVFa;AAUE,CAEL;AAEDnB,4BAA4BoB,cAAc;AAtBxC,SAAAX,MAAAY,GAAA;CAAA,OACuCA,EAACP,KAAKN;AAAY;AADzD,SAAAG,OAAAW,KAAA;CAAA,OAEuCD,IAACP,KAAKJ;AAAY"}
@@ -1,18 +1,16 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanIndent.d.ts
4
3
  export declare namespace SpanPrimitiveIndent {
5
- type Element = ComponentRef<typeof Primitive.div>;
6
- type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
7
- baseIndent?: number;
8
- indentPerLevel?: number;
9
- };
4
+ type Element = ComponentRef<typeof Primitive.div>;
5
+ type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
6
+ baseIndent?: number;
7
+ indentPerLevel?: number;
8
+ };
10
9
  }
11
10
  export declare const SpanPrimitiveIndent: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
12
- asChild?: boolean;
11
+ asChild?: boolean;
13
12
  }, "ref"> & {
14
- baseIndent?: number;
15
- indentPerLevel?: number;
13
+ baseIndent?: number;
14
+ indentPerLevel?: number;
16
15
  } & import("react").RefAttributes<HTMLDivElement>>;
17
- //#endregion
18
16
  //# sourceMappingURL=SpanIndent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanIndent.d.ts","names":[],"sources":["../../../src/primitives/span/SpanIndent.tsx"],"mappings":";;;yBASiB;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;IAC5D;IACA;;;qBAIS,qCAAmB,0BAAA,qBAAA,gBAAA,kCAAA,eAAA;;;EALf;EACI;oBA0BnB,cAAA"}
1
+ {"version":3,"file":"SpanIndent.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanIndent.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAGlB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,yBAAiB,mBAAmB,CAAC;IACnC,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC;IACzD,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,GAAG;QACnE,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,cAAc,CAAC,EAAE,MAAM,CAAC;KACzB,CAAC;CACH;AAED,eAAO,MAAM,mBAAmB;;;iBALf,MAAM;qBACF,MAAM;kDA0BzB,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
2
- import { forwardRef } from "@assistant-ui/tap/react-shim";
3
- import { Primitive } from "@radix-ui/react-primitive";
4
2
  import { useAuiState } from "@assistant-ui/store";
5
3
  import { jsx } from "react/jsx-runtime";
4
+ import { forwardRef } from "@assistant-ui/tap/react-shim";
5
+ import { Primitive } from "@radix-ui/react-primitive";
6
6
  //#region src/primitives/span/SpanIndent.tsx
7
7
  const SpanPrimitiveIndent = forwardRef((t0, ref) => {
8
8
  const $ = c(13);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanIndent.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","useMemo","Primitive","useAuiState","SpanPrimitiveIndent","Element","div","Props","baseIndent","indentPerLevel","t0","ref","$","_c","props","style","t1","t2","undefined","depth","_temp","t3","t4","paddingLeft","mergedStyle","t5","displayName","s","span"],"sources":["../../../src/primitives/span/SpanIndent.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n useMemo,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveIndent {\n export type Element = ComponentRef<typeof Primitive.div>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {\n baseIndent?: number;\n indentPerLevel?: number;\n };\n}\n\nexport const SpanPrimitiveIndent = forwardRef<\n SpanPrimitiveIndent.Element,\n SpanPrimitiveIndent.Props\n>(({ baseIndent = 8, indentPerLevel = 12, style, ...props }, ref) => {\n const depth = useAuiState((s) => s.span.depth);\n\n const mergedStyle = useMemo(\n () => ({\n ...style,\n paddingLeft: baseIndent + depth * indentPerLevel,\n }),\n [style, baseIndent, depth, indentPerLevel],\n );\n\n return (\n <Primitive.div\n {...props}\n ref={ref}\n style={mergedStyle}\n data-span-depth={depth}\n />\n );\n});\n\nSpanPrimitiveIndent.displayName = \"SpanPrimitive.Indent\";\n"],"mappings":";;;;;;AAiBA,MAAaM,sBAAsBJ,YAGjCU,IAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,EAAA;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAL,EAAA,OAAAF,IAAA;EAAC,CAAA,CAAAF,YAAAQ,IAAAP,gBAAAQ,IAAAF,OAAA,GAAAD,SAAAJ;EAAwDE,EAAA,KAAAF;EAAAE,EAAA,KAAAE;EAAAF,EAAA,KAAAG;EAAAH,EAAA,KAAAI;EAAAJ,EAAA,KAAAK;CAAA,OAAA;EAAAH,QAAAF,EAAA;EAAAG,QAAAH,EAAA;EAAAI,KAAAJ,EAAA;EAAAK,KAAAL,EAAA;CAAA;CAAtD,MAAAJ,aAAAQ,OAAAE,KAAAA,IAAA,IAAAF;CAAgB,MAAAP,iBAAAQ,OAAAC,KAAAA,IAAA,KAAAD;CACnB,MAAAE,QAAchB,YAAYiB,KAAmB;CAK5B,MAAAC,KAAAb,aAAaW,QAAQV;CAAc,IAAAa;CAAA,IAAAV,EAAA,OAAAG,SAAAH,EAAA,OAAAS,IAAA;EAF3CC,KAAA;GAAA,GACFP;GAAKQ,aACKF;EACf;EAACT,EAAA,KAAAG;EAAAH,EAAA,KAAAS;EAAAT,EAAA,KAAAU;CAAA,OAAAA,KAAAV,EAAA;CAJH,MAAAY,cACSF;CAKP,IAAAG;CAAA,IAAAb,EAAA,OAAAO,SAAAP,EAAA,OAAAY,eAAAZ,EAAA,QAAAE,SAAAF,EAAA,QAAAD,KAAA;EAGAc,KAAA,oBAAA,UAAA,KAAA;GAAA,GACMX;GACCH;GACEa,OAAAA;GACUL,mBAAAA;EAAK,CAAA;EACtBP,EAAA,KAAAO;EAAAP,EAAA,KAAAY;EAAAZ,EAAA,MAAAE;EAAAF,EAAA,MAAAD;EAAAC,EAAA,MAAAa;CAAA,OAAAA,KAAAb,EAAA;CAAA,OALFa;AAKE,CAEL;AAEDrB,oBAAoBsB,cAAc;AArBhC,SAAAN,MAAAO,GAAA;CAAA,OACiCA,EAACC,KAAKT;AAAM"}
1
+ {"version":3,"file":"SpanIndent.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","useMemo","Primitive","useAuiState","SpanPrimitiveIndent","Element","div","Props","baseIndent","indentPerLevel","t0","ref","$","_c","props","style","t1","t2","undefined","depth","_temp","t3","t4","paddingLeft","mergedStyle","t5","displayName","s","span","_c"],"sources":["../../../src/primitives/span/SpanIndent.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n useMemo,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveIndent {\n export type Element = ComponentRef<typeof Primitive.div>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {\n baseIndent?: number;\n indentPerLevel?: number;\n };\n}\n\nexport const SpanPrimitiveIndent = forwardRef<\n SpanPrimitiveIndent.Element,\n SpanPrimitiveIndent.Props\n>(({ baseIndent = 8, indentPerLevel = 12, style, ...props }, ref) => {\n const depth = useAuiState((s) => s.span.depth);\n\n const mergedStyle = useMemo(\n () => ({\n ...style,\n paddingLeft: baseIndent + depth * indentPerLevel,\n }),\n [style, baseIndent, depth, indentPerLevel],\n );\n\n return (\n <Primitive.div\n {...props}\n ref={ref}\n style={mergedStyle}\n data-span-depth={depth}\n />\n );\n});\n\nSpanPrimitiveIndent.displayName = \"SpanPrimitive.Indent\";\n"],"mappings":";;;;;;AAiBA,MAAaM,sBAAsBJ,YAGjCU,IAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,EAAA;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAC;CAAA,IAAAL,EAAA,OAAAF,IAAA;EAAC,CAAA,CAAAF,YAAAQ,IAAAP,gBAAAQ,IAAAF,OAAA,GAAAD,SAAAJ;EAAwDE,EAAA,KAAAF;EAAAE,EAAA,KAAAE;EAAAF,EAAA,KAAAG;EAAAH,EAAA,KAAAI;EAAAJ,EAAA,KAAAK;CAAA,OAAA;EAAAH,QAAAF,EAAA;EAAAG,QAAAH,EAAA;EAAAI,KAAAJ,EAAA;EAAAK,KAAAL,EAAA;CAAA;CAAtD,MAAAJ,aAAAQ,OAAAE,KAAAA,IAAA,IAAAF;CAAgB,MAAAP,iBAAAQ,OAAAC,KAAAA,IAAA,KAAAD;CACnB,MAAAE,QAAchB,YAAYiB,KAAmB;CAK5B,MAAAC,KAAAb,aAAaW,QAAQV;CAAc,IAAAa;CAAA,IAAAV,EAAA,OAAAG,SAAAH,EAAA,OAAAS,IAAA;EAF3CC,KAAA;GAAA,GACFP;GAAKQ,aACKF;EACf;EAACT,EAAA,KAAAG;EAAAH,EAAA,KAAAS;EAAAT,EAAA,KAAAU;CAAA,OAAAA,KAAAV,EAAA;CAJH,MAAAY,cACSF;CAKP,IAAAG;CAAA,IAAAb,EAAA,OAAAO,SAAAP,EAAA,OAAAY,eAAAZ,EAAA,QAAAE,SAAAF,EAAA,QAAAD,KAAA;EAGAc,KAAA,oBAAA,UAAA,KAAA;GAAA,GACMX;GACCH;GACEa,OAAAA;GACUL,mBAAAA;EAAK,CAAA;EACtBP,EAAA,KAAAO;EAAAP,EAAA,KAAAY;EAAAZ,EAAA,MAAAE;EAAAF,EAAA,MAAAD;EAAAC,EAAA,MAAAa;CAAA,OAAAA,KAAAb,EAAA;CAAA,OALFa;AAKE,CAEL;AAEDrB,oBAAoBsB,cAAc;AArBhC,SAAAN,MAAAO,GAAA;CAAA,OACiCA,EAACC,KAAKT;AAAM"}
@@ -1,12 +1,10 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanName.d.ts
4
3
  export declare namespace SpanPrimitiveName {
5
- type Element = ComponentRef<typeof Primitive.span>;
6
- type Props = ComponentPropsWithoutRef<typeof Primitive.span>;
4
+ type Element = ComponentRef<typeof Primitive.span>;
5
+ type Props = ComponentPropsWithoutRef<typeof Primitive.span>;
7
6
  }
8
7
  export declare const SpanPrimitiveName: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLSpanElement> & import("react").HTMLAttributes<HTMLSpanElement> & {
9
- asChild?: boolean;
8
+ asChild?: boolean;
10
9
  }, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
11
- //#endregion
12
10
  //# sourceMappingURL=SpanName.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanName.d.ts","names":[],"sources":["../../../src/primitives/span/SpanName.tsx"],"mappings":";;;yBAQiB;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;;qBAGnD,mCAAiB,0BAAA,qBAAA,gBAAA,mCAAA,eAAA;;4BAW5B,cAAA"}
1
+ {"version":3,"file":"SpanName.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanName.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAElB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,yBAAiB,iBAAiB,CAAC;IACjC,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;IAC1D,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;CACrE;AAED,eAAO,MAAM,iBAAiB;;2DAW5B,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
2
- import { forwardRef } from "@assistant-ui/tap/react-shim";
3
- import { Primitive } from "@radix-ui/react-primitive";
4
2
  import { useAuiState } from "@assistant-ui/store";
5
3
  import { jsx } from "react/jsx-runtime";
4
+ import { forwardRef } from "@assistant-ui/tap/react-shim";
5
+ import { Primitive } from "@radix-ui/react-primitive";
6
6
  //#region src/primitives/span/SpanName.tsx
7
7
  const SpanPrimitiveName = forwardRef((props, ref) => {
8
8
  const $ = c(4);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanName.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveName","Element","span","Props","props","ref","$","_c","name","_temp","t0","children","t1","displayName","s"],"sources":["../../../src/primitives/span/SpanName.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveName {\n export type Element = ComponentRef<typeof Primitive.span>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.span>;\n}\n\nexport const SpanPrimitiveName = forwardRef<\n SpanPrimitiveName.Element,\n SpanPrimitiveName.Props\n>((props, ref) => {\n const name = useAuiState((s) => s.span.name);\n\n return (\n <Primitive.span {...props} ref={ref}>\n {props.children ?? name}\n </Primitive.span>\n );\n});\n\nSpanPrimitiveName.displayName = \"SpanPrimitive.Name\";\n"],"mappings":";;;;;;AAaA,MAAaK,oBAAoBH,YAG/BO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,OAAaT,YAAYU,KAAkB;CAItC,MAAAC,KAAAN,MAAKO,YAALH;CAAsB,IAAAI;CAAA,IAAAN,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAI,IAAA;EADzBE,KAAA,oBAAA,UAAA,MAAA;GAAA,GAAoBR;GAAYC;GAC7BK,UAAAA;EACH,CAAA;EAAiBJ,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAI;EAAAJ,EAAA,KAAAM;CAAA,OAAAA,KAAAN,EAAA;CAAA,OAFjBM;AAEiB,CAEpB;AAEDZ,kBAAkBa,cAAc;AAV9B,SAAAJ,MAAAK,GAAA;CAAA,OACgCA,EAACZ,KAAKM;AAAK"}
1
+ {"version":3,"file":"SpanName.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveName","Element","span","Props","props","ref","$","_c","name","_temp","t0","children","t1","displayName","s","_c"],"sources":["../../../src/primitives/span/SpanName.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveName {\n export type Element = ComponentRef<typeof Primitive.span>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.span>;\n}\n\nexport const SpanPrimitiveName = forwardRef<\n SpanPrimitiveName.Element,\n SpanPrimitiveName.Props\n>((props, ref) => {\n const name = useAuiState((s) => s.span.name);\n\n return (\n <Primitive.span {...props} ref={ref}>\n {props.children ?? name}\n </Primitive.span>\n );\n});\n\nSpanPrimitiveName.displayName = \"SpanPrimitive.Name\";\n"],"mappings":";;;;;;AAaA,MAAaK,oBAAoBH,YAG/BO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,OAAaT,YAAYU,KAAkB;CAItC,MAAAC,KAAAN,MAAKO,YAALH;CAAsB,IAAAI;CAAA,IAAAN,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAI,IAAA;EADzBE,KAAA,oBAAA,UAAA,MAAA;GAAA,GAAoBR;GAAYC;GAC7BK,UAAAA;EACH,CAAA;EAAiBJ,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAI;EAAAJ,EAAA,KAAAM;CAAA,OAAAA,KAAAN,EAAA;CAAA,OAFjBM;AAEiB,CAEpB;AAEDZ,kBAAkBa,cAAc;AAV9B,SAAAJ,MAAAK,GAAA;CAAA,OACgCA,EAACZ,KAAKM;AAAK"}
@@ -1,12 +1,10 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanRoot.d.ts
4
3
  export declare namespace SpanPrimitiveRoot {
5
- type Element = ComponentRef<typeof Primitive.div>;
6
- type Props = ComponentPropsWithoutRef<typeof Primitive.div>;
4
+ type Element = ComponentRef<typeof Primitive.div>;
5
+ type Props = ComponentPropsWithoutRef<typeof Primitive.div>;
7
6
  }
8
7
  export declare const SpanPrimitiveRoot: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
9
- asChild?: boolean;
8
+ asChild?: boolean;
10
9
  }, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
11
- //#endregion
12
10
  //# sourceMappingURL=SpanRoot.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanRoot.d.ts","names":[],"sources":["../../../src/primitives/span/SpanRoot.tsx"],"mappings":";;;yBAQiB;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;;qBAGnD,mCAAiB,0BAAA,qBAAA,gBAAA,kCAAA,eAAA;;4BAqB5B,cAAA"}
1
+ {"version":3,"file":"SpanRoot.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanRoot.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAElB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,yBAAiB,iBAAiB,CAAC;IACjC,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC;IACzD,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC;CACpE;AAED,eAAO,MAAM,iBAAiB;;0DAqB5B,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
2
- import { forwardRef } from "@assistant-ui/tap/react-shim";
3
- import { Primitive } from "@radix-ui/react-primitive";
4
2
  import { useAuiState } from "@assistant-ui/store";
5
3
  import { jsx } from "react/jsx-runtime";
4
+ import { forwardRef } from "@assistant-ui/tap/react-shim";
5
+ import { Primitive } from "@radix-ui/react-primitive";
6
6
  //#region src/primitives/span/SpanRoot.tsx
7
7
  const SpanPrimitiveRoot = forwardRef((props, ref) => {
8
8
  const $ = c(8);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanRoot.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveRoot","Element","div","Props","props","ref","$","_c","spanId","_temp","status","_temp2","type","_temp3","depth","_temp4","isCollapsed","_temp5","t0","displayName","s","span","id","s_0","s_1","s_2","s_3"],"sources":["../../../src/primitives/span/SpanRoot.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveRoot {\n export type Element = ComponentRef<typeof Primitive.div>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.div>;\n}\n\nexport const SpanPrimitiveRoot = forwardRef<\n SpanPrimitiveRoot.Element,\n SpanPrimitiveRoot.Props\n>((props, ref) => {\n const spanId = useAuiState((s) => s.span.id);\n const status = useAuiState((s) => s.span.status);\n const type = useAuiState((s) => s.span.type);\n const depth = useAuiState((s) => s.span.depth);\n const isCollapsed = useAuiState((s) => s.span.isCollapsed);\n\n return (\n <Primitive.div\n {...props}\n ref={ref}\n data-span-id={spanId}\n data-span-status={status}\n data-span-type={type}\n data-span-depth={depth}\n data-collapsed={isCollapsed}\n />\n );\n});\n\nSpanPrimitiveRoot.displayName = \"SpanPrimitive.Root\";\n"],"mappings":";;;;;;AAaA,MAAaK,oBAAoBH,YAG/BO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,SAAeT,YAAYU,KAAgB;CAC3C,MAAAC,SAAeX,YAAYY,MAAoB;CAC/C,MAAAC,OAAab,YAAYc,MAAkB;CAC3C,MAAAC,QAAcf,YAAYgB,MAAmB;CAC7C,MAAAC,cAAoBjB,YAAYkB,MAAyB;CAAE,IAAAC;CAAA,IAAAZ,EAAA,OAAAQ,SAAAR,EAAA,OAAAU,eAAAV,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAE,UAAAF,EAAA,OAAAI,UAAAJ,EAAA,OAAAM,MAAA;EAGzDM,KAAA,oBAAA,UAAA,KAAA;GAAA,GACMd;GACCC;GACSG,gBAAAA;GACIE,oBAAAA;GACFE,kBAAAA;GACCE,mBAAAA;GACDE,kBAAAA;EAAW,CAAA;EAC3BV,EAAA,KAAAQ;EAAAR,EAAA,KAAAU;EAAAV,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAE;EAAAF,EAAA,KAAAI;EAAAJ,EAAA,KAAAM;EAAAN,EAAA,KAAAY;CAAA,OAAAA,KAAAZ,EAAA;CAAA,OARFY;AAQE,CAEL;AAEDlB,kBAAkBmB,cAAc;AApB9B,SAAAV,MAAAW,GAAA;CAAA,OACkCA,EAACC,KAAKC;AAAG;AAD3C,SAAAX,OAAAY,KAAA;CAAA,OAEkCH,IAACC,KAAKX;AAAO;AAF/C,SAAAG,OAAAW,KAAA;CAAA,OAGgCJ,IAACC,KAAKT;AAAK;AAH3C,SAAAG,OAAAU,KAAA;CAAA,OAIiCL,IAACC,KAAKP;AAAM;AAJ7C,SAAAG,OAAAS,KAAA;CAAA,OAKuCN,IAACC,KAAKL;AAAY"}
1
+ {"version":3,"file":"SpanRoot.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveRoot","Element","div","Props","props","ref","$","_c","spanId","_temp","status","_temp2","type","_temp3","depth","_temp4","isCollapsed","_temp5","t0","displayName","s","span","id","s_0","s_1","s_2","s_3","_c"],"sources":["../../../src/primitives/span/SpanRoot.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveRoot {\n export type Element = ComponentRef<typeof Primitive.div>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.div>;\n}\n\nexport const SpanPrimitiveRoot = forwardRef<\n SpanPrimitiveRoot.Element,\n SpanPrimitiveRoot.Props\n>((props, ref) => {\n const spanId = useAuiState((s) => s.span.id);\n const status = useAuiState((s) => s.span.status);\n const type = useAuiState((s) => s.span.type);\n const depth = useAuiState((s) => s.span.depth);\n const isCollapsed = useAuiState((s) => s.span.isCollapsed);\n\n return (\n <Primitive.div\n {...props}\n ref={ref}\n data-span-id={spanId}\n data-span-status={status}\n data-span-type={type}\n data-span-depth={depth}\n data-collapsed={isCollapsed}\n />\n );\n});\n\nSpanPrimitiveRoot.displayName = \"SpanPrimitive.Root\";\n"],"mappings":";;;;;;AAaA,MAAaK,oBAAoBH,YAG/BO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,SAAeT,YAAYU,KAAgB;CAC3C,MAAAC,SAAeX,YAAYY,MAAoB;CAC/C,MAAAC,OAAab,YAAYc,MAAkB;CAC3C,MAAAC,QAAcf,YAAYgB,MAAmB;CAC7C,MAAAC,cAAoBjB,YAAYkB,MAAyB;CAAE,IAAAC;CAAA,IAAAZ,EAAA,OAAAQ,SAAAR,EAAA,OAAAU,eAAAV,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAE,UAAAF,EAAA,OAAAI,UAAAJ,EAAA,OAAAM,MAAA;EAGzDM,KAAA,oBAAA,UAAA,KAAA;GAAA,GACMd;GACCC;GACSG,gBAAAA;GACIE,oBAAAA;GACFE,kBAAAA;GACCE,mBAAAA;GACDE,kBAAAA;EAAW,CAAA;EAC3BV,EAAA,KAAAQ;EAAAR,EAAA,KAAAU;EAAAV,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAE;EAAAF,EAAA,KAAAI;EAAAJ,EAAA,KAAAM;EAAAN,EAAA,KAAAY;CAAA,OAAAA,KAAAZ,EAAA;CAAA,OARFY;AAQE,CAEL;AAEDlB,kBAAkBmB,cAAc;AApB9B,SAAAV,MAAAW,GAAA;CAAA,OACkCA,EAACC,KAAKC;AAAG;AAD3C,SAAAX,OAAAY,KAAA;CAAA,OAEkCH,IAACC,KAAKX;AAAO;AAF/C,SAAAG,OAAAW,KAAA;CAAA,OAGgCJ,IAACC,KAAKT;AAAK;AAH3C,SAAAG,OAAAU,KAAA;CAAA,OAIiCL,IAACC,KAAKP;AAAM;AAJ7C,SAAAG,OAAAS,KAAA;CAAA,OAKuCN,IAACC,KAAKL;AAAY"}
@@ -1,12 +1,10 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanStatusIndicator.d.ts
4
3
  export declare namespace SpanPrimitiveStatusIndicator {
5
- type Element = ComponentRef<typeof Primitive.span>;
6
- type Props = ComponentPropsWithoutRef<typeof Primitive.span>;
4
+ type Element = ComponentRef<typeof Primitive.span>;
5
+ type Props = ComponentPropsWithoutRef<typeof Primitive.span>;
7
6
  }
8
7
  export declare const SpanPrimitiveStatusIndicator: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLSpanElement> & import("react").HTMLAttributes<HTMLSpanElement> & {
9
- asChild?: boolean;
8
+ asChild?: boolean;
10
9
  }, "ref"> & import("react").RefAttributes<HTMLSpanElement>>;
11
- //#endregion
12
10
  //# sourceMappingURL=SpanStatusIndicator.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanStatusIndicator.d.ts","names":[],"sources":["../../../src/primitives/span/SpanStatusIndicator.tsx"],"mappings":";;;yBAQiB;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;;qBAGnD,8CAA4B,0BAAA,qBAAA,gBAAA,mCAAA,eAAA;;4BAOvC,cAAA"}
1
+ {"version":3,"file":"SpanStatusIndicator.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanStatusIndicator.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAElB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,yBAAiB,4BAA4B,CAAC;IAC5C,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;IAC1D,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,IAAI,CAAC,CAAC;CACrE;AAED,eAAO,MAAM,4BAA4B;;2DAOvC,CAAC"}
@@ -1,8 +1,8 @@
1
1
  import { c } from "@assistant-ui/tap/react-shim/compiler-runtime";
2
- import { forwardRef } from "@assistant-ui/tap/react-shim";
3
- import { Primitive } from "@radix-ui/react-primitive";
4
2
  import { useAuiState } from "@assistant-ui/store";
5
3
  import { jsx } from "react/jsx-runtime";
4
+ import { forwardRef } from "@assistant-ui/tap/react-shim";
5
+ import { Primitive } from "@radix-ui/react-primitive";
6
6
  //#region src/primitives/span/SpanStatusIndicator.tsx
7
7
  const SpanPrimitiveStatusIndicator = forwardRef((props, ref) => {
8
8
  const $ = c(4);
@@ -1 +1 @@
1
- {"version":3,"file":"SpanStatusIndicator.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveStatusIndicator","Element","span","Props","props","ref","$","_c","status","_temp","t0","displayName","s"],"sources":["../../../src/primitives/span/SpanStatusIndicator.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveStatusIndicator {\n export type Element = ComponentRef<typeof Primitive.span>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.span>;\n}\n\nexport const SpanPrimitiveStatusIndicator = forwardRef<\n SpanPrimitiveStatusIndicator.Element,\n SpanPrimitiveStatusIndicator.Props\n>((props, ref) => {\n const status = useAuiState((s) => s.span.status);\n\n return <Primitive.span {...props} ref={ref} data-span-status={status} />;\n});\n\nSpanPrimitiveStatusIndicator.displayName = \"SpanPrimitive.StatusIndicator\";\n"],"mappings":";;;;;;AAaA,MAAaK,+BAA+BH,YAG1CO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,SAAeT,YAAYU,KAAoB;CAAE,IAAAC;CAAA,IAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAE,QAAA;EAE1CE,KAAA,oBAAA,UAAA,MAAA;GAAA,GAAoBN;GAAYC;GAAuBG,oBAAAA;EAAM,CAAA;EAAIF,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAE;EAAAF,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CAAA,OAAjEI;AAAiE,CACzE;AAEDV,6BAA6BW,cAAc;AANzC,SAAAF,MAAAG,GAAA;CAAA,OACkCA,EAACV,KAAKM;AAAO"}
1
+ {"version":3,"file":"SpanStatusIndicator.js","names":["ComponentPropsWithoutRef","ComponentRef","forwardRef","Primitive","useAuiState","SpanPrimitiveStatusIndicator","Element","span","Props","props","ref","$","_c","status","_temp","t0","displayName","s","_c"],"sources":["../../../src/primitives/span/SpanStatusIndicator.tsx"],"sourcesContent":["import {\n type ComponentPropsWithoutRef,\n type ComponentRef,\n forwardRef,\n} from \"react\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useAuiState } from \"@assistant-ui/store\";\n\nexport namespace SpanPrimitiveStatusIndicator {\n export type Element = ComponentRef<typeof Primitive.span>;\n export type Props = ComponentPropsWithoutRef<typeof Primitive.span>;\n}\n\nexport const SpanPrimitiveStatusIndicator = forwardRef<\n SpanPrimitiveStatusIndicator.Element,\n SpanPrimitiveStatusIndicator.Props\n>((props, ref) => {\n const status = useAuiState((s) => s.span.status);\n\n return <Primitive.span {...props} ref={ref} data-span-status={status} />;\n});\n\nSpanPrimitiveStatusIndicator.displayName = \"SpanPrimitive.StatusIndicator\";\n"],"mappings":";;;;;;AAaA,MAAaK,+BAA+BH,YAG1CO,OAAAC,QAAA;CAAA,MAAAC,IAAAC,EAAA,CAAA;CACA,MAAAC,SAAeT,YAAYU,KAAoB;CAAE,IAAAC;CAAA,IAAAJ,EAAA,OAAAF,SAAAE,EAAA,OAAAD,OAAAC,EAAA,OAAAE,QAAA;EAE1CE,KAAA,oBAAA,UAAA,MAAA;GAAA,GAAoBN;GAAYC;GAAuBG,oBAAAA;EAAM,CAAA;EAAIF,EAAA,KAAAF;EAAAE,EAAA,KAAAD;EAAAC,EAAA,KAAAE;EAAAF,EAAA,KAAAI;CAAA,OAAAA,KAAAJ,EAAA;CAAA,OAAjEI;AAAiE,CACzE;AAEDV,6BAA6BW,cAAc;AANzC,SAAAF,MAAAG,GAAA;CAAA,OACkCA,EAACV,KAAKM;AAAO"}
@@ -1,47 +1,45 @@
1
- import { ComponentPropsWithoutRef, ComponentRef } from "react";
1
+ import { type ComponentPropsWithoutRef, type ComponentRef } from "react";
2
2
  import { Primitive } from "@radix-ui/react-primitive";
3
- //#region src/primitives/span/SpanTimeline.d.ts
4
3
  export type SpanTimelineRange = {
5
- min: number;
6
- max: number;
4
+ min: number;
5
+ max: number;
7
6
  };
8
7
  export declare namespace SpanPrimitiveTimeline {
9
- type Element = ComponentRef<typeof Primitive.div>;
10
- type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
11
- timeRange?: SpanTimelineRange | undefined;
12
- paddingEnd?: number | undefined;
13
- };
8
+ type Element = ComponentRef<typeof Primitive.div>;
9
+ type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
10
+ timeRange?: SpanTimelineRange | undefined;
11
+ paddingEnd?: number | undefined;
12
+ };
14
13
  }
15
14
  export declare const SpanPrimitiveTimeline: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
16
- asChild?: boolean;
15
+ asChild?: boolean;
17
16
  }, "ref"> & {
18
- timeRange?: SpanTimelineRange | undefined;
19
- paddingEnd?: number | undefined;
17
+ timeRange?: SpanTimelineRange | undefined;
18
+ paddingEnd?: number | undefined;
20
19
  } & import("react").RefAttributes<HTMLDivElement>>;
21
20
  export declare namespace SpanPrimitiveTimelineBar {
22
- type Element = ComponentRef<typeof Primitive.div>;
23
- type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
24
- now?: number | undefined;
25
- timeRange?: SpanTimelineRange | undefined;
26
- };
21
+ type Element = ComponentRef<typeof Primitive.div>;
22
+ type Props = ComponentPropsWithoutRef<typeof Primitive.div> & {
23
+ now?: number | undefined;
24
+ timeRange?: SpanTimelineRange | undefined;
25
+ };
27
26
  }
28
- export declare const getSpanTimelineBarVars: ({ startedAt, endedAt, timeRange, now }: {
29
- startedAt: number;
30
- endedAt: number | null;
31
- timeRange: SpanTimelineRange;
32
- now?: number | undefined;
27
+ export declare const getSpanTimelineBarVars: ({ startedAt, endedAt, timeRange, now, }: {
28
+ startedAt: number;
29
+ endedAt: number | null;
30
+ timeRange: SpanTimelineRange;
31
+ now?: number | undefined;
33
32
  }) => {
34
- leftPercent: number;
35
- endPercent: number;
36
- widthPercent: number;
37
- durationMs: number;
38
- effectiveEnd: number;
33
+ leftPercent: number;
34
+ endPercent: number;
35
+ widthPercent: number;
36
+ durationMs: number;
37
+ effectiveEnd: number;
39
38
  };
40
39
  export declare const SpanPrimitiveTimelineBar: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
41
- asChild?: boolean;
40
+ asChild?: boolean;
42
41
  }, "ref"> & {
43
- now?: number | undefined;
44
- timeRange?: SpanTimelineRange | undefined;
42
+ now?: number | undefined;
43
+ timeRange?: SpanTimelineRange | undefined;
45
44
  } & import("react").RefAttributes<HTMLDivElement>>;
46
- //#endregion
47
45
  //# sourceMappingURL=SpanTimeline.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SpanTimeline.d.ts","names":[],"sources":["../../../src/primitives/span/SpanTimeline.tsx"],"mappings":";;;YAYY;EAAsB;EAAa;;yBA6B9B;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;IAC5D,YAAY;IACZ;;;qBAIS,uCAAqB,0BAAA,qBAAA,gBAAA,kCAAA,eAAA;;;EALlB,YAAA;EACC;oBAkCf,cAAA;yBAIe;OACH,UAAU,oBAAoB,UAAU;OACxC,QAAQ,gCAAgC,UAAU;IAC5D;IACA,YAAY;;;qBAIH,2BAA0B,WAAA,SAAA,WAAA;EAMrC;EACA;EACA,WAAW;EACX;;;;;;;;qBAqBW,0CAAwB,0BAAA,qBAAA,gBAAA,kCAAA,eAAA;;;EAnC3B;EACM,YAAA;oBA0Ed,cAAA"}
1
+ {"version":3,"file":"SpanTimeline.d.ts","sourceRoot":"","sources":["../../../src/primitives/span/SpanTimeline.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAMlB,MAAM,OAAO,CAAC;AACf,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAGtD,MAAM,MAAM,iBAAiB,GAAG;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC;AA6B7D,yBAAiB,qBAAqB,CAAC;IACrC,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC;IACzD,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,GAAG;QACnE,SAAS,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;QAC1C,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;KACjC,CAAC;CACH;AAED,eAAO,MAAM,qBAAqB;;;gBALlB,iBAAiB,GAAG,SAAS;iBAC5B,MAAM,GAAG,SAAS;kDAkCjC,CAAC;AAIH,yBAAiB,wBAAwB,CAAC;IACxC,KAAY,OAAO,GAAG,YAAY,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,CAAC;IACzD,KAAY,KAAK,GAAG,wBAAwB,CAAC,OAAO,SAAS,CAAC,GAAG,CAAC,GAAG;QACnE,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;QACzB,SAAS,CAAC,EAAE,iBAAiB,GAAG,SAAS,CAAC;KAC3C,CAAC;CACH;AAED,eAAO,MAAM,sBAAsB,GAAI,yCAKpC;IACD,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,SAAS,EAAE,iBAAiB,CAAC;IAC7B,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC1B;;;;;;CAkBA,CAAC;AAEF,eAAO,MAAM,wBAAwB;;;UAnC3B,MAAM,GAAG,SAAS;gBACZ,iBAAiB,GAAG,SAAS;kDA0E3C,CAAC"}