@vitrosoftware/common-ui-ts 1.0.4 → 1.0.5

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.
@@ -16,4 +16,6 @@ export interface TableViewProps {
16
16
  layout?: any;
17
17
  data?: any;
18
18
  filterOneLevel?: boolean;
19
+ cache?: number;
20
+ cacheVersion?: number | string;
19
21
  }
@@ -12,3 +12,6 @@ export declare enum TABLE_VIEW_URL {
12
12
  export declare enum TABLE_VIEW_CONTROLLER {
13
13
  REQUEST = "TableViewRequest"
14
14
  }
15
+ export declare enum TABLE_VIEW_CACHE {
16
+ DEFAULT = 2
17
+ }
@@ -1,8 +1,5 @@
1
1
  /// <reference types="react" />
2
2
  import { TableViewProps } from './TableView';
3
- import { TableViewContext } from './TableViewContext';
4
- export declare const tableViewList: Map<string, TableViewContext>;
5
- export declare function getTableViewById(id: string): TableViewContext | undefined;
6
3
  export declare const TreeGrid: (props: TableViewProps) => JSX.Element;
7
4
  declare global {
8
5
  namespace JSX {
@@ -2,6 +2,8 @@ import { TableViewContext } from './TableViewContext';
2
2
  import { TableViewRow } from './TableViewRow';
3
3
  import { TableViewCol } from './TableViewCol';
4
4
  import { TableViewEventHandler } from './TableViewEventHandler';
5
+ export declare const tableViewList: Map<string, TableViewContext>;
6
+ export declare function getTableViewById(id: string): TableViewContext | undefined;
5
7
  export declare class TreeGridTableViewContextImpl implements TableViewContext {
6
8
  private grid;
7
9
  readonly id: string;
package/dist/index.js CHANGED
@@ -26399,6 +26399,10 @@ var TABLE_VIEW_CONTROLLER;
26399
26399
  (function (TABLE_VIEW_CONTROLLER) {
26400
26400
  TABLE_VIEW_CONTROLLER["REQUEST"] = "TableViewRequest";
26401
26401
  })(TABLE_VIEW_CONTROLLER || (TABLE_VIEW_CONTROLLER = {}));
26402
+ var TABLE_VIEW_CACHE;
26403
+ (function (TABLE_VIEW_CACHE) {
26404
+ TABLE_VIEW_CACHE[TABLE_VIEW_CACHE["DEFAULT"] = 2] = "DEFAULT";
26405
+ })(TABLE_VIEW_CACHE || (TABLE_VIEW_CACHE = {}));
26402
26406
 
26403
26407
  function _defineProperties(target, props) {
26404
26408
  for (var i = 0; i < props.length; i++) {
@@ -26433,6 +26437,13 @@ function _toPropertyKey(arg) {
26433
26437
  }
26434
26438
 
26435
26439
  var w$2 = window;
26440
+ if (!w$2.tableViewList) {
26441
+ w$2.tableViewList = new Map();
26442
+ }
26443
+ var tableViewList = w$2.tableViewList;
26444
+ function getTableViewById(id) {
26445
+ return tableViewList.get(id);
26446
+ }
26436
26447
  var TreeGridTableViewContextImpl = /*#__PURE__*/function () {
26437
26448
  function TreeGridTableViewContextImpl(grid) {
26438
26449
  this.suggestValue = '';
@@ -26620,10 +26631,6 @@ var w$3 = window;
26620
26631
  if (!w$3.tableViewList) {
26621
26632
  w$3.tableViewList = new Map();
26622
26633
  }
26623
- var tableViewList = w$3.tableViewList;
26624
- function getTableViewById(id) {
26625
- return tableViewList.get(id);
26626
- }
26627
26634
  var TreeGrid = function TreeGrid(props) {
26628
26635
  var disposeTableViewById = function disposeTableViewById(gridId) {
26629
26636
  if (gridId && w$3.Grids) {
@@ -26705,7 +26712,9 @@ var TreeGrid = function TreeGrid(props) {
26705
26712
  Text: {
26706
26713
  Url: props.textUrl || TABLE_VIEW_URL.TREEGRID_TEXT
26707
26714
  },
26708
- Debug: props.debug || ''
26715
+ Debug: props.debug || '',
26716
+ Cache: props.cache || TABLE_VIEW_CACHE.DEFAULT,
26717
+ CacheVersion: props.cacheVersion
26709
26718
  }, "vitro-table-view" + props.id);
26710
26719
  } else {
26711
26720
  w$3.TreeGrid({
@@ -26722,7 +26731,9 @@ var TreeGrid = function TreeGrid(props) {
26722
26731
  Text: {
26723
26732
  Url: props.textUrl || TABLE_VIEW_URL.TREEGRID_TEXT
26724
26733
  },
26725
- Debug: props.debug || ''
26734
+ Debug: props.debug || '',
26735
+ Cache: props.cache || TABLE_VIEW_CACHE.DEFAULT,
26736
+ CacheVersion: props.cacheVersion
26726
26737
  }, "vitro-table-view" + props.id);
26727
26738
  }
26728
26739
  return function () {