@xh/hoist 73.0.0-SNAPSHOT.1746476580787 → 73.0.0-SNAPSHOT.1746482507483

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/CHANGELOG.md CHANGED
@@ -4,8 +4,14 @@
4
4
 
5
5
  ### 💥 Breaking Changes (upgrade difficulty: 🟢 TRIVIAL - minor upgrade to Hoist Core)
6
6
 
7
- Requires `hoist-core >= 30.0` with new APIs to support the consolidated Admin Console "Clients" tab
8
- and new properties on `TrackLog`.
7
+ * Requires `hoist-core >= 30.0` with new APIs to support the consolidated Admin Console "Clients"
8
+ tab and new properties on `TrackLog`.
9
+ * Apps with a custom `AppModel` for their admin app that extends `@xh/hoist/admin/AppModel` must
10
+ ensure they call `super.initAsync()` within their override of that lifecycle method, if
11
+ applicable. This did not previously have any effect, but is required now for the superclass to
12
+ initialize a new `ViewManagerModel`.
13
+ * For clarity, [here is where Toolbox makes that call](https://github.com/xh/toolbox/blob/f15a8018ce36c2ae998b45724b48a16320b88e49/client-app/src/admin/AppModel.ts#L12).
14
+
9
15
 
10
16
  ### 🎁 New Features
11
17
 
@@ -32,6 +38,8 @@ and new properties on `TrackLog`.
32
38
 
33
39
  * Corrected `GridGroupSortFn` param types.
34
40
  * Corrected `StoreCountLabelProps` interface.
41
+ * Corrected `textAlign` type in `DateInputProps`, `NumberInputProps` `SearchInputProps` and
42
+ `TextInputProps`.
35
43
 
36
44
  ### ⚙️ Technical
37
45
 
@@ -41,7 +49,7 @@ and new properties on `TrackLog`.
41
49
  * The two versions *should* be the same, but in cases where a browser "restores" a tab and
42
50
  re-inits an app without reloading the code itself, the upgrade check would miss the fact that
43
51
  the client remained on an older version.
44
- * Note that a misconfigured build - where the client build version is not set to the same value
52
+ * ⚠️ NOTE that a misconfigured build - where the client version is not set to the same value
45
53
  as the server - would result in a false positive for an upgrade. The two should always match.
46
54
  * Calls to `Promise.track()` that are rejected with an exception will be tracked with new
47
55
  severity level of `TrackSeverity.ERROR`
@@ -119,6 +127,10 @@ and new properties on `TrackLog`.
119
127
 
120
128
  ### 🎁 New Features
121
129
 
130
+ * Improvements to Grid columns `HeaderFilter` component:
131
+ * `GridFilterModel` `commitOnChage` now set to `false` by default
132
+ * Addition of ability to append terms to active filter **only** when `commitOnChage:false`
133
+ * Column header filtering functionality now similar to Excel on Windows
122
134
  * Introduced a new "JSON Search" feature to the Hoist Admin Console, accessible from the Config,
123
135
  User Preference, and JSON Blob tabs. Supports searching JSON values stored within these objects
124
136
  to filter and match data using JSON Path expressions.
@@ -60,7 +60,10 @@ export interface GridFilterModelConfig {
60
60
  * gridModel's store.
61
61
  */
62
62
  bind?: Store | View;
63
- /** True (default) to update filters immediately after each change made in the column-based filter UI.*/
63
+ /**
64
+ * True to update filters immediately after each change made in the column-based filter UI.
65
+ * Defaults to False.
66
+ */
64
67
  commitOnChange?: boolean;
65
68
  /**
66
69
  * Specifies the fields this model supports for filtering. Should be configs for
@@ -11,6 +11,7 @@ export declare class ValuesTabModel extends HoistModel {
11
11
  pendingValues: any[];
12
12
  /** Bound search term for `StoreFilterField` */
13
13
  filterText: string;
14
+ combineCurrentFilters: boolean;
14
15
  /** FieldFilter output by this model. */
15
16
  get filter(): FieldFilterSpec;
16
17
  get allVisibleRecsChecked(): boolean;
@@ -26,6 +27,7 @@ export declare class ValuesTabModel extends HoistModel {
26
27
  reset(): void;
27
28
  setRecsChecked(isChecked: boolean, values: any[]): void;
28
29
  toggleAllRecsChecked(): void;
30
+ setPendingValues(): void;
29
31
  private getFilter;
30
32
  private doSyncWithFilter;
31
33
  private syncGrid;
@@ -2,10 +2,11 @@ import { PopperBoundary, PopperModifierOverrides } from '@blueprintjs/core';
2
2
  import { TimePickerProps } from '@blueprintjs/datetime';
3
3
  import { ReactDayPickerSingleProps } from '@blueprintjs/datetime2/src/common/reactDayPickerProps';
4
4
  import { HoistInputProps } from '@xh/hoist/cmp/input';
5
- import { HoistProps, HSide, LayoutProps, Some } from '@xh/hoist/core';
5
+ import { HoistProps, LayoutProps, Some } from '@xh/hoist/core';
6
6
  import '@xh/hoist/desktop/register';
7
7
  import { Position } from '@xh/hoist/kit/blueprint';
8
8
  import { LocalDate } from '@xh/hoist/utils/datetime';
9
+ import type { Property } from 'csstype';
9
10
  import { ReactElement, ReactNode } from 'react';
10
11
  import './DateInput.scss';
11
12
  export interface DateInputProps extends HoistProps, LayoutProps, HoistInputProps {
@@ -88,7 +89,7 @@ export interface DateInputProps extends HoistProps, LayoutProps, HoistInputProps
88
89
  */
89
90
  strictInputParsing?: boolean;
90
91
  /** Alignment of entry text within control, default 'left'. */
91
- textAlign?: HSide;
92
+ textAlign?: Property.TextAlign;
92
93
  /**
93
94
  * Props passed to the TimePicker, as per Blueprint docs.
94
95
  * @see https://blueprintjs.com/docs/#datetime/dateinput
@@ -1,7 +1,8 @@
1
1
  import { HoistInputProps } from '@xh/hoist/cmp/input';
2
- import { HoistProps, HSide, LayoutProps, StyleProps } from '@xh/hoist/core';
2
+ import { HoistProps, LayoutProps, StyleProps } from '@xh/hoist/core';
3
3
  import '@xh/hoist/desktop/register';
4
4
  import { NumericPrecision, ZeroPad } from '@xh/hoist/format';
5
+ import type { Property } from 'csstype';
5
6
  import { KeyboardEventHandler, ReactElement, ReactNode, Ref } from 'react';
6
7
  export interface NumberInputProps extends HoistProps, LayoutProps, StyleProps, HoistInputProps {
7
8
  value?: number;
@@ -51,7 +52,7 @@ export interface NumberInputProps extends HoistProps, LayoutProps, StyleProps, H
51
52
  /** Standard step size for increment/decrement handling. */
52
53
  stepSize?: number;
53
54
  /** Alignment of entry text within control, default 'right'. */
54
- textAlign?: HSide;
55
+ textAlign?: Property.TextAlign;
55
56
  /**
56
57
  * Text appended to the rendered value within control when not editing.
57
58
  * Can be used to append e.g. "%" or a unit without need for an external right label.
@@ -1,6 +1,7 @@
1
1
  import { HoistInputModel, HoistInputProps } from '@xh/hoist/cmp/input';
2
- import { HoistProps, HSide, LayoutProps, StyleProps } from '@xh/hoist/core';
2
+ import { HoistProps, LayoutProps, StyleProps } from '@xh/hoist/core';
3
3
  import '@xh/hoist/desktop/register';
4
+ import type { Property } from 'csstype';
4
5
  import { FocusEvent, KeyboardEventHandler, ReactElement, ReactNode, Ref } from 'react';
5
6
  export interface TextInputProps extends HoistProps, HoistInputProps, LayoutProps, StyleProps {
6
7
  value?: string;
@@ -36,7 +37,7 @@ export interface TextInputProps extends HoistProps, HoistInputProps, LayoutProps
36
37
  /** True to select contents when control receives focus. */
37
38
  selectOnFocus?: boolean;
38
39
  /** Alignment of entry text within control, default 'left'. */
39
- textAlign?: HSide;
40
+ textAlign?: Property.TextAlign;
40
41
  /** True to allow browser spell check, default false. */
41
42
  spellCheck?: boolean;
42
43
  /** Underlying HTML <input> element type. */
@@ -1,7 +1,8 @@
1
1
  import { HoistInputProps } from '@xh/hoist/cmp/input';
2
- import { HoistProps, StyleProps, LayoutProps, HSide, PlainObject } from '@xh/hoist/core';
2
+ import { HoistProps, StyleProps, LayoutProps, PlainObject } from '@xh/hoist/core';
3
3
  import '@xh/hoist/mobile/register';
4
4
  import { LocalDate } from '@xh/hoist/utils/datetime';
5
+ import type { Property } from 'csstype';
5
6
  import './DateInput.scss';
6
7
  import { ReactElement } from 'react';
7
8
  export interface DateInputProps extends HoistProps, HoistInputProps, StyleProps, LayoutProps {
@@ -43,7 +44,7 @@ export interface DateInputProps extends HoistProps, HoistInputProps, StyleProps,
43
44
  /** Props passed to SingleDatePicker component, as per SingleDatePicker docs. */
44
45
  singleDatePickerProps?: PlainObject;
45
46
  /** Alignment of entry text within control, default 'left'. */
46
- textAlign?: HSide;
47
+ textAlign?: Property.TextAlign;
47
48
  /** Type of value to publish. Defaults to 'date'. */
48
49
  valueType?: 'date' | 'localDate';
49
50
  }
@@ -1,8 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  import { HoistInputProps } from '@xh/hoist/cmp/input';
3
- import { HoistProps, HSide, LayoutProps, StyleProps } from '@xh/hoist/core';
3
+ import { HoistProps, LayoutProps, StyleProps } from '@xh/hoist/core';
4
4
  import { NumericPrecision, ZeroPad } from '@xh/hoist/format';
5
5
  import '@xh/hoist/mobile/register';
6
+ import type { Property } from 'csstype';
6
7
  import './NumberInput.scss';
7
8
  export interface NumberInputProps extends HoistProps, HoistInputProps, StyleProps, LayoutProps {
8
9
  value?: number;
@@ -38,7 +39,7 @@ export interface NumberInputProps extends HoistProps, HoistInputProps, StyleProp
38
39
  /** True to select contents when control receives focus. */
39
40
  selectOnFocus?: boolean;
40
41
  /** Alignment of entry text within control, default 'right'. */
41
- textAlign?: HSide;
42
+ textAlign?: Property.TextAlign;
42
43
  /**
43
44
  * Text appended to the rendered value within control when not editing.
44
45
  * Can be used to append e.g. "%" or a unit without need for an external right label.
@@ -1,8 +1,9 @@
1
1
  /// <reference types="react" />
2
2
  import { HoistInputProps } from '@xh/hoist/cmp/input';
3
- import { HoistProps, HSide } from '@xh/hoist/core';
3
+ import { HoistProps } from '@xh/hoist/core';
4
4
  import '@xh/hoist/mobile/register';
5
5
  import './SearchInput.scss';
6
+ import type { Property } from 'csstype';
6
7
  export interface SearchInputProps extends HoistProps, HoistInputProps {
7
8
  value?: string;
8
9
  /** True to commit on every change/keystroke, default false. */
@@ -16,7 +17,7 @@ export interface SearchInputProps extends HoistProps, HoistInputProps {
16
17
  /** Whether to allow browser spell check, defaults to false */
17
18
  spellCheck?: boolean;
18
19
  /** Alignment of entry text within control, default 'left'. */
19
- textAlign?: HSide;
20
+ textAlign?: Property.TextAlign;
20
21
  }
21
22
  /**
22
23
  * A Search Input
@@ -1,7 +1,8 @@
1
1
  /// <reference types="react" />
2
2
  import { HoistInputProps } from '@xh/hoist/cmp/input';
3
- import { HoistProps, HSide, LayoutProps, StyleProps } from '@xh/hoist/core';
3
+ import { HoistProps, LayoutProps, StyleProps } from '@xh/hoist/core';
4
4
  import '@xh/hoist/mobile/register';
5
+ import type { Property } from 'csstype';
5
6
  import './TextInput.scss';
6
7
  export interface TextInputProps extends HoistProps, HoistInputProps, StyleProps, LayoutProps {
7
8
  value?: string;
@@ -36,7 +37,7 @@ export interface TextInputProps extends HoistProps, HoistInputProps, StyleProps,
36
37
  /** Whether to allow browser spell check, defaults to false */
37
38
  spellCheck?: boolean;
38
39
  /** Alignment of entry text within control, default 'left'. */
39
- textAlign?: HSide;
40
+ textAlign?: Property.TextAlign;
40
41
  /** Underlying HTML <input> element type. */
41
42
  type?: 'text' | 'password';
42
43
  }
package/cmp/grid/Types.ts CHANGED
@@ -90,7 +90,10 @@ export interface GridFilterModelConfig {
90
90
  */
91
91
  bind?: Store | View;
92
92
 
93
- /** True (default) to update filters immediately after each change made in the column-based filter UI.*/
93
+ /**
94
+ * True to update filters immediately after each change made in the column-based filter UI.
95
+ * Defaults to False.
96
+ */
94
97
  commitOnChange?: boolean;
95
98
 
96
99
  /**
@@ -46,7 +46,7 @@ export class GridFilterModel extends HoistModel {
46
46
  static BLANK_PLACEHOLDER = '[blank]';
47
47
 
48
48
  constructor(
49
- {bind, commitOnChange = true, fieldSpecs, fieldSpecDefaults}: GridFilterModelConfig,
49
+ {bind, commitOnChange = false, fieldSpecs, fieldSpecDefaults}: GridFilterModelConfig,
50
50
  gridModel: GridModel
51
51
  ) {
52
52
  super();
@@ -1,4 +1,17 @@
1
1
  .xh-values-filter-tab {
2
+ .store-filter-header {
3
+ padding: 5px 7px;
4
+ border-bottom: 1px solid var(--xh-grid-header-border-color);
5
+ row-gap: 5px;
6
+ .bp5-control-indicator {
7
+ font-size: 1em;
8
+ }
9
+ span {
10
+ font-size: var(--xh-grid-compact-header-font-size-px);
11
+ color: var(--xh-grid-header-text-color);
12
+ }
13
+ }
14
+
2
15
  &__hidden-values-message {
3
16
  display: flex;
4
17
  padding: var(--xh-pad-half-px);
@@ -5,10 +5,11 @@
5
5
  * Copyright © 2025 Extremely Heavy Industries Inc.
6
6
  */
7
7
  import {grid} from '@xh/hoist/cmp/grid';
8
- import {div, placeholder, vframe} from '@xh/hoist/cmp/layout';
8
+ import {div, hframe, placeholder, span, vbox, vframe} from '@xh/hoist/cmp/layout';
9
9
  import {storeFilterField} from '@xh/hoist/cmp/store';
10
10
  import {hoistCmp, uses} from '@xh/hoist/core';
11
11
  import {button} from '@xh/hoist/desktop/cmp/button';
12
+ import {checkbox} from '@xh/hoist/desktop/cmp/input';
12
13
  import {panel} from '@xh/hoist/desktop/cmp/panel';
13
14
  import {toolbar} from '@xh/hoist/desktop/cmp/toolbar';
14
15
  import {Icon} from '@xh/hoist/icon';
@@ -47,7 +48,33 @@ const tbar = hoistCmp.factory(() => {
47
48
  const body = hoistCmp.factory<ValuesTabModel>(({model}) => {
48
49
  const {isCustomFilter} = model.headerFilterModel;
49
50
  if (isCustomFilter) return customFilterPlaceholder();
50
- return vframe(grid(), hiddenValuesMessage());
51
+ return vframe(storeFilterSelect(), grid(), hiddenValuesMessage());
52
+ });
53
+
54
+ const storeFilterSelect = hoistCmp.factory<ValuesTabModel>(({model}) => {
55
+ const {gridModel, allVisibleRecsChecked, filterText, headerFilterModel} = model,
56
+ {store} = gridModel;
57
+ return vbox({
58
+ className: 'store-filter-header',
59
+ items: [
60
+ hframe(
61
+ checkbox({
62
+ disabled: store.empty,
63
+ displayUnsetState: true,
64
+ value: allVisibleRecsChecked,
65
+ onChange: () => model.toggleAllRecsChecked()
66
+ }),
67
+ span(`(Select All${filterText ? ' Search Results' : ''})`)
68
+ ),
69
+ hframe({
70
+ omit: !filterText || store.empty || headerFilterModel.commitOnChange,
71
+ items: [
72
+ checkbox({bind: 'combineCurrentFilters'}),
73
+ span(`Add current selection to filter`)
74
+ ]
75
+ })
76
+ ]
77
+ });
51
78
  });
52
79
 
53
80
  const customFilterPlaceholder = hoistCmp.factory<ValuesTabModel>(({model}) => {
@@ -10,7 +10,7 @@ import {FieldFilterSpec} from '@xh/hoist/data';
10
10
  import {HeaderFilterModel} from '../HeaderFilterModel';
11
11
  import {checkbox} from '@xh/hoist/desktop/cmp/input';
12
12
  import {action, bindable, computed, makeObservable, observable} from '@xh/hoist/mobx';
13
- import {castArray, difference, isEmpty, partition, uniq, without} from 'lodash';
13
+ import {castArray, difference, flatten, isEmpty, map, partition, uniq, without} from 'lodash';
14
14
 
15
15
  export class ValuesTabModel extends HoistModel {
16
16
  override xhImpl = true;
@@ -26,6 +26,12 @@ export class ValuesTabModel extends HoistModel {
26
26
  /** Bound search term for `StoreFilterField` */
27
27
  @bindable filterText: string = null;
28
28
 
29
+ /*
30
+ * Available only when commit on change is false merge
31
+ * current filter with pendingValues on commit
32
+ */
33
+ @bindable combineCurrentFilters: boolean = false;
34
+
29
35
  /** FieldFilter output by this model. */
30
36
  @computed.struct
31
37
  get filter(): FieldFilterSpec {
@@ -81,11 +87,18 @@ export class ValuesTabModel extends HoistModel {
81
87
  this.headerFilterModel = headerFilterModel;
82
88
  this.gridModel = this.createGridModel();
83
89
 
84
- this.addReaction({
85
- track: () => this.pendingValues,
86
- run: () => this.syncGrid(),
87
- fireImmediately: true
88
- });
90
+ this.addReaction(
91
+ {
92
+ track: () => this.pendingValues,
93
+ run: () => this.syncGrid(),
94
+ fireImmediately: true
95
+ },
96
+ {
97
+ track: () => [this.filterText, this.combineCurrentFilters],
98
+ run: () => this.setPendingValues(),
99
+ debounce: 300
100
+ }
101
+ );
89
102
  }
90
103
 
91
104
  syncWithFilter() {
@@ -115,6 +128,23 @@ export class ValuesTabModel extends HoistModel {
115
128
  //-------------------
116
129
  // Implementation
117
130
  //-------------------
131
+ @action
132
+ setPendingValues() {
133
+ if (!this.filterText) {
134
+ this.doSyncWithFilter();
135
+ this.syncGrid();
136
+ return;
137
+ }
138
+
139
+ const {records} = this.gridModel.store,
140
+ currentFilterValues = flatten(map(this.columnFilters, 'value')),
141
+ values = map(records, it => it.get('value'));
142
+
143
+ this.pendingValues = uniq(
144
+ this.combineCurrentFilters ? [...currentFilterValues, ...values] : values
145
+ );
146
+ }
147
+
118
148
  private getFilter() {
119
149
  const {gridFilterModel, pendingValues, values, valueCount, field} = this,
120
150
  included = pendingValues.map(it => gridFilterModel.fromDisplayValue(it)),
@@ -217,17 +247,10 @@ export class ValuesTabModel extends HoistModel {
217
247
  onRowClicked: ({data: record}) => {
218
248
  this.setRecsChecked(!record.get('isChecked'), record.get('value'));
219
249
  },
250
+ hideHeaders: true,
220
251
  columns: [
221
252
  {
222
253
  field: 'isChecked',
223
- headerName: ({gridModel}) => {
224
- return checkbox({
225
- disabled: gridModel.store.empty,
226
- displayUnsetState: true,
227
- value: this.allVisibleRecsChecked,
228
- onChange: () => this.toggleAllRecsChecked()
229
- });
230
- },
231
254
  width: 28,
232
255
  autosizable: false,
233
256
  pinned: true,
@@ -245,7 +268,6 @@ export class ValuesTabModel extends HoistModel {
245
268
  },
246
269
  {
247
270
  field: 'value',
248
- displayName: '(Select All)',
249
271
  align: 'left',
250
272
  comparator: (v1, v2, sortDir, abs, {defaultComparator}) => {
251
273
  const mul = sortDir === 'desc' ? -1 : 1;
@@ -9,7 +9,7 @@ import {TimePickerProps} from '@blueprintjs/datetime';
9
9
  import {ReactDayPickerSingleProps} from '@blueprintjs/datetime2/src/common/reactDayPickerProps';
10
10
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
11
11
  import {div, hbox} from '@xh/hoist/cmp/layout';
12
- import {hoistCmp, HoistProps, HSide, LayoutProps, Some} from '@xh/hoist/core';
12
+ import {hoistCmp, HoistProps, LayoutProps, Some} from '@xh/hoist/core';
13
13
  import {button} from '@xh/hoist/desktop/cmp/button';
14
14
  import {textInput, TextInputModel} from '@xh/hoist/desktop/cmp/input';
15
15
  import '@xh/hoist/desktop/register';
@@ -22,6 +22,7 @@ import {isLocalDate, LocalDate} from '@xh/hoist/utils/datetime';
22
22
  import {consumeEvent, getTestId, withDefault} from '@xh/hoist/utils/js';
23
23
  import {getLayoutProps} from '@xh/hoist/utils/react';
24
24
  import classNames from 'classnames';
25
+ import type {Property} from 'csstype';
25
26
  import {assign, castArray, clone, isEmpty, trim} from 'lodash';
26
27
  import moment from 'moment';
27
28
  import {createRef, ReactElement, ReactNode} from 'react';
@@ -128,7 +129,7 @@ export interface DateInputProps extends HoistProps, LayoutProps, HoistInputProps
128
129
  strictInputParsing?: boolean;
129
130
 
130
131
  /** Alignment of entry text within control, default 'left'. */
131
- textAlign?: HSide;
132
+ textAlign?: Property.TextAlign;
132
133
 
133
134
  /**
134
135
  * Props passed to the TimePicker, as per Blueprint docs.
@@ -6,13 +6,14 @@
6
6
  */
7
7
  import composeRefs from '@seznam/compose-react-refs';
8
8
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
9
- import {hoistCmp, HoistProps, HSide, LayoutProps, StyleProps} from '@xh/hoist/core';
9
+ import {hoistCmp, HoistProps, LayoutProps, StyleProps} from '@xh/hoist/core';
10
10
  import '@xh/hoist/desktop/register';
11
11
  import {fmtNumber, NumericPrecision, parseNumber, Precision, ZeroPad} from '@xh/hoist/format';
12
12
  import {numericInput} from '@xh/hoist/kit/blueprint';
13
13
  import {wait} from '@xh/hoist/promise';
14
14
  import {TEST_ID, throwIf, withDefault} from '@xh/hoist/utils/js';
15
15
  import {getLayoutProps} from '@xh/hoist/utils/react';
16
+ import type {Property} from 'csstype';
16
17
  import {debounce, isNaN, isNil, isNumber, round} from 'lodash';
17
18
  import {KeyboardEventHandler, ReactElement, ReactNode, Ref, useLayoutEffect} from 'react';
18
19
 
@@ -82,7 +83,7 @@ export interface NumberInputProps extends HoistProps, LayoutProps, StyleProps, H
82
83
  stepSize?: number;
83
84
 
84
85
  /** Alignment of entry text within control, default 'right'. */
85
- textAlign?: HSide;
86
+ textAlign?: Property.TextAlign;
86
87
 
87
88
  /**
88
89
  * Text appended to the rendered value within control when not editing.
@@ -7,13 +7,14 @@
7
7
  import composeRefs from '@seznam/compose-react-refs';
8
8
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
9
9
  import {div} from '@xh/hoist/cmp/layout';
10
- import {hoistCmp, HoistProps, HSide, LayoutProps, StyleProps} from '@xh/hoist/core';
10
+ import {hoistCmp, HoistProps, LayoutProps, StyleProps} from '@xh/hoist/core';
11
11
  import {button} from '@xh/hoist/desktop/cmp/button';
12
12
  import '@xh/hoist/desktop/register';
13
13
  import {Icon} from '@xh/hoist/icon';
14
14
  import {inputGroup} from '@xh/hoist/kit/blueprint';
15
15
  import {getTestId, TEST_ID, withDefault} from '@xh/hoist/utils/js';
16
16
  import {getLayoutProps} from '@xh/hoist/utils/react';
17
+ import type {Property} from 'csstype';
17
18
  import {isEmpty} from 'lodash';
18
19
  import {FocusEvent, KeyboardEventHandler, ReactElement, ReactNode, Ref} from 'react';
19
20
 
@@ -63,7 +64,7 @@ export interface TextInputProps extends HoistProps, HoistInputProps, LayoutProps
63
64
  selectOnFocus?: boolean;
64
65
 
65
66
  /** Alignment of entry text within control, default 'left'. */
66
- textAlign?: HSide;
67
+ textAlign?: Property.TextAlign;
67
68
 
68
69
  /** True to allow browser spell check, default false. */
69
70
  spellCheck?: boolean;
@@ -6,7 +6,7 @@
6
6
  */
7
7
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
8
8
  import {div} from '@xh/hoist/cmp/layout';
9
- import {hoistCmp, HoistProps, StyleProps, LayoutProps, HSide, PlainObject} from '@xh/hoist/core';
9
+ import {hoistCmp, HoistProps, StyleProps, LayoutProps, PlainObject} from '@xh/hoist/core';
10
10
  import {fmtDate} from '@xh/hoist/format';
11
11
  import {Icon} from '@xh/hoist/icon';
12
12
  import {singleDatePicker} from '@xh/hoist/kit/react-dates';
@@ -15,6 +15,7 @@ import {action, makeObservable, observable} from '@xh/hoist/mobx';
15
15
  import {isLocalDate, LocalDate} from '@xh/hoist/utils/datetime';
16
16
  import {withDefault} from '@xh/hoist/utils/js';
17
17
  import {getLayoutProps} from '@xh/hoist/utils/react';
18
+ import type {Property} from 'csstype';
18
19
  import moment from 'moment';
19
20
  import './DateInput.scss';
20
21
  import {ReactElement} from 'react';
@@ -68,7 +69,7 @@ export interface DateInputProps extends HoistProps, HoistInputProps, StyleProps,
68
69
  singleDatePickerProps?: PlainObject;
69
70
 
70
71
  /** Alignment of entry text within control, default 'left'. */
71
- textAlign?: HSide;
72
+ textAlign?: Property.TextAlign;
72
73
 
73
74
  /** Type of value to publish. Defaults to 'date'. */
74
75
  valueType?: 'date' | 'localDate';
@@ -5,13 +5,14 @@
5
5
  * Copyright © 2025 Extremely Heavy Industries Inc.
6
6
  */
7
7
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
8
- import {hoistCmp, HoistProps, HSide, LayoutProps, StyleProps} from '@xh/hoist/core';
8
+ import {hoistCmp, HoistProps, LayoutProps, StyleProps} from '@xh/hoist/core';
9
9
  import {fmtNumber, NumericPrecision, Precision, ZeroPad} from '@xh/hoist/format';
10
10
  import {input} from '@xh/hoist/kit/onsen';
11
11
  import '@xh/hoist/mobile/register';
12
12
  import {wait} from '@xh/hoist/promise';
13
13
  import {throwIf, withDefault} from '@xh/hoist/utils/js';
14
14
  import {getLayoutProps} from '@xh/hoist/utils/react';
15
+ import type {Property} from 'csstype';
15
16
  import {debounce, isNaN, isNil, isNumber, round} from 'lodash';
16
17
  import './NumberInput.scss';
17
18
 
@@ -60,7 +61,7 @@ export interface NumberInputProps extends HoistProps, HoistInputProps, StyleProp
60
61
  selectOnFocus?: boolean;
61
62
 
62
63
  /** Alignment of entry text within control, default 'right'. */
63
- textAlign?: HSide;
64
+ textAlign?: Property.TextAlign;
64
65
 
65
66
  /**
66
67
  * Text appended to the rendered value within control when not editing.
@@ -5,12 +5,13 @@
5
5
  * Copyright © 2025 Extremely Heavy Industries Inc.
6
6
  */
7
7
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
8
- import {hoistCmp, HoistProps, HSide} from '@xh/hoist/core';
8
+ import {hoistCmp, HoistProps} from '@xh/hoist/core';
9
9
  import {searchInput as onsenSearchInput} from '@xh/hoist/kit/onsen';
10
10
  import '@xh/hoist/mobile/register';
11
11
  import {withDefault} from '@xh/hoist/utils/js';
12
12
  import {getLayoutProps} from '@xh/hoist/utils/react';
13
13
  import './SearchInput.scss';
14
+ import type {Property} from 'csstype';
14
15
 
15
16
  export interface SearchInputProps extends HoistProps, HoistInputProps {
16
17
  value?: string;
@@ -31,7 +32,7 @@ export interface SearchInputProps extends HoistProps, HoistInputProps {
31
32
  spellCheck?: boolean;
32
33
 
33
34
  /** Alignment of entry text within control, default 'left'. */
34
- textAlign?: HSide;
35
+ textAlign?: Property.TextAlign;
35
36
  }
36
37
 
37
38
  /**
@@ -6,13 +6,14 @@
6
6
  */
7
7
  import {HoistInputModel, HoistInputProps, useHoistInputModel} from '@xh/hoist/cmp/input';
8
8
  import {hbox} from '@xh/hoist/cmp/layout';
9
- import {hoistCmp, HoistProps, HSide, LayoutProps, StyleProps} from '@xh/hoist/core';
9
+ import {hoistCmp, HoistProps, LayoutProps, StyleProps} from '@xh/hoist/core';
10
10
  import {Icon} from '@xh/hoist/icon';
11
11
  import {input} from '@xh/hoist/kit/onsen';
12
12
  import {button} from '@xh/hoist/mobile/cmp/button';
13
13
  import '@xh/hoist/mobile/register';
14
14
  import {withDefault} from '@xh/hoist/utils/js';
15
15
  import {getLayoutProps} from '@xh/hoist/utils/react';
16
+ import type {Property} from 'csstype';
16
17
  import {isEmpty} from 'lodash';
17
18
  import './TextInput.scss';
18
19
 
@@ -58,7 +59,7 @@ export interface TextInputProps extends HoistProps, HoistInputProps, StyleProps,
58
59
  spellCheck?: boolean;
59
60
 
60
61
  /** Alignment of entry text within control, default 'left'. */
61
- textAlign?: HSide;
62
+ textAlign?: Property.TextAlign;
62
63
 
63
64
  /** Underlying HTML <input> element type. */
64
65
  type?: 'text' | 'password';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xh/hoist",
3
- "version": "73.0.0-SNAPSHOT.1746476580787",
3
+ "version": "73.0.0-SNAPSHOT.1746482507483",
4
4
  "description": "Hoist add-on for building and deploying React Applications.",
5
5
  "repository": "github:xh/hoist-react",
6
6
  "homepage": "https://xh.io",