@naptics/vue-collection 0.1.10 → 0.2.1

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.
Files changed (53) hide show
  1. package/components/NAlert.d.ts +0 -12
  2. package/components/NAlert.js +1 -5
  3. package/components/NBadge.d.ts +21 -12
  4. package/components/NBadge.js +5 -3
  5. package/components/NBreadcrub.d.ts +3 -15
  6. package/components/NBreadcrub.js +3 -7
  7. package/components/NButton.d.ts +21 -12
  8. package/components/NButton.js +5 -3
  9. package/components/NCheckbox.d.ts +0 -12
  10. package/components/NCheckbox.js +2 -6
  11. package/components/NCheckboxLabel.d.ts +0 -3
  12. package/components/NCheckboxLabel.js +2 -8
  13. package/components/NDropdown.d.ts +89 -14
  14. package/components/NDropdown.js +9 -7
  15. package/components/NDropzone.d.ts +0 -12
  16. package/components/NDropzone.js +2 -6
  17. package/components/NFormModal.js +11 -7
  18. package/components/NIconButton.d.ts +21 -12
  19. package/components/NIconButton.js +5 -3
  20. package/components/NIconCircle.d.ts +0 -12
  21. package/components/NIconCircle.js +2 -6
  22. package/components/NInput.d.ts +9 -18
  23. package/components/NInput.js +1 -7
  24. package/components/NInputPhone.d.ts +9 -9
  25. package/components/NInputSelect.d.ts +9 -9
  26. package/components/NInputSuggestion.d.ts +9 -9
  27. package/components/NLink.d.ts +0 -12
  28. package/components/NLink.js +1 -5
  29. package/components/NList.d.ts +0 -12
  30. package/components/NList.js +2 -8
  31. package/components/NLoadingIndicator.d.ts +0 -12
  32. package/components/NLoadingIndicator.js +2 -6
  33. package/components/NPagination.d.ts +0 -12
  34. package/components/NPagination.js +1 -5
  35. package/components/NSearchbar.d.ts +0 -12
  36. package/components/NSearchbar.js +1 -7
  37. package/components/NSearchbarList.d.ts +0 -12
  38. package/components/NSearchbarList.js +1 -6
  39. package/components/NSelect.d.ts +9 -18
  40. package/components/NSelect.js +0 -4
  41. package/components/NTable.d.ts +27 -53
  42. package/components/NTable.js +21 -30
  43. package/components/NTableAction.d.ts +0 -12
  44. package/components/NTableAction.js +1 -5
  45. package/components/NTextArea.d.ts +9 -18
  46. package/components/NTextArea.js +0 -4
  47. package/components/NTooltip.d.ts +32 -12
  48. package/components/NTooltip.js +21 -11
  49. package/components/NValInput.d.ts +9 -9
  50. package/components/NValInput.js +4 -9
  51. package/package.json +1 -1
  52. package/utils/utils.d.ts +7 -0
  53. package/utils/utils.js +9 -0
