@gct-paas/core-web 0.1.4-dev.3 → 0.1.4-dev.4

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.
Files changed (85) hide show
  1. package/dist/core-web.css +1 -1
  2. package/dist/index.min.cjs +11 -11
  3. package/dist/index.system.min.js +11 -11
  4. package/es/components/code-editor/code-editor.mjs +1 -2
  5. package/es/editor/gct-form-field-select/gct-model-select.vue +2 -2
  6. package/es/editor/index.mjs +2 -2
  7. package/package.json +5 -5
  8. package/es/_virtual/_commonjsHelpers.mjs +0 -44
  9. package/es/_virtual/node.mjs +0 -7
  10. package/es/_virtual/node2.mjs +0 -3
  11. package/es/node_modules/.pnpm/@aesoper_normal-utils@0.1.5/node_modules/@aesoper/normal-utils/NormalUtils.es.mjs +0 -3
  12. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/_virtual/_rollupPluginBabelHelpers.mjs +0 -142
  13. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/config/index.mjs +0 -7
  14. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/index.mjs +0 -1
  15. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/loader/index.mjs +0 -188
  16. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/utils/compose.mjs +0 -13
  17. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/utils/curry.mjs +0 -19
  18. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/utils/deepMerge.mjs +0 -14
  19. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/utils/isObject.mjs +0 -5
  20. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/utils/makeCancelable.mjs +0 -20
  21. package/es/node_modules/.pnpm/@monaco-editor_loader@1.5.0/node_modules/@monaco-editor/loader/lib/es/validators/index.mjs +0 -49
  22. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/createPopper.mjs +0 -200
  23. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/contains.mjs +0 -26
  24. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getBoundingClientRect.mjs +0 -44
  25. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getClippingRect.mjs +0 -72
  26. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getCompositeRect.mjs +0 -60
  27. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getComputedStyle.mjs +0 -7
  28. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getDocumentElement.mjs +0 -9
  29. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getDocumentRect.mjs +0 -32
  30. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getHTMLElementScroll.mjs +0 -8
  31. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getLayoutRect.mjs +0 -28
  32. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getNodeName.mjs +0 -5
  33. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getNodeScroll.mjs +0 -14
  34. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getOffsetParent.mjs +0 -71
  35. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getParentNode.mjs +0 -22
  36. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getScrollParent.mjs +0 -19
  37. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getViewportRect.mjs +0 -34
  38. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getWindow.mjs +0 -14
  39. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getWindowScroll.mjs +0 -13
  40. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/getWindowScrollBarX.mjs +0 -16
  41. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/instanceOf.mjs +0 -23
  42. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/isLayoutViewport.mjs +0 -7
  43. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/isScrollParent.mjs +0 -13
  44. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/isTableElement.mjs +0 -7
  45. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/dom-utils/listScrollParents.mjs +0 -29
  46. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/enums.mjs +0 -33
  47. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/index.mjs +0 -5
  48. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/applyStyles.mjs +0 -87
  49. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/arrow.mjs +0 -92
  50. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/computeStyles.mjs +0 -171
  51. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/eventListeners.mjs +0 -51
  52. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/flip.mjs +0 -149
  53. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/hide.mjs +0 -63
  54. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/index.mjs +0 -9
  55. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/offset.mjs +0 -56
  56. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/popperOffsets.mjs +0 -27
  57. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/modifiers/preventOverflow.mjs +0 -144
  58. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/popper-lite.mjs +0 -12
  59. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/popper.mjs +0 -19
  60. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/computeAutoPlacement.mjs +0 -46
  61. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/computeOffsets.mjs +0 -73
  62. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/debounce.mjs +0 -17
  63. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/detectOverflow.mjs +0 -67
  64. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/expandToHashMap.mjs +0 -8
  65. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getAltAxis.mjs +0 -5
  66. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getBasePlacement.mjs +0 -7
  67. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getFreshSideObject.mjs +0 -10
  68. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getMainAxisFromPlacement.mjs +0 -5
  69. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getOppositePlacement.mjs +0 -13
  70. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getOppositeVariationPlacement.mjs +0 -11
  71. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/getVariation.mjs +0 -5
  72. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/math.mjs +0 -5
  73. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/mergeByName.mjs +0 -16
  74. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/mergePaddingObject.mjs +0 -7
  75. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/orderModifiers.mjs +0 -46
  76. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/rectToClientRect.mjs +0 -10
  77. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/userAgent.mjs +0 -13
  78. package/es/node_modules/.pnpm/@popperjs_core@2.11.8/node_modules/@popperjs/core/lib/utils/within.mjs +0 -11
  79. package/es/node_modules/.pnpm/@vueuse_core@13.7.0_vue@3.5.18_typescript@5.9.2_/node_modules/@vueuse/core/index.mjs +0 -8285
  80. package/es/node_modules/.pnpm/@vueuse_shared@13.7.0_vue@3.5.18_typescript@5.9.2_/node_modules/@vueuse/shared/index.mjs +0 -1641
  81. package/es/node_modules/.pnpm/gradient-parser@1.0.2/node_modules/gradient-parser/build/node.mjs +0 -528
  82. package/es/node_modules/.pnpm/state-local@1.0.7/node_modules/state-local/lib/es/state-local.mjs +0 -193
  83. package/es/node_modules/.pnpm/tinycolor2@1.6.0/node_modules/tinycolor2/esm/tinycolor.mjs +0 -1180
  84. package/es/node_modules/.pnpm/vue-types@3.0.2_vue@3.5.18_typescript@5.9.2_/node_modules/vue-types/dist/vue-types.m.mjs +0 -3
  85. package/es/node_modules/.pnpm/vue3-colorpicker@2.3.0_@aesoper_normal-utils@0.1.5_@popperjs_core@2.11.8_@vueuse_core@1_c6850a6c65df63e96440af393dfce213/node_modules/vue3-colorpicker/index.es.mjs +0 -1815
