@profitliga/ui 2.0.10 → 2.0.12

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.
@@ -1 +1 @@
1
- .sheet-trigger[data-v-8862ce15]{display:contents}.sheet-layer[data-v-8862ce15]{position:relative}.sheet-content[data-v-8862ce15]{background-color:var(--theme-neutral-0);z-index:1002;border-radius:12px 12px 0 0;flex-direction:column;width:100%;max-height:calc(100vh - 40px);display:flex;position:fixed;bottom:0;left:0;right:0;overflow:visible;box-shadow:0 2px 5px #3a3a3a40}.sheet-content[data-state=open][data-v-8862ce15]{animation:slideBottomIn var(--animation-duration) ease-in-out}.sheet-content[data-state=closed][data-v-8862ce15]{animation:slideBottomOut var(--animation-duration) ease-in-out}.sheet-content__handle[data-v-8862ce15]{cursor:grab;touch-action:none;flex-shrink:0;justify-content:center;align-items:flex-end;width:100%;height:24px;padding-bottom:12px;display:flex}.sheet-content__handle[data-v-8862ce15]:active{cursor:grabbing}.sheet-content__handle-dot[data-v-8862ce15]{background-color:var(--theme-neutral-icon-primary);border-radius:2px;width:48px;height:4px}.sheet-content__body[data-v-8862ce15]{box-sizing:content-box;scrollbar-width:thin;scrollbar-color:var(--theme-neutral-icon-primary) var(--theme-neutral-surface-icon);flex:auto;width:100%;min-height:0;overflow-y:auto}.sheet-content__body[data-v-8862ce15]::-webkit-scrollbar{width:8px;height:0}.sheet-content__body[data-v-8862ce15]::-webkit-scrollbar-thumb{background-color:var(--theme-neutral-icon-primary);background-clip:padding-box;border:1px solid #0000;border-radius:999px}.sheet-content__body[data-v-8862ce15]::-webkit-scrollbar-track{background:var(--theme-neutral-surface-icon);border-radius:4px}.sheet-content__body[data-v-8862ce15]::-webkit-scrollbar-corner{background:0 0}.sheet-overlay--drag-closing[data-v-8862ce15]{visibility:hidden}
1
+ .sheet-trigger[data-v-89da4791]{display:contents}.sheet-layer[data-v-89da4791]{position:relative}.sheet-overlay[data-v-89da4791]{pointer-events:auto;cursor:pointer}.sheet-content[data-v-89da4791]{background-color:var(--theme-neutral-0);z-index:1002;border-radius:12px 12px 0 0;flex-direction:column;width:100%;max-height:calc(100vh - 40px);display:flex;position:fixed;bottom:0;left:0;right:0;overflow:visible;box-shadow:0 2px 5px #3a3a3a40}.sheet-content[data-state=open][data-v-89da4791]{animation:slideBottomIn var(--animation-duration) ease-in-out}.sheet-content[data-state=closed][data-v-89da4791]{animation:slideBottomOut var(--animation-duration) ease-in-out}.sheet-content__handle[data-v-89da4791]{cursor:grab;touch-action:none;flex-shrink:0;justify-content:center;align-items:flex-end;width:100%;height:24px;padding-bottom:12px;display:flex}.sheet-content__handle[data-v-89da4791]:active{cursor:grabbing}.sheet-content__handle-dot[data-v-89da4791]{background-color:var(--theme-neutral-icon-primary);border-radius:2px;width:48px;height:4px}.sheet-content__body[data-v-89da4791]{box-sizing:content-box;scrollbar-width:thin;scrollbar-color:var(--theme-neutral-icon-primary) var(--theme-neutral-surface-icon);flex:auto;width:100%;min-height:0;overflow-y:auto}.sheet-content__body[data-v-89da4791]::-webkit-scrollbar{width:8px;height:0}.sheet-content__body[data-v-89da4791]::-webkit-scrollbar-thumb{background-color:var(--theme-neutral-icon-primary);background-clip:padding-box;border:1px solid #0000;border-radius:999px}.sheet-content__body[data-v-89da4791]::-webkit-scrollbar-track{background:var(--theme-neutral-surface-icon);border-radius:4px}.sheet-content__body[data-v-89da4791]::-webkit-scrollbar-corner{background:0 0}.sheet-overlay--drag-closing[data-v-89da4791]{visibility:hidden}
@@ -2,7 +2,7 @@ import './BottomSheet.css';
2
2
  import o from "./BottomSheet.vue2.js";
3
3
  /* empty css */
4
4
  import t from "../../../_virtual/_plugin-vue_export-helper.js";
5
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-8862ce15"]]);
5
+ const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-89da4791"]]);
6
6
  export {
7
- p as default
7
+ e as default
8
8
  };
@@ -71,9 +71,7 @@ const se = ["data-state"], re = ["aria-label", "aria-labelledby", "data-state"],
71
71
  E(O, (e) => d.registerElement(e));
72
72
  let b;
73
73
  E(v, (e) => {
74
- b?.(), b = e ? W(e, N, {
75
- ignore: () => d.elementsAbove()
76
- }) : void 0;
74
+ b?.(), b = e ? W(e, N, { ignore: () => d.elementsAbove() }) : void 0;
77
75
  }), q(() => {
78
76
  b?.(), document.removeEventListener("keydown", h), g.deactivate();
79
77
  });
@@ -102,7 +100,7 @@ const se = ["data-state"], re = ["aria-label", "aria-labelledby", "data-state"],
102
100
  style: G({ zIndex: A.value })
103
101
  }, [
104
102
  f("div", u({
105
- class: ["overlay dialog-overlay", { "sheet-overlay--drag-closing": i.value }],
103
+ class: ["overlay sheet-overlay dialog-overlay", { "sheet-overlay--drag-closing": i.value }],
106
104
  "data-state": t(T)
107
105
  }, t(r)("overlay")), null, 16, se),
108
106
  f("div", u({
@@ -1,41 +1,36 @@
1
- import { toValue as d, unref as g } from "vue";
1
+ import { toValue as p, unref as g } from "vue";
2
2
  const s = /* @__PURE__ */ new WeakMap();
3
- let c = 0;
3
+ let i = 0;
4
4
  const E = 500;
5
- function l(n) {
6
- const o = g(n);
5
+ function m(r) {
6
+ const o = g(r);
7
7
  return o?.$el ?? o;
8
8
  }
9
- function y(n) {
10
- return typeof n == "string" ? document.querySelector(n) : l(n);
9
+ function h(r) {
10
+ return typeof r == "string" ? document.querySelector(r) : m(r);
11
11
  }
12
- function h(n, o, f = {}) {
13
- const r = y(n);
14
- if (!r) return () => {
12
+ function L(r, o, f = {}) {
13
+ const n = h(r);
14
+ if (!n) return () => {
15
15
  };
16
- const a = s.get(r);
17
- a && (a(), s.delete(r));
18
- const u = (t) => {
19
- if (t.type === "touchstart")
20
- c = t.timeStamp;
21
- else if (c > 0 && t.timeStamp - c < E)
16
+ const a = s.get(n);
17
+ a && (a(), s.delete(n));
18
+ const u = (e) => {
19
+ if (e.type === "touchstart")
20
+ i = e.timeStamp;
21
+ else if (i > 0 && e.timeStamp - i < E)
22
22
  return;
23
- const i = t.target instanceof Node ? t.target : null;
24
- if (!i) return;
25
- const p = (d(f.ignore) ?? []).map((e) => typeof e == "string" ? document.querySelector(e) : l(e)).filter((e) => e != null);
26
- r.contains(i) || p.some((e) => e.contains(i)) || (o(t), t.type === "touchstart" && t.preventDefault());
23
+ const c = e.target instanceof Node ? e.target : null;
24
+ if (!c) return;
25
+ const d = (p(f.ignore) ?? []).map((t) => typeof t == "string" ? document.querySelector(t) : m(t)).filter((t) => t != null);
26
+ n.contains(c) || d.some((t) => t.contains(c)) || (o(e), e.type === "touchstart" && e.cancelable && console.log("would prevent default here", e.target));
27
27
  };
28
- document.addEventListener("mousedown", u, { capture: !0 }), document.addEventListener("touchstart", u, {
29
- capture: !0,
30
- passive: !1
31
- });
32
- const m = () => {
33
- document.removeEventListener("mousedown", u, { capture: !0 }), document.removeEventListener("touchstart", u, {
34
- capture: !0
35
- }), s.delete(r);
28
+ document.addEventListener("mousedown", u, { capture: !0 }), document.addEventListener("touchstart", u, { capture: !0, passive: !1 });
29
+ const l = () => {
30
+ document.removeEventListener("mousedown", u, { capture: !0 }), document.removeEventListener("touchstart", u, { capture: !0 }), s.delete(n);
36
31
  };
37
- return s.set(r, m), m;
32
+ return s.set(n, l), l;
38
33
  }
39
34
  export {
40
- h as onClickOutside
35
+ L as onClickOutside
41
36
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@profitliga/ui",
3
- "version": "2.0.10",
3
+ "version": "2.0.12",
4
4
  "author": "Profit League<dev@pr-lg.ru>",
5
5
  "license": "MIT",
6
6
  "description": "Vue 3 UI component library with TypeScript and SCSS",