eco-vue-js 0.11.5 → 0.11.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/dist/components/Button/WButtonDropdown.vue.d.ts +0 -2
  2. package/dist/components/Button/WButtonDropdown.vue.d.ts.map +1 -1
  3. package/dist/components/Button/WButtonDropdown.vue.js +2 -6
  4. package/dist/components/Button/WButtonMore.vue.d.ts.map +1 -1
  5. package/dist/components/Button/WButtonMore.vue.js +0 -2
  6. package/dist/components/Button/WButtonSelection.vue.d.ts.map +1 -1
  7. package/dist/components/Button/WButtonSelection.vue.js +0 -2
  8. package/dist/components/Button/types.d.ts +1 -1
  9. package/dist/components/Button/types.d.ts.map +1 -1
  10. package/dist/components/Dropdown/WDropdown.vue.d.ts.map +1 -1
  11. package/dist/components/Dropdown/WDropdown.vue.js +29 -47
  12. package/dist/components/Dropdown/types.d.ts +0 -7
  13. package/dist/components/Dropdown/types.d.ts.map +1 -1
  14. package/dist/components/Dropdown/utils/DropdownStyle.d.ts +35 -75
  15. package/dist/components/Dropdown/utils/DropdownStyle.d.ts.map +1 -1
  16. package/dist/components/Dropdown/utils/DropdownStyle.js +97 -164
  17. package/dist/components/DropdownMenu/WDropdownMenu.vue.d.ts +0 -4
  18. package/dist/components/DropdownMenu/WDropdownMenu.vue.d.ts.map +1 -1
  19. package/dist/components/DropdownMenu/WDropdownMenu.vue.js +1 -5
  20. package/dist/components/FormAsync/WFormAsyncSelect.vue.js +0 -2
  21. package/dist/components/FormAsync/WFormAsyncSelectInfiniteSingle.vue.js +0 -2
  22. package/dist/components/FormAsync/WFormAsyncSelectSingle.vue.js +0 -2
  23. package/dist/components/FormAsync/WFormAsyncSelectStringified.vue.js +0 -2
  24. package/dist/components/Input/WInput.vue.d.ts +10 -1
  25. package/dist/components/Input/WInput.vue.d.ts.map +1 -1
  26. package/dist/components/Input/WInput.vue.js +8 -1
  27. package/dist/components/Input/WInputDate.vue.d.ts +16 -6
  28. package/dist/components/Input/WInputDate.vue.d.ts.map +1 -1
  29. package/dist/components/Input/WInputDate.vue.js +0 -2
  30. package/dist/components/Input/WInputOptions.vue.js +0 -2
  31. package/dist/components/Input/WInputSuggest.vue.d.ts +11 -3
  32. package/dist/components/Input/WInputSuggest.vue.d.ts.map +1 -1
  33. package/dist/components/Input/WInputSuggest.vue.js +21 -18
  34. package/dist/components/Input/components/ContentEditable.vue.d.ts +7 -0
  35. package/dist/components/Input/components/ContentEditable.vue.d.ts.map +1 -1
  36. package/dist/components/Input/components/ContentEditable.vue.js +52 -37
  37. package/dist/components/Input/types.d.ts +4 -0
  38. package/dist/components/Input/types.d.ts.map +1 -1
  39. package/dist/components/List/components/HeaderSettings.vue.d.ts.map +1 -1
  40. package/dist/components/List/components/HeaderSettings.vue.js +0 -2
  41. package/dist/components/List/components/HeaderSort.vue.d.ts.map +1 -1
  42. package/dist/components/List/components/HeaderSort.vue.js +0 -2
  43. package/dist/components/List/components/ListFilterSelect.vue.d.ts.map +1 -1
  44. package/dist/components/List/components/ListFilterSelect.vue.js +0 -2
  45. package/dist/components/Nav/WNavItemExpand.vue.d.ts.map +1 -1
  46. package/dist/components/Nav/WNavItemExpand.vue.js +0 -2
  47. package/dist/components/Select/WSelect.vue.d.ts.map +1 -1
  48. package/dist/components/Select/WSelect.vue.js +75 -74
  49. package/dist/components/Select/WSelectAsync.vue.d.ts +2 -2
  50. package/dist/components/Select/WSelectAsync.vue.d.ts.map +1 -1
  51. package/dist/components/Select/WSelectAsync.vue.js +1 -2
  52. package/dist/components/Select/WSelectAsyncSingle.vue.js +0 -2
  53. package/dist/components/Select/WSelectSingle.vue.d.ts +5 -1
  54. package/dist/components/Select/WSelectSingle.vue.d.ts.map +1 -1
  55. package/dist/components/Select/WSelectSingle.vue.js +8 -6
  56. package/dist/components/Select/WSelectStringified.vue.js +0 -2
  57. package/dist/components/Select/components/SelectAsyncList.vue.js +1 -1
  58. package/dist/components/Tooltip/WTooltipContainer.vue.d.ts +0 -2
  59. package/dist/components/Tooltip/WTooltipContainer.vue.d.ts.map +1 -1
  60. package/dist/components/Tooltip/WTooltipContainer.vue.js +1 -3
  61. package/dist/utils/HorizontalAlign.d.ts +0 -1
  62. package/dist/utils/HorizontalAlign.d.ts.map +1 -1
  63. package/dist/utils/HorizontalAlign.js +0 -1
  64. package/package.json +1 -1
  65. package/tailwind-base/plugins/default.ts +14 -8
