vuetify-masonry 0.3.0 → 0.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.
@@ -20,19 +20,19 @@ const y = /* @__PURE__ */ B({
20
20
  mdAndUp: V,
21
21
  lgAndUp: k,
22
22
  xlAndUp: U,
23
- xxl: h
23
+ xxl: C
24
24
  } = w(), a = c(() => {
25
- const l = (t) => {
26
- if (t !== void 0)
27
- return typeof t == "string" ? Number(t) : t;
28
- }, r = (...t) => {
29
- for (const n of t) {
30
- const s = l(n);
25
+ const t = (l) => {
26
+ if (l !== void 0)
27
+ return typeof l == "string" ? Number(l) : l;
28
+ }, r = (...l) => {
29
+ for (const n of l) {
30
+ const s = t(n);
31
31
  if (s !== void 0) return s;
32
32
  }
33
33
  return 1;
34
34
  };
35
- return h.value ? r(
35
+ return C.value ? r(
36
36
  e.xxl,
37
37
  e.xl,
38
38
  e.lg,
@@ -41,34 +41,34 @@ const y = /* @__PURE__ */ B({
41
41
  e.xs,
42
42
  e.col
43
43
  ) : U.value ? r(e.xl, e.lg, e.md, e.sm, e.xs, e.col) : k.value ? r(e.lg, e.md, e.sm, e.xs, e.col) : V.value ? r(e.md, e.sm, e.xs, e.col) : A.value ? r(e.sm, e.xs, e.col) : b.value ? r(e.xs, e.col) : r(e.col);
44
- }), C = c(() => {
45
- const l = Array.from({ length: a.value }, () => []);
46
- return e.items.forEach((r, t) => {
47
- l[t % a.value].push(r);
48
- }), l;
44
+ }), h = c(() => {
45
+ const t = Array.from({ length: a.value }, () => []);
46
+ return e.items.forEach((r, l) => {
47
+ t[l % a.value].push(r);
48
+ }), t;
49
49
  });
50
- return (l, r) => (o(), d(f(_), null, {
50
+ return (t, r) => (o(), d(f(_), null, {
51
51
  default: p(() => [
52
- (o(!0), i(x, null, v(C.value, (t, n) => (o(), d(f(z), {
52
+ (o(!0), i(x, null, v(h.value, (l, n) => (o(), d(f(z), {
53
53
  key: n,
54
54
  cols: 12 / a.value
55
55
  }, {
56
56
  default: p(() => [
57
- (o(!0), i(x, null, v(t, (s, m) => (o(), i("div", {
57
+ (o(!0), i(x, null, v(l, (s, m) => (o(), i("div", {
58
58
  key: m,
59
- class: E({ "mb-6": m !== t.length - 1 })
59
+ class: E({ "mb-6": m !== l.length - 1 })
60
60
  }, [
61
- M(l.$slots, "item", {
61
+ M(t.$slots, "item", {
62
62
  item: s,
63
63
  index: m,
64
64
  columnIndex: n
65
65
  }, () => [
66
- r[0] || (r[0] = g(" Please provide an item slot – see the ", -1)),
66
+ r[0] || (r[0] = g(" Please provide an ", -1)),
67
67
  r[1] || (r[1] = N("a", {
68
68
  href: "https://github.com/senerh/vuetify-masonry?tab=readme-ov-file#slot-api",
69
69
  target: "_blank",
70
70
  rel: "noopener"
71
- }, "documentation", -1)),
71
+ }, "item slot", -1)),
72
72
  r[2] || (r[2] = g(". ", -1))
73
73
  ])
74
74
  ], 2))), 128))
@@ -1 +1 @@
1
- (function(r,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vuetify"),require("vuetify/components")):typeof define=="function"&&define.amd?define(["exports","vue","vuetify","vuetify/components"],e):(r=typeof globalThis<"u"?globalThis:r||self,e(r.VuetifyMasonry={},r.Vue,r.Vuetify,r.Vuetify))})(this,(function(r,e,m,f){"use strict";const u=e.defineComponent({__name:"VMasonry",props:{col:{},items:{default:()=>[]},xs:{},sm:{},md:{},lg:{},xl:{},xxl:{}},setup(c){const t=c,{xs:x,smAndUp:y,mdAndUp:k,lgAndUp:V,xlAndUp:g,xxl:B}=m.useDisplay(),a=e.computed(()=>{const l=o=>{if(o!==void 0)return typeof o=="string"?Number(o):o},n=(...o)=>{for(const s of o){const i=l(s);if(i!==void 0)return i}return 1};return B.value?n(t.xxl,t.xl,t.lg,t.md,t.sm,t.xs,t.col):g.value?n(t.xl,t.lg,t.md,t.sm,t.xs,t.col):V.value?n(t.lg,t.md,t.sm,t.xs,t.col):k.value?n(t.md,t.sm,t.xs,t.col):y.value?n(t.sm,t.xs,t.col):x.value?n(t.xs,t.col):n(t.col)}),h=e.computed(()=>{const l=Array.from({length:a.value},()=>[]);return t.items.forEach((n,o)=>{l[o%a.value].push(n)}),l});return(l,n)=>(e.openBlock(),e.createBlock(e.unref(f.VRow),null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(o,s)=>(e.openBlock(),e.createBlock(e.unref(f.VCol),{key:s,cols:12/a.value},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(i,d)=>(e.openBlock(),e.createElementBlock("div",{key:d,class:e.normalizeClass({"mb-6":d!==o.length-1})},[e.renderSlot(l.$slots,"item",{item:i,index:d,columnIndex:s},()=>[n[0]||(n[0]=e.createTextVNode(" Please provide an item slot – see the ",-1)),n[1]||(n[1]=e.createElementVNode("a",{href:"https://github.com/senerh/vuetify-masonry?tab=readme-ov-file#slot-api",target:"_blank",rel:"noopener"},"documentation",-1)),n[2]||(n[2]=e.createTextVNode(". ",-1))])],2))),128))]),_:2},1032,["cols"]))),128))]),_:3}))}}),p={...u,install(c){c.component("VMasonry",u)}};r.VMasonry=u,r.default=p,Object.defineProperties(r,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
1
+ (function(r,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("vuetify"),require("vuetify/components")):typeof define=="function"&&define.amd?define(["exports","vue","vuetify","vuetify/components"],e):(r=typeof globalThis<"u"?globalThis:r||self,e(r.VuetifyMasonry={},r.Vue,r.Vuetify,r.Vuetify))})(this,(function(r,e,m,d){"use strict";const u=e.defineComponent({__name:"VMasonry",props:{col:{},items:{default:()=>[]},xs:{},sm:{},md:{},lg:{},xl:{},xxl:{}},setup(c){const t=c,{xs:x,smAndUp:y,mdAndUp:k,lgAndUp:V,xlAndUp:g,xxl:B}=m.useDisplay(),f=e.computed(()=>{const l=o=>{if(o!==void 0)return typeof o=="string"?Number(o):o},n=(...o)=>{for(const s of o){const i=l(s);if(i!==void 0)return i}return 1};return B.value?n(t.xxl,t.xl,t.lg,t.md,t.sm,t.xs,t.col):g.value?n(t.xl,t.lg,t.md,t.sm,t.xs,t.col):V.value?n(t.lg,t.md,t.sm,t.xs,t.col):k.value?n(t.md,t.sm,t.xs,t.col):y.value?n(t.sm,t.xs,t.col):x.value?n(t.xs,t.col):n(t.col)}),h=e.computed(()=>{const l=Array.from({length:f.value},()=>[]);return t.items.forEach((n,o)=>{l[o%f.value].push(n)}),l});return(l,n)=>(e.openBlock(),e.createBlock(e.unref(d.VRow),null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(o,s)=>(e.openBlock(),e.createBlock(e.unref(d.VCol),{key:s,cols:12/f.value},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o,(i,a)=>(e.openBlock(),e.createElementBlock("div",{key:a,class:e.normalizeClass({"mb-6":a!==o.length-1})},[e.renderSlot(l.$slots,"item",{item:i,index:a,columnIndex:s},()=>[n[0]||(n[0]=e.createTextVNode(" Please provide an ",-1)),n[1]||(n[1]=e.createElementVNode("a",{href:"https://github.com/senerh/vuetify-masonry?tab=readme-ov-file#slot-api",target:"_blank",rel:"noopener"},"item slot",-1)),n[2]||(n[2]=e.createTextVNode(". ",-1))])],2))),128))]),_:2},1032,["cols"]))),128))]),_:3}))}}),p={...u,install(c){c.component("VMasonry",u)}};r.VMasonry=u,r.default=p,Object.defineProperties(r,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vuetify-masonry",
3
- "version": "0.3.0",
3
+ "version": "0.3.3",
4
4
  "description": "A simple Vuetify-compatible masonry grid Vue 3 component",
5
5
  "main": "dist/vuetify-masonry.umd.js",
6
6
  "module": "dist/vuetify-masonry.mjs",
@@ -34,13 +34,14 @@
34
34
  },
35
35
  "devDependencies": {
36
36
  "@vitejs/plugin-vue": "^6.0.3",
37
- "typescript": "^5.0.0",
37
+ "conventional-changelog-conventionalcommits": "^9.1.0",
38
38
  "eslint": "^9.13.0",
39
39
  "eslint-plugin-vue": "^9.29.0",
40
+ "prettier": "^3.3.3",
41
+ "typescript": "^5.0.0",
40
42
  "vite": "^7.3.0",
41
43
  "vite-plugin-dts": "^4.5.4",
42
44
  "vue": "^3.2.0",
43
- "vuetify": "^3.0.0",
44
- "prettier": "^3.3.3"
45
+ "vuetify": "^3.0.0"
45
46
  }
46
47
  }