@aiquants/daily-report 0.27.0 → 0.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/client.d.mts CHANGED
@@ -1,9 +1,9 @@
1
1
  import * as react from "react";
2
2
  import { RefObject, ReactNode, Context } from "react";
3
- import { D as DailyReportItem, a as DailyReportUser, b as DailyReportDetail } from "./types-DkERw8NE.mjs";
4
- import { VirtualScrollLocale, VirtualScrollLabels } from "@aiquants/virtualscroll";
3
+ import { D as DailyReportItem, a as DailyReportUser, b as DailyReportDetail, c as DailyReportSseStreamAnchor } from "./ids-stream-CWuIDrIO.mjs";
4
+ import { VirtualScrollLocale, VirtualScrollLabels, VirtualScrollHandle } from "@aiquants/virtualscroll";
5
5
  import { UseReopeningEventSourceResult } from "@aiquants/sse/react";
6
- import { D as DailyReportSseTerminalEvent, a as DailyReportSseMessage, U as UIComment, b as DailyReportSseStreamAnchor } from "./ids-stream-DvB2h1dj.mjs";
6
+ import { D as DailyReportSseTerminalEvent, a as DailyReportSseMessage, U as UIComment } from "./comment-adapter-lV2ZB_vH.mjs";
7
7
  import { ShouldRevalidateFunction } from "react-router";
8
8
  import "zod";