@@ -20,9 +20,7 @@ declare function __VLS_template(): {
20
20
  };
21
21
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
22
22
  declare const __VLS_component: import('vue').DefineComponent<ButtonDropdownProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ButtonDropdownProps> & Readonly<{}>, {
23
- maxHeight: number;
24
23
  disabled: boolean;
25
- maxWidth: number;
26
24
  horizontalAlign: HorizontalAlign;
27
25
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
28
26
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
@@ -1 +1 @@
1
- {"version":3,"file":"WButtonDropdown.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonDropdown.vue"],"names":[],"mappings":"AAqEA;AA2GA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,SAAS,CAAA;AAEhD,OAAO,EAAC,KAAK,KAAK,EAAM,MAAM,KAAK,CAAA;AAQnC,OAAO,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAA;AAiBvD,QAAA,MAAM,KAAK,YAEV,CAAA;AAeD,iBAAS,cAAc;WA4KT,OAAO,IAA6B;;iBAxLvC,MAAM,KAAK,EAAE;kBACZ,CAAC,KAAK,EAAE;YAAC,KAAK,EAAE,OAAO,KAAK,CAAA;SAAC,KAAK,KAAK,EAAE;;iBAD1C,MAAM,KAAK,EAAE;kBACZ,CAAC,KAAK,EAAE;YAAC,KAAK,EAAE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ACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -17,9 +17,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
17
17
  parentElement: {},
18
18
  top: { type: Boolean },
19
19
  bottom: { type: Boolean },
20
- horizontalAlign: { default: HorizontalAlign.LEFT_INNER },
21
- maxHeight: { default: 200 },
22
- maxWidth: { default: 320 }
20
+ horizontalAlign: { default: HorizontalAlign.LEFT_INNER }
23
21
  },
24
22
  setup(__props) {
25
23
  const isOpen = ref(false);
@@ -29,8 +27,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
29
27
  return (_ctx, _cache) => {
30
28
  return openBlock(), createBlock(_sfc_main$1, {
31
29
  "is-open": isOpen.value,
32
- "max-height": _ctx.maxHeight,
33
- "max-width": _ctx.maxWidth,
34
30
  "horizontal-align": _ctx.horizontalAlign,
35
31
  "update-align": ""
36
32
  }, {
@@ -91,7 +87,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
91
87
  })
92
88
  ]),
93
89
  _: 3
