@ddd-tool/domain-designer-cli 0.1.0-beta.9 → 0.3.1

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 (107) hide show
  1. package/README.md +12 -20
  2. package/bin/domain-designer-cli.cjs +19148 -18666
  3. package/package.json +42 -23
  4. package/packages/core/dist/README.md +43 -0
  5. package/packages/core/dist/actor.d.ts +2 -0
  6. package/packages/core/dist/agg.d.ts +2 -0
  7. package/packages/core/dist/command.d.ts +3 -0
  8. package/packages/core/dist/common.d.ts +158 -0
  9. package/packages/core/dist/event.d.ts +2 -0
  10. package/packages/core/dist/index.d.ts +33 -0
  11. package/packages/core/dist/index.js +1980 -0
  12. package/packages/core/dist/info.d.ts +2 -0
  13. package/packages/core/dist/note.d.ts +2 -0
  14. package/packages/core/dist/package.json +21 -0
  15. package/packages/core/dist/policy.d.ts +2 -0
  16. package/packages/core/dist/read-model.d.ts +2 -0
  17. package/packages/core/dist/service.d.ts +2 -0
  18. package/packages/core/dist/system.d.ts +2 -0
  19. package/packages/core/dist/types.d.ts +558 -0
  20. package/packages/playground/.env +1 -0
  21. package/packages/playground/node_modules/.vite/deps/_metadata.json +34 -0
  22. package/packages/playground/node_modules/.vite/deps/chunk-F4TQRHS6.js +2147 -0
  23. package/packages/playground/node_modules/.vite/deps/chunk-F4TQRHS6.js.map +7 -0
  24. package/packages/playground/node_modules/.vite/deps/chunk-MFAKUPMY.js +12787 -0
  25. package/packages/playground/node_modules/.vite/deps/chunk-MFAKUPMY.js.map +7 -0
  26. package/packages/playground/node_modules/.vite/deps/package.json +3 -0
  27. package/packages/playground/node_modules/.vite/deps/primevue_button.js +1215 -0
  28. package/packages/playground/node_modules/.vite/deps/primevue_button.js.map +7 -0
  29. package/packages/playground/node_modules/.vite/deps/primevue_dock.js +1236 -0
  30. package/packages/playground/node_modules/.vite/deps/primevue_dock.js.map +7 -0
  31. package/packages/playground/node_modules/.vite/deps/vue.js +346 -0
  32. package/packages/playground/node_modules/.vite/deps/vue.js.map +7 -0
  33. package/packages/playground/node_modules/.vue-global-types/vue_3.5_0.d.ts +136 -0
  34. package/packages/playground/package.json +19 -0
  35. package/{src → packages/playground/src}/App.vue +12 -12
  36. package/{src → packages/playground/src}/main.ts +27 -27
  37. package/{src → packages/playground/src}/views/Index.vue +16 -16
  38. package/packages/playground/src/views/complex-example-detail/book.ts +383 -0
  39. package/packages/playground/src/views/complex-example-detail/common.ts +4 -0
  40. package/packages/playground/src/views/complex-example-detail/user.ts +66 -0
  41. package/packages/playground/src/views/complex-example.ts +4 -0
  42. package/{src → packages/playground/src}/views/design-en.ts +110 -99
  43. package/{src → packages/playground/src}/views/design-zh.ts +97 -91
  44. package/packages/playground/src/views/index.ts +19 -0
  45. package/packages/playground/src/views/simple-example.ts +103 -0
  46. package/packages/playground/tsconfig.json +32 -0
  47. package/packages/playground/vite-env.d.ts +12 -0
  48. package/packages/playground/vite.config.ts +22 -0
  49. package/packages/ui-component/dist/LICENSE +201 -0
  50. package/packages/ui-component/dist/README.md +5 -0
  51. package/packages/ui-component/dist/UI.vue.d.ts +29 -0
  52. package/packages/ui-component/dist/common.d.ts +9 -0
  53. package/packages/ui-component/dist/components/drag-zoom/Index.vue.d.ts +37 -0
  54. package/packages/ui-component/dist/components/node-info/Index.vue.d.ts +29 -0
  55. package/packages/ui-component/dist/components/nomnoml/Index.vue.d.ts +24 -0
  56. package/packages/ui-component/dist/components/nomnoml/base-style.d.ts +2 -0
  57. package/packages/ui-component/dist/components/nomnoml/preprocess.d.ts +5 -0
  58. package/packages/ui-component/dist/components/story-bar/Index.vue.d.ts +28 -0
  59. package/packages/ui-component/dist/components/tool-bar/Index.vue.d.ts +29 -0
  60. package/packages/ui-component/dist/domain/common.d.ts +27 -0
  61. package/packages/ui-component/dist/domain/diagram-agg/gen-code.d.ts +64 -0
  62. package/packages/ui-component/dist/domain/diagram-agg/index.d.ts +8554 -0
  63. package/packages/ui-component/dist/domain/diagram-agg/plugins.d.ts +80 -0
  64. package/packages/ui-component/dist/domain/diagram-agg/types.d.ts +20 -0
  65. package/packages/ui-component/dist/domain/i18n-agg/index.d.ts +25 -0
  66. package/packages/ui-component/dist/domain/i18n-agg/locale/en-US.d.ts +3 -0
  67. package/packages/ui-component/dist/domain/i18n-agg/locale/zh-CN.d.ts +3 -0
  68. package/packages/ui-component/dist/domain/i18n-agg/message.d.ts +42 -0
  69. package/packages/ui-component/dist/domain/mount-plugin.d.ts +1 -0
  70. package/packages/ui-component/dist/favicon.ico +0 -0
  71. package/packages/ui-component/dist/index.css +144 -0
  72. package/packages/ui-component/dist/index.d.ts +6 -0
  73. package/packages/ui-component/dist/index.js +19776 -0
  74. package/packages/ui-component/dist/package.json +28 -0
  75. package/packages/ui-component/dist/ui.d.ts +8 -0
  76. package/scripts/ai-assist-worker.cjs +7123 -0
  77. package/scripts/sync-version.mjs +22 -0
  78. package/templates/CLAUDE.md +276 -0
  79. package/templates/README.md +97 -0
  80. package/templates/complex-example-detail/book.ts +383 -0
  81. package/templates/complex-example-detail/common.ts +4 -0
  82. package/templates/complex-example-detail/user.ts +66 -0
  83. package/templates/complex-example.ts +4 -0
  84. package/templates/node_modules/@ddd-tool/domain-designer-core/actor.d.ts +1 -1
  85. package/templates/node_modules/@ddd-tool/domain-designer-core/agg.d.ts +1 -1
  86. package/templates/node_modules/@ddd-tool/domain-designer-core/command.d.ts +1 -1
  87. package/templates/node_modules/@ddd-tool/domain-designer-core/common.d.ts +7 -8
  88. package/templates/node_modules/@ddd-tool/domain-designer-core/event.d.ts +1 -1
  89. package/templates/node_modules/@ddd-tool/domain-designer-core/index.d.ts +3 -3
  90. package/templates/node_modules/@ddd-tool/domain-designer-core/info.d.ts +1 -1
  91. package/templates/node_modules/@ddd-tool/domain-designer-core/note.d.ts +1 -1
  92. package/templates/node_modules/@ddd-tool/domain-designer-core/policy.d.ts +1 -1
  93. package/templates/node_modules/@ddd-tool/domain-designer-core/read-model.d.ts +1 -1
  94. package/templates/node_modules/@ddd-tool/domain-designer-core/service.d.ts +1 -1
  95. package/templates/node_modules/@ddd-tool/domain-designer-core/system.d.ts +1 -1
  96. package/templates/node_modules/@ddd-tool/domain-designer-core/{define.d.ts → types.d.ts} +23 -4
  97. package/templates/node_modules/version.txt +1 -1
  98. package/templates/simple-example.ts +103 -0
  99. package/tsconfig.json +19 -6
  100. package/scripts/sync-ver.mjs +0 -0
  101. package/src/views/index.ts +0 -15
  102. package/templates/example-agg.ts +0 -31
  103. package/templates/example.ts +0 -91
  104. package/vite.config.ts +0 -16
  105. /package/{index.html → packages/playground/index.html} +0 -0
  106. /package/{src → packages/playground/src}/assets/logo.svg +0 -0
  107. /package/{src → packages/playground/src}/assets/main.css +0 -0
