ninemoon-ui 0.0.1 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -1158,7 +1158,7 @@
1158
1158
  }`;
1159
1159
  document.head.appendChild(__vite_style__);
1160
1160
  const _hoisted_1$l = { class: "tdd-pointer-events-none tdd-fixed tdd-right-0 tdd-left-0 tdd-bottom-0 tdd-top-4 tdd-z-2000 tdd-space-y-5" };
1161
- const _hoisted_2$h = { class: "tdd-pointer-events-auto tdd-inline-flex tdd-items-center tdd-space-x-3 tdd-bg-white tdd-p-3 tdd-text-sm tdd-text-word3 tdd-drop-shadow" };
1161
+ const _hoisted_2$g = { class: "tdd-pointer-events-auto tdd-inline-flex tdd-items-center tdd-space-x-3 tdd-bg-white tdd-p-3 tdd-text-sm tdd-text-word3 tdd-drop-shadow" };
1162
1162
  const _hoisted_3$e = {
1163
1163
  key: 0,
1164
1164
  class: "tdd-h-4 tdd-w-4 tdd-fill-white",
@@ -1352,7 +1352,7 @@
1352
1352
  class: "tdd-w-full tdd-text-center",
1353
1353
  key: i.key
1354
1354
  }, [
1355
- vue.createElementVNode("div", _hoisted_2$h, [
1355
+ vue.createElementVNode("div", _hoisted_2$g, [
1356
1356
  vue.createElementVNode("div", {
1357
1357
  class: vue.normalizeClass(["tdd-flex tdd-h-5 tdd-w-5 tdd-items-center tdd-justify-center tdd-rounded-full", {
1358
1358
  "tdd-bg-green-400": i.type === "success",
@@ -1454,7 +1454,7 @@
1454
1454
  key: 0,
1455
1455
  class: "tdd-fixed tdd-top-0 tdd-right-0 tdd-left-0 tdd-bottom-0 tdd-z-1000 tdd-flex tdd-items-center tdd-justify-center"
1456
1456
  };
1457
- const _hoisted_2$g = {
1457
+ const _hoisted_2$f = {
1458
1458
  key: 0,
1459
1459
  class: "tdd-absolute tdd-top-0 tdd-right-0 tdd-left-0 tdd-bottom-0 tdd-bg-black tdd-bg-opacity-30"
1460
1460
  };
@@ -1509,7 +1509,7 @@
1509
1509
  return (_ctx, _cache) => {
1510
1510
  return vue.openBlock(), vue.createBlock(vue.Teleport, { to: "body" }, [
1511
1511
  showTip.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$k, [
1512
- myoption.bgshow ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$g)) : vue.createCommentVNode("", true),
1512
+ myoption.bgshow ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$f)) : vue.createCommentVNode("", true),
1513
1513
  vue.createElementVNode("div", _hoisted_3$d, [
1514
1514
  vue.createElementVNode("div", _hoisted_4$a, [
1515
1515
  _hoisted_5$6,
@@ -1621,7 +1621,7 @@
1621
1621
  })
1622
1622
  ])
1623
1623
  ], -1);
1624
- const _hoisted_2$f = { class: "tdd-mt-3 tdd-text-sm tdd-font-medium tdd-text-word9" };
1624
+ const _hoisted_2$e = { class: "tdd-mt-3 tdd-text-sm tdd-font-medium tdd-text-word9" };
1625
1625
  const _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
1626
1626
  __name: "loadcomponent",
1627
1627
  setup(__props, { expose: __expose }) {
@@ -1636,7 +1636,7 @@
1636
1636
  class: vue.normalizeClass(["tdd-top-0 tdd-right-0 tdd-left-0 tdd-bottom-0 tdd-z-50 tdd-flex tdd-h-full tdd-w-full tdd-flex-col tdd-items-center tdd-justify-center tdd-bg-white tdd-bg-opacity-90", fullScreen.value ? "fixed" : "absolute"])
1637
1637
  }, [
1638
1638
  _hoisted_1$j,
1639
- vue.createElementVNode("div", _hoisted_2$f, vue.toDisplayString(loaddingWord.value), 1)
1639
+ vue.createElementVNode("div", _hoisted_2$e, vue.toDisplayString(loaddingWord.value), 1)
1640
1640
  ], 2);
1641
1641
  };
1642
1642
  }
@@ -1915,7 +1915,7 @@
1915
1915
  }
1916
1916
  };
1917
1917
  const _hoisted_1$i = ["onClick"];
1918
- const _hoisted_2$e = {
1918
+ const _hoisted_2$d = {
1919
1919
  key: 0,
1920
1920
  class: "tdd-flex tdd-w-full tdd-justify-between tdd-p-2"
1921
1921
  };
@@ -2027,7 +2027,7 @@
2027
2027
  class: vue.normalizeClass(["tdd-z-50 tdd-divide-y tdd-divide-gray-300 tdd-rounded tdd-drop-shadow", { "tdd-w-96": !hasselfwidth.value, "tdd-bg-white": !_ctx.isDiy }]),
2028
2028
  style: vue.normalizeStyle({ width: selfwidth.value })
2029
2029
  }, [
2030
- showdefaultHand.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$e, [
2030
+ showdefaultHand.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$d, [
2031
2031
  vue.createElementVNode("span", null, vue.toDisplayString(_ctx.title), 1),
2032
2032
  vue.createElementVNode("button", {
2033
2033
  type: "button",
@@ -2140,7 +2140,7 @@
2140
2140
  default: _sfc_main$s
2141
2141
  }, Symbol.toStringTag, { value: "Module" }));
2142
2142
  const _hoisted_1$h = { class: "tdd-mb-5" };
2143
- const _hoisted_2$d = { class: "tdd-relative tdd-flex-1 tdd-items-center" };
2143
+ const _hoisted_2$c = { class: "tdd-relative tdd-flex-1 tdd-items-center" };
2144
2144
  const _hoisted_3$b = {
2145
2145
  key: 0,
2146
2146
  class: "tdd-absolute tdd--bottom-5 tdd-left-0 tdd-text-xs tdd-text-red-600"
@@ -2293,7 +2293,7 @@
2293
2293
  class: "tdd-text-sm",
2294
2294
  style: vue.normalizeStyle({ width: `${_ctx.width}px` })
2295
2295
  }, vue.toDisplayString(_ctx.label), 5),
2296
- vue.createElementVNode("div", _hoisted_2$d, [
2296
+ vue.createElementVNode("div", _hoisted_2$c, [
2297
2297
  vue.renderSlot(_ctx.$slots, "default"),
2298
2298
  showTip.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3$b, vue.toDisplayString(tip.value), 1)) : vue.createCommentVNode("", true)
2299
2299
  ])
@@ -2307,7 +2307,7 @@
2307
2307
  default: _sfc_main$r
2308
2308
  }, Symbol.toStringTag, { value: "Module" }));
2309
2309
  const _hoisted_1$g = { class: "tdd-relative tdd-flex tdd-h-full tdd-w-full tdd-items-center tdd-overflow-hidden tdd-rounded tdd-border tdd-border-solid" };
2310
- const _hoisted_2$c = ["placeholder", "type"];
2310
+ const _hoisted_2$b = ["placeholder", "type"];
2311
2311
  const _hoisted_3$a = /* @__PURE__ */ vue.createElementVNode("path", { d: "M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z" }, null, -1);
2312
2312
  const _hoisted_4$8 = [
2313
2313
  _hoisted_3$a
@@ -2372,7 +2372,7 @@
2372
2372
  onBlur: defaultEvent,
2373
2373
  onInput: defaultEvent,
2374
2374
  onChange: defaultEvent
2375
- }, null, 40, _hoisted_2$c), [
2375
+ }, null, 40, _hoisted_2$b), [
2376
2376
  [vue.vModelDynamic, inputValue.value]
2377
2377
  ]),
2378
2378
  vue.withDirectives((vue.openBlock(), vue.createElementBlock("svg", {
@@ -2397,8 +2397,7 @@
2397
2397
  __proto__: null,
2398
2398
  default: _sfc_main$q
2399
2399
  }, Symbol.toStringTag, { value: "Module" }));
2400
- const _hoisted_1$f = { class: "tdd-absolute tdd-z-2000 tdd-rounded-sm tdd-bg-white tdd-text-sm tdd-drop-shadow tdd-mt-1" };
2401
- const _hoisted_2$b = ["value", "disabled", "readonly", "placeholder"];
2400
+ const _hoisted_1$f = ["value", "disabled", "readonly", "placeholder"];
2402
2401
  const _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
2403
2402
  __name: "select",
2404
2403
  props: {
@@ -2492,7 +2491,7 @@
2492
2491
  trigger: "native",
2493
2492
  modelValue: showOption.value,
2494
2493
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => showOption.value = $event),
2495
- insertClass: "tdd-min-w-[200px]",
2494
+ insertClass: "tdd-min-w-[200px] tdd-z-2000 tdd-text-sm",
2496
2495
  placement: "bottomleft"
2497
2496
  }, {
2498
2497
  reference: vue.withCtx(() => [
@@ -2507,18 +2506,16 @@
2507
2506
  readonly: !_ctx.filter,
2508
2507
  class: "tdd-h-full tdd-w-full tdd-cursor-pointer tdd-appearance-none tdd-p-2 tdd-text-sm tdd-outline-none",
2509
2508
  placeholder: _ctx.placeHolder
2510
- }, null, 8, _hoisted_2$b)
2509
+ }, null, 8, _hoisted_1$f)
2511
2510
  ])
2512
2511
  ]),
2513
2512
  default: vue.withCtx(() => [
2514
- vue.createElementVNode("div", _hoisted_1$f, [
2515
- vue.createVNode(vue.unref(LibScrollBar2), { isSelectdom: true }, {
2516
- default: vue.withCtx(() => [
2517
- vue.createVNode(renderOption)
2518
- ]),
2519
- _: 1
2520
- })
2521
- ])
2513
+ vue.createVNode(vue.unref(LibScrollBar2), { isSelectdom: true }, {
2514
+ default: vue.withCtx(() => [
2515
+ vue.createVNode(renderOption)
2516
+ ]),
2517
+ _: 1
2518
+ })
2522
2519
  ]),
2523
2520
  _: 1
2524
2521
  }, 8, ["modelValue"]);
@@ -2601,9 +2598,6 @@
2601
2598
  vue.h("input", {
2602
2599
  type: "checkbox",
2603
2600
  "onUpdate:modelValue": (value) => allSelect.value = value,
2604
- onChange: () => {
2605
- allSelect.value ? allSelection() : toggleAllSelection();
2606
- },
2607
2601
  class: "tdd-appearance-none form-tick tdd-h-4 tdd-w-4 tdd-border tdd-border-gray-300 tdd-rounded checked:tdd-border-transparent checked:tdd-bg-red-600 tdd-text-red-600 focus:tdd-outline-none"
2608
2602
  }),
2609
2603
  [[vue.vModelCheckbox, allSelect.value]]
@@ -2629,15 +2623,6 @@
2629
2623
  const clearSelection = () => {
2630
2624
  choosed.value = [];
2631
2625
  };
2632
- const a = () => {
2633
- let arr = [
2634
- { a: 1, b: 3 },
2635
- { a: 3, b: 6 },
2636
- { a: 0, b: 9 }
2637
- ];
2638
- return arr.map((i) => i.a);
2639
- };
2640
- a();
2641
2626
  const allSelection = () => {
2642
2627
  let temp = [];
2643
2628
  for (let i = 0; i < props.data.length; i++) {
@@ -3583,19 +3568,23 @@
3583
3568
  }
3584
3569
  });
3585
3570
  const activeinputIndex = vue.ref(-1);
3586
- const showD = vue.computed(() => activeinputIndex.value !== -1);
3571
+ const showD = vue.ref(false);
3587
3572
  const hideDatePick = () => {
3588
3573
  tempaim.value = "";
3589
3574
  activeinputIndex.value = -1;
3575
+ showD.value = false;
3590
3576
  };
3591
3577
  const inputOne = vue.ref(null);
3592
3578
  const inputTwo = vue.ref(null);
3593
3579
  const FloatLeft = vue.ref(0);
3594
3580
  const FloatWidth = vue.ref(0);
3595
3581
  const setActiveHandle = (i) => {
3582
+ showD.value = true;
3596
3583
  activeinputIndex.value = i;
3597
3584
  const LeftArr = [inputOne.value.offsetLeft, inputTwo.value.offsetLeft];
3585
+ const widthArr = [inputOne.value.offsetWidth, inputTwo.value.offsetWidth];
3598
3586
  FloatLeft.value = LeftArr[i];
3587
+ FloatWidth.value = widthArr[i];
3599
3588
  if (i === 0) {
3600
3589
  if (date1.value !== null && date1.value !== void 0 && date1.value !== "") {
3601
3590
  const [y, m] = date1.value.split("-").map((i2) => parseInt(i2));
@@ -3844,7 +3833,7 @@
3844
3833
  return vue.openBlock(), vue.createBlock(vue.unref(Pop), {
3845
3834
  width: "512",
3846
3835
  insertClass: "tdd-z-2000 !tdd-p-0",
3847
- trigger: "native",
3836
+ trigger: "click",
3848
3837
  modelValue: showD.value,
3849
3838
  "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => showD.value = $event),
3850
3839
  placement: "bottomleft"
@@ -3870,12 +3859,10 @@
3870
3859
  ref_key: "inputTwo",
3871
3860
  ref: inputTwo
3872
3861
  }, null, 40, _hoisted_26),
3873
- vue.withDirectives(vue.createElementVNode("div", {
3862
+ vue.createElementVNode("div", {
3874
3863
  class: "tdd-h-0.5 tdd-bg-blue-600 tdd-absolute tdd-transition-all tdd-bottom-0",
3875
3864
  style: vue.normalizeStyle({ width: `${FloatWidth.value}px`, left: `${FloatLeft.value}px` })
3876
- }, null, 4), [
3877
- [vue.vShow, showD.value]
3878
- ])
3865
+ }, null, 4)
3879
3866
  ])
3880
3867
  ]),
3881
3868
  default: vue.withCtx(() => [
@@ -1,4 +1,4 @@
1
- import { defineComponent, defineAsyncComponent, computed, ref, openBlock, createBlock, unref, withCtx, createElementVNode, withDirectives, normalizeStyle, vShow, toDisplayString, createTextVNode, createElementBlock, Fragment, renderList, normalizeClass } from "vue";
1
+ import { defineComponent, defineAsyncComponent, computed, ref, openBlock, createBlock, unref, withCtx, createElementVNode, normalizeStyle, toDisplayString, createTextVNode, createElementBlock, Fragment, renderList, normalizeClass } from "vue";
2
2
  import { g as getNewArray } from "../index/index.js";
3
3
  import { a as addZero, g as getMonthDays } from "../getcalendar/getcalendar.js";
4
4
  const _hoisted_1 = { class: "tdd-flex tdd-justify-between tdd-items-center tdd-p-3" };
@@ -137,19 +137,23 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
137
137
  }
138
138
  });
139
139
  const activeinputIndex = ref(-1);
140
- const showD = computed(() => activeinputIndex.value !== -1);
140
+ const showD = ref(false);
141
141
  const hideDatePick = () => {
142
142
  tempaim.value = "";
143
143
  activeinputIndex.value = -1;
144
+ showD.value = false;
144
145
  };
145
146
  const inputOne = ref(null);
146
147
  const inputTwo = ref(null);
147
148
  const FloatLeft = ref(0);
148
149
  const FloatWidth = ref(0);
149
150
  const setActiveHandle = (i) => {
151
+ showD.value = true;
150
152
  activeinputIndex.value = i;
151
153
  const LeftArr = [inputOne.value.offsetLeft, inputTwo.value.offsetLeft];
154
+ const widthArr = [inputOne.value.offsetWidth, inputTwo.value.offsetWidth];
152
155
  FloatLeft.value = LeftArr[i];
156
+ FloatWidth.value = widthArr[i];
153
157
  if (i === 0) {
154
158
  if (date1.value !== null && date1.value !== void 0 && date1.value !== "") {
155
159
  const [y, m] = date1.value.split("-").map((i2) => parseInt(i2));
@@ -398,7 +402,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
398
402
  return openBlock(), createBlock(unref(Pop), {
399
403
  width: "512",
400
404
  insertClass: "tdd-z-2000 !tdd-p-0",
401
- trigger: "native",
405
+ trigger: "click",
402
406
  modelValue: showD.value,
403
407
  "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => showD.value = $event),
404
408
  placement: "bottomleft"
@@ -424,12 +428,10 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
424
428
  ref_key: "inputTwo",
425
429
  ref: inputTwo
426
430
  }, null, 40, _hoisted_26),
427
- withDirectives(createElementVNode("div", {
431
+ createElementVNode("div", {
428
432
  class: "tdd-h-0.5 tdd-bg-blue-600 tdd-absolute tdd-transition-all tdd-bottom-0",
429
433
  style: normalizeStyle({ width: `${FloatWidth.value}px`, left: `${FloatLeft.value}px` })
430
- }, null, 4), [
431
- [vShow, showD.value]
432
- ])
434
+ }, null, 4)
433
435
  ])
434
436
  ]),
435
437
  default: withCtx(() => [
@@ -1,6 +1,5 @@
1
1
  import { defineComponent, defineAsyncComponent, inject, useSlots, ref, computed, watch, openBlock, createBlock, unref, withCtx, createElementVNode, createVNode, h } from "vue";
2
- const _hoisted_1 = { class: "tdd-absolute tdd-z-2000 tdd-rounded-sm tdd-bg-white tdd-text-sm tdd-drop-shadow tdd-mt-1" };
3
- const _hoisted_2 = ["value", "disabled", "readonly", "placeholder"];
2
+ const _hoisted_1 = ["value", "disabled", "readonly", "placeholder"];
4
3
  const _sfc_main = /* @__PURE__ */ defineComponent({
5
4
  __name: "select",
6
5
  props: {
@@ -94,7 +93,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
94
93
  trigger: "native",
95
94
  modelValue: showOption.value,
96
95
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => showOption.value = $event),
97
- insertClass: "tdd-min-w-[200px]",
96
+ insertClass: "tdd-min-w-[200px] tdd-z-2000 tdd-text-sm",
98
97
  placement: "bottomleft"
99
98
  }, {
100
99
  reference: withCtx(() => [
@@ -109,18 +108,16 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
109
108
  readonly: !_ctx.filter,
110
109
  class: "tdd-h-full tdd-w-full tdd-cursor-pointer tdd-appearance-none tdd-p-2 tdd-text-sm tdd-outline-none",
111
110
  placeholder: _ctx.placeHolder
112
- }, null, 8, _hoisted_2)
111
+ }, null, 8, _hoisted_1)
113
112
  ])
114
113
  ]),
115
114
  default: withCtx(() => [
116
- createElementVNode("div", _hoisted_1, [
117
- createVNode(unref(LibScrollBar), { isSelectdom: true }, {
118
- default: withCtx(() => [
119
- createVNode(renderOption)
120
- ]),
121
- _: 1
122
- })
123
- ])
115
+ createVNode(unref(LibScrollBar), { isSelectdom: true }, {
116
+ default: withCtx(() => [
117
+ createVNode(renderOption)
118
+ ]),
119
+ _: 1
120
+ })
124
121
  ]),
125
122
  _: 1
126
123
  }, 8, ["modelValue"]);
@@ -54,9 +54,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
54
54
  h("input", {
55
55
  type: "checkbox",
56
56
  "onUpdate:modelValue": (value) => allSelect.value = value,
57
- onChange: () => {
58
- allSelect.value ? allSelection() : toggleAllSelection();
59
- },
60
57
  class: "tdd-appearance-none form-tick tdd-h-4 tdd-w-4 tdd-border tdd-border-gray-300 tdd-rounded checked:tdd-border-transparent checked:tdd-bg-red-600 tdd-text-red-600 focus:tdd-outline-none"
61
58
  }),
62
59
  [[vModelCheckbox, allSelect.value]]
@@ -82,15 +79,6 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
82
79
  const clearSelection = () => {
83
80
  choosed.value = [];
84
81
  };
85
- const a = () => {
86
- let arr = [
87
- { a: 1, b: 3 },
88
- { a: 3, b: 6 },
89
- { a: 0, b: 9 }
90
- ];
91
- return arr.map((i) => i.a);
92
- };
93
- a();
94
82
  const allSelection = () => {
95
83
  let temp = [];
96
84
  for (let i = 0; i < props.data.length; i++) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ninemoon-ui",
3
3
  "private": false,
4
- "version": "0.0.1",
4
+ "version": "0.0.3",
5
5
  "author": "zhuboy",
6
6
  "keywords": [
7
7
  "vue3",