94
- }, 8, ["is-open", "max-height", "max-width", "horizontal-align"]);
90
+ }, 8, ["is-open", "horizontal-align"]);
95
91
  };
96
92
  }
97
93
  });
@@ -1 +1 @@
1
- {"version":3,"file":"WButtonMore.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonMore.vue"],"names":[],"mappings":"AAyDA;AA0GA,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,mBAAmB,CAAA;AAWpD,KAAK,WAAW,GAAG;IACjB,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,CAAC,EAAE,aAAa,CAAC,eAAe,CAAC,CAAA;CACxC,CAAC;AAuCF,iBAAS,cAAc;WAgHT,OAAO,IAA6B;;yBAXpB,GAAG;;;;EAgBhC;AAgBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;gGASnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAQpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WButtonMore.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/WButtonMore.vue"],"names":[],"mappings":"AAuDA;AAwGA,OAAO,KAAK,EAAC,aAAa,EAAC,MAAM,mBAAmB,CAAA;AAWpD,KAAK,WAAW,GAAG;IACjB,IAAI,CAAC,EAAE,YAAY,CAAA;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,CAAC,EAAE,aAAa,CAAC,eAAe,CAAC,CAAA;CACxC,CAAC;AAuCF,iBAAS,cAAc;WA4GT,OAAO,IAA6B;;yBAXpB,GAAG;;;;EAgBhC;AAgBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;gGASnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAQpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -44,8 +44,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
44
44
  }), [
45
45
  createVNode(_sfc_main$1, {
46
46
  "is-open": isOpen.value,
47
- "max-height": 210,
48
- "max-width": 320,
49
47
  "horizontal-align": _ctx.anchor ? unref(HorizontalAlign).RIGHT_INNER : unref(HorizontalAlign).LEFT_INNER,
50
48
  "update-align": false,
51
49
  "parent-element": _ctx.anchor
@@ -1 +1 @@
1
- {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O;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -35,8 +35,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
35
35
  _ctx.$slots.more ? (openBlock(), createBlock(_sfc_main$1, {
36
36
  key: 0,
37
37
  "is-open": isOpen.value,
38
- "max-width": 200,
39
- "max-height": 300,
40
38
  "horizontal-align": unref(HorizontalAlign).RIGHT_INNER
41
39
  }, {
42
40
  toggle: withCtx(() => [
@@ -46,7 +46,7 @@ interface ButtonGroupPropsForEntity<Model extends number | string | null | boole
46
46
  export type ButtonGroupProps<Model extends number | string | null | boolean, Entity extends Record<string, unknown>, ValueGetter extends {
47
47
  fn(value: Entity): Model;
48
48
  }['fn'] | undefined = undefined> = ButtonGroupPropsForEntity<Model, Entity, ValueGetter> | ButtonGroupPropsForModel<Model, Entity, ValueGetter>;
49
- export interface ButtonDropdownProps extends Omit<DropdownMenuProps, 'isOpen' | 'updateAlign' | 'emitUpdate' | 'horizontalAlign' | 'maxHeight' | 'maxWidth'>, Partial<Pick<DropdownMenuProps, 'horizontalAlign' | 'maxHeight' | 'maxWidth'>> {
49
+ export interface ButtonDropdownProps extends Omit<DropdownMenuProps, 'isOpen' | 'updateAlign' | 'emitUpdate' | 'horizontalAlign'>, Partial<Pick<DropdownMenuProps, 'horizontalAlign'>> {
50
50
  semanticType?: SemanticType;
51
51
  leftToggle?: boolean;
52
52
  disabled?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,iBAAiB,CAAA;AACtD,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,iCAAiC,CAAA;AACtE,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,iCAAiC,CAAA;AACtE,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,eAAe,CAAA;AAC5C,OAAO,KAAK,EAAC,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- {"version":3,"file":"WDropdown.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/WDropdown.vue"],"names":[],"mappings":"AAqCA;AAwKA,OAAO,KAAK,EAAC,wBAAwB,EAAE,aAAa,EAAC,MAAM,SAAS,CAAA;AAEpE,OAAO,EAAC,KAAK,KAAK,EAAyF,MAAM,KAAK,CAAA;AAsItH,iBAAS,cAAc;WA+CT,OAAO,IAA6B;;iBA/DvC,CAAC,KAAK,EAAE,wBAAwB,KAAK,KAAK,EAAE;;iBAA5C,CAAC,KAAK,EAAE,wBAAwB,KAAK,KAAK,EAAE;;;;;;EAoEtD;AAmBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;kBAUnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAQpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"WDropdown.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/WDropdown.vue"],"names":[],"mappings":"AA6BA;AA8IA,OAAO,KAAK,EAAC,wBAAwB,EAAE,aAAa,EAAC,MAAM,SAAS,CAAA;AAEpE,OAAO,EAAC,KAAK,KAAK,EAAyF,MAAM,KAAK,CAAA;AAoHtH,iBAAS,cAAc;WA4CT,OAAO,IAA6B;;iBA5DvC,CAAC,KAAK,EAAE,wBAAwB,KAAK,KAAK,EAAE;;iBAA5C,CAAC,KAAK,EAAE,wBAAwB,KAAK,KAAK,EAAE;;;;;;EAiEtD;AAiBD,KAAK,oBAAoB,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAC9D,QAAA,MAAM,eAAe;;;;;;;;kBAUnB,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,oBAAoB,CAAC,OAAO,CAAC,CAAC;AAAnG,wBAAoG;AAQpG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IACxC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1,14 +1,11 @@
1
- import { defineComponent, useTemplateRef, ref, computed, onBeforeMount, onMounted, onBeforeUnmount, watch, toRef, createElementBlock, openBlock, normalizeClass, normalizeStyle, createElementVNode, unref, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
1
+ import { defineComponent, useTemplateRef, ref, computed, onBeforeMount, onMounted, onBeforeUnmount, watch, toRef, createElementBlock, openBlock, normalizeClass, normalizeStyle, createElementVNode, renderSlot, normalizeProps, guardReactiveProps } from 'vue';
2
2
  import { DOMListenerContainer } from '../../utils/DOMListenerContainer.js';
3
- import { HorizontalAlign } from '../../utils/HorizontalAlign.js';
4
3
  import { isClientSide, getAllScrollParents } from '../../utils/utils.js';
5
- import { OriginX, OriginY, horizontalGetterOrderMap, searchStyleGetter, LeftCenter, LeftOuter, LeftInner, RightOuter, RightInner } from './utils/DropdownStyle.js';
4
+ import { OriginX, horizontalGetterOrderMap, searchStyleGetter } from './utils/DropdownStyle.js';
6
5
 
7
6
  const _sfc_main = /* @__PURE__ */ defineComponent({
8
7
  __name: "WDropdown",
9
8
  props: {
10
- maxHeight: {},
11
- maxWidth: {},
12
9
  horizontalAlign: {},
13
10
  top: { type: Boolean },
14
11
  bottom: { type: Boolean },
@@ -21,41 +18,28 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
21
18
  const props = __props;
22
19
  const emit = __emit;
23
20
  const dropdownRef = useTemplateRef("dropdown");
24
- let parentRect = null;
25
- let horizontalGetter = null;
26
- let verticalGetter = null;
27
- const isTop = ref(false);
28
- const isLeftCenter = ref(false);
29
- const isLeft = ref(false);
30
- const isRight = ref(false);
21
+ const parentRect = ref(null);
22
+ const horizontalGetter = ref(null);
23
+ const verticalGetter = ref(null);
24
+ const isTop = computed(() => verticalGetter.value?.isTop === true);
25
+ const isLeft = computed(() => horizontalGetter.value?.origin === OriginX.RIGHT);
26
+ const isRight = computed(() => horizontalGetter.value?.origin === OriginX.LEFT);
31
27
  const x = ref(0);
32
28
  const y = ref(0);
33
- const width = ref(0);
34
- const height = ref(0);
35
- const originX = ref(OriginX.LEFT);
36
- const originY = ref(OriginY.TOP);
37
29
  const order = computed(() => horizontalGetterOrderMap[props.horizontalAlign]);
38
- const setParentRect = (updateSize = false, updateAlign = false) => {
30
+ const setParentRect = (updateAlign = false) => {
39
31
  const newRect = props.parentElement.getBoundingClientRect();
40
- const isLeftChanged = newRect.left !== parentRect?.left;
41
- const isTopChanged = newRect.top !== parentRect?.top || newRect.bottom !== parentRect?.bottom;
42
- if (!horizontalGetter || isLeftChanged && (props.updateAlign || updateAlign)) {
43
- horizontalGetter = searchStyleGetter(order.value, newRect, props.maxWidth);
44
- originX.value = horizontalGetter.origin;
45
- isLeftCenter.value = horizontalGetter instanceof LeftCenter;
46
- isLeft.value = horizontalGetter instanceof LeftOuter || horizontalGetter instanceof LeftInner;
47
- isRight.value = horizontalGetter instanceof RightOuter || horizontalGetter instanceof RightInner;
48
- if (updateSize) width.value = horizontalGetter.widthStyleGetter(newRect, props.maxWidth);
32
+ const isLeftChanged = newRect.left !== parentRect.value?.left;
33
+ const isTopChanged = newRect.top !== parentRect.value?.top || newRect.bottom !== parentRect.value?.bottom;
34
+ if (!horizontalGetter.value || isLeftChanged && (props.updateAlign || updateAlign)) {
35
+ horizontalGetter.value = searchStyleGetter(order.value, newRect);
49
36
  }
50
- if (!verticalGetter || isTopChanged && (props.updateAlign || updateAlign)) {
51
- verticalGetter = props.top ? horizontalGetter.verticalGetterOrder[1] : props.bottom ? horizontalGetter.verticalGetterOrder[0] : searchStyleGetter(horizontalGetter.verticalGetterOrder, newRect, props.maxHeight);
52
- originY.value = verticalGetter.origin;
53
- isTop.value = verticalGetter.isTop;
54
- if (updateSize) height.value = verticalGetter.heightStyleGetter(newRect, props.maxHeight);
37
+ if (!verticalGetter.value || isTopChanged && (props.updateAlign || updateAlign)) {
38
+ verticalGetter.value = props.top && horizontalGetter.value.verticalGetterOrder[1] ? horizontalGetter.value.verticalGetterOrder[1] : props.bottom ? horizontalGetter.value.verticalGetterOrder[0] : searchStyleGetter(horizontalGetter.value.verticalGetterOrder, newRect);
55
39
  }
56
- if (isLeftChanged) x.value = horizontalGetter.styleGetter(newRect);
57
- if (isTopChanged) y.value = verticalGetter.styleGetter(newRect);
58
- if (isLeftChanged || isTopChanged) parentRect = newRect;
40
+ if (isLeftChanged) x.value = horizontalGetter.value.x(newRect);
41
+ if (isTopChanged) y.value = verticalGetter.value.y(newRect);
42
+ if (isLeftChanged || isTopChanged) parentRect.value = newRect;
59
43
  };
60
44
  onBeforeMount(() => {
61
45
  setParentRect(true);
@@ -84,7 +68,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
84
68
  domListenerContainer.destroy();
85
69
  });
86
70
  watch(toRef(props, "parentElement"), () => {
87
- setParentRect(false, true);
71
+ setParentRect(true);
88
72
  });
89
73
  __expose({
90
74
  update: () => {
@@ -99,22 +83,20 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
99
83
  "--dropdown-y": y.value + "px"
100
84
  }, { "transform": "translate(var(--dropdown-x, 0px), var(--dropdown-y, 0px))" }]),
101
85
  class: normalizeClass(["group/dropdown width-0 height-0 fixed left-0 top-0 grid will-change-transform", [
102
- {
103
- "dropdown-top": isTop.value
104
- },
105
- originX.value,
106
- originY.value
86
+ { "dropdown-top": isTop.value },
87
+ horizontalGetter.value?.origin,
88
+ verticalGetter.value?.origin
107
89
  ]])
108
90
  }, [
109
91
  createElementVNode("div", {
110
- style: normalizeStyle([{
111
- "--dropdown-width": width.value !== void 0 ? width.value + "px" : void 0,
112
- "--dropdown-height": height.value !== void 0 ? height.value + "px" : void 0,
113
- width: props.horizontalAlign === unref(HorizontalAlign).FILL ? "var(--dropdown-width)" : "max-content",
114
- minWidth: props.horizontalAlign === unref(HorizontalAlign).FILL_MIN ? "var(--dropdown-width)" : void 0
115
- }, { "max-width": "var(--dropdown-width)", "max-height": "var(--dropdown-height)" }])
92
+ class: "relative w-max",
93
+ style: normalizeStyle([
94
+ verticalGetter.value?.style,
95
+ horizontalGetter.value?.style,
96
+ parentRect.value ? horizontalGetter.value?.styleGetter?.(parentRect.value) : void 0
97
+ ])
116
98
  }, [
117
- renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ isTop: isTop.value, isLeft: isLeft.value, isRight: isRight.value, x: x.value, y: y.value, originX: originX.value, originY: originY.value })))
99
+ renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ isTop: isTop.value, isLeft: isLeft.value, isRight: isRight.value })))
118
100
  ], 4)
119
101
  ], 6);
120
102
  };
@@ -1,8 +1,5 @@
1
- import { OriginX, OriginY } from './utils/DropdownStyle';
2
1
  import { HorizontalAlign } from '../../utils/HorizontalAlign';
3
2
  export interface DropdownProps {
4
- maxHeight: number;
5
- maxWidth: number;
6
3
  horizontalAlign: HorizontalAlign;
7
4
  top?: boolean;
8
5
  bottom?: boolean;
@@ -11,10 +8,6 @@ export interface DropdownProps {
11
8
  emitUpdate?: boolean;
12
9
  }
13
10
  export type DropdownDefaultSlotScope = {
14
- x: number;
15
- y: number;
16
- originX: OriginX;
17
- originY: OriginY;
18
11
  isTop: boolean;
19
12
  isLeft: boolean;
20
13
  isRight: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,OAAO,EAAE,OAAO,EAAC,MAAM,uBAAuB,CAAA;AAC3D,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAA;AAE5D,MAAM,WAAW,aAAa;IAC5B,SAAS,EAAE,MAAM,CAAA;IACjB,QAAQ,EAAE,MAAM,CAAA;IAChB,eAAe,EAAE,eAAe,CAAA;IAChC,GAAG,CAAC,EAAE,OAAO,CAAA;IACb,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,aAAa,EAAE,IAAI,CAAC,OAAO,EAAE,uBAAuB,CAAC,CAAA;IACrD,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,MAAM,MAAM,wBAAwB,GAAG;IACrC,CAAC,EAAE,MAAM,CAAA;IACT,CAAC,EAAE,MAAM,CAAA;IACT,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,OAAO,CAAA;IAChB,KAAK,EAAE,OAAO,CAAA;IACd,MAAM,EAAE,OAAO,CAAA;IACf,OAAO,EAAE,OAAO,CAAA;CACjB,CAAA"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/Dropdown/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAA;AAE5D,MAAM,WAAW,aAAa;IAC5B,eAAe,EAAE,eAAe,CAAA;IAChC,GAAG,CAAC,EAAE,OAAO,CAAA;IACb,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,aAAa,EAAE,IAAI,CAAC,OAAO,EAAE,uBAAuB,CAAC,CAAA;IACrD,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,UAAU,CAAC,EAAE,OAAO,CAAA;CACrB;AAED,MAAM,MAAM,wBAAwB,GAAG;IACrC,KAAK,EAAE,OAAO,CAAA;IACd,MAAM,EAAE,OAAO,CAAA;IACf,OAAO,EAAE,OAAO,CAAA;CACjB,CAAA"}
@@ -1,91 +1,51 @@
1
1
  import { HorizontalAlign } from '../../../utils/HorizontalAlign';
2
- interface StyleGetter {
3
- styleGetter(parentRect: DOMRect): number;
4
- marginGetter(parentRect: DOMRect, maxHeightOrWidth: number): number;
5
- }
2
+ type StyleGetter = {
3
+ isEdge: ((parentRect: DOMRect) => boolean) | undefined;
4
+ };
6
5
  export declare enum OriginY {
7
6
  TOP = "content-start",
8
7
  BOTTOM = "content-end",
9
8
  CENTER = "content-center"
10
9
  }
11
- export declare abstract class VerticalGetter implements StyleGetter {
12
- abstract isTop: boolean;
13
- abstract origin: OriginY;
14
- abstract styleGetter(parentRect: DOMRect): number;
15
- abstract marginGetter(parentRect: DOMRect, maxHeight: number): number;
16
- heightStyleGetter(parentRect: DOMRect, maxHeight: number): number | undefined;
17
- }
18
- declare class BottomInner extends VerticalGetter {
19
- isTop: boolean;
20
- origin: OriginY;
21
- styleGetter(parentRect: DOMRect): number;
22
- marginGetter(parentRect: DOMRect, maxHeight: number): number;
23
- }
24
- declare class BottomOuter extends VerticalGetter {
25
- isTop: boolean;
26
- origin: OriginY;
27
- styleGetter(parentRect: DOMRect): number;
28
- marginGetter(parentRect: DOMRect, maxHeight: number): number;
29
- }
30
- declare class VerticalCenter extends VerticalGetter {
31
- isTop: boolean;
32
- origin: OriginY;
33
- styleGetter(parentRect: DOMRect): number;
34
- marginGetter(): number;
35
- heightStyleGetter(): undefined;
36
- }
37
- declare class TopOuter extends VerticalGetter {
38
- isTop: boolean;
39
- origin: OriginY;
40
- styleGetter(parentRect: DOMRect): number;
41
- marginGetter(parentRect: DOMRect, maxHeight: number): number;
42
- }
43
- declare class TopInner extends VerticalGetter {
10
+ export type VerticalGetter = {
44
11
  isTop: boolean;
45
12
  origin: OriginY;
46
- styleGetter(parentRect: DOMRect): number;
47
- marginGetter(parentRect: DOMRect, maxHeight: number): number;
48
- }
13
+ style?: Record<string, string>;
14
+ y: (parentRect: DOMRect) => number;
15
+ } & StyleGetter;
49
16
  export declare enum OriginX {
50
17
  LEFT = "justify-start",
51
18
  RIGHT = "justify-end",
52
19
  CENTER = "justify-center"
53
20
  }
54
- export declare abstract class HorizontalGetter implements StyleGetter {
55
- abstract origin: OriginX;
56
- abstract verticalGetterOrder: Array<VerticalGetter>;
57
- abstract styleGetter(parentRect: DOMRect): number;
58
- abstract marginGetter(parentRect: DOMRect, maxWidth: number): number;
59
- widthStyleGetter(parentRect: DOMRect, maxWidth: number): number | undefined;
60
- }
61
- export declare class RightOuter extends HorizontalGetter {
62
- verticalGetterOrder: (BottomInner | TopInner)[];
63
- origin: OriginX;
64
- styleGetter(parentRect: DOMRect): number;
65
- marginGetter(parentRect: DOMRect, maxWidth: number): number;
66
- }
67
- export declare class RightInner extends HorizontalGetter {
68
- verticalGetterOrder: (BottomOuter | TopOuter)[];
21
+ export type HorizontalGetter = {
22
+ verticalGetterOrder: [VerticalGetter, VerticalGetter] | [VerticalGetter];
69
23
  origin: OriginX;
70
- styleGetter(parentRect: DOMRect): number;
71
- marginGetter(parentRect: DOMRect, maxWidth: number): number;
72
- }
73
- export declare class LeftInner extends HorizontalGetter {
74
- verticalGetterOrder: (BottomOuter | TopOuter)[];
75
- origin: OriginX;
76
- styleGetter(parentRect: DOMRect): number;
77
- marginGetter(parentRect: DOMRect, maxWidth: number): number;
78
- }
79
- export declare class LeftOuter extends HorizontalGetter {
80
- verticalGetterOrder: (BottomInner | TopInner)[];
81
- origin: OriginX;
82
- styleGetter(parentRect: DOMRect): number;
83
- marginGetter(parentRect: DOMRect, maxWidth: number): number;
84
- }
85
- export declare class LeftCenter extends LeftOuter {
86
- verticalGetterOrder: VerticalCenter[];
87
- }
88
- export declare const horizontalGetterOrderMap: Record<HorizontalAlign, HorizontalGetter[]>;
89
- export declare function searchStyleGetter<T extends StyleGetter>(order: Array<T>, parentRect: DOMRect, maxHeightOrWidth: number): T;
24
+ style?: Record<string, string> | undefined;
25
+ styleGetter?: (parentRect: DOMRect) => Record<string, string>;
26
+ x: (parentRect: DOMRect) => number;
27
+ } & StyleGetter;
28
+ /**
29
+ * [ ] →
30
+ */
31
+ export declare const RightOuter: HorizontalGetter;
32
+ /**
33
+ * → [ ]
34
+ */
35
+ export declare const RightInner: HorizontalGetter;
36
+ /**
37
+ * [ ]
38
+ */
39
+ export declare const LeftInner: HorizontalGetter;
40
+ /**
41
+ * ← [ ]
42
+ */
43
+ export declare const LeftOuter: HorizontalGetter;
44
+ /**
45
+ * ← [x]
46
+ */
47
+ export declare const LeftCenter: HorizontalGetter;
48
+ export declare const horizontalGetterOrderMap: Record<HorizontalAlign, [HorizontalGetter, HorizontalGetter] | [HorizontalGetter]>;
49
+ export declare function searchStyleGetter<T extends HorizontalGetter | VerticalGetter>(order: Array<T>, parentRect: DOMRect): T;
90
50
  export {};
91
51
  //# sourceMappingURL=DropdownStyle.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownStyle.d.ts","sourceRoot":"","sources":["../../../../../src/components/Dropdown/utils/DropdownStyle.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAA;AAIvD,UAAU,WAAW;IACnB,WAAW,CAAC,UAAU,EAAE,OAAO,GAAG,MAAM,CAAA;IACxC,YAAY,CAAC,UAAU,EAAE,OAAO,EAAE,gBAAgB,EAAE,MAAM,GAAG,MAAM,CAAA;CACpE;AAED,oBAAY,OAAO;IACjB,GAAG,kBAAkB;IACrB,MAAM,gBAAgB;IACtB,MAAM,mBAAmB;CAC1B;AAED,8BAAsB,cAAe,YAAW,WAAW;IACzD,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAA;IACvB,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAA;IAExB,QAAQ,CAAC,WAAW,CAAC,UAAU,EAAE,OAAO,GAAG,MAAM;IAEjD,QAAQ,CAAC,YAAY,CAAC,UAAU,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM;IAErE,iBAAiB,CAAC,UAAU,EAAE,OAAO,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS;CAG9E;AAED,cAAM,WAAY,SAAQ,cAAc;IACtC,KAAK,UAAQ;IACb,MAAM,UAAc;IAEpB,WAAW,CAAC,UAAU,EAAE,OAAO;IAI/B,YAAY,CAAC,UAAU,EAAE,OAAO,EAAE,SAAS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