@toolbox-web/grid-angular 0.3.1 → 0.4.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/index.d.ts CHANGED
@@ -15,6 +15,8 @@ export { GridColumnView } from './lib/directives/grid-column-view.directive';
15
15
  export type { GridCellContext } from './lib/directives/grid-column-view.directive';
16
16
  export { GridDetailView } from './lib/directives/grid-detail-view.directive';
17
17
  export type { GridDetailContext } from './lib/directives/grid-detail-view.directive';
18
+ export { GridResponsiveCard } from './lib/directives/grid-responsive-card.directive';
19
+ export type { GridResponsiveCardContext } from './lib/directives/grid-responsive-card.directive';
18
20
  export { GridToolPanel } from './lib/directives/grid-tool-panel.directive';
19
21
  export type { GridToolPanelContext } from './lib/directives/grid-tool-panel.directive';
20
22
  export { Grid } from './lib/directives/grid.directive';
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../libs/grid-angular/src/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAGhE,OAAO,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAC/D,YAAY,EACV,iBAAiB,EACjB,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,GAClB,MAAM,6BAA6B,CAAC;AAGrC,OAAO,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AACzG,YAAY,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAGnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,+CAA+C,CAAC;AACjF,YAAY,EAAE,iBAAiB,EAAE,MAAM,+CAA+C,CAAC;AACvF,OAAO,EAAE,cAAc,EAAE,MAAM,6CAA6C,CAAC;AAC7E,YAAY,EAAE,eAAe,EAAE,MAAM,6CAA6C,CAAC;AACnF,OAAO,EAAE,cAAc,EAAE,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iB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,MAAM,iDAAiD,CAAC;AACrF,YAAY,EAAE,yBAAyB,EAAE,MAAM,iDAAiD,CAAC;AACjG,OAAO,EAAE,aAAa,EAAE,MAAM,4CAA4C,CAAC;AAC3E,YAAY,EAAE,oBAAoB,EAAE,MAAM,4CAA4C,CAAC;AACvF,OAAO,EAAE,IAAI,EAAE,MAAM,iCAAiC,CAAC;AACvD,YAAY,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAC;AAGvF,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,wCAAwC,CAAC;AAChF,YAAY,EAAE,qBAAqB,EAAE,uBAAuB,EAAE,MAAM,wCAAwC,CAAC;AAG7G,OAAO,EAAE,SAAS,IAAI,aAAa,EAAE,WAAW,IAAI,WAAW,EAAE,MAAM,wCAAwC,CAAC"}
package/index.js CHANGED
@@ -1,31 +1,31 @@
1
- var Se = Object.create;
2
- var P = Object.defineProperty;
3
- var Ie = Object.getOwnPropertyDescriptor;
4
- var ne = (n, e) => (e = Symbol[n]) ? e : /* @__PURE__ */ Symbol.for("Symbol." + n), D = (n) => {
1
+ var Oe = Object.create;
2
+ var O = Object.defineProperty;
3
+ var Ne = Object.getOwnPropertyDescriptor;
4
+ var ie = (n, e) => (e = Symbol[n]) ? e : /* @__PURE__ */ Symbol.for("Symbol." + n), D = (n) => {
5
5
  throw TypeError(n);
6
6
  };
7
- var je = (n, e, t) => e in n ? P(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
8
- var Z = (n, e) => P(n, "name", { value: e, configurable: !0 });
9
- var h = (n) => [, , , Se(n?.[ne("metadata")] ?? null)], ie = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], A = (n) => n !== void 0 && typeof n != "function" ? D("Function expected") : n, Oe = (n, e, t, i, r) => ({ kind: ie[n], name: e, metadata: i, addInitializer: (s) => t._ ? D("Already initialized") : r.push(A(s || null)) }), Pe = (n, e) => je(e, ne("metadata"), n[3]), g = (n, e, t, i) => {
10
- for (var r = 0, s = n[e >> 1], a = s && s.length; r < a; r++) e & 1 ? s[r].call(t) : i = s[r].call(t, i);
11
- return i;
12
- }, w = (n, e, t, i, r, s) => {
13
- var a, l, y, u, d, o = e & 7, T = !!(e & 8), f = !!(e & 16), I = o > 3 ? n.length + 1 : o ? T ? 1 : 2 : 0, Q = ie[o + 5], X = o > 3 && (n[I - 1] = []), Le = n[I] || (n[I] = []), p = o && (!f && !T && (r = r.prototype), o < 5 && (o > 3 || !f) && Ie(o < 4 ? r : { get [t]() {
14
- return ee(this, s);
15
- }, set [t](c) {
16
- return te(this, s, c);
7
+ var Me = (n, e, t) => e in n ? O(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
8
+ var te = (n, e) => O(n, "name", { value: e, configurable: !0 });
9
+ var h = (n) => [, , , Oe(n?.[ie("metadata")] ?? null)], se = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], A = (n) => n !== void 0 && typeof n != "function" ? D("Function expected") : n, Ve = (n, e, t, r, i) => ({ kind: se[n], name: e, metadata: r, addInitializer: (s) => t._ ? D("Already initialized") : i.push(A(s || null)) }), _e = (n, e) => Me(e, ie("metadata"), n[3]), g = (n, e, t, r) => {
10
+ for (var i = 0, s = n[e >> 1], o = s && s.length; i < o; i++) e & 1 ? s[i].call(t) : r = s[i].call(t, r);
11
+ return r;
12
+ }, v = (n, e, t, r, i, s) => {
13
+ var o, l, w, u, d, a = e & 7, T = !!(e & 8), f = !!(e & 16), S = a > 3 ? n.length + 1 : a ? T ? 1 : 2 : 0, Z = se[a + 5], ee = a > 3 && (n[S - 1] = []), je = n[S] || (n[S] = []), p = a && (!f && !T && (i = i.prototype), a < 5 && (a > 3 || !f) && Ne(a < 4 ? i : { get [t]() {
14
+ return ne(this, s);
15
+ }, set [t](m) {
16
+ return re(this, s, m);
17
17
  } }, t));
18
- o ? f && o < 4 && Z(s, (o > 2 ? "set " : o > 1 ? "get " : "") + t) : Z(r, t);
19
- for (var j = i.length - 1; j >= 0; j--)
20
- u = Oe(o, t, y = {}, n[3], Le), o && (u.static = T, u.private = f, d = u.access = { has: f ? (c) => Ne(r, c) : (c) => t in c }, o ^ 3 && (d.get = f ? (c) => (o ^ 1 ? ee : Me)(c, r, o ^ 4 ? s : p.get) : (c) => c[t]), o > 2 && (d.set = f ? (c, O) => te(c, r, O, o ^ 4 ? s : p.set) : (c, O) => c[t] = O)), l = (0, i[j])(o ? o < 4 ? f ? s : p[Q] : o > 4 ? void 0 : { get: p.get, set: p.set } : r, u), y._ = 1, o ^ 4 || l === void 0 ? A(l) && (o > 4 ? X.unshift(l) : o ? f ? s = l : p[Q] = l : r = l) : typeof l != "object" || l === null ? D("Object expected") : (A(a = l.get) && (p.get = a), A(a = l.set) && (p.set = a), A(a = l.init) && X.unshift(a));
21
- return o || Pe(n, r), p && P(r, t, p), f ? o ^ 4 ? s : p : r;
18
+ a ? f && a < 4 && te(s, (a > 2 ? "set " : a > 1 ? "get " : "") + t) : te(i, t);
19
+ for (var I = r.length - 1; I >= 0; I--)
20
+ u = Ve(a, t, w = {}, n[3], je), a && (u.static = T, u.private = f, d = u.access = { has: f ? (m) => xe(i, m) : (m) => t in m }, a ^ 3 && (d.get = f ? (m) => (a ^ 1 ? ne : qe)(m, i, a ^ 4 ? s : p.get) : (m) => m[t]), a > 2 && (d.set = f ? (m, j) => re(m, i, j, a ^ 4 ? s : p.set) : (m, j) => m[t] = j)), l = (0, r[I])(a ? a < 4 ? f ? s : p[Z] : a > 4 ? void 0 : { get: p.get, set: p.set } : i, u), w._ = 1, a ^ 4 || l === void 0 ? A(l) && (a > 4 ? ee.unshift(l) : a ? f ? s = l : p[Z] = l : i = l) : typeof l != "object" || l === null ? D("Object expected") : (A(o = l.get) && (p.get = o), A(o = l.set) && (p.set = o), A(o = l.init) && ee.unshift(o));
21
+ return a || _e(n, i), p && O(i, t, p), f ? a ^ 4 ? s : p : i;
22
22
  };
23
- var N = (n, e, t) => e.has(n) || D("Cannot " + t), Ne = (n, e) => Object(e) !== e ? D('Cannot use the "in" operator on this value') : n.has(e), ee = (n, e, t) => (N(n, e, "read from private field"), t ? t.call(n) : e.get(n));
24
- var te = (n, e, t, i) => (N(n, e, "write to private field"), i ? i.call(n, t) : e.set(n, t), t), Me = (n, e, t) => (N(n, e, "access private method"), t);
25
- import { inject as m, ElementRef as v, contentChild as S, TemplateRef as b, effect as C, Directive as E, input as R, InjectionToken as Ve, Injectable as _e, makeEnvironmentProviders as qe, EventEmitter as re, createComponent as se, EnvironmentInjector as Ge, ApplicationRef as ke, ViewContainerRef as xe, output as oe } from "@angular/core";
26
- import { DataGridElement as Ue } from "@toolbox-web/grid";
27
- import { MasterDetailPlugin as ae } from "@toolbox-web/grid/all";
28
- function le(n) {
23
+ var N = (n, e, t) => e.has(n) || D("Cannot " + t), xe = (n, e) => Object(e) !== e ? D('Cannot use the "in" operator on this value') : n.has(e), ne = (n, e, t) => (N(n, e, "read from private field"), t ? t.call(n) : e.get(n));
24
+ var re = (n, e, t, r) => (N(n, e, "write to private field"), r ? r.call(n, t) : e.set(n, t), t), qe = (n, e, t) => (N(n, e, "access private method"), t);
25
+ import { inject as c, ElementRef as C, contentChild as L, TemplateRef as b, effect as E, Directive as y, input as R, InjectionToken as ke, Injectable as $e, makeEnvironmentProviders as Ge, EventEmitter as oe, createComponent as ae, EnvironmentInjector as Ue, ApplicationRef as We, ViewContainerRef as Fe, output as le } from "@angular/core";
26
+ import { DataGridElement as He } from "@toolbox-web/grid";
27
+ import { MasterDetailPlugin as ce, ResponsivePlugin as Be } from "@toolbox-web/grid/all";
28
+ function me(n) {
29
29
  if (typeof n != "function" || n.prototype === void 0)
30
30
  return !1;
31
31
  if (Object.prototype.hasOwnProperty.call(n, "ɵcmp") || Object.prototype.hasOwnProperty.call(n, "ɵfac"))
@@ -33,22 +33,22 @@ function le(n) {
33
33
  const e = Function.prototype.toString.call(n);
34
34
  return e.startsWith("class ") || e.startsWith("class{");
35
35
  }
36
- const Ce = /* @__PURE__ */ new Map();
37
- function Ee(n) {
38
- return Ce.get(n);
36
+ const be = /* @__PURE__ */ new Map();
37
+ function Te(n) {
38
+ return be.get(n);
39
39
  }
40
- var de, U;
41
- de = [E({ selector: "tbw-grid-column-editor" })];
40
+ var fe, U;
41
+ fe = [y({ selector: "tbw-grid-column-editor" })];
42
42
  class M {
43
- elementRef = m(v);
43
+ elementRef = c(C);
44
44
  /**
45
45
  * Query for the ng-template content child.
46
46
  */
47
- template = S(b);
47
+ template = L(b);
48
48
  /** Effect that triggers when the template is available */
49
- onTemplateReceived = C(() => {
49
+ onTemplateReceived = E(() => {
50
50
  const e = this.template();
51
- e && Ce.set(this.elementRef.nativeElement, e);
51
+ e && be.set(this.elementRef.nativeElement, e);
52
52
  });
53
53
  /**
54
54
  * Static type guard for template context.
@@ -58,23 +58,23 @@ class M {
58
58
  return !0;
59
59
  }
60
60
  }
61
- U = h(null), M = w(U, 0, "GridColumnEditor", de, M), g(U, 1, M);
62
- const ye = /* @__PURE__ */ new Map();
63
- function be(n) {
64
- return ye.get(n);
61
+ U = h(null), M = v(U, 0, "GridColumnEditor", fe, M), g(U, 1, M);
62
+ const Ae = /* @__PURE__ */ new Map();
63
+ function De(n) {
64
+ return Ae.get(n);
65
65
  }
66
- var pe, $;
67
- pe = [E({ selector: "tbw-grid-column-view" })];
66
+ var he, W;
67
+ he = [y({ selector: "tbw-grid-column-view" })];
68
68
  class V {
69
- elementRef = m(v);
69
+ elementRef = c(C);
70
70
  /**
71
71
  * Query for the ng-template content child.
72
72
  */
73
- template = S(b);
73
+ template = L(b);
74
74
  /** Effect that triggers when the template is available */
75
- onTemplateReceived = C(() => {
75
+ onTemplateReceived = E(() => {
76
76
  const e = this.template();
77
- e && ye.set(this.elementRef.nativeElement, e);
77
+ e && Ae.set(this.elementRef.nativeElement, e);
78
78
  });
79
79
  /**
80
80
  * Static type guard for template context.
@@ -84,17 +84,17 @@ class V {
84
84
  return !0;
85
85
  }
86
86
  }
87
- $ = h(null), V = w($, 0, "GridColumnView", pe, V), g($, 1, V);
88
- const Te = /* @__PURE__ */ new Map();
89
- function ce(n) {
87
+ W = h(null), V = v(W, 0, "GridColumnView", he, V), g(W, 1, V);
88
+ const Le = /* @__PURE__ */ new Map();
89
+ function ue(n) {
90
90
  const e = n.querySelector("tbw-grid-detail");
91
91
  if (e)
92
- return Te.get(e);
92
+ return Le.get(e);
93
93
  }
94
- var fe, W;
95
- fe = [E({ selector: "tbw-grid-detail" })];
94
+ var ge, F;
95
+ ge = [y({ selector: "tbw-grid-detail" })];
96
96
  class _ {
97
- elementRef = m(v);
97
+ elementRef = c(C);
98
98
  /** Whether to show the expand/collapse column. Default: true */
99
99
  showExpandColumn = R(!0);
100
100
  /** Animation style for expand/collapse. Default: 'slide' */
@@ -102,11 +102,11 @@ class _ {
102
102
  /**
103
103
  * Query for the ng-template content child.
104
104
  */
105
- template = S(b);
105
+ template = L(b);
106
106
  /** Effect that triggers when the template is available */
107
- onTemplateReceived = C(() => {
107
+ onTemplateReceived = E(() => {
108
108
  const e = this.template();
109
- e && Te.set(this.elementRef.nativeElement, e);
109
+ e && Le.set(this.elementRef.nativeElement, e);
110
110
  });
111
111
  /**
112
112
  * Static type guard for template context.
@@ -116,15 +116,49 @@ class _ {
116
116
  return !0;
117
117
  }
118
118
  }
119
- W = h(null), _ = w(W, 0, "GridDetailView", fe, _), g(W, 1, _);
120
- const Ae = /* @__PURE__ */ new Map();
121
- function $e(n) {
122
- return Ae.get(n);
119
+ F = h(null), _ = v(F, 0, "GridDetailView", ge, _), g(F, 1, _);
120
+ const Pe = /* @__PURE__ */ new Map();
121
+ function Ye(n) {
122
+ const e = n.querySelector("tbw-grid-responsive-card");
123
+ if (e)
124
+ return Pe.get(e);
123
125
  }
124
- var he, F;
125
- he = [E({ selector: "tbw-grid-tool-panel" })];
126
+ var ve, H;
127
+ ve = [y({
128
+ selector: "tbw-grid-responsive-card"
129
+ })];
130
+ class x {
131
+ elementRef = c(C);
132
+ /**
133
+ * The ng-template containing the card content.
134
+ */
135
+ template = L(b);
136
+ /**
137
+ * Effect that registers the template when it becomes available.
138
+ */
139
+ onTemplateReceived = E(() => {
140
+ const e = this.template();
141
+ e && Pe.set(
142
+ this.elementRef.nativeElement,
143
+ e
144
+ );
145
+ });
146
+ /**
147
+ * Type guard for template context inference.
148
+ */
149
+ static ngTemplateContextGuard(e, t) {
150
+ return !0;
151
+ }
152
+ }
153
+ H = h(null), x = v(H, 0, "GridResponsiveCard", ve, x), g(H, 1, x);
154
+ const Se = /* @__PURE__ */ new Map();
155
+ function ze(n) {
156
+ return Se.get(n);
157
+ }
158
+ var Re, B;
159
+ Re = [y({ selector: "tbw-grid-tool-panel" })];
126
160
  class q {
127
- elementRef = m(v);
161
+ elementRef = c(C);
128
162
  /** Unique panel identifier (required) */
129
163
  id = R.required({ alias: "id" });
130
164
  /** Panel title shown in accordion header (required) */
@@ -138,16 +172,16 @@ class q {
138
172
  /**
139
173
  * Query for the ng-template content child.
140
174
  */
141
- template = S(b);
175
+ template = L(b);
142
176
  /** Effect that triggers when the template is available */
143
- onTemplateReceived = C(() => {
177
+ onTemplateReceived = E(() => {
144
178
  const e = this.template(), t = this.elementRef.nativeElement;
145
179
  if (e) {
146
180
  t.setAttribute("id", this.id()), t.setAttribute("title", this.title());
147
- const i = this.icon();
148
- i && t.setAttribute("icon", i);
149
- const r = this.tooltip();
150
- r && t.setAttribute("tooltip", r), t.setAttribute("order", String(this.order())), Ae.set(t, e);
181
+ const r = this.icon();
182
+ r && t.setAttribute("icon", r);
183
+ const i = this.tooltip();
184
+ i && t.setAttribute("tooltip", i), t.setAttribute("order", String(this.order())), Se.set(t, e);
151
185
  }
152
186
  });
153
187
  /**
@@ -158,30 +192,30 @@ class q {
158
192
  return !0;
159
193
  }
160
194
  }
161
- F = h(null), q = w(F, 0, "GridToolPanel", he, q), g(F, 1, q);
162
- const J = /* @__PURE__ */ new Map(), K = /* @__PURE__ */ new Map();
163
- function We(n) {
164
- const e = J.get(n);
195
+ B = h(null), q = v(B, 0, "GridToolPanel", Re, q), g(B, 1, q);
196
+ const Q = /* @__PURE__ */ new Map(), X = /* @__PURE__ */ new Map();
197
+ function Je(n) {
198
+ const e = Q.get(n);
165
199
  if (e) return e;
166
200
  const t = n.querySelector("tbw-grid-column-view");
167
201
  if (t)
168
- return be(t);
202
+ return De(t);
169
203
  }
170
- function Fe(n) {
171
- const e = K.get(n);
204
+ function Ke(n) {
205
+ const e = X.get(n);
172
206
  if (e) return e;
173
207
  const t = n.querySelector("tbw-grid-column-editor");
174
208
  if (t)
175
- return Ee(t);
209
+ return Te(t);
176
210
  }
177
- var ge, H;
178
- ge = [E({ selector: "[tbwRenderer]" })];
179
- class G {
180
- template = m(b);
181
- elementRef = m(v);
211
+ var we, Y;
212
+ we = [y({ selector: "[tbwRenderer]" })];
213
+ class k {
214
+ template = c(b);
215
+ elementRef = c(C);
182
216
  columnElement = null;
183
217
  constructor() {
184
- C(() => {
218
+ E(() => {
185
219
  this.registerTemplate();
186
220
  });
187
221
  }
@@ -189,10 +223,10 @@ class G {
189
223
  let e = this.elementRef.nativeElement?.parentElement;
190
224
  for (; e && e.tagName !== "TBW-GRID-COLUMN"; )
191
225
  e = e.parentElement;
192
- e && (this.columnElement = e, J.set(e, this.template));
226
+ e && (this.columnElement = e, Q.set(e, this.template));
193
227
  }
194
228
  ngOnDestroy() {
195
- this.columnElement && J.delete(this.columnElement);
229
+ this.columnElement && Q.delete(this.columnElement);
196
230
  }
197
231
  /**
198
232
  * Static type guard for template context.
@@ -202,15 +236,15 @@ class G {
202
236
  return !0;
203
237
  }
204
238
  }
205
- H = h(null), G = w(H, 0, "TbwRenderer", ge, G), g(H, 1, G);
206
- var we, B;
207
- we = [E({ selector: "[tbwEditor]" })];
208
- class k {
209
- template = m(b);
210
- elementRef = m(v);
239
+ Y = h(null), k = v(Y, 0, "TbwRenderer", we, k), g(Y, 1, k);
240
+ var Ce, z;
241
+ Ce = [y({ selector: "[tbwEditor]" })];
242
+ class $ {
243
+ template = c(b);
244
+ elementRef = c(C);
211
245
  columnElement = null;
212
246
  constructor() {
213
- C(() => {
247
+ E(() => {
214
248
  this.registerTemplate();
215
249
  });
216
250
  }
@@ -218,10 +252,10 @@ class k {
218
252
  let e = this.elementRef.nativeElement?.parentElement;
219
253
  for (; e && e.tagName !== "TBW-GRID-COLUMN"; )
220
254
  e = e.parentElement;
221
- e && (this.columnElement = e, K.set(e, this.template));
255
+ e && (this.columnElement = e, X.set(e, this.template));
222
256
  }
223
257
  ngOnDestroy() {
224
- this.columnElement && K.delete(this.columnElement);
258
+ this.columnElement && X.delete(this.columnElement);
225
259
  }
226
260
  /**
227
261
  * Static type guard for template context.
@@ -231,17 +265,17 @@ class k {
231
265
  return !0;
232
266
  }
233
267
  }
234
- B = h(null), k = w(B, 0, "TbwEditor", we, k), g(B, 1, k);
235
- const De = new Ve("GRID_TYPE_DEFAULTS");
236
- var Re, Y;
237
- Re = [_e({ providedIn: "root" })];
238
- class L {
268
+ z = h(null), $ = v(z, 0, "TbwEditor", Ce, $), g(z, 1, $);
269
+ const Ie = new ke("GRID_TYPE_DEFAULTS");
270
+ var Ee, J;
271
+ Ee = [$e({ providedIn: "root" })];
272
+ class P {
239
273
  defaults = /* @__PURE__ */ new Map();
240
274
  constructor() {
241
- const e = m(De, { optional: !0 });
275
+ const e = c(Ie, { optional: !0 });
242
276
  if (e)
243
- for (const [t, i] of Object.entries(e))
244
- this.defaults.set(t, i);
277
+ for (const [t, r] of Object.entries(e))
278
+ this.defaults.set(t, r);
245
279
  }
246
280
  /**
247
281
  * Register type-level defaults for a custom type.
@@ -292,23 +326,23 @@ class L {
292
326
  };
293
327
  }
294
328
  }
295
- Y = h(null), L = w(Y, 0, "GridTypeRegistry", Re, L), g(Y, 1, L);
296
- function Ke(n) {
297
- return qe([{ provide: De, useValue: n }]);
329
+ J = h(null), P = v(J, 0, "GridTypeRegistry", Ee, P), g(J, 1, P);
330
+ function nt(n) {
331
+ return Ge([{ provide: Ie, useValue: n }]);
298
332
  }
299
- function me(n) {
300
- const e = We(n);
301
- return e || be(n);
333
+ function de(n) {
334
+ const e = Je(n);
335
+ return e || De(n);
302
336
  }
303
- function ue(n) {
304
- const e = Fe(n);
305
- return e || Ee(n);
337
+ function pe(n) {
338
+ const e = Ke(n);
339
+ return e || Te(n);
306
340
  }
307
- class He {
308
- constructor(e, t, i) {
309
- this.injector = e, this.appRef = t, this.viewContainerRef = i, window.__ANGULAR_GRID_ADAPTER__ = this;
341
+ class Qe {
342
+ constructor(e, t, r) {
343
+ this.injector = e, this.appRef = t, this.viewContainerRef = r, window.__ANGULAR_GRID_ADAPTER__ = this;
310
344
  try {
311
- this.typeRegistry = this.injector.get(L, null);
345
+ this.typeRegistry = this.injector.get(P, null);
312
346
  } catch {
313
347
  }
314
348
  }
@@ -344,7 +378,7 @@ class He {
344
378
  processGridConfig(e) {
345
379
  if (!e.columns)
346
380
  return e;
347
- const t = e.columns.map((i) => this.processColumn(i));
381
+ const t = e.columns.map((r) => this.processColumn(r));
348
382
  return {
349
383
  ...e,
350
384
  columns: t
@@ -359,14 +393,14 @@ class He {
359
393
  */
360
394
  processColumn(e) {
361
395
  const t = { ...e };
362
- return e.renderer && le(e.renderer) && (t.renderer = this.createComponentRenderer(e.renderer)), e.editor && le(e.editor) && (t.editor = this.createComponentEditor(e.editor)), t;
396
+ return e.renderer && me(e.renderer) && (t.renderer = this.createComponentRenderer(e.renderer)), e.editor && me(e.editor) && (t.editor = this.createComponentEditor(e.editor)), t;
363
397
  }
364
398
  /**
365
399
  * Determines if this adapter can handle the given element.
366
400
  * Checks if a template is registered for this element (structural or nested).
367
401
  */
368
402
  canHandle(e) {
369
- return me(e) !== void 0 || ue(e) !== void 0;
403
+ return de(e) !== void 0 || pe(e) !== void 0;
370
404
  }
371
405
  /**
372
406
  * Creates a view renderer function that creates an embedded view
@@ -376,15 +410,15 @@ class He {
376
410
  * allowing the grid to use its default rendering.
377
411
  */
378
412
  createRenderer(e) {
379
- const t = me(e);
413
+ const t = de(e);
380
414
  if (t)
381
- return (i) => {
382
- const r = {
383
- $implicit: i.value,
384
- value: i.value,
385
- row: i.row,
386
- column: i.column
387
- }, s = this.viewContainerRef.createEmbeddedView(t, r);
415
+ return (r) => {
416
+ const i = {
417
+ $implicit: r.value,
418
+ value: r.value,
419
+ row: r.row,
420
+ column: r.column
421
+ }, s = this.viewContainerRef.createEmbeddedView(t, i);
388
422
  return this.viewRefs.push(s), s.detectChanges(), s.rootNodes[0];
389
423
  };
390
424
  }
@@ -407,29 +441,29 @@ class He {
407
441
  * As long as the component emits `(commit)` with the new value.
408
442
  */
409
443
  createEditor(e) {
410
- const t = ue(e);
411
- return t ? (i) => {
412
- const r = (o) => i.commit(o), s = () => i.cancel(), a = new re(), l = new re();
413
- a.subscribe((o) => i.commit(o)), l.subscribe(() => i.cancel());
414
- const y = {
415
- $implicit: i.value,
416
- value: i.value,
417
- row: i.row,
418
- column: i.column,
444
+ const t = pe(e);
445
+ return t ? (r) => {
446
+ const i = (a) => r.commit(a), s = () => r.cancel(), o = new oe(), l = new oe();
447
+ o.subscribe((a) => r.commit(a)), l.subscribe(() => r.cancel());
448
+ const w = {
449
+ $implicit: r.value,
450
+ value: r.value,
451
+ row: r.row,
452
+ column: r.column,
419
453
  // Preferred: simple callback functions
420
- onCommit: r,
454
+ onCommit: i,
421
455
  onCancel: s,
422
456
  // Deprecated: EventEmitters (for backwards compatibility)
423
- commit: a,
457
+ commit: o,
424
458
  cancel: l
425
- }, u = this.viewContainerRef.createEmbeddedView(t, y);
459
+ }, u = this.viewContainerRef.createEmbeddedView(t, w);
426
460
  this.viewRefs.push(u), u.detectChanges();
427
461
  const d = u.rootNodes[0];
428
- return d && d.addEventListener && (d.addEventListener("commit", (o) => {
429
- const T = o;
430
- i.commit(T.detail);
462
+ return d && d.addEventListener && (d.addEventListener("commit", (a) => {
463
+ const T = a;
464
+ r.commit(T.detail);
431
465
  }), d.addEventListener("cancel", () => {
432
- i.cancel();
466
+ r.cancel();
433
467
  })), d;
434
468
  } : (console.warn("[AngularGridAdapter] No editor template registered for element"), () => document.createElement("div"));
435
469
  }
@@ -438,16 +472,16 @@ class He {
438
472
  * Renders Angular templates for expandable detail rows.
439
473
  */
440
474
  createDetailRenderer(e) {
441
- const t = ce(e);
475
+ const t = ue(e);
442
476
  if (t)
443
- return (i) => {
444
- const r = {
445
- $implicit: i,
446
- row: i
447
- }, s = this.viewContainerRef.createEmbeddedView(t, r);
477
+ return (r) => {
478
+ const i = {
479
+ $implicit: r,
480
+ row: r
481
+ }, s = this.viewContainerRef.createEmbeddedView(t, i);
448
482
  this.viewRefs.push(s), s.detectChanges();
449
- const a = document.createElement("div");
450
- return s.rootNodes.forEach((l) => a.appendChild(l)), a;
483
+ const o = document.createElement("div");
484
+ return s.rootNodes.forEach((l) => o.appendChild(l)), o;
451
485
  };
452
486
  }
453
487
  /**
@@ -458,16 +492,37 @@ class He {
458
492
  * without manual configuration in the Grid directive.
459
493
  */
460
494
  parseDetailElement(e) {
461
- const t = ce(e.closest("tbw-grid"));
495
+ const t = ue(e.closest("tbw-grid"));
462
496
  if (t)
463
- return (i) => {
464
- const r = {
465
- $implicit: i,
466
- row: i
467
- }, s = this.viewContainerRef.createEmbeddedView(t, r);
497
+ return (r) => {
498
+ const i = {
499
+ $implicit: r,
500
+ row: r
501
+ }, s = this.viewContainerRef.createEmbeddedView(t, i);
468
502
  this.viewRefs.push(s), s.detectChanges();
469
- const a = document.createElement("div");
470
- return s.rootNodes.forEach((l) => a.appendChild(l)), a;
503
+ const o = document.createElement("div");
504
+ return s.rootNodes.forEach((l) => o.appendChild(l)), o;
505
+ };
506
+ }
507
+ /**
508
+ * Creates a responsive card renderer function for ResponsivePlugin.
509
+ * Renders Angular templates for card layout in responsive mode.
510
+ *
511
+ * @param gridElement - The grid element to look up the template for
512
+ * @returns A card renderer function or undefined if no template is found
513
+ */
514
+ createResponsiveCardRenderer(e) {
515
+ const t = Ye(e);
516
+ if (t)
517
+ return (r, i) => {
518
+ const s = {
519
+ $implicit: r,
520
+ row: r,
521
+ index: i
522
+ }, o = this.viewContainerRef.createEmbeddedView(t, s);
523
+ this.viewRefs.push(o), o.detectChanges();
524
+ const l = document.createElement("div");
525
+ return o.rootNodes.forEach((w) => l.appendChild(w)), l;
471
526
  };
472
527
  }
473
528
  /**
@@ -475,18 +530,18 @@ class He {
475
530
  * The renderer creates an Angular template-based panel content.
476
531
  */
477
532
  createToolPanelRenderer(e) {
478
- const t = $e(e);
533
+ const t = ze(e);
479
534
  if (!t)
480
535
  return;
481
- const i = e.closest("tbw-grid");
482
- return (r) => {
536
+ const r = e.closest("tbw-grid");
537
+ return (i) => {
483
538
  const s = {
484
- $implicit: i ?? r,
485
- grid: i ?? r
486
- }, a = this.viewContainerRef.createEmbeddedView(t, s);
487
- return this.viewRefs.push(a), a.detectChanges(), a.rootNodes.forEach((l) => r.appendChild(l)), () => {
488
- const l = this.viewRefs.indexOf(a);
489
- l > -1 && this.viewRefs.splice(l, 1), a.destroy();
539
+ $implicit: r ?? i,
540
+ grid: r ?? i
541
+ }, o = this.viewContainerRef.createEmbeddedView(t, s);
542
+ return this.viewRefs.push(o), o.detectChanges(), o.rootNodes.forEach((l) => i.appendChild(l)), () => {
543
+ const l = this.viewRefs.indexOf(o);
544
+ l > -1 && this.viewRefs.splice(l, 1), o.destroy();
490
545
  };
491
546
  };
492
547
  }
@@ -523,10 +578,10 @@ class He {
523
578
  const t = this.typeRegistry.get(e);
524
579
  if (!t)
525
580
  return;
526
- const i = {
581
+ const r = {
527
582
  editorParams: t.editorParams
528
583
  };
529
- return t.renderer && (i.renderer = this.createComponentRenderer(t.renderer)), t.editor && (i.editor = this.createComponentEditor(t.editor)), i;
584
+ return t.renderer && (r.renderer = this.createComponentRenderer(t.renderer)), t.editor && (r.editor = this.createComponentEditor(t.editor)), r;
530
585
  }
531
586
  /**
532
587
  * Creates a renderer function from an Angular component class.
@@ -534,17 +589,17 @@ class He {
534
589
  */
535
590
  createComponentRenderer(e) {
536
591
  return (t) => {
537
- const i = document.createElement("span");
538
- i.style.display = "contents";
539
- const r = se(e, {
592
+ const r = document.createElement("span");
593
+ r.style.display = "contents";
594
+ const i = ae(e, {
540
595
  environmentInjector: this.injector,
541
- hostElement: i
596
+ hostElement: r
542
597
  });
543
- return this.setComponentInputs(r, {
598
+ return this.setComponentInputs(i, {
544
599
  value: t.value,
545
600
  row: t.row,
546
601
  column: t.column
547
- }), this.appRef.attachView(r.hostView), this.componentRefs.push(r), r.changeDetectorRef.detectChanges(), i;
602
+ }), this.appRef.attachView(i.hostView), this.componentRefs.push(i), i.changeDetectorRef.detectChanges(), r;
548
603
  };
549
604
  }
550
605
  /**
@@ -553,24 +608,24 @@ class He {
553
608
  */
554
609
  createComponentEditor(e) {
555
610
  return (t) => {
556
- const i = document.createElement("span");
557
- i.style.display = "contents";
558
- const r = se(e, {
611
+ const r = document.createElement("span");
612
+ r.style.display = "contents";
613
+ const i = ae(e, {
559
614
  environmentInjector: this.injector,
560
- hostElement: i
615
+ hostElement: r
561
616
  });
562
- this.setComponentInputs(r, {
617
+ this.setComponentInputs(i, {
563
618
  value: t.value,
564
619
  row: t.row,
565
620
  column: t.column
566
- }), this.appRef.attachView(r.hostView), this.componentRefs.push(r), r.changeDetectorRef.detectChanges();
567
- const s = r.instance;
568
- return this.subscribeToOutput(s, "commit", (a) => t.commit(a)), this.subscribeToOutput(s, "cancel", () => t.cancel()), i.addEventListener("commit", (a) => {
569
- const l = a;
621
+ }), this.appRef.attachView(i.hostView), this.componentRefs.push(i), i.changeDetectorRef.detectChanges();
622
+ const s = i.instance;
623
+ return this.subscribeToOutput(s, "commit", (o) => t.commit(o)), this.subscribeToOutput(s, "cancel", () => t.cancel()), r.addEventListener("commit", (o) => {
624
+ const l = o;
570
625
  t.commit(l.detail);
571
- }), i.addEventListener("cancel", () => {
626
+ }), r.addEventListener("cancel", () => {
572
627
  t.cancel();
573
- }), i;
628
+ }), r;
574
629
  };
575
630
  }
576
631
  /**
@@ -578,18 +633,18 @@ class He {
578
633
  * Works with both EventEmitter and OutputEmitterRef (signal outputs).
579
634
  * @internal
580
635
  */
581
- subscribeToOutput(e, t, i) {
582
- const r = e[t];
583
- r && typeof r.subscribe == "function" && r.subscribe(i);
636
+ subscribeToOutput(e, t, r) {
637
+ const i = e[t];
638
+ i && typeof i.subscribe == "function" && i.subscribe(r);
584
639
  }
585
640
  /**
586
641
  * Sets component inputs using Angular's setInput API.
587
642
  * @internal
588
643
  */
589
644
  setComponentInputs(e, t) {
590
- for (const [i, r] of Object.entries(t))
645
+ for (const [r, i] of Object.entries(t))
591
646
  try {
592
- e.setInput(i, r);
647
+ e.setInput(r, i);
593
648
  } catch {
594
649
  }
595
650
  }
@@ -601,21 +656,21 @@ class He {
601
656
  this.viewRefs.forEach((e) => e.destroy()), this.viewRefs = [], this.componentRefs.forEach((e) => e.destroy()), this.componentRefs = [];
602
657
  }
603
658
  }
604
- var ve, z;
605
- ve = [E({ selector: "tbw-grid" })];
606
- class x {
607
- elementRef = m(v);
608
- injector = m(Ge);
609
- appRef = m(ke);
610
- viewContainerRef = m(xe);
659
+ var ye, K;
660
+ ye = [y({ selector: "tbw-grid" })];
661
+ class G {
662
+ elementRef = c(C);
663
+ injector = c(Ue);
664
+ appRef = c(We);
665
+ viewContainerRef = c(Fe);
611
666
  adapter = null;
612
667
  cellCommitListener = null;
613
668
  constructor() {
614
- C(() => {
669
+ E(() => {
615
670
  const e = this.angularConfig();
616
671
  if (!e || !this.adapter) return;
617
- const t = this.adapter.processGridConfig(e), i = this.elementRef.nativeElement;
618
- i.gridConfig = t;
672
+ const t = this.adapter.processGridConfig(e), r = this.elementRef.nativeElement;
673
+ r.gridConfig = t;
619
674
  });
620
675
  }
621
676
  rowCommitListener = null;
@@ -689,7 +744,7 @@ class x {
689
744
  * }
690
745
  * ```
691
746
  */
692
- cellCommit = oe();
747
+ cellCommit = le();
693
748
  /**
694
749
  * Emitted when a row's values are committed (bulk/row editing).
695
750
  * Provides the row data and change tracking information.
@@ -699,22 +754,22 @@ class x {
699
754
  * <tbw-grid (rowCommit)="onRowCommit($event)">...</tbw-grid>
700
755
  * ```
701
756
  */
702
- rowCommit = oe();
757
+ rowCommit = le();
703
758
  ngOnInit() {
704
- this.adapter = new He(this.injector, this.appRef, this.viewContainerRef), Ue.registerAdapter(this.adapter);
759
+ this.adapter = new Qe(this.injector, this.appRef, this.viewContainerRef), He.registerAdapter(this.adapter);
705
760
  const e = this.elementRef.nativeElement;
706
761
  this.cellCommitListener = (t) => {
707
- const i = t.detail;
708
- this.cellCommit.emit(i);
762
+ const r = t.detail;
763
+ this.cellCommit.emit(r);
709
764
  }, e.addEventListener("cell-commit", this.cellCommitListener), this.rowCommitListener = (t) => {
710
- const i = t.detail;
711
- this.rowCommit.emit(i);
765
+ const r = t.detail;
766
+ this.rowCommit.emit(r);
712
767
  }, e.addEventListener("row-commit", this.rowCommitListener), e.__frameworkAdapter = this.adapter;
713
768
  }
714
769
  ngAfterContentInit() {
715
770
  const e = this.elementRef.nativeElement;
716
771
  e && typeof e.refreshColumns == "function" && setTimeout(() => {
717
- e.refreshColumns(), this.configureMasterDetail(e), typeof e.refreshShellHeader == "function" && e.refreshShellHeader(), this.registerCustomStyles(e);
772
+ e.refreshColumns(), this.configureMasterDetail(e), this.configureResponsiveCard(e), typeof e.refreshShellHeader == "function" && e.refreshShellHeader(), this.registerCustomStyles(e);
718
773
  }, 0);
719
774
  }
720
775
  /**
@@ -734,47 +789,72 @@ class x {
734
789
  */
735
790
  configureMasterDetail(e) {
736
791
  if (!this.adapter) return;
737
- const t = e.getPlugin?.(ae);
792
+ const t = e.getPlugin?.(ce);
738
793
  if (t && typeof t.refreshDetailRenderer == "function") {
739
794
  t.refreshDetailRenderer();
740
795
  return;
741
796
  }
742
- const i = e.querySelector("tbw-grid-detail");
743
- if (!i) return;
744
- const r = this.adapter.createDetailRenderer(e);
797
+ const r = e.querySelector("tbw-grid-detail");
745
798
  if (!r) return;
746
- const s = i.getAttribute("animation");
747
- let a = "slide";
748
- s === "false" ? a = !1 : s === "fade" && (a = "fade");
749
- const l = i.getAttribute("showExpandColumn") !== "false", y = new ae({
750
- detailRenderer: r,
799
+ const i = this.adapter.createDetailRenderer(e);
800
+ if (!i) return;
801
+ const s = r.getAttribute("animation");
802
+ let o = "slide";
803
+ s === "false" ? o = !1 : s === "fade" && (o = "fade");
804
+ const l = r.getAttribute("showExpandColumn") !== "false", w = new ce({
805
+ detailRenderer: i,
751
806
  showExpandColumn: l,
752
- animation: a
807
+ animation: o
753
808
  }), u = e.gridConfig || {}, d = u.plugins || [];
754
809
  e.gridConfig = {
755
810
  ...u,
756
- plugins: [...d, y]
811
+ plugins: [...d, w]
757
812
  };
758
813
  }
814
+ /**
815
+ * Configures the ResponsivePlugin with Angular template-based card renderer.
816
+ * - If plugin exists: updates its cardRenderer configuration
817
+ * - If plugin doesn't exist but <tbw-grid-responsive-card> is present: logs a warning
818
+ */
819
+ configureResponsiveCard(e) {
820
+ if (!this.adapter || !e.querySelector("tbw-grid-responsive-card")) return;
821
+ const r = this.adapter.createResponsiveCardRenderer(e);
822
+ if (!r) return;
823
+ const i = e.getPlugin?.(Be);
824
+ if (i) {
825
+ i.setCardRenderer(r);
826
+ return;
827
+ }
828
+ console.warn(
829
+ `[tbw-grid-angular] <tbw-grid-responsive-card> found but ResponsivePlugin is not configured.
830
+ Add ResponsivePlugin to your gridConfig.plugins array:
831
+
832
+ import { ResponsivePlugin } from "@toolbox-web/grid/all";
833
+ gridConfig = {
834
+ plugins: [new ResponsivePlugin({ breakpoint: 600 })]
835
+ };`
836
+ );
837
+ }
759
838
  ngOnDestroy() {
760
839
  const e = this.elementRef.nativeElement;
761
840
  e && (this.cellCommitListener && (e.removeEventListener("cell-commit", this.cellCommitListener), this.cellCommitListener = null), this.rowCommitListener && (e.removeEventListener("row-commit", this.rowCommitListener), this.rowCommitListener = null)), e && this.customStyles() && e.unregisterStyles?.("angular-custom-styles"), this.adapter && (this.adapter.destroy?.(), this.adapter = null);
762
841
  }
763
842
  }
764
- z = h(null), x = w(z, 0, "Grid", ve, x), g(z, 1, x);
843
+ K = h(null), G = v(K, 0, "Grid", ye, G), g(K, 1, G);
765
844
  export {
766
- He as AngularGridAdapter,
767
- De as GRID_TYPE_DEFAULTS,
768
- x as Grid,
845
+ Qe as AngularGridAdapter,
846
+ Ie as GRID_TYPE_DEFAULTS,
847
+ G as Grid,
769
848
  M as GridColumnEditor,
770
849
  V as GridColumnView,
771
850
  _ as GridDetailView,
851
+ x as GridResponsiveCard,
772
852
  q as GridToolPanel,
773
- L as GridTypeRegistry,
774
- k as TbwCellEditor,
775
- G as TbwCellView,
776
- k as TbwEditor,
777
- G as TbwRenderer,
778
- le as isComponentClass,
779
- Ke as provideGridTypeDefaults
853
+ P as GridTypeRegistry,
854
+ $ as TbwCellEditor,
855
+ k as TbwCellView,
856
+ $ as TbwEditor,
857
+ k as TbwRenderer,
858
+ me as isComponentClass,
859
+ nt as provideGridTypeDefaults
780
860
  };
@@ -149,6 +149,14 @@ export declare class AngularGridAdapter implements FrameworkAdapter {
149
149
  * without manual configuration in the Grid directive.
150
150
  */
151
151
  parseDetailElement<TRow = unknown>(detailElement: Element): ((row: TRow, rowIndex: number) => HTMLElement | string) | undefined;
152
+ /**
153
+ * Creates a responsive card renderer function for ResponsivePlugin.
154
+ * Renders Angular templates for card layout in responsive mode.
155
+ *
156
+ * @param gridElement - The grid element to look up the template for
157
+ * @returns A card renderer function or undefined if no template is found
158
+ */
159
+ createResponsiveCardRenderer<TRow = unknown>(gridElement: HTMLElement): ((row: TRow, rowIndex: number) => HTMLElement) | undefined;
152
160
  /**
153
161
  * Creates a tool panel renderer from a light DOM element.
154
162
  * The renderer creates an Angular template-based panel content.
@@ -1 +1 @@
1
- {"version":3,"file":"angular-grid-adapter.d.ts","sourceRoot":"","sources":["../../../../libs/grid-angular/src/lib/angular-grid-adapter.ts"],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I,KAAK,WAAW,CAAC,GAAG,SAAS;IA4BxG;;;;;;OAMG;IACH,kBAAkB,CAAC,IAAI,GAAG,OAAO,EAC/B,aAAa,EAAE,OAAO,GACrB,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,KAAK,WAAW,GAAG,MAAM,CAAC,GAAG,SAAS;IA4BtE;;;;;;OAMG;IACH,4BAA4B,CAAC,IAAI,GAAG,OAAO,EACzC,WAAW,EAAE,WAAW,GACvB,CAAC,CAAC,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,KAAK,WAAW,CAAC,GAAG,SAAS;IA6B7D;;;OAGG;IACH,uBAAuB,CAAC,OAAO,EAAE,WAAW,GAAG,CAAC,CAAC,SAAS,EAAE,WAAW,KAAK,IAAI,GAAG,CAAC,MAAM,IAAI,CAAC,CAAC,GAAG,SAAS;IAsC5G;;;;;;;;;;;;;;;;;;;;;;;;;;OA0BG;IACH,cAAc,CAAC,IAAI,GAAG,OAAO,EAAE,IAAI,EAAE,MAAM,GAAG,WAAW,CAAC,IAAI,CAAC,GAAG,SAAS;IA2B3E;;;OAGG;IACH,OAAO,CAAC,uBAAuB;IAgC/B;;;OAGG;IACH,OAAO,CAAC,qBAAqB;IA+C7B;;;;OAIG;IACH,OAAO,CAAC,iBAAiB;IAczB;;;OAGG;IACH,OAAO,CAAC,kBAAkB;IAU1B;;;OAGG;IACH,OAAO,IAAI,IAAI;CAMhB"}
@@ -0,0 +1,92 @@
1
+ import { TemplateRef } from '@angular/core';
2
+ /**
3
+ * Context object passed to the responsive card template.
4
+ *
5
+ * @template TRow - The type of row data
6
+ *
7
+ * @example
8
+ * ```html
9
+ * <tbw-grid-responsive-card>
10
+ * <ng-template let-row let-index="index">
11
+ * <div class="card-content">
12
+ * <span>{{ row.name }}</span>
13
+ * <span>Row #{{ index }}</span>
14
+ * </div>
15
+ * </ng-template>
16
+ * </tbw-grid-responsive-card>
17
+ * ```
18
+ */
19
+ export interface GridResponsiveCardContext<TRow = unknown> {
20
+ /**
21
+ * The row data (available as `let-row` or `let-myVar`).
22
+ */
23
+ $implicit: TRow;
24
+ /**
25
+ * The row data (explicit access via `let-row="row"`).
26
+ */
27
+ row: TRow;
28
+ /**
29
+ * The row index (zero-based).
30
+ */
31
+ index: number;
32
+ }
33
+ /**
34
+ * Registry to store responsive card templates by grid element.
35
+ * Used by AngularGridAdapter to create card renderers.
36
+ */
37
+ export declare const responsiveCardTemplateRegistry: Map<HTMLElement, TemplateRef<GridResponsiveCardContext<unknown>>>;
38
+ /**
39
+ * Retrieves the responsive card template for a grid element.
40
+ *
41
+ * @param gridElement - The grid element to look up
42
+ * @returns The template reference or undefined if not found
43
+ */
44
+ export declare function getResponsiveCardTemplate(gridElement: HTMLElement): TemplateRef<GridResponsiveCardContext> | undefined;
45
+ /**
46
+ * Directive for providing custom Angular templates for responsive card layout.
47
+ *
48
+ * Use this directive to define how each row should render when the grid
49
+ * is in responsive/mobile mode. The template receives the row data and index.
50
+ *
51
+ * ## Usage
52
+ *
53
+ * ```html
54
+ * <tbw-grid [rows]="employees">
55
+ * <tbw-grid-responsive-card>
56
+ * <ng-template let-employee let-idx="index">
57
+ * <div class="employee-card">
58
+ * <img [src]="employee.avatar" alt="">
59
+ * <div class="info">
60
+ * <strong>{{ employee.name }}</strong>
61
+ * <span>{{ employee.department }}</span>
62
+ * </div>
63
+ * </div>
64
+ * </ng-template>
65
+ * </tbw-grid-responsive-card>
66
+ * </tbw-grid>
67
+ * ```
68
+ *
69
+ * ## Important Notes
70
+ *
71
+ * - The ResponsivePlugin must be added to your grid config
72
+ * - The Grid directive will automatically configure the plugin's cardRenderer
73
+ * - Template context provides `$implicit` (row), `row`, and `index`
74
+ *
75
+ * @see ResponsivePlugin
76
+ */
77
+ export declare class GridResponsiveCard<TRow = unknown> {
78
+ private elementRef;
79
+ /**
80
+ * The ng-template containing the card content.
81
+ */
82
+ template: import('@angular/core').Signal<TemplateRef<any> | undefined>;
83
+ /**
84
+ * Effect that registers the template when it becomes available.
85
+ */
86
+ private onTemplateReceived;
87
+ /**
88
+ * Type guard for template context inference.
89
+ */
90
+ static ngTemplateContextGuard<T>(_directive: GridResponsiveCard<T>, context: unknown): context is GridResponsiveCardContext<T>;
91
+ }
92
+ //# sourceMappingURL=grid-responsive-card.directive.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grid-responsive-card.directive.d.ts","sourceRoot":"","sources":["../../../../../libs/grid-angular/src/lib/directives/grid-responsive-card.directive.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuD,WAAW,EAAE,MAAM,eAAe,CAAC;AAEjG;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,WAAW,yBAAyB,CAAC,IAAI,GAAG,OAAO;IACvD;;OAEG;IACH,SAAS,EAAE,IAAI,CAAC;IAEhB;;OAEG;IACH,GAAG,EAAE,IAAI,CAAC;IAEV;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,eAAO,MAAM,8BAA8B,mEAAiE,CAAC;AAE7G;;;;;GAKG;AACH,wBAAgB,yBAAyB,CACvC,WAAW,EAAE,WAAW,GACvB,WAAW,CAAC,yBAAyB,CAAC,GAAG,SAAS,CAKpD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,qBAGa,kBAAkB,CAAC,IAAI,GAAG,OAAO;IAC5C,OAAO,CAAC,UAAU,CAAmC;IAErD;;OAEG;IACH,QAAQ,+DAA8D;IAEtE;;OAEG;IACH,OAAO,CAAC,kBAAkB,CAQvB;IAEH;;OAEG;IACH,MAAM,CAAC,sBAAsB,CAAC,CAAC,EAC7B,UAAU,EAAE,kBAAkB,CAAC,CAAC,CAAC,EACjC,OAAO,EAAE,OAAO,GACf,OAAO,IAAI,yBAAyB,CAAC,CAAC,CAAC;CAG3C"}
@@ -171,6 +171,12 @@ export declare class Grid implements OnInit, AfterContentInit, OnDestroy {
171
171
  * - If plugin doesn't exist but <tbw-grid-detail> is present: create and add the plugin
172
172
  */
173
173
  private configureMasterDetail;
174
+ /**
175
+ * Configures the ResponsivePlugin with Angular template-based card renderer.
176
+ * - If plugin exists: updates its cardRenderer configuration
177
+ * - If plugin doesn't exist but <tbw-grid-responsive-card> is present: logs a warning
178
+ */
179
+ private configureResponsiveCard;
174
180
  ngOnDestroy(): void;
175
181
  }
176
182
  //# sourceMappingURL=grid.directive.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"grid.directive.d.ts","sourceRoot":"","sources":["../../../../../libs/grid-angular/src/lib/directives/grid.directive.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAQhB,SAAS,EACT,MAAM,EAGP,MAAM,eAAe,CAAC;AAGvB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAGlE;;GAEG;AACH,MAAM,WAAW,eAAe,CAAC,IAAI,GAAG,OAAO,EAAE,MAAM,GAAG,OAAO;IAC/D,0BAA0B;IAC1B,GAAG,EAAE,IAAI,CAAC;IACV,0CAA0C;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,+BAA+B;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,sCAAsC;IACtC,QAAQ,EAAE,MAAM,CAAC;IACjB,gDAAgD;IAChD,WAAW,EAAE,IAAI,EAAE,CAAC;IACpB,iDAAiD;IACjD,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC/B,yDAAyD;IACzD,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,cAAc,CAAC,IAAI,GAAG,OAAO;IAC5C,0BAA0B;IAC1B,GAAG,EAAE,IAAI,CAAC;IACV,sCAAsC;IACtC,QAAQ,EAAE,MAAM,CAAC;IACjB,gDAAgD;IAChD,WAAW,EAAE,IAAI,EAAE,CAAC;IACpB,iDAAiD;IACjD,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IAC/B,yDAAyD;IACzD,eAAe,EAAE,OAAO,CAAC;CAC1B;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,qBACa,IAAK,YAAW,MAAM,EAAE,gBAAgB,EAAE,SAAS;IAC9D,OAAO,CAAC,UAAU,CAAmC;IACrD,OAAO,CAAC,QAAQ,CAA+B;IAC/C,OAAO,CAAC,MAAM,CAA0B;IACxC,OAAO,CAAC,gBAAgB,CAA4B;IAEpD,OAAO,CAAC,OAAO,CAAmC;IAClD,OAAO,CAAC,kBAAkB,CAAqC;;IAgB/D,OAAO,CAAC,iBAAiB,CAAqC;IAE9D;;;;;;;;;;;;;;;;OAgBG;IACH,YAAY,0DAAmB;IAE/B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAkCG;IAEH,aAAa,0EAAmC;IAEhD;;;;;;;;;;;;;;OAcG;IACH,UAAU,8EAA6B;IAEvC;;;;;;;;OAQG;IACH,SAAS,oEAA4B;IAErC,QAAQ,IAAI,IAAI;IAyBhB,kBAAkB,IAAI,IAAI;IAwB1B;;;OAGG;IACH,OAAO,CAAC,oBAAoB;IAU5B;;;;OAIG;IACH,OAAO,CAAC,qBAAqB;IA4C7B,WAAW,IAAI,IAAI;CAyBpB"}
1
+ {"version":3,"file":"grid.directive.d.ts","sourceRoot":"","sources":["../../../../../libs/grid-angular/src/lib/directives/grid.directive.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAQhB,SAAS,EACT,MAAM,EAGP,MAAM,eAAe,CAAC;AAGvB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAGlE;;GAEG;AACH,MAAM,WAAW,eAAe,CAAC,IAAI,GAAG,OAAO,EAAE,MAAM,GAAG,OAAO;IAC/D,0BAA0B;IAC1B,GAAG,EAAE,IAAI,CAAC;IACV,0CAA0C;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,+BAA+B;IAC/B,KAAK,EAAE,MAAM,CAAC;IACd,sCAAsC;IACtC,QAAQ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CAAC,uBAAuB;IA6B/B,WAAW,IAAI,IAAI;CAyBpB"}
@@ -1,6 +1,7 @@
1
1
  export { GridColumnEditor } from './grid-column-editor.directive';
2
2
  export { GridColumnView } from './grid-column-view.directive';
3
3
  export { GridDetailView } from './grid-detail-view.directive';
4
+ export { GridResponsiveCard } from './grid-responsive-card.directive';
4
5
  export { GridToolPanel } from './grid-tool-panel.directive';
5
6
  export { Grid } from './grid.directive';
6
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../libs/grid-angular/src/lib/directives/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../libs/grid-angular/src/lib/directives/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,gCAAgC,CAAC;AAClE,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AACtE,OAAO,EAAE,aAAa,EAAE,MAAM,6BAA6B,CAAC;AAC5D,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@toolbox-web/grid-angular",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "description": "Angular adapter for @toolbox-web/grid data grid component",
5
5
  "type": "module",
6
6
  "main": "./index.js",