@sankhyalabs/ezui 7.2.0-dev.1 → 7.2.0-dev.2
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/dist/cjs/ez-grid.cjs.entry.js +42 -6
- package/dist/cjs/ez-popup.cjs.entry.js +0 -1
- package/dist/cjs/ez-sortable-list.cjs.entry.js +97 -112
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js +20 -6
- package/dist/collection/components/ez-grid/controller/ag-grid/gridColumnDefaultWidths.js +23 -0
- package/dist/collection/components/ez-grid/utils/index.js +1 -0
- package/dist/collection/components/ez-popup/ez-popup.js +0 -1
- package/dist/custom-elements/index.js +138 -118
- package/dist/esm/ez-grid.entry.js +42 -6
- package/dist/esm/ez-popup.entry.js +0 -1
- package/dist/esm/ez-sortable-list.entry.js +97 -112
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-5a74d132.entry.js → p-bea06aae.entry.js} +1 -1
- package/dist/ezui/p-bf2a7f94.entry.js +7 -0
- package/dist/ezui/p-f969b65d.entry.js +1 -0
- package/dist/types/components/ez-grid/controller/ag-grid/AgGridController.d.ts +2 -0
- package/dist/types/components/ez-grid/controller/ag-grid/gridColumnDefaultWidths.d.ts +4 -0
- package/dist/types/components/ez-grid/utils/index.d.ts +1 -0
- package/package.json +1 -1
- package/dist/ezui/p-b8078832.entry.js +0 -1
- package/dist/ezui/p-ce0a0036.entry.js +0 -7
|
@@ -79782,6 +79782,29 @@ function resolveAggFunc(aggFunc) {
|
|
|
79782
79782
|
return fn;
|
|
79783
79783
|
}
|
|
79784
79784
|
|
|
79785
|
+
/**
|
|
79786
|
+
* Larguras padrão das colunas do grid por tipo de UserInterface
|
|
79787
|
+
*/
|
|
79788
|
+
const GRID_COLUMN_DEFAULT_WIDTHS = {
|
|
79789
|
+
[UserInterface.SEARCH]: 200,
|
|
79790
|
+
[UserInterface.SEARCHPLUS]: 100,
|
|
79791
|
+
[UserInterface.DATE]: 120,
|
|
79792
|
+
[UserInterface.DATETIME]: 160,
|
|
79793
|
+
[UserInterface.TIME]: 100,
|
|
79794
|
+
[UserInterface.ELAPSEDTIME]: 100,
|
|
79795
|
+
[UserInterface.DECIMALNUMBER]: 130,
|
|
79796
|
+
[UserInterface.INTEGERNUMBER]: 120,
|
|
79797
|
+
[UserInterface.SWITCH]: 80,
|
|
79798
|
+
[UserInterface.FILE]: 100,
|
|
79799
|
+
[UserInterface.HTML]: 200,
|
|
79800
|
+
[UserInterface.LONGTEXT]: 200,
|
|
79801
|
+
[UserInterface.CHECKBOX]: 80,
|
|
79802
|
+
[UserInterface.OPTIONSELECTOR]: 100,
|
|
79803
|
+
[UserInterface.SHORTTEXT]: 200,
|
|
79804
|
+
[UserInterface.PASSWORD]: 100,
|
|
79805
|
+
[UserInterface.MASKEDTEXT]: 100,
|
|
79806
|
+
};
|
|
79807
|
+
|
|
79785
79808
|
class AgGridController {
|
|
79786
79809
|
configFilterColumn(filterColumn) {
|
|
79787
79810
|
this._filterColumn = filterColumn;
|
|
@@ -79810,10 +79833,10 @@ class AgGridController {
|
|
|
79810
79833
|
this.COLUMN_FOOTER_OPER = 'gridFooterOper';
|
|
79811
79834
|
this.RECORD_ARCHIVE_COL_ID = '__RECORD_ARCHIVE__';
|
|
79812
79835
|
this.BLOCK_LOAD_DEBOUNCE = 100;
|
|
79813
|
-
this.DEFAULT_FONT_SIZE =
|
|
79836
|
+
this.DEFAULT_FONT_SIZE = 8;
|
|
79814
79837
|
this.DEFAULT_FONT_SIZE_HTML5 = 32;
|
|
79815
|
-
this.DEFAULT_ICON_SIZE =
|
|
79816
|
-
this.DEFAULT_MAX_SIZE =
|
|
79838
|
+
this.DEFAULT_ICON_SIZE = 40;
|
|
79839
|
+
this.DEFAULT_MAX_SIZE = 300;
|
|
79817
79840
|
this._menuItems = [];
|
|
79818
79841
|
this._idAttribName = '__record__id__';
|
|
79819
79842
|
this._gridConfig = [];
|
|
@@ -80799,9 +80822,11 @@ class AgGridController {
|
|
|
80799
80822
|
tooltip = this._i18n('ez-grid.columnCantBeOrder');
|
|
80800
80823
|
}
|
|
80801
80824
|
const presentationFrom = (_d = source === null || source === void 0 ? void 0 : source.props) === null || _d === void 0 ? void 0 : _d.get(PRESENTATION_FROM_COL_PROP_NAME);
|
|
80825
|
+
const initialWidth = this.getInitialColumnWidth(source.userInterface, source.label);
|
|
80802
80826
|
return this._editionManager.configureColumn({
|
|
80803
80827
|
headerName: source.label,
|
|
80804
80828
|
field: source.name,
|
|
80829
|
+
width: initialWidth,
|
|
80805
80830
|
aggFunc: this.getAggFunc(source),
|
|
80806
80831
|
sortable: propSortable,
|
|
80807
80832
|
resizable: true,
|
|
@@ -81147,10 +81172,21 @@ class AgGridController {
|
|
|
81147
81172
|
}
|
|
81148
81173
|
const field = (_a = this._dataUnit) === null || _a === void 0 ? void 0 : _a.getField(cfgColumn.name);
|
|
81149
81174
|
const label = (_b = field === null || field === void 0 ? void 0 : field.label) !== null && _b !== void 0 ? _b : (_f = (_e = (_d = (_c = this._gridOptions) === null || _c === void 0 ? void 0 : _c.columnApi) === null || _d === void 0 ? void 0 : _d.getColumn(cfgColumn.name)) === null || _e === void 0 ? void 0 : _e.getColDef()) === null || _f === void 0 ? void 0 : _f.headerName;
|
|
81150
|
-
|
|
81151
|
-
|
|
81175
|
+
return this.getInitialColumnWidth(field === null || field === void 0 ? void 0 : field.userInterface, label);
|
|
81176
|
+
}
|
|
81177
|
+
getInitialColumnWidth(userInterface, label) {
|
|
81178
|
+
const columnWidthByLabel = this.getColumnWidthByLabel(label);
|
|
81179
|
+
const defaultWidth = this.getDefaultWidthByUserInterface(userInterface);
|
|
81180
|
+
if (!defaultWidth) {
|
|
81181
|
+
return columnWidthByLabel;
|
|
81182
|
+
}
|
|
81183
|
+
return Math.max(defaultWidth, columnWidthByLabel);
|
|
81184
|
+
}
|
|
81185
|
+
getDefaultWidthByUserInterface(userInterface) {
|
|
81186
|
+
if (!userInterface) {
|
|
81187
|
+
return undefined;
|
|
81152
81188
|
}
|
|
81153
|
-
return
|
|
81189
|
+
return GRID_COLUMN_DEFAULT_WIDTHS[userInterface];
|
|
81154
81190
|
}
|
|
81155
81191
|
getColumnWidthByLabel(label) {
|
|
81156
81192
|
const labelSize = ((label === null || label === void 0 ? void 0 : label.length) || 0) * this.DEFAULT_FONT_SIZE + this.DEFAULT_ICON_SIZE;
|
|
@@ -86094,7 +86130,6 @@ const EzPopup$1 = class extends HTMLElement$1 {
|
|
|
86094
86130
|
}
|
|
86095
86131
|
componentDidRender() {
|
|
86096
86132
|
this.manageOverlay();
|
|
86097
|
-
this.popUpFocus();
|
|
86098
86133
|
}
|
|
86099
86134
|
handleAutoClose(event) {
|
|
86100
86135
|
if (!this.opened || !this._popupRef || !this.autoClose) {
|
|
@@ -88442,136 +88477,118 @@ const EzSkeleton$1 = class extends HTMLElement$1 {
|
|
|
88442
88477
|
};
|
|
88443
88478
|
|
|
88444
88479
|
/**!
|
|
88445
|
-
* Sortable 1.15.
|
|
88480
|
+
* Sortable 1.15.7
|
|
88446
88481
|
* @author RubaXa <trash@rubaxa.org>
|
|
88447
88482
|
* @author owenm <owen23355@gmail.com>
|
|
88448
88483
|
* @license MIT
|
|
88449
88484
|
*/
|
|
88450
|
-
function
|
|
88451
|
-
|
|
88452
|
-
|
|
88453
|
-
|
|
88454
|
-
if (enumerableOnly) {
|
|
88455
|
-
symbols = symbols.filter(function (sym) {
|
|
88456
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
88457
|
-
});
|
|
88458
|
-
}
|
|
88459
|
-
keys.push.apply(keys, symbols);
|
|
88460
|
-
}
|
|
88461
|
-
return keys;
|
|
88462
|
-
}
|
|
88463
|
-
function _objectSpread2(target) {
|
|
88464
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
88465
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
88466
|
-
if (i % 2) {
|
|
88467
|
-
ownKeys(Object(source), true).forEach(function (key) {
|
|
88468
|
-
_defineProperty(target, key, source[key]);
|
|
88469
|
-
});
|
|
88470
|
-
} else if (Object.getOwnPropertyDescriptors) {
|
|
88471
|
-
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
88472
|
-
} else {
|
|
88473
|
-
ownKeys(Object(source)).forEach(function (key) {
|
|
88474
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
88475
|
-
});
|
|
88476
|
-
}
|
|
88477
|
-
}
|
|
88478
|
-
return target;
|
|
88485
|
+
function _arrayLikeToArray(r, a) {
|
|
88486
|
+
(null == a || a > r.length) && (a = r.length);
|
|
88487
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
88488
|
+
return n;
|
|
88479
88489
|
}
|
|
88480
|
-
function
|
|
88481
|
-
|
|
88482
|
-
|
|
88483
|
-
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
|
88484
|
-
_typeof = function (obj) {
|
|
88485
|
-
return typeof obj;
|
|
88486
|
-
};
|
|
88487
|
-
} else {
|
|
88488
|
-
_typeof = function (obj) {
|
|
88489
|
-
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
88490
|
-
};
|
|
88491
|
-
}
|
|
88492
|
-
return _typeof(obj);
|
|
88490
|
+
function _arrayWithoutHoles(r) {
|
|
88491
|
+
if (Array.isArray(r)) return _arrayLikeToArray(r);
|
|
88493
88492
|
}
|
|
88494
|
-
function _defineProperty(
|
|
88495
|
-
|
|
88496
|
-
|
|
88497
|
-
|
|
88498
|
-
|
|
88499
|
-
|
|
88500
|
-
|
|
88501
|
-
});
|
|
88502
|
-
} else {
|
|
88503
|
-
obj[key] = value;
|
|
88504
|
-
}
|
|
88505
|
-
return obj;
|
|
88493
|
+
function _defineProperty(e, r, t) {
|
|
88494
|
+
return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
88495
|
+
value: t,
|
|
88496
|
+
enumerable: !0,
|
|
88497
|
+
configurable: !0,
|
|
88498
|
+
writable: !0
|
|
88499
|
+
}) : e[r] = t, e;
|
|
88506
88500
|
}
|
|
88507
88501
|
function _extends() {
|
|
88508
|
-
_extends = Object.assign
|
|
88509
|
-
for (var
|
|
88510
|
-
var
|
|
88511
|
-
for (var
|
|
88512
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
88513
|
-
target[key] = source[key];
|
|
88514
|
-
}
|
|
88515
|
-
}
|
|
88502
|
+
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
88503
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
88504
|
+
var t = arguments[e];
|
|
88505
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
88516
88506
|
}
|
|
88517
|
-
return
|
|
88518
|
-
};
|
|
88519
|
-
|
|
88507
|
+
return n;
|
|
88508
|
+
}, _extends.apply(null, arguments);
|
|
88509
|
+
}
|
|
88510
|
+
function _iterableToArray(r) {
|
|
88511
|
+
if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r);
|
|
88520
88512
|
}
|
|
88521
|
-
function
|
|
88522
|
-
|
|
88523
|
-
|
|
88524
|
-
|
|
88525
|
-
var
|
|
88526
|
-
|
|
88527
|
-
|
|
88528
|
-
|
|
88529
|
-
|
|
88513
|
+
function _nonIterableSpread() {
|
|
88514
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
88515
|
+
}
|
|
88516
|
+
function ownKeys(e, r) {
|
|
88517
|
+
var t = Object.keys(e);
|
|
88518
|
+
if (Object.getOwnPropertySymbols) {
|
|
88519
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
88520
|
+
r && (o = o.filter(function (r) {
|
|
88521
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
88522
|
+
})), t.push.apply(t, o);
|
|
88530
88523
|
}
|
|
88531
|
-
return
|
|
88524
|
+
return t;
|
|
88525
|
+
}
|
|
88526
|
+
function _objectSpread2(e) {
|
|
88527
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
88528
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
88529
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
|
|
88530
|
+
_defineProperty(e, r, t[r]);
|
|
88531
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
|
|
88532
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
88533
|
+
});
|
|
88534
|
+
}
|
|
88535
|
+
return e;
|
|
88532
88536
|
}
|
|
88533
|
-
function _objectWithoutProperties(
|
|
88534
|
-
if (
|
|
88535
|
-
var
|
|
88536
|
-
|
|
88537
|
+
function _objectWithoutProperties(e, t) {
|
|
88538
|
+
if (null == e) return {};
|
|
88539
|
+
var o,
|
|
88540
|
+
r,
|
|
88541
|
+
i = _objectWithoutPropertiesLoose(e, t);
|
|
88537
88542
|
if (Object.getOwnPropertySymbols) {
|
|
88538
|
-
var
|
|
88539
|
-
for (
|
|
88540
|
-
key = sourceSymbolKeys[i];
|
|
88541
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
88542
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
|
88543
|
-
target[key] = source[key];
|
|
88544
|
-
}
|
|
88543
|
+
var n = Object.getOwnPropertySymbols(e);
|
|
88544
|
+
for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
88545
88545
|
}
|
|
88546
|
-
return
|
|
88546
|
+
return i;
|
|
88547
88547
|
}
|
|
88548
|
-
function
|
|
88549
|
-
|
|
88548
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
88549
|
+
if (null == r) return {};
|
|
88550
|
+
var t = {};
|
|
88551
|
+
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
88552
|
+
if (-1 !== e.indexOf(n)) continue;
|
|
88553
|
+
t[n] = r[n];
|
|
88554
|
+
}
|
|
88555
|
+
return t;
|
|
88550
88556
|
}
|
|
88551
|
-
function
|
|
88552
|
-
|
|
88557
|
+
function _toConsumableArray(r) {
|
|
88558
|
+
return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread();
|
|
88553
88559
|
}
|
|
88554
|
-
function
|
|
88555
|
-
if (
|
|
88560
|
+
function _toPrimitive(t, r) {
|
|
88561
|
+
if ("object" != typeof t || !t) return t;
|
|
88562
|
+
var e = t[Symbol.toPrimitive];
|
|
88563
|
+
if (void 0 !== e) {
|
|
88564
|
+
var i = e.call(t, r || "default");
|
|
88565
|
+
if ("object" != typeof i) return i;
|
|
88566
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
88567
|
+
}
|
|
88568
|
+
return ("string" === r ? String : Number)(t);
|
|
88556
88569
|
}
|
|
88557
|
-
function
|
|
88558
|
-
|
|
88559
|
-
|
|
88560
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
88561
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
88562
|
-
if (n === "Map" || n === "Set") return Array.from(o);
|
|
88563
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
88570
|
+
function _toPropertyKey(t) {
|
|
88571
|
+
var i = _toPrimitive(t, "string");
|
|
88572
|
+
return "symbol" == typeof i ? i : i + "";
|
|
88564
88573
|
}
|
|
88565
|
-
function
|
|
88566
|
-
|
|
88567
|
-
|
|
88568
|
-
return
|
|
88574
|
+
function _typeof(o) {
|
|
88575
|
+
"@babel/helpers - typeof";
|
|
88576
|
+
|
|
88577
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
|
|
88578
|
+
return typeof o;
|
|
88579
|
+
} : function (o) {
|
|
88580
|
+
return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
|
|
88581
|
+
}, _typeof(o);
|
|
88569
88582
|
}
|
|
88570
|
-
function
|
|
88571
|
-
|
|
88583
|
+
function _unsupportedIterableToArray(r, a) {
|
|
88584
|
+
if (r) {
|
|
88585
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
88586
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
88587
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
88588
|
+
}
|
|
88572
88589
|
}
|
|
88573
88590
|
|
|
88574
|
-
var version = "1.15.
|
|
88591
|
+
var version = "1.15.7";
|
|
88575
88592
|
|
|
88576
88593
|
function userAgent(pattern) {
|
|
88577
88594
|
if (typeof window !== 'undefined' && window.navigator) {
|
|
@@ -88614,7 +88631,7 @@ function matches( /**HTMLElement*/el, /**String*/selector) {
|
|
|
88614
88631
|
return false;
|
|
88615
88632
|
}
|
|
88616
88633
|
function getParentOrHost(el) {
|
|
88617
|
-
return el.host && el !== document && el.host.nodeType ? el.host : el.parentNode;
|
|
88634
|
+
return el.host && el !== document && el.host.nodeType && el.host !== el ? el.host : el.parentNode;
|
|
88618
88635
|
}
|
|
88619
88636
|
function closest( /**HTMLElement*/el, /**String*/selector, /**HTMLElement*/ctx, includeCTX) {
|
|
88620
88637
|
if (el) {
|
|
@@ -90498,8 +90515,11 @@ Sortable.prototype = /** @lends Sortable.prototype */{
|
|
|
90498
90515
|
_nulling: function _nulling() {
|
|
90499
90516
|
pluginEvent('nulling', this);
|
|
90500
90517
|
rootEl = dragEl = parentEl = ghostEl = nextEl = cloneEl = lastDownEl = cloneHidden = tapEvt = touchEvt = moved = newIndex = newDraggableIndex = oldIndex = oldDraggableIndex = lastTarget = lastDirection = putSortable = activeGroup = Sortable.dragged = Sortable.ghost = Sortable.clone = Sortable.active = null;
|
|
90501
|
-
|
|
90502
|
-
|
|
90518
|
+
var el = this.el;
|
|
90519
|
+
savedInputChecked.forEach(function (checkEl) {
|
|
90520
|
+
if (el.contains(checkEl)) {
|
|
90521
|
+
checkEl.checked = true;
|
|
90522
|
+
}
|
|
90503
90523
|
});
|
|
90504
90524
|
savedInputChecked.length = lastDx = lastDy = 0;
|
|
90505
90525
|
},
|
|
@@ -64863,6 +64863,29 @@ function resolveAggFunc(aggFunc) {
|
|
|
64863
64863
|
return fn;
|
|
64864
64864
|
}
|
|
64865
64865
|
|
|
64866
|
+
/**
|
|
64867
|
+
* Larguras padrão das colunas do grid por tipo de UserInterface
|
|
64868
|
+
*/
|
|
64869
|
+
const GRID_COLUMN_DEFAULT_WIDTHS = {
|
|
64870
|
+
[UserInterface.SEARCH]: 200,
|
|
64871
|
+
[UserInterface.SEARCHPLUS]: 100,
|
|
64872
|
+
[UserInterface.DATE]: 120,
|
|
64873
|
+
[UserInterface.DATETIME]: 160,
|
|
64874
|
+
[UserInterface.TIME]: 100,
|
|
64875
|
+
[UserInterface.ELAPSEDTIME]: 100,
|
|
64876
|
+
[UserInterface.DECIMALNUMBER]: 130,
|
|
64877
|
+
[UserInterface.INTEGERNUMBER]: 120,
|
|
64878
|
+
[UserInterface.SWITCH]: 80,
|
|
64879
|
+
[UserInterface.FILE]: 100,
|
|
64880
|
+
[UserInterface.HTML]: 200,
|
|
64881
|
+
[UserInterface.LONGTEXT]: 200,
|
|
64882
|
+
[UserInterface.CHECKBOX]: 80,
|
|
64883
|
+
[UserInterface.OPTIONSELECTOR]: 100,
|
|
64884
|
+
[UserInterface.SHORTTEXT]: 200,
|
|
64885
|
+
[UserInterface.PASSWORD]: 100,
|
|
64886
|
+
[UserInterface.MASKEDTEXT]: 100,
|
|
64887
|
+
};
|
|
64888
|
+
|
|
64866
64889
|
class AgGridController {
|
|
64867
64890
|
configFilterColumn(filterColumn) {
|
|
64868
64891
|
this._filterColumn = filterColumn;
|
|
@@ -64891,10 +64914,10 @@ class AgGridController {
|
|
|
64891
64914
|
this.COLUMN_FOOTER_OPER = 'gridFooterOper';
|
|
64892
64915
|
this.RECORD_ARCHIVE_COL_ID = '__RECORD_ARCHIVE__';
|
|
64893
64916
|
this.BLOCK_LOAD_DEBOUNCE = 100;
|
|
64894
|
-
this.DEFAULT_FONT_SIZE =
|
|
64917
|
+
this.DEFAULT_FONT_SIZE = 8;
|
|
64895
64918
|
this.DEFAULT_FONT_SIZE_HTML5 = 32;
|
|
64896
|
-
this.DEFAULT_ICON_SIZE =
|
|
64897
|
-
this.DEFAULT_MAX_SIZE =
|
|
64919
|
+
this.DEFAULT_ICON_SIZE = 40;
|
|
64920
|
+
this.DEFAULT_MAX_SIZE = 300;
|
|
64898
64921
|
this._menuItems = [];
|
|
64899
64922
|
this._idAttribName = '__record__id__';
|
|
64900
64923
|
this._gridConfig = [];
|
|
@@ -65880,9 +65903,11 @@ class AgGridController {
|
|
|
65880
65903
|
tooltip = this._i18n('ez-grid.columnCantBeOrder');
|
|
65881
65904
|
}
|
|
65882
65905
|
const presentationFrom = (_d = source === null || source === void 0 ? void 0 : source.props) === null || _d === void 0 ? void 0 : _d.get(PRESENTATION_FROM_COL_PROP_NAME);
|
|
65906
|
+
const initialWidth = this.getInitialColumnWidth(source.userInterface, source.label);
|
|
65883
65907
|
return this._editionManager.configureColumn({
|
|
65884
65908
|
headerName: source.label,
|
|
65885
65909
|
field: source.name,
|
|
65910
|
+
width: initialWidth,
|
|
65886
65911
|
aggFunc: this.getAggFunc(source),
|
|
65887
65912
|
sortable: propSortable,
|
|
65888
65913
|
resizable: true,
|
|
@@ -66228,10 +66253,21 @@ class AgGridController {
|
|
|
66228
66253
|
}
|
|
66229
66254
|
const field = (_a = this._dataUnit) === null || _a === void 0 ? void 0 : _a.getField(cfgColumn.name);
|
|
66230
66255
|
const label = (_b = field === null || field === void 0 ? void 0 : field.label) !== null && _b !== void 0 ? _b : (_f = (_e = (_d = (_c = this._gridOptions) === null || _c === void 0 ? void 0 : _c.columnApi) === null || _d === void 0 ? void 0 : _d.getColumn(cfgColumn.name)) === null || _e === void 0 ? void 0 : _e.getColDef()) === null || _f === void 0 ? void 0 : _f.headerName;
|
|
66231
|
-
|
|
66232
|
-
|
|
66256
|
+
return this.getInitialColumnWidth(field === null || field === void 0 ? void 0 : field.userInterface, label);
|
|
66257
|
+
}
|
|
66258
|
+
getInitialColumnWidth(userInterface, label) {
|
|
66259
|
+
const columnWidthByLabel = this.getColumnWidthByLabel(label);
|
|
66260
|
+
const defaultWidth = this.getDefaultWidthByUserInterface(userInterface);
|
|
66261
|
+
if (!defaultWidth) {
|
|
66262
|
+
return columnWidthByLabel;
|
|
66263
|
+
}
|
|
66264
|
+
return Math.max(defaultWidth, columnWidthByLabel);
|
|
66265
|
+
}
|
|
66266
|
+
getDefaultWidthByUserInterface(userInterface) {
|
|
66267
|
+
if (!userInterface) {
|
|
66268
|
+
return undefined;
|
|
66233
66269
|
}
|
|
66234
|
-
return
|
|
66270
|
+
return GRID_COLUMN_DEFAULT_WIDTHS[userInterface];
|
|
66235
66271
|
}
|
|
66236
66272
|
getColumnWidthByLabel(label) {
|
|
66237
66273
|
const labelSize = ((label === null || label === void 0 ? void 0 : label.length) || 0) * this.DEFAULT_FONT_SIZE + this.DEFAULT_ICON_SIZE;
|