@superblocksteam/library 2.0.0-next.6 → 2.0.0-next.61

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 (69) hide show
  1. package/dist/{allPaths-JTh0AvL-.js → allPaths-BBGvblR2.js} +2 -2
  2. package/dist/{allPaths-JTh0AvL-.js.map → allPaths-BBGvblR2.js.map} +1 -1
  3. package/dist/{allPaths-CQicmj05.js → allPaths-BLs3_1JE.js} +2 -2
  4. package/dist/{allPaths-CQicmj05.js.map → allPaths-BLs3_1JE.js.map} +1 -1
  5. package/dist/{allPathsLoader-BzKYsLDE.js → allPathsLoader-D3ybY8Wk.js} +3 -3
  6. package/dist/{allPathsLoader-BzKYsLDE.js.map → allPathsLoader-D3ybY8Wk.js.map} +1 -1
  7. package/dist/{allPathsLoader-DUkr4f2u.js → allPathsLoader-Dggiono4.js} +3 -3
  8. package/dist/{allPathsLoader-DUkr4f2u.js.map → allPathsLoader-Dggiono4.js.map} +1 -1
  9. package/dist/{index-U8MX-8Hu.js → index-DWMz_Ohy.js} +1890 -941
  10. package/dist/{index-U8MX-8Hu.js.map → index-DWMz_Ohy.js.map} +1 -1
  11. package/dist/index.js +2 -2
  12. package/dist/{splitPathsBySizeLoader-D1iVVUla.js → splitPathsBySizeLoader-B-TUNLgR.js} +2 -2
  13. package/dist/{splitPathsBySizeLoader-D1iVVUla.js.map → splitPathsBySizeLoader-B-TUNLgR.js.map} +1 -1
  14. package/dist/{splitPathsBySizeLoader-4uQi8FeZ.js → splitPathsBySizeLoader-DHzX-8rX.js} +2 -2
  15. package/dist/{splitPathsBySizeLoader-4uQi8FeZ.js.map → splitPathsBySizeLoader-DHzX-8rX.js.map} +1 -1
  16. package/dist-types/edit-mode/default-table-data.d.ts +64 -0
  17. package/dist-types/edit-mode/dnd/utils.d.ts +19 -1
  18. package/dist-types/edit-mode/features/operation-store.d.ts +4 -0
  19. package/dist-types/edit-mode/source-update-api.d.ts +2 -1
  20. package/dist-types/lib/internal-details/identifier-normalizer.d.ts +0 -1
  21. package/dist-types/lib/internal-details/lib/evaluator/base-entity-manager.d.ts +3 -2
  22. package/dist-types/lib/internal-details/lib/evaluator/compute-engines.d.ts +2 -1
  23. package/dist-types/lib/internal-details/lib/evaluator/entity-manager.d.ts +8 -0
  24. package/dist-types/lib/internal-details/lib/evaluator/lazy-function.d.ts +1 -1
  25. package/dist-types/lib/internal-details/lib/types.d.ts +3 -0
  26. package/dist-types/lib/internal-details/scope/global.d.ts +1 -0
  27. package/dist-types/lib/user-facing/components/button/props.d.ts +0 -5
  28. package/dist-types/lib/user-facing/components/column/index.d.ts +8 -21
  29. package/dist-types/lib/user-facing/components/column/props.d.ts +20 -33
  30. package/dist-types/lib/user-facing/components/container/index.d.ts +8 -22
  31. package/dist-types/lib/user-facing/components/container/props.d.ts +7 -22
  32. package/dist-types/lib/user-facing/components/date-picker/date-picker-component.d.ts +3 -3
  33. package/dist-types/lib/user-facing/components/date-picker/utils.d.ts +1 -1
  34. package/dist-types/lib/user-facing/components/dropdown/index.d.ts +1 -1
  35. package/dist-types/lib/user-facing/components/dropdown/props.d.ts +1 -1
  36. package/dist-types/lib/user-facing/components/dropdown/types.d.ts +1 -1
  37. package/dist-types/lib/user-facing/components/grid/index.d.ts +8 -8
  38. package/dist-types/lib/user-facing/components/image/index.d.ts +1 -1
  39. package/dist-types/lib/user-facing/components/image/props.d.ts +1 -1
  40. package/dist-types/lib/user-facing/components/input/index.d.ts +5 -11
  41. package/dist-types/lib/user-facing/components/input/props.d.ts +5 -11
  42. package/dist-types/lib/user-facing/components/modal/index.d.ts +8 -13
  43. package/dist-types/lib/user-facing/components/modal/modal-component.d.ts +1 -1
  44. package/dist-types/lib/user-facing/components/modal/props.d.ts +8 -13
  45. package/dist-types/lib/user-facing/components/pixel-input/index.d.ts +7 -0
  46. package/dist-types/lib/user-facing/components/section/index.d.ts +2 -2
  47. package/dist-types/lib/user-facing/components/section/props.d.ts +2 -2
  48. package/dist-types/lib/user-facing/components/stack/index.d.ts +2 -2
  49. package/dist-types/lib/user-facing/components/switch/index.d.ts +1 -1
  50. package/dist-types/lib/user-facing/components/switch/props.d.ts +1 -1
  51. package/dist-types/lib/user-facing/components/table/column-properties-panel.d.ts +45 -40
  52. package/dist-types/lib/user-facing/components/table/components/boolean-value-icons.d.ts +5 -5
  53. package/dist-types/lib/user-facing/components/table/components/table-data-download.d.ts +2 -2
  54. package/dist-types/lib/user-facing/components/table/components/table-footer.d.ts +4 -4
  55. package/dist-types/lib/user-facing/components/table/components/table-pagination.d.ts +3 -3
  56. package/dist-types/lib/user-facing/components/table/derived-properties.d.ts +0 -1
  57. package/dist-types/lib/user-facing/components/table/index.d.ts +55 -51
  58. package/dist-types/lib/user-facing/components/table/props.d.ts +56 -53
  59. package/dist-types/lib/user-facing/components/table/table-component.d.ts +3 -3
  60. package/dist-types/lib/user-facing/components/table/table-styles.d.ts +0 -1
  61. package/dist-types/lib/user-facing/components/table/table-utilities.d.ts +1 -3
  62. package/dist-types/lib/user-facing/components/table/types.d.ts +8 -19
  63. package/dist-types/lib/user-facing/properties-panel/mixins/appearance-properties.d.ts +1 -0
  64. package/dist-types/lib/user-facing/properties-panel/mixins/appearance.d.ts +4 -8
  65. package/dist-types/lib/user-facing/properties-panel/mixins/form-inputs-properties.d.ts +1 -1
  66. package/dist-types/lib/user-facing/properties-panel/mixins/layout-section.d.ts +12 -14
  67. package/dist-types/lib/user-facing/properties-panel/props-builder.d.ts +1 -0
  68. package/dist-types/lib/user-facing/themes/constants.d.ts +2 -0
  69. package/package.json +4 -3
