@mittwald/flow-react-components 0.1.0-alpha.380 → 0.1.0-alpha.382

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.
@@ -36,7 +36,7 @@ export declare class List<T> {
36
36
  get visibleSorting(): Sorting<T>[];
37
37
  static useNew<T>(shape: ListShape<T>): List<T>;
38
38
  storeFilterDefaultSettings(): void;
39
- getStoredFilterDefaultSettings(): Record<string, unknown[]> | undefined;
39
+ getStoredFilterDefaultSettings(): Record<string, string[]> | undefined;
40
40
  getStoredViewModeDefaultSetting(): "table" | "list" | undefined;
41
41
  getSorting(id: string): Sorting<T>;
42
42
  clearSorting(): void;
@@ -5,7 +5,7 @@ import { PropertyName, PropertyValueRenderMethod } from '../types';
5
5
  import { FilterValue } from './FilterValue';
6
6
  import { default as z } from 'zod';
7
7
  export declare class Filter<T, TProp extends PropertyName<T>, TMatchValue> {
8
- static readonly settingsStorageSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodUnknown, "many">>>;
8
+ static readonly settingsStorageSchema: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodString, "many">>>;
9
9
  private _values?;
10
10
  private _valuesFromTableState?;
11
11
  readonly list: List<T>;
@@ -17,7 +17,7 @@ export declare class Filter<T, TProp extends PropertyName<T>, TMatchValue> {
17
17
  private onFilterUpdateCallbacks;
18
18
  private readonly defaultSelectedValues?;
19
19
  constructor(list: List<T>, shape: FilterShape<T, TProp, TMatchValue>);
20
- private getStoredDefaultSelectedValues;
20
+ private getStoredSelectedIds;
21
21
  updateInitialState(initialState: InitialTableState): void;
22
22
  updateTableColumnDef(def: ColumnDef<T>): void;
23
23
  private getReactTableFilterFn;
@@ -36,6 +36,7 @@ export declare class Filter<T, TProp extends PropertyName<T>, TMatchValue> {
36
36
  deactivateValue(value: FilterValue): void;
37
37
  hasChanged(): boolean;
38
38
  private getInitialValues;
39
+ private getInitialFilterValues;
39
40
  resetValues(): void;
40
41
  clear(): void;
41
42
  toggleValue(newValue: FilterValue): void;
@@ -2,9 +2,10 @@ import { Filter } from './Filter';
2
2
  export declare class FilterValue {
3
3
  readonly filter: Filter<unknown, string, unknown>;
4
4
  readonly value: unknown;
5
- constructor(filter: Filter<any, any, any>, value: unknown);
5
+ readonly id: string;
6
+ private constructor();
7
+ static create(filter: Filter<any, any, any>, value: unknown): FilterValue;
6
8
  equals(otherValue: FilterValue): boolean;
7
- get id(): string;
8
9
  get isActive(): boolean;
9
10
  render(): import('react').ReactNode;
10
11
  toggle(): void;
@@ -9,5 +9,5 @@ export interface FilterShape<T, TProp extends PropertyName<T>, TMatcherValue> {
9
9
  matcher?: FilterMatcher<T, TProp, TMatcherValue>;
10
10
  values?: readonly TMatcherValue[];
11
11
  name?: string;
12
- defaultSelected?: readonly NonNullable<ItemType<TMatcherValue>>[];
12
+ defaultSelected?: readonly NonNullable<TMatcherValue>[];
13
13
  }
@@ -0,0 +1 @@
1
+ export declare const toArray: <T>(val: T | T[]) => T[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mittwald/flow-react-components",
3
- "version": "0.1.0-alpha.380",
3
+ "version": "0.1.0-alpha.382",
4
4
  "type": "module",
5
5
  "description": "A React implementation of Flow, mittwald’s design system",
6
6
  "homepage": "https://mittwald.github.io/flow",
@@ -425,7 +425,7 @@
425
425
  "@chakra-ui/live-region": "^2.1.0",
426
426
  "@internationalized/date": "^3.6.0",
427
427
  "@internationalized/string-compiler": "^3.2.6",
428
- "@mittwald/react-tunnel": "^0.1.0-alpha.380",
428
+ "@mittwald/react-tunnel": "^0.1.0-alpha.382",
429
429
  "@mittwald/react-use-promise": "^2.6.0",
430
430
  "@react-aria/form": "^3.0.11",
431
431
  "@react-aria/utils": "^3.26.0",
@@ -456,7 +456,7 @@
456
456
  },
457
457
  "devDependencies": {
458
458
  "@faker-js/faker": "^9.2.0",
459
- "@mittwald/flow-design-tokens": "^0.1.0-alpha.380",
459
+ "@mittwald/flow-design-tokens": "^0.1.0-alpha.382",
460
460
  "@mittwald/react-use-promise": "^2.6.0",
461
461
  "@nx/storybook": "^20.1.3",
462
462
  "@storybook/addon-a11y": "^8.4.5",
@@ -551,5 +551,5 @@
551
551
  }
552
552
  }
553
553
  },
554
- "gitHead": "eda0a079a103ae21af4e5c3c467646b62806ae4f"
554
+ "gitHead": "30b1e1fde6995d99d8824361257cec75eda0950d"
555
555
  }