9
9
  type DailyReportAttachmentIndicatorProps = {
@@ -281,6 +281,15 @@ type DailyReportResolvedContentProps = {
281
281
  userId?: string | null;
282
282
  };
283
283
  declare const DailyReportResolvedContent: ({ userId }: DailyReportResolvedContentProps) => react.JSX.Element;
284
+ type ListNavigationHandle = Pick<VirtualScrollHandle, "getViewportSize" | "getScrollPosition" | "getScrollAnchor">;
285
+ type ListScrollToIndexOptions = NonNullable<Parameters<VirtualScrollHandle["scrollToIndex"]>[1]>;
286
+ type ViewTestReadHandle = ListNavigationHandle & Pick<VirtualScrollHandle, "getRange" | "getFenwickSize">;
287
+ type ViewTestHandle = ViewTestReadHandle & {
288
+ readonly findReportIndex: (id: number) => number;
289
+ readonly getReportItem: (index: number) => DailyReportItem | undefined;
290
+ readonly getReportIds: (limit?: number) => number[];
291
+ readonly revealIndex: (index: number, options: ListScrollToIndexOptions) => void;
292
+ };
284
293
  type DailyReportSseConnectionStatus = UseReopeningEventSourceResult<DailyReportSseTerminalEvent>["status"] | {
285
294
  readonly kind: "resyncing";
286
295
  };
@@ -454,4 +463,5 @@ declare const bootstrapDailyReportIdsStreamSession: (options: {
454
463
  declare const primeDailyReportIdsStreamSession: () => void;
455
464
  declare const resyncDailyReportIdsStream: () => void;
456
465
  declare const useDailyReportIdsStream: () => DailyReportIdsStreamState;
457
- export { DAILY_REPORT_LABEL_CATALOGS, DAILY_REPORT_LABEL_KEYS, DailyReportActionProvider, DailyReportAttachmentIndicator, type DailyReportClientConfigDefaults, type DailyReportClientConfigInput, DailyReportConfigProvider, DailyReportDetailList, type DailyReportErrorInfo, DailyReportErrorProvider, DailyReportIdsStreamClient, DailyReportIdsStreamStatus, type DailyReportLabelOverrides, type DailyReportLabels, DailyReportList, type DailyReportLocale, type DailyReportOperation, DailyReportPage, DailyReportResolvedContent, type DailyReportSseConnectionStatus, type SourceTypeConfig, bootstrapDailyReportIdsStreamSession, createDailyReportClientLoader, dailyReportShouldRevalidate, defaultDailyReportClientConfig, ensureDailyReportIdsStreamSession, primeDailyReportIdsStreamSession, resolveDailyReportLabels, resolveSourceTypeConfig, resyncDailyReportIdsStream, useDailyReportActionContext, useDailyReportComments, useDailyReportConfig, useDailyReportDetail, useDailyReportIdsStream, useDailyReportPrefetch, useDailyReportSseConnection };
466
+ declare const DAILY_REPORT_LAYOUT_LATTICE_PX = 4;
467
+ export { DAILY_REPORT_LABEL_CATALOGS, DAILY_REPORT_LABEL_KEYS, DAILY_REPORT_LAYOUT_LATTICE_PX, DailyReportActionProvider, DailyReportAttachmentIndicator, type DailyReportClientConfigDefaults, type DailyReportClientConfigInput, DailyReportConfigProvider, DailyReportDetailList, type DailyReportErrorInfo, DailyReportErrorProvider, DailyReportIdsStreamClient, DailyReportIdsStreamStatus, type DailyReportLabelOverrides, type DailyReportLabels, DailyReportList, type DailyReportLocale, type DailyReportOperation, DailyReportPage, DailyReportResolvedContent, type ListScrollToIndexOptions as DailyReportRevealOptions, type DailyReportSseConnectionStatus, type ViewTestHandle as DailyReportViewTestHandle, type ViewTestReadHandle as DailyReportViewTestReadHandle, type SourceTypeConfig, bootstrapDailyReportIdsStreamSession, createDailyReportClientLoader, dailyReportShouldRevalidate, defaultDailyReportClientConfig, ensureDailyReportIdsStreamSession, primeDailyReportIdsStreamSession, resolveDailyReportLabels, resolveSourceTypeConfig, resyncDailyReportIdsStream, useDailyReportActionContext, useDailyReportComments, useDailyReportConfig, useDailyReportDetail, useDailyReportIdsStream, useDailyReportPrefetch, useDailyReportSseConnection };
package/dist/client.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  import * as react from "react";
2
2
  import { RefObject, ReactNode, Context } from "react";
3
- import { D as DailyReportItem, a as DailyReportUser, b as DailyReportDetail } from "./types-DkERw8NE.js";
4
- import { VirtualScrollLocale, VirtualScrollLabels } from "@aiquants/virtualscroll";
3
+ import { D as DailyReportItem, a as DailyReportUser, b as DailyReportDetail, c as DailyReportSseStreamAnchor } from "./ids-stream-CWuIDrIO.js";
4
+ import { VirtualScrollLocale, VirtualScrollLabels, VirtualScrollHandle } from "@aiquants/virtualscroll";
5
5
  import { UseReopeningEventSourceResult } from "@aiquants/sse/react";
6
- import { D as DailyReportSseTerminalEvent, a as DailyReportSseMessage, U as UIComment, b as DailyReportSseStreamAnchor } from "./ids-stream-BR5RSj5u.js";
6
+ import { D as DailyReportSseTerminalEvent, a as DailyReportSseMessage, U as UIComment } from "./comment-adapter-5bAtR4qb.js";
7
7
  import { ShouldRevalidateFunction } from "react-router";
8
8
  import "zod";
9
9
  type DailyReportAttachmentIndicatorProps = {
@@ -281,6 +281,15 @@ type DailyReportResolvedContentProps = {
281
281
  userId?: string | null;
282
282
  };
283
283
  declare const DailyReportResolvedContent: ({ userId }: DailyReportResolvedContentProps) => react.JSX.Element;
284
+ type ListNavigationHandle = Pick<VirtualScrollHandle, "getViewportSize" | "getScrollPosition" | "getScrollAnchor">;
285
+ type ListScrollToIndexOptions = NonNullable<Parameters<VirtualScrollHandle["scrollToIndex"]>[1]>;
286
+ type ViewTestReadHandle = ListNavigationHandle & Pick<VirtualScrollHandle, "getRange" | "getFenwickSize">;
287
+ type ViewTestHandle = ViewTestReadHandle & {
288
+ readonly findReportIndex: (id: number) => number;
289
+ readonly getReportItem: (index: number) => DailyReportItem | undefined;
290
+ readonly getReportIds: (limit?: number) => number[];
291
+ readonly revealIndex: (index: number, options: ListScrollToIndexOptions) => void;
292
+ };
284
293
  type DailyReportSseConnectionStatus = UseReopeningEventSourceResult<DailyReportSseTerminalEvent>["status"] | {
285
294
  readonly kind: "resyncing";
286
295
  };
@@ -454,4 +463,5 @@ declare const bootstrapDailyReportIdsStreamSession: (options: {
454
463
  declare const primeDailyReportIdsStreamSession: () => void;
455
464
  declare const resyncDailyReportIdsStream: () => void;
456
465
  declare const useDailyReportIdsStream: () => DailyReportIdsStreamState;
457
- export { DAILY_REPORT_LABEL_CATALOGS, DAILY_REPORT_LABEL_KEYS, DailyReportActionProvider, DailyReportAttachmentIndicator, type DailyReportClientConfigDefaults, type DailyReportClientConfigInput, DailyReportConfigProvider, DailyReportDetailList, type DailyReportErrorInfo, DailyReportErrorProvider, DailyReportIdsStreamClient, DailyReportIdsStreamStatus, type DailyReportLabelOverrides, type DailyReportLabels, DailyReportList, type DailyReportLocale, type DailyReportOperation, DailyReportPage, DailyReportResolvedContent, type DailyReportSseConnectionStatus, type SourceTypeConfig, bootstrapDailyReportIdsStreamSession, createDailyReportClientLoader, dailyReportShouldRevalidate, defaultDailyReportClientConfig, ensureDailyReportIdsStreamSession, primeDailyReportIdsStreamSession, resolveDailyReportLabels, resolveSourceTypeConfig, resyncDailyReportIdsStream, useDailyReportActionContext, useDailyReportComments, useDailyReportConfig, useDailyReportDetail, useDailyReportIdsStream, useDailyReportPrefetch, useDailyReportSseConnection };
466
+ declare const DAILY_REPORT_LAYOUT_LATTICE_PX = 4;
467
+ export { DAILY_REPORT_LABEL_CATALOGS, DAILY_REPORT_LABEL_KEYS, DAILY_REPORT_LAYOUT_LATTICE_PX, DailyReportActionProvider, DailyReportAttachmentIndicator, type DailyReportClientConfigDefaults, type DailyReportClientConfigInput, DailyReportConfigProvider, DailyReportDetailList, type DailyReportErrorInfo, DailyReportErrorProvider, DailyReportIdsStreamClient, DailyReportIdsStreamStatus, type DailyReportLabelOverrides, type DailyReportLabels, DailyReportList, type DailyReportLocale, type DailyReportOperation, DailyReportPage, DailyReportResolvedContent, type ListScrollToIndexOptions as DailyReportRevealOptions, type DailyReportSseConnectionStatus, type ViewTestHandle as DailyReportViewTestHandle, type ViewTestReadHandle as DailyReportViewTestReadHandle, type SourceTypeConfig, bootstrapDailyReportIdsStreamSession, createDailyReportClientLoader, dailyReportShouldRevalidate, defaultDailyReportClientConfig, ensureDailyReportIdsStreamSession, primeDailyReportIdsStreamSession, resolveDailyReportLabels, resolveSourceTypeConfig, resyncDailyReportIdsStream, useDailyReportActionContext, useDailyReportComments, useDailyReportConfig, useDailyReportDetail, useDailyReportIdsStream, useDailyReportPrefetch, useDailyReportSseConnection };