@@ -1,11 +1,7 @@
1
1
  import type { IconPosition } from "../../icons/constants";
2
2
  import type { Dim, DimModes } from "@superblocksteam/library-shared";
3
3
  import type { TextStyleWithVariant, UserAccessibleTheme, PerCornerBorderRadius, PerSideBorder } from "@superblocksteam/library-shared/types";
4
- export declare enum PaginationTypes {
5
- NONE = "NONE",
6
- CLIENT_SIDE = "CLIENT_SIDE",
7
- SERVER_SIDE = "SERVER_SIDE"
8
- }
4
+ export type PaginationType = "none" | "client_side" | "server_side";
9
5
  export interface TableFilters {
10
6
  byColumn?: {
11
7
  [column: string]: ColumnFilter;
@@ -91,12 +87,7 @@ export declare enum EditInputType {
91
87
  Checkbox = "CHECKBOX",
92
88
  Date = "DATE"
93
89
  }
94
- export declare enum BooleanStyleFalse {
95
- EMPTY = "EMPTY",
96
- CLOSE = "CLOSE",
97
- MINUS = "MINUS",
98
- EMPTY_CHECKBOX = "EMPTY_CHECKBOX"
99
- }
90
+ export type BooleanStyleFalse = "empty" | "close" | "minus" | "empty_checkbox";
100
91
  export declare enum ImageSize {
101
92
  Fixed = "FIXED",
102
93
  Fit = "FIT",
@@ -184,7 +175,6 @@ export interface TableStyles {
184
175
  horizontalAlign?: CellAlignment;
185
176
  verticalAlign?: VerticalAlignment;
186
177
  }
187
- export type Pagination = keyof typeof PaginationTypes;
188
178
  type CellAlignment = keyof typeof CellAlignmentTypes;
189
179
  type VerticalAlignment = keyof typeof VerticalAlignmentTypes;
190
180
  type TextSize = keyof typeof TextSizes;
@@ -304,8 +294,8 @@ export interface ColumnProperties extends ColumnEditConfigs, ColumnPropertiesFor
304
294
  imageSize?: ImageSize;
305
295
  imageBorderRadius?: Dim<DimModes>;
306
296
  openImageUrl?: boolean;
307
- outputFormat?: string | string[];
308
- inputFormat?: string | string[];
297
+ outputFormat?: string;
298
+ inputFormat?: string;
309
299
  }
310
300
  export type EditProps = ColumnEditConfigs & {
311
301
  handleEditStart: () => void;
@@ -366,7 +356,7 @@ type ColumnEditConfigs = {
366
356
  export type UnknownRow = Record<string, unknown>;
367
357
  export type UnknownRows = Array<UnknownRow>;
368
358
  export interface TableSortColumn {
369
- column: string;
359
+ column?: string;
370
360
  asc: boolean;
371
361
  }
372
362
  export interface TagsColorAssignment {
@@ -377,11 +367,10 @@ export interface TableWidgetProps extends TableFunctions {
377
367
  sourceId: string;
378
368
  widgetName: string;
379
369
  isLoading: boolean;
380
- defaultSearchText: string;
381
370
  searchPlaceholder: string;
382
371
  pageSize: number;
383
372
  configuredPageSize?: number;
384
- pageType: Pagination;
373
+ paginationType: PaginationType;
385
374
  multiRowSelection?: boolean;
386
375
  columnOrder?: string[];
387
376
  columnSizeMap?: {
@@ -393,9 +382,8 @@ export interface TableWidgetProps extends TableFunctions {
393
382
  isDownloadable: boolean;
394
383
  isFilterable: boolean;
395
384
  showColumnBorders: boolean;
396
- defaultFilters: string;
397
385
  isSearchable: boolean;
398
- tableHeader: string;
386
+ header: string;
399
387
  compactMode: CompactMode;
400
388
  enableRowDeletion: boolean;
401
389
  enableRowInsertion: boolean;
@@ -427,6 +415,7 @@ export interface TableWidgetProps extends TableFunctions {
427
415
  theme: UserAccessibleTheme;
428
416
  border: PerSideBorder;
429
417
  disableNudge: (disable: boolean) => void;
418
+ disableDrag: (disable: boolean) => void;
430
419
  filteredTableData?: UnknownRows;
431
420
  filteredOrderMap?: Array<number>;
432
421
  editedRows?: {
@@ -19,4 +19,5 @@ export declare const textStyleProp: ({ baseProp, propertiesPanel, }?: {
19
19
  baseProp?: ReturnType<typeof createTextStyleCompositeBase>;
20
20
  propertiesPanel?: Omit<Partial<PropertiesPanelDisplay<TextStyleWithVariant, "TEXT_STYLE">>, "controlType">;
21
21
  }) => Prop<TextStyleWithVariant>;
22
+ export declare const colorProp: (schema: Omit<Partial<PropertiesPanelDisplay<string, "COLOR_PICKER">>, "controlType">) => Prop<string, false>;
22
23
  export declare const labelTextStyle: () => Prop<TextStyleWithVariant, true>;
@@ -1,12 +1,8 @@
1
- import { Dim } from "@superblocksteam/library-shared";
2
1
  import { Prop } from "../props-builder.js";
2
+ import type { Dim } from "@superblocksteam/library-shared";
3
3
  import type { PropertiesPanelDisplay } from "@superblocksteam/library-shared/props";
4
- import type { PerCornerBorderRadius, PerSideBorder } from "@superblocksteam/library-shared/types";
5
- export declare const perSideBorderDef: () => import("../props-builder.js").CompositeProp<{
6
- color: Prop<string, false>;
7
- width: Prop<Dim<import("@superblocksteam/library-shared").DimModes>, false>;
8
- style: Prop<string, false>;
9
- }>;
10
- export declare const border: (propertiesPanelConfig?: Partial<Partial<PropertiesPanelDisplay<"unknown", "BORDER_CONTROL">>>) => Prop<PerSideBorder, true>;
4
+ import type { BorderStyleBlock, PerCornerBorderRadius, PerSideBorder } from "@superblocksteam/library-shared/types";
5
+ export declare const createPerSideBorder: (border: BorderStyleBlock) => PerSideBorder;
6
+ export declare const border: (propertiesPanelConfig?: Partial<Partial<PropertiesPanelDisplay<PerSideBorder, "BORDER_CONTROL">>>) => Prop<PerSideBorder, false>;
11
7
  export declare const createBorderRadiusObject: (borderRadius: Dim<"px" | "%">) => PerCornerBorderRadius;
12
8
  export declare const borderRadius: (propertiesPanelConfig?: Partial<Partial<PropertiesPanelDisplay<PerCornerBorderRadius, "BORDER_RADIUS_CONTROL">>>) => Prop<PerCornerBorderRadius, true>;
@@ -8,7 +8,7 @@ export declare const customValidationProperties: {
8
8
  customValidationRule: Prop<string, true>;
9
9
  customErrorMessage: Prop<string, true>;
10
10
  };
11
- export declare const labelPosition: Prop<"left" | "top", true>;
11
+ export declare const labelPosition: () => Prop<"left" | "top", true>;
12
12
  export declare const getTypographyOptions: () => {
13
13
  label: string;
14
14
  value: {
@@ -52,7 +52,7 @@ export declare const spacing: (options?: {
52
52
  spacing: Prop<Dim<"px">, true>;
53
53
  };
54
54
  export declare const padding: (options?: {
55
- default?: Padding;
55
+ default?: Padding | ((this: any) => Padding);
56
56
  } & Partial<PropertiesPanelDisplay<Padding, "PADDING_CONTROL">>) => {
57
57
  padding: Prop<import("@superblocksteam/library-shared/types").Spacing, true>;
58
58
  };
@@ -63,14 +63,9 @@ export declare const getAlignmentProps: <LayoutType extends "vertical" | "horizo
63
63
  verticalAlign: Prop<VerticalAlignment<LayoutType>, true>;
64
64
  horizontalAlign: Prop<HorizontalAlignment<LayoutType>, true>;
65
65
  };
66
- export declare const containerLayout: () => import("../props-builder.js").UnionProp<{
66
+ export declare const containerLayout: (sizeProps?: Record<string, Prop<any, any>>) => import("../props-builder.js").UnionProp<{
67
67
  layout: Prop<ContainerLayout, true>;
68
68
  }, [{
69
- readonly layout: Prop<"freeform", true>;
70
- readonly columns: Prop<number, true>;
71
- readonly rows: Prop<number, false>;
72
- readonly rowSize: Prop<number, false>;
73
- }, {
74
69
  readonly verticalAlign: Prop<"center" | "space-around" | "space-between" | "bottom" | "top", true>;
75
70
  readonly horizontalAlign: Prop<"center" | "left" | "right", true>;
76
71
  readonly layout: Prop<"vertical", true>;
@@ -78,14 +73,11 @@ export declare const containerLayout: () => import("../props-builder.js").UnionP
78
73
  readonly verticalAlign: Prop<"center" | "bottom" | "top", true>;
79
74
  readonly horizontalAlign: Prop<"center" | "space-around" | "space-between" | "left" | "right", true>;
80
75
  readonly layout: Prop<"horizontal", true>;
81
- }], ({
82
- layout: Prop<ContainerLayout, true>;
83
- } & {
84
- readonly layout: Prop<"freeform", true>;
76
+ }, {
85
77
  readonly columns: Prop<number, true>;
86
- readonly rows: Prop<number, false>;
87
- readonly rowSize: Prop<number, false>;
88
- }) | ({
78
+ readonly rowHeight: Prop<Dim<"px">, true>;
79
+ readonly layout: Prop<"freeform", true>;
80
+ }], ({
89
81
  layout: Prop<ContainerLayout, true>;
90
82
  } & {
91
83
  readonly verticalAlign: Prop<"center" | "space-around" | "space-between" | "bottom" | "top", true>;
@@ -97,6 +89,12 @@ export declare const containerLayout: () => import("../props-builder.js").UnionP
97
89
  readonly verticalAlign: Prop<"center" | "bottom" | "top", true>;
98
90
  readonly horizontalAlign: Prop<"center" | "space-around" | "space-between" | "left" | "right", true>;
99
91
  readonly layout: Prop<"horizontal", true>;
92
+ }) | ({
93
+ layout: Prop<ContainerLayout, true>;
94
+ } & {
95
+ readonly columns: Prop<number, true>;
96
+ readonly rowHeight: Prop<Dim<"px">, true>;
97
+ readonly layout: Prop<"freeform", true>;
100
98
  })>;
101
99
  export declare const basicLayout: () => Section<Record<string, Prop<any, any>> & {
102
100
  maxHeight?: Prop<Dim<DimModes>, false> | undefined;
@@ -141,6 +141,7 @@ declare class Prop<Type extends DataType, _HasDefault extends boolean = false> {
141
141
  */
142
142
  protected relations: Relation[][];
143
143
  protected constructor(typeString: DataTypeString, defaultValidator?: ValidateFn<Type | undefined>);
144
+ static unset(): Prop<undefined>;
144
145
  static string<T extends string>(): Prop<T>;
145
146
  static number<T extends number>(): Prop<T>;
146
147
  static boolean<T extends boolean>(): Prop<T>;
@@ -5,6 +5,7 @@ export declare const LIGHT_APP_BG: "#F9FAFB";
5
5
  export declare const DARK_APP_BG = "#131516";
6
6
  export declare const noBorder: (theme: UserAccessibleTheme) => Border;
7
7
  export declare const noBorderOject: (theme: UserAccessibleTheme) => PerSideBorder;
8
+ export declare const onePixelTransparentBorderObject: () => PerSideBorder;
8
9
  export declare const EMPTY_RADIUS: PerCornerBorderRadius;
9
10
  export declare const DEFAULT_SYSTEM_RADIUS: PerCornerBorderRadius;
10
11
  export declare const defaultContainerBorderObject: (theme: UserAccessibleTheme) => PerSideBorder;
@@ -77,4 +78,5 @@ export declare const KEY_VALUE_PADDING: {
77
78
  bottom: Dim<"px">;
78
79
  };
79
80
  export declare const KEY_VALUE_SPACING: Dim<"px">;
81
+ export declare const DEFAULT_GRID_ROW_SIZE = 12;
80
82
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@superblocksteam/library",
3
- "version": "2.0.0-next.6",
3
+ "version": "2.0.0-next.61",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -26,14 +26,15 @@
26
26
  "@dnd-kit/modifiers": "^9.0.0",
27
27
  "@mobx-devtools/tools": "^0.0.4",
28
28
  "@oddbird/css-anchor-positioning": "^0.4.0",
29
+ "@opentelemetry/api": "^1.9.0",
29
30
  "@popperjs/core": "^2.11.7",
30
31
  "@radix-ui/colors": "^3.0.0",
31
32
  "@radix-ui/react-context-menu": "^2.2.2",
32
33
  "@react-hook/resize-observer": "1.2.6",
33
34
  "@superblocksteam/fast-deep-equal": "3.1.4",
34
35
  "@superblocksteam/iso-currency": "2.0.0",
35
- "@superblocksteam/library-shared": "2.0.0-next.6",
36
- "@superblocksteam/shared": "0.9122.0",
36
+ "@superblocksteam/library-shared": "2.0.0-next.61",
37
+ "@superblocksteam/shared": "0.9146.0",
37
38
  "antd": "4.24.15",
38
39
  "apca-w3": "^0.1.9",
39
40
  "clsx": "^2.1.1",