@@ -1,49 +0,0 @@
1
- import curry from '../utils/curry.mjs';
2
- import isObject from '../utils/isObject.mjs';
3
-
4
- /**
5
- * validates the configuration object and informs about deprecation
6
- * @param {Object} config - the configuration object
7
- * @return {Object} config - the validated configuration object
8
- */
9
-
10
- function validateConfig(config) {
11
- if (!config) errorHandler('configIsRequired');
12
- if (!isObject(config)) errorHandler('configType');
13
-
14
- if (config.urls) {
15
- informAboutDeprecation();
16
- return {
17
- paths: {
18
- vs: config.urls.monacoBase
19
- }
20
- };
21
- }
22
-
23
- return config;
24
- }
25
- /**
26
- * logs deprecation message
27
- */
28
-
29
-
30
- function informAboutDeprecation() {
31
- console.warn(errorMessages.deprecation);
32
- }
33
-
34
- function throwError(errorMessages, type) {
35
- throw new Error(errorMessages[type] || errorMessages["default"]);
36
- }
37
-
38
- var errorMessages = {
39
- configIsRequired: 'the configuration object is required',
40
- configType: 'the configuration object should be an object',
41
- "default": 'an unknown error accured in `@monaco-editor/loader` package',
42
- deprecation: "Deprecation warning!\n You are using deprecated way of configuration.\n\n Instead of using\n monaco.config({ urls: { monacoBase: '...' } })\n use\n monaco.config({ paths: { vs: '...' } })\n\n For more please check the link https://github.com/suren-atoyan/monaco-loader#config\n "
43
- };
44
- var errorHandler = curry(throwError)(errorMessages);
45
- var validators = {
46
- config: validateConfig
47
- };
48
-
49
- export { validators as default, errorHandler, errorMessages };
@@ -1,200 +0,0 @@
1
- import getCompositeRect from './dom-utils/getCompositeRect.mjs';
2
- import getLayoutRect from './dom-utils/getLayoutRect.mjs';
3
- import listScrollParents from './dom-utils/listScrollParents.mjs';
4
- import getOffsetParent from './dom-utils/getOffsetParent.mjs';
5
- import orderModifiers from './utils/orderModifiers.mjs';
6
- import debounce from './utils/debounce.mjs';
7
- import mergeByName from './utils/mergeByName.mjs';
8
- export { default as detectOverflow } from './utils/detectOverflow.mjs';
9
- import { isElement } from './dom-utils/instanceOf.mjs';
10
-
11
- var DEFAULT_OPTIONS = {
12
- placement: 'bottom',
13
- modifiers: [],
14
- strategy: 'absolute'
15
- };
16
-
17
- function areValidElements() {
18
- for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
19
- args[_key] = arguments[_key];
20
- }
21
-
22
- return !args.some(function (element) {
23
- return !(element && typeof element.getBoundingClientRect === 'function');
24
- });
25
- }
26
-
27
- function popperGenerator(generatorOptions) {
28
- if (generatorOptions === void 0) {
29
- generatorOptions = {};
30
- }
31
-
32
- var _generatorOptions = generatorOptions,
33
- _generatorOptions$def = _generatorOptions.defaultModifiers,
34
- defaultModifiers = _generatorOptions$def === void 0 ? [] : _generatorOptions$def,
35
- _generatorOptions$def2 = _generatorOptions.defaultOptions,
36
- defaultOptions = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS : _generatorOptions$def2;
37
- return function createPopper(reference, popper, options) {
38
- if (options === void 0) {
39
- options = defaultOptions;
40
- }
41
-
42
- var state = {
43
- placement: 'bottom',
44
- orderedModifiers: [],
45
- options: Object.assign({}, DEFAULT_OPTIONS, defaultOptions),
46
- modifiersData: {},
47
- elements: {
48
- reference: reference,
49
- popper: popper
50
- },
51
- attributes: {},
52
- styles: {}
53
- };
54
- var effectCleanupFns = [];
55
- var isDestroyed = false;
56
- var instance = {
57
- state: state,
58
- setOptions: function setOptions(setOptionsAction) {
59
- var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;
60
- cleanupModifierEffects();
61
- state.options = Object.assign({}, defaultOptions, state.options, options);
62
- state.scrollParents = {
63
- reference: isElement(reference) ? listScrollParents(reference) : reference.contextElement ? listScrollParents(reference.contextElement) : [],
64
- popper: listScrollParents(popper)
65
- }; // Orders the modifiers based on their dependencies and `phase`
66
- // properties
67
-
68
- var orderedModifiers = orderModifiers(mergeByName([].concat(defaultModifiers, state.options.modifiers))); // Strip out disabled modifiers
69
-
70
- state.orderedModifiers = orderedModifiers.filter(function (m) {
71
- return m.enabled;
72
- });
73
- runModifierEffects();
74
- return instance.update();
75
- },
76
- // Sync update – it will always be executed, even if not necessary. This
77
- // is useful for low frequency updates where sync behavior simplifies the
78
- // logic.
79
- // For high frequency updates (e.g. `resize` and `scroll` events), always
80
- // prefer the async Popper#update method
81
- forceUpdate: function forceUpdate() {
82
- if (isDestroyed) {
83
- return;
84
- }
85
-
86
- var _state$elements = state.elements,
87
- reference = _state$elements.reference,
88
- popper = _state$elements.popper; // Don't proceed if `reference` or `popper` are not valid elements
89
- // anymore
90
-
91
- if (!areValidElements(reference, popper)) {
92
- return;
93
- } // Store the reference and popper rects to be read by modifiers
94
-
95
-
96
- state.rects = {
97
- reference: getCompositeRect(reference, getOffsetParent(popper), state.options.strategy === 'fixed'),
98
- popper: getLayoutRect(popper)
99
- }; // Modifiers have the ability to reset the current update cycle. The
100
- // most common use case for this is the `flip` modifier changing the
101
- // placement, which then needs to re-run all the modifiers, because the
102
- // logic was previously ran for the previous placement and is therefore
103
- // stale/incorrect
104
-
105
- state.reset = false;
106
- state.placement = state.options.placement; // On each update cycle, the `modifiersData` property for each modifier
107
- // is filled with the initial data specified by the modifier. This means
108
- // it doesn't persist and is fresh on each update.
109
- // To ensure persistent data, use `${name}#persistent`
110
-
111
- state.orderedModifiers.forEach(function (modifier) {
112
- return state.modifiersData[modifier.name] = Object.assign({}, modifier.data);
113
- });
114
-
115
- for (var index = 0; index < state.orderedModifiers.length; index++) {
116
- if (state.reset === true) {
117
- state.reset = false;
118
- index = -1;
119
- continue;
120
- }
121
-
122
- var _state$orderedModifie = state.orderedModifiers[index],
123
- fn = _state$orderedModifie.fn,
124
- _state$orderedModifie2 = _state$orderedModifie.options,
125
- _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2,
126
- name = _state$orderedModifie.name;
127
-
128
- if (typeof fn === 'function') {
129
- state = fn({
130
- state: state,
131
- options: _options,
132
- name: name,
133
- instance: instance
134
- }) || state;
135
- }
136
- }
137
- },
138
- // Async and optimistically optimized update – it will not be executed if
139
- // not necessary (debounced to run at most once-per-tick)
140
- update: debounce(function () {
141
- return new Promise(function (resolve) {
142
- instance.forceUpdate();
143
- resolve(state);
144
- });
145
- }),
146
- destroy: function destroy() {
147
- cleanupModifierEffects();
148
- isDestroyed = true;
149
- }
150
- };
151
-
152
- if (!areValidElements(reference, popper)) {
153
- return instance;
154
- }
155
-
156
- instance.setOptions(options).then(function (state) {
157
- if (!isDestroyed && options.onFirstUpdate) {
158
- options.onFirstUpdate(state);
159
- }
160
- }); // Modifiers have the ability to execute arbitrary code before the first
161
- // update cycle runs. They will be executed in the same order as the update
162
- // cycle. This is useful when a modifier adds some persistent data that
163
- // other modifiers need to use, but the modifier is run after the dependent
164
- // one.
165
-
166
- function runModifierEffects() {
167
- state.orderedModifiers.forEach(function (_ref) {
168
- var name = _ref.name,
169
- _ref$options = _ref.options,
170
- options = _ref$options === void 0 ? {} : _ref$options,
171
- effect = _ref.effect;
172
-
173
- if (typeof effect === 'function') {
174
- var cleanupFn = effect({
175
- state: state,
176
- name: name,
177
- instance: instance,
178
- options: options
179
- });
180
-
181
- var noopFn = function noopFn() {};
182
-
183
- effectCleanupFns.push(cleanupFn || noopFn);
184
- }
185
- });
186
- }
187
-
188
- function cleanupModifierEffects() {
189
- effectCleanupFns.forEach(function (fn) {
190
- return fn();
191
- });
192
- effectCleanupFns = [];
193
- }
194
-
195
- return instance;
196
- };
197
- }
198
- var createPopper = /*#__PURE__*/popperGenerator(); // eslint-disable-next-line import/no-unused-modules
199
-
200
- export { createPopper, popperGenerator };
@@ -1,26 +0,0 @@
1
- import { isShadowRoot } from './instanceOf.mjs';
2
-
3
- function contains(parent, child) {
4
- var rootNode = child.getRootNode && child.getRootNode(); // First, attempt with faster native method
5
-
6
- if (parent.contains(child)) {
7
- return true;
8
- } // then fallback to custom implementation with Shadow DOM support
9
- else if (rootNode && isShadowRoot(rootNode)) {
10
- var next = child;
11
-
12
- do {
13
- if (next && parent.isSameNode(next)) {
14
- return true;
15
- } // $FlowFixMe[prop-missing]: need a better way to handle this...
16
-
17
-
18
- next = next.parentNode || next.host;
19
- } while (next);
20
- } // Give up, the result is false
21
-
22
-
23
- return false;
24
- }
25
-
26
- export { contains as default };
@@ -1,44 +0,0 @@
1
- import { isHTMLElement, isElement } from './instanceOf.mjs';
2
- import { round } from '../utils/math.mjs';
3
- import getWindow from './getWindow.mjs';
4
- import isLayoutViewport from './isLayoutViewport.mjs';
5
-
6
- function getBoundingClientRect(element, includeScale, isFixedStrategy) {
7
- if (includeScale === void 0) {
8
- includeScale = false;
9
- }
10
-
11
- if (isFixedStrategy === void 0) {
12
- isFixedStrategy = false;
13
- }
14
-
15
- var clientRect = element.getBoundingClientRect();
16
- var scaleX = 1;
17
- var scaleY = 1;
18
-
19
- if (includeScale && isHTMLElement(element)) {
20
- scaleX = element.offsetWidth > 0 ? round(clientRect.width) / element.offsetWidth || 1 : 1;
21
- scaleY = element.offsetHeight > 0 ? round(clientRect.height) / element.offsetHeight || 1 : 1;
22
- }
23
-
24
- var _ref = isElement(element) ? getWindow(element) : window,
25
- visualViewport = _ref.visualViewport;
26
-
27
- var addVisualOffsets = !isLayoutViewport() && isFixedStrategy;
28
- var x = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX;
29
- var y = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY;
30
- var width = clientRect.width / scaleX;
31
- var height = clientRect.height / scaleY;
32
- return {
33
- width: width,
34
- height: height,
35
- top: y,
36
- right: x + width,
37
- bottom: y + height,
38
- left: x,
39
- x: x,
40
- y: y
41
- };
42
- }
43
-
44
- export { getBoundingClientRect as default };
@@ -1,72 +0,0 @@
1
- import { viewport } from '../enums.mjs';
2
- import getViewportRect from './getViewportRect.mjs';
3
- import getDocumentRect from './getDocumentRect.mjs';
4
- import listScrollParents from './listScrollParents.mjs';
5
- import getOffsetParent from './getOffsetParent.mjs';
6
- import getDocumentElement from './getDocumentElement.mjs';
7
- import getComputedStyle from './getComputedStyle.mjs';
8
- import { isElement, isHTMLElement } from './instanceOf.mjs';
9
- import getBoundingClientRect from './getBoundingClientRect.mjs';
10
- import getParentNode from './getParentNode.mjs';
11
- import contains from './contains.mjs';
12
- import getNodeName from './getNodeName.mjs';
13
- import rectToClientRect from '../utils/rectToClientRect.mjs';
14
- import { max, min } from '../utils/math.mjs';
15
-
16
- function getInnerBoundingClientRect(element, strategy) {
17
- var rect = getBoundingClientRect(element, false, strategy === 'fixed');
18
- rect.top = rect.top + element.clientTop;
19
- rect.left = rect.left + element.clientLeft;
20
- rect.bottom = rect.top + element.clientHeight;
21
- rect.right = rect.left + element.clientWidth;
22
- rect.width = element.clientWidth;
23
- rect.height = element.clientHeight;
24
- rect.x = rect.left;
25
- rect.y = rect.top;
26
- return rect;
27
- }
28
-
29
- function getClientRectFromMixedType(element, clippingParent, strategy) {
30
- return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element)));
31
- } // A "clipping parent" is an overflowable container with the characteristic of
32
- // clipping (or hiding) overflowing elements with a position different from
33
- // `initial`
34
-
35
-
36
- function getClippingParents(element) {
37
- var clippingParents = listScrollParents(getParentNode(element));
38
- var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle(element).position) >= 0;
39
- var clipperElement = canEscapeClipping && isHTMLElement(element) ? getOffsetParent(element) : element;
40
-
41
- if (!isElement(clipperElement)) {
42
- return [];
43
- } // $FlowFixMe[incompatible-return]: https://github.com/facebook/flow/issues/1414
44
-
45
-
46
- return clippingParents.filter(function (clippingParent) {
47
- return isElement(clippingParent) && contains(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body';
48
- });
49
- } // Gets the maximum area that the element is visible in due to any number of
50
- // clipping parents
51
-
52
-
53
- function getClippingRect(element, boundary, rootBoundary, strategy) {
54
- var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary);
55
- var clippingParents = [].concat(mainClippingParents, [rootBoundary]);
56
- var firstClippingParent = clippingParents[0];
57
- var clippingRect = clippingParents.reduce(function (accRect, clippingParent) {
58
- var rect = getClientRectFromMixedType(element, clippingParent, strategy);
59
- accRect.top = max(rect.top, accRect.top);
60
- accRect.right = min(rect.right, accRect.right);
61
- accRect.bottom = min(rect.bottom, accRect.bottom);
62
- accRect.left = max(rect.left, accRect.left);
63
- return accRect;
64
- }, getClientRectFromMixedType(element, firstClippingParent, strategy));
65
- clippingRect.width = clippingRect.right - clippingRect.left;
66
- clippingRect.height = clippingRect.bottom - clippingRect.top;
67
- clippingRect.x = clippingRect.left;
68
- clippingRect.y = clippingRect.top;
69
- return clippingRect;
70
- }
71
-
72
- export { getClippingRect as default };
@@ -1,60 +0,0 @@
1
- import getBoundingClientRect from './getBoundingClientRect.mjs';
2
- import getNodeScroll from './getNodeScroll.mjs';
3
- import getNodeName from './getNodeName.mjs';
4
- import { isHTMLElement } from './instanceOf.mjs';
5
- import getWindowScrollBarX from './getWindowScrollBarX.mjs';
6
- import getDocumentElement from './getDocumentElement.mjs';
7
- import isScrollParent from './isScrollParent.mjs';
8
- import { round } from '../utils/math.mjs';
9
-
10
- function isElementScaled(element) {
11
- var rect = element.getBoundingClientRect();
12
- var scaleX = round(rect.width) / element.offsetWidth || 1;
13
- var scaleY = round(rect.height) / element.offsetHeight || 1;
14
- return scaleX !== 1 || scaleY !== 1;
15
- } // Returns the composite rect of an element relative to its offsetParent.
16
- // Composite means it takes into account transforms as well as layout.
17
-
18
-
19
- function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) {
20
- if (isFixed === void 0) {
21
- isFixed = false;
22
- }
23
-
24
- var isOffsetParentAnElement = isHTMLElement(offsetParent);
25
- var offsetParentIsScaled = isHTMLElement(offsetParent) && isElementScaled(offsetParent);
26
- var documentElement = getDocumentElement(offsetParent);
27
- var rect = getBoundingClientRect(elementOrVirtualElement, offsetParentIsScaled, isFixed);
28
- var scroll = {
29
- scrollLeft: 0,
30
- scrollTop: 0
31
- };
32
- var offsets = {
33
- x: 0,
34
- y: 0
35
- };
36
-
37
- if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
38
- if (getNodeName(offsetParent) !== 'body' || // https://github.com/popperjs/popper-core/issues/1078
39
- isScrollParent(documentElement)) {
40
- scroll = getNodeScroll(offsetParent);
41
- }
42
-
43
- if (isHTMLElement(offsetParent)) {
44
- offsets = getBoundingClientRect(offsetParent, true);
45
- offsets.x += offsetParent.clientLeft;
46
- offsets.y += offsetParent.clientTop;
47
- } else if (documentElement) {
48
- offsets.x = getWindowScrollBarX(documentElement);
49
- }
50
- }
51
-
52
- return {
53
- x: rect.left + scroll.scrollLeft - offsets.x,
54
- y: rect.top + scroll.scrollTop - offsets.y,
55
- width: rect.width,
56
- height: rect.height
57
- };
58
- }
59
-
60
- export { getCompositeRect as default };
@@ -1,7 +0,0 @@
1
- import getWindow from './getWindow.mjs';
2
-
3
- function getComputedStyle(element) {
4
- return getWindow(element).getComputedStyle(element);
5
- }
6
-
7
- export { getComputedStyle as default };
@@ -1,9 +0,0 @@
1
- import { isElement } from './instanceOf.mjs';
2
-
3
- function getDocumentElement(element) {
4
- // $FlowFixMe[incompatible-return]: assume body is always available
5
- return ((isElement(element) ? element.ownerDocument : // $FlowFixMe[prop-missing]
6
- element.document) || window.document).documentElement;
7
- }
8
-
9
- export { getDocumentElement as default };
@@ -1,32 +0,0 @@
1
- import getDocumentElement from './getDocumentElement.mjs';
2
- import getComputedStyle from './getComputedStyle.mjs';
3
- import getWindowScrollBarX from './getWindowScrollBarX.mjs';
4
- import getWindowScroll from './getWindowScroll.mjs';
5
- import { max } from '../utils/math.mjs';
6
-
7
- // of the `<html>` and `<body>` rect bounds if horizontally scrollable
8
-
9
- function getDocumentRect(element) {
10
- var _element$ownerDocumen;
11
-
12
- var html = getDocumentElement(element);
13
- var winScroll = getWindowScroll(element);
14
- var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
15
- var width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
16
- var height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
17
- var x = -winScroll.scrollLeft + getWindowScrollBarX(element);
18
- var y = -winScroll.scrollTop;
19
-
20
- if (getComputedStyle(body || html).direction === 'rtl') {
21
- x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
22
- }
23
-
24
- return {
25
- width: width,
26
- height: height,
27
- x: x,
28
- y: y
29
- };
30
- }
31
-
32
- export { getDocumentRect as default };
@@ -1,8 +0,0 @@
1
- function getHTMLElementScroll(element) {
2
- return {
3
- scrollLeft: element.scrollLeft,
4
- scrollTop: element.scrollTop
5
- };
6
- }
7
-
8
- export { getHTMLElementScroll as default };
@@ -1,28 +0,0 @@
1
- import getBoundingClientRect from './getBoundingClientRect.mjs';
2
-
3
- // means it doesn't take into account transforms.
4
-
5
- function getLayoutRect(element) {
6
- var clientRect = getBoundingClientRect(element); // Use the clientRect sizes if it's not been transformed.
7
- // Fixes https://github.com/popperjs/popper-core/issues/1223
8
-
9
- var width = element.offsetWidth;
10
- var height = element.offsetHeight;
11
-
12
- if (Math.abs(clientRect.width - width) <= 1) {
13
- width = clientRect.width;
14
- }
15
-
16
- if (Math.abs(clientRect.height - height) <= 1) {
17
- height = clientRect.height;
18
- }
19
-
20
- return {
21
- x: element.offsetLeft,
22
- y: element.offsetTop,
23
- width: width,
24
- height: height
25
- };
26
- }
27
-
28
- export { getLayoutRect as default };
@@ -1,5 +0,0 @@
1
- function getNodeName(element) {
2
- return element ? (element.nodeName || '').toLowerCase() : null;
3
- }
4
-
5
- export { getNodeName as default };
@@ -1,14 +0,0 @@
1
- import getWindowScroll from './getWindowScroll.mjs';
2
- import getWindow from './getWindow.mjs';
3
- import { isHTMLElement } from './instanceOf.mjs';
4
- import getHTMLElementScroll from './getHTMLElementScroll.mjs';
5
-
6
- function getNodeScroll(node) {
7
- if (node === getWindow(node) || !isHTMLElement(node)) {
8
- return getWindowScroll(node);
9
- } else {
10
- return getHTMLElementScroll(node);
11
- }
12
- }
13
-
14
- export { getNodeScroll as default };
@@ -1,71 +0,0 @@
1
- import getWindow from './getWindow.mjs';
2
- import getNodeName from './getNodeName.mjs';
3
- import getComputedStyle from './getComputedStyle.mjs';
4
- import { isHTMLElement, isShadowRoot } from './instanceOf.mjs';
5
- import isTableElement from './isTableElement.mjs';
6
- import getParentNode from './getParentNode.mjs';
7
- import getUAString from '../utils/userAgent.mjs';
8
-
9
- function getTrueOffsetParent(element) {
10
- if (!isHTMLElement(element) || // https://github.com/popperjs/popper-core/issues/837
11
- getComputedStyle(element).position === 'fixed') {
12
- return null;
13
- }
14
-
15
- return element.offsetParent;
16
- } // `.offsetParent` reports `null` for fixed elements, while absolute elements
17
- // return the containing block
18
-
19
-
20
- function getContainingBlock(element) {
21
- var isFirefox = /firefox/i.test(getUAString());
22
- var isIE = /Trident/i.test(getUAString());
23
-
24
- if (isIE && isHTMLElement(element)) {
25
- // In IE 9, 10 and 11 fixed elements containing block is always established by the viewport
26
- var elementCss = getComputedStyle(element);
27
-
28
- if (elementCss.position === 'fixed') {
29
- return null;
30
- }
31
- }
32
-
33
- var currentNode = getParentNode(element);
34
-
35
- if (isShadowRoot(currentNode)) {
36
- currentNode = currentNode.host;
37
- }
38
-
39
- while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {
40
- var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that
41
- // create a containing block.
42
- // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
43
-
44
- if (css.transform !== 'none' || css.perspective !== 'none' || css.contain === 'paint' || ['transform', 'perspective'].indexOf(css.willChange) !== -1 || isFirefox && css.willChange === 'filter' || isFirefox && css.filter && css.filter !== 'none') {
45
- return currentNode;
46
- } else {
47
- currentNode = currentNode.parentNode;
48
- }
49
- }
50
-
51
- return null;
52
- } // Gets the closest ancestor positioned element. Handles some edge cases,
53
- // such as table ancestors and cross browser bugs.
54
-
55
-
56
- function getOffsetParent(element) {
57
- var window = getWindow(element);
58
- var offsetParent = getTrueOffsetParent(element);
59
-
60
- while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {
61
- offsetParent = getTrueOffsetParent(offsetParent);
62
- }
63
-
64
- if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static')) {
65
- return window;
66
- }
67
-
68
- return offsetParent || getContainingBlock(element) || window;
69
- }
70
-
71
- export { getOffsetParent as default };
@@ -1,22 +0,0 @@
1
- import getNodeName from './getNodeName.mjs';
2
- import getDocumentElement from './getDocumentElement.mjs';
3
- import { isShadowRoot } from './instanceOf.mjs';
4
-
5
- function getParentNode(element) {
6
- if (getNodeName(element) === 'html') {
7
- return element;
8
- }
9
-
10
- return (// this is a quicker (but less type safe) way to save quite some bytes from the bundle
11
- // $FlowFixMe[incompatible-return]
12
- // $FlowFixMe[prop-missing]
13
- element.assignedSlot || // step into the shadow DOM of the parent of a slotted node
14
- element.parentNode || ( // DOM Element detected
15
- isShadowRoot(element) ? element.host : null) || // ShadowRoot detected
16
- // $FlowFixMe[incompatible-call]: HTMLElement is a Node
17
- getDocumentElement(element) // fallback
18
-
19
- );
20
- }
21
-
22
- export { getParentNode as default };