@nutui/nutui 4.3.1 → 4.3.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.
Files changed (130) hide show
  1. package/CHANGELOG.md +44 -0
  2. package/dist/nutui.es.js +2 -4
  3. package/dist/nutui.js +6035 -6408
  4. package/dist/nutui.umd.js +1 -1
  5. package/dist/packages/actionsheet/ActionSheet.js +1 -1
  6. package/dist/packages/address/Address.js +1 -1
  7. package/dist/packages/addresslist/AddressList.js +2 -2
  8. package/dist/packages/animate/Animate.js +51 -44
  9. package/dist/packages/backtop/Backtop.js +79 -89
  10. package/dist/packages/calendar/Calendar.js +814 -3
  11. package/dist/packages/calendar/index.scss +0 -1
  12. package/dist/packages/calendarcard/CalendarCard.js +1 -1
  13. package/dist/packages/card/Card.js +4 -4
  14. package/dist/packages/cascader/Cascader.js +1 -1
  15. package/dist/packages/checkbox/Checkbox.js +1 -1
  16. package/dist/packages/circleprogress/CircleProgress.js +90 -97
  17. package/dist/packages/col/Col.js +41 -30
  18. package/dist/packages/comment/Comment.js +2 -2
  19. package/dist/packages/{common-LvGbU-A3.js → common-FZL3qC99.js} +5 -2
  20. package/dist/packages/dialog/Dialog.js +1 -1
  21. package/dist/packages/ecard/Ecard.js +2 -2
  22. package/dist/packages/form/Form.js +3 -1
  23. package/dist/packages/formitem/FormItem.js +1 -1
  24. package/dist/packages/imagepreview/ImagePreview.js +1 -1
  25. package/dist/packages/{index-wY4t0zYt.js → index-BqB5dTeo.js} +29 -17
  26. package/dist/packages/{index.vue_vue_type_script_lang-w2sgcysj.js → index.vue_vue_type_script_lang-n0HbjvfF.js} +1 -1
  27. package/dist/packages/input/Input.js +8 -8
  28. package/dist/packages/inputnumber/InputNumber.js +84 -103
  29. package/dist/packages/invoice/Invoice.js +87 -138
  30. package/dist/packages/layout/Layout.js +3 -0
  31. package/dist/packages/menuitem/MenuItem.js +1 -1
  32. package/dist/packages/navbar/Navbar.js +103 -115
  33. package/dist/packages/notify/Notify.js +1 -1
  34. package/dist/packages/numberkeyboard/NumberKeyboard.js +1 -1
  35. package/dist/packages/popover/Popover.js +1 -1
  36. package/dist/packages/popup/Popup.js +1 -1
  37. package/dist/packages/price/Price.js +69 -77
  38. package/dist/packages/progress/Progress.js +96 -115
  39. package/dist/packages/radio/Radio.js +1 -1
  40. package/dist/packages/range/Range.js +1 -1
  41. package/dist/packages/rate/Rate.js +99 -141
  42. package/dist/packages/row/Row.js +43 -39
  43. package/dist/packages/searchbar/Searchbar.js +1 -1
  44. package/dist/packages/shortpassword/ShortPassword.js +1 -1
  45. package/dist/packages/sku/Sku.js +5 -5
  46. package/dist/packages/swipe/Swipe.js +96 -110
  47. package/dist/packages/swipegroup/SwipeGroup.js +41 -23
  48. package/dist/packages/switch/Switch.js +12 -4
  49. package/dist/packages/switch/index.css +1 -1
  50. package/dist/packages/switch/index.scss +1 -1
  51. package/dist/packages/tag/Tag.js +57 -66
  52. package/dist/packages/textarea/Textarea.js +1 -1
  53. package/dist/packages/timeselect/TimeSelect.js +1 -1
  54. package/dist/packages/uploader/Uploader.js +5 -5
  55. package/dist/smartips/web-types.json +12 -3
  56. package/dist/style.css +1 -1
  57. package/dist/styles/base-jdb.css +1 -1
  58. package/dist/styles/base-jddkh.css +1 -1
  59. package/dist/styles/base-jdt.css +1 -1
  60. package/dist/styles/themes/default.scss +0 -1
  61. package/dist/styles/themes/jdb.scss +0 -1
  62. package/dist/styles/themes/jddkh.scss +0 -1
  63. package/dist/styles/themes/jdt.scss +0 -1
  64. package/dist/styles/variables-jdb.scss +0 -1
  65. package/dist/styles/variables-jddkh.scss +0 -1
  66. package/dist/styles/variables-jdt.scss +0 -1
  67. package/dist/styles/variables.scss +0 -1
  68. package/dist/types/__VUE/animate/animate.vue.d.ts +75 -0
  69. package/dist/types/__VUE/animate/index.d.ts +6 -0
  70. package/dist/types/__VUE/backtop/backtop.vue.d.ts +87 -0
  71. package/dist/types/__VUE/backtop/index.d.ts +5 -0
  72. package/dist/types/__VUE/calendaritem/index.vue.d.ts +2 -12
  73. package/dist/types/__VUE/circleprogress/circle-progress.vue.d.ts +88 -0
  74. package/dist/types/__VUE/circleprogress/index.d.ts +6 -0
  75. package/dist/types/__VUE/col/col.vue.d.ts +53 -0
  76. package/dist/types/__VUE/col/index.d.ts +5 -0
  77. package/dist/types/__VUE/form/common.d.ts +2 -0
  78. package/dist/types/__VUE/form/types.d.ts +0 -1
  79. package/dist/types/__VUE/input/index.vue.d.ts +1 -1
  80. package/dist/types/__VUE/inputnumber/index.d.ts +5 -0
  81. package/dist/types/__VUE/inputnumber/input-number.vue.d.ts +112 -0
  82. package/dist/types/__VUE/invoice/index.d.ts +6 -0
  83. package/dist/types/__VUE/invoice/invoice.vue.d.ts +59 -0
  84. package/dist/types/__VUE/invoice/types.d.ts +12 -0
  85. package/dist/types/__VUE/layout/index.d.ts +4 -0
  86. package/dist/types/__VUE/layout/layout.vue.d.ts +10 -0
  87. package/dist/types/__VUE/navbar/index.d.ts +5 -0
  88. package/dist/types/__VUE/navbar/navbar.vue.d.ts +125 -0
  89. package/dist/types/__VUE/price/index.d.ts +6 -0
  90. package/dist/types/__VUE/price/price.vue.d.ts +83 -0
  91. package/dist/types/__VUE/progress/index.d.ts +6 -0
  92. package/dist/types/__VUE/progress/progress.vue.d.ts +91 -0
  93. package/dist/types/__VUE/rate/index.d.ts +5 -0
  94. package/dist/types/__VUE/rate/rate.vue.d.ts +208 -0
  95. package/dist/types/__VUE/row/index.d.ts +5 -0
  96. package/dist/types/__VUE/row/row.vue.d.ts +71 -0
  97. package/dist/types/__VUE/swipe/index.d.ts +6 -0
  98. package/dist/types/__VUE/swipe/swipe.vue.d.ts +79 -0
  99. package/dist/types/__VUE/swipe/types.d.ts +1 -0
  100. package/dist/types/__VUE/swipegroup/index.d.ts +5 -0
  101. package/dist/types/__VUE/swipegroup/swipe-group.vue.d.ts +47 -0
  102. package/dist/types/__VUE/switch/index.vue.d.ts +9 -0
  103. package/dist/types/__VUE/tag/index.d.ts +6 -0
  104. package/dist/types/__VUE/tag/tag.vue.d.ts +90 -0
  105. package/dist/types/__VUE/tag/types.d.ts +1 -1
  106. package/dist/types/index.d.ts +32 -18
  107. package/package.json +1 -1
  108. package/dist/packages/calendaritem/CalendarItem.js +0 -819
  109. package/dist/packages/calendaritem/index.css +0 -0
  110. package/dist/packages/calendaritem/index.mjs +0 -2
  111. package/dist/packages/calendaritem/index.scss +0 -0
  112. package/dist/packages/calendaritem/style/css.mjs +0 -2
  113. package/dist/packages/calendaritem/style/index.mjs +0 -2
  114. package/dist/packages/types-Ynmct7na.js +0 -4
  115. package/dist/types/__VUE/animate/index.vue.d.ts +0 -71
  116. package/dist/types/__VUE/backtop/index.vue.d.ts +0 -98
  117. package/dist/types/__VUE/circleprogress/index.vue.d.ts +0 -95
  118. package/dist/types/__VUE/col/index.vue.d.ts +0 -42
  119. package/dist/types/__VUE/inputnumber/index.vue.d.ts +0 -117
  120. package/dist/types/__VUE/invoice/index.vue.d.ts +0 -53
  121. package/dist/types/__VUE/layout/index.vue.d.ts +0 -12
  122. package/dist/types/__VUE/navbar/index.vue.d.ts +0 -129
  123. package/dist/types/__VUE/price/index.vue.d.ts +0 -97
  124. package/dist/types/__VUE/progress/index.vue.d.ts +0 -120
  125. package/dist/types/__VUE/rate/index.vue.d.ts +0 -240
  126. package/dist/types/__VUE/row/index.vue.d.ts +0 -62
  127. package/dist/types/__VUE/swipe/index.vue.d.ts +0 -70
  128. package/dist/types/__VUE/swipegroup/index.vue.d.ts +0 -26
  129. package/dist/types/__VUE/tag/index.vue.d.ts +0 -94
  130. /package/dist/types/__VUE/animate/{type.d.ts → types.d.ts} +0 -0
