@naptics/vue-collection 0.2.12 → 0.2.14

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.
@@ -95,6 +95,7 @@ export declare const nCrudModalProps: {
95
95
  readonly onOk: PropType<() => void>;
96
96
  readonly onCancel: PropType<() => void>;
97
97
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
98
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
98
99
  readonly header: PropType<() => JSX.Element>;
99
100
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
100
101
  readonly value: PropType<boolean>;
@@ -200,6 +201,7 @@ declare const Component: import("vue").DefineComponent<{
200
201
  readonly onOk: PropType<() => void>;
201
202
  readonly onCancel: PropType<() => void>;
202
203
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
204
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
203
205
  readonly header: PropType<() => JSX.Element>;
204
206
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
205
207
  readonly value: PropType<boolean>;
@@ -299,6 +301,7 @@ declare const Component: import("vue").DefineComponent<{
299
301
  readonly onOk: PropType<() => void>;
300
302
  readonly onCancel: PropType<() => void>;
301
303
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
304
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
302
305
  readonly header: PropType<() => JSX.Element>;
303
306
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
304
307
  readonly value: PropType<boolean>;
@@ -52,6 +52,7 @@ export declare const nFormModalProps: {
52
52
  readonly onOk: PropType<() => void>;
53
53
  readonly onCancel: PropType<() => void>;
54
54
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
55
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
55
56
  readonly header: PropType<() => JSX.Element>;
56
57
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
57
58
  readonly value: PropType<boolean>;
@@ -113,6 +114,7 @@ declare const Component: import("vue").DefineComponent<{
113
114
  readonly onOk: PropType<() => void>;
114
115
  readonly onCancel: PropType<() => void>;
115
116
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
117
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
116
118
  readonly header: PropType<() => JSX.Element>;
117
119
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
118
120
  readonly value: PropType<boolean>;
@@ -168,6 +170,7 @@ declare const Component: import("vue").DefineComponent<{
168
170
  readonly onOk: PropType<() => void>;
169
171
  readonly onCancel: PropType<() => void>;
170
172
  readonly modal: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
173
+ readonly content: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
171
174
  readonly header: PropType<() => JSX.Element>;
172
175
  readonly footer: PropType<(props: import("./NModal").ModalSlotProps) => JSX.Element>;
173
176
  readonly value: PropType<boolean>;
@@ -22,9 +22,13 @@ export declare const nListProps: {
22
22
  */
23
23
  readonly titleClass: StringConstructor;
24
24
  /**
25
- * Adds the classese to all text elements (on the right side).
25
+ * Adds the classes to all text elements (on the right side).
26
26
  */
27
27
  readonly textClass: StringConstructor;
28
+ /**
29
+ * Adds the classes to each row.
30
+ */
31
+ readonly rowClass: StringConstructor;
28
32
  };
29
33
  /**
30
34
  * The `NList` displays key-value data in an appealing way.
@@ -42,9 +46,13 @@ declare const Component: import("vue").DefineComponent<{
42
46
  */
43
47
  readonly titleClass: StringConstructor;
44
48
  /**
45
- * Adds the classese to all text elements (on the right side).
49
+ * Adds the classes to all text elements (on the right side).
46
50
  */
47
51
  readonly textClass: StringConstructor;
52
+ /**
53
+ * Adds the classes to each row.
54
+ */
55
+ readonly rowClass: StringConstructor;
48
56
  }, import("vue").RenderFunction, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, never[], never, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
49
57
  /**
50
58
  * The items which are displayed in the list.
@@ -58,9 +66,13 @@ declare const Component: import("vue").DefineComponent<{
58
66
  */
59
67
  readonly titleClass: StringConstructor;
60
68
  /**
61
- * Adds the classese to all text elements (on the right side).
69
+ * Adds the classes to all text elements (on the right side).
62
70
  */
63
71
  readonly textClass: StringConstructor;
72
+ /**
73
+ * Adds the classes to each row.
74
+ */
75
+ readonly rowClass: StringConstructor;
64
76
  }>> & {}, {
65
77
  readonly items: ListItem[];
66
78
  }>;
@@ -13,9 +13,13 @@ export const nListProps = {
13
13
  */
14
14
  titleClass: String,
15
15
  /**
16
- * Adds the classese to all text elements (on the right side).
16
+ * Adds the classes to all text elements (on the right side).
17
17
  */
18
- textClass: String
18
+ textClass: String,
19
+ /**
20
+ * Adds the classes to each row.
21
+ */
22
+ rowClass: String
19
23
  };
20
24
  /**
21
25
  * The `NList` displays key-value data in an appealing way.
@@ -23,7 +27,7 @@ export const nListProps = {
23
27
  const Component = createComponent('NList', nListProps, props => {
24
28
  return () => _createVNode("dl", null, [props.items.map((item, index) => _createVNode("div", {
25
29
  "key": index,
26
- "class": ['py-5 px-4 sm:grid sm:grid-cols-3 sm:gap-4', index % 2 === 1 ? 'bg-white' : 'bg-default-50']
30
+ "class": ['py-5 px-4 sm:grid sm:grid-cols-3 sm:gap-4', index % 2 === 1 ? 'bg-white' : 'bg-default-50', props.rowClass]
27
31
  }, [_createVNode("dt", {
28
32
  "class": `text-sm font-medium text-default-500 ${props.titleClass}`
29
33
  }, [buildElement(item.title)]), _createVNode("dd", {
@@ -92,6 +92,10 @@ export declare const nModalProps: {
92
92
  * A slot to replace the whole modal content including all buttons, header and footer.
93
93
  */
94
94
  readonly modal: PropType<(props: ModalSlotProps) => JSX.Element>;
95
+ /**
96
+ * A slot to replace the whole content section, i.e. everything between the header and the footer.
97
+ */
98
+ readonly content: PropType<(props: ModalSlotProps) => JSX.Element>;
95
99
  /**
96
100
  * A slot to replace the whole header section (excluding the x).
97
101
  */
@@ -203,6 +207,10 @@ declare const Component: import("vue").DefineComponent<{
203
207
  * A slot to replace the whole modal content including all buttons, header and footer.
204
208
  */
205
209
  readonly modal: PropType<(props: ModalSlotProps) => JSX.Element>;
210
+ /**
211
+ * A slot to replace the whole content section, i.e. everything between the header and the footer.
212
+ */
213
+ readonly content: PropType<(props: ModalSlotProps) => JSX.Element>;
206
214
  /**
207
215
  * A slot to replace the whole header section (excluding the x).
208
216
  */
@@ -305,6 +313,10 @@ declare const Component: import("vue").DefineComponent<{
305
313
  * A slot to replace the whole modal content including all buttons, header and footer.
306
314
  */
307
315
  readonly modal: PropType<(props: ModalSlotProps) => JSX.Element>;
316
+ /**
317
+ * A slot to replace the whole content section, i.e. everything between the header and the footer.
318
+ */
319
+ readonly content: PropType<(props: ModalSlotProps) => JSX.Element>;
308
320
  /**
309
321
  * A slot to replace the whole header section (excluding the x).
310
322
  */
@@ -99,6 +99,10 @@ export const nModalProps = {
99
99
  * A slot to replace the whole modal content including all buttons, header and footer.
100
100
  */
101
101
  modal: Function,
102
+ /**
103
+ * A slot to replace the whole content section, i.e. everything between the header and the footer.
104
+ */
105
+ content: Function,
102
106
  /**
103
107
  * A slot to replace the whole header section (excluding the x).
104
108
  */
@@ -183,7 +187,10 @@ const Component = createComponentWithSlots('NModal', nModalProps, ['modal', 'hea
183
187
  "class": "text-lg font-semibold"
184
188
  }, {
185
189
  default: () => [props.title]
186
- })]), _createVNode("div", {
190
+ })]), props.content?.({
191
+ ok,
192
+ cancel
193
+ }) || _createVNode("div", {
187
194
  "class": "px-4 sm:px-6 py-4 rounded-lg"
188
195
  }, [slots.default?.()]), !props.hideFooter && _createVNode("div", {
189
196
  "class": "px-4 sm:px-6 pb-4 pt-2 bg-default-50 rounded-b-lg"
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@naptics/vue-collection",
3
3
  "author": "Timo Siegenthaler",
4
4
  "description": "Vue Collection is a collection of styled and fully functional Vue components which can easily be integrated into our projects.",
5
- "version": "0.2.12",
5
+ "version": "0.2.14",
6
6
  "main": "./index.js",
7
7
  "repository": {
8
8
  "type": "git",