@handamade/psi-react 0.15.0 → 0.17.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.
@@ -20,7 +20,11 @@
20
20
  * standing in for one number is worse than the number. */
21
21
  export declare function paginationRange(page: number, pageCount: number, siblingCount: number): Array<number | "ellipsis">;
22
22
  export interface PaginationProps {
23
- /** Current page, 1-based. */
23
+ /**
24
+ * Current page, 1-based. A value outside `[1, pageCount]` (including
25
+ * non-finite values like `NaN`) is clamped for rendering and logs a
26
+ * `console.warn` in development. `pageCount < 1` renders no page buttons.
27
+ */
24
28
  page: number;
25
29
  /** Total number of pages. */
26
30
  pageCount: number;
@@ -1 +1 @@
1
- {"version":3,"file":"Pagination.d.ts","sourceRoot":"","sources":["../../src/Pagination/Pagination.tsx"],"names":[],"mappings":"AAQA;;;;;;;;;;;;;;;;;;;0DAmB0D;AAC1D,wBAAgB,eAAe,CAC7B,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,GACnB,KAAK,CAAC,MAAM,GAAG,UAAU,CAAC,CAkC5B;AAED,MAAM,WAAW,eAAe;IAC9B,6BAA6B;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,6BAA6B;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB;;;;;;OAMG;IACH,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,+EAA+E;IAC/E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,kEAAkE;IAClE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;2BAE2B;AAC3B,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,SAAS,EACT,YAAY,EACZ,YAAgB,EAChB,YAAY,EAAE,SAAwB,EACtC,SAAS,GACV,EAAE,eAAe,+BA+CjB"}
1
+ {"version":3,"file":"Pagination.d.ts","sourceRoot":"","sources":["../../src/Pagination/Pagination.tsx"],"names":[],"mappings":"AAQA;;;;;;;;;;;;;;;;;;;0DAmB0D;AAC1D,wBAAgB,eAAe,CAC7B,IAAI,EAAE,MAAM,EACZ,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,GACnB,KAAK,CAAC,MAAM,GAAG,UAAU,CAAC,CAkC5B;AAED,MAAM,WAAW,eAAe;IAC9B;;;;OAIG;IACH,IAAI,EAAE,MAAM,CAAC;IACb,6BAA6B;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB;;;;;;OAMG;IACH,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,+EAA+E;IAC/E,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,kEAAkE;IAClE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;2BAE2B;AAC3B,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,SAAS,EACT,YAAY,EACZ,YAAgB,EAChB,YAAY,EAAE,SAAwB,EACtC,SAAS,GACV,EAAE,eAAe,+BA6DjB"}
@@ -15,10 +15,13 @@ export interface TableProps {
15
15
  /** Controlled sort state; `null` when nothing is sorted. */
16
16
  sort?: TableSortState | null;
17
17
  /**
18
- * Called when a header's sort control is activated. Optional in the type
19
- * because `sortable` may be false; a discriminated union expressing the real
20
- * contract does not survive docgen's flat prop extraction, which would strip
21
- * these props from the manifest entirely (D62).
18
+ * Called with the **next** sort state, already toggled — store it as given
19
+ * and do not toggle again. A fresh column arrives `"asc"`; an active `"asc"`
20
+ * column emits `"desc"`; an active `"desc"` column emits `"asc"`.
21
+ *
22
+ * Optional in the type because `sortable` may be false; a discriminated union
23
+ * expressing the real contract does not survive docgen's flat prop
24
+ * extraction, which would strip these props from the manifest entirely (D62).
22
25
  */
23
26
  onSortChange?: (sort: TableSortState) => void;
24
27
  /** Renders the row-selection checkbox column. */
@@ -1 +1 @@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