blue-web 1.25.5 → 1.26.0
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/js/overflow-detector.bundle.js +1 -0
- package/dist/js/overflow-detector.d.ts +15 -0
- package/dist/js/overflow-detector.js +67 -0
- package/dist/merged.scss +26 -2
- package/dist/style.css +9 -3
- package/dist/style.css.map +1 -1
- package/dist/style.min.css +3 -3
- package/dist/style.scss +1 -1
- package/dist/styles/_devexpress.scss +25 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(()=>{"use strict";var e={};function r(e,r,t){return(r=function(e){var r=function(e){if("object"!=typeof e||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var t=r.call(e,"string");if("object"!=typeof t)return t;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof r?r:r+""}(r))in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}e.d=(r,t)=>{for(var i in t)e.o(t,i)&&!e.o(r,i)&&Object.defineProperty(r,i,{enumerable:!0,get:t[i]})},e.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),window.blueWeb=window.blueWeb||{},window.blueWeb.OverflowDetector=class{constructor(){r(this,"resizeObserver",null),r(this,"entries",new Map),"ResizeObserver"in window&&(this.resizeObserver=new ResizeObserver(e=>{for(const r of e){const e=r.target,t=this.entries.get(e);t&&this.check(t)}}))}check(e){const r=e.element.scrollWidth>e.element.clientWidth+1;r!==e.wasOverflowing&&(e.wasOverflowing=r,e.onChange(r,e.element))}observe(e){var r;const{element:t,onChange:i}=e;this.entries.has(t)&&this.unobserve(t);const n={element:t,onChange:i,wasOverflowing:!1};this.entries.set(t,n),null===(r=this.resizeObserver)||void 0===r||r.observe(t),this.check(n)}unobserve(e){var r;null===(r=this.resizeObserver)||void 0===r||r.unobserve(e),this.entries.delete(e)}checkAll(){this.entries.forEach(e=>{this.check(e)})}destroy(){var e;null===(e=this.resizeObserver)||void 0===e||e.disconnect(),this.resizeObserver=null,this.entries.clear()}},window.blueWeb.isOverflowing=function(e){return e.scrollWidth>e.clientWidth+1}})();
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface OverflowObserverOptions {
|
|
2
|
+
element: HTMLElement;
|
|
3
|
+
onChange: (isOverflowing: boolean, element: HTMLElement) => void;
|
|
4
|
+
}
|
|
5
|
+
export declare class OverflowDetector {
|
|
6
|
+
private resizeObserver;
|
|
7
|
+
private entries;
|
|
8
|
+
constructor();
|
|
9
|
+
private check;
|
|
10
|
+
observe(options: OverflowObserverOptions): void;
|
|
11
|
+
unobserve(element: HTMLElement): void;
|
|
12
|
+
checkAll(): void;
|
|
13
|
+
destroy(): void;
|
|
14
|
+
}
|
|
15
|
+
export declare function isOverflowing(element: HTMLElement): boolean;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
2
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
3
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
4
|
+
export class OverflowDetector {
|
|
5
|
+
constructor() {
|
|
6
|
+
_defineProperty(this, "resizeObserver", null);
|
|
7
|
+
_defineProperty(this, "entries", new Map());
|
|
8
|
+
if ("ResizeObserver" in window) {
|
|
9
|
+
this.resizeObserver = new ResizeObserver(resizeEntries => {
|
|
10
|
+
for (const resizeEntry of resizeEntries) {
|
|
11
|
+
const element = resizeEntry.target;
|
|
12
|
+
const entry = this.entries.get(element);
|
|
13
|
+
if (entry) {
|
|
14
|
+
this.check(entry);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
check(entry) {
|
|
21
|
+
const isOverflowing = entry.element.scrollWidth > entry.element.clientWidth + 1;
|
|
22
|
+
if (isOverflowing !== entry.wasOverflowing) {
|
|
23
|
+
entry.wasOverflowing = isOverflowing;
|
|
24
|
+
entry.onChange(isOverflowing, entry.element);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
observe(options) {
|
|
28
|
+
var _this$resizeObserver;
|
|
29
|
+
const {
|
|
30
|
+
element,
|
|
31
|
+
onChange
|
|
32
|
+
} = options;
|
|
33
|
+
if (this.entries.has(element)) {
|
|
34
|
+
this.unobserve(element);
|
|
35
|
+
}
|
|
36
|
+
const entry = {
|
|
37
|
+
element,
|
|
38
|
+
onChange,
|
|
39
|
+
wasOverflowing: false
|
|
40
|
+
};
|
|
41
|
+
this.entries.set(element, entry);
|
|
42
|
+
(_this$resizeObserver = this.resizeObserver) === null || _this$resizeObserver === void 0 || _this$resizeObserver.observe(element);
|
|
43
|
+
this.check(entry);
|
|
44
|
+
}
|
|
45
|
+
unobserve(element) {
|
|
46
|
+
var _this$resizeObserver2;
|
|
47
|
+
(_this$resizeObserver2 = this.resizeObserver) === null || _this$resizeObserver2 === void 0 || _this$resizeObserver2.unobserve(element);
|
|
48
|
+
this.entries.delete(element);
|
|
49
|
+
}
|
|
50
|
+
checkAll() {
|
|
51
|
+
this.entries.forEach(entry => {
|
|
52
|
+
this.check(entry);
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
destroy() {
|
|
56
|
+
var _this$resizeObserver3;
|
|
57
|
+
(_this$resizeObserver3 = this.resizeObserver) === null || _this$resizeObserver3 === void 0 || _this$resizeObserver3.disconnect();
|
|
58
|
+
this.resizeObserver = null;
|
|
59
|
+
this.entries.clear();
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
export function isOverflowing(element) {
|
|
63
|
+
return element.scrollWidth > element.clientWidth + 1;
|
|
64
|
+
}
|
|
65
|
+
window.blueWeb = window.blueWeb || {};
|
|
66
|
+
window.blueWeb.OverflowDetector = OverflowDetector;
|
|
67
|
+
window.blueWeb.isOverflowing = isOverflowing;
|
package/dist/merged.scss
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Blue Web v1.
|
|
2
|
+
* Blue Web v1.26.0 (https://bruegmann.github.io/blue-web)
|
|
3
3
|
* Licensed under GNU General Public License v3.0 (https://github.com/bruegmann/blue-web/blob/master/LICENSE).
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -12367,6 +12367,8 @@ dialog.blue-modal:has(.offcanvas-start) {
|
|
|
12367
12367
|
--dxbl-dropdown-border-radius: var(--bs-border-radius) !important;
|
|
12368
12368
|
--dxbl-btn-border-radius: var(--bs-border-radius) !important;
|
|
12369
12369
|
--dxbl-context-menu-border-radius: var(--bs-border-radius) !important;
|
|
12370
|
+
--dxbl-edit-dropdown-border-radius: var(--bs-border-radius) !important;
|
|
12371
|
+
--dxbl-list-box-border-radius: var(--bs-border-radius) !important;
|
|
12370
12372
|
|
|
12371
12373
|
--dxbl-btn-font-size: 1rem;
|
|
12372
12374
|
--dxbl-checkbox-font-size: 1rem;
|
|
@@ -12470,7 +12472,29 @@ body.modal-open .dxbl-popup-cell[style="z-index: 1050;"] {
|
|
|
12470
12472
|
.dxbl-dropdown-body
|
|
12471
12473
|
ul
|
|
12472
12474
|
li:not(.dxbl-context-menu-separator)
|
|
12473
|
-
> .dxbl-context-menu-item
|
|
12475
|
+
> .dxbl-context-menu-item,
|
|
12476
|
+
.dxbl-list-box-render-container:not(.dxbl-disabled):not(:disabled):not(.dxbl-readonly)
|
|
12477
|
+
> .dxbl-scroll-viewer
|
|
12478
|
+
> .dxbl-scroll-viewer-content
|
|
12479
|
+
> :not(.dxbl-list-box-empty-data-container)
|
|
12480
|
+
> li:not(.dxbl-list-box-group-item):not(.dxbl-list-box-item-disabled):not(.dxbl-list-box-empty-list-item),
|
|
12481
|
+
.dxbl-list-box-render-container:not(.dxbl-disabled):not(:disabled):not(.dxbl-readonly)
|
|
12482
|
+
> .dxbl-scroll-viewer
|
|
12483
|
+
> .dxbl-scroll-viewer-content
|
|
12484
|
+
> :not(.dxbl-list-box-empty-data-container)
|
|
12485
|
+
> tbody
|
|
12486
|
+
> tr:not(.dxbl-list-box-group-item):not(.dxbl-list-box-item-disabled):not(.dxbl-list-box-empty-list-item),
|
|
12487
|
+
.dxbl-list-box:not(.dxbl-disabled):not(:disabled):not(.dxbl-readonly)
|
|
12488
|
+
> .dxbl-scroll-viewer
|
|
12489
|
+
> .dxbl-scroll-viewer-content
|
|
12490
|
+
> :not(.dxbl-list-box-empty-data-container)
|
|
12491
|
+
> li:not(.dxbl-list-box-group-item):not(.dxbl-list-box-item-disabled):not(.dxbl-list-box-empty-list-item),
|
|
12492
|
+
.dxbl-list-box:not(.dxbl-disabled):not(:disabled):not(.dxbl-readonly)
|
|
12493
|
+
> .dxbl-scroll-viewer
|
|
12494
|
+
> .dxbl-scroll-viewer-content
|
|
12495
|
+
> :not(.dxbl-list-box-empty-data-container)
|
|
12496
|
+
> tbody
|
|
12497
|
+
> tr:not(.dxbl-list-box-group-item):not(.dxbl-list-box-item-disabled):not(.dxbl-list-box-empty-list-item) {
|
|
12474
12498
|
cursor: default;
|
|
12475
12499
|
}
|
|
12476
12500
|
}
|