@max-ts/svelte 1.8.0 → 1.8.2

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,5 +1,6 @@
1
1
  .styles_contentWrapper__ho48de0 {
2
2
  overflow: hidden;
3
+ height: 100%;
3
4
  }
4
5
  .styles_container__ho48de1 {
5
6
  display: flex;
@@ -20,11 +20,7 @@ function Content($$anchor, $$props) {
20
20
  var div = root();
21
21
  var div_1 = $.child(div);
22
22
  $.attribute_effect(div_1, () => ({
23
- class: [
24
- __default__.container,
25
- __default__.orientation[emblaCtx.orientation],
26
- $$props.class
27
- ],
23
+ class: [__default__.container, __default__.orientation[emblaCtx.orientation]],
28
24
  "data-embla-container": "",
29
25
  ...restProps
30
26
  }));
@@ -42,7 +38,7 @@ function Content($$anchor, $$props) {
42
38
  },
43
39
  plugins: emblaCtx.plugins
44
40
  }));
45
- $.template_effect(() => $.set_class(div, 1, $.clsx(__default__.contentWrapper)));
41
+ $.template_effect(() => $.set_class(div, 1, $.clsx([__default__.contentWrapper, $$props.class])));
46
42
  $.event("emblaInit", div, function(...$$args) {
47
43
  emblaCtx.onInit?.apply(this, $$args);
48
44
  });
@@ -1,5 +1,5 @@
1
1
  import "./../../../assets/src/theme.css.ts.vanilla-DlH7Hr_5.css";
2
- import "./../../../assets/src/components/Carousel/Content/styles.css.ts.vanilla-vey50OEc.css";
2
+ import "./../../../assets/src/components/Carousel/Content/styles.css.ts.vanilla-BtIjPFTJ.css";
3
3
 
4
4
  //#region src/components/Carousel/Content/styles.css.ts
5
5
  var __default__ = {
@@ -41,7 +41,13 @@ function ScalableContainer($$anchor, $$props) {
41
41
  return $$props.onPositionChanged;
42
42
  }
43
43
  });
44
+ function shouldSkipDragStart(target) {
45
+ if (!(target instanceof Element)) return false;
46
+ return Boolean(target.closest("button, a, input, textarea, select, label, path, summary, [role=\"button\"], [contenteditable=\"true\"]"));
47
+ }
44
48
  function onpointerdown(e) {
49
+ if (e.pointerType === "mouse" && e.button !== 0) return;
50
+ if (shouldSkipDragStart(e.target)) return;
45
51
  e.currentTarget.setPointerCapture(e.pointerId);
46
52
  store.startDrag(e.pointerId, e.clientX, e.clientY);
47
53
  }
@@ -90,13 +96,13 @@ function ScalableContainer($$anchor, $$props) {
90
96
  var node_2 = $.first_child(fragment_1);
91
97
  Button(node_2, {
92
98
  get onclick() {
93
- return store.reset;
99
+ return store.zoomIn;
94
100
  },
95
101
  size: "iconSmall",
96
- title: "Сбросить",
102
+ title: "Увеличить",
97
103
  variant: "outline",
98
104
  children: ($$anchor, $$slotProps) => {
99
- RotateCcw($$anchor, {});
105
+ ZoomIn($$anchor, {});
100
106
  },
101
107
  $$slots: { default: true }
102
108
  });
@@ -115,13 +121,13 @@ function ScalableContainer($$anchor, $$props) {
115
121
  });
116
122
  Button($.sibling(node_3, 2), {
117
123
  get onclick() {
118
- return store.zoomIn;
124
+ return store.reset;
119
125
  },
120
126
  size: "iconSmall",
121
- title: "Увеличить",
127
+ title: "Сбросить",
122
128
  variant: "outline",
123
129
  children: ($$anchor, $$slotProps) => {
124
- ZoomIn($$anchor, {});
130
+ RotateCcw($$anchor, {});
125
131
  },
126
132
  $$slots: { default: true }
127
133
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@max-ts/svelte",
3
- "version": "1.8.0",
3
+ "version": "1.8.2",
4
4
  "type": "module",
5
5
  "description": "Svelte component library.",
6
6
  "author": "Tsepelev Maksim",