@@ -0,0 +1,1236 @@
1
+ import {
2
+ $,
3
+ At,
4
+ BaseDirective,
5
+ BaseStyle,
6
+ C,
7
+ P,
8
+ Q,
9
+ R,
10
+ Ripple,
11
+ T,
12
+ U,
13
+ W,
14
+ Y,
15
+ Yt,
16
+ h,
17
+ ht,
18
+ k,
19
+ l,
20
+ m,
21
+ s,
22
+ s2,
23
+ script,
24
+ v,
25
+ x,
26
+ z
27
+ } from "./chunk-F4TQRHS6.js";
28
+ import {
29
+ Fragment,
30
+ createBaseVNode,
31
+ createBlock,
32
+ createElementBlock,
33
+ createVNode,
34
+ mergeProps,
35
+ normalizeClass,
36
+ openBlock,
37
+ renderList,
38
+ resolveComponent,
39
+ resolveDirective,
40
+ resolveDynamicComponent,
41
+ withDirectives
42
+ } from "./chunk-MFAKUPMY.js";
43
+
44
+ // ../../node_modules/@primeuix/styles/dist/dock/index.mjs
45
+ var style = "\n .p-dock {\n position: absolute;\n z-index: 1;\n display: flex;\n justify-content: center;\n align-items: center;\n pointer-events: none;\n }\n\n .p-dock-list-container {\n display: flex;\n pointer-events: auto;\n background: dt('dock.background');\n border: 1px solid dt('dock.border.color');\n padding: dt('dock.padding');\n border-radius: dt('dock.border.radius');\n }\n\n .p-dock-list {\n margin: 0;\n padding: 0;\n list-style: none;\n display: flex;\n align-items: center;\n justify-content: center;\n outline: 0 none;\n }\n\n .p-dock-item {\n transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);\n will-change: transform;\n padding: dt('dock.item.padding');\n border-radius: dt('dock.item.border.radius');\n }\n\n .p-dock-item.p-focus {\n box-shadow: dt('dock.item.focus.ring.shadow');\n outline: dt('dock.item.focus.ring.width') dt('dock.item.focus.ring.style') dt('dock.item.focus.ring.color');\n outline-offset: dt('dock.item.focus.ring.offset');\n }\n\n .p-dock-item-link {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n position: relative;\n overflow: hidden;\n cursor: default;\n width: dt('dock.item.size');\n height: dt('dock.item.size');\n }\n\n .p-dock-top {\n left: 0;\n top: 0;\n width: 100%;\n }\n\n .p-dock-bottom {\n left: 0;\n bottom: 0;\n width: 100%;\n }\n\n .p-dock-right {\n right: 0;\n top: 0;\n height: 100%;\n }\n\n .p-dock-right .p-dock-list {\n flex-direction: column;\n }\n\n .p-dock-left {\n left: 0;\n top: 0;\n height: 100%;\n }\n\n .p-dock-left .p-dock-list {\n flex-direction: column;\n }\n\n .p-dock-mobile.p-dock-top .p-dock-list-container,\n .p-dock-mobile.p-dock-bottom .p-dock-list-container {\n overflow-x: auto;\n width: 100%;\n }\n\n .p-dock-mobile.p-dock-top .p-dock-list-container .p-dock-list,\n .p-dock-mobile.p-dock-bottom .p-dock-list-container .p-dock-list {\n margin: 0 auto;\n }\n\n .p-dock-mobile.p-dock-left .p-dock-list-container,\n .p-dock-mobile.p-dock-right .p-dock-list-container {\n overflow-y: auto;\n height: 100%;\n }\n\n .p-dock-mobile.p-dock-left .p-dock-list-container .p-dock-list,\n .p-dock-mobile.p-dock-right .p-dock-list-container .p-dock-list {\n margin: auto 0;\n }\n\n .p-dock-mobile .p-dock-list .p-dock-item {\n transform: none;\n margin: 0;\n }\n";
46
+
47
+ // ../../node_modules/primevue/dock/style/index.mjs
48
+ var classes = {
49
+ root: function root(_ref) {
50
+ var instance = _ref.instance, props = _ref.props;
51
+ return ["p-dock p-component", "p-dock-".concat(props.position), {
52
+ "p-dock-mobile": instance.queryMatches
53
+ }];
54
+ },
55
+ listContainer: "p-dock-list-container",
56
+ list: "p-dock-list",
57
+ item: function item(_ref2) {
58
+ var instance = _ref2.instance, processedItem = _ref2.processedItem, id = _ref2.id;
59
+ return ["p-dock-item", {
60
+ "p-focus": instance.isItemActive(id),
61
+ "p-disabled": instance.disabled(processedItem)
62
+ }];
63
+ },
64
+ itemContent: "p-dock-item-content",
65
+ itemLink: "p-dock-item-link",
66
+ itemIcon: "p-dock-item-icon"
67
+ };
68
+ var DockStyle = BaseStyle.extend({
69
+ name: "dock",
70
+ style,
71
+ classes
72
+ });
73
+
74
+ // ../../node_modules/@primevue/core/utils/index.mjs
75
+ function _typeof$1(o) {
76
+ "@babel/helpers - typeof";
77
+ return _typeof$1 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o2) {
78
+ return typeof o2;
79
+ } : function(o2) {
80
+ return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
81
+ }, _typeof$1(o);
82
+ }
83
+ function _classCallCheck$1(a, n) {
84
+ if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
85
+ }
86
+ function _defineProperties$1(e, r) {
87
+ for (var t = 0; t < r.length; t++) {
88
+ var o = r[t];
89
+ o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(e, _toPropertyKey$1(o.key), o);
90
+ }
91
+ }
92
+ function _createClass$1(e, r, t) {
93
+ return r && _defineProperties$1(e.prototype, r), Object.defineProperty(e, "prototype", { writable: false }), e;
94
+ }
95
+ function _toPropertyKey$1(t) {
96
+ var i = _toPrimitive$1(t, "string");
97
+ return "symbol" == _typeof$1(i) ? i : i + "";
98
+ }
99
+ function _toPrimitive$1(t, r) {
100
+ if ("object" != _typeof$1(t) || !t) return t;
101
+ var e = t[Symbol.toPrimitive];
102
+ if (void 0 !== e) {
103
+ var i = e.call(t, r);
104
+ if ("object" != _typeof$1(i)) return i;
105
+ throw new TypeError("@@toPrimitive must return a primitive value.");
106
+ }
107
+ return String(t);
108
+ }
109
+ var ConnectedOverlayScrollHandler = (function() {
110
+ function ConnectedOverlayScrollHandler2(element) {
111
+ var listener = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : function() {
112
+ };
113
+ _classCallCheck$1(this, ConnectedOverlayScrollHandler2);
114
+ this.element = element;
115
+ this.listener = listener;
116
+ }
117
+ return _createClass$1(ConnectedOverlayScrollHandler2, [{
118
+ key: "bindScrollListener",
119
+ value: function bindScrollListener2() {
120
+ this.scrollableParents = At(this.element);
121
+ for (var i = 0; i < this.scrollableParents.length; i++) {
122
+ this.scrollableParents[i].addEventListener("scroll", this.listener);
123
+ }
124
+ }
125
+ }, {
126
+ key: "unbindScrollListener",
127
+ value: function unbindScrollListener2() {
128
+ if (this.scrollableParents) {
129
+ for (var i = 0; i < this.scrollableParents.length; i++) {
130
+ this.scrollableParents[i].removeEventListener("scroll", this.listener);
131
+ }
132
+ }
133
+ }
134
+ }, {
135
+ key: "destroy",
136
+ value: function destroy() {
137
+ this.unbindScrollListener();
138
+ this.element = null;
139
+ this.listener = null;
140
+ this.scrollableParents = null;
141
+ }
142
+ }]);
143
+ })();
144
+ function _typeof(o) {
145
+ "@babel/helpers - typeof";
146
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o2) {
147
+ return typeof o2;
148
+ } : function(o2) {
149
+ return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
150
+ }, _typeof(o);
151
+ }
152
+ function _toConsumableArray(r) {
153
+ return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread();
154
+ }
155
+ function _nonIterableSpread() {
156
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
157
+ }
158
+ function _unsupportedIterableToArray(r, a) {
159
+ if (r) {
160
+ if ("string" == typeof r) return _arrayLikeToArray(r, a);
161
+ var t = {}.toString.call(r).slice(8, -1);
162
+ 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;
163
+ }
164
+ }
165
+ function _iterableToArray(r) {
166
+ if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r);
167
+ }
168
+ function _arrayWithoutHoles(r) {
169
+ if (Array.isArray(r)) return _arrayLikeToArray(r);
170
+ }
171
+ function _arrayLikeToArray(r, a) {
172
+ (null == a || a > r.length) && (a = r.length);
173
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
174
+ return n;
175
+ }
176
+ function _classCallCheck(a, n) {
177
+ if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
178
+ }
179
+ function _defineProperties(e, r) {
180
+ for (var t = 0; t < r.length; t++) {
181
+ var o = r[t];
182
+ o.enumerable = o.enumerable || false, o.configurable = true, "value" in o && (o.writable = true), Object.defineProperty(e, _toPropertyKey(o.key), o);
183
+ }
184
+ }
185
+ function _createClass(e, r, t) {
186
+ return r && _defineProperties(e.prototype, r), Object.defineProperty(e, "prototype", { writable: false }), e;
187
+ }
188
+ function _defineProperty(e, r, t) {
189
+ return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
190
+ }
191
+ function _toPropertyKey(t) {
192
+ var i = _toPrimitive(t, "string");
193
+ return "symbol" == _typeof(i) ? i : i + "";
194
+ }
195
+ function _toPrimitive(t, r) {
196
+ if ("object" != _typeof(t) || !t) return t;
197
+ var e = t[Symbol.toPrimitive];
198
+ if (void 0 !== e) {
199
+ var i = e.call(t, r);
200
+ if ("object" != _typeof(i)) return i;
201
+ throw new TypeError("@@toPrimitive must return a primitive value.");
202
+ }
203
+ return String(t);
204
+ }
205
+ var _default = (function() {
206
+ function _default2(_ref) {
207
+ var init = _ref.init, type = _ref.type;
208
+ _classCallCheck(this, _default2);
209
+ _defineProperty(this, "helpers", void 0);
210
+ _defineProperty(this, "type", void 0);
211
+ this.helpers = new Set(init);
212
+ this.type = type;
213
+ }
214
+ return _createClass(_default2, [{
215
+ key: "add",
216
+ value: function add(instance) {
217
+ this.helpers.add(instance);
218
+ }
219
+ }, {
220
+ key: "update",
221
+ value: function update() {
222
+ }
223
+ }, {
224
+ key: "delete",
225
+ value: function _delete(instance) {
226
+ this.helpers["delete"](instance);
227
+ }
228
+ }, {
229
+ key: "clear",
230
+ value: function clear() {
231
+ this.helpers.clear();
232
+ }
233
+ }, {
234
+ key: "get",
235
+ value: function get(parentInstance, slots) {
236
+ var children = this._get(parentInstance, slots);
237
+ var computed = children ? this._recursive(_toConsumableArray(this.helpers), children) : null;
238
+ return s(computed) ? computed : null;
239
+ }
240
+ }, {
241
+ key: "_isMatched",
242
+ value: function _isMatched(instance, key) {
243
+ var _parent$vnode;
244
+ var parent = instance === null || instance === void 0 ? void 0 : instance.parent;
245
+ return (parent === null || parent === void 0 || (_parent$vnode = parent.vnode) === null || _parent$vnode === void 0 ? void 0 : _parent$vnode.key) === key || parent && this._isMatched(parent, key) || false;
246
+ }
247
+ }, {
248
+ key: "_get",
249
+ value: function _get(parentInstance, slots) {
250
+ var _ref2, _ref2$default;
251
+ return ((_ref2 = slots || (parentInstance === null || parentInstance === void 0 ? void 0 : parentInstance.$slots)) === null || _ref2 === void 0 || (_ref2$default = _ref2["default"]) === null || _ref2$default === void 0 ? void 0 : _ref2$default.call(_ref2)) || null;
252
+ }
253
+ }, {
254
+ key: "_recursive",
255
+ value: function _recursive() {
256
+ var _this = this;
257
+ var helpers = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [];
258
+ var children = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
259
+ var components = [];
260
+ children.forEach(function(child) {
261
+ if (child.children instanceof Array) {
262
+ components = components.concat(_this._recursive(helpers, child.children));
263
+ } else if (child.type.name === _this.type) {
264
+ components.push(child);
265
+ } else if (s(child.key)) {
266
+ components = components.concat(helpers.filter(function(c) {
267
+ return _this._isMatched(c, child.key);
268
+ }).map(function(c) {
269
+ return c.vnode;
270
+ }));
271
+ }
272
+ });
273
+ return components;
274
+ }
275
+ }]);
276
+ })();
277
+
278
+ // ../../node_modules/@primeuix/styles/dist/tooltip/index.mjs
279
+ var style2 = "\n .p-tooltip {\n position: absolute;\n display: none;\n max-width: dt('tooltip.max.width');\n }\n\n .p-tooltip-right,\n .p-tooltip-left {\n padding: 0 dt('tooltip.gutter');\n }\n\n .p-tooltip-top,\n .p-tooltip-bottom {\n padding: dt('tooltip.gutter') 0;\n }\n\n .p-tooltip-text {\n white-space: pre-line;\n word-break: break-word;\n background: dt('tooltip.background');\n color: dt('tooltip.color');\n padding: dt('tooltip.padding');\n box-shadow: dt('tooltip.shadow');\n border-radius: dt('tooltip.border.radius');\n }\n\n .p-tooltip-arrow {\n position: absolute;\n width: 0;\n height: 0;\n border-color: transparent;\n border-style: solid;\n }\n\n .p-tooltip-right .p-tooltip-arrow {\n margin-top: calc(-1 * dt('tooltip.gutter'));\n border-width: dt('tooltip.gutter') dt('tooltip.gutter') dt('tooltip.gutter') 0;\n border-right-color: dt('tooltip.background');\n }\n\n .p-tooltip-left .p-tooltip-arrow {\n margin-top: calc(-1 * dt('tooltip.gutter'));\n border-width: dt('tooltip.gutter') 0 dt('tooltip.gutter') dt('tooltip.gutter');\n border-left-color: dt('tooltip.background');\n }\n\n .p-tooltip-top .p-tooltip-arrow {\n margin-left: calc(-1 * dt('tooltip.gutter'));\n border-width: dt('tooltip.gutter') dt('tooltip.gutter') 0 dt('tooltip.gutter');\n border-top-color: dt('tooltip.background');\n border-bottom-color: dt('tooltip.background');\n }\n\n .p-tooltip-bottom .p-tooltip-arrow {\n margin-left: calc(-1 * dt('tooltip.gutter'));\n border-width: 0 dt('tooltip.gutter') dt('tooltip.gutter') dt('tooltip.gutter');\n border-top-color: dt('tooltip.background');\n border-bottom-color: dt('tooltip.background');\n }\n";
280
+
281
+ // ../../node_modules/primevue/tooltip/style/index.mjs
282
+ var classes2 = {
283
+ root: "p-tooltip p-component",
284
+ arrow: "p-tooltip-arrow",
285
+ text: "p-tooltip-text"
286
+ };
287
+ var TooltipStyle = BaseStyle.extend({
288
+ name: "tooltip-directive",
289
+ style: style2,
290
+ classes: classes2
291
+ });
292
+
293
+ // ../../node_modules/primevue/tooltip/index.mjs
294
+ var BaseTooltip = BaseDirective.extend({
295
+ style: TooltipStyle
296
+ });
297
+ function _slicedToArray(r, e) {
298
+ return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray2(r, e) || _nonIterableRest();
299
+ }
300
+ function _nonIterableRest() {
301
+ throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
302
+ }
303
+ function _unsupportedIterableToArray2(r, a) {
304
+ if (r) {
305
+ if ("string" == typeof r) return _arrayLikeToArray2(r, a);
306
+ var t = {}.toString.call(r).slice(8, -1);
307
+ 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) ? _arrayLikeToArray2(r, a) : void 0;
308
+ }
309
+ }
310
+ function _arrayLikeToArray2(r, a) {
311
+ (null == a || a > r.length) && (a = r.length);
312
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
313
+ return n;
314
+ }
315
+ function _iterableToArrayLimit(r, l2) {
316
+ var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
317
+ if (null != t) {
318
+ var e, n, i, u, a = [], f = true, o = false;
319
+ try {
320
+ if (i = (t = t.call(r)).next, 0 === l2) ;
321
+ else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l2); f = true) ;
322
+ } catch (r2) {
323
+ o = true, n = r2;
324
+ } finally {
325
+ try {
326
+ if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return;
327
+ } finally {
328
+ if (o) throw n;
329
+ }
330
+ }
331
+ return a;
332
+ }
333
+ }
334
+ function _arrayWithHoles(r) {
335
+ if (Array.isArray(r)) return r;
336
+ }
337
+ function _defineProperty2(e, r, t) {
338
+ return (r = _toPropertyKey2(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: true, configurable: true, writable: true }) : e[r] = t, e;
339
+ }
340
+ function _toPropertyKey2(t) {
341
+ var i = _toPrimitive2(t, "string");
342
+ return "symbol" == _typeof2(i) ? i : i + "";
343
+ }
344
+ function _toPrimitive2(t, r) {
345
+ if ("object" != _typeof2(t) || !t) return t;
346
+ var e = t[Symbol.toPrimitive];
347
+ if (void 0 !== e) {
348
+ var i = e.call(t, r);
349
+ if ("object" != _typeof2(i)) return i;
350
+ throw new TypeError("@@toPrimitive must return a primitive value.");
351
+ }
352
+ return ("string" === r ? String : Number)(t);
353
+ }
354
+ function _typeof2(o) {
355
+ "@babel/helpers - typeof";
356
+ return _typeof2 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o2) {
357
+ return typeof o2;
358
+ } : function(o2) {
359
+ return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
360
+ }, _typeof2(o);
361
+ }
362
+ var Tooltip = BaseTooltip.extend("tooltip", {
363
+ beforeMount: function beforeMount(el, options) {
364
+ var _options$instance$$pr;
365
+ var target = this.getTarget(el);
366
+ target.$_ptooltipModifiers = this.getModifiers(options);
367
+ if (!options.value) return;
368
+ else if (typeof options.value === "string") {
369
+ target.$_ptooltipValue = options.value;
370
+ target.$_ptooltipDisabled = false;
371
+ target.$_ptooltipEscape = true;
372
+ target.$_ptooltipClass = null;
373
+ target.$_ptooltipFitContent = true;
374
+ target.$_ptooltipIdAttr = s2("pv_id") + "_tooltip";
375
+ target.$_ptooltipShowDelay = 0;
376
+ target.$_ptooltipHideDelay = 0;
377
+ target.$_ptooltipAutoHide = true;
378
+ } else if (_typeof2(options.value) === "object" && options.value) {
379
+ if (l(options.value.value) || options.value.value.trim() === "") return;
380
+ else {
381
+ target.$_ptooltipValue = options.value.value;
382
+ target.$_ptooltipDisabled = !!options.value.disabled === options.value.disabled ? options.value.disabled : false;
383
+ target.$_ptooltipEscape = !!options.value.escape === options.value.escape ? options.value.escape : true;
384
+ target.$_ptooltipClass = options.value["class"] || "";
385
+ target.$_ptooltipFitContent = !!options.value.fitContent === options.value.fitContent ? options.value.fitContent : true;
386
+ target.$_ptooltipIdAttr = options.value.id || s2("pv_id") + "_tooltip";
387
+ target.$_ptooltipShowDelay = options.value.showDelay || 0;
388
+ target.$_ptooltipHideDelay = options.value.hideDelay || 0;
389
+ target.$_ptooltipAutoHide = !!options.value.autoHide === options.value.autoHide ? options.value.autoHide : true;
390
+ }
391
+ }
392
+ target.$_ptooltipZIndex = (_options$instance$$pr = options.instance.$primevue) === null || _options$instance$$pr === void 0 || (_options$instance$$pr = _options$instance$$pr.config) === null || _options$instance$$pr === void 0 || (_options$instance$$pr = _options$instance$$pr.zIndex) === null || _options$instance$$pr === void 0 ? void 0 : _options$instance$$pr.tooltip;
393
+ this.bindEvents(target, options);
394
+ el.setAttribute("data-pd-tooltip", true);
395
+ },
396
+ updated: function updated(el, options) {
397
+ var target = this.getTarget(el);
398
+ target.$_ptooltipModifiers = this.getModifiers(options);
399
+ this.unbindEvents(target);
400
+ if (!options.value) {
401
+ return;
402
+ }
403
+ if (typeof options.value === "string") {
404
+ target.$_ptooltipValue = options.value;
405
+ target.$_ptooltipDisabled = false;
406
+ target.$_ptooltipEscape = true;
407
+ target.$_ptooltipClass = null;
408
+ target.$_ptooltipIdAttr = target.$_ptooltipIdAttr || s2("pv_id") + "_tooltip";
409
+ target.$_ptooltipShowDelay = 0;
410
+ target.$_ptooltipHideDelay = 0;
411
+ target.$_ptooltipAutoHide = true;
412
+ this.bindEvents(target, options);
413
+ } else if (_typeof2(options.value) === "object" && options.value) {
414
+ if (l(options.value.value) || options.value.value.trim() === "") {
415
+ this.unbindEvents(target, options);
416
+ return;
417
+ } else {
418
+ target.$_ptooltipValue = options.value.value;
419
+ target.$_ptooltipDisabled = !!options.value.disabled === options.value.disabled ? options.value.disabled : false;
420
+ target.$_ptooltipEscape = !!options.value.escape === options.value.escape ? options.value.escape : true;
421
+ target.$_ptooltipClass = options.value["class"] || "";
422
+ target.$_ptooltipFitContent = !!options.value.fitContent === options.value.fitContent ? options.value.fitContent : true;
423
+ target.$_ptooltipIdAttr = options.value.id || target.$_ptooltipIdAttr || s2("pv_id") + "_tooltip";
424
+ target.$_ptooltipShowDelay = options.value.showDelay || 0;
425
+ target.$_ptooltipHideDelay = options.value.hideDelay || 0;
426
+ target.$_ptooltipAutoHide = !!options.value.autoHide === options.value.autoHide ? options.value.autoHide : true;
427
+ this.bindEvents(target, options);
428
+ }
429
+ }
430
+ },
431
+ unmounted: function unmounted(el, options) {
432
+ var target = this.getTarget(el);
433
+ this.hide(el, 0);
434
+ this.remove(target);
435
+ this.unbindEvents(target, options);
436
+ if (target.$_ptooltipScrollHandler) {
437
+ target.$_ptooltipScrollHandler.destroy();
438
+ target.$_ptooltipScrollHandler = null;
439
+ }
440
+ },
441
+ timer: void 0,
442
+ methods: {
443
+ bindEvents: function bindEvents(el, options) {
444
+ var _this = this;
445
+ var modifiers = el.$_ptooltipModifiers;
446
+ if (modifiers.focus) {
447
+ el.$_ptooltipFocusEvent = function(event) {
448
+ return _this.onFocus(event, options);
449
+ };
450
+ el.$_ptooltipBlurEvent = this.onBlur.bind(this);
451
+ el.addEventListener("focus", el.$_ptooltipFocusEvent);
452
+ el.addEventListener("blur", el.$_ptooltipBlurEvent);
453
+ } else {
454
+ el.$_ptooltipMouseEnterEvent = function(event) {
455
+ return _this.onMouseEnter(event, options);
456
+ };
457
+ el.$_ptooltipMouseLeaveEvent = this.onMouseLeave.bind(this);
458
+ el.$_ptooltipClickEvent = this.onClick.bind(this);
459
+ el.addEventListener("mouseenter", el.$_ptooltipMouseEnterEvent);
460
+ el.addEventListener("mouseleave", el.$_ptooltipMouseLeaveEvent);
461
+ el.addEventListener("click", el.$_ptooltipClickEvent);
462
+ }
463
+ el.$_ptooltipKeydownEvent = this.onKeydown.bind(this);
464
+ el.addEventListener("keydown", el.$_ptooltipKeydownEvent);
465
+ el.$_pWindowResizeEvent = this.onWindowResize.bind(this, el);
466
+ },
467
+ unbindEvents: function unbindEvents(el) {
468
+ var modifiers = el.$_ptooltipModifiers;
469
+ if (modifiers.focus) {
470
+ el.removeEventListener("focus", el.$_ptooltipFocusEvent);
471
+ el.$_ptooltipFocusEvent = null;
472
+ el.removeEventListener("blur", el.$_ptooltipBlurEvent);
473
+ el.$_ptooltipBlurEvent = null;
474
+ } else {
475
+ el.removeEventListener("mouseenter", el.$_ptooltipMouseEnterEvent);
476
+ el.$_ptooltipMouseEnterEvent = null;
477
+ el.removeEventListener("mouseleave", el.$_ptooltipMouseLeaveEvent);
478
+ el.$_ptooltipMouseLeaveEvent = null;
479
+ el.removeEventListener("click", el.$_ptooltipClickEvent);
480
+ el.$_ptooltipClickEvent = null;
481
+ }
482
+ el.removeEventListener("keydown", el.$_ptooltipKeydownEvent);
483
+ window.removeEventListener("resize", el.$_pWindowResizeEvent);
484
+ if (el.$_ptooltipId) {
485
+ this.remove(el);
486
+ }
487
+ },
488
+ bindScrollListener: function bindScrollListener(el) {
489
+ var _this2 = this;
490
+ if (!el.$_ptooltipScrollHandler) {
491
+ el.$_ptooltipScrollHandler = new ConnectedOverlayScrollHandler(el, function() {
492
+ _this2.hide(el);
493
+ });
494
+ }
495
+ el.$_ptooltipScrollHandler.bindScrollListener();
496
+ },
497
+ unbindScrollListener: function unbindScrollListener(el) {
498
+ if (el.$_ptooltipScrollHandler) {
499
+ el.$_ptooltipScrollHandler.unbindScrollListener();
500
+ }
501
+ },
502
+ onMouseEnter: function onMouseEnter(event, options) {
503
+ var el = event.currentTarget;
504
+ var showDelay = el.$_ptooltipShowDelay;
505
+ this.show(el, options, showDelay);
506
+ },
507
+ onMouseLeave: function onMouseLeave(event) {
508
+ var el = event.currentTarget;
509
+ var hideDelay = el.$_ptooltipHideDelay;
510
+ var autoHide = el.$_ptooltipAutoHide;
511
+ if (!autoHide) {
512
+ var valid = Q(event.target, "data-pc-name") === "tooltip" || Q(event.target, "data-pc-section") === "arrow" || Q(event.target, "data-pc-section") === "text" || Q(event.relatedTarget, "data-pc-name") === "tooltip" || Q(event.relatedTarget, "data-pc-section") === "arrow" || Q(event.relatedTarget, "data-pc-section") === "text";
513
+ !valid && this.hide(el, hideDelay);
514
+ } else {
515
+ this.hide(el, hideDelay);
516
+ }
517
+ },
518
+ onFocus: function onFocus(event, options) {
519
+ var el = event.currentTarget;
520
+ var showDelay = el.$_ptooltipShowDelay;
521
+ this.show(el, options, showDelay);
522
+ },
523
+ onBlur: function onBlur(event) {
524
+ var el = event.currentTarget;
525
+ var hideDelay = el.$_ptooltipHideDelay;
526
+ this.hide(el, hideDelay);
527
+ },
528
+ onClick: function onClick(event) {
529
+ var el = event.currentTarget;
530
+ var hideDelay = el.$_ptooltipHideDelay;
531
+ this.hide(el, hideDelay);
532
+ },
533
+ onKeydown: function onKeydown(event) {
534
+ var el = event.currentTarget;
535
+ var hideDelay = el.$_ptooltipHideDelay;
536
+ event.code === "Escape" && this.hide(event.currentTarget, hideDelay);
537
+ },
538
+ onWindowResize: function onWindowResize(el) {
539
+ if (!Yt()) {
540
+ this.hide(el);
541
+ }
542
+ window.removeEventListener("resize", el.$_pWindowResizeEvent);
543
+ },
544
+ tooltipActions: function tooltipActions(el, options) {
545
+ if (el.$_ptooltipDisabled || !T(el) || !el.$_ptooltipPendingShow) {
546
+ return;
547
+ }
548
+ el.$_ptooltipPendingShow = false;
549
+ var tooltipElement = this.create(el, options);
550
+ this.align(el);
551
+ !this.isUnstyled() && ht(tooltipElement, 250);
552
+ var $this = this;
553
+ window.addEventListener("resize", el.$_pWindowResizeEvent);
554
+ tooltipElement.addEventListener("mouseleave", function onTooltipLeave() {
555
+ $this.hide(el);
556
+ tooltipElement.removeEventListener("mouseleave", onTooltipLeave);
557
+ el.removeEventListener("mouseenter", el.$_ptooltipMouseEnterEvent);
558
+ setTimeout(function() {
559
+ return el.addEventListener("mouseenter", el.$_ptooltipMouseEnterEvent);
560
+ }, 50);
561
+ });
562
+ this.bindScrollListener(el);
563
+ x.set("tooltip", tooltipElement, el.$_ptooltipZIndex);
564
+ },
565
+ show: function show(el, options, showDelay) {
566
+ var _this3 = this;
567
+ if (showDelay !== void 0) {
568
+ this.timer = setTimeout(function() {
569
+ return _this3.tooltipActions(el, options);
570
+ }, showDelay);
571
+ el.$_ptooltipPendingShow = true;
572
+ } else {
573
+ this.tooltipActions(el, options);
574
+ el.$_ptooltipPendingShow = false;
575
+ }
576
+ },
577
+ tooltipRemoval: function tooltipRemoval(el) {
578
+ this.remove(el);
579
+ this.unbindScrollListener(el);
580
+ window.removeEventListener("resize", el.$_pWindowResizeEvent);
581
+ },
582
+ hide: function hide(el, hideDelay) {
583
+ var _this4 = this;
584
+ clearTimeout(this.timer);
585
+ el.$_ptooltipPendingShow = false;
586
+ if (hideDelay !== void 0) {
587
+ setTimeout(function() {
588
+ return _this4.tooltipRemoval(el);
589
+ }, hideDelay);
590
+ } else {
591
+ this.tooltipRemoval(el);
592
+ }
593
+ },
594
+ getTooltipElement: function getTooltipElement(el) {
595
+ return document.getElementById(el.$_ptooltipId);
596
+ },
597
+ getArrowElement: function getArrowElement(el) {
598
+ var tooltipElement = this.getTooltipElement(el);
599
+ return z(tooltipElement, '[data-pc-section="arrow"]');
600
+ },
601
+ create: function create(el) {
602
+ var modifiers = el.$_ptooltipModifiers;
603
+ var tooltipArrow = U("div", {
604
+ "class": !this.isUnstyled() && this.cx("arrow"),
605
+ "p-bind": this.ptm("arrow", {
606
+ context: modifiers
607
+ })
608
+ });
609
+ var tooltipText = U("div", {
610
+ "class": !this.isUnstyled() && this.cx("text"),
611
+ "p-bind": this.ptm("text", {
612
+ context: modifiers
613
+ })
614
+ });
615
+ if (!el.$_ptooltipEscape) {
616
+ tooltipText.innerHTML = el.$_ptooltipValue;
617
+ } else {
618
+ tooltipText.innerHTML = "";
619
+ tooltipText.appendChild(document.createTextNode(el.$_ptooltipValue));
620
+ }
621
+ var container = U("div", _defineProperty2(_defineProperty2({
622
+ id: el.$_ptooltipIdAttr,
623
+ role: "tooltip",
624
+ style: {
625
+ display: "inline-block",
626
+ width: el.$_ptooltipFitContent ? "fit-content" : void 0,
627
+ pointerEvents: !this.isUnstyled() && el.$_ptooltipAutoHide && "none"
628
+ },
629
+ "class": [!this.isUnstyled() && this.cx("root"), el.$_ptooltipClass]
630
+ }, this.$attrSelector, ""), "p-bind", this.ptm("root", {
631
+ context: modifiers
632
+ })), tooltipArrow, tooltipText);
633
+ document.body.appendChild(container);
634
+ el.$_ptooltipId = container.id;
635
+ this.$el = container;
636
+ return container;
637
+ },
638
+ remove: function remove(el) {
639
+ if (el) {
640
+ var tooltipElement = this.getTooltipElement(el);
641
+ if (tooltipElement && tooltipElement.parentElement) {
642
+ x.clear(tooltipElement);
643
+ document.body.removeChild(tooltipElement);
644
+ }
645
+ el.$_ptooltipId = null;
646
+ }
647
+ },
648
+ align: function align(el) {
649
+ var modifiers = el.$_ptooltipModifiers;
650
+ if (modifiers.top) {
651
+ this.alignTop(el);
652
+ if (this.isOutOfBounds(el)) {
653
+ this.alignBottom(el);
654
+ if (this.isOutOfBounds(el)) {
655
+ this.alignTop(el);
656
+ }
657
+ }
658
+ } else if (modifiers.left) {
659
+ this.alignLeft(el);
660
+ if (this.isOutOfBounds(el)) {
661
+ this.alignRight(el);
662
+ if (this.isOutOfBounds(el)) {
663
+ this.alignTop(el);
664
+ if (this.isOutOfBounds(el)) {
665
+ this.alignBottom(el);
666
+ if (this.isOutOfBounds(el)) {
667
+ this.alignLeft(el);
668
+ }
669
+ }
670
+ }
671
+ }
672
+ } else if (modifiers.bottom) {
673
+ this.alignBottom(el);
674
+ if (this.isOutOfBounds(el)) {
675
+ this.alignTop(el);
676
+ if (this.isOutOfBounds(el)) {
677
+ this.alignBottom(el);
678
+ }
679
+ }
680
+ } else {
681
+ this.alignRight(el);
682
+ if (this.isOutOfBounds(el)) {
683
+ this.alignLeft(el);
684
+ if (this.isOutOfBounds(el)) {
685
+ this.alignTop(el);
686
+ if (this.isOutOfBounds(el)) {
687
+ this.alignBottom(el);
688
+ if (this.isOutOfBounds(el)) {
689
+ this.alignRight(el);
690
+ }
691
+ }
692
+ }
693
+ }
694
+ }
695
+ },
696
+ getHostOffset: function getHostOffset(el) {
697
+ var offset = el.getBoundingClientRect();
698
+ var targetLeft = offset.left + k();
699
+ var targetTop = offset.top + $();
700
+ return {
701
+ left: targetLeft,
702
+ top: targetTop
703
+ };
704
+ },
705
+ alignRight: function alignRight(el) {
706
+ this.preAlign(el, "right");
707
+ var tooltipElement = this.getTooltipElement(el);
708
+ var arrowElement = this.getArrowElement(el);
709
+ var hostOffset = this.getHostOffset(el);
710
+ var left = hostOffset.left + v(el);
711
+ var top = hostOffset.top + (C(el) - C(tooltipElement)) / 2;
712
+ tooltipElement.style.left = left + "px";
713
+ tooltipElement.style.top = top + "px";
714
+ arrowElement.style.top = "50%";
715
+ arrowElement.style.right = null;
716
+ arrowElement.style.bottom = null;
717
+ arrowElement.style.left = "0";
718
+ },
719
+ alignLeft: function alignLeft(el) {
720
+ this.preAlign(el, "left");
721
+ var tooltipElement = this.getTooltipElement(el);
722
+ var arrowElement = this.getArrowElement(el);
723
+ var hostOffset = this.getHostOffset(el);
724
+ var left = hostOffset.left - v(tooltipElement);
725
+ var top = hostOffset.top + (C(el) - C(tooltipElement)) / 2;
726
+ tooltipElement.style.left = left + "px";
727
+ tooltipElement.style.top = top + "px";
728
+ arrowElement.style.top = "50%";
729
+ arrowElement.style.right = "0";
730
+ arrowElement.style.bottom = null;
731
+ arrowElement.style.left = null;
732
+ },
733
+ alignTop: function alignTop(el) {
734
+ this.preAlign(el, "top");
735
+ var tooltipElement = this.getTooltipElement(el);
736
+ var arrowElement = this.getArrowElement(el);
737
+ var tooltipWidth = v(tooltipElement);
738
+ var elementWidth = v(el);
739
+ var _getViewport = h(), viewportWidth = _getViewport.width;
740
+ var hostOffset = this.getHostOffset(el);
741
+ var left = hostOffset.left + (elementWidth - tooltipWidth) / 2;
742
+ var top = hostOffset.top - C(tooltipElement);
743
+ if (left < 0) {
744
+ left = 0;
745
+ } else if (left + tooltipWidth > viewportWidth) {
746
+ left = Math.floor(hostOffset.left + elementWidth - tooltipWidth);
747
+ }
748
+ tooltipElement.style.left = left + "px";
749
+ tooltipElement.style.top = top + "px";
750
+ var elementRelativeCenter = hostOffset.left - this.getHostOffset(tooltipElement).left + elementWidth / 2;
751
+ arrowElement.style.top = null;
752
+ arrowElement.style.right = null;
753
+ arrowElement.style.bottom = "0";
754
+ arrowElement.style.left = elementRelativeCenter + "px";
755
+ },
756
+ alignBottom: function alignBottom(el) {
757
+ this.preAlign(el, "bottom");
758
+ var tooltipElement = this.getTooltipElement(el);
759
+ var arrowElement = this.getArrowElement(el);
760
+ var tooltipWidth = v(tooltipElement);
761
+ var elementWidth = v(el);
762
+ var _getViewport2 = h(), viewportWidth = _getViewport2.width;
763
+ var hostOffset = this.getHostOffset(el);
764
+ var left = hostOffset.left + (elementWidth - tooltipWidth) / 2;
765
+ var top = hostOffset.top + C(el);
766
+ if (left < 0) {
767
+ left = 0;
768
+ } else if (left + tooltipWidth > viewportWidth) {
769
+ left = Math.floor(hostOffset.left + elementWidth - tooltipWidth);
770
+ }
771
+ tooltipElement.style.left = left + "px";
772
+ tooltipElement.style.top = top + "px";
773
+ var elementRelativeCenter = hostOffset.left - this.getHostOffset(tooltipElement).left + elementWidth / 2;
774
+ arrowElement.style.top = "0";
775
+ arrowElement.style.right = null;
776
+ arrowElement.style.bottom = null;
777
+ arrowElement.style.left = elementRelativeCenter + "px";
778
+ },
779
+ preAlign: function preAlign(el, position) {
780
+ var tooltipElement = this.getTooltipElement(el);
781
+ tooltipElement.style.left = "-999px";
782
+ tooltipElement.style.top = "-999px";
783
+ P(tooltipElement, "p-tooltip-".concat(tooltipElement.$_ptooltipPosition));
784
+ !this.isUnstyled() && W(tooltipElement, "p-tooltip-".concat(position));
785
+ tooltipElement.$_ptooltipPosition = position;
786
+ tooltipElement.setAttribute("data-p-position", position);
787
+ },
788
+ isOutOfBounds: function isOutOfBounds(el) {
789
+ var tooltipElement = this.getTooltipElement(el);
790
+ var offset = tooltipElement.getBoundingClientRect();
791
+ var targetTop = offset.top;
792
+ var targetLeft = offset.left;
793
+ var width = v(tooltipElement);
794
+ var height = C(tooltipElement);
795
+ var viewport = h();
796
+ return targetLeft + width > viewport.width || targetLeft < 0 || targetTop < 0 || targetTop + height > viewport.height;
797
+ },
798
+ getTarget: function getTarget(el) {
799
+ var _findSingle;
800
+ return R(el, "p-inputwrapper") ? (_findSingle = z(el, "input")) !== null && _findSingle !== void 0 ? _findSingle : el : el;
801
+ },
802
+ getModifiers: function getModifiers(options) {
803
+ if (options.modifiers && Object.keys(options.modifiers).length) {
804
+ return options.modifiers;
805
+ }
806
+ if (options.arg && _typeof2(options.arg) === "object") {
807
+ return Object.entries(options.arg).reduce(function(acc, _ref) {
808
+ var _ref2 = _slicedToArray(_ref, 2), key = _ref2[0], val = _ref2[1];
809
+ if (key === "event" || key === "position") acc[val] = true;
810
+ return acc;
811
+ }, {});
812
+ }
813
+ return {};
814
+ }
815
+ }
816
+ });
817
+
818
+ // ../../node_modules/primevue/dock/index.mjs
819
+ var script$2 = {
820
+ name: "BaseDock",
821
+ "extends": script,
822
+ props: {
823
+ position: {
824
+ type: String,
825
+ "default": "bottom"
826
+ },
827
+ model: null,
828
+ "class": null,
829
+ style: null,
830
+ tooltipOptions: null,
831
+ menuId: {
832
+ type: String,
833
+ "default": null
834
+ },
835
+ tabindex: {
836
+ type: Number,
837
+ "default": 0
838
+ },
839
+ breakpoint: {
840
+ type: String,
841
+ "default": "960px"
842
+ },
843
+ ariaLabel: {
844
+ type: String,
845
+ "default": null
846
+ },
847
+ ariaLabelledby: {
848
+ type: String,
849
+ "default": null
850
+ }
851
+ },
852
+ style: DockStyle,
853
+ provide: function provide() {
854
+ return {
855
+ $pcDock: this,
856
+ $parentInstance: this
857
+ };
858
+ }
859
+ };
860
+ function _toConsumableArray2(r) {
861
+ return _arrayWithoutHoles2(r) || _iterableToArray2(r) || _unsupportedIterableToArray3(r) || _nonIterableSpread2();
862
+ }
863
+ function _nonIterableSpread2() {
864
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
865
+ }
866
+ function _unsupportedIterableToArray3(r, a) {
867
+ if (r) {
868
+ if ("string" == typeof r) return _arrayLikeToArray3(r, a);
869
+ var t = {}.toString.call(r).slice(8, -1);
870
+ 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) ? _arrayLikeToArray3(r, a) : void 0;
871
+ }
872
+ }
873
+ function _iterableToArray2(r) {
874
+ if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r);
875
+ }
876
+ function _arrayWithoutHoles2(r) {
877
+ if (Array.isArray(r)) return _arrayLikeToArray3(r);
878
+ }
879
+ function _arrayLikeToArray3(r, a) {
880
+ (null == a || a > r.length) && (a = r.length);
881
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
882
+ return n;
883
+ }
884
+ var script$1 = {
885
+ name: "DockSub",
886
+ hostName: "Dock",
887
+ "extends": script,
888
+ emits: ["focus", "blur"],
889
+ props: {
890
+ position: {
891
+ type: String,
892
+ "default": "bottom"
893
+ },
894
+ model: {
895
+ type: Array,
896
+ "default": null
897
+ },
898
+ templates: {
899
+ type: null,
900
+ "default": null
901
+ },
902
+ tooltipOptions: null,
903
+ menuId: {
904
+ type: String,
905
+ "default": null
906
+ },
907
+ tabindex: {
908
+ type: Number,
909
+ "default": 0
910
+ },
911
+ ariaLabel: {
912
+ type: String,
913
+ "default": null
914
+ },
915
+ ariaLabelledby: {
916
+ type: String,
917
+ "default": null
918
+ }
919
+ },
920
+ data: function data() {
921
+ return {
922
+ currentIndex: -3,
923
+ focused: false,
924
+ focusedOptionIndex: -1
925
+ };
926
+ },
927
+ methods: {
928
+ getItemId: function getItemId(index) {
929
+ return "".concat(this.idx, "_").concat(index);
930
+ },
931
+ getItemProp: function getItemProp(processedItem, name) {
932
+ return processedItem && processedItem.item ? m(processedItem.item[name]) : void 0;
933
+ },
934
+ getPTOptions: function getPTOptions(key, item2, index) {
935
+ return this.ptm(key, {
936
+ context: {
937
+ index,
938
+ item: item2,
939
+ active: this.isItemActive(this.getItemId(index))
940
+ }
941
+ });
942
+ },
943
+ isSameMenuItem: function isSameMenuItem(event) {
944
+ return event.currentTarget && (event.currentTarget.isSameNode(event.target) || event.currentTarget.isSameNode(event.target.closest('[data-pc-section="item"]')));
945
+ },
946
+ isItemActive: function isItemActive(id) {
947
+ return id === this.focusedOptionIndex;
948
+ },
949
+ onListMouseLeave: function onListMouseLeave() {
950
+ this.currentIndex = -3;
951
+ },
952
+ onItemMouseEnter: function onItemMouseEnter(index) {
953
+ this.currentIndex = index;
954
+ },
955
+ onItemClick: function onItemClick(event, processedItem) {
956
+ if (this.isSameMenuItem(event)) {
957
+ var command = this.getItemProp(processedItem, "command");
958
+ command && command({
959
+ originalEvent: event,
960
+ item: processedItem.item
961
+ });
962
+ }
963
+ },
964
+ onListFocus: function onListFocus(event) {
965
+ this.focused = true;
966
+ this.changeFocusedOptionIndex(0);
967
+ this.$emit("focus", event);
968
+ },
969
+ onListBlur: function onListBlur(event) {
970
+ this.focused = false;
971
+ this.focusedOptionIndex = -1;
972
+ this.$emit("blur", event);
973
+ },
974
+ onListKeyDown: function onListKeyDown(event) {
975
+ switch (event.code) {
976
+ case "ArrowDown": {
977
+ if (this.position === "left" || this.position === "right") this.onArrowDownKey();
978
+ event.preventDefault();
979
+ break;
980
+ }
981
+ case "ArrowUp": {
982
+ if (this.position === "left" || this.position === "right") this.onArrowUpKey();
983
+ event.preventDefault();
984
+ break;
985
+ }
986
+ case "ArrowRight": {
987
+ if (this.position === "top" || this.position === "bottom") this.onArrowDownKey();
988
+ event.preventDefault();
989
+ break;
990
+ }
991
+ case "ArrowLeft": {
992
+ if (this.position === "top" || this.position === "bottom") this.onArrowUpKey();
993
+ event.preventDefault();
994
+ break;
995
+ }
996
+ case "Home": {
997
+ this.onHomeKey();
998
+ event.preventDefault();
999
+ break;
1000
+ }
1001
+ case "End": {
1002
+ this.onEndKey();
1003
+ event.preventDefault();
1004
+ break;
1005
+ }
1006
+ case "Enter":
1007
+ case "NumpadEnter":
1008
+ case "Space": {
1009
+ this.onSpaceKey(event);
1010
+ event.preventDefault();
1011
+ break;
1012
+ }
1013
+ }
1014
+ },
1015
+ onArrowDownKey: function onArrowDownKey() {
1016
+ var optionIndex = this.findNextOptionIndex(this.focusedOptionIndex);
1017
+ this.changeFocusedOptionIndex(optionIndex);
1018
+ },
1019
+ onArrowUpKey: function onArrowUpKey() {
1020
+ var optionIndex = this.findPrevOptionIndex(this.focusedOptionIndex);
1021
+ this.changeFocusedOptionIndex(optionIndex);
1022
+ },
1023
+ onHomeKey: function onHomeKey() {
1024
+ this.changeFocusedOptionIndex(0);
1025
+ },
1026
+ onEndKey: function onEndKey() {
1027
+ this.changeFocusedOptionIndex(Y(this.$refs.list, 'li[data-pc-section="item"][data-p-disabled="false"]').length - 1);
1028
+ },
1029
+ onSpaceKey: function onSpaceKey() {
1030
+ var element = z(this.$refs.list, 'li[id="'.concat("".concat(this.focusedOptionIndex), '"]'));
1031
+ var anchorElement = element && z(element, '[data-pc-section="itemlink"]');
1032
+ anchorElement ? anchorElement.click() : element && element.click();
1033
+ },
1034
+ findNextOptionIndex: function findNextOptionIndex(index) {
1035
+ var menuitems = Y(this.$refs.list, 'li[data-pc-section="item"][data-p-disabled="false"]');
1036
+ var matchedOptionIndex = _toConsumableArray2(menuitems).findIndex(function(link) {
1037
+ return link.id === index;
1038
+ });
1039
+ return matchedOptionIndex > -1 ? matchedOptionIndex + 1 : 0;
1040
+ },
1041
+ findPrevOptionIndex: function findPrevOptionIndex(index) {
1042
+ var menuitems = Y(this.$refs.list, 'li[data-pc-section="item"][data-p-disabled="false"]');
1043
+ var matchedOptionIndex = _toConsumableArray2(menuitems).findIndex(function(link) {
1044
+ return link.id === index;
1045
+ });
1046
+ return matchedOptionIndex > -1 ? matchedOptionIndex - 1 : 0;
1047
+ },
1048
+ changeFocusedOptionIndex: function changeFocusedOptionIndex(index) {
1049
+ var menuitems = Y(this.$refs.list, 'li[data-pc-section="item"][data-p-disabled="false"]');
1050
+ var order = index >= menuitems.length ? menuitems.length - 1 : index < 0 ? 0 : index;
1051
+ this.focusedOptionIndex = menuitems[order].getAttribute("id");
1052
+ },
1053
+ disabled: function disabled(item2) {
1054
+ return typeof item2.disabled === "function" ? item2.disabled() : item2.disabled;
1055
+ },
1056
+ getMenuItemProps: function getMenuItemProps(item2, index) {
1057
+ return {
1058
+ action: mergeProps({
1059
+ tabindex: -1,
1060
+ "class": this.cx("itemLink")
1061
+ }, this.getPTOptions("itemLink", item2, index)),
1062
+ icon: mergeProps({
1063
+ "class": [this.cx("itemIcon"), item2.icon]
1064
+ }, this.getPTOptions("itemIcon", item2, index))
1065
+ };
1066
+ }
1067
+ },
1068
+ computed: {
1069
+ focusedOptionId: function focusedOptionId() {
1070
+ return this.focusedOptionIndex !== -1 ? this.focusedOptionIndex : null;
1071
+ },
1072
+ idx: function idx() {
1073
+ return this.menuId || this.$id;
1074
+ }
1075
+ },
1076
+ directives: {
1077
+ ripple: Ripple,
1078
+ tooltip: Tooltip
1079
+ }
1080
+ };
1081
+ var _hoisted_1 = ["id", "aria-orientation", "aria-activedescendant", "tabindex", "aria-label", "aria-labelledby"];
1082
+ var _hoisted_2 = ["id", "aria-label", "aria-disabled", "onClick", "onMouseenter", "data-p-focused", "data-p-disabled"];
1083
+ var _hoisted_3 = ["href", "target"];
1084
+ function render$1(_ctx, _cache, $props, $setup, $data, $options) {
1085
+ var _directive_ripple = resolveDirective("ripple");
1086
+ var _directive_tooltip = resolveDirective("tooltip");
1087
+ return openBlock(), createElementBlock("div", mergeProps({
1088
+ "class": _ctx.cx("listContainer")
1089
+ }, _ctx.ptm("listContainer")), [createBaseVNode("ul", mergeProps({
1090
+ ref: "list",
1091
+ id: $options.idx,
1092
+ "class": _ctx.cx("list"),
1093
+ role: "menu",
1094
+ "aria-orientation": $props.position === "bottom" || $props.position === "top" ? "horizontal" : "vertical",
1095
+ "aria-activedescendant": $data.focused ? $options.focusedOptionId : void 0,
1096
+ tabindex: $props.tabindex,
1097
+ "aria-label": $props.ariaLabel,
1098
+ "aria-labelledby": $props.ariaLabelledby,
1099
+ onFocus: _cache[0] || (_cache[0] = function() {
1100
+ return $options.onListFocus && $options.onListFocus.apply($options, arguments);
1101
+ }),
1102
+ onBlur: _cache[1] || (_cache[1] = function() {
1103
+ return $options.onListBlur && $options.onListBlur.apply($options, arguments);
1104
+ }),
1105
+ onKeydown: _cache[2] || (_cache[2] = function() {
1106
+ return $options.onListKeyDown && $options.onListKeyDown.apply($options, arguments);
1107
+ }),
1108
+ onMouseleave: _cache[3] || (_cache[3] = function() {
1109
+ return $options.onListMouseLeave && $options.onListMouseLeave.apply($options, arguments);
1110
+ })
1111
+ }, _ctx.ptm("list")), [(openBlock(true), createElementBlock(Fragment, null, renderList($props.model, function(processedItem, index) {
1112
+ return openBlock(), createElementBlock("li", mergeProps({
1113
+ key: index,
1114
+ id: $options.getItemId(index),
1115
+ "class": _ctx.cx("item", {
1116
+ processedItem,
1117
+ id: $options.getItemId(index)
1118
+ }),
1119
+ role: "menuitem",
1120
+ "aria-label": processedItem.label,
1121
+ "aria-disabled": $options.disabled(processedItem),
1122
+ onClick: function onClick2($event) {
1123
+ return $options.onItemClick($event, processedItem);
1124
+ },
1125
+ onMouseenter: function onMouseenter($event) {
1126
+ return $options.onItemMouseEnter(index);
1127
+ }
1128
+ }, {
1129
+ ref_for: true
1130
+ }, $options.getPTOptions("item", processedItem, index), {
1131
+ "data-p-focused": $options.isItemActive($options.getItemId(index)),
1132
+ "data-p-disabled": $options.disabled(processedItem) || false
1133
+ }), [createBaseVNode("div", mergeProps({
1134
+ "class": _ctx.cx("itemContent")
1135
+ }, {
1136
+ ref_for: true
1137
+ }, $options.getPTOptions("itemContent", processedItem, index)), [!$props.templates["item"] ? withDirectives((openBlock(), createElementBlock("a", mergeProps({
1138
+ key: 0,
1139
+ href: processedItem.url,
1140
+ "class": _ctx.cx("itemLink"),
1141
+ target: processedItem.target,
1142
+ tabindex: "-1"
1143
+ }, {
1144
+ ref_for: true
1145
+ }, $options.getPTOptions("itemLink", processedItem, index)), [!$props.templates["icon"] && !$props.templates["itemicon"] ? withDirectives((openBlock(), createElementBlock("span", mergeProps({
1146
+ key: 0,
1147
+ "class": [_ctx.cx("itemIcon"), processedItem.icon]
1148
+ }, {
1149
+ ref_for: true
1150
+ }, $options.getPTOptions("itemIcon", processedItem, index)), null, 16)), [[_directive_ripple]]) : (openBlock(), createBlock(resolveDynamicComponent($props.templates["icon"] || $props.templates["itemicon"]), {
1151
+ key: 1,
1152
+ item: processedItem,
1153
+ "class": normalizeClass(_ctx.cx("itemIcon"))
1154
+ }, null, 8, ["item", "class"]))], 16, _hoisted_3)), [[_directive_tooltip, {
1155
+ value: processedItem.label,
1156
+ disabled: !$props.tooltipOptions
1157
+ }, $props.tooltipOptions]]) : (openBlock(), createBlock(resolveDynamicComponent($props.templates["item"]), {
1158
+ key: 1,
1159
+ item: processedItem,
1160
+ index,
1161
+ label: processedItem.label,
1162
+ props: $options.getMenuItemProps(processedItem, index)
1163
+ }, null, 8, ["item", "index", "label", "props"]))], 16)], 16, _hoisted_2);
1164
+ }), 128))], 16, _hoisted_1)], 16);
1165
+ }
1166
+ script$1.render = render$1;
1167
+ var script2 = {
1168
+ name: "Dock",
1169
+ "extends": script$2,
1170
+ inheritAttrs: false,
1171
+ matchMediaListener: null,
1172
+ data: function data2() {
1173
+ return {
1174
+ query: null,
1175
+ queryMatches: false
1176
+ };
1177
+ },
1178
+ mounted: function mounted() {
1179
+ this.bindMatchMediaListener();
1180
+ },
1181
+ beforeUnmount: function beforeUnmount() {
1182
+ this.unbindMatchMediaListener();
1183
+ },
1184
+ methods: {
1185
+ bindMatchMediaListener: function bindMatchMediaListener() {
1186
+ var _this = this;
1187
+ if (!this.matchMediaListener) {
1188
+ var query = matchMedia("(max-width: ".concat(this.breakpoint, ")"));
1189
+ this.query = query;
1190
+ this.queryMatches = query.matches;
1191
+ this.matchMediaListener = function() {
1192
+ _this.queryMatches = query.matches;
1193
+ _this.mobileActive = false;
1194
+ };
1195
+ this.query.addEventListener("change", this.matchMediaListener);
1196
+ }
1197
+ },
1198
+ unbindMatchMediaListener: function unbindMatchMediaListener() {
1199
+ if (this.matchMediaListener) {
1200
+ this.query.removeEventListener("change", this.matchMediaListener);
1201
+ this.matchMediaListener = null;
1202
+ }
1203
+ }
1204
+ },
1205
+ computed: {
1206
+ containerClass: function containerClass() {
1207
+ return [this["class"], this.cx("root")];
1208
+ }
1209
+ },
1210
+ components: {
1211
+ DockSub: script$1
1212
+ }
1213
+ };
1214
+ function render(_ctx, _cache, $props, $setup, $data, $options) {
1215
+ var _component_DockSub = resolveComponent("DockSub");
1216
+ return openBlock(), createElementBlock("div", mergeProps({
1217
+ "class": $options.containerClass,
1218
+ style: _ctx.style
1219
+ }, _ctx.ptmi("root")), [createVNode(_component_DockSub, {
1220
+ model: _ctx.model,
1221
+ templates: _ctx.$slots,
1222
+ tooltipOptions: _ctx.tooltipOptions,
1223
+ position: _ctx.position,
1224
+ menuId: _ctx.menuId,
1225
+ "aria-label": _ctx.ariaLabel,
1226
+ "aria-labelledby": _ctx.ariaLabelledby,
1227
+ tabindex: _ctx.tabindex,
1228
+ pt: _ctx.pt,
1229
+ unstyled: _ctx.unstyled
1230
+ }, null, 8, ["model", "templates", "tooltipOptions", "position", "menuId", "aria-label", "aria-labelledby", "tabindex", "pt", "unstyled"])], 16);
1231
+ }
1232
+ script2.render = render;
1233
+ export {
1234
+ script2 as default
1235
+ };
1236
+ //# sourceMappingURL=primevue_dock.js.map