@@ -23,10 +23,6 @@ export declare const nPaginationProps: {
23
23
  * If set to `true`, the pagination is displayed smaller.
24
24
  */
25
25
  readonly small: BooleanConstructor;
26
- /**
27
- * Adds the classes to the top-level element.
28
- */
29
- readonly addClass: StringConstructor;
30
26
  /**
31
27
  * This is called, when the visible pages, which are selectable in the pagination, have changed.
32
28
  * This is useful as only these pages can be navigated to on the next click.
@@ -60,10 +56,6 @@ declare const _default: import("vue").DefineComponent<{
60
56
  * If set to `true`, the pagination is displayed smaller.
61
57
  */
62
58
  readonly small: BooleanConstructor;
63
- /**
64
- * Adds the classes to the top-level element.
65
- */
66
- readonly addClass: StringConstructor;
67
59
  /**
68
60
  * This is called, when the visible pages, which are selectable in the pagination, have changed.
69
61
  * This is useful as only these pages can be navigated to on the next click.
@@ -93,10 +85,6 @@ declare const _default: import("vue").DefineComponent<{
93
85
  * If set to `true`, the pagination is displayed smaller.
94
86
  */
95
87
  readonly small: BooleanConstructor;
96
- /**
97
- * Adds the classes to the top-level element.
98
- */
99
- readonly addClass: StringConstructor;
100
88
  /**
101
89
  * This is called, when the visible pages, which are selectable in the pagination, have changed.
102
90
  * This is useful as only these pages can be navigated to on the next click.
@@ -26,10 +26,6 @@ export const nPaginationProps = {
26
26
  * If set to `true`, the pagination is displayed smaller.
27
27
  */
28
28
  small: Boolean,
29
- /**
30
- * Adds the classes to the top-level element.
31
- */
32
- addClass: String,
33
29
  /**
34
30
  * This is called, when the visible pages, which are selectable in the pagination, have changed.
35
31
  * This is useful as only these pages can be navigated to on the next click.
@@ -77,7 +73,7 @@ export default createComponent('NPagination', nPaginationProps, props => {
77
73
  }));
78
74
  const classesForItem = item => ['pagination-item', item.selectable ? 'selectable ' : '', item.selected ? 'selected' : '', props.small ? '' : 'not-small'];
79
75
  return () => _createVNode("nav", {
80
- "class": ['inline-flex rounded-md shadow -space-x-px', props.addClass]
76
+ "class": "inline-flex rounded-md shadow -space-x-px"
81
77
  }, [_createVNode("button", {
82
78
  "class": ['pagination-item selectable rounded-l-md', props.small ? '' : 'not-small'],
83
79
  "onClick": previous
@@ -15,10 +15,6 @@ export declare const nSearchbarProps: {
15
15
  * Adds the classes directly to the input (e.g. for shadow).
16
16
  */
17
17
  readonly inputClass: StringConstructor;
18
- /**
19
- * Adds the classes to the top-level element.
20
- */
21
- readonly addClass: StringConstructor;
22
18
  /**
23
19
  * This is called when the search-bar receives focus.
24
20
  */
@@ -55,10 +51,6 @@ declare const _default: import("vue").DefineComponent<{
55
51
  * Adds the classes directly to the input (e.g. for shadow).
56
52
  */
57
53
  readonly inputClass: StringConstructor;
58
- /**
59
- * Adds the classes to the top-level element.
60
- */
61
- readonly addClass: StringConstructor;
62
54
  /**
63
55
  * This is called when the search-bar receives focus.
64
56
  */
@@ -85,10 +77,6 @@ declare const _default: import("vue").DefineComponent<{
85
77
  * Adds the classes directly to the input (e.g. for shadow).
86
78
  */
87
79
  readonly inputClass: StringConstructor;
88
- /**
89
- * Adds the classes to the top-level element.
90
- */
91
- readonly addClass: StringConstructor;
92
80
  /**
93
81
  * This is called when the search-bar receives focus.
94
82
  */
@@ -21,10 +21,6 @@ export const nSearchbarProps = {
21
21
  * Adds the classes directly to the input (e.g. for shadow).
22
22
  */
23
23
  inputClass: String,
24
- /**
25
- * Adds the classes to the top-level element.
26
- */
27
- addClass: String,
28
24
  /**
29
25
  * This is called when the search-bar receives focus.
30
26
  */
@@ -45,9 +41,7 @@ export default createComponent('NSearchbar', nSearchbarProps, (props, context) =
45
41
  }
46
42
  };
47
43
  context.expose(exposed);
48
- return () => _createVNode("div", {
49
- "class": props.addClass
50
- }, [_createVNode("label", {
44
+ return () => _createVNode("div", null, [_createVNode("label", {
51
45
  "for": "search",
52
46
  "class": "sr-only"
53
47
  }, [props.placeholder]), _createVNode("div", {
@@ -10,10 +10,6 @@ export declare const nSearchbarListProps: {
10
10
  * Adds the classes directly to the input (e.g. for shadow).
11
11
  */
12
12
  readonly inputClass: StringConstructor;
13
- /**
14
- * Adds the classes to the top-level element.
15
- */
16
- readonly addClass: StringConstructor;
17
13
  readonly value: import("vue").PropType<string>;
18
14
  readonly onUpdateValue: import("vue").PropType<(newValue: string) => void>;
19
15
  readonly items: {
@@ -45,10 +41,6 @@ declare const _default: import("vue").DefineComponent<{
45
41
  * Adds the classes directly to the input (e.g. for shadow).
46
42
  */
47
43
  readonly inputClass: StringConstructor;
48
- /**
49
- * Adds the classes to the top-level element.
50
- */
51
- readonly addClass: StringConstructor;
52
44
  readonly value: import("vue").PropType<string>;
53
45
  readonly onUpdateValue: import("vue").PropType<(newValue: string) => void>;
54
46
  readonly items: {
@@ -76,10 +68,6 @@ declare const _default: import("vue").DefineComponent<{
76
68
  * Adds the classes directly to the input (e.g. for shadow).
77
69
  */
78
70
  readonly inputClass: StringConstructor;
79
- /**
80
- * Adds the classes to the top-level element.
81
- */
82
- readonly addClass: StringConstructor;
83
71
  readonly value: import("vue").PropType<string>;
84
72
  readonly onUpdateValue: import("vue").PropType<(newValue: string) => void>;
85
73
  readonly items: {
@@ -14,11 +14,7 @@ export const nSearchbarListProps = {
14
14
  /**
15
15
  * Adds the classes directly to the input (e.g. for shadow).
16
16
  */
17
- inputClass: String,
18
- /**
19
- * Adds the classes to the top-level element.
20
- */
21
- addClass: String
17
+ inputClass: String
22
18
  };
23
19
  /**
24
20
  * The `NSearchbarList` is a {@link NSearchbar} with a {@link NSuggestionList}.
@@ -36,7 +32,6 @@ export default createComponentWithSlots('NSearchbarList', nSearchbarListProps, [
36
32
  "onUpdateValue": props.onUpdateValue,
37
33
  "placeholder": props.placeholder,
38
34
  "inputClass": `shadow-lg ${props.inputClass}`,
39
- "addClass": props.addClass,
40
35
  "onFocus": onFocus,
41
36
  "onBlur": onBlur
42
37
  }, null),
@@ -14,8 +14,9 @@ export declare const nSelectProps: {
14
14
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
15
15
  readonly default: "max-w-xs";
16
16
  };
17
- readonly tooltipWrapperAddClass: StringConstructor;
18
- readonly tooltipContentAddClass: StringConstructor;
17
+ readonly tooltipWrapperClass: StringConstructor;
18
+ readonly tooltipContentClass: StringConstructor;
19
+ readonly tooltipArrowClass: StringConstructor;
19
20
  /**
20
21
  * The id of the currently selected option of this input.
21
22
  */
@@ -53,10 +54,6 @@ export declare const nSelectProps: {
53
54
  * @see {@link nValInputProps.inputClass}
54
55
  */
55
56
  readonly inputClass: StringConstructor;
56
- /**
57
- * @see {@link nValInputProps.addClass}
58
- */
59
- readonly addClass: StringConstructor;
60
57
  };
61
58
  export type SelectionOption = Identifiable & {
62
59
  label: string;
@@ -78,8 +75,9 @@ declare const _default: import("vue").DefineComponent<{
78
75
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
79
76
  readonly default: "max-w-xs";
80
77
  };
81
- readonly tooltipWrapperAddClass: StringConstructor;
82
- readonly tooltipContentAddClass: StringConstructor;
78
+ readonly tooltipWrapperClass: StringConstructor;
79
+ readonly tooltipContentClass: StringConstructor;
80
+ readonly tooltipArrowClass: StringConstructor;
83
81
  /**
84
82
  * The id of the currently selected option of this input.
85
83
  */
@@ -117,10 +115,6 @@ declare const _default: import("vue").DefineComponent<{
117
115
  * @see {@link nValInputProps.inputClass}
118
116
  */
119
117
  readonly inputClass: StringConstructor;
120
- /**
121
- * @see {@link nValInputProps.addClass}
122
- */
123
- readonly addClass: StringConstructor;
124
118
  }, 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<{
125
119
  readonly tooltipText: StringConstructor;
126
120
  readonly tooltipContent: PropType<() => JSX.Element>;
@@ -134,8 +128,9 @@ declare const _default: import("vue").DefineComponent<{
134
128
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
135
129
  readonly default: "max-w-xs";
136
130
  };
137
- readonly tooltipWrapperAddClass: StringConstructor;
138
- readonly tooltipContentAddClass: StringConstructor;
131
+ readonly tooltipWrapperClass: StringConstructor;
132
+ readonly tooltipContentClass: StringConstructor;
133
+ readonly tooltipArrowClass: StringConstructor;
139
134
  /**
140
135
  * The id of the currently selected option of this input.
141
136
  */
@@ -173,10 +168,6 @@ declare const _default: import("vue").DefineComponent<{
173
168
  * @see {@link nValInputProps.inputClass}
174
169
  */
175
170
  readonly inputClass: StringConstructor;
176
- /**
177
- * @see {@link nValInputProps.addClass}
178
- */
179
- readonly addClass: StringConstructor;
180
171
  }>> & {}, {
181
172
  readonly tooltipHide: boolean;
182
173
  readonly tooltipShow: boolean;
@@ -42,10 +42,6 @@ export const nSelectProps = {
42
42
  * @see {@link nValInputProps.inputClass}
43
43
  */
44
44
  inputClass: nValInputProps.inputClass,
45
- /**
46
- * @see {@link nValInputProps.addClass}
47
- */
48
- addClass: nValInputProps.addClass,
49
45
  ...nToolTipPropsForImplementor
50
46
  };
51
47
  /**
@@ -1,6 +1,7 @@
1
1
  import { type TWBreakpoint } from '../utils/breakpoints';
2
2
  import { type PropType } from 'vue';
3
3
  import './NTable.css';
4
+ export type TableItem = string | number | (() => JSX.Element);
4
5
  export type TableHeading = {
5
6
  /**
6
7
  * The key of the table heading. This should match the key of the items.
@@ -9,7 +10,7 @@ export type TableHeading = {
9
10
  /**
10
11
  * The label of the table heading. If not set, no label is displayed.
11
12
  */
12
- label?: string;
13
+ label?: TableItem;
13
14
  /**
14
15
  * If set to `true` the whole column of this heading will be emphasized.
15
16
  */
@@ -19,19 +20,18 @@ export type TableHeading = {
19
20
  */
20
21
  cellClass?: string;
21
22
  /**
22
- * If set the heading will become a details entry when the screen is smaller than the specified breakpoint.
23
+ * This classes will be directly set on all cells of this heading, when they show up in the details.
23
24
  */
24
- breakpoint?: TWBreakpoint;
25
- };
26
- export type TableDetail = {
25
+ detailsClass?: string;
27
26
  /**
28
- * The key of the table details. This should match the key of the items.
27
+ * If set the heading will become a details entry when the screen is smaller than the specified breakpoint.
29
28
  */
30
- key: string;
29
+ breakpoint?: TWBreakpoint;
31
30
  /**
32
- * The label of the table detail. If not set, no label is displayed.
31
+ * If set to `true`, this heading will always show up inside the details. If this is set the `breakpoint`
32
+ * property has no effect, because the items always show up as details ignoring the breakpoint.
33
33
  */
34
- label?: string;
34
+ isDetail?: boolean;
35
35
  };
36
36
  export type TableRow = Record<string, TableItem> & {
37
37
  /**
@@ -40,7 +40,6 @@ export type TableRow = Record<string, TableItem> & {
40
40
  */
41
41
  action?: TableItem;
42
42
  };
43
- export type TableItem = string | number | (() => JSX.Element);
44
43
  export declare const nTableProps: {
45
44
  /**
46
45
  * The headings of the table. These define which columns are shown in the table and in which order.
@@ -50,17 +49,13 @@ export declare const nTableProps: {
50
49
  readonly required: true;
51
50
  };
52
51
  /**
53
- * Details can be added additionally to headings.
54
- * If details are set a little chevron icon is displayed at the end of each table row
55
- * and if clicked on it the data is displayed in a key-value fashion.
56
- * The values of the entries should be passed via the `items` prop
57
- * in the same way as if the details were normal headings.
58
- * Note that details can be added dynamically by adding the `breakpoint` property to the headings.
52
+ * Adds the classes to all headings at the top of the table.
59
53
  */
60
- readonly details: {
61
- readonly type: PropType<TableDetail[]>;
62
- readonly default: () => never[];
63
- };
54
+ readonly headingsClass: StringConstructor;
55
+ /**
56
+ * Adds the classes to all headings in the details of the table.
57
+ */
58
+ readonly headingDetailsClass: StringConstructor;
64
59
  /**
65
60
  * The items of the table. They consist of an array of table rows.
66
61
  * Every tablerow is an object containing elements for the heading keys.
@@ -86,10 +81,6 @@ export declare const nTableProps: {
86
81
  readonly type: PropType<TableRow[]>;
87
82
  readonly default: () => never[];
88
83
  };
89
- /**
90
- * Adds the classes to the top-level element.
91
- */
92
- readonly addClass: StringConstructor;
93
84
  };
94
85
  /**
95
86
  * The `NTable` is a styled html table which accepts data and displays it appropriately.
@@ -103,17 +94,13 @@ declare const _default: import("vue").DefineComponent<{
103
94
  readonly required: true;
104
95
  };
105
96
  /**
106
- * Details can be added additionally to headings.
107
- * If details are set a little chevron icon is displayed at the end of each table row
108
- * and if clicked on it the data is displayed in a key-value fashion.
109
- * The values of the entries should be passed via the `items` prop
110
- * in the same way as if the details were normal headings.
111
- * Note that details can be added dynamically by adding the `breakpoint` property to the headings.
97
+ * Adds the classes to all headings at the top of the table.
112
98
  */
113
- readonly details: {
114
- readonly type: PropType<TableDetail[]>;
115
- readonly default: () => never[];
116
- };
99
+ readonly headingsClass: StringConstructor;
100
+ /**
101
+ * Adds the classes to all headings in the details of the table.
102
+ */
103
+ readonly headingDetailsClass: StringConstructor;
117
104
  /**
118
105
  * The items of the table. They consist of an array of table rows.
119
106
  * Every tablerow is an object containing elements for the heading keys.
@@ -139,10 +126,6 @@ declare const _default: import("vue").DefineComponent<{
139
126
  readonly type: PropType<TableRow[]>;
140
127
  readonly default: () => never[];
141
128
  };
142
- /**
143
- * Adds the classes to the top-level element.
144
- */
145
- readonly addClass: StringConstructor;
146
129
  }, 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<{
147
130
  /**
148
131
  * The headings of the table. These define which columns are shown in the table and in which order.
@@ -152,17 +135,13 @@ declare const _default: import("vue").DefineComponent<{
152
135
  readonly required: true;
153
136
  };
154
137
  /**
155
- * Details can be added additionally to headings.
156
- * If details are set a little chevron icon is displayed at the end of each table row
157
- * and if clicked on it the data is displayed in a key-value fashion.
158
- * The values of the entries should be passed via the `items` prop
159
- * in the same way as if the details were normal headings.
160
- * Note that details can be added dynamically by adding the `breakpoint` property to the headings.
138
+ * Adds the classes to all headings at the top of the table.
161
139
  */
162
- readonly details: {
163
- readonly type: PropType<TableDetail[]>;
164
- readonly default: () => never[];
165
- };
140
+ readonly headingsClass: StringConstructor;
141
+ /**
142
+ * Adds the classes to all headings in the details of the table.
143
+ */
144
+ readonly headingDetailsClass: StringConstructor;
166
145
  /**
167
146
  * The items of the table. They consist of an array of table rows.
168
147
  * Every tablerow is an object containing elements for the heading keys.
@@ -188,12 +167,7 @@ declare const _default: import("vue").DefineComponent<{
188
167
  readonly type: PropType<TableRow[]>;
189
168
  readonly default: () => never[];
190
169
  };
191
- /**
192
- * Adds the classes to the top-level element.
193
- */
194
- readonly addClass: StringConstructor;
195
170
  }>> & {}, {
196
- readonly details: TableDetail[];
197
171
  readonly items: TableRow[];
198
172
  }>;
199
173
  export default _default;
@@ -15,17 +15,13 @@ export const nTableProps = {
15
15
  required: true
16
16
  },
17
17
  /**
18
- * Details can be added additionally to headings.
19
- * If details are set a little chevron icon is displayed at the end of each table row
20
- * and if clicked on it the data is displayed in a key-value fashion.
21
- * The values of the entries should be passed via the `items` prop
22
- * in the same way as if the details were normal headings.
23
- * Note that details can be added dynamically by adding the `breakpoint` property to the headings.
18
+ * Adds the classes to all headings at the top of the table.
24
19
  */
25
- details: {
26
- type: Array,
27
- default: () => []
28
- },
20
+ headingsClass: String,
21
+ /**
22
+ * Adds the classes to all headings in the details of the table.
23
+ */
24
+ headingDetailsClass: String,
29
25
  /**
30
26
  * The items of the table. They consist of an array of table rows.
31
27
  * Every tablerow is an object containing elements for the heading keys.
@@ -50,19 +46,15 @@ export const nTableProps = {
50
46
  items: {
51
47
  type: Array,
52
48
  default: () => []
53
- },
54
- /**
55
- * Adds the classes to the top-level element.
56
- */
57
- addClass: String
49
+ }
58
50
  };
59
51
  /**
60
52
  * The `NTable` is a styled html table which accepts data and displays it appropriately.
61
53
  */
62
54
  export default createComponent('NTable', nTableProps, props => {
63
55
  const headings = computed(() => {
64
- // remove all headings which are below the breakpoint
65
- const headings = props.headings.filter(heading => !heading.breakpoint || isWidthBreakpoint(heading.breakpoint).value);
56
+ // filter out details headings
57
+ const headings = props.headings.filter(heading => !isHeadingDetail(heading));
66
58
  // The column for actions is shown if there are details
67
59
  // or if any of the items contain an element with the action-key.
68
60
  if (showDetails.value || props.items.filter(row => row.action != null).length != 0) {
@@ -72,12 +64,7 @@ export default createComponent('NTable', nTableProps, props => {
72
64
  }
73
65
  return headings;
74
66
  });
75
- const details = computed(() => {
76
- // take all headings which are below the breakpoint
77
- const details = props.headings.filter(heading => heading.breakpoint && !isWidthBreakpoint(heading.breakpoint).value);
78
- details.push(...props.details);
79
- return details;
80
- });
67
+ const details = computed(() => props.headings.filter(isHeadingDetail));
81
68
  const showDetails = computed(() => details.value.length > 0);
82
69
  const detailsOpen = ref([]);
83
70
  const isDetailsOpen = index => detailsOpen.value[index] || false;
@@ -90,7 +77,7 @@ export default createComponent('NTable', nTableProps, props => {
90
77
  immediate: true
91
78
  });
92
79
  return () => _createVNode("div", {
93
- "class": `overflow-x-auto ${props.addClass}`
80
+ "class": "overflow-x-auto"
94
81
  }, [_createVNode("table", {
95
82
  "class": "min-w-full text-default-500 text-sm"
96
83
  }, [_createVNode("thead", {
@@ -98,8 +85,8 @@ export default createComponent('NTable', nTableProps, props => {
98
85
  }, [_createVNode("tr", null, [headings.value.map(heading => _createVNode("th", {
99
86
  "key": heading.key,
100
87
  "scope": "col",
101
- "class": "p-4 table-heading"
102
- }, [heading.label]))])]), props.items.length > 0 && props.items.map((item, itemIndex) => _createVNode(_Fragment, {
88
+ "class": `p-4 table-heading ${props.headingsClass}`
89
+ }, [buildItem(heading.label)]))])]), props.items.length > 0 && props.items.map((item, itemIndex) => _createVNode(_Fragment, {
103
90
  "key": itemIndex
104
91
  }, [_createVNode("tbody", {
105
92
  "class": ['border-default-200 border-t', itemIndex % 2 === 0 ? 'bg-white' : 'bg-default-50']
@@ -116,9 +103,9 @@ export default createComponent('NTable', nTableProps, props => {
116
103
  }, [details.value.map((detail, detailIndex) => _createVNode("tr", {
117
104
  "key": `detail-${detailIndex}`
118
105
  }, [_createVNode("td", {
119
- "class": ['table-heading px-4 py-1', details.value.length - 1 == detailIndex ? 'pb-4' : '']
120
- }, [detail.label]), _createVNode("td", {
121
- "class": ['px-4 py-1', details.value.length - 1 == detailIndex ? 'pb-4' : ''],
106
+ "class": ['table-heading px-4 py-1', props.headingDetailsClass, details.value.length - 1 == detailIndex ? 'pb-4' : '']
107
+ }, [buildItem(detail.label)]), _createVNode("td", {
108
+ "class": ['px-4 py-1', details.value[detailIndex].detailsClass, details.value.length - 1 == detailIndex ? 'pb-4' : ''],
122
109
  "colspan": headings.value.length - 1
123
110
  }, [item[detail.key] && buildItem(item[detail.key])])]))])]))])]);
124
111
  });
@@ -126,5 +113,9 @@ export default createComponent('NTable', nTableProps, props => {
126
113
  * Builds a JSX-Element out of the item
127
114
  */
128
115
  function buildItem(item) {
129
- if (typeof item == 'string' || typeof item == 'number') return _createVNode(_Fragment, null, [item]);else return item();
116
+ if (item === undefined) return undefined;else if (typeof item == 'string' || typeof item == 'number') return _createVNode(_Fragment, null, [item]);else return item();
117
+ }
118
+ function isHeadingDetail(heading) {
119
+ // take all headings which are details or below the breakpoint
120
+ return heading.isDetail || heading.breakpoint !== undefined && !isWidthBreakpoint(heading.breakpoint).value;
130
121
  }
@@ -16,10 +16,6 @@ export declare const nTableActionProps: {
16
16
  readonly type: PropType<"button" | "submit" | "reset">;
17
17
  readonly default: "button";
18
18
  };
19
- /**
20
- * Adds the classes to the top-level element.
21
- */
22
- readonly addClass: StringConstructor;
23
19
  /**
24
20
  * This is called when the action is clicked.
25
21
  * It is only called when the `route` prop is not set on the action.
@@ -46,10 +42,6 @@ declare const _default: import("vue").DefineComponent<{
46
42
  readonly type: PropType<"button" | "submit" | "reset">;
47
43
  readonly default: "button";
48
44
  };
49
- /**
50
- * Adds the classes to the top-level element.
51
- */
52
- readonly addClass: StringConstructor;
53
45
  /**
54
46
  * This is called when the action is clicked.
55
47
  * It is only called when the `route` prop is not set on the action.
@@ -71,10 +63,6 @@ declare const _default: import("vue").DefineComponent<{
71
63
  readonly type: PropType<"button" | "submit" | "reset">;
72
64
  readonly default: "button";
73
65
  };
74
- /**
75
- * Adds the classes to the top-level element.
76
- */
77
- readonly addClass: StringConstructor;
78
66
  /**
79
67
  * This is called when the action is clicked.
80
68
  * It is only called when the `route` prop is not set on the action.
@@ -18,10 +18,6 @@ export const nTableActionProps = {
18
18
  * The html attribute, which indicates the type of the button.
19
19
  */
20
20
  type: nButtonProps.type,
21
- /**
22
- * Adds the classes to the top-level element.
23
- */
24
- addClass: String,
25
21
  /**
26
22
  * This is called when the action is clicked.
27
23
  * It is only called when the `route` prop is not set on the action.
@@ -36,7 +32,7 @@ export default createComponent('NTableAction', nTableActionProps, (props, {
36
32
  slots
37
33
  }) => {
38
34
  const content = () => slots.default?.() || _createVNode(_Fragment, null, [props.text]);
39
- const classes = ['text-left font-medium focus:outline-none focus-visible:ring-2 focus-visible:ring-default-900 rounded-sm ring-offset-2 text-default-900 hover:underline hover:text-default-700', props.addClass];
35
+ const classes = ['text-left font-medium focus:outline-none focus-visible:ring-2 focus-visible:ring-default-900 rounded-sm ring-offset-2 text-default-900 hover:underline hover:text-default-700'];
40
36
  return () => {
41
37
  let _slot;
42
38
  return props.route ? _createVNode(RouterLink, {
@@ -22,8 +22,9 @@ export declare const nTextAreaProps: {
22
22
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
23
23
  readonly default: "max-w-xs";
24
24
  };
25
- readonly tooltipWrapperAddClass: StringConstructor;
26
- readonly tooltipContentAddClass: StringConstructor;
25
+ readonly tooltipWrapperClass: StringConstructor;
26
+ readonly tooltipContentClass: StringConstructor;
27
+ readonly tooltipArrowClass: StringConstructor;
27
28
  /**
28
29
  * The name of the text area. Is displayed as a label above the text area.
29
30
  */
@@ -69,10 +70,6 @@ export declare const nTextAreaProps: {
69
70
  * Adds the classes directly to the input (e.g. for shadow).
70
71
  */
71
72
  readonly inputClass: StringConstructor;
72
- /**
73
- * Adds the classes to the top-level element.
74
- */
75
- readonly addClass: StringConstructor;
76
73
  /**
77
74
  * This is called when the text area reveices focus.
78
75
  */
@@ -113,8 +110,9 @@ declare const _default: import("vue").DefineComponent<{
113
110
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
114
111
  readonly default: "max-w-xs";
115
112
  };
116
- readonly tooltipWrapperAddClass: StringConstructor;
117
- readonly tooltipContentAddClass: StringConstructor;
113
+ readonly tooltipWrapperClass: StringConstructor;
114
+ readonly tooltipContentClass: StringConstructor;
115
+ readonly tooltipArrowClass: StringConstructor;
118
116
  /**
119
117
  * The name of the text area. Is displayed as a label above the text area.
120
118
  */
@@ -160,10 +158,6 @@ declare const _default: import("vue").DefineComponent<{
160
158
  * Adds the classes directly to the input (e.g. for shadow).
161
159
  */
162
160
  readonly inputClass: StringConstructor;
163
- /**
164
- * Adds the classes to the top-level element.
165
- */
166
- readonly addClass: StringConstructor;
167
161
  /**
168
162
  * This is called when the text area reveices focus.
169
163
  */
@@ -197,8 +191,9 @@ declare const _default: import("vue").DefineComponent<{
197
191
  readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
198
192
  readonly default: "max-w-xs";
199
193
  };
200
- readonly tooltipWrapperAddClass: StringConstructor;
201
- readonly tooltipContentAddClass: StringConstructor;
194
+ readonly tooltipWrapperClass: StringConstructor;
195
+ readonly tooltipContentClass: StringConstructor;
196
+ readonly tooltipArrowClass: StringConstructor;
202
197
  /**
203
198
  * The name of the text area. Is displayed as a label above the text area.
204
199
  */
@@ -244,10 +239,6 @@ declare const _default: import("vue").DefineComponent<{
244
239
  * Adds the classes directly to the input (e.g. for shadow).
245
240
  */
246
241
  readonly inputClass: StringConstructor;
247
- /**
248
- * Adds the classes to the top-level element.
249
- */
250
- readonly addClass: StringConstructor;
251
242
  /**
252
243
  * This is called when the text area reveices focus.
253
244
  */
@@ -56,10 +56,6 @@ const nTextAreaBaseProps = {
56
56
  * Adds the classes directly to the input (e.g. for shadow).
57
57
  */
58
58
  inputClass: String,
59
- /**
60
- * Adds the classes to the top-level element.
61
- */
62
- addClass: String,
63
59
  /**
64
60
  * This is called when the text area reveices focus.
65
61
  */