@@ -19,7 +19,7 @@ var __spreadValues = (a, b) => {
19
19
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  import { c as createComponent } from "../component-TCzwHGVq.js";
21
21
  import { useSlots, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, createElementBlock, toDisplayString, createCommentVNode, renderSlot, Fragment, renderList, normalizeClass, normalizeStyle } from "vue";
22
- import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
22
+ import { N as NutPopup, p as popupProps } from "../index-BqB5dTeo.js";
23
23
  import { Loading } from "@nutui/icons-vue";
24
24
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
25
25
  const { create } = createComponent("action-sheet");
@@ -20,7 +20,7 @@ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
20
  import { ref, reactive, computed, watch, toRefs, nextTick, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, renderSlot, withDirectives, createVNode, vShow, toDisplayString, createElementBlock, Fragment, renderList, normalizeClass, createCommentVNode, normalizeStyle, createTextVNode } from "vue";
21
21
  import { Location, Location2, Check, Close, Left } from "@nutui/icons-vue";
22
22
  import { c as createComponent } from "../component-TCzwHGVq.js";
23
- import { N as NutPopup, p as popupProps } from "../index-wY4t0zYt.js";
23
+ import { N as NutPopup, p as popupProps } from "../index-BqB5dTeo.js";
24
24
  import NutElevator from "../elevator/Elevator.js";
25
25
  import { u as useLocale } from "../index-s3RgMhc7.js";
26
26
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
@@ -5,7 +5,7 @@ import { u as useLocale } from "../index-s3RgMhc7.js";
5
5
  import { Del, Edit } from "@nutui/icons-vue";
6
6
  import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
7
7
  import { Button as _sfc_main$3 } from "../button/Button.js";
8
- import NutSwipe from "../swipe/Swipe.js";
8
+ import { Swipe as _sfc_main$4 } from "../swipe/Swipe.js";
9
9
  const { create: create$2 } = createComponent("address-list-item");
10
10
  const cN$1 = "NutAddressList";
11
11
  const _sfc_main$2 = create$2({
@@ -107,7 +107,7 @@ const _sfc_main$1 = create$1({
107
107
  components: {
108
108
  ItemContents,
109
109
  NutButton: _sfc_main$3,
110
- NutSwipe
110
+ NutSwipe: _sfc_main$4
111
111
  },
112
112
  setup(props, { emit }) {
113
113
  const renderCompontent = () => {
@@ -1,32 +1,40 @@
1
- import { ref, computed, watch, openBlock, createElementBlock, createElementVNode, normalizeClass, normalizeStyle, renderSlot } from "vue";
2
- import { c as createComponent } from "../component-TCzwHGVq.js";
3
- import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
4
- const { create } = createComponent("animate");
5
- const _sfc_main = create({
6
- props: {
7
- type: {
8
- type: String,
9
- default: ""
10
- },
11
- show: {
12
- type: Boolean,
13
- defualt: false
14
- },
15
- action: {
16
- type: String,
17
- default: ""
18
- },
19
- loop: {
20
- type: Boolean,
21
- default: false
22
- },
23
- duration: {
24
- type: [String, Number],
25
- defualt: 500
1
+ var __defProp = Object.defineProperty;
2
+ var __defProps = Object.defineProperties;
3
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
+ var __spreadValues = (a, b) => {
9
+ for (var prop in b || (b = {}))
10
+ if (__hasOwnProp.call(b, prop))
11
+ __defNormalProp(a, prop, b[prop]);
12
+ if (__getOwnPropSymbols)
13
+ for (var prop of __getOwnPropSymbols(b)) {
14
+ if (__propIsEnum.call(b, prop))
15
+ __defNormalProp(a, prop, b[prop]);
26
16
  }
17
+ return a;
18
+ };
19
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
+ import { defineComponent, ref, computed, watch, openBlock, createElementBlock, createElementVNode, normalizeClass, normalizeStyle, renderSlot } from "vue";
21
+ import { w as withInstall } from "../with-install-p59gYYU_.js";
22
+ const _hoisted_1 = { class: "nut-animate" };
23
+ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
24
+ name: "NutAnimate"
25
+ }), {
26
+ __name: "animate",
27
+ props: {
28
+ type: {},
29
+ show: { type: Boolean, default: false },
30
+ action: { default: "" },
31
+ loop: { type: Boolean, default: false },
32
+ duration: { default: 500 }
27
33
  },
28
34
  emits: ["click", "animate"],
29
- setup(props, { emit }) {
35
+ setup(__props, { emit: __emit }) {
36
+ const props = __props;
37
+ const emit = __emit;
30
38
  const animated = ref(props.action === "initial" || props.show === true || props.loop);
31
39
  const classes = computed(() => {
32
40
  const prefixCls = "nut-animate";
@@ -60,24 +68,23 @@ const _sfc_main = create({
60
68
  }
61
69
  }
62
70
  );
63
- return { classes, handleClick };
71
+ return (_ctx, _cache) => {
72
+ return openBlock(), createElementBlock("view", _hoisted_1, [
73
+ createElementVNode("view", {
74
+ class: normalizeClass(classes.value),
75
+ style: normalizeStyle({
76
+ animationDuration: _ctx.duration ? `${_ctx.duration}ms` : void 0
77
+ }),
78
+ onClick: handleClick
79
+ }, [
80
+ renderSlot(_ctx.$slots, "default")
81
+ ], 6)
82
+ ]);
83
+ };
64
84
  }
65
- });
66
- const _hoisted_1 = { class: "nut-animate" };
67
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
68
- return openBlock(), createElementBlock("view", _hoisted_1, [
69
- createElementVNode("view", {
70
- class: normalizeClass(_ctx.classes),
71
- style: normalizeStyle({
72
- animationDuration: _ctx.duration ? `${_ctx.duration}ms` : void 0
73
- }),
74
- onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args))
75
- }, [
76
- renderSlot(_ctx.$slots, "default")
77
- ], 6)
78
- ]);
79
- }
80
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
85
+ }));
86
+ withInstall(_sfc_main);
81
87
  export {
82
- index as default
88
+ _sfc_main as Animate,
89
+ _sfc_main as default
83
90
  };
@@ -1,57 +1,53 @@
1
- import { reactive, computed, onMounted, onUnmounted, onActivated, onDeactivated, resolveComponent, openBlock, createElementBlock, normalizeClass, normalizeStyle, withModifiers, renderSlot, createVNode } from "vue";
2
- import { c as createComponent } from "../component-TCzwHGVq.js";
1
+ var __defProp = Object.defineProperty;
2
+ var __defProps = Object.defineProperties;
3
+ var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
4
+ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __propIsEnum = Object.prototype.propertyIsEnumerable;
7
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
8
+ var __spreadValues = (a, b) => {
9
+ for (var prop in b || (b = {}))
10
+ if (__hasOwnProp.call(b, prop))
11
+ __defNormalProp(a, prop, b[prop]);
12
+ if (__getOwnPropSymbols)
13
+ for (var prop of __getOwnPropSymbols(b)) {
14
+ if (__propIsEnum.call(b, prop))
15
+ __defNormalProp(a, prop, b[prop]);
16
+ }
17
+ return a;
18
+ };
19
+ var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
20
+ import { defineComponent, ref, computed, onMounted, onUnmounted, onActivated, onDeactivated, openBlock, createElementBlock, normalizeClass, normalizeStyle, withModifiers, renderSlot, createVNode, unref } from "vue";
3
21
  import { r as requestAniFrame, c as cancelRaf } from "../raf-MQjoO-Ag.js";
4
22
  import { Top } from "@nutui/icons-vue";
5
- import { _ as _export_sfc } from "../_plugin-vue_export-helper-yVxbj29m.js";
6
- const { componentName, create } = createComponent("backtop");
7
- const _sfc_main = create({
8
- components: {
9
- Top
10
- },
23
+ import { w as withInstall } from "../with-install-p59gYYU_.js";
24
+ const _sfc_main = /* @__PURE__ */ defineComponent(__spreadProps(__spreadValues({}, {
25
+ name: "NutBacktop"
26
+ }), {
27
+ __name: "backtop",
11
28
  props: {
12
- bottom: {
13
- type: Number,
14
- default: 20
15
- },
16
- right: {
17
- type: Number,
18
- default: 10
19
- },
20
- elId: {
21
- type: [String],
22
- default: "body"
23
- },
24
- distance: {
25
- type: Number,
26
- default: 200
27
- },
28
- zIndex: {
29
- type: Number,
30
- default: 10
31
- },
32
- isAnimation: {
33
- type: Boolean,
34
- default: true
35
- },
36
- duration: {
37
- type: Number,
38
- default: 1e3
39
- }
29
+ bottom: { default: 20 },
30
+ right: { default: 10 },
31
+ elId: { default: "body" },
32
+ distance: { default: 200 },
33
+ zIndex: { default: 10 },
34
+ isAnimation: { type: Boolean, default: true },
35
+ duration: { default: 1e3 }
40
36
  },
41
37
  emits: ["click"],
42
- setup(props, { emit }) {
43
- const state = reactive({
44
- backTop: false,
45
- scrollTop: 0,
46
- scrollEl: window,
47
- startTime: 0,
48
- keepAlive: false
49
- });
38
+ setup(__props, { emit: __emit }) {
39
+ const props = __props;
40
+ const emit = __emit;
41
+ const backTop = ref(false);
42
+ const scrollTop = ref(0);
43
+ const scrollEl = ref(window);
44
+ const startTime = ref(0);
45
+ const keepAlive = ref(false);
50
46
  const classes = computed(() => {
51
- const prefixCls = componentName;
47
+ const prefixCls = "nut-backtop";
52
48
  return {
53
49
  [prefixCls]: true,
54
- show: state.backTop
50
+ show: backTop.value
55
51
  };
56
52
  });
57
53
  const style = computed(() => {
@@ -62,24 +58,24 @@ const _sfc_main = create({
62
58
  };
63
59
  });
64
60
  function scrollListener() {
65
- if (state.scrollEl instanceof Window) {
66
- state.scrollTop = state.scrollEl.pageYOffset;
61
+ if (scrollEl.value instanceof Window) {
62
+ scrollTop.value = scrollEl.value.scrollY;
67
63
  } else {
68
- state.scrollTop = state.scrollEl.scrollTop;
64
+ scrollTop.value = scrollEl.value.scrollTop;
69
65
  }
70
- state.backTop = state.scrollTop >= props.distance;
66
+ backTop.value = scrollTop.value >= props.distance;
71
67
  }
72
68
  function scroll(y = 0) {
73
- if (state.scrollEl instanceof Window) {
69
+ if (scrollEl.value instanceof Window) {
74
70
  window.scrollTo(0, y);
75
71
  } else {
76
- state.scrollEl.scrollTop = y;
72
+ scrollEl.value.scrollTop = y;
77
73
  }
78
74
  }
79
75
  function scrollAnimation() {
80
76
  let cid = requestAniFrame(function fn() {
81
- var t = props.duration - Math.max(0, state.startTime - +/* @__PURE__ */ new Date() + props.duration);
82
- var y = t * -state.scrollTop / props.duration + state.scrollTop;
77
+ var t = props.duration - Math.max(0, startTime.value - +/* @__PURE__ */ new Date() + props.duration);
78
+ var y = t * -scrollTop.value / props.duration + scrollTop.value;
83
79
  scroll(y);
84
80
  cid = requestAniFrame(fn);
85
81
  if (t == props.duration || y == 0) {
@@ -88,27 +84,27 @@ const _sfc_main = create({
88
84
  });
89
85
  }
90
86
  function addEventListener() {
91
- state.scrollEl.addEventListener("scroll", scrollListener, false);
92
- state.scrollEl.addEventListener("resize", scrollListener, false);
87
+ scrollEl.value.addEventListener("scroll", scrollListener, false);
88
+ scrollEl.value.addEventListener("resize", scrollListener, false);
93
89
  }
94
90
  function removeEventListener() {
95
- state.scrollEl.removeEventListener("scroll", scrollListener, false);
96
- state.scrollEl.removeEventListener("resize", scrollListener, false);
91
+ scrollEl.value.removeEventListener("scroll", scrollListener, false);
92
+ scrollEl.value.removeEventListener("resize", scrollListener, false);
97
93
  }
98
- function click(e) {
99
- state.startTime = +/* @__PURE__ */ new Date();
94
+ function handleClick(e) {
95
+ startTime.value = +/* @__PURE__ */ new Date();
100
96
  props.isAnimation && props.duration > 0 ? scrollAnimation() : scroll();
101
97
  emit("click", e);
102
98
  }
103
99
  function init() {
104
100
  if (props.elId && document.getElementById(props.elId)) {
105
- state.scrollEl = document.getElementById(props.elId);
101
+ scrollEl.value = document.getElementById(props.elId);
106
102
  }
107
103
  addEventListener();
108
104
  }
109
105
  onMounted(() => {
110
106
  if (props.distance == 0) {
111
- state.backTop = true;
107
+ backTop.value = true;
112
108
  }
113
109
  init();
114
110
  });
@@ -116,40 +112,34 @@ const _sfc_main = create({
116
112
  removeEventListener();
117
113
  });
118
114
  onActivated(() => {
119
- if (state.keepAlive) {
120
- state.keepAlive = false;
115
+ if (keepAlive.value) {
116
+ keepAlive.value = false;
121
117
  init();
122
118
  }
123
119
  });
124
120
  onDeactivated(() => {
125
- state.keepAlive = true;
121
+ keepAlive.value = true;
126
122
  removeEventListener();
127
123
  });
128
- return {
129
- state,
130
- classes,
131
- style,
132
- click
124
+ return (_ctx, _cache) => {
125
+ return openBlock(), createElementBlock("div", {
126
+ class: normalizeClass(classes.value),
127
+ style: normalizeStyle(style.value),
128
+ onClick: withModifiers(handleClick, ["stop"])
129
+ }, [
130
+ renderSlot(_ctx.$slots, "default", {}, () => [
131
+ createVNode(unref(Top), {
132
+ width: "19px",
133
+ height: "19px",
134
+ class: "nut-backtop-main"
135
+ })
136
+ ])
137
+ ], 6);
133
138
  };
134
139
  }
135
- });
136
- function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
137
- const _component_Top = resolveComponent("Top");
138
- return openBlock(), createElementBlock("div", {
139
- class: normalizeClass(_ctx.classes),
140
- style: normalizeStyle(_ctx.style),
141
- onClick: _cache[0] || (_cache[0] = withModifiers((...args) => _ctx.click && _ctx.click(...args), ["stop"]))
142
- }, [
143
- renderSlot(_ctx.$slots, "default", {}, () => [
144
- createVNode(_component_Top, {
145
- width: "19px",
146
- height: "19px",
147
- class: "nut-backtop-main"
148
- })
149
- ])
150
- ], 6);
151
- }
152
- const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
140
+ }));
141
+ withInstall(_sfc_main);
153
142
  export {
154
- index as default
143
+ _sfc_main as Backtop,
144
+ _sfc_main as default
155
145
  };