@nova-design-system/nova-react 3.29.0 → 3.30.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/dist/cjs/{constants-BReL3Lsa-DpB_ghPF.js → constants-gOKBmbgZ-CSoZ8z-G.js} +5 -0
- package/dist/cjs/generated/components.server.js +33 -1
- package/dist/cjs/index-DXwd3F_r.js +10391 -0
- package/dist/cjs/index.js +7 -1
- package/dist/cjs/{nv-accordion-item.entry-D1o0gC5w.js → nv-accordion-item.entry-CTbduehY.js} +3 -3
- package/dist/cjs/{nv-accordion.entry-DYJtq9Az.js → nv-accordion.entry-DeaPwIUP.js} +2 -2
- package/dist/cjs/{nv-alert.entry-CMtCdHmk.js → nv-alert.entry-B5k8RXXD.js} +8 -8
- package/dist/cjs/{nv-avatar.entry-B6e7aG4W.js → nv-avatar.entry-CJh9bGfN.js} +8 -8
- package/dist/cjs/{nv-badge_2.entry-RD3j0bJM.js → nv-badge_2.entry-BnPPW4rW.js} +5 -5
- package/dist/cjs/{nv-breadcrumb.entry-DgpqY2fr.js → nv-breadcrumb.entry-DS5GJVCJ.js} +2 -2
- package/dist/cjs/{nv-breadcrumbs.entry-CZgcDUw5.js → nv-breadcrumbs.entry-CJ835Ba8.js} +2 -2
- package/dist/cjs/{nv-button.entry-DR9NaRxG.js → nv-button.entry-8U0o_X3d.js} +7 -7
- package/dist/cjs/{nv-buttongroup.entry-qO8r7WqG.js → nv-buttongroup.entry-D5I5d9y0.js} +2 -2
- package/dist/cjs/{nv-calendar.entry-DRlv3Xph.js → nv-calendar.entry-C0ggIM3A.js} +9 -9
- package/dist/cjs/{nv-col.entry-B7utJttP.js → nv-col.entry-tIk723nS.js} +2 -2
- package/dist/cjs/{nv-datagrid.entry-digYmlnA.js → nv-datagrid.entry-Cal_usTi.js} +8 -8
- package/dist/cjs/{nv-datagridcolumn.entry-UwaDi-Hr.js → nv-datagridcolumn.entry-BLbpwW7Q.js} +2 -2
- package/dist/cjs/{nv-datetest.entry-BJtWaM2T.js → nv-datetest.entry-NQzySOox.js} +2 -2
- package/dist/cjs/{nv-datetimetest.entry-WaNPcHxh.js → nv-datetimetest.entry-Br6j4eAR.js} +1 -1
- package/dist/cjs/{nv-dialog.entry-BI_mFT2G.js → nv-dialog.entry-GTDQJaoQ.js} +3 -3
- package/dist/cjs/{nv-dialogfooter_2.entry-DU2ClBUR.js → nv-dialogfooter_2.entry-CHY36NHl.js} +6 -6
- package/dist/cjs/{nv-drawer.entry-BKF4CyOt.js → nv-drawer.entry-C-TZDi4-.js} +3 -3
- package/dist/cjs/{nv-drawerfooter_2.entry-BSyUs7_4.js → nv-drawerfooter_2.entry-DTY4qAnd.js} +6 -6
- package/dist/cjs/{nv-fieldcheckbox.entry-l5FWToQi.js → nv-fieldcheckbox.entry-Qf4gdEnq.js} +5 -5
- package/dist/cjs/{nv-fielddate.entry-BfviesNp.js → nv-fielddate.entry-D1aJmKbh.js} +7 -7
- package/dist/cjs/{nv-fielddaterange.entry-BvDkPLXG.js → nv-fielddaterange.entry-Vc-gHwf8.js} +7 -7
- package/dist/cjs/{nv-fielddropdown.entry-B-nYjuMt.js → nv-fielddropdown.entry-BVVsM71m.js} +5 -5
- package/dist/cjs/{nv-fielddropdownitem.entry-Dxqyb9DN.js → nv-fielddropdownitem.entry-DTRonCZJ.js} +2 -2
- package/dist/cjs/{nv-fieldmultiselect.entry-CgO1RP0W.js → nv-fieldmultiselect.entry-Cvsh_jn7.js} +1 -1
- package/dist/cjs/{nv-fieldnumber.entry-stgdLi7x.js → nv-fieldnumber.entry-jVFZ0wj3.js} +5 -5
- package/dist/cjs/{nv-fieldpassword.entry-CHA3JAUd.js → nv-fieldpassword.entry-CQKbWqMe.js} +5 -5
- package/dist/cjs/{nv-fieldradio.entry-DHavVjB-.js → nv-fieldradio.entry-FPGOqFBo.js} +4 -4
- package/dist/cjs/{nv-fieldselect.entry-Dq5AsOFt.js → nv-fieldselect.entry-DJmW4pff.js} +6 -6
- package/dist/cjs/{nv-fieldslider.entry-SlF3BBUW.js → nv-fieldslider.entry-D71HjSto.js} +4 -4
- package/dist/cjs/{nv-fieldtext.entry-BYCc8SyD.js → nv-fieldtext.entry-BxgbvxEW.js} +5 -5
- package/dist/cjs/{nv-fieldtextarea.entry-96JCOb9L.js → nv-fieldtextarea.entry-BDS37zhJ.js} +4 -4
- package/dist/cjs/{nv-fieldtime.entry-BdzjxkaK.js → nv-fieldtime.entry-DkWokxdT.js} +44 -44
- package/dist/cjs/{nv-icon.entry-CSRxi6BH.js → nv-icon.entry-CUemAv89.js} +8 -8
- package/dist/cjs/{nv-iconbutton_2.entry-BtDxwMFD.js → nv-iconbutton_2.entry-BLdJr3QV.js} +3 -3
- package/dist/cjs/{nv-menu.entry-aX39SPH8.js → nv-menu.entry-z4cDNCeX.js} +2 -2
- package/dist/cjs/{nv-menuitem.entry-DzSp52G2.js → nv-menuitem.entry-4XdONuGl.js} +2 -2
- package/dist/cjs/{nv-notification-bullet.entry-D2yOXj46.js → nv-notification-bullet.entry-B1EK4G_X.js} +1 -1
- package/dist/cjs/{nv-notification.entry-BRXHbtT8.js → nv-notification.entry-BBAQ72f7.js} +19 -19
- package/dist/cjs/{nv-notificationcontainer.entry-YNIM2_ah.js → nv-notificationcontainer.entry-CtFunFA9.js} +2 -2
- package/dist/cjs/{nv-pagination-nav.entry-uY1nT9aT.js → nv-pagination-nav.entry-DbzEBjoa.js} +2 -2
- package/dist/cjs/{nv-paginationtable.entry-mr5KYXVC.js → nv-paginationtable.entry-DRGsk0DH.js} +19 -3
- package/dist/cjs/{nv-popover.entry-_9ARKM70.js → nv-popover.entry-w9o3Y_vT.js} +2 -2
- package/dist/cjs/{nv-row.entry-BMQvcqlU.js → nv-row.entry-Cop4QB1Y.js} +2 -2
- package/dist/cjs/nv-sidebar.entry-96HyTMt9.js +355 -0
- package/dist/cjs/{nv-sidebarcontent.entry-llnRwVuj.js → nv-sidebarcontent.entry-RCkZZp9I.js} +2 -2
- package/dist/cjs/{nv-sidebardivider.entry--rQv8d5T.js → nv-sidebardivider.entry-DY25WqI7.js} +2 -2
- package/dist/cjs/{nv-sidebarfooter.entry-C5R0sUI_.js → nv-sidebarfooter.entry-9BFpNPLP.js} +2 -2
- package/dist/cjs/{nv-sidebargroup.entry-DdrpLbU7.js → nv-sidebargroup.entry-Cj52DXba.js} +2 -2
- package/dist/cjs/{nv-sidebarheader.entry-HuBPIsyf.js → nv-sidebarheader.entry-_WZgNwoi.js} +2 -2
- package/dist/cjs/{nv-sidebarlogo.entry-TZNPoqnA.js → nv-sidebarlogo.entry-4Zy6k3V5.js} +2 -2
- package/dist/cjs/{nv-sidebarnavitem.entry-BWc3mF5I.js → nv-sidebarnavitem.entry-fQ9sqxDj.js} +3 -3
- package/dist/cjs/{nv-sidebarnavsubitem.entry-DekANwO8.js → nv-sidebarnavsubitem.entry-1iBobkME.js} +2 -2
- package/dist/cjs/{nv-split.entry-BOwOB8FW.js → nv-split.entry-Dfzpge0r.js} +2 -2
- package/dist/cjs/{nv-stack.entry-CaTiSLGN.js → nv-stack.entry-BnCput1S.js} +2 -2
- package/dist/cjs/nv-statusindicator.entry-ClPHcTkz.js +42 -0
- package/dist/cjs/{nv-table.entry-LFZaS0Dy.js → nv-table.entry-DsllD6Bz.js} +3 -3
- package/dist/cjs/{nv-tableheader.entry-CK50S8xW.js → nv-tableheader.entry-AWCKrpLj.js} +2 -2
- package/dist/cjs/nv-tag.entry-BwENpoSV.js +85 -0
- package/dist/cjs/{nv-timetest.entry-A9elKwkf.js → nv-timetest.entry-BQsV7Qb2.js} +2 -2
- package/dist/cjs/{nv-toggle.entry-BGu-6rEs.js → nv-toggle.entry-a0tSJ6GE.js} +3 -3
- package/dist/cjs/{nv-togglebutton.entry-BzAcBOgN.js → nv-togglebutton.entry-CT8fZr74.js} +2 -2
- package/dist/cjs/{nv-togglebuttongroup.entry-CIWp7IXc.js → nv-togglebuttongroup.entry-BN7WkQ_L.js} +2 -2
- package/dist/cjs/{nv-tooltip.entry-CoGkSHpv.js → nv-tooltip.entry-xpFqRgZM.js} +2 -2
- package/dist/components/NvDatatable/NvDatatable.js +176 -59
- package/dist/components/NvDatatable/expandState.js +8 -0
- package/dist/components/NvDatatable/expandState.test.js +41 -0
- package/dist/components/NvDatatable/paginationState.js +9 -0
- package/dist/components/NvDatatable/paginationState.test.js +84 -0
- package/dist/generated/components.js +20 -1
- package/dist/generated/components.server.js +31 -1
- package/dist/types/components/NvDatatable/NvDatatable.d.ts +1 -1
- package/dist/types/components/NvDatatable/expandState.d.ts +5 -0
- package/dist/types/components/NvDatatable/expandState.test.d.ts +1 -0
- package/dist/types/components/NvDatatable/paginationState.d.ts +9 -0
- package/dist/types/components/NvDatatable/paginationState.test.d.ts +1 -0
- package/dist/types/components/NvDatatable/types.d.ts +16 -1
- package/dist/types/generated/components.d.ts +12 -1
- package/dist/types/generated/components.server.d.ts +12 -1
- package/package.json +1 -1
- package/dist/cjs/index-DgKzi_Pd.js +0 -10208
- package/dist/cjs/nv-sidebar.entry-C4HTjJmz.js +0 -181
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
var
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
|
+
var constantsGOKBmbgZ = require('./constants-gOKBmbgZ-CSoZ8z-G.js');
|
|
5
5
|
var v4BdYh22OP = require('./v4-BdYh22OP-C1vaJ4yP.js');
|
|
6
6
|
require('@stencil/react-output-target/runtime');
|
|
7
7
|
require('react');
|
|
@@ -13,37 +13,37 @@ require('react-dom');
|
|
|
13
13
|
const FORMAT_CONFIGS = {
|
|
14
14
|
'HH': {
|
|
15
15
|
pattern: /^([0-1]?[0-9]|2[0-3])$/,
|
|
16
|
-
parts: [
|
|
16
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours],
|
|
17
17
|
defaultValue: '00',
|
|
18
18
|
maxLength: 2,
|
|
19
19
|
},
|
|
20
20
|
'HH:mm': {
|
|
21
21
|
pattern: /^([0-1]?[0-9]|2[0-3]):([0-5]?[0-9])$/,
|
|
22
|
-
parts: [
|
|
22
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours, constantsGOKBmbgZ.TimeType.Minutes],
|
|
23
23
|
defaultValue: '00:00',
|
|
24
24
|
maxLength: 5,
|
|
25
25
|
},
|
|
26
26
|
'HH:mm:ss': {
|
|
27
27
|
pattern: /^([0-1]?[0-9]|2[0-3]):([0-5]?[0-9]):([0-5]?[0-9])$/,
|
|
28
|
-
parts: [
|
|
28
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours, constantsGOKBmbgZ.TimeType.Minutes, constantsGOKBmbgZ.TimeType.Seconds],
|
|
29
29
|
defaultValue: '00:00:00',
|
|
30
30
|
maxLength: 8,
|
|
31
31
|
},
|
|
32
32
|
'hh': {
|
|
33
33
|
pattern: /^(0?[1-9]|1[0-2])$/,
|
|
34
|
-
parts: [
|
|
34
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours],
|
|
35
35
|
defaultValue: '01',
|
|
36
36
|
maxLength: 2,
|
|
37
37
|
},
|
|
38
38
|
'hh:mm': {
|
|
39
39
|
pattern: /^(0?[1-9]|1[0-2]):([0-5]?[0-9])$/,
|
|
40
|
-
parts: [
|
|
40
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours, constantsGOKBmbgZ.TimeType.Minutes],
|
|
41
41
|
defaultValue: '01:00',
|
|
42
42
|
maxLength: 5,
|
|
43
43
|
},
|
|
44
44
|
'hh:mm:ss': {
|
|
45
45
|
pattern: /^(0?[1-9]|1[0-2]):([0-5]?[0-9]):([0-5]?[0-9])$/,
|
|
46
|
-
parts: [
|
|
46
|
+
parts: [constantsGOKBmbgZ.TimeType.Hours, constantsGOKBmbgZ.TimeType.Minutes, constantsGOKBmbgZ.TimeType.Seconds],
|
|
47
47
|
defaultValue: '01:00:00',
|
|
48
48
|
maxLength: 8,
|
|
49
49
|
},
|
|
@@ -57,7 +57,7 @@ function getVisibleTimeTypes(format) {
|
|
|
57
57
|
const config = FORMAT_CONFIGS[format];
|
|
58
58
|
if (!config) {
|
|
59
59
|
// Fallback for unknown formats
|
|
60
|
-
return [
|
|
60
|
+
return [constantsGOKBmbgZ.TimeType.Hours, constantsGOKBmbgZ.TimeType.Minutes, constantsGOKBmbgZ.TimeType.Seconds];
|
|
61
61
|
}
|
|
62
62
|
return config.parts;
|
|
63
63
|
}
|
|
@@ -138,7 +138,7 @@ function parseValueByFormat(value, format) {
|
|
|
138
138
|
}
|
|
139
139
|
if (parts.length >= 2 &&
|
|
140
140
|
parts[1] &&
|
|
141
|
-
config.parts.includes(
|
|
141
|
+
config.parts.includes(constantsGOKBmbgZ.TimeType.Minutes)) {
|
|
142
142
|
const minutes = parseInt(parts[1], 10);
|
|
143
143
|
if (!isNaN(minutes) && minutes >= 0 && minutes <= 59) {
|
|
144
144
|
result.minutes = minutes.toString().padStart(2, '0');
|
|
@@ -146,7 +146,7 @@ function parseValueByFormat(value, format) {
|
|
|
146
146
|
}
|
|
147
147
|
if (parts.length >= 3 &&
|
|
148
148
|
parts[2] &&
|
|
149
|
-
config.parts.includes(
|
|
149
|
+
config.parts.includes(constantsGOKBmbgZ.TimeType.Seconds)) {
|
|
150
150
|
const seconds = parseInt(parts[2], 10);
|
|
151
151
|
if (!isNaN(seconds) && seconds >= 0 && seconds <= 59) {
|
|
152
152
|
result.seconds = seconds.toString().padStart(2, '0');
|
|
@@ -190,7 +190,7 @@ function extractRelevantComponents(components, format) {
|
|
|
190
190
|
minutes: '00',
|
|
191
191
|
seconds: '00',
|
|
192
192
|
};
|
|
193
|
-
if (config.parts.includes(
|
|
193
|
+
if (config.parts.includes(constantsGOKBmbgZ.TimeType.Hours)) {
|
|
194
194
|
// Validate hours for the target format
|
|
195
195
|
const hours = parseInt(components.hours, 10);
|
|
196
196
|
if (format.startsWith('hh')) {
|
|
@@ -208,10 +208,10 @@ function extractRelevantComponents(components, format) {
|
|
|
208
208
|
// If invalid, keep the default '00'
|
|
209
209
|
}
|
|
210
210
|
}
|
|
211
|
-
if (config.parts.includes(
|
|
211
|
+
if (config.parts.includes(constantsGOKBmbgZ.TimeType.Minutes)) {
|
|
212
212
|
result.minutes = components.minutes;
|
|
213
213
|
}
|
|
214
|
-
if (config.parts.includes(
|
|
214
|
+
if (config.parts.includes(constantsGOKBmbgZ.TimeType.Seconds)) {
|
|
215
215
|
result.seconds = components.seconds;
|
|
216
216
|
}
|
|
217
217
|
return result;
|
|
@@ -251,7 +251,7 @@ const NvFieldtime = class {
|
|
|
251
251
|
// Input elements for hours, minutes, and seconds
|
|
252
252
|
this.inputElements = {};
|
|
253
253
|
this.inputZeroAdded = {};
|
|
254
|
-
this.typeFocused =
|
|
254
|
+
this.typeFocused = constantsGOKBmbgZ.TimeType.Hours;
|
|
255
255
|
/****************************************************************************/
|
|
256
256
|
//#region STATES
|
|
257
257
|
this.hours = '00';
|
|
@@ -414,11 +414,11 @@ const NvFieldtime = class {
|
|
|
414
414
|
// React to external changes, e.g., highlight current time on open
|
|
415
415
|
if (newOpen) {
|
|
416
416
|
// Re-highlight columns based on current value
|
|
417
|
-
const hourSelector = `.time-column.time-column-${
|
|
417
|
+
const hourSelector = `.time-column.time-column-${constantsGOKBmbgZ.TimeType.Hours} div`;
|
|
418
418
|
this.updateColumnHighlight(hourSelector, this.hours);
|
|
419
|
-
const minutesSelector = `.time-column.time-column-${
|
|
419
|
+
const minutesSelector = `.time-column.time-column-${constantsGOKBmbgZ.TimeType.Minutes} div`;
|
|
420
420
|
this.updateColumnHighlight(minutesSelector, this.minutes);
|
|
421
|
-
const secondsSelector = `.time-column.time-column-${
|
|
421
|
+
const secondsSelector = `.time-column.time-column-${constantsGOKBmbgZ.TimeType.Seconds} div`;
|
|
422
422
|
this.updateColumnHighlight(secondsSelector, this.seconds);
|
|
423
423
|
}
|
|
424
424
|
}
|
|
@@ -454,13 +454,13 @@ const NvFieldtime = class {
|
|
|
454
454
|
}
|
|
455
455
|
// Update the time value based on the type
|
|
456
456
|
switch (type) {
|
|
457
|
-
case
|
|
457
|
+
case constantsGOKBmbgZ.TimeType.Hours:
|
|
458
458
|
this.handleHoursChange(inputValue, type);
|
|
459
459
|
break;
|
|
460
|
-
case
|
|
460
|
+
case constantsGOKBmbgZ.TimeType.Minutes:
|
|
461
461
|
this.handleMinutesChange(inputValue, type);
|
|
462
462
|
break;
|
|
463
|
-
case
|
|
463
|
+
case constantsGOKBmbgZ.TimeType.Seconds:
|
|
464
464
|
this.handleSecondsChange(inputValue, type);
|
|
465
465
|
break;
|
|
466
466
|
}
|
|
@@ -527,7 +527,7 @@ const NvFieldtime = class {
|
|
|
527
527
|
// Auto-navigation to next field when input is complete
|
|
528
528
|
if (this.hours.length >= 1 && !this.inputZeroAdded[type]) {
|
|
529
529
|
const visibleTypes = getVisibleTimeTypes(this.format);
|
|
530
|
-
const currentTypeIndex = visibleTypes.indexOf(
|
|
530
|
+
const currentTypeIndex = visibleTypes.indexOf(constantsGOKBmbgZ.TimeType.Hours);
|
|
531
531
|
const nextTypeIndex = currentTypeIndex + 1;
|
|
532
532
|
if (nextTypeIndex < visibleTypes.length) {
|
|
533
533
|
const nextType = visibleTypes[nextTypeIndex];
|
|
@@ -592,7 +592,7 @@ const NvFieldtime = class {
|
|
|
592
592
|
// Auto-navigation to next field when input is complete
|
|
593
593
|
if (this.minutes.length >= 1 && !this.inputZeroAdded[type]) {
|
|
594
594
|
const visibleTypes = getVisibleTimeTypes(this.format);
|
|
595
|
-
const currentTypeIndex = visibleTypes.indexOf(
|
|
595
|
+
const currentTypeIndex = visibleTypes.indexOf(constantsGOKBmbgZ.TimeType.Minutes);
|
|
596
596
|
const nextTypeIndex = currentTypeIndex + 1;
|
|
597
597
|
if (nextTypeIndex < visibleTypes.length) {
|
|
598
598
|
const nextType = visibleTypes[nextTypeIndex];
|
|
@@ -734,13 +734,13 @@ const NvFieldtime = class {
|
|
|
734
734
|
const option = parseInt(event.target.textContent || '0', 10);
|
|
735
735
|
// Update the time component directly without constraint validation
|
|
736
736
|
// Dropdown options are already filtered by constraints during generation
|
|
737
|
-
if (type ===
|
|
737
|
+
if (type === constantsGOKBmbgZ.TimeType.Hours) {
|
|
738
738
|
this.hours = option.toString().padStart(2, '0');
|
|
739
739
|
}
|
|
740
|
-
else if (type ===
|
|
740
|
+
else if (type === constantsGOKBmbgZ.TimeType.Minutes) {
|
|
741
741
|
this.minutes = option.toString().padStart(2, '0');
|
|
742
742
|
}
|
|
743
|
-
else if (type ===
|
|
743
|
+
else if (type === constantsGOKBmbgZ.TimeType.Seconds) {
|
|
744
744
|
this.seconds = option.toString().padStart(2, '0');
|
|
745
745
|
}
|
|
746
746
|
// Reconstruct time in the correct format and update value
|
|
@@ -793,11 +793,11 @@ const NvFieldtime = class {
|
|
|
793
793
|
}
|
|
794
794
|
// Generate the time options based on the type
|
|
795
795
|
switch (type) {
|
|
796
|
-
case
|
|
796
|
+
case constantsGOKBmbgZ.TimeType.Hours:
|
|
797
797
|
return this.generateHourOptions(stepInSeconds);
|
|
798
|
-
case
|
|
798
|
+
case constantsGOKBmbgZ.TimeType.Minutes:
|
|
799
799
|
return this.generateMinuteOptions(stepInSeconds);
|
|
800
|
-
case
|
|
800
|
+
case constantsGOKBmbgZ.TimeType.Seconds:
|
|
801
801
|
return this.generateSecondOptions(stepInSeconds);
|
|
802
802
|
default:
|
|
803
803
|
return [];
|
|
@@ -1047,11 +1047,11 @@ const NvFieldtime = class {
|
|
|
1047
1047
|
renderTimeInputField(type) {
|
|
1048
1048
|
const getValue = () => {
|
|
1049
1049
|
switch (type) {
|
|
1050
|
-
case
|
|
1050
|
+
case constantsGOKBmbgZ.TimeType.Hours:
|
|
1051
1051
|
return this.hours;
|
|
1052
|
-
case
|
|
1052
|
+
case constantsGOKBmbgZ.TimeType.Minutes:
|
|
1053
1053
|
return this.minutes;
|
|
1054
|
-
case
|
|
1054
|
+
case constantsGOKBmbgZ.TimeType.Seconds:
|
|
1055
1055
|
return this.seconds;
|
|
1056
1056
|
default:
|
|
1057
1057
|
return '00';
|
|
@@ -1059,11 +1059,11 @@ const NvFieldtime = class {
|
|
|
1059
1059
|
};
|
|
1060
1060
|
const getPlaceholder = () => {
|
|
1061
1061
|
switch (type) {
|
|
1062
|
-
case
|
|
1062
|
+
case constantsGOKBmbgZ.TimeType.Hours:
|
|
1063
1063
|
return this.format.includes('hh') ? 'hh' : 'HH';
|
|
1064
|
-
case
|
|
1064
|
+
case constantsGOKBmbgZ.TimeType.Minutes:
|
|
1065
1065
|
return 'mm';
|
|
1066
|
-
case
|
|
1066
|
+
case constantsGOKBmbgZ.TimeType.Seconds:
|
|
1067
1067
|
return 'ss';
|
|
1068
1068
|
default:
|
|
1069
1069
|
return '';
|
|
@@ -1071,11 +1071,11 @@ const NvFieldtime = class {
|
|
|
1071
1071
|
};
|
|
1072
1072
|
const getId = () => {
|
|
1073
1073
|
switch (type) {
|
|
1074
|
-
case
|
|
1074
|
+
case constantsGOKBmbgZ.TimeType.Hours:
|
|
1075
1075
|
return this.inputId;
|
|
1076
|
-
case
|
|
1076
|
+
case constantsGOKBmbgZ.TimeType.Minutes:
|
|
1077
1077
|
return `${this.inputId}-minutes`;
|
|
1078
|
-
case
|
|
1078
|
+
case constantsGOKBmbgZ.TimeType.Seconds:
|
|
1079
1079
|
return `${this.inputId}-seconds`;
|
|
1080
1080
|
default:
|
|
1081
1081
|
return this.inputId;
|
|
@@ -1101,15 +1101,15 @@ const NvFieldtime = class {
|
|
|
1101
1101
|
RenderTimeOptionsColumn(type) {
|
|
1102
1102
|
return (index.h("div", { class: `time-column time-column-${type}`, onScroll: e => this.handleScroll(e, type) }, this.generateInfiniteTimeOptions(type).map((option, index$1) => (index.h("div", { class: {
|
|
1103
1103
|
'time-option': true,
|
|
1104
|
-
'selected': (type ===
|
|
1105
|
-
(type ===
|
|
1106
|
-
(type ===
|
|
1104
|
+
'selected': (type === constantsGOKBmbgZ.TimeType.Hours && option === this.hours) ||
|
|
1105
|
+
(type === constantsGOKBmbgZ.TimeType.Minutes && option === this.minutes) ||
|
|
1106
|
+
(type === constantsGOKBmbgZ.TimeType.Seconds && option === this.seconds),
|
|
1107
1107
|
}, key: `${option}-${index$1}`, onClick: e => this.handleTimeOptionClick(e, type) }, option)))));
|
|
1108
1108
|
}
|
|
1109
1109
|
render() {
|
|
1110
|
-
return (index.h(index.Host, { key: '
|
|
1111
|
-
this.el.querySelector('[slot="description"]')) && (index.h("div", { key: '
|
|
1112
|
-
this.el.querySelector('[slot="error-description"]')) && (index.h("div", { key: '
|
|
1110
|
+
return (index.h(index.Host, { key: 'a032b1f8f529f78197c0c392a36a2a7a0e64da9a', onclick: (e) => this.handleHostClick(e), "aria-expanded": this.open ? 'true' : 'false' }, (this.label || this.el.querySelector('[slot="label"]')) && (index.h("label", { key: '2ad43d201ababc34f5f2e83f56e993b4f4308391', htmlFor: this.inputId }, index.h("slot", { key: '94c4ae7c844a21ca5f2eaa2944ae6fde8a743db1', name: "label" }, this.label))), index.h("nv-popover", { key: '2ffeb7b5cdd4bee7c16d749a8f9056aa0b3e0def', ref: el => (this.popoverElement = el), triggerMode: "controlled", placement: "bottom-start", open: this.open, onOpenChanged: this.handleOpenChanged }, index.h("div", { key: '493e8641008451f36d289e54061cfbf7041219a8', class: "input-wrapper", slot: "trigger" }, index.h("slot", { key: 'cc4dda576165ac75fa7c3e64c2688e74631adbe1', name: "before-input" }), index.h("div", { key: '589853e389e86ada62ee220bd7d383d53841a857', class: "input-container" }, index.h("slot", { key: 'a705e0d398d6a169ff98b04944baf0df13d02a3f', name: "leading-input" }), this.renderTimeInputFields(), index.h("nv-iconbutton", { key: 'a33b9ba6453d7649970040e690ee50bdfaa83ee3', name: 'clock', size: "md", emphasis: "lower", "aria-label": this.open ? 'Hide time picker' : 'Show time picker', onClick: () => this.HandleDropdownIconClick() }), this.error && (index.h("nv-icon", { key: '89890ac88e95199aedc13ea536843ba1c0e1cb18', name: "alert-circle", class: "validation", size: "sm" })), this.success && (index.h("nv-icon", { key: '2f020e2a5efb5ec37eecbe2629236fbbf4ca6ce8', name: "circle-check", class: "validation", size: "sm" }))), index.h("slot", { key: '2357690da2edc71f674f384b2d497155ef47984e', name: "after-input" })), index.h("div", { key: 'd13be0ad80be00d85b87eb7981e875d75a0e4862', class: "time-dropdown", slot: "content" }, index.h("div", { key: '1443d77eea765261a16bd3f838ed9f7126bf68a5', class: "time-columns" }, this.renderTimeDropdownColumns()))), (this.description ||
|
|
1111
|
+
this.el.querySelector('[slot="description"]')) && (index.h("div", { key: '4feca47ba72f1594a6a6c8246810620eda9d207b', class: "description" }, index.h("slot", { key: '43845e3b0f15f787ea69eb1a588e3bc6392449c1', name: "description" }, this.description))), (this.errorDescription ||
|
|
1112
|
+
this.el.querySelector('[slot="error-description"]')) && (index.h("div", { key: '539a080864dd94f4b7b1b1c2c16e813ca3d5e42d', hidden: !this.error, class: "error-description" }, index.h("slot", { key: '9c70b3af02a3e3a26b022d65cced0217d14c8812', name: "error-description" }, this.errorDescription)))));
|
|
1113
1113
|
}
|
|
1114
1114
|
static get formAssociated() { return true; }
|
|
1115
1115
|
get el() { return index.getElement(this); }
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
var clsxChV9xqsO = require('./clsx-ChV9xqsO-BtxeOLZW.js');
|
|
5
|
-
var
|
|
5
|
+
var constantsGOKBmbgZ = require('./constants-gOKBmbgZ-CSoZ8z-G.js');
|
|
6
6
|
require('@stencil/react-output-target/runtime');
|
|
7
7
|
require('react');
|
|
8
8
|
require('react-dom');
|
|
@@ -50,19 +50,19 @@ const NvIcon = class {
|
|
|
50
50
|
}
|
|
51
51
|
componentWillRender() {
|
|
52
52
|
if (this.xsmall) {
|
|
53
|
-
this.size =
|
|
53
|
+
this.size = constantsGOKBmbgZ.SemanticSizes.ExtraSmall;
|
|
54
54
|
}
|
|
55
55
|
if (this.small) {
|
|
56
|
-
this.size =
|
|
56
|
+
this.size = constantsGOKBmbgZ.SemanticSizes.Small;
|
|
57
57
|
}
|
|
58
58
|
if (this.medium) {
|
|
59
|
-
this.size =
|
|
59
|
+
this.size = constantsGOKBmbgZ.SemanticSizes.Medium;
|
|
60
60
|
}
|
|
61
61
|
if (this.large) {
|
|
62
|
-
this.size =
|
|
62
|
+
this.size = constantsGOKBmbgZ.SemanticSizes.Large;
|
|
63
63
|
}
|
|
64
64
|
if (this.xlarge) {
|
|
65
|
-
this.size =
|
|
65
|
+
this.size = constantsGOKBmbgZ.SemanticSizes.ExtraLarge;
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
68
|
componentWillLoad() {
|
|
@@ -72,7 +72,7 @@ const NvIcon = class {
|
|
|
72
72
|
/****************************************************************************/
|
|
73
73
|
//#region RENDER
|
|
74
74
|
render() {
|
|
75
|
-
return (index.h(index.Host, { key: '
|
|
75
|
+
return (index.h(index.Host, { key: '296afbaf68b6883a35fa67651ffef9052a604c51', class: clsxChV9xqsO.clsx(this.color && `${this.color}`), role: "img", "aria-label": `${this.name}-icon` }, index.h("svg", { key: '8d6977768135682a5c3777bacc55d5e0553211c1', stroke: "currentColor", width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", class: `nv-icon-${this.size}` }, index.h("use", { key: '91f29aae64f5f32ecc95382f0cdb8338112ee332', href: `#nvicon_${this.name}` }))));
|
|
76
76
|
}
|
|
77
77
|
};
|
|
78
78
|
NvIcon.style = nvIconCss();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
var clsxChV9xqsO = require('./clsx-ChV9xqsO-BtxeOLZW.js');
|
|
5
5
|
require('@stencil/react-output-target/runtime');
|
|
6
6
|
require('react');
|
|
@@ -128,7 +128,7 @@ const NvIconbutton = class {
|
|
|
128
128
|
/****************************************************************************/
|
|
129
129
|
//#region RENDER
|
|
130
130
|
render() {
|
|
131
|
-
return (index.h(index.Host, { key: '
|
|
131
|
+
return (index.h(index.Host, { key: '9b96d47b036561ab1458f193bf7a3b749e6189da', role: "button", type: this.type, tabindex: this.disableTabindex ? -1 : 0, disabled: this.disabled ? true : undefined, class: clsxChV9xqsO.clsx('root', `size-${this.size}`, `emphasis-${this.emphasis}`, this.loading && 'loading', `shape-${this.shape}`), onClick: this.handleClick }, this.loading && index.h("nv-loader", { key: 'cd55b87aae05c11cf9759421a2aa3c15fef8a19f', size: this.size }), !this.loading && index.h("nv-icon", { key: '1fb7bd007f0bde6693bc2241b4e3baa57e0a7fc0', name: this.name, size: this.size }), index.h("slot", { key: 'd2cc6d92bb9714d1b204e75c664b965d696a2fae' })));
|
|
132
132
|
}
|
|
133
133
|
static get formAssociated() { return true; }
|
|
134
134
|
get el() { return index.getElement(this); }
|
|
@@ -162,7 +162,7 @@ const NvLoader = class {
|
|
|
162
162
|
//#region RENDER
|
|
163
163
|
/* <slot> empty to force rendering change */
|
|
164
164
|
render() {
|
|
165
|
-
return (index.h(index.Host, { key: '
|
|
165
|
+
return (index.h(index.Host, { key: '8cac2279ffe58fe0243f638c9d55d2f0e5a8443a', class: clsxChV9xqsO.clsx(this.size && `size-${this.size}`, this.color && `color-${this.color}`) }));
|
|
166
166
|
}
|
|
167
167
|
};
|
|
168
168
|
NvLoader.style = nvLoaderCss();
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -192,7 +192,7 @@ const NvMenu = class {
|
|
|
192
192
|
this.triggerElement = this.el.querySelector('[slot="trigger"]');
|
|
193
193
|
}
|
|
194
194
|
render() {
|
|
195
|
-
return (index.h(index.Host, { key: '
|
|
195
|
+
return (index.h(index.Host, { key: 'efaa7d9242c23b27395dc1584ea05300ce3142d8' }, index.h("slot", { key: '42be7569ce9b393f2f22daabbe4f7594e3e48a7a', name: "trigger" }), index.h("nv-popover", { key: '55a12dabf7230a3fbb5e1811b4d211a4c9c7514a', ref: el => (this.popoverElement = el), triggerMode: "click", triggerElement: this.triggerElement, placement: this.placement, nested: this.nested, open: this.open, onOpenChanged: this.handleOpenChanged.bind(this) }, this.items ? (index.h("ul", { slot: "content" }, this.renderMenuItems())) : (index.h("slot", { name: "content" })))));
|
|
196
196
|
}
|
|
197
197
|
get el() { return index.getElement(this); }
|
|
198
198
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -50,7 +50,7 @@ const NvMenuitem = class {
|
|
|
50
50
|
/****************************************************************************/
|
|
51
51
|
//#region RENDER
|
|
52
52
|
render() {
|
|
53
|
-
return (index.h(index.Host, { key: '
|
|
53
|
+
return (index.h(index.Host, { key: '052f7822782c1a50cfc207dc6c7090e9ae7ddb23', role: "menuitem", tabindex: this.disabled ? '-1' : '0' }, this.icon && index.h("nv-icon", { key: 'b6fb4a24573d6ce2a65d1fbec49f25084aca4efc', name: this.icon }), index.h("slot", { key: 'dd4b413f909db1b13a642411532b4980fe495bcf' }), this.label && index.h("span", { key: '06e14c729b5d1a8c7fb58797fcf345eb15d02be4', "data-scope": "text" }, this.label), this.shortcut && !this.hasSubmenu && index.h("kbd", { key: '53802fa02a1c643b8f04ec71365115c469016e65' }, this.shortcut), this.hasSubmenu && index.h("nv-icon", { key: 'ef8e14ab9147ef7cba4e160a053e4900aac9a927', name: "chevron-right" })));
|
|
54
54
|
}
|
|
55
55
|
get el() { return index.getElement(this); }
|
|
56
56
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
var
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
|
+
var constantsGOKBmbgZ = require('./constants-gOKBmbgZ-CSoZ8z-G.js');
|
|
5
5
|
var collapse_animationDZDm0vSK = require('./collapse.animation-DZDm0vSK-C2TOIhIK.js');
|
|
6
6
|
var fade_animationDcRL9lcm = require('./fade.animation-DcRL9lcm-DAZeHoKN.js');
|
|
7
7
|
require('./style-value-types.es-xlgmw4x8-B1vLqX9m.js');
|
|
@@ -53,18 +53,18 @@ const NvNotification = class {
|
|
|
53
53
|
/****************************************************************************/
|
|
54
54
|
//#region INTERNAL
|
|
55
55
|
this.iconByFeedback = {
|
|
56
|
-
[
|
|
57
|
-
[
|
|
58
|
-
[
|
|
59
|
-
[
|
|
60
|
-
[
|
|
56
|
+
[constantsGOKBmbgZ.FeedbackColors.Warning]: 'alert-circle',
|
|
57
|
+
[constantsGOKBmbgZ.FeedbackColors.Information]: 'info-circle',
|
|
58
|
+
[constantsGOKBmbgZ.FeedbackColors.Success]: 'circle-check',
|
|
59
|
+
[constantsGOKBmbgZ.FeedbackColors.Error]: 'alert-triangle',
|
|
60
|
+
[constantsGOKBmbgZ.FeedbackColors.Neutral]: 'help',
|
|
61
61
|
};
|
|
62
62
|
this.roleByFeedback = {
|
|
63
|
-
[
|
|
64
|
-
[
|
|
65
|
-
[
|
|
66
|
-
[
|
|
67
|
-
[
|
|
63
|
+
[constantsGOKBmbgZ.FeedbackColors.Error]: 'alert',
|
|
64
|
+
[constantsGOKBmbgZ.FeedbackColors.Warning]: 'alert',
|
|
65
|
+
[constantsGOKBmbgZ.FeedbackColors.Information]: 'status',
|
|
66
|
+
[constantsGOKBmbgZ.FeedbackColors.Success]: 'status',
|
|
67
|
+
[constantsGOKBmbgZ.FeedbackColors.Neutral]: 'status',
|
|
68
68
|
};
|
|
69
69
|
}
|
|
70
70
|
//#endregion PROPERTIES
|
|
@@ -118,15 +118,15 @@ const NvNotification = class {
|
|
|
118
118
|
}
|
|
119
119
|
getSlideDestination(pos) {
|
|
120
120
|
switch (pos) {
|
|
121
|
-
case
|
|
122
|
-
case
|
|
121
|
+
case constantsGOKBmbgZ.NotificationPosition.TopRight:
|
|
122
|
+
case constantsGOKBmbgZ.NotificationPosition.BottomRight:
|
|
123
123
|
return { axis: 'x', to: 100 }; // right
|
|
124
|
-
case
|
|
125
|
-
case
|
|
124
|
+
case constantsGOKBmbgZ.NotificationPosition.TopLeft:
|
|
125
|
+
case constantsGOKBmbgZ.NotificationPosition.BottomLeft:
|
|
126
126
|
return { axis: 'x', to: -100 }; // left
|
|
127
|
-
case
|
|
127
|
+
case constantsGOKBmbgZ.NotificationPosition.TopCenter:
|
|
128
128
|
return { axis: 'y', to: -100 }; // up
|
|
129
|
-
case
|
|
129
|
+
case constantsGOKBmbgZ.NotificationPosition.BottomCenter:
|
|
130
130
|
return { axis: 'y', to: 100 }; // down
|
|
131
131
|
default:
|
|
132
132
|
return { axis: 'x', to: 100 }; // fallback
|
|
@@ -167,7 +167,7 @@ const NvNotification = class {
|
|
|
167
167
|
/****************************************************************************/
|
|
168
168
|
//#region RENDER
|
|
169
169
|
render() {
|
|
170
|
-
return (index.h(index.Host, { key: '
|
|
170
|
+
return (index.h(index.Host, { key: '32af1308aa22ce8228416fcce23ce5b75111895b', role: this.getAriaRole(), "aria-live": this.getAriaLive(), "aria-atomic": true, "aria-labelledby": this.getHeadingId() ?? null, "aria-describedby": this.getMessageId() ?? null, tabindex: "-1" }, index.h("div", { key: 'e63deeef95ae6c0e3fe1d8ce178c5dbe9d82f88c', "data-scope": "container", ref: el => (this.container = el) }, this.dismissible && (index.h("button", { key: '1b66875001f685293d83bbe90a85b297b335c024', "data-scope": "dismiss", type: "button", onClick: this.dismiss.bind(this) }, index.h("nv-icon", { key: 'b1be8798751f60f41925ea92e40df697eb15fa42', name: "x", size: "sm" }))), index.h("nv-icon", { key: 'a922d93bddb729fa7674199d438833544d48da2e', name: this.icon ?? this.getDefaultIcon(), size: "md", "data-scope": "icon" }), index.h("div", { key: 'a55e449e8e17560a70d3d40ff3b9e7e2855fbbac', "data-scope": "content" }, (this.heading || this.headingSlot) && (index.h("p", { key: 'd4c7b85c8b9c5c488b86ba4c8f0c456b8ea3ca2d', id: this.getHeadingId(), "data-scope": "heading" }, index.h("slot", { key: 'e1ef0d24ae77ee788c63d66bed7fee308f3f9d13', name: "heading" }, this.heading))), (this.message || this.messageSlot) && (index.h("p", { key: 'cd7d469058230fec03311e485da0360766633dd0', id: this.getMessageId(), "data-scope": "message" }, index.h("slot", { key: 'cd5000e571c1a7b19bbb0f59e58e938ee4e51361', name: "content" }, this.message))), this.actionsSlot && (index.h("div", { key: 'b0a19b512cc2fbce22907ac28828429202378e75', "data-scope": "actions" }, index.h("slot", { key: 'd40e04eb94154b319c8e212c76f1d932942137d0', name: "actions" })))))));
|
|
171
171
|
}
|
|
172
172
|
get el() { return index.getElement(this); }
|
|
173
173
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -21,7 +21,7 @@ const NvNotificationContainer = class {
|
|
|
21
21
|
/****************************************************************************/
|
|
22
22
|
//#region RENDER
|
|
23
23
|
render() {
|
|
24
|
-
return (index.h(index.Host, { key: '
|
|
24
|
+
return (index.h(index.Host, { key: '3618bd72eb82ee09c8c971d83ea3e0dbb58f6fbf', class: `position-${this.position}` }, index.h("slot", { key: 'ed0d1b37dd23e984365a92d45c6ecae31a5bbac9' })));
|
|
25
25
|
}
|
|
26
26
|
};
|
|
27
27
|
NvNotificationContainer.style = nvNotificationcontainerCss();
|
package/dist/cjs/{nv-pagination-nav.entry-uY1nT9aT.js → nv-pagination-nav.entry-DbzEBjoa.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -180,7 +180,7 @@ const NvPaginationNav = class {
|
|
|
180
180
|
render() {
|
|
181
181
|
const isFirstPage = this.currentPage === 1;
|
|
182
182
|
const isLastPage = this.currentPage === this.totalPages;
|
|
183
|
-
return (index.h(index.Host, { key: '
|
|
183
|
+
return (index.h(index.Host, { key: '2aecff38a5777b1e229b04110e774d4ac708e940' }, index.h("nav", { key: 'a470aab7d30178269f25eb794b447b6478ed274d', "data-scope": "pagination-nav", "aria-label": "Pagination navigation" }, this.isOnlyIcon ? (index.h("nv-iconbutton", { name: "chevron-left", size: "md", emphasis: "lower", disabled: isFirstPage, onClick: () => this.handlePageChange(this.currentPage - 1), "data-scope": "previous-iconbutton", "aria-label": this.previousButtonLabel })) : (index.h("nv-button", { size: "md", emphasis: "lower", disabled: isFirstPage, onClick: () => this.handlePageChange(this.currentPage - 1), "data-scope": "previous-button" }, index.h("nv-icon", { slot: "leading-icon", name: "chevron-left" }), this.previousButtonLabel)), index.h("ol", { key: '4ea58c4f536310c0d60354da84d9fd650a16dc67', "data-scope": "page-list" }, calculatePaginationRange({
|
|
184
184
|
currentPage: this.currentPage,
|
|
185
185
|
totalCount: this.totalCount,
|
|
186
186
|
pageSize: this.pageSize,
|
package/dist/cjs/{nv-paginationtable.entry-mr5KYXVC.js → nv-paginationtable.entry-DRGsk0DH.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -40,6 +40,19 @@ function interpolate(template, values, fallback) {
|
|
|
40
40
|
function isFirstPage(pageIndex) {
|
|
41
41
|
return pageIndex === 0;
|
|
42
42
|
}
|
|
43
|
+
/**
|
|
44
|
+
* Returns the 1-based page number to show in the page label.
|
|
45
|
+
* When there are no pages (empty/filtered-to-zero dataset), returns 0 so
|
|
46
|
+
* the label reads e.g. "Page 0 of 0" instead of "Page 1 of 0".
|
|
47
|
+
* @param {number} pageIndex - Current page index (zero-based)
|
|
48
|
+
* @param {number} pageCount - Total number of pages
|
|
49
|
+
* @returns {number} The page number to display (1-based, or 0 when no pages)
|
|
50
|
+
*/
|
|
51
|
+
function getDisplayPageNumber(pageIndex, pageCount) {
|
|
52
|
+
if (pageCount <= 0)
|
|
53
|
+
return 0;
|
|
54
|
+
return pageIndex + 1;
|
|
55
|
+
}
|
|
43
56
|
/**
|
|
44
57
|
* Checks if navigation to the last/next page is possible
|
|
45
58
|
* @param {number} pageIndex - Current page index (zero-based)
|
|
@@ -212,10 +225,13 @@ const NvPaginationtable = class {
|
|
|
212
225
|
const atFirstPage = isFirstPage(this.pageIndex);
|
|
213
226
|
const atLastPage = isLastPage(this.pageIndex, this.pageCount);
|
|
214
227
|
// Use fallback values to handle undefined props (can happen when frameworks pass undefined explicitly)
|
|
215
|
-
const pageLabel = interpolate(this.labelPage, {
|
|
228
|
+
const pageLabel = interpolate(this.labelPage, {
|
|
229
|
+
pageIndex: getDisplayPageNumber(this.pageIndex, this.pageCount),
|
|
230
|
+
pageCount: this.pageCount,
|
|
231
|
+
}, 'Page {pageIndex} of {pageCount}');
|
|
216
232
|
const totalLabel = interpolate(this.labelTotal, { rowCount: this.rowCount }, 'Total: {rowCount} rows');
|
|
217
233
|
const pageSizeOptions = generatePageSizeOptions(this.labelPageSizeOption ?? '{pageSize} per page');
|
|
218
|
-
return (index.h(index.Host, { key: '
|
|
234
|
+
return (index.h(index.Host, { key: '5f0e4d93600b77cf9b54b99a1ccffb1048c389fe', role: "navigation", "aria-label": "Pagination" }, !this.hideControls && (index.h("div", { key: '5226510a0d4cabba98d7aafaa7e3cd7d413b2d8a', "data-scope": "controls" }, !this.hideFirstLast && (index.h("nv-iconbutton", { key: 'bdcb8d93cdf24821ab5cdedc0413a77f163e19a1', name: "chevrons-left", emphasis: "lower", size: "sm", disabled: atFirstPage, onClick: () => this.firstPage() })), !this.hidePrevNext && (index.h("nv-iconbutton", { key: '822cfe5bd177ebbdce436f0f850fad9a86aae1c5', name: "chevron-left", emphasis: "lower", size: "sm", disabled: atFirstPage, onClick: () => this.previousPage() })), !this.hidePrevNext && (index.h("nv-iconbutton", { key: 'fd0aa10dee6b72d816b6801c03e5be7fb9a3698d', name: "chevron-right", emphasis: "lower", size: "sm", disabled: atLastPage, onClick: () => this.nextPage() })), !this.hideFirstLast && (index.h("nv-iconbutton", { key: 'a5b8fa71a51d0157dc37b908f972c0d830b44b00', name: "chevrons-right", emphasis: "lower", size: "sm", disabled: atLastPage, onClick: () => this.lastPage() })))), index.h("span", { key: '0b09d7507a9d1f3dbabbb37265d6949243290b1b', "data-scope": "page-label" }, pageLabel), index.h("span", { key: '275c4a1ca625a0afc68bfff46fc3e2872e0f76c3', "data-scope": "total" }, totalLabel), index.h("div", { key: '8a329ccc7baaac9f580aed7d2a53ed7f940c123a', "data-scope": "per-page" }, index.h("nv-fieldselect", { key: '83c644de7d30e63e0a96ccccaefb311acdd7617c', value: String(this.pageSize), onValueChanged: this.handlePageSizeChange, options: pageSizeOptions })), index.h("slot", { key: '190b8c8587c25ca449339a6ea1bbd85bed06d35f' })));
|
|
219
235
|
}
|
|
220
236
|
static get watchers() { return {
|
|
221
237
|
"pageIndex": [{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
var fade_animationDcRL9lcm = require('./fade.animation-DcRL9lcm-DAZeHoKN.js');
|
|
5
5
|
var grow_animationD7ep_aVl = require('./grow.animation-D7ep_aVl-BuXEDSK-.js');
|
|
6
6
|
require('./style-value-types.es-xlgmw4x8-B1vLqX9m.js');
|
|
@@ -1962,7 +1962,7 @@ const NvPopover = class {
|
|
|
1962
1962
|
/****************************************************************************/
|
|
1963
1963
|
//#region RENDER
|
|
1964
1964
|
render() {
|
|
1965
|
-
return (index.h(index.Host, { key: '
|
|
1965
|
+
return (index.h(index.Host, { key: '01b6cff8203a7e1ffe5b05aeea7f8e35238ac9bb' }, index.h("slot", { key: '63264f349fbc817a8b4efe7272715942fc307863', name: "trigger" }), index.h("div", { key: '0a251a4447bbe7481a71465ac2402aeb156ba537', "data-scope": "popover", "data-strategy": this.strategy, hidden: true, ref: el => (this.popoverElement = el) }, this.hasArrow && (index.h("div", { key: 'c958f8cd4c8f19d4ac7e8779cb4555a5b9dbfc01', "data-scope": "arrow", ref: el => (this.arrowElement = el) })), index.h("slot", { key: '72d516982d54945924c88372a54d19ba568a4e4a', name: "content" }))));
|
|
1966
1966
|
}
|
|
1967
1967
|
get el() { return index.getElement(this); }
|
|
1968
1968
|
static get watchers() { return {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
3
|
+
var index = require('./index-DXwd3F_r.js');
|
|
4
4
|
require('@stencil/react-output-target/runtime');
|
|
5
5
|
require('react');
|
|
6
6
|
require('react-dom');
|
|
@@ -14,7 +14,7 @@ const NvRow = class {
|
|
|
14
14
|
/****************************************************************************/
|
|
15
15
|
//#region RENDER
|
|
16
16
|
render() {
|
|
17
|
-
return (index.h(index.Host, { key: '
|
|
17
|
+
return (index.h(index.Host, { key: '6363fba1008818b66f1eeb4ade8949f56c7c23b0' }, index.h("slot", { key: '2a2399121ac20fb577a29c93ba764f196352a9b8' })));
|
|
18
18
|
}
|
|
19
19
|
};
|
|
20
20
|
NvRow.style = nvRowCss();
|