namirasoft-site-react 1.4.133 → 1.4.134
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/.dockerignore +86 -86
- package/.env.template +10 -10
- package/Dockerfile +18 -18
- package/config-overrides.js +72 -72
- package/dist/App.d.ts +0 -6
- package/dist/App.js +44 -174
- package/dist/App.js.map +1 -1
- package/dist/Validator.d.ts +2 -1
- package/dist/Validator.js +16 -8
- package/dist/Validator.js.map +1 -1
- package/dist/components/NSBarAction.d.ts +4 -4
- package/dist/components/NSBarAction.js +3 -3
- package/dist/components/NSBarAction.js.map +1 -1
- package/dist/components/NSBarAction.module.css +97 -97
- package/dist/components/NSBarAlert.d.ts +5 -5
- package/dist/components/NSBarAlert.js +1 -1
- package/dist/components/NSBarAlert.js.map +1 -1
- package/dist/components/NSBarAlert.module.css +69 -69
- package/dist/components/NSBarNotification.d.ts +3 -3
- package/dist/components/NSBarNotification.js +1 -1
- package/dist/components/NSBarNotification.js.map +1 -1
- package/dist/components/NSBarNotification.module.css +34 -34
- package/dist/components/NSBarTitle.d.ts +2 -2
- package/dist/components/NSBarTitle.js.map +1 -1
- package/dist/components/NSBarTitle.module.css +9 -9
- package/dist/components/NSBox.module.css +50 -126
- package/dist/components/NSBoxBaseCombo.d.ts +58 -0
- package/dist/components/NSBoxBaseCombo.js +163 -0
- package/dist/components/NSBoxBaseCombo.js.map +1 -0
- package/dist/components/{NSBoxCombo.module.css → NSBoxBaseCombo.module.css} +6 -6
- package/dist/components/NSBoxBoolean.d.ts +5 -6
- package/dist/components/NSBoxBoolean.js +6 -3
- package/dist/components/NSBoxBoolean.js.map +1 -1
- package/dist/components/NSBoxBoolean.module.css +67 -88
- package/dist/components/NSBoxCombo.d.ts +6 -25
- package/dist/components/NSBoxCombo.js +31 -61
- package/dist/components/NSBoxCombo.js.map +1 -1
- package/dist/components/NSBoxDate.d.ts +5 -4
- package/dist/components/NSBoxDate.js +11 -4
- package/dist/components/NSBoxDate.js.map +1 -1
- package/dist/components/NSBoxDate.module.css +4 -56
- package/dist/components/NSBoxDateTime.d.ts +5 -4
- package/dist/components/NSBoxDateTime.js +11 -5
- package/dist/components/NSBoxDateTime.js.map +1 -1
- package/dist/components/NSBoxDateTime.module.css +4 -51
- package/dist/components/NSBoxDouble.d.ts +4 -4
- package/dist/components/NSBoxDouble.js +9 -4
- package/dist/components/NSBoxDouble.js.map +1 -1
- package/dist/components/NSBoxDuration.d.ts +5 -4
- package/dist/components/NSBoxDuration.js +11 -4
- package/dist/components/NSBoxDuration.js.map +1 -1
- package/dist/components/NSBoxDuration.module.css +5 -0
- package/dist/components/NSBoxEmail.d.ts +6 -7
- package/dist/components/NSBoxEmail.js +18 -11
- package/dist/components/NSBoxEmail.js.map +1 -1
- package/dist/components/NSBoxEntity.d.ts +10 -44
- package/dist/components/NSBoxEntity.js +19 -92
- package/dist/components/NSBoxEntity.js.map +1 -1
- package/dist/components/NSBoxEnum.d.ts +12 -9
- package/dist/components/NSBoxEnum.js +29 -20
- package/dist/components/NSBoxEnum.js.map +1 -1
- package/dist/components/NSBoxFile.d.ts +9 -14
- package/dist/components/NSBoxFile.js +33 -47
- package/dist/components/NSBoxFile.js.map +1 -1
- package/dist/components/NSBoxFile.module.css +10 -4
- package/dist/components/NSBoxIPV4.d.ts +4 -4
- package/dist/components/NSBoxIPV4.js +12 -6
- package/dist/components/NSBoxIPV4.js.map +1 -1
- package/dist/components/NSBoxIPV6.d.ts +4 -4
- package/dist/components/NSBoxIPV6.js +11 -6
- package/dist/components/NSBoxIPV6.js.map +1 -1
- package/dist/components/NSBoxInteger.d.ts +4 -4
- package/dist/components/NSBoxInteger.js +9 -4
- package/dist/components/NSBoxInteger.js.map +1 -1
- package/dist/components/{NSBoxPrice.d.ts → NSBoxMoney.d.ts} +7 -7
- package/dist/components/NSBoxMoney.js +50 -0
- package/dist/components/NSBoxMoney.js.map +1 -0
- package/dist/components/NSBoxPassword.d.ts +5 -4
- package/dist/components/NSBoxPassword.js +18 -5
- package/dist/components/NSBoxPassword.js.map +1 -1
- package/dist/components/NSBoxPhone.d.ts +7 -8
- package/dist/components/NSBoxPhone.js +30 -20
- package/dist/components/NSBoxPhone.js.map +1 -1
- package/dist/components/NSBoxPhone.module.css +36 -0
- package/dist/components/NSBoxRadio.d.ts +5 -6
- package/dist/components/NSBoxRadio.js +3 -3
- package/dist/components/NSBoxRadio.js.map +1 -1
- package/dist/components/NSBoxRadio.module.css +69 -70
- package/dist/components/NSBoxSearch.d.ts +4 -6
- package/dist/components/NSBoxSearch.js +9 -14
- package/dist/components/NSBoxSearch.js.map +1 -1
- package/dist/components/NSBoxString.d.ts +4 -6
- package/dist/components/NSBoxString.js +10 -10
- package/dist/components/NSBoxString.js.map +1 -1
- package/dist/components/NSBoxTextArea.d.ts +4 -6
- package/dist/components/NSBoxTextArea.js +9 -12
- package/dist/components/NSBoxTextArea.js.map +1 -1
- package/dist/components/NSBoxTextArea.module.css +45 -83
- package/dist/components/NSBoxTime.d.ts +5 -4
- package/dist/components/NSBoxTime.js +11 -4
- package/dist/components/NSBoxTime.js.map +1 -1
- package/dist/components/NSBoxTime.module.css +5 -0
- package/dist/components/NSButton.d.ts +2 -2
- package/dist/components/NSButton.js.map +1 -1
- package/dist/components/NSButton.module.css +42 -42
- package/dist/components/NSButtonBlue.d.ts +2 -2
- package/dist/components/NSButtonBlue.js.map +1 -1
- package/dist/components/NSButtonBlue.module.css +4 -4
- package/dist/components/NSButtonGreen.d.ts +2 -2
- package/dist/components/NSButtonGreen.js.map +1 -1
- package/dist/components/NSButtonGreen.module.css +4 -4
- package/dist/components/NSButtonRed.d.ts +2 -2
- package/dist/components/NSButtonRed.js.map +1 -1
- package/dist/components/NSButtonRed.module.css +4 -4
- package/dist/components/NSCard.d.ts +2 -2
- package/dist/components/NSCard.js.map +1 -1
- package/dist/components/NSCard.module.css +114 -114
- package/dist/components/NSCardScreenshot.module.css +41 -41
- package/dist/components/NSChartColumn.module.css +7 -7
- package/dist/components/NSChartRange.d.ts +2 -2
- package/dist/components/NSChartRange.js.map +1 -1
- package/dist/components/NSChartTable.module.css +21 -21
- package/dist/components/NSCopyBox.d.ts +7 -0
- package/dist/components/{NSBoxCopy.js → NSCopyBox.js} +3 -3
- package/dist/components/{NSBoxCopy.js.map → NSCopyBox.js.map} +1 -1
- package/{src/components/NSBoxCopy.module.css → dist/components/NSCopyBox.module.css} +43 -43
- package/dist/components/NSDialog.module.css +106 -106
- package/dist/components/NSDialogDelete.d.ts +6 -0
- package/dist/components/{NSDeleteDialog.js → NSDialogDelete.js} +4 -4
- package/dist/components/NSDialogDelete.js.map +1 -0
- package/dist/components/{NSInfoDialog.d.ts → NSDialogInfo.d.ts} +2 -2
- package/dist/components/{NSInfoDialog.js → NSDialogInfo.js} +2 -2
- package/dist/components/{NSInfoDialog.js.map → NSDialogInfo.js.map} +1 -1
- package/dist/components/{NSPageSelectionModal.d.ts → NSDialogPageSelection.d.ts} +4 -4
- package/dist/components/{NSPageSelectionModal.js → NSDialogPageSelection.js} +4 -4
- package/dist/components/NSDialogPageSelection.js.map +1 -0
- package/dist/components/{NSPageSelectionModal.module.css → NSDialogPageSelection.module.css} +103 -103
- package/dist/components/NSDownTimer.module.css +55 -55
- package/dist/components/NSDownload.js.map +1 -1
- package/dist/components/NSDownload.module.css +46 -46
- package/dist/components/NSElectronicCard.d.ts +2 -2
- package/dist/components/NSElectronicCard.js.map +1 -1
- package/dist/components/NSElectronicCard.module.css +60 -60
- package/dist/components/NSEntityCardBackground.d.ts +2 -2
- package/dist/components/NSEntityCardBackground.js.map +1 -1
- package/dist/components/NSEntityCardBackground.module.css +27 -27
- package/dist/components/NSFilterBox.d.ts +13 -13
- package/dist/components/NSFilterBox.js +4 -4
- package/dist/components/NSFilterBox.js.map +1 -1
- package/dist/components/NSFilterBox.module.css +62 -62
- package/dist/components/NSFilterBoxDialog.js +1 -1
- package/dist/components/NSFilterBoxDialog.js.map +1 -1
- package/dist/components/NSFilterBoxDialog.module.css +36 -36
- package/dist/components/NSFilterItem.module.css +23 -23
- package/dist/components/NSFooter.d.ts +3 -3
- package/dist/components/NSFooter.js +4 -4
- package/dist/components/NSFooter.js.map +1 -1
- package/dist/components/NSFooter.module.css +123 -123
- package/dist/components/NSHeader.d.ts +3 -3
- package/dist/components/NSHeader.js +3 -3
- package/dist/components/NSHeader.js.map +1 -1
- package/dist/components/NSHeader.module.css +291 -291
- package/dist/components/NSHeaderScreenshot.d.ts +2 -2
- package/dist/components/NSHeaderScreenshot.js.map +1 -1
- package/dist/components/NSHeaderScreenshot.module.css +35 -35
- package/dist/components/{NSBoxLabel.d.ts → NSLabel.d.ts} +3 -3
- package/dist/components/NSLabel.js +11 -0
- package/dist/components/NSLabel.js.map +1 -0
- package/{src/components/NSBoxLabel.module.css → dist/components/NSLabel.module.css} +15 -14
- package/dist/components/NSLabelErrorNotifier.d.ts +6 -0
- package/dist/components/{NSBoxErrorNotifier.js → NSLabelErrorNotifier.js} +3 -3
- package/dist/components/NSLabelErrorNotifier.js.map +1 -0
- package/dist/components/{NSBoxErrorNotifier.module.css → NSLabelErrorNotifier.module.css} +2 -2
- package/dist/components/NSLayout.d.ts +10 -12
- package/dist/components/NSLayout.js +2 -4
- package/dist/components/NSLayout.js.map +1 -1
- package/dist/components/NSLayout.module.css +13 -13
- package/dist/components/NSLine.module.css +12 -12
- package/dist/components/NSLink.d.ts +2 -2
- package/dist/components/NSLink.js.map +1 -1
- package/dist/components/NSLink.module.css +36 -36
- package/dist/components/NSLinkBlue.d.ts +2 -2
- package/dist/components/NSLinkBlue.js.map +1 -1
- package/dist/components/NSLinkGreen.d.ts +2 -2
- package/dist/components/NSLinkGreen.js.map +1 -1
- package/dist/components/NSLinkRed.d.ts +2 -2
- package/dist/components/NSLinkRed.js.map +1 -1
- package/dist/components/{NSGroupedList.d.ts → NSListGrouped.d.ts} +8 -8
- package/dist/components/NSListGrouped.js +40 -0
- package/dist/components/{NSGroupedList.js.map → NSListGrouped.js.map} +1 -1
- package/dist/components/{NSGroupedList.module.css → NSListGrouped.module.css} +72 -72
- package/dist/components/{NSProductList.d.ts → NSListProduct.d.ts} +2 -2
- package/dist/components/{NSProductList.js → NSListProduct.js} +2 -2
- package/dist/components/{NSProductList.js.map → NSListProduct.js.map} +1 -1
- package/dist/components/NSLoading.d.ts +2 -2
- package/dist/components/NSLoading.js.map +1 -1
- package/dist/components/NSLoading.module.css +30 -30
- package/dist/components/{NSActionMenu.d.ts → NSMenuAction.d.ts} +4 -4
- package/dist/components/{NSActionMenu.js → NSMenuAction.js} +5 -5
- package/dist/components/{NSActionMenu.js.map → NSMenuAction.js.map} +1 -1
- package/{src/components/NSActionMenu.module.css → dist/components/NSMenuAction.module.css} +100 -101
- package/dist/components/NSMenuButton.d.ts +18 -0
- package/dist/components/NSMenuButton.js +42 -0
- package/dist/components/NSMenuButton.js.map +1 -0
- package/{src/components/NSAssistantButton.module.css → dist/components/NSMenuButton.module.css} +124 -135
- package/dist/components/NSNoData.d.ts +2 -2
- package/dist/components/NSNoData.js.map +1 -1
- package/dist/components/NSNoData.module.css +9 -9
- package/dist/components/NSPagination.d.ts +4 -4
- package/dist/components/NSPagination.js +2 -2
- package/dist/components/NSPagination.js.map +1 -1
- package/dist/components/NSPagination.module.css +110 -110
- package/dist/components/NSPanel.module.css +46 -46
- package/dist/components/{NSAccordion.d.ts → NSPanelAccordion.d.ts} +2 -2
- package/dist/components/{NSAccordion.js → NSPanelAccordion.js} +5 -5
- package/dist/components/NSPanelAccordion.js.map +1 -0
- package/dist/components/{NSAccordion.module.css → NSPanelAccordion.module.css} +4 -4
- package/dist/components/NSRange.d.ts +2 -2
- package/dist/components/NSRange.js.map +1 -1
- package/dist/components/NSRange.module.css +66 -66
- package/dist/components/NSSection.d.ts +2 -2
- package/dist/components/NSSection.js.map +1 -1
- package/dist/components/NSSection.module.css +10 -10
- package/dist/components/NSSectionCards.d.ts +4 -4
- package/dist/components/NSSectionCards.js.map +1 -1
- package/dist/components/NSSectionCards.module.css +38 -38
- package/dist/components/NSSectionTiles.d.ts +7 -0
- package/dist/components/NSSectionTiles.js +10 -0
- package/dist/components/NSSectionTiles.js.map +1 -0
- package/dist/components/{NSSectionBars.module.css → NSSectionTiles.module.css} +10 -10
- package/dist/components/NSSectionTitle.d.ts +2 -2
- package/dist/components/NSSectionTitle.js.map +1 -1
- package/dist/components/NSSpace.d.ts +2 -2
- package/dist/components/NSSpace.js.map +1 -1
- package/dist/components/NSTabPage.js +2 -1
- package/dist/components/NSTabPage.js.map +1 -1
- package/dist/components/NSTabPage.module.css +59 -59
- package/dist/components/NSTable.d.ts +3 -3
- package/dist/components/NSTable.js +6 -6
- package/dist/components/NSTable.js.map +1 -1
- package/dist/components/NSTable.module.css +260 -260
- package/dist/components/NSTag.js +2 -2
- package/dist/components/NSTag.js.map +1 -1
- package/dist/components/NSTag.module.css +52 -52
- package/dist/components/{NSEntityBar.d.ts → NSTile.d.ts} +2 -2
- package/dist/components/{NSEntityBar.js → NSTile.js} +3 -3
- package/dist/components/NSTile.js.map +1 -0
- package/{src/components/NSEntityBar.module.css → dist/components/NSTile.module.css} +77 -77
- package/dist/components/NSTimelineMonthly.d.ts +2 -2
- package/dist/components/NSTimelineMonthly.js.map +1 -1
- package/dist/components/NSTimelineMonthly.module.css +71 -71
- package/dist/components/NSTitle.d.ts +2 -2
- package/dist/components/NSTitle.js.map +1 -1
- package/dist/components/NSTitle.module.css +15 -15
- package/dist/main.d.ts +21 -26
- package/dist/main.js +21 -26
- package/dist/main.js.map +1 -1
- package/dist/pages/NSNotFoundPage.module.css +17 -17
- package/dist/pages/NSUpdating.module.css +35 -35
- package/dist/routing/INSRouterState.d.ts +2 -2
- package/dist/routing/Notifier.d.ts +2 -2
- package/dist/routing/Notifier.js.map +1 -1
- package/package.json +76 -75
- package/public/index.html +38 -38
- package/src/App.css +33 -57
- package/src/App.tsx +191 -377
- package/src/Color.tsx +10 -10
- package/src/CopyToClipboard.ts +6 -6
- package/src/Validator.ts +125 -117
- package/src/components/NSBarAction.module.css +97 -97
- package/src/components/NSBarAction.tsx +89 -89
- package/src/components/NSBarAlert.module.css +69 -69
- package/src/components/NSBarAlert.tsx +30 -30
- package/src/components/NSBarNotification.module.css +34 -34
- package/src/components/NSBarNotification.tsx +89 -87
- package/src/components/NSBarTitle.module.css +9 -9
- package/src/components/NSBarTitle.tsx +29 -29
- package/src/components/NSBox.module.css +50 -126
- package/src/components/{NSBoxCombo.module.css → NSBoxBaseCombo.module.css} +6 -6
- package/src/components/NSBoxBaseCombo.tsx +268 -0
- package/src/components/NSBoxBoolean.module.css +67 -88
- package/src/components/NSBoxBoolean.tsx +131 -124
- package/src/components/NSBoxBooleans.tsx +159 -159
- package/src/components/NSBoxCombo.tsx +61 -151
- package/src/components/NSBoxDate.module.css +4 -56
- package/src/components/NSBoxDate.tsx +101 -88
- package/src/components/NSBoxDateTime.module.css +4 -51
- package/src/components/NSBoxDateTime.tsx +101 -89
- package/src/components/NSBoxDouble.tsx +104 -92
- package/src/components/NSBoxDuration.module.css +5 -0
- package/src/components/NSBoxDuration.tsx +105 -92
- package/src/components/NSBoxEmail.tsx +112 -103
- package/src/components/NSBoxEntity.tsx +52 -197
- package/src/components/NSBoxEnum.tsx +64 -55
- package/src/components/NSBoxFile.module.css +10 -4
- package/src/components/NSBoxFile.tsx +101 -124
- package/src/components/NSBoxIPV4.tsx +107 -97
- package/src/components/NSBoxIPV6.tsx +103 -94
- package/src/components/NSBoxInteger.tsx +104 -94
- package/src/components/{NSBoxPrice.tsx → NSBoxMoney.tsx} +102 -92
- package/src/components/NSBoxPassword.tsx +111 -90
- package/src/components/NSBoxPhone.module.css +36 -0
- package/src/components/NSBoxPhone.tsx +116 -97
- package/src/components/NSBoxRadio.module.css +69 -70
- package/src/components/NSBoxRadio.tsx +107 -111
- package/src/components/NSBoxSearch.tsx +99 -107
- package/src/components/NSBoxString.tsx +104 -106
- package/src/components/NSBoxTextArea.module.css +45 -83
- package/src/components/NSBoxTextArea.tsx +108 -112
- package/src/components/NSBoxTime.module.css +5 -0
- package/src/components/NSBoxTime.tsx +104 -92
- package/src/components/NSButton.module.css +42 -42
- package/src/components/NSButton.tsx +25 -25
- package/src/components/NSButtonBlue.module.css +4 -4
- package/src/components/NSButtonBlue.tsx +19 -19
- package/src/components/NSButtonGreen.module.css +4 -4
- package/src/components/NSButtonGreen.tsx +19 -19
- package/src/components/NSButtonRed.module.css +4 -4
- package/src/components/NSButtonRed.tsx +19 -19
- package/src/components/NSCard.module.css +114 -114
- package/src/components/NSCard.tsx +63 -63
- package/src/components/NSCardScreenshot.module.css +41 -41
- package/src/components/NSCardScreenshot.tsx +31 -31
- package/src/components/NSChartColumn.module.css +7 -7
- package/src/components/NSChartColumn.tsx +106 -106
- package/src/components/NSChartDoughnut.tsx +108 -108
- package/src/components/NSChartPie.tsx +105 -105
- package/src/components/NSChartRange.tsx +14 -15
- package/src/components/NSChartTable.module.css +21 -21
- package/src/components/NSChartTable.tsx +94 -94
- package/src/components/NSCopy.tsx +67 -67
- package/{dist/components/NSBoxCopy.module.css → src/components/NSCopyBox.module.css} +43 -43
- package/src/components/{NSBoxCopy.tsx → NSCopyBox.tsx} +41 -41
- package/src/components/NSDialog.module.css +106 -106
- package/src/components/NSDialog.tsx +56 -56
- package/src/components/{NSDeleteDialog.tsx → NSDialogDelete.tsx} +26 -26
- package/src/components/{NSInfoDialog.tsx → NSDialogInfo.tsx} +36 -36
- package/src/components/{NSPageSelectionModal.module.css → NSDialogPageSelection.module.css} +103 -103
- package/src/components/{NSPageSelectionModal.tsx → NSDialogPageSelection.tsx} +223 -228
- package/src/components/NSDownTimer.module.css +55 -55
- package/src/components/NSDownTimer.tsx +77 -77
- package/src/components/NSDownload.module.css +46 -46
- package/src/components/NSDownload.tsx +63 -62
- package/src/components/NSElectronicCard.module.css +60 -60
- package/src/components/NSElectronicCard.tsx +46 -45
- package/src/components/NSEntityCardBackground.module.css +27 -27
- package/src/components/NSEntityCardBackground.tsx +36 -34
- package/src/components/NSFilterBox.module.css +62 -62
- package/src/components/NSFilterBox.tsx +360 -360
- package/src/components/NSFilterBoxDialog.module.css +36 -36
- package/src/components/NSFilterBoxDialog.tsx +72 -74
- package/src/components/NSFilterItem.module.css +23 -23
- package/src/components/NSFilterItem.tsx +72 -72
- package/src/components/NSFooter.module.css +123 -123
- package/src/components/NSFooter.tsx +316 -316
- package/src/components/NSHeader.module.css +291 -291
- package/src/components/NSHeader.tsx +250 -250
- package/src/components/NSHeaderScreenshot.module.css +35 -35
- package/src/components/NSHeaderScreenshot.tsx +39 -38
- package/{dist/components/NSBoxLabel.module.css → src/components/NSLabel.module.css} +15 -14
- package/src/components/{NSBoxLabel.tsx → NSLabel.tsx} +29 -29
- package/src/components/{NSBoxErrorNotifier.module.css → NSLabelErrorNotifier.module.css} +2 -2
- package/src/components/{NSBoxErrorNotifier.tsx → NSLabelErrorNotifier.tsx} +32 -32
- package/src/components/NSLayout.module.css +13 -13
- package/src/components/NSLayout.tsx +100 -109
- package/src/components/NSLine.module.css +12 -12
- package/src/components/NSLine.tsx +15 -15
- package/src/components/NSLink.module.css +36 -36
- package/src/components/NSLink.tsx +25 -25
- package/src/components/NSLinkBlue.tsx +20 -20
- package/src/components/NSLinkGreen.tsx +5 -5
- package/src/components/NSLinkRed.tsx +5 -5
- package/src/components/{NSGroupedList.module.css → NSListGrouped.module.css} +72 -72
- package/src/components/{NSGroupedList.tsx → NSListGrouped.tsx} +112 -112
- package/src/components/{NSProductList.tsx → NSListProduct.tsx} +45 -45
- package/src/components/NSLoading.module.css +30 -30
- package/src/components/NSLoading.tsx +19 -20
- package/{dist/components/NSActionMenu.module.css → src/components/NSMenuAction.module.css} +100 -101
- package/src/components/{NSActionMenu.tsx → NSMenuAction.tsx} +90 -90
- package/{dist/components/NSAssistantButton.module.css → src/components/NSMenuButton.module.css} +124 -135
- package/src/components/NSMenuButton.tsx +125 -0
- package/src/components/NSNoData.module.css +9 -9
- package/src/components/NSNoData.tsx +24 -24
- package/src/components/NSPagination.module.css +110 -110
- package/src/components/NSPagination.tsx +190 -189
- package/src/components/NSPanel.module.css +46 -46
- package/src/components/NSPanel.tsx +19 -19
- package/src/components/{NSAccordion.module.css → NSPanelAccordion.module.css} +4 -4
- package/src/components/{NSAccordion.tsx → NSPanelAccordion.tsx} +51 -51
- package/src/components/NSRange.module.css +66 -66
- package/src/components/NSRange.tsx +83 -81
- package/src/components/NSRepeater.tsx +179 -179
- package/src/components/NSSection.module.css +10 -10
- package/src/components/NSSection.tsx +23 -23
- package/src/components/NSSectionCards.module.css +38 -38
- package/src/components/NSSectionCards.tsx +51 -51
- package/src/components/{NSSectionBars.module.css → NSSectionTiles.module.css} +10 -10
- package/src/components/{NSSectionBars.tsx → NSSectionTiles.tsx} +25 -25
- package/src/components/NSSectionTitle.tsx +21 -21
- package/src/components/NSSpace.tsx +28 -28
- package/src/components/NSTabPage.module.css +59 -59
- package/src/components/NSTabPage.tsx +78 -78
- package/src/components/NSTable.module.css +260 -260
- package/src/components/NSTable.tsx +477 -477
- package/src/components/NSTag.module.css +52 -52
- package/src/components/NSTag.tsx +78 -78
- package/{dist/components/NSEntityBar.module.css → src/components/NSTile.module.css} +77 -77
- package/src/components/{NSEntityBar.tsx → NSTile.tsx} +27 -27
- package/src/components/NSTimelineMonthly.module.css +71 -71
- package/src/components/NSTimelineMonthly.tsx +44 -42
- package/src/components/NSTitle.module.css +15 -15
- package/src/components/NSTitle.tsx +19 -19
- package/src/formatter/BackColorFormatter.tsx +23 -23
- package/src/formatter/BaseColumnFormatter.ts +16 -16
- package/src/formatter/BooleanFormatter.ts +22 -22
- package/src/formatter/DateFormatter.ts +20 -20
- package/src/formatter/DateTimeFormatter.ts +20 -20
- package/src/formatter/DurationFormatter.ts +13 -13
- package/src/formatter/EmailFormatter.ts +13 -13
- package/src/formatter/EnumFormatter.ts +13 -13
- package/src/formatter/FloatFormatter.ts +16 -16
- package/src/formatter/ForeColorFormatter.tsx +24 -24
- package/src/formatter/IDFormatter.tsx +30 -30
- package/src/formatter/IPFormatter.ts +13 -13
- package/src/formatter/IntegerFormatter.ts +16 -16
- package/src/formatter/JsonFormatter.ts +14 -14
- package/src/formatter/MoneyFormatter.ts +16 -16
- package/src/formatter/PhoneFormatter.ts +13 -13
- package/src/formatter/StringFormatter.ts +22 -22
- package/src/formatter/TimeFormatter.ts +21 -21
- package/src/formatter/UnknowFormatter.ts +14 -14
- package/src/index.tsx +7 -7
- package/src/main.ts +186 -118
- package/src/pages/NSNotFoundPage.module.css +17 -17
- package/src/pages/NSNotFoundPage.tsx +11 -11
- package/src/pages/NSUpdating.module.css +35 -35
- package/src/pages/NSUpdating.tsx +32 -32
- package/src/props/IBaseComponentProps.ts +8 -8
- package/src/props/IHeaderIconProps.ts +10 -10
- package/src/props/IHeaderProps.ts +7 -7
- package/src/props/IImageProps.ts +4 -4
- package/src/props/ILinkProps.ts +5 -5
- package/src/props/IValidationNumberProps.ts +4 -4
- package/src/props/IValidationProps.ts +7 -7
- package/src/props/IValidationRegexProps.ts +4 -4
- package/src/props/IValidationStringProps.ts +4 -4
- package/src/routing/INSRouterMaker.ts +6 -6
- package/src/routing/INSRouterProps.ts +5 -5
- package/src/routing/INSRouterState.ts +5 -5
- package/src/routing/NSRouterMaker.tsx +33 -33
- package/src/routing/Notifier.ts +79 -79
- package/tsconfig.json +43 -43
- package/dist/App.css +0 -58
- package/dist/components/NSAccordion.js.map +0 -1
- package/dist/components/NSAssistantButton.d.ts +0 -5
- package/dist/components/NSAssistantButton.js +0 -17
- package/dist/components/NSAssistantButton.js.map +0 -1
- package/dist/components/NSBarHeroBanner.d.ts +0 -7
- package/dist/components/NSBarHeroBanner.js +0 -8
- package/dist/components/NSBarHeroBanner.js.map +0 -1
- package/dist/components/NSBarHeroBanner.module.css +0 -43
- package/dist/components/NSBoxCopy.d.ts +0 -7
- package/dist/components/NSBoxEntity.module.css +0 -22
- package/dist/components/NSBoxErrorNotifier.d.ts +0 -6
- package/dist/components/NSBoxErrorNotifier.js.map +0 -1
- package/dist/components/NSBoxLabel.js +0 -11
- package/dist/components/NSBoxLabel.js.map +0 -1
- package/dist/components/NSBoxPrice.js +0 -45
- package/dist/components/NSBoxPrice.js.map +0 -1
- package/dist/components/NSCopyToClipboard.d.ts +0 -7
- package/dist/components/NSCopyToClipboard.js +0 -13
- package/dist/components/NSCopyToClipboard.js.map +0 -1
- package/dist/components/NSCopyToClipboard.module.css +0 -44
- package/dist/components/NSDeleteDialog.d.ts +0 -6
- package/dist/components/NSDeleteDialog.js.map +0 -1
- package/dist/components/NSEntityBar.js.map +0 -1
- package/dist/components/NSGroupedList.js +0 -40
- package/dist/components/NSPageSelectionModal.js.map +0 -1
- package/dist/components/NSRadioButton.d.ts +0 -25
- package/dist/components/NSRadioButton.js +0 -49
- package/dist/components/NSRadioButton.js.map +0 -1
- package/dist/components/NSSectionBars.d.ts +0 -7
- package/dist/components/NSSectionBars.js +0 -10
- package/dist/components/NSSectionBars.js.map +0 -1
- package/dist/components/NSTimeTable.d.ts +0 -15
- package/dist/components/NSTimeTable.js +0 -21
- package/dist/components/NSTimeTable.js.map +0 -1
- package/dist/components/NSTimeTable.module.css +0 -7
- package/dist/formatter/ForeignIDFormatter.d.ts +0 -4
- package/dist/formatter/ForeignIDFormatter.js +0 -7
- package/dist/formatter/ForeignIDFormatter.js.map +0 -1
- package/dist/index.css +0 -6
- package/src/components/NSAssistantButton.tsx +0 -71
- package/src/components/NSBarHeroBanner.module.css +0 -43
- package/src/components/NSBarHeroBanner.tsx +0 -62
- package/src/components/NSBoxEntity.module.css +0 -22
- package/src/components/NSDeleteDialog.module.css +0 -0
- package/src/components/NSInfoDialog.module.css +0 -0
- package/src/components/NSProductList.module.css +0 -0
- package/src/components/NSTimeTable.module.css +0 -7
- package/src/components/NSTimeTable.tsx +0 -50
- /package/dist/components/{NSBoxEnum.module.css → NSDialogDelete.module.css} +0 -0
- /package/dist/components/{NSChartPie.module.css → NSDialogInfo.module.css} +0 -0
- /package/dist/components/{NSDeleteDialog.module.css → NSListProduct.module.css} +0 -0
- /package/{dist/components/NSInfoDialog.module.css → src/components/NSDialogDelete.module.css} +0 -0
- /package/{dist/components/NSProductList.module.css → src/components/NSDialogInfo.module.css} +0 -0
- /package/src/components/{NSBoxEnum.module.css → NSListProduct.module.css} +0 -0
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
3
|
import React from "react";
|
|
4
|
-
import
|
|
4
|
+
import StylesNSBox from "./NSBox.module.css";
|
|
5
5
|
import { Validator } from "../Validator";
|
|
6
|
-
import {
|
|
6
|
+
import { NSLabelErrorNotifier } from "./NSLabelErrorNotifier";
|
|
7
|
+
import { NSMenuButton } from "./NSMenuButton";
|
|
7
8
|
export class NSBoxDouble extends React.Component {
|
|
8
9
|
constructor(props) {
|
|
9
10
|
super(props);
|
|
@@ -38,8 +39,12 @@ export class NSBoxDouble extends React.Component {
|
|
|
38
39
|
this.setValue(parseFloat(e.target.value));
|
|
39
40
|
}
|
|
40
41
|
render() {
|
|
41
|
-
var _a;
|
|
42
|
-
return (_jsx(_Fragment, { children: _jsxs("div", {
|
|
42
|
+
var _a, _b, _c, _d;
|
|
43
|
+
return (_jsx(_Fragment, { children: _jsxs("div", { className: `${StylesNSBox.ns_input_parent} ${(_a = this.props.classList) === null || _a === void 0 ? void 0 : _a.join(" ")}`, style: (_b = this.props.style) !== null && _b !== void 0 ? _b : {}, children: [_jsxs("div", { className: `${StylesNSBox.ns_input_bar}`, children: [_jsxs("span", { className: StylesNSBox.ns_input_title, children: [this.props.required && _jsx("span", { style: { color: "red" }, children: "*" }), " ", this.props.title] }), _jsx(NSMenuButton, { value: (_d = (_c = this.state.value) === null || _c === void 0 ? void 0 : _c.toLocaleString()) !== null && _d !== void 0 ? _d : "", setValue: () => { }, hideFullscreen: true })] }), _jsx("input", { id: this.props.id, name: this.props.name, type: "number", min: this.props.min, max: this.props.max, className: StylesNSBox.ns_input, placeholder: this.props.placeholder, value: this.state.value, onChange: this.onChanged, onClick: () => { if (this.props.onClicked)
|
|
44
|
+
this.props.onClicked(this); }, inputMode: "decimal", pattern: "[0-9]*[.,]?[0-9]*", style: {
|
|
45
|
+
background: `url("https://static.namirasoft.com/image/concept/type/float.png") white no-repeat scroll center right 4px`,
|
|
46
|
+
backgroundSize: "24px"
|
|
47
|
+
} }), _jsx(NSLabelErrorNotifier, { error: this.state.error, clearError: () => this.setState({ error: "" }) })] }) }));
|
|
43
48
|
}
|
|
44
49
|
}
|
|
45
50
|
//# sourceMappingURL=NSBoxDouble.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NSBoxDouble.js","sourceRoot":"","sources":["../../src/components/NSBoxDouble.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,
|
|
1
|
+
{"version":3,"file":"NSBoxDouble.js","sourceRoot":"","sources":["../../src/components/NSBoxDouble.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAI7C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAiB9C,MAAM,OAAO,WAAY,SAAQ,KAAK,CAAC,SAA6C;IAEnF,YAAY,KAAuB;QAElC,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,KAAK,GAAG,EAAE,KAAK,EAAE,KAAK,CAAC,YAAY,EAAE,CAAC;QAC3C,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACzC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC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G;4BACvH,cAAc,EAAE,MAAM;yBACtB,GACA,EACF,KAAC,oBAAoB,IAAC,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,GAAI,IAC5F,GACJ,CACH,CAAC;IACH,CAAC;CACD"}
|
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
+
import "./NSBoxDuration.module.css";
|
|
2
3
|
import { IBaseComponentProps } from "../props/IBaseComponentProps";
|
|
3
4
|
import { IValidationProps } from "../props/IValidationProps";
|
|
4
5
|
import { IValidationNumberProps } from "../props/IValidationNumberProps";
|
|
5
6
|
import { IValidationStringProps } from "../props/IValidationStringProps";
|
|
6
|
-
export interface
|
|
7
|
+
export interface NSBoxDurationProps extends IBaseComponentProps, IValidationProps, IValidationStringProps, IValidationNumberProps {
|
|
7
8
|
title: string;
|
|
8
9
|
placeholder?: string;
|
|
9
10
|
defaultValue?: string;
|
|
10
11
|
onChanged?: (e: NSBoxDuration, callback?: () => void) => void;
|
|
11
12
|
onClicked?: (e: NSBoxDuration) => void;
|
|
12
13
|
}
|
|
13
|
-
export interface
|
|
14
|
+
export interface NSBoxDurationState {
|
|
14
15
|
value: string;
|
|
15
16
|
error?: string;
|
|
16
17
|
}
|
|
17
|
-
export declare class NSBoxDuration extends React.Component<
|
|
18
|
-
constructor(props:
|
|
18
|
+
export declare class NSBoxDuration extends React.Component<NSBoxDurationProps, NSBoxDurationState> {
|
|
19
|
+
constructor(props: NSBoxDurationProps);
|
|
19
20
|
getError(): string | null;
|
|
20
21
|
getValue(checkError?: boolean): string;
|
|
21
22
|
setValue(value: string, callback?: () => void): void;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
3
|
import React from "react";
|
|
4
|
-
import
|
|
4
|
+
import "./NSBoxDuration.module.css";
|
|
5
|
+
import StylesNSBox from "./NSBox.module.css";
|
|
5
6
|
import { Validator } from "../Validator";
|
|
6
|
-
import {
|
|
7
|
+
import { NSLabelErrorNotifier } from "./NSLabelErrorNotifier";
|
|
8
|
+
import { NSMenuButton } from "./NSMenuButton";
|
|
7
9
|
export class NSBoxDuration extends React.Component {
|
|
8
10
|
constructor(props) {
|
|
9
11
|
var _a;
|
|
@@ -39,8 +41,13 @@ export class NSBoxDuration extends React.Component {
|
|
|
39
41
|
this.setValue(e.target.value);
|
|
40
42
|
}
|
|
41
43
|
render() {
|
|
42
|
-
var _a;
|
|
43
|
-
return (_jsx(_Fragment, { children: _jsxs("div", {
|
|
44
|
+
var _a, _b, _c, _d;
|
|
45
|
+
return (_jsx(_Fragment, { children: _jsxs("div", { className: `${StylesNSBox.ns_input_parent} ${(_a = this.props.classList) === null || _a === void 0 ? void 0 : _a.join(" ")}`, style: (_b = this.props.style) !== null && _b !== void 0 ? _b : {}, children: [_jsxs("div", { className: `${StylesNSBox.ns_input_bar}`, children: [_jsxs("span", { className: StylesNSBox.ns_input_title, children: [this.props.required && _jsx("span", { style: { color: "red" }, children: "*" }), " ", this.props.title] }), _jsx(NSMenuButton, { value: (_d = (_c = this.state.value) === null || _c === void 0 ? void 0 : _c.toString()) !== null && _d !== void 0 ? _d : "", setValue: () => { }, hideFullscreen: true })] }), _jsx("input", { id: this.props.id, name: this.props.name, type: "time", className: StylesNSBox.ns_input, placeholder: this.props.placeholder, value: this.state.value, step: "1", onChange: this.onChanged, onClick: () => { if (this.props.onClicked)
|
|
46
|
+
this.props.onClicked(this); }, style: {
|
|
47
|
+
background: `url("https://static.namirasoft.com/image/concept/type/duration.png") white no-repeat scroll center right 4px`,
|
|
48
|
+
backgroundSize: "24px",
|
|
49
|
+
paddingRight: "7px"
|
|
50
|
+
} }), _jsx(NSLabelErrorNotifier, { error: this.state.error, clearError: () => this.setState({ error: "" }) })] }) }));
|
|
44
51
|
}
|
|
45
52
|
}
|
|
46
53
|
//# sourceMappingURL=NSBoxDuration.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NSBoxDuration.js","sourceRoot":"","sources":["../../src/components/NSBoxDuration.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,
|
|
1
|
+
{"version":3,"file":"NSBoxDuration.js","sourceRoot":"","sources":["../../src/components/NSBoxDuration.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,4BAA4B,CAAA;AACnC,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAK7C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAiB9C,MAAM,OAAO,aAAc,SAAQ,KAAK,CAAC,SAAiD;IAEzF,YAAY,KAAyB;;QAEpC,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,KAAK,GAAG,EAAE,KAAK,EAAE,MAAA,KAAK,CAAC,YAAY,mCAAI,EAAE,EAAE,CAAC;QACjD,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACzC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACzC,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAC5C,CAAC;IACD,QAAQ;QAEP,OAAO,CACN,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,I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zC,IAAI,CAAC,KAAK,CAAC,QAAQ,IAAI,eAAM,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,kBAAU,OAAG,IAAI,CAAC,KAAK,CAAC,KAAK,IAC5E,EACP,KAAC,YAAY,IAAC,KAAK,EAAE,MAAA,MAAA,IAAI,CAAC,KAAK,CAAC,KAAK,0CAAE,QAAQ,EAAE,mCAAI,EAAE,EAAE,QAAQ,EAAE,GAAG,EAAE,GAAG,CAAC,EAAE,cAAc,SAAG,IAC1F,EACN,gBACC,EAAE,EAAE,IAAI,CAAC,KAAK,CAAC,EAAE,EACjB,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,IAAI,EACrB,IAAI,EAAC,MAAM,EACX,SAAS,EAAE,WAAW,CAAC,QAAQ,EAC/B,WAAW,EAAE,IAAI,CAAC,KAAK,CAAC,WAAW,EACnC,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EACvB,IAAI,EAAC,GAAG,EACR,QAAQ,EAAE,IAAI,CAAC,SAAS,EACxB,OAAO,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,SAAS;4BAAE,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EACxE,KAAK,EAAE;4BACN,UAAU,EAAE,8GAA8G;4BAC1H,cAAc,EAAE,MAAM;4BACtB,YAAY,EAAE,KAAK;yBACnB,GACA,EACF,KAAC,oBAAoB,IAAC,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,GAAI,IAC5F,GACJ,CACH,CAAC;IACH,CAAC;CACD"}
|
|
@@ -2,23 +2,22 @@ import React from "react";
|
|
|
2
2
|
import { IValidationProps } from "../props/IValidationProps";
|
|
3
3
|
import { IValidationStringProps } from "../props/IValidationStringProps";
|
|
4
4
|
import { IBaseComponentProps } from "../props/IBaseComponentProps";
|
|
5
|
-
export interface
|
|
5
|
+
export interface NSBoxEmailProps extends IBaseComponentProps, IValidationProps, IValidationStringProps {
|
|
6
6
|
title: string;
|
|
7
7
|
defaultValue?: string;
|
|
8
|
-
onChanged?: (e:
|
|
8
|
+
onChanged?: (e: NSBoxEmail, callback?: () => void) => void;
|
|
9
|
+
onClicked?: (e: NSBoxEmail) => void;
|
|
9
10
|
placeholder?: string;
|
|
10
11
|
}
|
|
11
|
-
export interface
|
|
12
|
+
export interface NSBoxEmailState {
|
|
12
13
|
value: string;
|
|
13
14
|
error?: string;
|
|
14
|
-
isFullScreen: boolean;
|
|
15
15
|
}
|
|
16
|
-
export declare class NSBoxEmail extends React.Component<
|
|
17
|
-
constructor(props:
|
|
16
|
+
export declare class NSBoxEmail extends React.Component<NSBoxEmailProps, NSBoxEmailState> {
|
|
17
|
+
constructor(props: NSBoxEmailProps);
|
|
18
18
|
getError(): string | null;
|
|
19
19
|
getValue(checkError?: boolean): string;
|
|
20
20
|
setValue(value: string, callback?: () => void): void;
|
|
21
21
|
private onChanged;
|
|
22
|
-
private toggleFullScreen;
|
|
23
22
|
render(): import("react/jsx-runtime").JSX.Element;
|
|
24
23
|
}
|
|
@@ -1,19 +1,18 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
3
|
import React from "react";
|
|
4
|
+
import StylesNSBox from "./NSBox.module.css";
|
|
4
5
|
import { Validator } from "../Validator";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import Styles from "./NSBox.module.css";
|
|
6
|
+
import { NSLabelErrorNotifier } from "./NSLabelErrorNotifier";
|
|
7
|
+
import { NSMenuButton } from "./NSMenuButton";
|
|
8
8
|
export class NSBoxEmail extends React.Component {
|
|
9
9
|
constructor(props) {
|
|
10
10
|
var _a;
|
|
11
11
|
super(props);
|
|
12
|
-
this.state = { value: (_a = props.defaultValue) !== null && _a !== void 0 ? _a : ""
|
|
12
|
+
this.state = { value: (_a = props.defaultValue) !== null && _a !== void 0 ? _a : "" };
|
|
13
13
|
this.setValue = this.setValue.bind(this);
|
|
14
14
|
this.getValue = this.getValue.bind(this);
|
|
15
15
|
this.onChanged = this.onChanged.bind(this);
|
|
16
|
-
this.toggleFullScreen = this.toggleFullScreen.bind(this);
|
|
17
16
|
}
|
|
18
17
|
getError() {
|
|
19
18
|
return (Validator.getError(this.props.title, this.state.value, this.props) ||
|
|
@@ -36,16 +35,24 @@ export class NSBoxEmail extends React.Component {
|
|
|
36
35
|
onChanged(e, callback) {
|
|
37
36
|
this.setValue(e.target.value, callback);
|
|
38
37
|
if (this.props.onChanged)
|
|
39
|
-
this.props.onChanged(
|
|
38
|
+
this.props.onChanged(this, callback);
|
|
40
39
|
else if (callback)
|
|
41
40
|
callback();
|
|
42
41
|
}
|
|
43
|
-
toggleFullScreen() {
|
|
44
|
-
this.setState(prevState => ({ isFullScreen: !prevState.isFullScreen }));
|
|
45
|
-
}
|
|
46
42
|
render() {
|
|
47
|
-
var _a;
|
|
48
|
-
|
|
43
|
+
var _a, _b;
|
|
44
|
+
let menus = [];
|
|
45
|
+
if (!this.getError())
|
|
46
|
+
menus.push({
|
|
47
|
+
title: "Send Email",
|
|
48
|
+
icon: "https://static.namirasoft.com/image/concept/type/email.png",
|
|
49
|
+
href: `mailto:${this.state.value}`
|
|
50
|
+
});
|
|
51
|
+
return (_jsx(_Fragment, { children: _jsxs("div", { className: `${StylesNSBox.ns_input_parent} ${(_a = this.props.classList) === null || _a === void 0 ? void 0 : _a.join(" ")}`, style: (_b = this.props.style) !== null && _b !== void 0 ? _b : {}, children: [_jsxs("div", { className: `${StylesNSBox.ns_input_bar}`, children: [_jsxs("span", { className: StylesNSBox.ns_input_title, children: [this.props.required && _jsx("span", { style: { color: "red" }, children: "*" }), " ", this.props.title] }), _jsx(NSMenuButton, { value: this.state.value, setValue: this.setValue, menus: menus })] }), _jsx("input", { id: this.props.id, name: this.props.name, type: "email", className: StylesNSBox.ns_input, placeholder: this.props.placeholder, value: this.state.value, onChange: this.onChanged, onClick: () => { if (this.props.onClicked)
|
|
52
|
+
this.props.onClicked(this); }, style: {
|
|
53
|
+
background: `url("https://static.namirasoft.com/image/concept/type/email.png") white no-repeat scroll center right 4px`,
|
|
54
|
+
backgroundSize: "24px"
|
|
55
|
+
} }), _jsx(NSLabelErrorNotifier, { error: this.state.error, clearError: () => this.setState({ error: "" }) })] }) }));
|
|
49
56
|
}
|
|
50
57
|
}
|
|
51
58
|
//# sourceMappingURL=NSBoxEmail.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NSBoxEmail.js","sourceRoot":"","sources":["../../src/components/NSBoxEmail.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AACb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,
|
|
1
|
+
{"version":3,"file":"NSBoxEmail.js","sourceRoot":"","sources":["../../src/components/NSBoxEmail.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AACb,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,WAAW,MAAM,oBAAoB,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAIzC,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAiB9C,MAAM,OAAO,UAAW,SAAQ,KAAK,CAAC,SAA2C;IAEhF,YAAY,KAAsB;;QAEjC,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,CAAC,KAAK,GAAG,EAAE,KAAK,EAAE,MAAA,KAAK,CAAC,YAAY,mCAAI,EAAE,EAAE,CAAC;QACjD,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QACzC,IAAI,CAAC,QAAQ,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,EAAE,IAAI,CAAC,SAAS,EACxB,OAAO,EAAE,GAAG,EAAE,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,SAAS;4BAAE,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,EACxE,KAAK,EAAE;4BACN,UAAU,EAAE,2GAA2G;4BACvH,cAAc,EAAE,MAAM;yBACtB,GACA,EACF,KAAC,oBAAoB,IAAC,KAAK,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,EAAE,UAAU,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,GAAI,IAC5F,GACJ,CACH,CAAC;IACH,CAAC;CACD"}
|
|
@@ -1,47 +1,13 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
placeholder?: string;
|
|
13
|
-
fullWidth?: boolean;
|
|
14
|
-
defaultValue?: string;
|
|
15
|
-
onChanged?: (e: NSBoxEntity<Data>, callback?: () => void) => void;
|
|
16
|
-
onClicked?: (e: NSBoxEntity<Data>) => void;
|
|
17
|
-
onLoaded?: (e: NSBoxEntity<Data>) => void;
|
|
18
|
-
multiple: boolean;
|
|
19
|
-
getItems: (filters: FilterItem[] | null, page: number | null, size: number | null, sorts: SortItem[], user_id: (string | null)) => Promise<{
|
|
20
|
-
count: number;
|
|
21
|
-
rows: Data[];
|
|
22
|
-
}>;
|
|
23
|
-
getValue: (item: Data) => string;
|
|
24
|
-
getText: (item: Data) => string;
|
|
25
|
-
}
|
|
26
|
-
export interface INSBoxEntityState<Data> {
|
|
27
|
-
items: Data[] | null;
|
|
28
|
-
items_string: INSBoxEntitOption[] | null;
|
|
29
|
-
value: Data | null;
|
|
30
|
-
values: Data[];
|
|
31
|
-
error?: string;
|
|
32
|
-
set_value: ((data: Data) => boolean) | null;
|
|
33
|
-
}
|
|
34
|
-
export declare class NSBoxEntity<Data> extends React.Component<INSBoxEntityProps<Data>, INSBoxEntityState<Data>> {
|
|
35
|
-
constructor(props: INSBoxEntityProps<Data>);
|
|
36
|
-
getError(value: Data | null): string | null;
|
|
37
|
-
getValue(checkError?: boolean): Data | null;
|
|
38
|
-
getValues(): Data[];
|
|
39
|
-
search(finder: (data: Data) => boolean): Data | null;
|
|
40
|
-
setValueBySearch(finder: (data: Data) => boolean, callback?: () => void): boolean;
|
|
41
|
-
setValue(value: Data | null, callback?: () => void): void;
|
|
42
|
-
setValues(values: Data[], callback?: () => void): void;
|
|
43
|
-
private onChanged;
|
|
44
|
-
componentDidMount(): void;
|
|
2
|
+
import { NSBoxBaseCombo, NSBoxBaseComboProps } from "../main";
|
|
3
|
+
export interface NSBoxEntityProps<Data> extends NSBoxBaseComboProps<Data> {
|
|
4
|
+
}
|
|
5
|
+
export declare class NSBoxEntity<Data> extends React.Component<NSBoxEntityProps<Data>> {
|
|
6
|
+
NSBoxBaseCombo: React.RefObject<NSBoxBaseCombo<Data>>;
|
|
7
|
+
constructor(props: NSBoxEntityProps<Data>);
|
|
8
|
+
getValue(checkError?: boolean): string | null;
|
|
9
|
+
getValues(): string[];
|
|
10
|
+
setValue(value: string | null, callback?: () => void): void;
|
|
11
|
+
setValues(values: string[], callback?: () => void): void;
|
|
45
12
|
render(): import("react/jsx-runtime").JSX.Element;
|
|
46
13
|
}
|
|
47
|
-
export {};
|
|
@@ -1,113 +1,40 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as _jsx
|
|
3
|
-
import React from "react";
|
|
4
|
-
import
|
|
5
|
-
import StyleNSBox from "./NSBox.module.css";
|
|
6
|
-
import { Select, Space } from 'antd';
|
|
7
|
-
import { Validator } from "../Validator";
|
|
8
|
-
import { NSBoxErrorNotifier } from "./NSBoxErrorNotifier";
|
|
9
|
-
import { NSLoading } from "./NSLoading";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import React, { createRef } from "react";
|
|
4
|
+
import { NSBoxBaseCombo } from "../main";
|
|
10
5
|
export class NSBoxEntity extends React.Component {
|
|
11
6
|
constructor(props) {
|
|
12
7
|
super(props);
|
|
13
|
-
this.
|
|
14
|
-
items: null,
|
|
15
|
-
items_string: null,
|
|
16
|
-
value: null,
|
|
17
|
-
values: [],
|
|
18
|
-
set_value: null
|
|
19
|
-
};
|
|
8
|
+
this.NSBoxBaseCombo = createRef();
|
|
20
9
|
this.getValues = this.getValues.bind(this);
|
|
21
10
|
this.setValues = this.setValues.bind(this);
|
|
22
11
|
this.setValue = this.setValue.bind(this);
|
|
23
12
|
this.getValue = this.getValue.bind(this);
|
|
24
|
-
this.onChanged = this.onChanged.bind(this);
|
|
25
|
-
}
|
|
26
|
-
getError(value) {
|
|
27
|
-
let value_string = value == null ? "" : this.props.getValue(value);
|
|
28
|
-
return (Validator.getError(this.props.title, value_string, this.props));
|
|
29
13
|
}
|
|
30
14
|
getValue(checkError = true) {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
if (error) {
|
|
34
|
-
this.setState({ error });
|
|
35
|
-
throw new Error(error);
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
return this.state.value;
|
|
15
|
+
var _a, _b;
|
|
16
|
+
return (_b = (_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.getValue(checkError)) !== null && _b !== void 0 ? _b : null;
|
|
39
17
|
}
|
|
40
18
|
getValues() {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
if (error) {
|
|
44
|
-
this.setState({ error });
|
|
45
|
-
throw new Error(error);
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
return this.state.values;
|
|
49
|
-
}
|
|
50
|
-
search(finder) {
|
|
51
|
-
if (this.state.items)
|
|
52
|
-
for (let i = 0; i < this.state.items.length; i++) {
|
|
53
|
-
const data = this.state.items[i];
|
|
54
|
-
if (finder(data))
|
|
55
|
-
return data;
|
|
56
|
-
}
|
|
57
|
-
return null;
|
|
58
|
-
}
|
|
59
|
-
setValueBySearch(finder, callback) {
|
|
60
|
-
let data = this.search(finder);
|
|
61
|
-
if (data) {
|
|
62
|
-
this.setValue(data, callback);
|
|
63
|
-
return true;
|
|
64
|
-
}
|
|
65
|
-
this.setState({ set_value: finder }, callback);
|
|
66
|
-
return false;
|
|
19
|
+
var _a, _b;
|
|
20
|
+
return (_b = (_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.getValues()) !== null && _b !== void 0 ? _b : [];
|
|
67
21
|
}
|
|
68
22
|
setValue(value, callback) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
this.props.onChanged(this, callback);
|
|
72
|
-
else if (callback)
|
|
73
|
-
callback();
|
|
74
|
-
});
|
|
23
|
+
var _a;
|
|
24
|
+
(_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.setValue(value, callback);
|
|
75
25
|
}
|
|
76
26
|
setValues(values, callback) {
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
this.props.onChanged(this, callback);
|
|
80
|
-
else if (callback)
|
|
81
|
-
callback();
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
|
-
onChanged(value) {
|
|
85
|
-
var _a, _b;
|
|
86
|
-
if (this.state.items)
|
|
87
|
-
if (this.props.multiple) {
|
|
88
|
-
let string_values = value;
|
|
89
|
-
let ds = (_a = this.state.items.filter(item => string_values.includes(this.props.getValue(item)))) !== null && _a !== void 0 ? _a : [];
|
|
90
|
-
this.setValues(ds);
|
|
91
|
-
}
|
|
92
|
-
else {
|
|
93
|
-
let d = (_b = this.state.items.find(item => this.props.getValue(item) === value)) !== null && _b !== void 0 ? _b : null;
|
|
94
|
-
this.setValue(d);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
componentDidMount() {
|
|
98
|
-
this.props.getItems([], null, null, [], null).then(items => {
|
|
99
|
-
let items_string = items.rows.map(item => { return { value: this.props.getValue(item), desc: this.props.getText(item) }; });
|
|
100
|
-
this.setState({ items: items.rows, items_string }, () => {
|
|
101
|
-
if (this.state.set_value)
|
|
102
|
-
this.setValueBySearch(this.state.set_value);
|
|
103
|
-
if (this.props.onLoaded)
|
|
104
|
-
this.props.onLoaded(this);
|
|
105
|
-
});
|
|
106
|
-
}).catch(() => { });
|
|
27
|
+
var _a;
|
|
28
|
+
(_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.setValues(values, callback);
|
|
107
29
|
}
|
|
108
30
|
render() {
|
|
109
|
-
|
|
110
|
-
|
|
31
|
+
return _jsx(NSBoxBaseCombo, Object.assign({ ref: this.NSBoxBaseCombo }, this.props, { onChanged: (_, callback) => {
|
|
32
|
+
if (this.props.onChanged)
|
|
33
|
+
this.props.onChanged(this, callback);
|
|
34
|
+
}, onClicked: (_) => {
|
|
35
|
+
if (this.props.onClicked)
|
|
36
|
+
this.props.onClicked(this);
|
|
37
|
+
} }));
|
|
111
38
|
}
|
|
112
39
|
}
|
|
113
40
|
//# sourceMappingURL=NSBoxEntity.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NSBoxEntity.js","sourceRoot":"","sources":["../../src/components/NSBoxEntity.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;
|
|
1
|
+
{"version":3,"file":"NSBoxEntity.js","sourceRoot":"","sources":["../../src/components/NSBoxEntity.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACzC,OAAO,EAAE,cAAc,EAAuB,MAAM,SAAS,CAAC;AAK9D,MAAM,OAAO,WAAkB,SAAQ,KAAK,CAAC,SAAiC;IAG7E,YAAY,KAA6B;QAExC,KAAK,CAAC,KAAK,CAAC,CAAC;QAHP,mBAAc,GAAG,SAAS,EAAwB,CAAC;QAIzD,IAAI,CAAC,SAAS,GAA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CAAC,KAAK,CAAC,SAAS;oBACvB,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;YAC7B,CAAC,IACA,CAAA;IACH,CAAC;CACD"}
|
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import {
|
|
3
|
-
|
|
2
|
+
import { NSBoxBaseCombo, NSBoxBaseComboBaseProps } from "../main";
|
|
3
|
+
interface NSBoxEnumProps<T> extends NSBoxBaseComboBaseProps {
|
|
4
|
+
getEnumObject: () => {
|
|
5
|
+
[s: string]: T;
|
|
6
|
+
};
|
|
4
7
|
}
|
|
5
|
-
export declare class NSBoxEnum extends React.Component<
|
|
6
|
-
|
|
7
|
-
constructor(props:
|
|
8
|
-
|
|
9
|
-
getValue<T>(enumObj: {
|
|
8
|
+
export declare class NSBoxEnum<T> extends React.Component<NSBoxEnumProps<T>> {
|
|
9
|
+
NSBoxBaseCombo: React.RefObject<NSBoxBaseCombo<string>>;
|
|
10
|
+
constructor(props: NSBoxEnumProps<T>);
|
|
11
|
+
getValue<T>(enumObject: {
|
|
10
12
|
[s: string]: T;
|
|
11
|
-
}, _default: T): T | null;
|
|
12
|
-
getValues<T>(
|
|
13
|
+
}, _default: T, checkError?: boolean): T | null;
|
|
14
|
+
getValues<T>(enumObject: {
|
|
13
15
|
[s: string]: T;
|
|
14
16
|
}, _default: T): T[];
|
|
15
17
|
setValue(value: string | null, callback?: () => void): void;
|
|
16
18
|
setValues(values: string[], callback?: () => void): void;
|
|
17
19
|
render(): import("react/jsx-runtime").JSX.Element;
|
|
18
20
|
}
|
|
21
|
+
export {};
|
|
@@ -1,46 +1,55 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
2
11
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
12
|
import React, { createRef } from "react";
|
|
4
13
|
import { ObjectService } from "namirasoft-core";
|
|
5
|
-
import {
|
|
14
|
+
import { NSBoxBaseCombo } from "../main";
|
|
6
15
|
export class NSBoxEnum extends React.Component {
|
|
7
16
|
constructor(props) {
|
|
8
17
|
super(props);
|
|
9
|
-
this.
|
|
18
|
+
this.NSBoxBaseCombo = createRef();
|
|
10
19
|
this.getValues = this.getValues.bind(this);
|
|
11
20
|
this.setValues = this.setValues.bind(this);
|
|
12
21
|
this.setValue = this.setValue.bind(this);
|
|
13
22
|
this.getValue = this.getValue.bind(this);
|
|
14
23
|
}
|
|
15
|
-
|
|
16
|
-
var _a, _b;
|
|
17
|
-
return (_b = (_a = this.NSBoxCombo.current) === null || _a === void 0 ? void 0 : _a.getError(value)) !== null && _b !== void 0 ? _b : null;
|
|
18
|
-
}
|
|
19
|
-
getValue(enumObj, _default) {
|
|
24
|
+
getValue(enumObject, _default, checkError = true) {
|
|
20
25
|
var _a;
|
|
21
|
-
return new ObjectService((_a = this.
|
|
26
|
+
return new ObjectService((_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.getValue(checkError)).getEnum(enumObject, _default);
|
|
22
27
|
}
|
|
23
|
-
getValues(
|
|
28
|
+
getValues(enumObject, _default) {
|
|
24
29
|
var _a, _b;
|
|
25
|
-
let values = (_b = (_a = this.
|
|
26
|
-
return values.map(value => new ObjectService(value).getEnum(
|
|
30
|
+
let values = (_b = (_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.getValues()) !== null && _b !== void 0 ? _b : [];
|
|
31
|
+
return values.map(value => new ObjectService(value).getEnum(enumObject, _default));
|
|
27
32
|
}
|
|
28
33
|
setValue(value, callback) {
|
|
29
34
|
var _a;
|
|
30
|
-
(_a = this.
|
|
35
|
+
(_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.setValue(value, callback);
|
|
31
36
|
}
|
|
32
37
|
setValues(values, callback) {
|
|
33
38
|
var _a;
|
|
34
|
-
(_a = this.
|
|
39
|
+
(_a = this.NSBoxBaseCombo.current) === null || _a === void 0 ? void 0 : _a.setValues(values, callback);
|
|
35
40
|
}
|
|
36
41
|
render() {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
return _jsx(NSBoxBaseCombo, Object.assign({ ref: this.NSBoxBaseCombo }, this.props, { onChanged: (_, callback) => {
|
|
43
|
+
if (this.props.onChanged)
|
|
44
|
+
this.props.onChanged(this, callback);
|
|
45
|
+
}, onClicked: (_) => {
|
|
46
|
+
if (this.props.onClicked)
|
|
47
|
+
this.props.onClicked(this);
|
|
48
|
+
}, getItems: () => __awaiter(this, void 0, void 0, function* () {
|
|
49
|
+
let obj = this.props.getEnumObject();
|
|
50
|
+
let rows = Object.keys(obj);
|
|
51
|
+
return { count: rows.length, rows };
|
|
52
|
+
}), getValue: x => x, getTitle: x => x }));
|
|
44
53
|
}
|
|
45
54
|
}
|
|
46
55
|
//# sourceMappingURL=NSBoxEnum.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NSBoxEnum.js","sourceRoot":"","sources":["../../src/components/NSBoxEnum.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC
|
|
1
|
+
{"version":3,"file":"NSBoxEnum.js","sourceRoot":"","sources":["../../src/components/NSBoxEnum.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;AAEb,OAAO,KAAK,EAAE,EAAE,S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