@opentinyvue/vue-dialog-box 2.21.0 → 3.21.0

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/lib/index.js CHANGED
@@ -204,7 +204,7 @@ var DialogBox = defineComponent({
204
204
  });
205
205
  }
206
206
  });
207
- var version = "2.21.0";
207
+ var version = "3.21.0";
208
208
  DialogBox.install = function(Vue) {
209
209
  Vue.component(DialogBox.name, DialogBox);
210
210
  };
@@ -2,38 +2,42 @@ import { renderless, api } from '@opentinyvue/vue-renderless/dialog-box/vue';
2
2
  import { defineComponent, props, setup } from '@opentinyvue/vue-common';
3
3
  import { IconClose, IconFullscreen, IconMinscreen } from '@opentinyvue/vue-icon';
4
4
  import ActionSheet from '@opentinyvue/vue-action-sheet';
5
+ import { resolveComponent, openBlock, createElementBlock, createVNode, Transition, withCtx, withDirectives, createElementVNode, normalizeClass, withModifiers, normalizeStyle, renderSlot, toDisplayString, createCommentVNode, vShow, createBlock, mergeProps, createSlots, renderList, normalizeProps, guardReactiveProps } from 'vue';
5
6
 
6
- function normalizeComponent(scriptExports, render, staticRenderFns, functionalTemplate, injectStyles, scopeId, moduleIdentifier, shadowMode) {
7
- var options = typeof scriptExports === "function" ? scriptExports.options : scriptExports;
8
- if (render) {
9
- options.render = render;
10
- options.staticRenderFns = staticRenderFns;
11
- options._compiled = true;
7
+ function _createForOfIteratorHelperLoose(r, e) {
8
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
9
+ if (t) return (t = t.call(r)).next.bind(t);
10
+ if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
11
+ t && (r = t);
12
+ var o = 0;
13
+ return function() {
14
+ return o >= r.length ? { done: true } : { done: false, value: r[o++] };
15
+ };
12
16
  }
13
- var hook;
14
- if (injectStyles) {
15
- hook = injectStyles;
16
- }
17
- if (hook) {
18
- if (options.functional) {
19
- options._injectStyles = hook;
20
- var originalRender = options.render;
21
- options.render = function renderWithStyleInjection(h, context) {
22
- hook.call(context);
23
- return originalRender(h, context);
24
- };
25
- } else {
26
- var existing = options.beforeCreate;
27
- options.beforeCreate = existing ? [].concat(existing, hook) : [hook];
28
- }
17
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
18
+ }
19
+ function _unsupportedIterableToArray(r, a) {
20
+ if (r) {
21
+ if ("string" == typeof r) return _arrayLikeToArray(r, a);
22
+ var t = {}.toString.call(r).slice(8, -1);
23
+ 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;
29
24
  }
30
- return {
31
- exports: scriptExports,
32
- options
33
- };
34
25
  }
26
+ function _arrayLikeToArray(r, a) {
27
+ (null == a || a > r.length) && (a = r.length);
28
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
29
+ return n;
30
+ }
31
+ var _export_sfc = function _export_sfc2(sfc, props) {
32
+ var target = sfc.__vccOpts || sfc;
33
+ for (var _iterator = _createForOfIteratorHelperLoose(props), _step; !(_step = _iterator()).done; ) {
34
+ var _step$value = _step.value, key = _step$value[0], val = _step$value[1];
35
+ target[key] = val;
36
+ }
37
+ return target;
38
+ };
35
39
 
36
- var __vue2_script = defineComponent({
40
+ var _sfc_main = defineComponent({
37
41
  components: {
38
42
  IconClose: IconClose(),
39
43
  IconFullscreen: IconFullscreen(),
@@ -55,167 +59,169 @@ var __vue2_script = defineComponent({
55
59
  });
56
60
  }
57
61
  });
58
- var render = function render2() {
59
- var _vm = this;
60
- var _h = _vm.$createElement;
61
- var _c = _vm._self._c || _h;
62
- return _c("div", [_vm.state.current !== "default" ? _c("div", [_c("transition", {
63
- attrs: {
64
- "duration": _vm.noAnimation ? 0 : void 0,
65
- "name": _vm.state.animationName
66
- },
67
- on: {
68
- "after-enter": _vm.afterEnter,
69
- "after-leave": _vm.afterLeave
70
- }
71
- }, [_c("div", {
72
- directives: [{
73
- name: "show",
74
- rawName: "v-show",
75
- value: _vm.visible,
76
- expression: "visible"
77
- }],
78
- class: ["fixed inset-0 m-0 flex items-center", _vm.dialogClass],
79
- attrs: {
80
- "data-tag": "tiny-dialog-box__wrapper"
81
- },
82
- on: {
83
- "click": function click($event) {
84
- if ($event.target !== $event.currentTarget) return null;
85
- return _vm.handleWrapperClick.apply(null, arguments);
86
- }
87
- }
88
- }, [(_vm.destroyOnClose ? _vm.visible : true) ? _c("div", {
89
- key: _vm.state.key,
90
- ref: "dialog",
91
- staticClass: "absolute bg-color-bg-1 border-none overflow-hidden shadow-xl rounded flex flex-col",
92
- class: [{
93
- "left-0 top-0 w-screen h-screen": _vm.state.isFull,
94
- "text-center": _vm.center,
95
- "flex flex-col rounded-none": _vm.rightSlide
96
- }],
97
- style: _vm.state.style,
98
- attrs: {
99
- "data-tag": "tiny-dialog-box"
100
- }
101
- }, [_vm.showHeader ? _c("div", {
102
- staticClass: "px-6 py-4 leading-5.5 bg-color-bg-1 flex justify-between items-center border-b border-b-color-bg-3",
103
- attrs: {
104
- "data-tag": "tiny-dialog-box__header"
105
- },
106
- on: {
107
- "mousedown": _vm.handleDrag
108
- }
109
- }, [_vm._t("title", function() {
110
- return [_c("span", {
111
- staticClass: "text-sm text-color-text-primary mr-4 flex-1 font-bold",
112
- attrs: {
113
- "data-tag": "tiny-dialog-box__title"
114
- }
115
- }, [_vm._v(_vm._s(_vm.title))])];
116
- }), _vm.resize && !_vm.state.isFull ? _c("button", {
117
- staticClass: "border-none p-0 leading-none cursor-pointer focus:outline-0",
118
- attrs: {
119
- "type": "button",
120
- "data-tag": "tiny-dialog-box__headerbtn",
121
- "aria-label": "Resize"
122
- },
123
- on: {
124
- "click": function click($event) {
125
- return _vm.toggleFullScreen(true);
126
- }
127
- }
128
- }, [_c("icon-fullscreen", {
129
- staticClass: "fill-color-text-primary text-base hover:fill-color-brand",
130
- attrs: {
131
- "data-tag": "tiny-svg-size tiny-dialog-box__close"
132
- }
133
- })], 1) : _vm._e(), _vm.resize && _vm.state.isFull ? _c("button", {
134
- staticClass: "border-none p-0 leading-none cursor-pointer focus:outline-0",
135
- attrs: {
136
- "type": "button",
137
- "data-tag": "tiny-dialog-box__headerbtn",
138
- "aria-label": "Resize"
139
- },
140
- on: {
141
- "click": function click($event) {
142
- return _vm.toggleFullScreen(false);
143
- }
144
- }
145
- }, [_c("icon-minscreen", {
146
- staticClass: "fill-color-text-primary text-base hover:fill-color-brand",
147
- attrs: {
148
- "data-tag": "tiny-svg-size tiny-dialog-box__close"
149
- }
150
- })], 1) : _vm._e(), _vm.showClose ? _c("button", {
151
- staticClass: "border-none p-0 leading-none cursor-pointer focus:outline-0",
152
- attrs: {
153
- "type": "button",
154
- "data-tag": "tiny-dialog-box__headerbtn",
155
- "aria-label": "Close"
156
- },
157
- on: {
158
- "click": function click($event) {
159
- return _vm.handleClose("close", $event);
160
- }
161
- }
162
- }, [_c("icon-close", {
163
- staticClass: "fill-color-text-primary text-base hover:fill-color-brand",
164
- attrs: {
165
- "data-tag": "tiny-svg-size tiny-dialog-box__close"
166
- }
167
- })], 1) : _vm._e()], 2) : _vm._e(), _c("div", {
168
- staticClass: "text-left pt-0 pr-6 pb-0 pl-6 mb-3 mt-3 text-color-text-primary leading-5.5 text-sm overflow-auto",
169
- class: [_vm.rightSlide || _vm.state.isFull ? "max-h-[none] flex-auto" : "max-h-[65vh]"],
170
- attrs: {
171
- "data-tag": "tiny-dialog-box__body"
172
- }
173
- }, [_vm._t("default")], 2), _vm.slots.footer ? _c("div", {
174
- staticClass: "pt-4 pr-6 pb-4 pl-6 text-right box-border border-t border-t-color-bg-3 [&_[data-tag=tiny-button]]:mx-1 [&_[data-tag=tiny-button]]:my-0 [&_[data-tag=tiny-toolbar]_[data-tag=tiny-button]]:my-0 [&_[data-tag=tiny-toolbar]_[data-tag=tiny-button]]:mx-1",
175
- attrs: {
176
- "data-tag": "tiny-dialog-box__footer"
177
- }
178
- }, [_vm._t("footer", null, {
179
- "beforeClose": _vm.beforeClose
180
- })], 2) : _vm._e()]) : _vm._e()])])], 1) : _vm._e(), _vm.state.current === "default" ? _c("div", [(_vm.destroyOnClose ? _vm.visible : true) ? _c("tiny-action-sheet", _vm._b({
181
- ref: "dialog",
182
- attrs: {
183
- "show-footer": true,
184
- "mask": _vm.modal,
185
- "mask-closable": _vm.closeOnClickModal,
186
- "before-close": _vm.beforeClose
187
- },
188
- on: {
189
- "update:visible": function updateVisible($event) {
190
- return _vm.$emit("update:visible", $event);
191
- }
192
- },
193
- scopedSlots: _vm._u([_vm._l(_vm.slots, function(value, name) {
194
- return {
195
- key: name,
196
- fn: function fn(scopeData) {
197
- return [_c("div", {
198
- key: name,
199
- class: {
62
+ var _hoisted_1 = {
63
+ key: 0
64
+ };
65
+ var _hoisted_2 = {
66
+ "data-tag": "tiny-dialog-box__title",
67
+ class: "text-sm text-color-text-primary mr-4 flex-1 font-bold"
68
+ };
69
+ var _hoisted_3 = {
70
+ key: 1,
71
+ "data-tag": "tiny-dialog-box__footer",
72
+ class: "pt-4 pr-6 pb-4 pl-6 text-right box-border border-t border-t-color-bg-3 [&_[data-tag=tiny-button]]:mx-1 [&_[data-tag=tiny-button]]:my-0 [&_[data-tag=tiny-toolbar]_[data-tag=tiny-button]]:my-0 [&_[data-tag=tiny-toolbar]_[data-tag=tiny-button]]:mx-1"
73
+ };
74
+ var _hoisted_4 = {
75
+ key: 1
76
+ };
77
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
78
+ var _component_icon_fullscreen = resolveComponent("icon-fullscreen");
79
+ var _component_icon_minscreen = resolveComponent("icon-minscreen");
80
+ var _component_icon_close = resolveComponent("icon-close");
81
+ var _component_tiny_action_sheet = resolveComponent("tiny-action-sheet");
82
+ return openBlock(), createElementBlock("div", null, [_ctx.state.current !== "default" ? (openBlock(), createElementBlock("div", _hoisted_1, [createVNode(Transition, {
83
+ duration: _ctx.noAnimation ? 0 : void 0,
84
+ name: _ctx.state.animationName,
85
+ onAfterEnter: _ctx.afterEnter,
86
+ onAfterLeave: _ctx.afterLeave,
87
+ persisted: ""
88
+ }, {
89
+ default: withCtx(function() {
90
+ return [withDirectives(createElementVNode(
91
+ "div",
92
+ {
93
+ class: normalizeClass(["fixed inset-0 m-0 flex items-center", _ctx.dialogClass]),
94
+ "data-tag": "tiny-dialog-box__wrapper",
95
+ onClick: _cache[4] || (_cache[4] = withModifiers(function() {
96
+ return _ctx.handleWrapperClick && _ctx.handleWrapperClick.apply(_ctx, arguments);
97
+ }, ["self"]))
98
+ },
99
+ [(_ctx.destroyOnClose ? _ctx.visible : true) ? (openBlock(), createElementBlock(
100
+ "div",
101
+ {
102
+ ref: "dialog",
103
+ "data-tag": "tiny-dialog-box",
104
+ class: normalizeClass([[{
105
+ "left-0 top-0 w-screen h-screen": _ctx.state.isFull,
106
+ "text-center": _ctx.center,
107
+ "flex flex-col rounded-none": _ctx.rightSlide
108
+ }], "absolute bg-color-bg-1 border-none overflow-hidden shadow-xl rounded flex flex-col"]),
109
+ style: normalizeStyle(_ctx.state.style),
110
+ key: _ctx.state.key
111
+ },
112
+ [_ctx.showHeader ? (openBlock(), createElementBlock(
113
+ "div",
114
+ {
115
+ key: 0,
116
+ "data-tag": "tiny-dialog-box__header",
117
+ class: "px-6 py-4 leading-5.5 bg-color-bg-1 flex justify-between items-center border-b border-b-color-bg-3",
118
+ onMousedown: _cache[3] || (_cache[3] = function() {
119
+ return _ctx.handleDrag && _ctx.handleDrag.apply(_ctx, arguments);
120
+ })
121
+ },
122
+ [renderSlot(_ctx.$slots, "title", {}, function() {
123
+ return [createElementVNode(
124
+ "span",
125
+ _hoisted_2,
126
+ toDisplayString(_ctx.title),
127
+ 1
128
+ /* TEXT */
129
+ )];
130
+ }), _ctx.resize && !_ctx.state.isFull ? (openBlock(), createElementBlock("button", {
131
+ key: 0,
132
+ type: "button",
133
+ "data-tag": "tiny-dialog-box__headerbtn",
134
+ class: "border-none p-0 leading-none cursor-pointer focus:outline-0",
135
+ "aria-label": "Resize",
136
+ onClick: _cache[0] || (_cache[0] = function($event) {
137
+ return _ctx.toggleFullScreen(true);
138
+ })
139
+ }, [createVNode(_component_icon_fullscreen, {
140
+ "data-tag": "tiny-svg-size tiny-dialog-box__close",
141
+ class: "fill-color-text-primary text-base hover:fill-color-brand"
142
+ })])) : createCommentVNode("v-if", true), _ctx.resize && _ctx.state.isFull ? (openBlock(), createElementBlock("button", {
143
+ key: 1,
144
+ type: "button",
145
+ "data-tag": "tiny-dialog-box__headerbtn",
146
+ class: "border-none p-0 leading-none cursor-pointer focus:outline-0",
147
+ "aria-label": "Resize",
148
+ onClick: _cache[1] || (_cache[1] = function($event) {
149
+ return _ctx.toggleFullScreen(false);
150
+ })
151
+ }, [createVNode(_component_icon_minscreen, {
152
+ "data-tag": "tiny-svg-size tiny-dialog-box__close",
153
+ class: "fill-color-text-primary text-base hover:fill-color-brand"
154
+ })])) : createCommentVNode("v-if", true), _ctx.showClose ? (openBlock(), createElementBlock("button", {
155
+ key: 2,
156
+ type: "button",
157
+ "data-tag": "tiny-dialog-box__headerbtn",
158
+ class: "border-none p-0 leading-none cursor-pointer focus:outline-0",
159
+ "aria-label": "Close",
160
+ onClick: _cache[2] || (_cache[2] = function($event) {
161
+ return _ctx.handleClose("close", $event);
162
+ })
163
+ }, [createVNode(_component_icon_close, {
164
+ "data-tag": "tiny-svg-size tiny-dialog-box__close",
165
+ class: "fill-color-text-primary text-base hover:fill-color-brand"
166
+ })])) : createCommentVNode("v-if", true)],
167
+ 32
168
+ /* NEED_HYDRATION */
169
+ )) : createCommentVNode("v-if", true), createElementVNode(
170
+ "div",
171
+ {
172
+ "data-tag": "tiny-dialog-box__body",
173
+ class: normalizeClass(["text-left pt-0 pr-6 pb-0 pl-6 mb-3 mt-3 text-color-text-primary leading-5.5 text-sm overflow-auto", [_ctx.rightSlide || _ctx.state.isFull ? "max-h-[none] flex-auto" : "max-h-[65vh]"]])
174
+ },
175
+ [renderSlot(_ctx.$slots, "default")],
176
+ 2
177
+ /* CLASS */
178
+ ), _ctx.slots.footer ? (openBlock(), createElementBlock("div", _hoisted_3, [renderSlot(_ctx.$slots, "footer", {
179
+ beforeClose: _ctx.beforeClose
180
+ })])) : createCommentVNode("v-if", true)],
181
+ 6
182
+ /* CLASS, STYLE */
183
+ )) : createCommentVNode("v-if", true)],
184
+ 2
185
+ /* CLASS */
186
+ ), [[vShow, _ctx.visible]])];
187
+ }),
188
+ _: 3
189
+ /* FORWARDED */
190
+ }, 8, ["duration", "name", "onAfterEnter", "onAfterLeave"])])) : createCommentVNode("v-if", true), _ctx.state.current === "default" ? (openBlock(), createElementBlock("div", _hoisted_4, [(_ctx.destroyOnClose ? _ctx.visible : true) ? (openBlock(), createBlock(_component_tiny_action_sheet, mergeProps({
191
+ key: 0,
192
+ ref: "dialog"
193
+ }, _ctx.$props, {
194
+ "show-footer": true,
195
+ mask: _ctx.modal,
196
+ "mask-closable": _ctx.closeOnClickModal,
197
+ "before-close": _ctx.beforeClose,
198
+ "onUpdate:visible": _cache[5] || (_cache[5] = function($event) {
199
+ return _ctx.$emit("update:visible", $event);
200
+ })
201
+ }), createSlots({
202
+ _: 2
203
+ /* DYNAMIC */
204
+ }, [renderList(_ctx.slots, function(value, name) {
205
+ return {
206
+ name,
207
+ fn: withCtx(function(scopeData) {
208
+ return [(openBlock(), createElementBlock(
209
+ "div",
210
+ {
211
+ class: normalizeClass({
200
212
  "flex w-full justify-between px-4 [&_[data-tag=tiny-button]]:flex-grow [&_[data-tag=tiny-button]:nth-child(2)]:ml-2": name === "footer",
201
213
  "px-4 min-h-[250px]": name === "default"
202
- }
203
- }, [_vm._t(name, null, null, scopeData)], 2)];
204
- }
205
- };
206
- })], null, true)
207
- }, "tiny-action-sheet", _vm.$props, false)) : _vm._e()], 1) : _vm._e()]);
208
- };
209
- var staticRenderFns = [];
210
- var __cssModules = {};
211
- var __component__ = /* @__PURE__ */ normalizeComponent(__vue2_script, render, staticRenderFns, false, __vue2_injectStyles);
212
- function __vue2_injectStyles(context) {
213
- for (var o in __cssModules) {
214
- this[o] = __cssModules[o];
215
- }
214
+ }),
215
+ key: name
216
+ },
217
+ [renderSlot(_ctx.$slots, name, normalizeProps(guardReactiveProps(scopeData)))],
218
+ 2
219
+ /* CLASS */
220
+ ))];
221
+ })
222
+ };
223
+ })]), 1040, ["mask", "mask-closable", "before-close"])) : createCommentVNode("v-if", true)])) : createCommentVNode("v-if", true)]);
216
224
  }
217
- var mobileFirst = /* @__PURE__ */ function() {
218
- return __component__.exports;
219
- }();
225
+ var mobileFirst = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
220
226
 
221
227
  export { mobileFirst as default };
package/lib/mobile.js CHANGED
@@ -1,38 +1,42 @@
1
1
  import { renderless, api } from '@opentinyvue/vue-renderless/dialog-box/vue';
2
2
  import { defineComponent, props, setup } from '@opentinyvue/vue-common';
3
3
  import '@opentinyvue/vue-theme-mobile/dialog-box/index.css';
4
+ import { openBlock, createBlock, Transition, withCtx, withDirectives, createElementVNode, withModifiers, createElementBlock, normalizeClass, renderSlot, toDisplayString, createCommentVNode, vShow } from 'vue';
4
5
 
5
- function normalizeComponent(scriptExports, render, staticRenderFns, functionalTemplate, injectStyles, scopeId, moduleIdentifier, shadowMode) {
6
- var options = typeof scriptExports === "function" ? scriptExports.options : scriptExports;
7
- if (render) {
8
- options.render = render;
9
- options.staticRenderFns = staticRenderFns;
10
- options._compiled = true;
6
+ function _createForOfIteratorHelperLoose(r, e) {
7
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
8
+ if (t) return (t = t.call(r)).next.bind(t);
9
+ if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
10
+ t && (r = t);
11
+ var o = 0;
12
+ return function() {
13
+ return o >= r.length ? { done: true } : { done: false, value: r[o++] };
14
+ };
11
15
  }
12
- var hook;
13
- if (injectStyles) {
14
- hook = injectStyles;
15
- }
16
- if (hook) {
17
- if (options.functional) {
18
- options._injectStyles = hook;
19
- var originalRender = options.render;
20
- options.render = function renderWithStyleInjection(h, context) {
21
- hook.call(context);
22
- return originalRender(h, context);
23
- };
24
- } else {
25
- var existing = options.beforeCreate;
26
- options.beforeCreate = existing ? [].concat(existing, hook) : [hook];
27
- }
16
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
17
+ }
18
+ function _unsupportedIterableToArray(r, a) {
19
+ if (r) {
20
+ if ("string" == typeof r) return _arrayLikeToArray(r, a);
21
+ var t = {}.toString.call(r).slice(8, -1);
22
+ 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;
28
23
  }
29
- return {
30
- exports: scriptExports,
31
- options
32
- };
33
24
  }
25
+ function _arrayLikeToArray(r, a) {
26
+ (null == a || a > r.length) && (a = r.length);
27
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
28
+ return n;
29
+ }
30
+ var _export_sfc = function _export_sfc2(sfc, props) {
31
+ var target = sfc.__vccOpts || sfc;
32
+ for (var _iterator = _createForOfIteratorHelperLoose(props), _step; !(_step = _iterator()).done; ) {
33
+ var _step$value = _step.value, key = _step$value[0], val = _step$value[1];
34
+ target[key] = val;
35
+ }
36
+ return target;
37
+ };
34
38
 
35
- var __vue2_script = defineComponent({
39
+ var _sfc_main = defineComponent({
36
40
  emits: ["update:visible", "change", "before-close", "open", "close", "opened", "confirm", "cancel", "closed"],
37
41
  props: [].concat(props, ["visible", "title", "modal", "closeOnClickModal", "modalAppendToBody", "appendToBody", "width", "top", "showHeader", "destroyOnClose"]),
38
42
  model: {
@@ -48,75 +52,88 @@ var __vue2_script = defineComponent({
48
52
  });
49
53
  }
50
54
  });
51
- var render = function render2() {
52
- var _vm = this;
53
- var _h = _vm.$createElement;
54
- var _c = _vm._self._c || _h;
55
- return _c("transition", {
56
- attrs: {
57
- "name": "dialog-fade"
58
- }
59
- }, [_c("div", {
60
- directives: [{
61
- name: "show",
62
- rawName: "v-show",
63
- value: _vm.visible,
64
- expression: "visible"
65
- }],
66
- staticClass: "tiny-mobile-dialog-box__wrapper",
67
- on: {
68
- "click": function click($event) {
69
- if ($event.target !== $event.currentTarget) return null;
70
- return _vm.handleWrapperClick.apply(null, arguments);
71
- }
72
- }
73
- }, [_c("div", {
74
- key: _vm.state.key,
75
- ref: "dialog",
76
- staticClass: "tiny-mobile-dialog-box",
77
- class: {
78
- "is-hide-header": !_vm.showHeader
79
- }
80
- }, [_vm.showHeader ? _c("div", {
81
- staticClass: "tiny-mobile-dialog-box__header"
82
- }, [_vm._t("title", function() {
83
- return [_c("span", {
84
- staticClass: "tiny-mobile-dialog-box__title"
85
- }, [_vm._v(_vm._s(_vm.title))])];
86
- })], 2) : _vm._e(), _c("div", {
87
- staticClass: "tiny-mobile-dialog-box__body"
88
- }, [_vm._t("default")], 2), _c("div", {
89
- staticClass: "tiny-mobile-dialog-box__footer"
90
- }, [_vm._t("footer", function() {
91
- return [_c("button", {
92
- staticClass: "tiny-mobile-dialog-box__button cancel-button",
93
- attrs: {
94
- "type": "button"
95
- },
96
- on: {
97
- "click": _vm.handleCancel
98
- }
99
- }, [_vm._v(" " + _vm._s(_vm.t("ui.dialogBox.cancel")) + " ")]), _c("button", {
100
- staticClass: "tiny-mobile-dialog-box__button confirm-button",
101
- attrs: {
102
- "type": "button"
103
- },
104
- on: {
105
- "click": _vm.handleConfirm
106
- }
107
- }, [_vm._v(" " + _vm._s(_vm.t("ui.dialogBox.confirm")) + " ")])];
108
- })], 2)])])]);
55
+ var _hoisted_1 = {
56
+ key: 0,
57
+ class: "tiny-mobile-dialog-box__header"
109
58
  };
110
- var staticRenderFns = [];
111
- var __cssModules = {};
112
- var __component__ = /* @__PURE__ */ normalizeComponent(__vue2_script, render, staticRenderFns, false, __vue2_injectStyles);
113
- function __vue2_injectStyles(context) {
114
- for (var o in __cssModules) {
115
- this[o] = __cssModules[o];
116
- }
59
+ var _hoisted_2 = {
60
+ class: "tiny-mobile-dialog-box__title"
61
+ };
62
+ var _hoisted_3 = {
63
+ class: "tiny-mobile-dialog-box__body"
64
+ };
65
+ var _hoisted_4 = {
66
+ class: "tiny-mobile-dialog-box__footer"
67
+ };
68
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
69
+ return openBlock(), createBlock(Transition, {
70
+ name: "dialog-fade",
71
+ persisted: ""
72
+ }, {
73
+ default: withCtx(function() {
74
+ return [withDirectives(createElementVNode(
75
+ "div",
76
+ {
77
+ class: "tiny-mobile-dialog-box__wrapper",
78
+ onClick: _cache[2] || (_cache[2] = withModifiers(function() {
79
+ return _ctx.handleWrapperClick && _ctx.handleWrapperClick.apply(_ctx, arguments);
80
+ }, ["self"]))
81
+ },
82
+ [(openBlock(), createElementBlock(
83
+ "div",
84
+ {
85
+ ref: "dialog",
86
+ class: normalizeClass([{
87
+ "is-hide-header": !_ctx.showHeader
88
+ }, "tiny-mobile-dialog-box"]),
89
+ key: _ctx.state.key
90
+ },
91
+ [_ctx.showHeader ? (openBlock(), createElementBlock("div", _hoisted_1, [renderSlot(_ctx.$slots, "title", {}, function() {
92
+ return [createElementVNode(
93
+ "span",
94
+ _hoisted_2,
95
+ toDisplayString(_ctx.title),
96
+ 1
97
+ /* TEXT */
98
+ )];
99
+ })])) : createCommentVNode("v-if", true), createElementVNode("div", _hoisted_3, [renderSlot(_ctx.$slots, "default")]), createElementVNode("div", _hoisted_4, [renderSlot(_ctx.$slots, "footer", {}, function() {
100
+ return [createElementVNode(
101
+ "button",
102
+ {
103
+ type: "button",
104
+ onClick: _cache[0] || (_cache[0] = function() {
105
+ return _ctx.handleCancel && _ctx.handleCancel.apply(_ctx, arguments);
106
+ }),
107
+ class: "tiny-mobile-dialog-box__button cancel-button"
108
+ },
109
+ toDisplayString(_ctx.t("ui.dialogBox.cancel")),
110
+ 1
111
+ /* TEXT */
112
+ ), createElementVNode(
113
+ "button",
114
+ {
115
+ type: "button",
116
+ onClick: _cache[1] || (_cache[1] = function() {
117
+ return _ctx.handleConfirm && _ctx.handleConfirm.apply(_ctx, arguments);
118
+ }),
119
+ class: "tiny-mobile-dialog-box__button confirm-button"
120
+ },
121
+ toDisplayString(_ctx.t("ui.dialogBox.confirm")),
122
+ 1
123
+ /* TEXT */
124
+ )];
125
+ })])],
126
+ 2
127
+ /* CLASS */
128
+ ))],
129
+ 512
130
+ /* NEED_PATCH */
131
+ ), [[vShow, _ctx.visible]])];
132
+ }),
133
+ _: 3
134
+ /* FORWARDED */
135
+ });
117
136
  }
118
- var mobile = /* @__PURE__ */ function() {
119
- return __component__.exports;
120
- }();
137
+ var mobile = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
121
138
 
122
139
  export { mobile as default };