vlite3 1.2.16 → 1.2.17

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,7 +1,7 @@
1
1
  import o from "./Carousel.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-e8fba320"]]);
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-2d3c51df"]]);
5
5
  export {
6
- f as default
6
+ m as default
7
7
  };
@@ -1,35 +1,43 @@
1
- import { defineComponent as g, shallowRef as f, openBlock as p, createElementBlock as m, createVNode as c, unref as v, mergeProps as P, createSlots as h, renderList as y, withCtx as S, renderSlot as x, normalizeProps as B, guardReactiveProps as N } from "vue";
2
- import _ from "vue-carousel-lite";
1
+ import { defineComponent as f, shallowRef as g, openBlock as p, createElementBlock as c, createVNode as m, unref as h, mergeProps as v, createSlots as P, renderList as y, withCtx as S, renderSlot as B, normalizeProps as x, guardReactiveProps as T } from "vue";
2
+ import w from "vue-carousel-lite";
3
3
  import "vue-carousel-lite/style.css";
4
- const w = { class: "carousel-wrapper" }, V = /* @__PURE__ */ g({
4
+ const N = { class: "carousel-wrapper" }, V = /* @__PURE__ */ f({
5
5
  __name: "Carousel",
6
6
  props: {
7
7
  data: { default: () => [] },
8
- pagination: { type: [String, Array, Boolean], default: "dots" },
9
- paginationSize: { default: "sm" },
10
- paginationPosition: { default: "bottom-center" },
11
- paginationVisibility: {},
12
- paginationHoverInitialTimeout: {},
13
- paginationHoverEdgeThreshold: {},
14
- direction: { default: "horizontal" },
15
- autoPlay: { type: Boolean, default: !1 },
16
- draggable: { type: Boolean, default: !1 },
17
- autoPlayInterval: { default: 3e3 },
18
- itemsToShow: { default: 1 },
19
8
  gap: { default: 0 },
20
- speed: { default: 300 },
9
+ loop: { type: Boolean, default: !1 },
10
+ speed: { default: 700 },
21
11
  easing: { default: "ease" },
12
+ autoPlay: { type: Boolean, default: !1 },
13
+ draggable: { type: Boolean, default: !1 },
22
14
  mousewheel: { type: Boolean, default: !0 },
23
- loop: { type: Boolean, default: !1 },
15
+ autoFocus: { type: Boolean, default: !1 },
16
+ autoPlayInterval: { default: 3e3 },
24
17
  currentItem: { default: 0 },
18
+ paginationBackground: { type: Boolean, default: !1 },
19
+ paginationSize: { default: "sm" },
20
+ itemsToShow: { default: 1 },
21
+ direction: { default: "horizontal" },
22
+ pagination: { type: [String, Boolean, Array], default: "dots" },
23
+ paginationPosition: { default: "bottom-center" },
24
+ paginationVisibility: { default: "always" },
25
+ paginationHoverEdgeThreshold: { default: 10 },
26
+ paginationHoverInitialTimeout: { default: 500 },
27
+ wheelOptions: { default: () => ({
28
+ threshold: 5,
29
+ velocityThreshold: 0.5,
30
+ pageScrollThreshold: 0.1,
31
+ debounceTime: 50
32
+ }) },
25
33
  bufferSize: { default: 5 },
26
34
  maxDomElements: { default: 10 },
27
35
  updateKey: { default: void 0 }
28
36
  },
29
37
  emits: ["slide-change"],
30
- setup(r, { expose: n, emit: i }) {
31
- const s = r, u = i, o = f(null);
32
- return n({
38
+ setup(n, { expose: r, emit: i }) {
39
+ const s = n, u = i, o = g(null);
40
+ return r({
33
41
  goToSlide: (e, t) => {
34
42
  o.value?.goToSlide(e, t);
35
43
  },
@@ -45,18 +53,18 @@ const w = { class: "carousel-wrapper" }, V = /* @__PURE__ */ g({
45
53
  goPrevPage: (e) => {
46
54
  o.value?.goPrevPage(e);
47
55
  }
48
- }), (e, t) => (p(), m("div", w, [
49
- c(v(_), P({
56
+ }), (e, t) => (p(), c("div", N, [
57
+ m(h(w), v({
50
58
  ref_key: "carouselRef",
51
59
  ref: o
52
60
  }, s, {
53
61
  style: { height: "100%", width: "100%" },
54
62
  onSlideChange: t[0] || (t[0] = (a) => u("slide-change", a))
55
- }), h({ _: 2 }, [
63
+ }), P({ _: 2 }, [
56
64
  y(e.$slots, (a, l) => ({
57
65
  name: l,
58
66
  fn: S((d) => [
59
- x(e.$slots, l, B(N(d || {})), void 0, !0)
67
+ B(e.$slots, l, x(T(d || {})), void 0, !0)
60
68
  ])
61
69
  }))
62
70
  ]), 1040)
@@ -1,24 +1,86 @@
1
+ import { ComputedRef } from 'vue';
2
+ export interface SlidesPerView {
3
+ [key: number]: number;
4
+ }
5
+ export type PaginationType = 'buttons' | 'dots' | 'lines' | 'fraction' | false;
6
+ export type PaginationPosition = 'center' | 'bottom-center' | 'bottom-left' | 'bottom-right' | 'center-right' | 'bottom';
7
+ export type PaginationVisibility = 'always' | 'hover';
8
+ export interface WheelOptions {
9
+ threshold?: number;
10
+ velocityThreshold?: number;
11
+ pageScrollThreshold?: number;
12
+ debounceTime?: number;
13
+ }
1
14
  export interface CarouselProps {
2
- data?: any[];
3
- pagination?: string | string[] | boolean;
4
- paginationSize?: 'sm' | 'md' | 'lg';
5
- paginationPosition?: string | string[];
6
- paginationVisibility?: string | string[];
7
- paginationHoverInitialTimeout?: number;
8
- paginationHoverEdgeThreshold?: number;
9
- direction?: 'horizontal' | 'vertical';
10
- autoPlay?: boolean;
11
- draggable?: boolean;
12
- autoPlayInterval?: number;
13
- itemsToShow?: number | Record<number, number>;
15
+ data: any[];
14
16
  gap?: number;
17
+ loop?: boolean;
15
18
  speed?: number;
16
19
  easing?: string;
20
+ autoPlay?: boolean;
21
+ draggable?: boolean;
17
22
  mousewheel?: boolean;
18
- loop?: boolean;
23
+ autoFocus?: boolean;
24
+ autoPlayInterval?: number;
19
25
  currentItem?: number;
26
+ paginationBackground?: boolean;
27
+ paginationSize?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
28
+ itemsToShow?: number | SlidesPerView;
29
+ direction?: 'horizontal' | 'vertical';
30
+ pagination?: PaginationType | PaginationType[];
31
+ paginationPosition?: PaginationPosition | PaginationPosition[];
32
+ paginationVisibility?: PaginationVisibility | PaginationVisibility[];
33
+ paginationHoverEdgeThreshold?: number;
34
+ paginationHoverInitialTimeout?: number;
35
+ wheelOptions?: WheelOptions;
20
36
  bufferSize?: number;
21
37
  maxDomElements?: number;
22
38
  updateKey?: string | number;
23
- [key: string]: any;
39
+ }
40
+ export interface CarouselState {
41
+ currentIndex: number;
42
+ isTransitioning: boolean;
43
+ isDragging: boolean;
44
+ isHovered: boolean;
45
+ isWheeling: boolean;
46
+ }
47
+ export interface CarouselMethods {
48
+ goNext: (smooth?: boolean) => void;
49
+ goPrev: (smooth?: boolean) => void;
50
+ goNextPage: (smooth?: boolean) => void;
51
+ goPrevPage: (smooth?: boolean) => void;
52
+ goToSlide: (index: number, smooth?: boolean) => void;
53
+ }
54
+ export interface CarouselExposedMethods extends CarouselMethods {
55
+ state: Readonly<CarouselState>;
56
+ canGoNext: ComputedRef<boolean>;
57
+ canGoPrev: ComputedRef<boolean>;
58
+ }
59
+ export interface DragState {
60
+ startX: number;
61
+ startY: number;
62
+ deltaX: number;
63
+ deltaY: number;
64
+ isDragging: boolean;
65
+ currentX: number;
66
+ currentY: number;
67
+ startTime: number;
68
+ }
69
+ export interface CarouselChangeEvent {
70
+ currentIndex: number;
71
+ previousIndex: number;
72
+ direction: 'next' | 'prev';
73
+ }
74
+ export interface CarouselDragEvent {
75
+ deltaX: number;
76
+ deltaY: number;
77
+ velocity: number;
78
+ direction: 'horizontal' | 'vertical';
79
+ }
80
+ export interface CarouselBreakpoint {
81
+ width: number;
82
+ settings: Partial<CarouselProps>;
83
+ }
84
+ export interface CarouselResponsive {
85
+ breakpoints: CarouselBreakpoint[];
24
86
  }
@@ -0,0 +1,31 @@
1
+ export interface FadeOverlayProps {
2
+ /** Which edge to fade toward */
3
+ direction?: 'top' | 'bottom' | 'left' | 'right';
4
+ /** How much of the container the overlay covers */
5
+ coverage?: string | number;
6
+ /** Where the transparent part of the gradient starts (0% = edge of overlay) */
7
+ fadeStart?: string | number;
8
+ /** Where the opaque/masked part of the gradient ends (100% = full coverage end) */
9
+ fadeEnd?: string | number;
10
+ /**
11
+ * Blur amount for a frosted-glass effect.
12
+ * true → 8px, a number → px, a string → used as-is (e.g. "12px")
13
+ */
14
+ blur?: boolean | string | number;
15
+ /** CSS mix-blend-mode */
16
+ blendMode?: 'normal' | 'multiply' | 'screen' | 'overlay' | 'darken' | 'lighten' | 'color-dodge' | 'color-burn' | 'hard-light' | 'soft-light' | 'difference' | 'exclusion' | 'hue' | 'saturation' | 'color' | 'luminosity';
17
+ /** Overall opacity of the overlay (0–1) */
18
+ opacity?: string | number;
19
+ /** CSS z-index */
20
+ zIndex?: string | number;
21
+ /** Solid/gradient color. Defaults to the page background color. */
22
+ color?: string;
23
+ }
24
+ declare const _default: import('vue').DefineComponent<FadeOverlayProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<FadeOverlayProps> & Readonly<{}>, {
25
+ color: string;
26
+ direction: "top" | "bottom" | "left" | "right";
27
+ coverage: string | number;
28
+ fadeStart: string | number;
29
+ fadeEnd: string | number;
30
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLDivElement>;
31
+ export default _default;
@@ -0,0 +1,55 @@
1
+ import { defineComponent as f, computed as i, openBlock as m, createElementBlock as g, normalizeStyle as v } from "vue";
2
+ const $ = /* @__PURE__ */ f({
3
+ __name: "FadeOverlay",
4
+ props: {
5
+ direction: { default: "bottom" },
6
+ coverage: { default: "20%" },
7
+ fadeStart: { default: "0%" },
8
+ fadeEnd: { default: "100%" },
9
+ blur: { type: [Boolean, String, Number] },
10
+ blendMode: {},
11
+ opacity: {},
12
+ zIndex: {},
13
+ color: { default: "var(--color-background)" }
14
+ },
15
+ setup(c) {
16
+ const e = c, t = i(() => e.blur ? e.blur === !0 ? "8px" : typeof e.blur == "number" ? `${e.blur}px` : e.blur : ""), u = i(() => {
17
+ const o = typeof e.coverage == "number" ? `${e.coverage}%` : e.coverage, r = typeof e.fadeStart == "number" ? `${e.fadeStart}%` : e.fadeStart, n = typeof e.fadeEnd == "number" ? `${e.fadeEnd}%` : e.fadeEnd, a = {
18
+ top: "to top",
19
+ bottom: "to bottom",
20
+ left: "to left",
21
+ right: "to right"
22
+ }[e.direction] || "to bottom", b = e.direction === "top" || e.direction === "bottom" ? { left: 0, right: 0, height: o, [e.direction]: 0 } : { top: 0, bottom: 0, width: o, [e.direction]: 0 }, d = {
23
+ position: "absolute",
24
+ pointerEvents: "none",
25
+ opacity: e.opacity ?? 1,
26
+ zIndex: e.zIndex ?? 10,
27
+ ...e.blendMode ? { mixBlendMode: e.blendMode } : {},
28
+ ...b
29
+ };
30
+ if (t.value) {
31
+ const l = `linear-gradient(${a}, transparent ${r}, black ${n})`, p = e.color === "var(--color-background)" ? "color-mix(in srgb, var(--color-background) 60%, transparent)" : e.color;
32
+ return {
33
+ ...d,
34
+ background: p,
35
+ backdropFilter: `blur(${t.value})`,
36
+ WebkitBackdropFilter: `blur(${t.value})`,
37
+ maskImage: l,
38
+ WebkitMaskImage: l
39
+ };
40
+ }
41
+ const s = `linear-gradient(${a}, transparent ${r}, ${e.color} ${n})`;
42
+ return {
43
+ ...d,
44
+ background: s
45
+ };
46
+ });
47
+ return (o, r) => (m(), g("div", {
48
+ style: v(u.value),
49
+ "aria-hidden": "true"
50
+ }, null, 4));
51
+ }
52
+ });
53
+ export {
54
+ $ as default
55
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./FadeOverlay.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -5,7 +5,7 @@ const _ = /* @__PURE__ */ l({
5
5
  __name: "WorkbookAddButton",
6
6
  emits: ["click"],
7
7
  setup(a, { emit: o }) {
8
- const n = o, i = c(() => {
8
+ const r = o, n = c(() => {
9
9
  const t = u("vlite.workbook.addSheet");
10
10
  return t !== "vlite.workbook.addSheet" ? t : "Add New Sheet";
11
11
  });
@@ -13,10 +13,10 @@ const _ = /* @__PURE__ */ l({
13
13
  variant: "ghost",
14
14
  size: "md",
15
15
  icon: "lucide:plus",
16
- title: i.value,
16
+ title: n.value,
17
17
  rounded: "none",
18
- class: "h-full!",
19
- onClick: e[0] || (e[0] = (r) => n("click", r))
18
+ class: "h-full! hover:bg-gray-250!",
19
+ onClick: e[0] || (e[0] = (i) => r("click", i))
20
20
  }, null, 8, ["title"]));
21
21
  }
22
22
  });
package/index.d.ts CHANGED
@@ -77,6 +77,7 @@ export { default as CheckBox } from './components/CheckBox.vue';
77
77
  export { default as Textarea } from './components/Textarea.vue';
78
78
  export { default as Radio } from './components/Radio.vue';
79
79
  export { default as RadioGroup } from './components/RadioGroup.vue';
80
+ export { default as FadeOverlay } from './components/FadeOverlay.vue';
80
81
  export { default as SidePanel } from './components/SidePanel.vue';
81
82
  export { default as DatePicker } from './components/DatePicker.vue';
82
83
  export { default as IconPicker } from './components/IconPicker.vue';