@m4l/components 0.1.6 → 0.1.7
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/components/DynamicFilter/index.js +1 -1
- package/components/ScrollBar/index.js +2 -2
- package/index.js +2 -4
- package/lodash.js +23 -512
- package/package.json +3 -2
- package/react-draggable.js +4 -4
- package/react-resizable.js +4 -4
- package/react-splitter-layout.js +2 -2
- package/utils/index.js +1 -189
- package/can-use-dom.js +0 -3
- package/core-js.js +0 -2684
- package/juggle.js +0 -325
- package/simplebar.js +0 -850
- package/style.css +0 -1
package/react-splitter-layout.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { g as getDefaultExportFromCjs } from "./commonjs.js";
|
|
2
|
-
import
|
|
2
|
+
import require$$1 from "prop-types";
|
|
3
3
|
import require$$0 from "react";
|
|
4
4
|
var lib = { exports: {} };
|
|
5
5
|
(function(module, exports) {
|
|
6
6
|
!function(e, t) {
|
|
7
|
-
module.exports = t(
|
|
7
|
+
module.exports = t(require$$1, require$$0);
|
|
8
8
|
}(window, function(e, t) {
|
|
9
9
|
return function(e2) {
|
|
10
10
|
var t2 = {};
|
package/utils/index.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import require$$0 from "react";
|
|
2
|
-
import { g as gatherActiveObservationsAtDepth, h as hasActiveObservations, b as broadcastActiveObservations, a as hasSkippedObservations, d as deliverResizeLoopError } from "../juggle.js";
|
|
3
2
|
const getPaletteColor = function(palette, s) {
|
|
4
3
|
s = s.replace(/\[(\w+)\]/g, ".$1");
|
|
5
4
|
s = s.replace(/^\./, "");
|
|
@@ -571,191 +570,4 @@ function cloneElement(element, props) {
|
|
|
571
570
|
}
|
|
572
571
|
return /* @__PURE__ */ _react.default.cloneElement(element, props);
|
|
573
572
|
}
|
|
574
|
-
|
|
575
|
-
var freeze = function(obj) {
|
|
576
|
-
return Object.freeze(obj);
|
|
577
|
-
};
|
|
578
|
-
var isSVG = function(target) {
|
|
579
|
-
return target instanceof SVGElement && "getBBox" in target;
|
|
580
|
-
};
|
|
581
|
-
var isHidden = function(target) {
|
|
582
|
-
if (isSVG(target)) {
|
|
583
|
-
var _a = target.getBBox(), width = _a.width, height = _a.height;
|
|
584
|
-
return !width && !height;
|
|
585
|
-
}
|
|
586
|
-
var _b = target, offsetWidth = _b.offsetWidth, offsetHeight = _b.offsetHeight;
|
|
587
|
-
return !(offsetWidth || offsetHeight || target.getClientRects().length);
|
|
588
|
-
};
|
|
589
|
-
var isElement = function(obj) {
|
|
590
|
-
var _a;
|
|
591
|
-
if (obj instanceof Element) {
|
|
592
|
-
return true;
|
|
593
|
-
}
|
|
594
|
-
var scope = (_a = obj === null || obj === void 0 ? void 0 : obj.ownerDocument) === null || _a === void 0 ? void 0 : _a.defaultView;
|
|
595
|
-
return !!(scope && obj instanceof scope.Element);
|
|
596
|
-
};
|
|
597
|
-
var isReplacedElement = function(target) {
|
|
598
|
-
switch (target.tagName) {
|
|
599
|
-
case "INPUT":
|
|
600
|
-
if (target.type !== "image") {
|
|
601
|
-
break;
|
|
602
|
-
}
|
|
603
|
-
case "VIDEO":
|
|
604
|
-
case "AUDIO":
|
|
605
|
-
case "EMBED":
|
|
606
|
-
case "OBJECT":
|
|
607
|
-
case "CANVAS":
|
|
608
|
-
case "IFRAME":
|
|
609
|
-
case "IMG":
|
|
610
|
-
return true;
|
|
611
|
-
}
|
|
612
|
-
return false;
|
|
613
|
-
};
|
|
614
|
-
var global = typeof window !== "undefined" ? window : {};
|
|
615
|
-
var process = function() {
|
|
616
|
-
var depth = 0;
|
|
617
|
-
gatherActiveObservationsAtDepth(depth);
|
|
618
|
-
while (hasActiveObservations()) {
|
|
619
|
-
depth = broadcastActiveObservations();
|
|
620
|
-
gatherActiveObservationsAtDepth(depth);
|
|
621
|
-
}
|
|
622
|
-
if (hasSkippedObservations()) {
|
|
623
|
-
deliverResizeLoopError();
|
|
624
|
-
}
|
|
625
|
-
return depth > 0;
|
|
626
|
-
};
|
|
627
|
-
var trigger;
|
|
628
|
-
var callbacks = [];
|
|
629
|
-
var notify = function() {
|
|
630
|
-
return callbacks.splice(0).forEach(function(cb) {
|
|
631
|
-
return cb();
|
|
632
|
-
});
|
|
633
|
-
};
|
|
634
|
-
var queueMicroTask = function(callback) {
|
|
635
|
-
if (!trigger) {
|
|
636
|
-
var toggle_1 = 0;
|
|
637
|
-
var el_1 = document.createTextNode("");
|
|
638
|
-
var config = { characterData: true };
|
|
639
|
-
new MutationObserver(function() {
|
|
640
|
-
return notify();
|
|
641
|
-
}).observe(el_1, config);
|
|
642
|
-
trigger = function() {
|
|
643
|
-
el_1.textContent = "".concat(toggle_1 ? toggle_1-- : toggle_1++);
|
|
644
|
-
};
|
|
645
|
-
}
|
|
646
|
-
callbacks.push(callback);
|
|
647
|
-
trigger();
|
|
648
|
-
};
|
|
649
|
-
var queueResizeObserver = function(cb) {
|
|
650
|
-
queueMicroTask(function ResizeObserver() {
|
|
651
|
-
requestAnimationFrame(cb);
|
|
652
|
-
});
|
|
653
|
-
};
|
|
654
|
-
var watching = 0;
|
|
655
|
-
var isWatching = function() {
|
|
656
|
-
return !!watching;
|
|
657
|
-
};
|
|
658
|
-
var CATCH_PERIOD = 250;
|
|
659
|
-
var observerConfig = { attributes: true, characterData: true, childList: true, subtree: true };
|
|
660
|
-
var events = [
|
|
661
|
-
"resize",
|
|
662
|
-
"load",
|
|
663
|
-
"transitionend",
|
|
664
|
-
"animationend",
|
|
665
|
-
"animationstart",
|
|
666
|
-
"animationiteration",
|
|
667
|
-
"keyup",
|
|
668
|
-
"keydown",
|
|
669
|
-
"mouseup",
|
|
670
|
-
"mousedown",
|
|
671
|
-
"mouseover",
|
|
672
|
-
"mouseout",
|
|
673
|
-
"blur",
|
|
674
|
-
"focus"
|
|
675
|
-
];
|
|
676
|
-
var time = function(timeout) {
|
|
677
|
-
if (timeout === void 0) {
|
|
678
|
-
timeout = 0;
|
|
679
|
-
}
|
|
680
|
-
return Date.now() + timeout;
|
|
681
|
-
};
|
|
682
|
-
var scheduled = false;
|
|
683
|
-
var Scheduler = function() {
|
|
684
|
-
function Scheduler2() {
|
|
685
|
-
var _this = this;
|
|
686
|
-
this.stopped = true;
|
|
687
|
-
this.listener = function() {
|
|
688
|
-
return _this.schedule();
|
|
689
|
-
};
|
|
690
|
-
}
|
|
691
|
-
Scheduler2.prototype.run = function(timeout) {
|
|
692
|
-
var _this = this;
|
|
693
|
-
if (timeout === void 0) {
|
|
694
|
-
timeout = CATCH_PERIOD;
|
|
695
|
-
}
|
|
696
|
-
if (scheduled) {
|
|
697
|
-
return;
|
|
698
|
-
}
|
|
699
|
-
scheduled = true;
|
|
700
|
-
var until = time(timeout);
|
|
701
|
-
queueResizeObserver(function() {
|
|
702
|
-
var elementsHaveResized = false;
|
|
703
|
-
try {
|
|
704
|
-
elementsHaveResized = process();
|
|
705
|
-
} finally {
|
|
706
|
-
scheduled = false;
|
|
707
|
-
timeout = until - time();
|
|
708
|
-
if (!isWatching()) {
|
|
709
|
-
return;
|
|
710
|
-
}
|
|
711
|
-
if (elementsHaveResized) {
|
|
712
|
-
_this.run(1e3);
|
|
713
|
-
} else if (timeout > 0) {
|
|
714
|
-
_this.run(timeout);
|
|
715
|
-
} else {
|
|
716
|
-
_this.start();
|
|
717
|
-
}
|
|
718
|
-
}
|
|
719
|
-
});
|
|
720
|
-
};
|
|
721
|
-
Scheduler2.prototype.schedule = function() {
|
|
722
|
-
this.stop();
|
|
723
|
-
this.run();
|
|
724
|
-
};
|
|
725
|
-
Scheduler2.prototype.observe = function() {
|
|
726
|
-
var _this = this;
|
|
727
|
-
var cb = function() {
|
|
728
|
-
return _this.observer && _this.observer.observe(document.body, observerConfig);
|
|
729
|
-
};
|
|
730
|
-
document.body ? cb() : global.addEventListener("DOMContentLoaded", cb);
|
|
731
|
-
};
|
|
732
|
-
Scheduler2.prototype.start = function() {
|
|
733
|
-
var _this = this;
|
|
734
|
-
if (this.stopped) {
|
|
735
|
-
this.stopped = false;
|
|
736
|
-
this.observer = new MutationObserver(this.listener);
|
|
737
|
-
this.observe();
|
|
738
|
-
events.forEach(function(name) {
|
|
739
|
-
return global.addEventListener(name, _this.listener, true);
|
|
740
|
-
});
|
|
741
|
-
}
|
|
742
|
-
};
|
|
743
|
-
Scheduler2.prototype.stop = function() {
|
|
744
|
-
var _this = this;
|
|
745
|
-
if (!this.stopped) {
|
|
746
|
-
this.observer && this.observer.disconnect();
|
|
747
|
-
events.forEach(function(name) {
|
|
748
|
-
return global.removeEventListener(name, _this.listener, true);
|
|
749
|
-
});
|
|
750
|
-
this.stopped = true;
|
|
751
|
-
}
|
|
752
|
-
};
|
|
753
|
-
return Scheduler2;
|
|
754
|
-
}();
|
|
755
|
-
var scheduler = new Scheduler();
|
|
756
|
-
var updateCount = function(n) {
|
|
757
|
-
!watching && n > 0 && scheduler.start();
|
|
758
|
-
watching += n;
|
|
759
|
-
!watching && scheduler.stop();
|
|
760
|
-
};
|
|
761
|
-
export { getThemeVariantColor as a, getVariantColor as b, global as c, isSVG as d, isReplacedElement as e, freeze as f, getPaletteColor as g, isElement as h, isHidden as i, shims as j, domFns as k, log$1 as l, utils as m, positionFns as p, resizeObservers as r, scheduler as s, updateCount as u };
|
|
573
|
+
export { getThemeVariantColor as a, getVariantColor as b, domFns as d, getPaletteColor as g, log$1 as l, positionFns as p, shims as s, utils as u };
|
package/can-use-dom.js
DELETED