@e-llm-studio/instant-learning 0.0.75 → 0.0.77
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/features/InstantLearning/InstantLearning.js +1 -1
- package/dist/cjs/features/InstantLearning/_components/ChatComponent.js +1 -1
- package/dist/cjs/features/InstantLearning/_components/ConflictingLearningWarnCard.js +1 -1
- package/dist/cjs/features/InstantLearning/_components/ConflictingLearningWarnCardDB.js +1 -1
- package/dist/cjs/features/InstantLearning/_components/ContextualChatComponent.js +2 -0
- package/dist/cjs/features/InstantLearning/_components/ContextualChatComponent.js.map +1 -0
- package/dist/cjs/features/InstantLearning/_components/ContextualConflictDBCard.js +2 -0
- package/dist/cjs/features/InstantLearning/_components/ContextualConflictDBCard.js.map +1 -0
- package/dist/cjs/features/InstantLearning/_components/ContextualLearningForm.js +2 -0
- package/dist/cjs/features/InstantLearning/_components/ContextualLearningForm.js.map +1 -0
- package/dist/cjs/features/InstantLearning/_components/LearningDetailsForm.js +1 -1
- package/dist/cjs/features/WtaWnta/WtaWnta.js +1 -1
- package/dist/cjs/features/WtaWnta/_components/AgentDetailsForm.js +1 -1
- package/dist/cjs/features/WtaWnta/_components/SimilarConflictingCard.js +1 -1
- package/dist/cjs/features/WtaWnta/_components/ValidationCard.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Box/Box.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Box/Box.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/ButtonBase/TouchRipple.js +5 -5
- package/dist/cjs/node_modules/@mui/material/ButtonBase/TouchRipple.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/CircularProgress/CircularProgress.js +5 -5
- package/dist/cjs/node_modules/@mui/material/CircularProgress/CircularProgress.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Container/Container.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Container/Container.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/cjs/node_modules/@mui/material/GlobalStyles/GlobalStyles.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Grid/Grid.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Grid/Grid.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Hidden/HiddenCss.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Hidden/HiddenCss.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/LinearProgress/LinearProgress.js +7 -7
- package/dist/cjs/node_modules/@mui/material/LinearProgress/LinearProgress.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Link/getTextDecoration.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Link/getTextDecoration.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Popper/Popper.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Popper/Popper.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Skeleton/Skeleton.js +5 -5
- package/dist/cjs/node_modules/@mui/material/Skeleton/Skeleton.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Snackbar/Snackbar.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Snackbar/Snackbar.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Stack/Stack.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Stack/Stack.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/ToggleButton/ToggleButton.js +1 -1
- package/dist/cjs/node_modules/@mui/material/ToggleButton/ToggleButton.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Tooltip/Tooltip.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Tooltip/Tooltip.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/Unstable_Grid2/Grid2.js +1 -1
- package/dist/cjs/node_modules/@mui/material/Unstable_Grid2/Grid2.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/CssVarsProvider.js +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/CssVarsProvider.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/ThemeProvider.js +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/ThemeProvider.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/experimental_extendTheme.js +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/experimental_extendTheme.js.map +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/useTheme.js +1 -1
- package/dist/cjs/node_modules/@mui/material/styles/useTheme.js.map +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js.map +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js.map +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js.map +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/useThemeWithoutDefault.js +1 -1
- package/dist/cjs/node_modules/@mui/system/esm/useThemeWithoutDefault.js.map +1 -1
- package/dist/cjs/node_modules/lucide-react/dist/esm/icons/sparkles.js +1 -1
- package/dist/cjs/node_modules/lucide-react/dist/esm/icons/sparkles.js.map +1 -1
- package/dist/cjs/utils/agentGenieAPI.js +2 -0
- package/dist/cjs/utils/agentGenieAPI.js.map +1 -0
- package/dist/cjs/utils/instantLearningAPI.js +2 -0
- package/dist/cjs/utils/instantLearningAPI.js.map +1 -0
- package/dist/features/InstantLearning/InstantLearning.js +1 -1
- package/dist/features/InstantLearning/_components/ChatComponent.js +1 -1
- package/dist/features/InstantLearning/_components/ConflictingLearningWarnCard.js +1 -1
- package/dist/features/InstantLearning/_components/ConflictingLearningWarnCardDB.js +1 -1
- package/dist/features/InstantLearning/_components/ContextualChatComponent.js +2 -0
- package/dist/features/InstantLearning/_components/ContextualChatComponent.js.map +1 -0
- package/dist/features/InstantLearning/_components/ContextualConflictDBCard.js +2 -0
- package/dist/features/InstantLearning/_components/ContextualConflictDBCard.js.map +1 -0
- package/dist/features/InstantLearning/_components/ContextualLearningForm.js +2 -0
- package/dist/features/InstantLearning/_components/ContextualLearningForm.js.map +1 -0
- package/dist/features/InstantLearning/_components/LearningDetailsForm.js +1 -1
- package/dist/features/WtaWnta/WtaWnta.js +1 -1
- package/dist/features/WtaWnta/_components/AgentDetailsForm.js +1 -1
- package/dist/features/WtaWnta/_components/SimilarConflictingCard.js +1 -1
- package/dist/features/WtaWnta/_components/ValidationCard.js +1 -1
- package/dist/node_modules/@mui/material/Box/Box.js +1 -1
- package/dist/node_modules/@mui/material/Box/Box.js.map +1 -1
- package/dist/node_modules/@mui/material/ButtonBase/TouchRipple.js +5 -5
- package/dist/node_modules/@mui/material/ButtonBase/TouchRipple.js.map +1 -1
- package/dist/node_modules/@mui/material/CircularProgress/CircularProgress.js +5 -5
- package/dist/node_modules/@mui/material/CircularProgress/CircularProgress.js.map +1 -1
- package/dist/node_modules/@mui/material/Container/Container.js +1 -1
- package/dist/node_modules/@mui/material/Container/Container.js.map +1 -1
- package/dist/node_modules/@mui/material/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/node_modules/@mui/material/GlobalStyles/GlobalStyles.js.map +1 -1
- package/dist/node_modules/@mui/material/Grid/Grid.js +1 -1
- package/dist/node_modules/@mui/material/Grid/Grid.js.map +1 -1
- package/dist/node_modules/@mui/material/Hidden/HiddenCss.js +1 -1
- package/dist/node_modules/@mui/material/Hidden/HiddenCss.js.map +1 -1
- package/dist/node_modules/@mui/material/LinearProgress/LinearProgress.js +7 -7
- package/dist/node_modules/@mui/material/LinearProgress/LinearProgress.js.map +1 -1
- package/dist/node_modules/@mui/material/Link/getTextDecoration.js +1 -1
- package/dist/node_modules/@mui/material/Link/getTextDecoration.js.map +1 -1
- package/dist/node_modules/@mui/material/Popper/Popper.js +1 -1
- package/dist/node_modules/@mui/material/Popper/Popper.js.map +1 -1
- package/dist/node_modules/@mui/material/Skeleton/Skeleton.js +5 -5
- package/dist/node_modules/@mui/material/Skeleton/Skeleton.js.map +1 -1
- package/dist/node_modules/@mui/material/Snackbar/Snackbar.js +1 -1
- package/dist/node_modules/@mui/material/Snackbar/Snackbar.js.map +1 -1
- package/dist/node_modules/@mui/material/Stack/Stack.js +1 -1
- package/dist/node_modules/@mui/material/Stack/Stack.js.map +1 -1
- package/dist/node_modules/@mui/material/ToggleButton/ToggleButton.js +1 -1
- package/dist/node_modules/@mui/material/ToggleButton/ToggleButton.js.map +1 -1
- package/dist/node_modules/@mui/material/Tooltip/Tooltip.js +1 -1
- package/dist/node_modules/@mui/material/Tooltip/Tooltip.js.map +1 -1
- package/dist/node_modules/@mui/material/Unstable_Grid2/Grid2.js +1 -1
- package/dist/node_modules/@mui/material/Unstable_Grid2/Grid2.js.map +1 -1
- package/dist/node_modules/@mui/material/styles/CssVarsProvider.js +1 -1
- package/dist/node_modules/@mui/material/styles/CssVarsProvider.js.map +1 -1
- package/dist/node_modules/@mui/material/styles/ThemeProvider.js +1 -1
- package/dist/node_modules/@mui/material/styles/ThemeProvider.js.map +1 -1
- package/dist/node_modules/@mui/material/styles/experimental_extendTheme.js +1 -1
- package/dist/node_modules/@mui/material/styles/experimental_extendTheme.js.map +1 -1
- package/dist/node_modules/@mui/material/styles/useTheme.js +1 -1
- package/dist/node_modules/@mui/material/styles/useTheme.js.map +1 -1
- package/dist/node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js +1 -1
- package/dist/node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js.map +1 -1
- package/dist/node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js +1 -1
- package/dist/node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js.map +1 -1
- package/dist/node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js +1 -1
- package/dist/node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js.map +1 -1
- package/dist/node_modules/@mui/system/esm/useThemeWithoutDefault.js +1 -1
- package/dist/node_modules/@mui/system/esm/useThemeWithoutDefault.js.map +1 -1
- package/dist/node_modules/lucide-react/dist/esm/icons/sparkles.js +1 -1
- package/dist/node_modules/lucide-react/dist/esm/icons/sparkles.js.map +1 -1
- package/dist/types/src/features/InstantLearning/InstantLearning.d.ts +48 -1
- package/dist/types/src/features/InstantLearning/InstantLearning.d.ts.map +1 -1
- package/dist/{src/features/InstantLearning/_components/ChatComponent.d.ts → types/src/features/InstantLearning/_components/ContextualChatComponent.d.ts} +10 -4
- package/dist/types/src/features/InstantLearning/_components/ContextualChatComponent.d.ts.map +1 -0
- package/dist/{src/features/InstantLearning/_components/ConflictingLearningWarnCardDB.d.ts → types/src/features/InstantLearning/_components/ContextualConflictDBCard.d.ts} +4 -15
- package/dist/types/src/features/InstantLearning/_components/ContextualConflictDBCard.d.ts.map +1 -0
- package/dist/types/src/features/InstantLearning/_components/ContextualLearningForm.d.ts +43 -0
- package/dist/types/src/features/InstantLearning/_components/ContextualLearningForm.d.ts.map +1 -0
- package/dist/types/src/utils/agentGenieAPI.d.ts +15 -0
- package/dist/types/src/utils/agentGenieAPI.d.ts.map +1 -0
- package/dist/types/src/utils/instantLearningAPI.d.ts +13 -0
- package/dist/types/src/utils/instantLearningAPI.d.ts.map +1 -0
- package/dist/utils/agentGenieAPI.js +2 -0
- package/dist/utils/agentGenieAPI.js.map +1 -0
- package/dist/utils/instantLearningAPI.js +2 -0
- package/dist/utils/instantLearningAPI.js.map +1 -0
- package/package.json +1 -1
- package/dist/index.esm.js +0 -382
- package/dist/src/AccordianHeadTest.d.ts +0 -2
- package/dist/src/AccordianHeadTest.d.ts.map +0 -1
- package/dist/src/App.d.ts +0 -4
- package/dist/src/App.d.ts.map +0 -1
- package/dist/src/CodeCitationTest.d.ts +0 -3
- package/dist/src/CodeCitationTest.d.ts.map +0 -1
- package/dist/src/CommonComponents/AccordianHead/AccordianHead.d.ts +0 -9
- package/dist/src/CommonComponents/AccordianHead/AccordianHead.d.ts.map +0 -1
- package/dist/src/CommonComponents/CustomDropdown.d.ts +0 -11
- package/dist/src/CommonComponents/CustomDropdown.d.ts.map +0 -1
- package/dist/src/CommonComponents/GradientSparkleIcon.d.ts +0 -5
- package/dist/src/CommonComponents/GradientSparkleIcon.d.ts.map +0 -1
- package/dist/src/CommonComponents/HelloWorld.d.ts +0 -2
- package/dist/src/CommonComponents/HelloWorld.d.ts.map +0 -1
- package/dist/src/CommonComponents/NoTableData.d.ts +0 -6
- package/dist/src/CommonComponents/NoTableData.d.ts.map +0 -1
- package/dist/src/CommonComponents/Spinner.d.ts +0 -4
- package/dist/src/CommonComponents/Spinner.d.ts.map +0 -1
- package/dist/src/CommonConstants/CommonConstants.d.ts +0 -5
- package/dist/src/CommonConstants/CommonConstants.d.ts.map +0 -1
- package/dist/src/CustomStylesProvider.d.ts +0 -6
- package/dist/src/CustomStylesProvider.d.ts.map +0 -1
- package/dist/src/CustomThemeProvider.d.ts +0 -7
- package/dist/src/CustomThemeProvider.d.ts.map +0 -1
- package/dist/src/GoogleFilePickerDemo.d.ts +0 -2
- package/dist/src/GoogleFilePickerDemo.d.ts.map +0 -1
- package/dist/src/ProjectAccordianTest.d.ts +0 -3
- package/dist/src/ProjectAccordianTest.d.ts.map +0 -1
- package/dist/src/ThinkingBulbIconComponent.d.ts +0 -3
- package/dist/src/ThinkingBulbIconComponent.d.ts.map +0 -1
- package/dist/src/context/DataSelectedContext.d.ts +0 -73
- package/dist/src/context/DataSelectedContext.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/CodeCitation.d.ts +0 -42
- package/dist/src/features/CodeCitation/CodeCitation.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/Accordian.d.ts +0 -10
- package/dist/src/features/CodeCitation/_components/Accordian.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/CodeCitationPopup.d.ts +0 -30
- package/dist/src/features/CodeCitation/_components/CodeCitationPopup.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/CodeCitationsStats.d.ts +0 -12
- package/dist/src/features/CodeCitation/_components/CodeCitationsStats.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/CodeEditor.d.ts +0 -21
- package/dist/src/features/CodeCitation/_components/CodeEditor.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/DescriptionWithToggle.d.ts +0 -5
- package/dist/src/features/CodeCitation/_components/DescriptionWithToggle.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/HighlightedCodeDetails.d.ts +0 -16
- package/dist/src/features/CodeCitation/_components/HighlightedCodeDetails.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/Spinner.d.ts +0 -4
- package/dist/src/features/CodeCitation/_components/Spinner.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/ThemeToggle.d.ts +0 -12
- package/dist/src/features/CodeCitation/_components/ThemeToggle.d.ts.map +0 -1
- package/dist/src/features/CodeCitation/_components/TooltipComponent.d.ts +0 -8
- package/dist/src/features/CodeCitation/_components/TooltipComponent.d.ts.map +0 -1
- package/dist/src/features/DataSelector/DataSelector.d.ts +0 -18
- package/dist/src/features/DataSelector/DataSelector.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/DataSelectionOptionsScreen.d.ts +0 -3
- package/dist/src/features/DataSelector/components/DataSelectionOptionsScreen.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/RLEFDataPointsListInSelectedDataSetCollection.d.ts +0 -3
- package/dist/src/features/DataSelector/components/RLEFDataPointsListInSelectedDataSetCollection.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/RLEFDataSetCollectionsList.d.ts +0 -3
- package/dist/src/features/DataSelector/components/RLEFDataSetCollectionsList.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/RlefDataTabsComponent.d.ts +0 -3
- package/dist/src/features/DataSelector/components/RlefDataTabsComponent.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/RlefHistoricalCopilotData.d.ts +0 -3
- package/dist/src/features/DataSelector/components/RlefHistoricalCopilotData.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/SavedDataSetListScreen.d.ts +0 -13
- package/dist/src/features/DataSelector/components/SavedDataSetListScreen.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/SelectedDataList.d.ts +0 -3
- package/dist/src/features/DataSelector/components/SelectedDataList.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/subcomponents/DataSetElement/DataSetElement.d.ts +0 -11
- package/dist/src/features/DataSelector/components/subcomponents/DataSetElement/DataSetElement.d.ts.map +0 -1
- package/dist/src/features/DataSelector/components/subcomponents/Pagination/Pagination.d.ts +0 -7
- package/dist/src/features/DataSelector/components/subcomponents/Pagination/Pagination.d.ts.map +0 -1
- package/dist/src/features/DataSelector/tables/ShowSelectedDataTable.d.ts +0 -4
- package/dist/src/features/DataSelector/tables/ShowSelectedDataTable.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/InstantLearning.d.ts +0 -55
- package/dist/src/features/InstantLearning/InstantLearning.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/AudioWaveform.d.ts +0 -13
- package/dist/src/features/InstantLearning/_components/AudioWaveform.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/ChatComponent.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/ConflictingLearningWarnCard.d.ts +0 -13
- package/dist/src/features/InstantLearning/_components/ConflictingLearningWarnCard.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/ConflictingLearningWarnCardDB.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/LearningDetailsForm.d.ts +0 -71
- package/dist/src/features/InstantLearning/_components/LearningDetailsForm.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/MessageRendering.d.ts +0 -9
- package/dist/src/features/InstantLearning/_components/MessageRendering.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/MinimizedThinkingSteps.d.ts +0 -3
- package/dist/src/features/InstantLearning/_components/MinimizedThinkingSteps.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/SimilarLearningCard.d.ts +0 -20
- package/dist/src/features/InstantLearning/_components/SimilarLearningCard.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/TemplateRetrievalForm.d.ts +0 -50
- package/dist/src/features/InstantLearning/_components/TemplateRetrievalForm.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/TooltipComponent.d.ts +0 -8
- package/dist/src/features/InstantLearning/_components/TooltipComponent.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/_svg/ArrowDown.d.ts +0 -3
- package/dist/src/features/InstantLearning/_components/_svg/ArrowDown.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/_svg/ArrowIconBlue.d.ts +0 -3
- package/dist/src/features/InstantLearning/_components/_svg/ArrowIconBlue.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/_svg/CompleteIconGreen.d.ts +0 -3
- package/dist/src/features/InstantLearning/_components/_svg/CompleteIconGreen.d.ts.map +0 -1
- package/dist/src/features/InstantLearning/_components/_svg/NewChatIcon.d.ts +0 -3
- package/dist/src/features/InstantLearning/_components/_svg/NewChatIcon.d.ts.map +0 -1
- package/dist/src/features/PdfEditorCitation/PdfEditorCitation.d.ts +0 -19
- package/dist/src/features/PdfEditorCitation/PdfEditorCitation.d.ts.map +0 -1
- package/dist/src/features/PdfEditorCitation/PdfEditorCitationTest/PdfEditorCitationTest.d.ts +0 -2
- package/dist/src/features/PdfEditorCitation/PdfEditorCitationTest/PdfEditorCitationTest.d.ts.map +0 -1
- package/dist/src/features/ProjectAccordion/ProjectAccordion.d.ts +0 -23
- package/dist/src/features/ProjectAccordion/ProjectAccordion.d.ts.map +0 -1
- package/dist/src/features/ProjectAccordion/_components/Markdown.d.ts +0 -5
- package/dist/src/features/ProjectAccordion/_components/Markdown.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromGoogleDrive/SelectDataFromGoogleDrive.d.ts +0 -3
- package/dist/src/features/UploadData/Components/SelectDataFromGoogleDrive/SelectDataFromGoogleDrive.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromGoogleDrive/SelectDataFromGoogleDriveButton.d.ts +0 -9
- package/dist/src/features/UploadData/Components/SelectDataFromGoogleDrive/SelectDataFromGoogleDriveButton.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromLocalSystem/SelectDataFromLocalSystem.d.ts +0 -3
- package/dist/src/features/UploadData/Components/SelectDataFromLocalSystem/SelectDataFromLocalSystem.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromLocalSystem/SelectDataFromLocalSystemButton.d.ts +0 -9
- package/dist/src/features/UploadData/Components/SelectDataFromLocalSystem/SelectDataFromLocalSystemButton.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/Dataset-collection.d.ts +0 -42
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/Dataset-collection.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/DatasetCollectionInfo.d.ts +0 -8
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/DatasetCollectionInfo.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/ProjectTaskSelect.d.ts +0 -13
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/ProjectTaskSelect.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/Tooltip.d.ts +0 -10
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/Tooltip.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/ConfidenceScoreColumnMenu.d.ts +0 -21
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/ConfidenceScoreColumnMenu.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/FilterHandlerUtility.d.ts +0 -33
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/FilterHandlerUtility.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/LabelColumnMenu.d.ts +0 -19
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/LabelColumnMenu.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/TableColumnResetFilterButton.d.ts +0 -19
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/TableColumnResetFilterButton.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/TagColumnMenu.d.ts +0 -17
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dataset-collectionFilterColumnMenuComponents/TagColumnMenu.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dropdown-with-radio.d.ts +0 -26
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/dropdown-with-radio.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/input-label-with-info.d.ts +0 -11
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/Components/input-label-with-info.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/RELFInterfaces.d.ts +0 -3
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/RELFInterfaces.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/SelectDataFromRLEF.d.ts +0 -3
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/SelectDataFromRLEF.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/SelectDataFromRLEFButton.d.ts +0 -9
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/SelectDataFromRLEFButton.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/collections.d.ts +0 -1108
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/collections.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/common.d.ts +0 -57
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/common.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/data.d.ts +0 -643
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/data.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/modelGroup.type.d.ts +0 -24
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/modelGroup.type.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/models.d.ts +0 -283
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/models.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/projects.d.ts +0 -58
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/projects.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/tags.d.ts +0 -20
- package/dist/src/features/UploadData/Components/SelectDataFromRLEF/interfaces/tags.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromSavedDataSet/SelectDataFromSavedDataSet.d.ts +0 -3
- package/dist/src/features/UploadData/Components/SelectDataFromSavedDataSet/SelectDataFromSavedDataSet.d.ts.map +0 -1
- package/dist/src/features/UploadData/Components/SelectDataFromSavedDataSet/SelectDataFromSavedDataSetButton.d.ts +0 -9
- package/dist/src/features/UploadData/Components/SelectDataFromSavedDataSet/SelectDataFromSavedDataSetButton.d.ts.map +0 -1
- package/dist/src/features/UploadData/NotFound.d.ts +0 -4
- package/dist/src/features/UploadData/NotFound.d.ts.map +0 -1
- package/dist/src/features/UploadData/main.d.ts +0 -10
- package/dist/src/features/UploadData/main.d.ts.map +0 -1
- package/dist/src/features/WtaWnta/WtaWnta.d.ts +0 -50
- package/dist/src/features/WtaWnta/WtaWnta.d.ts.map +0 -1
- package/dist/src/features/WtaWnta/_components/AgentDetailsForm.d.ts +0 -42
- package/dist/src/features/WtaWnta/_components/AgentDetailsForm.d.ts.map +0 -1
- package/dist/src/features/WtaWnta/_components/SimilarConflictingCard.d.ts +0 -16
- package/dist/src/features/WtaWnta/_components/SimilarConflictingCard.d.ts.map +0 -1
- package/dist/src/features/WtaWnta/_components/ValidationCard.d.ts +0 -30
- package/dist/src/features/WtaWnta/_components/ValidationCard.d.ts.map +0 -1
- package/dist/src/hooks/useAgentFix.d.ts +0 -15
- package/dist/src/hooks/useAgentFix.d.ts.map +0 -1
- package/dist/src/hooks/useAgentSuggestions.d.ts +0 -20
- package/dist/src/hooks/useAgentSuggestions.d.ts.map +0 -1
- package/dist/src/hooks/useAgentValidation.d.ts +0 -17
- package/dist/src/hooks/useAgentValidation.d.ts.map +0 -1
- package/dist/src/hooks/useDebounce copy.d.ts +0 -2
- package/dist/src/hooks/useDebounce copy.d.ts.map +0 -1
- package/dist/src/hooks/useDebounce.d.ts +0 -2
- package/dist/src/hooks/useDebounce.d.ts.map +0 -1
- package/dist/src/hooks/useExistingAgentCheck.d.ts +0 -28
- package/dist/src/hooks/useExistingAgentCheck.d.ts.map +0 -1
- package/dist/src/hooks/usePromptFix.d.ts +0 -14
- package/dist/src/hooks/usePromptFix.d.ts.map +0 -1
- package/dist/src/hooks/usePromptSuggestions.d.ts +0 -8
- package/dist/src/hooks/usePromptSuggestions.d.ts.map +0 -1
- package/dist/src/hooks/usePromptValidation.d.ts +0 -18
- package/dist/src/hooks/usePromptValidation.d.ts.map +0 -1
- package/dist/src/hooks/useTableHeadCellsCount copy.d.ts +0 -6
- package/dist/src/hooks/useTableHeadCellsCount copy.d.ts.map +0 -1
- package/dist/src/hooks/useTableHeadCellsCount.d.ts +0 -6
- package/dist/src/hooks/useTableHeadCellsCount.d.ts.map +0 -1
- package/dist/src/hooks/useURLQuery copy.d.ts +0 -10
- package/dist/src/hooks/useURLQuery copy.d.ts.map +0 -1
- package/dist/src/hooks/useURLQuery.d.ts +0 -10
- package/dist/src/hooks/useURLQuery.d.ts.map +0 -1
- package/dist/src/index.d.ts +0 -8
- package/dist/src/index.d.ts.map +0 -1
- package/dist/src/methodsToExpose.d.ts +0 -13
- package/dist/src/methodsToExpose.d.ts.map +0 -1
- package/dist/src/routes/ErrorBoundary.d.ts +0 -20
- package/dist/src/routes/ErrorBoundary.d.ts.map +0 -1
- package/dist/src/routes/Routes.d.ts +0 -2
- package/dist/src/routes/Routes.d.ts.map +0 -1
- package/dist/src/service/API.d.ts +0 -6
- package/dist/src/service/API.d.ts.map +0 -1
- package/dist/src/service/DataService.d.ts +0 -73
- package/dist/src/service/DataService.d.ts.map +0 -1
- package/dist/src/service/GoogleFilePickerService.d.ts +0 -61
- package/dist/src/service/GoogleFilePickerService.d.ts.map +0 -1
- package/dist/src/service/InstantLearningService.d.ts +0 -9
- package/dist/src/service/InstantLearningService.d.ts.map +0 -1
- package/dist/src/service/JavascriptFileService.d.ts +0 -4
- package/dist/src/service/JavascriptFileService.d.ts.map +0 -1
- package/dist/src/service/ModelService.d.ts +0 -68
- package/dist/src/service/ModelService.d.ts.map +0 -1
- package/dist/src/service/ProjectService.d.ts +0 -16
- package/dist/src/service/ProjectService.d.ts.map +0 -1
- package/dist/src/service/SavedDataSetService.d.ts +0 -22
- package/dist/src/service/SavedDataSetService.d.ts.map +0 -1
- package/dist/src/service/constants.d.ts +0 -3
- package/dist/src/service/constants.d.ts.map +0 -1
- package/dist/src/service/envHelperService.d.ts +0 -5
- package/dist/src/service/envHelperService.d.ts.map +0 -1
- package/dist/src/service/variableHelperService.d.ts +0 -6
- package/dist/src/service/variableHelperService.d.ts.map +0 -1
- package/dist/src/theme.d.ts +0 -4
- package/dist/src/theme.d.ts.map +0 -1
- package/dist/src/types/GoogleFilePicker/GoogleFilePickerCallbackFunctionType.d.ts +0 -23
- package/dist/src/types/GoogleFilePicker/GoogleFilePickerCallbackFunctionType.d.ts.map +0 -1
- package/dist/src/userProvidedConfig.d.ts +0 -8
- package/dist/src/userProvidedConfig.d.ts.map +0 -1
- package/dist/src/utils/CustomSkeleton.d.ts +0 -3
- package/dist/src/utils/CustomSkeleton.d.ts.map +0 -1
- package/dist/src/utils/SkeletonLoader.d.ts +0 -7
- package/dist/src/utils/SkeletonLoader.d.ts.map +0 -1
- package/dist/src/utils/api.d.ts +0 -2
- package/dist/src/utils/api.d.ts.map +0 -1
- package/dist/src/utils/codeCitations.utils.d.ts +0 -2
- package/dist/src/utils/codeCitations.utils.d.ts.map +0 -1
- package/dist/src/utils/colors.d.ts +0 -5
- package/dist/src/utils/colors.d.ts.map +0 -1
- package/dist/src/utils/date.d.ts +0 -8
- package/dist/src/utils/date.d.ts.map +0 -1
- package/dist/src/utils/helperFunctions.d.ts +0 -2
- package/dist/src/utils/helperFunctions.d.ts.map +0 -1
- package/dist/src/utils/instantLearning.utils.d.ts +0 -2
- package/dist/src/utils/instantLearning.utils.d.ts.map +0 -1
- package/dist/src/utils/payloadParsers.d.ts +0 -16
- package/dist/src/utils/payloadParsers.d.ts.map +0 -1
- package/dist/src/utils/recommendationParser.d.ts +0 -22
- package/dist/src/utils/recommendationParser.d.ts.map +0 -1
- package/dist/src/utils/regexHelperService.d.ts +0 -9
- package/dist/src/utils/regexHelperService.d.ts.map +0 -1
- package/dist/src/utils/urlQueryParamService.d.ts +0 -2
- package/dist/src/utils/urlQueryParamService.d.ts.map +0 -1
- package/dist/src/utils/variableHelperService.d.ts +0 -7
- package/dist/src/utils/variableHelperService.d.ts.map +0 -1
- package/dist/src/utils/variantParser.d.ts +0 -14
- package/dist/src/utils/variantParser.d.ts.map +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as s from"react";import"../../system/esm/GlobalStyles/GlobalStyles.js";import"../../system/esm/borders.js";import"../../../../_virtual/index3.js";import"../../system/esm/display.js";import"../../system/esm/flexbox.js";import"../../system/esm/cssGrid.js";import"../../system/esm/palette.js";import"../../system/esm/positions.js";import"../../system/esm/shadows.js";import"../../system/esm/sizing.js";import"../../system/esm/spacing.js";import"../../system/esm/responsivePropType.js";import"../../system/esm/typography.js";import"../../system/esm/styleFunctionSx/styleFunctionSx.js";import"../../system/esm/getThemeValue.js";import"../../system/esm/Box/Box.js";import"../../system/esm/Box/boxClasses.js";import e from"../../system/esm/useTheme.js";import"react/jsx-runtime";import"../../system/esm/createStyled.js";import"../../system/esm/styled.js";import"../../system/esm/ThemeProvider/ThemeProvider.js";import"../../private-theming/ThemeProvider/ThemeProvider.js";import"../../private-theming/useTheme/ThemeContext.js";import"../../system/esm/RtlProvider/index.js";import"../../system/esm/Container/createContainer.js";import"../../system/esm/Container/Container.js";import"../../system/esm/Container/containerClasses.js";import"../../system/esm/Unstable_Grid/Grid.js";import"../../system/esm/Unstable_Grid/createGrid.js";import"../../system/esm/Unstable_Grid/gridClasses.js";import"../../system/esm/Stack/Stack.js";import"../../system/esm/Stack/createStack.js";import"../../system/esm/Stack/stackClasses.js";import t from"./defaultTheme.js";import m from"./identifier.js";function r(){const r=e(t);return"production"!==process.env.NODE_ENV&&s.useDebugValue(r),r[m]||r}export{r as default};
|
|
1
|
+
import*as s from"react";import"../../../@emotion/styled/dist/emotion-styled.browser.esm.js";import"../../../@emotion/react/dist/emotion-react.browser.esm.js";import"../../styled-engine/StyledEngineProvider/StyledEngineProvider.js";import"../../styled-engine/GlobalStyles/GlobalStyles.js";import"../../system/esm/GlobalStyles/GlobalStyles.js";import"../../system/esm/borders.js";import"../../../../_virtual/index3.js";import"../../system/esm/display.js";import"../../system/esm/flexbox.js";import"../../system/esm/cssGrid.js";import"../../system/esm/palette.js";import"../../system/esm/positions.js";import"../../system/esm/shadows.js";import"../../system/esm/sizing.js";import"../../system/esm/spacing.js";import"../../system/esm/responsivePropType.js";import"../../system/esm/typography.js";import"../../system/esm/styleFunctionSx/styleFunctionSx.js";import"../../system/esm/getThemeValue.js";import"../../system/esm/Box/Box.js";import"../../system/esm/Box/boxClasses.js";import e from"../../system/esm/useTheme.js";import"react/jsx-runtime";import"../../system/esm/createStyled.js";import"../../system/esm/styled.js";import"../../system/esm/ThemeProvider/ThemeProvider.js";import"../../private-theming/ThemeProvider/ThemeProvider.js";import"../../private-theming/useTheme/ThemeContext.js";import"../../system/esm/RtlProvider/index.js";import"../../system/esm/Container/createContainer.js";import"../../system/esm/Container/Container.js";import"../../system/esm/Container/containerClasses.js";import"../../system/esm/Unstable_Grid/Grid.js";import"../../system/esm/Unstable_Grid/createGrid.js";import"../../system/esm/Unstable_Grid/gridClasses.js";import"../../system/esm/Stack/Stack.js";import"../../system/esm/Stack/createStack.js";import"../../system/esm/Stack/stackClasses.js";import t from"./defaultTheme.js";import m from"./identifier.js";function r(){const r=e(t);return"production"!==process.env.NODE_ENV&&s.useDebugValue(r),r[m]||r}export{r as default};
|
|
2
2
|
//# sourceMappingURL=useTheme.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTheme.js","sources":["../../../../../node_modules/@mui/material/styles/useTheme.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}"],"names":["useTheme","theme","useThemeSystem","defaultTheme","process","env","NODE_ENV","React","useDebugValue","THEME_ID"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useTheme.js","sources":["../../../../../node_modules/@mui/material/styles/useTheme.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { useTheme as useThemeSystem } from '@mui/system';\nimport defaultTheme from './defaultTheme';\nimport THEME_ID from './identifier';\nexport default function useTheme() {\n const theme = useThemeSystem(defaultTheme);\n if (process.env.NODE_ENV !== 'production') {\n // eslint-disable-next-line react-hooks/rules-of-hooks\n React.useDebugValue(theme);\n }\n return theme[THEME_ID] || theme;\n}"],"names":["useTheme","theme","useThemeSystem","defaultTheme","process","env","NODE_ENV","React","useDebugValue","THEME_ID"],"mappings":"qzDAMe,SAASA,IACtB,MAAMC,EAAQC,EAAeC,GAK7B,MAJ6B,eAAzBC,QAAQC,IAAIC,UAEdC,EAAMC,cAAcP,GAEfA,EAAMQ,IAAaR,CAC5B"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"react";import e from"../../../../../_virtual/index3.js";import
|
|
1
|
+
import"react";import e from"../../../../../_virtual/index3.js";import"../../../../@emotion/styled/dist/emotion-styled.browser.esm.js";import"../../../../@emotion/react/dist/emotion-react.browser.esm.js";import"../../../styled-engine/StyledEngineProvider/StyledEngineProvider.js";import t from"../../../styled-engine/GlobalStyles/GlobalStyles.js";import o from"../useTheme.js";import{jsx as r}from"react/jsx-runtime";function s({styles:e,themeId:s,defaultTheme:i={}}){const n=o(i),m="function"==typeof e?e(s&&n[s]||n):e;return r(t,{styles:m})}"production"!==process.env.NODE_ENV&&(s.propTypes={defaultTheme:e.object,styles:e.oneOfType([e.array,e.func,e.number,e.object,e.string,e.bool]),themeId:e.string});export{s as default};
|
|
2
2
|
//# sourceMappingURL=GlobalStyles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GlobalStyles.js","sources":["../../../../../../node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { GlobalStyles as MuiGlobalStyles } from '@mui/styled-engine';\nimport useTheme from '../useTheme';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction GlobalStyles({\n styles,\n themeId,\n defaultTheme = {}\n}) {\n const upperTheme = useTheme(defaultTheme);\n const globalStyles = typeof styles === 'function' ? styles(themeId ? upperTheme[themeId] || upperTheme : upperTheme) : styles;\n return /*#__PURE__*/_jsx(MuiGlobalStyles, {\n styles: globalStyles\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? GlobalStyles.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n defaultTheme: PropTypes.object,\n /**\n * @ignore\n */\n styles: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.array, PropTypes.func, PropTypes.number, PropTypes.object, PropTypes.string, PropTypes.bool]),\n /**\n * @ignore\n */\n themeId: PropTypes.string\n} : void 0;\nexport default GlobalStyles;"],"names":["GlobalStyles","styles","themeId","defaultTheme","upperTheme","useTheme","globalStyles","_jsx","MuiGlobalStyles","process","env","NODE_ENV","propTypes","PropTypes","object","oneOfType","array","func","number","string","bool"],"mappings":"
|
|
1
|
+
{"version":3,"file":"GlobalStyles.js","sources":["../../../../../../node_modules/@mui/system/esm/GlobalStyles/GlobalStyles.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { GlobalStyles as MuiGlobalStyles } from '@mui/styled-engine';\nimport useTheme from '../useTheme';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nfunction GlobalStyles({\n styles,\n themeId,\n defaultTheme = {}\n}) {\n const upperTheme = useTheme(defaultTheme);\n const globalStyles = typeof styles === 'function' ? styles(themeId ? upperTheme[themeId] || upperTheme : upperTheme) : styles;\n return /*#__PURE__*/_jsx(MuiGlobalStyles, {\n styles: globalStyles\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? GlobalStyles.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * @ignore\n */\n defaultTheme: PropTypes.object,\n /**\n * @ignore\n */\n styles: PropTypes /* @typescript-to-proptypes-ignore */.oneOfType([PropTypes.array, PropTypes.func, PropTypes.number, PropTypes.object, PropTypes.string, PropTypes.bool]),\n /**\n * @ignore\n */\n themeId: PropTypes.string\n} : void 0;\nexport default GlobalStyles;"],"names":["GlobalStyles","styles","themeId","defaultTheme","upperTheme","useTheme","globalStyles","_jsx","MuiGlobalStyles","process","env","NODE_ENV","propTypes","PropTypes","object","oneOfType","array","func","number","string","bool"],"mappings":"gaAOA,SAASA,GAAaC,OACpBA,EAAMC,QACNA,EAAOC,aACPA,EAAe,CAAE,IAEjB,MAAMC,EAAaC,EAASF,GACtBG,EAAiC,mBAAXL,EAAwBA,EAAOC,GAAUE,EAAWF,IAAyBE,GAAcH,EACvH,OAAoBM,EAAKC,EAAiB,CACxCP,OAAQK,GAEZ,CACyB,eAAzBG,QAAQC,IAAIC,WAA4BX,EAAaY,UAAmC,CAQtFT,aAAcU,EAAUC,OAIxBb,OAAQY,EAAgDE,UAAU,CAACF,EAAUG,MAAOH,EAAUI,KAAMJ,EAAUK,OAAQL,EAAUC,OAAQD,EAAUM,OAAQN,EAAUO,OAIpKlB,QAASW,EAAUM"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import e from"../../../../@babel/runtime/helpers/esm/extends.js";import*as
|
|
1
|
+
import e from"../../../../@babel/runtime/helpers/esm/extends.js";import*as o from"react";import r from"../../../../../_virtual/index3.js";import t from"../../../private-theming/ThemeProvider/ThemeProvider.js";import i from"../../../private-theming/useTheme/useTheme.js";import n from"../../../utils/esm/exactProp/exactProp.js";import"../../../../@emotion/styled/dist/emotion-styled.browser.esm.js";import"../../../../@emotion/react/dist/emotion-react.browser.esm.js";import"../../../styled-engine/StyledEngineProvider/StyledEngineProvider.js";import"../../../styled-engine/GlobalStyles/GlobalStyles.js";import s from"../useThemeWithoutDefault.js";import m from"../RtlProvider/index.js";import p from"../DefaultPropsProvider/DefaultPropsProvider.js";import{jsx as d}from"react/jsx-runtime";import{T as c}from"../../../../@emotion/react/dist/emotion-element-f0de968e.browser.esm.js";const u={};function l(r,t,i,n=!1){return o.useMemo((()=>{const o=r&&t[r]||t;if("function"==typeof i){const s=i(o),m=r?e({},t,{[r]:s}):s;return n?()=>m:m}return e({},t,r?{[r]:i}:i)}),[r,t,i,n])}function h(e){const{children:o,theme:r,themeId:n}=e,h=s(u),a=i()||u;"production"!==process.env.NODE_ENV&&(null===h&&"function"==typeof r||n&&h&&!h[n]&&"function"==typeof r)&&console.error(["MUI: You are providing a theme function prop to the ThemeProvider component:","<ThemeProvider theme={outerTheme => outerTheme} />","","However, no outer theme is present.","Make sure a theme is already injected higher in the React tree or provide a theme object."].join("\n"));const f=l(n,h,r),v=l(n,a,r,!0),j="rtl"===f.direction;return d(t,{theme:v,children:d(c.Provider,{value:f,children:d(m,{value:j,children:d(p,{value:null==f?void 0:f.components,children:o})})})})}"production"!==process.env.NODE_ENV&&(h.propTypes={children:r.node,theme:r.oneOfType([r.func,r.object]).isRequired,themeId:r.string}),"production"!==process.env.NODE_ENV&&"production"!==process.env.NODE_ENV&&(h.propTypes=n(h.propTypes));export{h as default};
|
|
2
2
|
//# sourceMappingURL=ThemeProvider.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ThemeProvider.js","sources":["../../../../../../node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js"],"sourcesContent":["'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { ThemeProvider as MuiThemeProvider, useTheme as usePrivateTheme } from '@mui/private-theming';\nimport exactProp from '@mui/utils/exactProp';\nimport { ThemeContext as StyledEngineThemeContext } from '@mui/styled-engine';\nimport useThemeWithoutDefault from '../useThemeWithoutDefault';\nimport RtlProvider from '../RtlProvider';\nimport DefaultPropsProvider from '../DefaultPropsProvider';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst EMPTY_THEME = {};\nfunction useThemeScoping(themeId, upperTheme, localTheme, isPrivate = false) {\n return React.useMemo(() => {\n const resolvedTheme = themeId ? upperTheme[themeId] || upperTheme : upperTheme;\n if (typeof localTheme === 'function') {\n const mergedTheme = localTheme(resolvedTheme);\n const result = themeId ? _extends({}, upperTheme, {\n [themeId]: mergedTheme\n }) : mergedTheme;\n // must return a function for the private theme to NOT merge with the upper theme.\n // see the test case \"use provided theme from a callback\" in ThemeProvider.test.js\n if (isPrivate) {\n return () => result;\n }\n return result;\n }\n return themeId ? _extends({}, upperTheme, {\n [themeId]: localTheme\n }) : _extends({}, upperTheme, localTheme);\n }, [themeId, upperTheme, localTheme, isPrivate]);\n}\n\n/**\n * This component makes the `theme` available down the React tree.\n * It should preferably be used at **the root of your component tree**.\n *\n * <ThemeProvider theme={theme}> // existing use case\n * <ThemeProvider theme={{ id: theme }}> // theme scoping\n */\nfunction ThemeProvider(props) {\n const {\n children,\n theme: localTheme,\n themeId\n } = props;\n const upperTheme = useThemeWithoutDefault(EMPTY_THEME);\n const upperPrivateTheme = usePrivateTheme() || EMPTY_THEME;\n if (process.env.NODE_ENV !== 'production') {\n if (upperTheme === null && typeof localTheme === 'function' || themeId && upperTheme && !upperTheme[themeId] && typeof localTheme === 'function') {\n console.error(['MUI: You are providing a theme function prop to the ThemeProvider component:', '<ThemeProvider theme={outerTheme => outerTheme} />', '', 'However, no outer theme is present.', 'Make sure a theme is already injected higher in the React tree ' + 'or provide a theme object.'].join('\\n'));\n }\n }\n const engineTheme = useThemeScoping(themeId, upperTheme, localTheme);\n const privateTheme = useThemeScoping(themeId, upperPrivateTheme, localTheme, true);\n const rtlValue = engineTheme.direction === 'rtl';\n return /*#__PURE__*/_jsx(MuiThemeProvider, {\n theme: privateTheme,\n children: /*#__PURE__*/_jsx(StyledEngineThemeContext.Provider, {\n value: engineTheme,\n children: /*#__PURE__*/_jsx(RtlProvider, {\n value: rtlValue,\n children: /*#__PURE__*/_jsx(DefaultPropsProvider, {\n value: engineTheme == null ? void 0 : engineTheme.components,\n children: children\n })\n })\n })\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? ThemeProvider.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Your component tree.\n */\n children: PropTypes.node,\n /**\n * A theme object. You can provide a function to extend the outer theme.\n */\n theme: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).isRequired,\n /**\n * The design system's unique id for getting the corresponded theme when there are multiple design systems.\n */\n themeId: PropTypes.string\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n process.env.NODE_ENV !== \"production\" ? ThemeProvider.propTypes = exactProp(ThemeProvider.propTypes) : void 0;\n}\nexport default ThemeProvider;"],"names":["EMPTY_THEME","useThemeScoping","themeId","upperTheme","localTheme","isPrivate","React","useMemo","resolvedTheme","mergedTheme","result","_extends","ThemeProvider","props","children","theme","useThemeWithoutDefault","upperPrivateTheme","usePrivateTheme","process","env","NODE_ENV","console","error","join","engineTheme","privateTheme","rtlValue","direction","_jsx","MuiThemeProvider","StyledEngineThemeContext","Provider","value","RtlProvider","DefaultPropsProvider","components","propTypes","PropTypes","node","oneOfType","func","object","isRequired","string","exactProp"],"mappings":"
|
|
1
|
+
{"version":3,"file":"ThemeProvider.js","sources":["../../../../../../node_modules/@mui/system/esm/ThemeProvider/ThemeProvider.js"],"sourcesContent":["'use client';\n\nimport _extends from \"@babel/runtime/helpers/esm/extends\";\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport { ThemeProvider as MuiThemeProvider, useTheme as usePrivateTheme } from '@mui/private-theming';\nimport exactProp from '@mui/utils/exactProp';\nimport { ThemeContext as StyledEngineThemeContext } from '@mui/styled-engine';\nimport useThemeWithoutDefault from '../useThemeWithoutDefault';\nimport RtlProvider from '../RtlProvider';\nimport DefaultPropsProvider from '../DefaultPropsProvider';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nconst EMPTY_THEME = {};\nfunction useThemeScoping(themeId, upperTheme, localTheme, isPrivate = false) {\n return React.useMemo(() => {\n const resolvedTheme = themeId ? upperTheme[themeId] || upperTheme : upperTheme;\n if (typeof localTheme === 'function') {\n const mergedTheme = localTheme(resolvedTheme);\n const result = themeId ? _extends({}, upperTheme, {\n [themeId]: mergedTheme\n }) : mergedTheme;\n // must return a function for the private theme to NOT merge with the upper theme.\n // see the test case \"use provided theme from a callback\" in ThemeProvider.test.js\n if (isPrivate) {\n return () => result;\n }\n return result;\n }\n return themeId ? _extends({}, upperTheme, {\n [themeId]: localTheme\n }) : _extends({}, upperTheme, localTheme);\n }, [themeId, upperTheme, localTheme, isPrivate]);\n}\n\n/**\n * This component makes the `theme` available down the React tree.\n * It should preferably be used at **the root of your component tree**.\n *\n * <ThemeProvider theme={theme}> // existing use case\n * <ThemeProvider theme={{ id: theme }}> // theme scoping\n */\nfunction ThemeProvider(props) {\n const {\n children,\n theme: localTheme,\n themeId\n } = props;\n const upperTheme = useThemeWithoutDefault(EMPTY_THEME);\n const upperPrivateTheme = usePrivateTheme() || EMPTY_THEME;\n if (process.env.NODE_ENV !== 'production') {\n if (upperTheme === null && typeof localTheme === 'function' || themeId && upperTheme && !upperTheme[themeId] && typeof localTheme === 'function') {\n console.error(['MUI: You are providing a theme function prop to the ThemeProvider component:', '<ThemeProvider theme={outerTheme => outerTheme} />', '', 'However, no outer theme is present.', 'Make sure a theme is already injected higher in the React tree ' + 'or provide a theme object.'].join('\\n'));\n }\n }\n const engineTheme = useThemeScoping(themeId, upperTheme, localTheme);\n const privateTheme = useThemeScoping(themeId, upperPrivateTheme, localTheme, true);\n const rtlValue = engineTheme.direction === 'rtl';\n return /*#__PURE__*/_jsx(MuiThemeProvider, {\n theme: privateTheme,\n children: /*#__PURE__*/_jsx(StyledEngineThemeContext.Provider, {\n value: engineTheme,\n children: /*#__PURE__*/_jsx(RtlProvider, {\n value: rtlValue,\n children: /*#__PURE__*/_jsx(DefaultPropsProvider, {\n value: engineTheme == null ? void 0 : engineTheme.components,\n children: children\n })\n })\n })\n });\n}\nprocess.env.NODE_ENV !== \"production\" ? ThemeProvider.propTypes /* remove-proptypes */ = {\n // ┌────────────────────────────── Warning ──────────────────────────────┐\n // │ These PropTypes are generated from the TypeScript type definitions. │\n // │ To update them, edit the d.ts file and run `pnpm proptypes`. │\n // └─────────────────────────────────────────────────────────────────────┘\n /**\n * Your component tree.\n */\n children: PropTypes.node,\n /**\n * A theme object. You can provide a function to extend the outer theme.\n */\n theme: PropTypes.oneOfType([PropTypes.func, PropTypes.object]).isRequired,\n /**\n * The design system's unique id for getting the corresponded theme when there are multiple design systems.\n */\n themeId: PropTypes.string\n} : void 0;\nif (process.env.NODE_ENV !== 'production') {\n process.env.NODE_ENV !== \"production\" ? ThemeProvider.propTypes = exactProp(ThemeProvider.propTypes) : void 0;\n}\nexport default ThemeProvider;"],"names":["EMPTY_THEME","useThemeScoping","themeId","upperTheme","localTheme","isPrivate","React","useMemo","resolvedTheme","mergedTheme","result","_extends","ThemeProvider","props","children","theme","useThemeWithoutDefault","upperPrivateTheme","usePrivateTheme","process","env","NODE_ENV","console","error","join","engineTheme","privateTheme","rtlValue","direction","_jsx","MuiThemeProvider","StyledEngineThemeContext","Provider","value","RtlProvider","DefaultPropsProvider","components","propTypes","PropTypes","node","oneOfType","func","object","isRequired","string","exactProp"],"mappings":"i3BAYA,MAAMA,EAAc,CAAA,EACpB,SAASC,EAAgBC,EAASC,EAAYC,EAAYC,GAAY,GACpE,OAAOC,EAAMC,SAAQ,KACnB,MAAMC,EAAgBN,GAAUC,EAAWD,IAAyBC,EACpE,GAA0B,mBAAfC,EAA2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/runtime/helpers/esm/extends.js";import o from"../../../../@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js";import t from"../../../utils/esm/formatMuiErrorMessage/formatMuiErrorMessage.js";import*as r from"react";import s from"../../../../../_virtual/index3.js";import n from"../../../utils/esm/deepmerge/deepmerge.js";import"../../../private-theming/ThemeProvider/ThemeProvider.js";import
|
|
1
|
+
import e from"../../../../@babel/runtime/helpers/esm/extends.js";import o from"../../../../@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js";import t from"../../../utils/esm/formatMuiErrorMessage/formatMuiErrorMessage.js";import*as r from"react";import s from"../../../../../_virtual/index3.js";import n from"../../../utils/esm/deepmerge/deepmerge.js";import"../../../../@emotion/styled/dist/emotion-styled.browser.esm.js";import"../../../../@emotion/react/dist/emotion-react.browser.esm.js";import"../../../styled-engine/StyledEngineProvider/StyledEngineProvider.js";import i from"../../../styled-engine/GlobalStyles/GlobalStyles.js";import"../../../private-theming/ThemeProvider/ThemeProvider.js";import m from"../../../private-theming/useTheme/useTheme.js";import c from"../ThemeProvider/ThemeProvider.js";import l,{DEFAULT_ATTRIBUTE as d,DEFAULT_MODE_STORAGE_KEY as a,DEFAULT_COLOR_SCHEME_STORAGE_KEY as h}from"../InitColorSchemeScript/InitColorSchemeScript.js";import u from"./useCurrentColorScheme.js";import{jsxs as S,jsx as p}from"react/jsx-runtime";const f=["colorSchemes","components","generateCssVars","cssVarPrefix"],g="*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}";function y(y){const{themeId:C,theme:b={},attribute:v=d,modeStorageKey:j=a,colorSchemeStorageKey:E=h,defaultMode:x="light",defaultColorScheme:M,disableTransitionOnChange:T=!1,resolveTheme:w,excludeVariablesFromRoot:N}=y;(!b.colorSchemes||"string"==typeof M&&!b.colorSchemes[M]||"object"==typeof M&&!b.colorSchemes[null==M?void 0:M.light]||"object"==typeof M&&!b.colorSchemes[null==M?void 0:M.dark])&&console.error(`MUI: \`${M}\` does not exist in \`theme.colorSchemes\`.`);const P=r.createContext(void 0);"production"!==process.env.NODE_ENV&&(P.displayName="ColorSchemeContext");function k(t){const{children:s,theme:l=b,modeStorageKey:d=j,colorSchemeStorageKey:a=E,attribute:h=v,defaultMode:y=x,defaultColorScheme:k=M,disableTransitionOnChange:V=T,storageWindow:$=("undefined"==typeof window?void 0:window),documentNode:K=("undefined"==typeof document?void 0:document),colorSchemeNode:O=("undefined"==typeof document?void 0:document.documentElement),colorSchemeSelector:I=":root",disableNestedContext:D=!1,disableStyleSheetGeneration:G=!1}=t,W=r.useRef(!1),_=m(),F=r.useContext(P),L=!!F&&!D,R=l[C],U=R||l,{colorSchemes:z={},components:A={},generateCssVars:q=()=>({vars:{},css:{}}),cssVarPrefix:B}=U,H=o(U,f),J=Object.keys(z),Q="string"==typeof k?k:k.light,X="string"==typeof k?k:k.dark,{mode:Y,setMode:Z,systemMode:ee,lightColorScheme:oe,darkColorScheme:te,colorScheme:re,setColorScheme:se}=u({supportedColorSchemes:J,defaultLightColorScheme:Q,defaultDarkColorScheme:X,modeStorageKey:d,colorSchemeStorageKey:a,defaultMode:y,storageWindow:$});let ne=Y,ie=re;L&&(ne=F.mode,ie=F.colorScheme);const me=ie||("dark"===(ne||("system"===y?x:y))?X:Q),{css:ce,vars:le}=q(),de=e({},H,{components:A,colorSchemes:z,cssVarPrefix:B,vars:le,getColorSchemeSelector:e=>`[${h}="${e}"] &`}),ae={},he={};Object.entries(z).forEach((([o,t])=>{const{css:r,vars:s}=q(o);de.vars=n(de.vars,s),o===me&&(Object.keys(t).forEach((o=>{t[o]&&"object"==typeof t[o]?de[o]=e({},de[o],t[o]):de[o]=t[o]})),de.palette&&(de.palette.colorScheme=o));if(o===("string"==typeof k?k:"dark"===y?k.dark:k.light)){if(N){const e={};N(B).forEach((o=>{e[o]=r[o],delete r[o]})),ae[`[${h}="${o}"]`]=e}ae[`${I}, [${h}="${o}"]`]=r}else he[`${":root"===I?"":I}[${h}="${o}"]`]=r})),de.vars=n(de.vars,le),r.useEffect((()=>{ie&&O&&O.setAttribute(h,ie)}),[ie,h,O]),r.useEffect((()=>{let e;if(V&&W.current&&K){const o=K.createElement("style");o.appendChild(K.createTextNode(g)),K.head.appendChild(o),window.getComputedStyle(K.body),e=setTimeout((()=>{K.head.removeChild(o)}),1)}return()=>{clearTimeout(e)}}),[ie,V,K]),r.useEffect((()=>(W.current=!0,()=>{W.current=!1})),[]);const ue=r.useMemo((()=>({allColorSchemes:J,colorScheme:ie,darkColorScheme:te,lightColorScheme:oe,mode:ne,setColorScheme:se,setMode:Z,systemMode:ee})),[J,ie,te,oe,ne,se,Z,ee]);let Se=!0;(G||L&&(null==_?void 0:_.cssVarPrefix)===B)&&(Se=!1);const pe=S(r.Fragment,{children:[Se&&S(r.Fragment,{children:[p(i,{styles:{[I]:ce}}),p(i,{styles:ae}),p(i,{styles:he})]}),p(c,{themeId:R?C:void 0,theme:w?w(de):de,children:s})]});return L?pe:p(P.Provider,{value:ue,children:pe})}"production"!==process.env.NODE_ENV&&(k.propTypes={attribute:s.string,children:s.node,colorSchemeNode:s.any,colorSchemeSelector:s.string,colorSchemeStorageKey:s.string,defaultColorScheme:s.oneOfType([s.string,s.object]),defaultMode:s.string,disableNestedContext:s.bool,disableStyleSheetGeneration:s.bool,disableTransitionOnChange:s.bool,documentNode:s.any,modeStorageKey:s.string,storageWindow:s.any,theme:s.object});const V="string"==typeof M?M:M.light,$="string"==typeof M?M:M.dark;return{CssVarsProvider:k,useColorScheme:()=>{const e=r.useContext(P);if(!e)throw new Error("production"!==process.env.NODE_ENV?"MUI: `useColorScheme` must be called under <CssVarsProvider />":t(19));return e},getInitColorSchemeScript:o=>l(e({attribute:v,colorSchemeStorageKey:E,defaultMode:x,defaultLightColorScheme:V,defaultDarkColorScheme:$,modeStorageKey:j},o))}}export{g as DISABLE_CSS_TRANSITION,y as default};
|
|
2
2
|
//# sourceMappingURL=createCssVarsProvider.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createCssVarsProvider.js","sources":["../../../../../../node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"colorSchemes\", \"components\", \"generateCssVars\", \"cssVarPrefix\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport { GlobalStyles } from '@mui/styled-engine';\nimport { useTheme as muiUseTheme } from '@mui/private-theming';\nimport ThemeProvider from '../ThemeProvider';\nimport InitColorSchemeScript, { DEFAULT_ATTRIBUTE, DEFAULT_COLOR_SCHEME_STORAGE_KEY, DEFAULT_MODE_STORAGE_KEY } from '../InitColorSchemeScript/InitColorSchemeScript';\nimport useCurrentColorScheme from './useCurrentColorScheme';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const DISABLE_CSS_TRANSITION = '*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}';\nexport default function createCssVarsProvider(options) {\n const {\n themeId,\n /**\n * This `theme` object needs to follow a certain structure to\n * be used correctly by the finel `CssVarsProvider`. It should have a\n * `colorSchemes` key with the light and dark (and any other) palette.\n * It should also ideally have a vars object created using `prepareCssVars`.\n */\n theme: defaultTheme = {},\n attribute: defaultAttribute = DEFAULT_ATTRIBUTE,\n modeStorageKey: defaultModeStorageKey = DEFAULT_MODE_STORAGE_KEY,\n colorSchemeStorageKey: defaultColorSchemeStorageKey = DEFAULT_COLOR_SCHEME_STORAGE_KEY,\n defaultMode: designSystemMode = 'light',\n defaultColorScheme: designSystemColorScheme,\n disableTransitionOnChange: designSystemTransitionOnChange = false,\n resolveTheme,\n excludeVariablesFromRoot\n } = options;\n if (!defaultTheme.colorSchemes || typeof designSystemColorScheme === 'string' && !defaultTheme.colorSchemes[designSystemColorScheme] || typeof designSystemColorScheme === 'object' && !defaultTheme.colorSchemes[designSystemColorScheme == null ? void 0 : designSystemColorScheme.light] || typeof designSystemColorScheme === 'object' && !defaultTheme.colorSchemes[designSystemColorScheme == null ? void 0 : designSystemColorScheme.dark]) {\n console.error(`MUI: \\`${designSystemColorScheme}\\` does not exist in \\`theme.colorSchemes\\`.`);\n }\n const ColorSchemeContext = /*#__PURE__*/React.createContext(undefined);\n if (process.env.NODE_ENV !== 'production') {\n ColorSchemeContext.displayName = 'ColorSchemeContext';\n }\n const useColorScheme = () => {\n const value = React.useContext(ColorSchemeContext);\n if (!value) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`useColorScheme\\` must be called under <CssVarsProvider />` : _formatMuiErrorMessage(19));\n }\n return value;\n };\n function CssVarsProvider(props) {\n const {\n children,\n theme: themeProp = defaultTheme,\n modeStorageKey = defaultModeStorageKey,\n colorSchemeStorageKey = defaultColorSchemeStorageKey,\n attribute = defaultAttribute,\n defaultMode = designSystemMode,\n defaultColorScheme = designSystemColorScheme,\n disableTransitionOnChange = designSystemTransitionOnChange,\n storageWindow = typeof window === 'undefined' ? undefined : window,\n documentNode = typeof document === 'undefined' ? undefined : document,\n colorSchemeNode = typeof document === 'undefined' ? undefined : document.documentElement,\n colorSchemeSelector = ':root',\n disableNestedContext = false,\n disableStyleSheetGeneration = false\n } = props;\n const hasMounted = React.useRef(false);\n const upperTheme = muiUseTheme();\n const ctx = React.useContext(ColorSchemeContext);\n const nested = !!ctx && !disableNestedContext;\n const scopedTheme = themeProp[themeId];\n const _ref = scopedTheme || themeProp,\n {\n colorSchemes = {},\n components = {},\n generateCssVars = () => ({\n vars: {},\n css: {}\n }),\n cssVarPrefix\n } = _ref,\n restThemeProp = _objectWithoutPropertiesLoose(_ref, _excluded);\n const allColorSchemes = Object.keys(colorSchemes);\n const defaultLightColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.light;\n const defaultDarkColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.dark;\n\n // 1. Get the data about the `mode`, `colorScheme`, and setter functions.\n const {\n mode: stateMode,\n setMode,\n systemMode,\n lightColorScheme,\n darkColorScheme,\n colorScheme: stateColorScheme,\n setColorScheme\n } = useCurrentColorScheme({\n supportedColorSchemes: allColorSchemes,\n defaultLightColorScheme,\n defaultDarkColorScheme,\n modeStorageKey,\n colorSchemeStorageKey,\n defaultMode,\n storageWindow\n });\n let mode = stateMode;\n let colorScheme = stateColorScheme;\n if (nested) {\n mode = ctx.mode;\n colorScheme = ctx.colorScheme;\n }\n const calculatedMode = (() => {\n if (mode) {\n return mode;\n }\n // This scope occurs on the server\n if (defaultMode === 'system') {\n return designSystemMode;\n }\n return defaultMode;\n })();\n const calculatedColorScheme = (() => {\n if (!colorScheme) {\n // This scope occurs on the server\n if (calculatedMode === 'dark') {\n return defaultDarkColorScheme;\n }\n // use light color scheme, if default mode is 'light' | 'system'\n return defaultLightColorScheme;\n }\n return colorScheme;\n })();\n\n // 2. Create CSS variables and store them in objects (to be generated in stylesheets in the final step)\n const {\n css: rootCss,\n vars: rootVars\n } = generateCssVars();\n\n // 3. Start composing the theme object\n const theme = _extends({}, restThemeProp, {\n components,\n colorSchemes,\n cssVarPrefix,\n vars: rootVars,\n getColorSchemeSelector: targetColorScheme => `[${attribute}=\"${targetColorScheme}\"] &`\n });\n\n // 4. Create color CSS variables and store them in objects (to be generated in stylesheets in the final step)\n // The default color scheme stylesheet is constructed to have the least CSS specificity.\n // The other color schemes uses selector, default as data attribute, to increase the CSS specificity so that they can override the default color scheme stylesheet.\n const defaultColorSchemeStyleSheet = {};\n const otherColorSchemesStyleSheet = {};\n Object.entries(colorSchemes).forEach(([key, scheme]) => {\n const {\n css,\n vars\n } = generateCssVars(key);\n theme.vars = deepmerge(theme.vars, vars);\n if (key === calculatedColorScheme) {\n // 4.1 Merge the selected color scheme to the theme\n Object.keys(scheme).forEach(schemeKey => {\n if (scheme[schemeKey] && typeof scheme[schemeKey] === 'object') {\n // shallow merge the 1st level structure of the theme.\n theme[schemeKey] = _extends({}, theme[schemeKey], scheme[schemeKey]);\n } else {\n theme[schemeKey] = scheme[schemeKey];\n }\n });\n if (theme.palette) {\n theme.palette.colorScheme = key;\n }\n }\n const resolvedDefaultColorScheme = (() => {\n if (typeof defaultColorScheme === 'string') {\n return defaultColorScheme;\n }\n if (defaultMode === 'dark') {\n return defaultColorScheme.dark;\n }\n return defaultColorScheme.light;\n })();\n if (key === resolvedDefaultColorScheme) {\n if (excludeVariablesFromRoot) {\n const excludedVariables = {};\n excludeVariablesFromRoot(cssVarPrefix).forEach(cssVar => {\n excludedVariables[cssVar] = css[cssVar];\n delete css[cssVar];\n });\n defaultColorSchemeStyleSheet[`[${attribute}=\"${key}\"]`] = excludedVariables;\n }\n defaultColorSchemeStyleSheet[`${colorSchemeSelector}, [${attribute}=\"${key}\"]`] = css;\n } else {\n otherColorSchemesStyleSheet[`${colorSchemeSelector === ':root' ? '' : colorSchemeSelector}[${attribute}=\"${key}\"]`] = css;\n }\n });\n theme.vars = deepmerge(theme.vars, rootVars);\n\n // 5. Declaring effects\n // 5.1 Updates the selector value to use the current color scheme which tells CSS to use the proper stylesheet.\n React.useEffect(() => {\n if (colorScheme && colorSchemeNode) {\n // attaches attribute to <html> because the css variables are attached to :root (html)\n colorSchemeNode.setAttribute(attribute, colorScheme);\n }\n }, [colorScheme, attribute, colorSchemeNode]);\n\n // 5.2 Remove the CSS transition when color scheme changes to create instant experience.\n // credit: https://github.com/pacocoursey/next-themes/blob/b5c2bad50de2d61ad7b52a9c5cdc801a78507d7a/index.tsx#L313\n React.useEffect(() => {\n let timer;\n if (disableTransitionOnChange && hasMounted.current && documentNode) {\n const css = documentNode.createElement('style');\n css.appendChild(documentNode.createTextNode(DISABLE_CSS_TRANSITION));\n documentNode.head.appendChild(css);\n\n // Force browser repaint\n (() => window.getComputedStyle(documentNode.body))();\n timer = setTimeout(() => {\n documentNode.head.removeChild(css);\n }, 1);\n }\n return () => {\n clearTimeout(timer);\n };\n }, [colorScheme, disableTransitionOnChange, documentNode]);\n React.useEffect(() => {\n hasMounted.current = true;\n return () => {\n hasMounted.current = false;\n };\n }, []);\n const contextValue = React.useMemo(() => ({\n allColorSchemes,\n colorScheme,\n darkColorScheme,\n lightColorScheme,\n mode,\n setColorScheme,\n setMode,\n systemMode\n }), [allColorSchemes, colorScheme, darkColorScheme, lightColorScheme, mode, setColorScheme, setMode, systemMode]);\n let shouldGenerateStyleSheet = true;\n if (disableStyleSheetGeneration || nested && (upperTheme == null ? void 0 : upperTheme.cssVarPrefix) === cssVarPrefix) {\n shouldGenerateStyleSheet = false;\n }\n const element = /*#__PURE__*/_jsxs(React.Fragment, {\n children: [shouldGenerateStyleSheet && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(GlobalStyles, {\n styles: {\n [colorSchemeSelector]: rootCss\n }\n }), /*#__PURE__*/_jsx(GlobalStyles, {\n styles: defaultColorSchemeStyleSheet\n }), /*#__PURE__*/_jsx(GlobalStyles, {\n styles: otherColorSchemesStyleSheet\n })]\n }), /*#__PURE__*/_jsx(ThemeProvider, {\n themeId: scopedTheme ? themeId : undefined,\n theme: resolveTheme ? resolveTheme(theme) : theme,\n children: children\n })]\n });\n if (nested) {\n return element;\n }\n return /*#__PURE__*/_jsx(ColorSchemeContext.Provider, {\n value: contextValue,\n children: element\n });\n }\n process.env.NODE_ENV !== \"production\" ? CssVarsProvider.propTypes = {\n /**\n * The body attribute name to attach colorScheme.\n */\n attribute: PropTypes.string,\n /**\n * The component tree.\n */\n children: PropTypes.node,\n /**\n * The node used to attach the color-scheme attribute\n */\n colorSchemeNode: PropTypes.any,\n /**\n * The CSS selector for attaching the generated custom properties\n */\n colorSchemeSelector: PropTypes.string,\n /**\n * localStorage key used to store `colorScheme`\n */\n colorSchemeStorageKey: PropTypes.string,\n /**\n * The initial color scheme used.\n */\n defaultColorScheme: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),\n /**\n * The initial mode used.\n */\n defaultMode: PropTypes.string,\n /**\n * If `true`, the provider creates its own context and generate stylesheet as if it is a root `CssVarsProvider`.\n */\n disableNestedContext: PropTypes.bool,\n /**\n * If `true`, the style sheet won't be generated.\n *\n * This is useful for controlling nested CssVarsProvider behavior.\n */\n disableStyleSheetGeneration: PropTypes.bool,\n /**\n * Disable CSS transitions when switching between modes or color schemes.\n */\n disableTransitionOnChange: PropTypes.bool,\n /**\n * The document to attach the attribute to.\n */\n documentNode: PropTypes.any,\n /**\n * The key in the local storage used to store current color scheme.\n */\n modeStorageKey: PropTypes.string,\n /**\n * The window that attaches the 'storage' event listener.\n * @default window\n */\n storageWindow: PropTypes.any,\n /**\n * The calculated theme object that will be passed through context.\n */\n theme: PropTypes.object\n } : void 0;\n const defaultLightColorScheme = typeof designSystemColorScheme === 'string' ? designSystemColorScheme : designSystemColorScheme.light;\n const defaultDarkColorScheme = typeof designSystemColorScheme === 'string' ? designSystemColorScheme : designSystemColorScheme.dark;\n const getInitColorSchemeScript = params => InitColorSchemeScript(_extends({\n attribute: defaultAttribute,\n colorSchemeStorageKey: defaultColorSchemeStorageKey,\n defaultMode: designSystemMode,\n defaultLightColorScheme,\n defaultDarkColorScheme,\n modeStorageKey: defaultModeStorageKey\n }, params));\n return {\n CssVarsProvider,\n useColorScheme,\n getInitColorSchemeScript\n };\n}"],"names":["_excluded","DISABLE_CSS_TRANSITION","createCssVarsProvider","options","themeId","theme","defaultTheme","attribute","defaultAttribute","DEFAULT_ATTRIBUTE","modeStorageKey","defaultModeStorageKey","DEFAULT_MODE_STORAGE_KEY","colorSchemeStorageKey","defaultColorSchemeStorageKey","DEFAULT_COLOR_SCHEME_STORAGE_KEY","defaultMode","designSystemMode","defaultColorScheme","designSystemColorScheme","disableTransitionOnChange","designSystemTransitionOnChange","resolveTheme","excludeVariablesFromRoot","colorSchemes","light","dark","console","error","ColorSchemeContext","React","createContext","undefined","process","env","NODE_ENV","displayName","CssVarsProvider","props","children","themeProp","storageWindow","window","documentNode","document","colorSchemeNode","documentElement","colorSchemeSelector","disableNestedContext","disableStyleSheetGeneration","hasMounted","useRef","upperTheme","muiUseTheme","ctx","useContext","nested","scopedTheme","_ref","components","generateCssVars","vars","css","cssVarPrefix","restThemeProp","_objectWithoutPropertiesLoose","allColorSchemes","Object","keys","defaultLightColorScheme","defaultDarkColorScheme","mode","stateMode","setMode","systemMode","lightColorScheme","darkColorScheme","colorScheme","stateColorScheme","setColorScheme","useCurrentColorScheme","supportedColorSchemes","calculatedColorScheme","rootCss","rootVars","_extends","getColorSchemeSelector","targetColorScheme","defaultColorSchemeStyleSheet","otherColorSchemesStyleSheet","entries","forEach","key","scheme","deepmerge","schemeKey","palette","excludedVariables","cssVar","useEffect","setAttribute","timer","current","createElement","appendChild","createTextNode","head","getComputedStyle","body","setTimeout","removeChild","clearTimeout","contextValue","useMemo","shouldGenerateStyleSheet","element","_jsxs","Fragment","_jsx","GlobalStyles","styles","ThemeProvider","Provider","value","propTypes","PropTypes","string","node","any","oneOfType","object","bool","useColorScheme","Error","_formatMuiErrorMessage","getInitColorSchemeScript","params","InitColorSchemeScript"],"mappings":"o1BAGA,MAAMA,EAAY,CAAC,eAAgB,aAAc,kBAAmB,gBAWvDC,EAAyB,2JACvB,SAASC,EAAsBC,GAC5C,MAAMC,QACJA,EAOAC,MAAOC,EAAe,CAAE,EACxBC,UAAWC,EAAmBC,EAC9BC,eAAgBC,EAAwBC,EACxCC,sBAAuBC,EAA+BC,EACtDC,YAAaC,EAAmB,QAChCC,mBAAoBC,EACpBC,0BAA2BC,GAAiC,EAAKC,aACjEA,EAAYC,yBACZA,GACEpB,IACCG,EAAakB,cAAmD,iBAA5BL,IAAyCb,EAAakB,aAAaL,IAA+D,iBAA5BA,IAAyCb,EAAakB,aAAwC,MAA3BL,OAAkC,EAASA,EAAwBM,QAA6C,iBAA5BN,IAAyCb,EA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EAAmB6F,SAAU,CACpDC,MAAOX,GACPzE,SAAU4E,IAEb,CACwB,eAAzBlF,QAAQC,IAAIC,WAA4BE,EAAgBuF,UAAY,CAIlErH,UAAWsH,EAAUC,OAIrBvF,SAAUsF,EAAUE,KAIpBlF,gBAAiBgF,EAAUG,IAI3BjF,oBAAqB8E,EAAUC,OAI/BjH,sBAAuBgH,EAAUC,OAIjC5G,mBAAoB2G,EAAUI,UAAU,CAACJ,EAAUC,OAAQD,EAAUK,SAIrElH,YAAa6G,EAAUC,OAIvB9E,qBAAsB6E,EAAUM,KAMhClF,4BAA6B4E,EAAUM,KAIvC/G,0BAA2ByG,EAAUM,KAIrCxF,aAAckF,EAAUG,IAIxBtH,eAAgBmH,EAAUC,OAK1BrF,cAAeoF,EAAUG,IAIzB3H,MAAOwH,EAAUK,SAEnB,MAAM7D,EAA6D,iBAA5BlD,EAAuCA,EAA0BA,EAAwBM,MAC1H6C,EAA4D,iBAA5BnD,EAAuCA,EAA0BA,EAAwBO,KAS/H,MAAO,CACLW,kBACA+F,eA7SqB,KACrB,MAAMT,EAAQ7F,EAAMyB,WAAW1B,GAC/B,IAAK8F,EACH,MAAM,IAAIU,MAA+B,eAAzBpG,QAAQC,IAAIC,SAA4B,iEAAqEmG,EAAuB,KAEtJ,OAAOX,CAAK,EAySZY,yBAX+BC,GAAUC,EAAsBpD,EAAS,CACxE9E,UAAWC,EACXK,sBAAuBC,EACvBE,YAAaC,EACboD,0BACAC,yBACA5D,eAAgBC,GACf6H,IAML"}
|
|
1
|
+
{"version":3,"file":"createCssVarsProvider.js","sources":["../../../../../../node_modules/@mui/system/esm/cssVars/createCssVarsProvider.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nimport _formatMuiErrorMessage from \"@mui/utils/formatMuiErrorMessage\";\nconst _excluded = [\"colorSchemes\", \"components\", \"generateCssVars\", \"cssVarPrefix\"];\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport deepmerge from '@mui/utils/deepmerge';\nimport { GlobalStyles } from '@mui/styled-engine';\nimport { useTheme as muiUseTheme } from '@mui/private-theming';\nimport ThemeProvider from '../ThemeProvider';\nimport InitColorSchemeScript, { DEFAULT_ATTRIBUTE, DEFAULT_COLOR_SCHEME_STORAGE_KEY, DEFAULT_MODE_STORAGE_KEY } from '../InitColorSchemeScript/InitColorSchemeScript';\nimport useCurrentColorScheme from './useCurrentColorScheme';\nimport { jsx as _jsx } from \"react/jsx-runtime\";\nimport { jsxs as _jsxs } from \"react/jsx-runtime\";\nexport const DISABLE_CSS_TRANSITION = '*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}';\nexport default function createCssVarsProvider(options) {\n const {\n themeId,\n /**\n * This `theme` object needs to follow a certain structure to\n * be used correctly by the finel `CssVarsProvider`. It should have a\n * `colorSchemes` key with the light and dark (and any other) palette.\n * It should also ideally have a vars object created using `prepareCssVars`.\n */\n theme: defaultTheme = {},\n attribute: defaultAttribute = DEFAULT_ATTRIBUTE,\n modeStorageKey: defaultModeStorageKey = DEFAULT_MODE_STORAGE_KEY,\n colorSchemeStorageKey: defaultColorSchemeStorageKey = DEFAULT_COLOR_SCHEME_STORAGE_KEY,\n defaultMode: designSystemMode = 'light',\n defaultColorScheme: designSystemColorScheme,\n disableTransitionOnChange: designSystemTransitionOnChange = false,\n resolveTheme,\n excludeVariablesFromRoot\n } = options;\n if (!defaultTheme.colorSchemes || typeof designSystemColorScheme === 'string' && !defaultTheme.colorSchemes[designSystemColorScheme] || typeof designSystemColorScheme === 'object' && !defaultTheme.colorSchemes[designSystemColorScheme == null ? void 0 : designSystemColorScheme.light] || typeof designSystemColorScheme === 'object' && !defaultTheme.colorSchemes[designSystemColorScheme == null ? void 0 : designSystemColorScheme.dark]) {\n console.error(`MUI: \\`${designSystemColorScheme}\\` does not exist in \\`theme.colorSchemes\\`.`);\n }\n const ColorSchemeContext = /*#__PURE__*/React.createContext(undefined);\n if (process.env.NODE_ENV !== 'production') {\n ColorSchemeContext.displayName = 'ColorSchemeContext';\n }\n const useColorScheme = () => {\n const value = React.useContext(ColorSchemeContext);\n if (!value) {\n throw new Error(process.env.NODE_ENV !== \"production\" ? `MUI: \\`useColorScheme\\` must be called under <CssVarsProvider />` : _formatMuiErrorMessage(19));\n }\n return value;\n };\n function CssVarsProvider(props) {\n const {\n children,\n theme: themeProp = defaultTheme,\n modeStorageKey = defaultModeStorageKey,\n colorSchemeStorageKey = defaultColorSchemeStorageKey,\n attribute = defaultAttribute,\n defaultMode = designSystemMode,\n defaultColorScheme = designSystemColorScheme,\n disableTransitionOnChange = designSystemTransitionOnChange,\n storageWindow = typeof window === 'undefined' ? undefined : window,\n documentNode = typeof document === 'undefined' ? undefined : document,\n colorSchemeNode = typeof document === 'undefined' ? undefined : document.documentElement,\n colorSchemeSelector = ':root',\n disableNestedContext = false,\n disableStyleSheetGeneration = false\n } = props;\n const hasMounted = React.useRef(false);\n const upperTheme = muiUseTheme();\n const ctx = React.useContext(ColorSchemeContext);\n const nested = !!ctx && !disableNestedContext;\n const scopedTheme = themeProp[themeId];\n const _ref = scopedTheme || themeProp,\n {\n colorSchemes = {},\n components = {},\n generateCssVars = () => ({\n vars: {},\n css: {}\n }),\n cssVarPrefix\n } = _ref,\n restThemeProp = _objectWithoutPropertiesLoose(_ref, _excluded);\n const allColorSchemes = Object.keys(colorSchemes);\n const defaultLightColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.light;\n const defaultDarkColorScheme = typeof defaultColorScheme === 'string' ? defaultColorScheme : defaultColorScheme.dark;\n\n // 1. Get the data about the `mode`, `colorScheme`, and setter functions.\n const {\n mode: stateMode,\n setMode,\n systemMode,\n lightColorScheme,\n darkColorScheme,\n colorScheme: stateColorScheme,\n setColorScheme\n } = useCurrentColorScheme({\n supportedColorSchemes: allColorSchemes,\n defaultLightColorScheme,\n defaultDarkColorScheme,\n modeStorageKey,\n colorSchemeStorageKey,\n defaultMode,\n storageWindow\n });\n let mode = stateMode;\n let colorScheme = stateColorScheme;\n if (nested) {\n mode = ctx.mode;\n colorScheme = ctx.colorScheme;\n }\n const calculatedMode = (() => {\n if (mode) {\n return mode;\n }\n // This scope occurs on the server\n if (defaultMode === 'system') {\n return designSystemMode;\n }\n return defaultMode;\n })();\n const calculatedColorScheme = (() => {\n if (!colorScheme) {\n // This scope occurs on the server\n if (calculatedMode === 'dark') {\n return defaultDarkColorScheme;\n }\n // use light color scheme, if default mode is 'light' | 'system'\n return defaultLightColorScheme;\n }\n return colorScheme;\n })();\n\n // 2. Create CSS variables and store them in objects (to be generated in stylesheets in the final step)\n const {\n css: rootCss,\n vars: rootVars\n } = generateCssVars();\n\n // 3. Start composing the theme object\n const theme = _extends({}, restThemeProp, {\n components,\n colorSchemes,\n cssVarPrefix,\n vars: rootVars,\n getColorSchemeSelector: targetColorScheme => `[${attribute}=\"${targetColorScheme}\"] &`\n });\n\n // 4. Create color CSS variables and store them in objects (to be generated in stylesheets in the final step)\n // The default color scheme stylesheet is constructed to have the least CSS specificity.\n // The other color schemes uses selector, default as data attribute, to increase the CSS specificity so that they can override the default color scheme stylesheet.\n const defaultColorSchemeStyleSheet = {};\n const otherColorSchemesStyleSheet = {};\n Object.entries(colorSchemes).forEach(([key, scheme]) => {\n const {\n css,\n vars\n } = generateCssVars(key);\n theme.vars = deepmerge(theme.vars, vars);\n if (key === calculatedColorScheme) {\n // 4.1 Merge the selected color scheme to the theme\n Object.keys(scheme).forEach(schemeKey => {\n if (scheme[schemeKey] && typeof scheme[schemeKey] === 'object') {\n // shallow merge the 1st level structure of the theme.\n theme[schemeKey] = _extends({}, theme[schemeKey], scheme[schemeKey]);\n } else {\n theme[schemeKey] = scheme[schemeKey];\n }\n });\n if (theme.palette) {\n theme.palette.colorScheme = key;\n }\n }\n const resolvedDefaultColorScheme = (() => {\n if (typeof defaultColorScheme === 'string') {\n return defaultColorScheme;\n }\n if (defaultMode === 'dark') {\n return defaultColorScheme.dark;\n }\n return defaultColorScheme.light;\n })();\n if (key === resolvedDefaultColorScheme) {\n if (excludeVariablesFromRoot) {\n const excludedVariables = {};\n excludeVariablesFromRoot(cssVarPrefix).forEach(cssVar => {\n excludedVariables[cssVar] = css[cssVar];\n delete css[cssVar];\n });\n defaultColorSchemeStyleSheet[`[${attribute}=\"${key}\"]`] = excludedVariables;\n }\n defaultColorSchemeStyleSheet[`${colorSchemeSelector}, [${attribute}=\"${key}\"]`] = css;\n } else {\n otherColorSchemesStyleSheet[`${colorSchemeSelector === ':root' ? '' : colorSchemeSelector}[${attribute}=\"${key}\"]`] = css;\n }\n });\n theme.vars = deepmerge(theme.vars, rootVars);\n\n // 5. Declaring effects\n // 5.1 Updates the selector value to use the current color scheme which tells CSS to use the proper stylesheet.\n React.useEffect(() => {\n if (colorScheme && colorSchemeNode) {\n // attaches attribute to <html> because the css variables are attached to :root (html)\n colorSchemeNode.setAttribute(attribute, colorScheme);\n }\n }, [colorScheme, attribute, colorSchemeNode]);\n\n // 5.2 Remove the CSS transition when color scheme changes to create instant experience.\n // credit: https://github.com/pacocoursey/next-themes/blob/b5c2bad50de2d61ad7b52a9c5cdc801a78507d7a/index.tsx#L313\n React.useEffect(() => {\n let timer;\n if (disableTransitionOnChange && hasMounted.current && documentNode) {\n const css = documentNode.createElement('style');\n css.appendChild(documentNode.createTextNode(DISABLE_CSS_TRANSITION));\n documentNode.head.appendChild(css);\n\n // Force browser repaint\n (() => window.getComputedStyle(documentNode.body))();\n timer = setTimeout(() => {\n documentNode.head.removeChild(css);\n }, 1);\n }\n return () => {\n clearTimeout(timer);\n };\n }, [colorScheme, disableTransitionOnChange, documentNode]);\n React.useEffect(() => {\n hasMounted.current = true;\n return () => {\n hasMounted.current = false;\n };\n }, []);\n const contextValue = React.useMemo(() => ({\n allColorSchemes,\n colorScheme,\n darkColorScheme,\n lightColorScheme,\n mode,\n setColorScheme,\n setMode,\n systemMode\n }), [allColorSchemes, colorScheme, darkColorScheme, lightColorScheme, mode, setColorScheme, setMode, systemMode]);\n let shouldGenerateStyleSheet = true;\n if (disableStyleSheetGeneration || nested && (upperTheme == null ? void 0 : upperTheme.cssVarPrefix) === cssVarPrefix) {\n shouldGenerateStyleSheet = false;\n }\n const element = /*#__PURE__*/_jsxs(React.Fragment, {\n children: [shouldGenerateStyleSheet && /*#__PURE__*/_jsxs(React.Fragment, {\n children: [/*#__PURE__*/_jsx(GlobalStyles, {\n styles: {\n [colorSchemeSelector]: rootCss\n }\n }), /*#__PURE__*/_jsx(GlobalStyles, {\n styles: defaultColorSchemeStyleSheet\n }), /*#__PURE__*/_jsx(GlobalStyles, {\n styles: otherColorSchemesStyleSheet\n })]\n }), /*#__PURE__*/_jsx(ThemeProvider, {\n themeId: scopedTheme ? themeId : undefined,\n theme: resolveTheme ? resolveTheme(theme) : theme,\n children: children\n })]\n });\n if (nested) {\n return element;\n }\n return /*#__PURE__*/_jsx(ColorSchemeContext.Provider, {\n value: contextValue,\n children: element\n });\n }\n process.env.NODE_ENV !== \"production\" ? CssVarsProvider.propTypes = {\n /**\n * The body attribute name to attach colorScheme.\n */\n attribute: PropTypes.string,\n /**\n * The component tree.\n */\n children: PropTypes.node,\n /**\n * The node used to attach the color-scheme attribute\n */\n colorSchemeNode: PropTypes.any,\n /**\n * The CSS selector for attaching the generated custom properties\n */\n colorSchemeSelector: PropTypes.string,\n /**\n * localStorage key used to store `colorScheme`\n */\n colorSchemeStorageKey: PropTypes.string,\n /**\n * The initial color scheme used.\n */\n defaultColorScheme: PropTypes.oneOfType([PropTypes.string, PropTypes.object]),\n /**\n * The initial mode used.\n */\n defaultMode: PropTypes.string,\n /**\n * If `true`, the provider creates its own context and generate stylesheet as if it is a root `CssVarsProvider`.\n */\n disableNestedContext: PropTypes.bool,\n /**\n * If `true`, the style sheet won't be generated.\n *\n * This is useful for controlling nested CssVarsProvider behavior.\n */\n disableStyleSheetGeneration: PropTypes.bool,\n /**\n * Disable CSS transitions when switching between modes or color schemes.\n */\n disableTransitionOnChange: PropTypes.bool,\n /**\n * The document to attach the attribute to.\n */\n documentNode: PropTypes.any,\n /**\n * The key in the local storage used to store current color scheme.\n */\n modeStorageKey: PropTypes.string,\n /**\n * The window that attaches the 'storage' event listener.\n * @default window\n */\n storageWindow: PropTypes.any,\n /**\n * The calculated theme object that will be passed through context.\n */\n theme: PropTypes.object\n } : void 0;\n const defaultLightColorScheme = typeof designSystemColorScheme === 'string' ? designSystemColorScheme : designSystemColorScheme.light;\n const defaultDarkColorScheme = typeof designSystemColorScheme === 'string' ? designSystemColorScheme : designSystemColorScheme.dark;\n const getInitColorSchemeScript = params => InitColorSchemeScript(_extends({\n attribute: defaultAttribute,\n colorSchemeStorageKey: defaultColorSchemeStorageKey,\n defaultMode: designSystemMode,\n defaultLightColorScheme,\n defaultDarkColorScheme,\n modeStorageKey: defaultModeStorageKey\n }, params));\n return {\n CssVarsProvider,\n useColorScheme,\n getInitColorSchemeScript\n };\n}"],"names":["_excluded","DISABLE_CSS_TRANSITION","createCssVarsProvider","options","themeId","theme","defaultTheme","attribute","defaultAttribute","DEFAULT_ATTRIBUTE","modeStorageKey","defaultModeStorageKey","DEFAULT_MODE_STORAGE_KEY","colorSchemeStorageKey","defaultColorSchemeStorageKey","DEFAULT_COLOR_SCHEME_STORAGE_KEY","defaultMode","designSystemMode","defaultColorScheme","designSystemColorScheme","disableTransitionOnChange","designSystemTransitionOnChange","resolveTheme","excludeVariablesFromRoot","colorSchemes","light","dark","console","error","ColorSchemeContext","React","createContext","undefined","process","env","NODE_ENV","displayName","CssVarsProvider","props","children","themeProp","storageWindow","window","documentNode","document","colorSchemeNode","documentElement","colorSchemeSelector","disableNestedContext","disableStyleSheetGeneration","hasMounted","useRef","upperTheme","muiUseTheme","ctx","useContext","nested","scopedTheme","_ref","components","generateCssVars","vars","css","cssVarPrefix","restThemeProp","_objectWithoutPropertiesLoose","allColorSchemes","Object","keys","defaultLightColorScheme","defaultDarkColorScheme","mode","stateMode","setMode","systemMode","lightColorScheme","darkColorScheme","colorScheme","stateColorScheme","setColorScheme","useCurrentColorScheme","supportedColorSchemes","calculatedColorScheme","rootCss","rootVars","_extends","getColorSchemeSelector","targetColorScheme","defaultColorSchemeStyleSheet","otherColorSchemesStyleSheet","entries","forEach","key","scheme","deepmerge","schemeKey","palette","excludedVariables","cssVar","useEffect","setAttribute","timer","current","createElement","appendChild","createTextNode","head","getComputedStyle","body","setTimeout","removeChild","clearTimeout","contextValue","useMemo","shouldGenerateStyleSheet","element","_jsxs","Fragment","_jsx","GlobalStyles","styles","ThemeProvider","Provider","value","propTypes","PropTypes","string","node","any","oneOfType","object","bool","useColorScheme","Error","_formatMuiErrorMessage","getInitColorSchemeScript","params","InitColorSchemeScript"],"mappings":"4iCAGA,MAAMA,EAAY,CAAC,eAAgB,aAAc,kBAAmB,gBAWvDC,EAAyB,2JACvB,SAASC,EAAsBC,GAC5C,MAAMC,QACJA,EAOAC,MAAOC,EAAe,CAAE,EACxBC,UAAWC,EAAmBC,EAC9BC,eAAgBC,EAAwBC,EACxCC,sBAAuBC,EAA+BC,EACtDC,YAAaC,EAAmB,QAChCC,mBAAoBC,EACpBC,0BAA2BC,GAAiC,EAAKC,aACjEA,EAAYC,yBACZA,GACEpB,IACCG,EAAakB,cAAmD,iBAA5BL,IAAyCb,EAAakB,aAAaL,IAA+D,iBAA5BA,IAAyCb,EAAakB,aAAwC,MAA3BL,OAAkC,EAASA,EAAwBM,QAA6C,iBAA5BN,IAAyCb,EAAakB,aAAwC,MAA3BL,OAAkC,EAASA,EAAwBO,QAC1aC,QAAQC,MAAM,UAAUT,iDAE1B,MAAMU,EAAkCC,EAAMC,mBAAcC,GAC/B,eAAzBC,QAAQC,IAAIC,WACdN,EAAmBO,YAAc,sBASnC,SAASC,EAAgBC,GACvB,MAAMC,SACJA,EACAlC,MAAOmC,EAAYlC,EAAYI,eAC/BA,EAAiBC,EAAqBE,sBACtCA,EAAwBC,EAA4BP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UC,OAAQD,EAAUK,SAIrElH,YAAa6G,EAAUC,OAIvB9E,qBAAsB6E,EAAUM,KAMhClF,4BAA6B4E,EAAUM,KAIvC/G,0BAA2ByG,EAAUM,KAIrCxF,aAAckF,EAAUG,IAIxBtH,eAAgBmH,EAAUC,OAK1BrF,cAAeoF,EAAUG,IAIzB3H,MAAOwH,EAAUK,SAEnB,MAAM7D,EAA6D,iBAA5BlD,EAAuCA,EAA0BA,EAAwBM,MAC1H6C,EAA4D,iBAA5BnD,EAAuCA,EAA0BA,EAAwBO,KAS/H,MAAO,CACLW,kBACA+F,eA7SqB,KACrB,MAAMT,EAAQ7F,EAAMyB,WAAW1B,GAC/B,IAAK8F,EACH,MAAM,IAAIU,MAA+B,eAAzBpG,QAAQC,IAAIC,SAA4B,iEAAqEmG,EAAuB,KAEtJ,OAAOX,CAAK,EAySZY,yBAX+BC,GAAUC,EAAsBpD,EAAS,CACxE9E,UAAWC,EACXK,sBAAuBC,EACvBE,YAAaC,EACboD,0BACAC,yBACA5D,eAAgBC,GACf6H,IAML"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import*as e from"react";import{T as t}from"../../../@emotion/react/dist/emotion-element-f0de968e.browser.esm.js";function o(o=null){const r=e.useContext(t);return r&&(
|
|
1
|
+
import*as e from"react";import"../../../@emotion/styled/dist/emotion-styled.browser.esm.js";import"../../../@emotion/react/dist/emotion-react.browser.esm.js";import"../../styled-engine/StyledEngineProvider/StyledEngineProvider.js";import"../../styled-engine/GlobalStyles/GlobalStyles.js";import{T as t}from"../../../@emotion/react/dist/emotion-element-f0de968e.browser.esm.js";function o(o=null){const r=e.useContext(t);return r&&(s=r,0!==Object.keys(s).length)?r:o;var s}export{o as default};
|
|
2
2
|
//# sourceMappingURL=useThemeWithoutDefault.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useThemeWithoutDefault.js","sources":["../../../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;"],"names":["useTheme","defaultTheme","contextTheme","React","useContext","ThemeContext","obj","Object","keys","length"],"mappings":"
|
|
1
|
+
{"version":3,"file":"useThemeWithoutDefault.js","sources":["../../../../../node_modules/@mui/system/esm/useThemeWithoutDefault.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport { ThemeContext } from '@mui/styled-engine';\nfunction isObjectEmpty(obj) {\n return Object.keys(obj).length === 0;\n}\nfunction useTheme(defaultTheme = null) {\n const contextTheme = React.useContext(ThemeContext);\n return !contextTheme || isObjectEmpty(contextTheme) ? defaultTheme : contextTheme;\n}\nexport default useTheme;"],"names":["useTheme","defaultTheme","contextTheme","React","useContext","ThemeContext","obj","Object","keys","length"],"mappings":"yXAOA,SAASA,EAASC,EAAe,MAC/B,MAAMC,EAAeC,EAAMC,WAAWC,GACtC,OAAQH,IALaI,EAKiBJ,EAJH,IAA5BK,OAAOC,KAAKF,GAAKG,QAI6CP,EAAfD,EALxD,IAAuBK,CAMvB"}
|
|
@@ -4,5 +4,5 @@ import a from"../createLucideIcon.js";
|
|
|
4
4
|
*
|
|
5
5
|
* This source code is licensed under the ISC license.
|
|
6
6
|
* See the LICENSE file in the root directory of this source tree.
|
|
7
|
-
*/const e=[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]
|
|
7
|
+
*/const e=[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]],t=a("sparkles",e);export{e as __iconNode,t as default};
|
|
8
8
|
//# sourceMappingURL=sparkles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sparkles.js","sources":["../../../../../../node_modules/lucide-react/dist/esm/icons/sparkles.js"],"sourcesContent":["/**\n * @license lucide-react v0.525.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z\",\n key: \"4pj2yx\"\n }\n ],\n [\"path\", { d: \"M20 3v4\", key: \"1olli1\" }],\n [\"path\", { d: \"M22 5h-4\", key: \"1gvqau\" }],\n [\"path\", { d: \"M4 17v2\", key: \"vumght\" }],\n [\"path\", { d: \"M5 18H3\", key: \"zchphs\" }]\n];\nconst Sparkles = createLucideIcon(\"sparkles\", __iconNode);\n\nexport { __iconNode, Sparkles as default };\n//# sourceMappingURL=sparkles.js.map\n"],"names":["__iconNode","d","key","createLucideIcon"],"mappings":";;;;;;GASK,MAACA,EAAa,CACjB,CACE,OACA,CACEC,EAAG,8PACHC,IAAK,WAGT,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,WAC9B,CAAC,OAAQ,CAAED,EAAG,WAAYC,IAAK,WAC/B,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,WAC9B,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,
|
|
1
|
+
{"version":3,"file":"sparkles.js","sources":["../../../../../../node_modules/lucide-react/dist/esm/icons/sparkles.js"],"sourcesContent":["/**\n * @license lucide-react v0.525.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z\",\n key: \"4pj2yx\"\n }\n ],\n [\"path\", { d: \"M20 3v4\", key: \"1olli1\" }],\n [\"path\", { d: \"M22 5h-4\", key: \"1gvqau\" }],\n [\"path\", { d: \"M4 17v2\", key: \"vumght\" }],\n [\"path\", { d: \"M5 18H3\", key: \"zchphs\" }]\n];\nconst Sparkles = createLucideIcon(\"sparkles\", __iconNode);\n\nexport { __iconNode, Sparkles as default };\n//# sourceMappingURL=sparkles.js.map\n"],"names":["__iconNode","d","key","Sparkles","createLucideIcon"],"mappings":";;;;;;GASK,MAACA,EAAa,CACjB,CACE,OACA,CACEC,EAAG,8PACHC,IAAK,WAGT,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,WAC9B,CAAC,OAAQ,CAAED,EAAG,WAAYC,IAAK,WAC/B,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,WAC9B,CAAC,OAAQ,CAAED,EAAG,UAAWC,IAAK,YAE1BC,EAAWC,EAAiB,WAAYJ"}
|
|
@@ -15,6 +15,45 @@ interface InstantLearningData {
|
|
|
15
15
|
_mergeWTA?: string[];
|
|
16
16
|
_mergeWNTA?: string[];
|
|
17
17
|
}
|
|
18
|
+
interface TopicItem {
|
|
19
|
+
id: string | null;
|
|
20
|
+
value: string;
|
|
21
|
+
label?: string;
|
|
22
|
+
isCustom?: boolean;
|
|
23
|
+
}
|
|
24
|
+
export interface CategoryItem {
|
|
25
|
+
id: string | null;
|
|
26
|
+
value: string;
|
|
27
|
+
label?: string;
|
|
28
|
+
isCustom?: boolean;
|
|
29
|
+
}
|
|
30
|
+
export type ScopeField = {
|
|
31
|
+
name: 'Global' | 'Assistant' | 'User' | 'Custom' | '';
|
|
32
|
+
value: null | AssistantScopeValue | UserScopeItem[] | CustomScopeValue;
|
|
33
|
+
};
|
|
34
|
+
export type AssistantScopeValue = {
|
|
35
|
+
assistantName: string;
|
|
36
|
+
conciergeId: string;
|
|
37
|
+
};
|
|
38
|
+
export type UserScopeItem = {
|
|
39
|
+
email: string;
|
|
40
|
+
userId: string;
|
|
41
|
+
name: string;
|
|
42
|
+
};
|
|
43
|
+
export type CustomScopeValue = {
|
|
44
|
+
scopeName: string;
|
|
45
|
+
scopeId: string;
|
|
46
|
+
};
|
|
47
|
+
export interface ContextualLearningData {
|
|
48
|
+
question?: string;
|
|
49
|
+
howToRespond: string;
|
|
50
|
+
whenToApply: string;
|
|
51
|
+
whenNotToApply: string;
|
|
52
|
+
topic: TopicItem;
|
|
53
|
+
categories: CategoryItem[];
|
|
54
|
+
scope: ScopeField;
|
|
55
|
+
_contextualUpdate?: boolean;
|
|
56
|
+
}
|
|
18
57
|
interface InstantLearningProps {
|
|
19
58
|
open: boolean;
|
|
20
59
|
selectedText: string;
|
|
@@ -23,7 +62,7 @@ interface InstantLearningProps {
|
|
|
23
62
|
value: string;
|
|
24
63
|
}[];
|
|
25
64
|
devModeTag?: string;
|
|
26
|
-
submitFunction: (details: InstantLearningData, setLoader: Function) => void;
|
|
65
|
+
submitFunction: (details: InstantLearningData | ContextualLearningData, setLoader: Function) => void;
|
|
27
66
|
chatAssistantName: string;
|
|
28
67
|
organizationName: string;
|
|
29
68
|
baseUrl: string;
|
|
@@ -49,6 +88,14 @@ interface InstantLearningProps {
|
|
|
49
88
|
setValidateWtaApiResponse?: any;
|
|
50
89
|
learningWtaResponse?: any;
|
|
51
90
|
setLearningWtaApiResponse?: any;
|
|
91
|
+
learningType?: 'findreplace' | 'contextual';
|
|
92
|
+
iLAssistantName?: string;
|
|
93
|
+
addInReview?: any[];
|
|
94
|
+
editInReview?: any[];
|
|
95
|
+
deleteInReview?: {
|
|
96
|
+
question_id: string;
|
|
97
|
+
variant_id: string;
|
|
98
|
+
}[];
|
|
52
99
|
}
|
|
53
100
|
declare const InstantLearning: React.FC<InstantLearningProps>;
|
|
54
101
|
export default InstantLearning;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InstantLearning.d.ts","sourceRoot":"","sources":["../../../../../src/features/InstantLearning/InstantLearning.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"InstantLearning.d.ts","sourceRoot":"","sources":["../../../../../src/features/InstantLearning/InstantLearning.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAcnD,UAAU,mBAAmB;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,cAA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C,EAAE,MAAM,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,qBAAqB,CAAC,EAAE,GAAG,CAAC;IAC5B,yBAAyB,CAAC,EAAE,GAAG,CAAC;IAChC,mBAAmB,CAAC,EAAE,GAAG,CAAC;IAC1B,yBAAyB,CAAC,EAAE,GAAG,CAAC;IAChC,YAAY,CAAC,EAAE,aAAa,GAAG,YAAY,CAAC;IAC5C,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,WAAW,CAAC,EAAE,GAAG,EAAE,CAAC;IACpB,YAAY,CAAC,EAAE,GAAG,EAAE,CAAC;IACrB,cAAc,CAAC,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;CAElE;AAED,QAAA,MAAM,eAAe,EAAE,KAAK,CAAC,EAAE,CAAC,oBAAoB,CAgYnD,CAAC;AAEF,eAAe,eAAe,CAAC"}
|
|
@@ -45,12 +45,18 @@ interface ChatComponentProps {
|
|
|
45
45
|
sendMessageInChat: string;
|
|
46
46
|
setSendMessageInChat: React.Dispatch<React.SetStateAction<string>>;
|
|
47
47
|
setIsMergeLoading: React.Dispatch<React.SetStateAction<boolean>>;
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
setExtractedHowToRespond: React.Dispatch<React.SetStateAction<string>>;
|
|
49
|
+
setExtractedTopic: React.Dispatch<React.SetStateAction<string>>;
|
|
50
|
+
setExtractedCategories: React.Dispatch<React.SetStateAction<string[]>>;
|
|
50
51
|
setValidationRecommendations: (recommendations: FormattedValidationRecommendation | null) => void;
|
|
51
|
-
isFormValidating: boolean;
|
|
52
52
|
validationRecommendations: FormattedValidationRecommendation | null;
|
|
53
|
+
addInReview?: any[];
|
|
54
|
+
editInReview?: any[];
|
|
55
|
+
deleteInReview?: {
|
|
56
|
+
question_id: string;
|
|
57
|
+
variant_id: string;
|
|
58
|
+
}[];
|
|
53
59
|
}
|
|
54
60
|
declare const ChatComponent: React.FC<ChatComponentProps>;
|
|
55
61
|
export default ChatComponent;
|
|
56
|
-
//# sourceMappingURL=
|
|
62
|
+
//# sourceMappingURL=ContextualChatComponent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContextualChatComponent.d.ts","sourceRoot":"","sources":["../../../../../../src/features/InstantLearning/_components/ContextualChatComponent.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAA;AAYhF,OAAO,qBAAqB,CAAA;AAI5B,OAAO,EAAkC,iCAAiC,EAAE,MAAM,qCAAqC,CAAC;AA8BxH,UAAU,kBAAkB;IACxB,oBAAoB,EAAE,MAAM,CAAA;IAC5B,iBAAiB,EAAE,MAAM,CAAA;IACzB,gBAAgB,EAAE,MAAM,CAAA;IACxB,OAAO,EAAE,MAAM,CAAA;IACf,6BAA6B,EAAE,GAAG,CAAA;IAClC,aAAa,EAAE,GAAG,CAAC;IACnB,gBAAgB,EAAE,GAAG,CAAC;IACtB,iBAAiB,EAAE,OAAO,CAAA;IAC1B,oBAAoB,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAA;IACnE,gBAAgB,EAAE,MAAM,CAAA;IACxB,mBAAmB,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAA;IAClE,YAAY,EAAE,MAAM,CAAA;IACpB,iBAAiB,EAAE,KAAK,CAAC,SAAS,CAAA;IAClC,gBAAgB,EAAE,MAAM,CAAA;IACxB,yBAAyB,EAAE,KAAK,CAAC,SAAS,CAAA;IAC1C,0BAA0B,EAAE,OAAO,CAAA;IACnC,wBAAwB,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,GAAG,KAA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AAkB,CAgjF/C,CAAA;AAED,eAAe,aAAa,CAAA"}
|
|
@@ -10,32 +10,21 @@ interface LearningConflict {
|
|
|
10
10
|
similarity_score: number;
|
|
11
11
|
reason: string;
|
|
12
12
|
}
|
|
13
|
-
interface
|
|
13
|
+
interface ContextualConflictsDisplayDBProps {
|
|
14
14
|
conflictingConditions: [LearningConflict[], LearningConflict[]];
|
|
15
15
|
baseUrl?: string;
|
|
16
16
|
organizationName?: string;
|
|
17
17
|
chatAssistantName?: string;
|
|
18
|
-
curlPayload?: string;
|
|
19
18
|
onDeleted?: (variantId: string) => void;
|
|
20
|
-
onMerged?: (mergedLearningId: string, mergedConditions: {
|
|
21
|
-
whenToApply: string[];
|
|
22
|
-
whenNotToApply: string[];
|
|
23
|
-
}) => void;
|
|
24
|
-
onDeleteLearning?: (label: string) => void;
|
|
25
19
|
onMergeMessage?: (message: string) => void;
|
|
26
20
|
setSendMessageInChat: React.Dispatch<React.SetStateAction<string>>;
|
|
27
21
|
editConflictingLearningTrigger?: any;
|
|
28
22
|
editSimilarLearningTrigger?: any;
|
|
29
|
-
operationStatus?: {
|
|
30
|
-
status: 'success' | 'error';
|
|
31
|
-
message: string;
|
|
32
|
-
} | null;
|
|
33
|
-
onOperationComplete?: () => void;
|
|
34
23
|
onSetOperationStatus?: (status: {
|
|
35
24
|
status: 'success' | 'error';
|
|
36
25
|
message: string;
|
|
37
26
|
} | null) => void;
|
|
38
27
|
}
|
|
39
|
-
declare const
|
|
40
|
-
export default
|
|
41
|
-
//# sourceMappingURL=
|
|
28
|
+
declare const ContextualConflictsDisplayDB: React.FC<ContextualConflictsDisplayDBProps>;
|
|
29
|
+
export default ContextualConflictsDisplayDB;
|
|
30
|
+
//# sourceMappingURL=ContextualConflictDBCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContextualConflictDBCard.d.ts","sourceRoot":"","sources":["../../../../../../src/features/InstantLearning/_components/ContextualConflictDBCard.tsx"],"names":[],"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import { FormattedValidationRecommendation } from '../../../utils/recommendationParser';
|
|
4
|
+
interface ContextualLearningFormProps {
|
|
5
|
+
question: string;
|
|
6
|
+
topicOptions?: {
|
|
7
|
+
label: string;
|
|
8
|
+
value: string;
|
|
9
|
+
}[];
|
|
10
|
+
categoryOptions?: {
|
|
11
|
+
label: string;
|
|
12
|
+
value: string;
|
|
13
|
+
}[];
|
|
14
|
+
onSubmit: (formData: ContextualLearningData, setLoader: Function) => void;
|
|
15
|
+
formData: ContextualLearningData;
|
|
16
|
+
setFormData: React.Dispatch<React.SetStateAction<ContextualLearningData>>;
|
|
17
|
+
extractedHowToRespond?: string;
|
|
18
|
+
extractedTopic?: string;
|
|
19
|
+
organizationName?: string;
|
|
20
|
+
iLAssistantName?: string;
|
|
21
|
+
validationWtaResponse?: any;
|
|
22
|
+
setValidationWtaResponse?: React.Dispatch<React.SetStateAction<any>>;
|
|
23
|
+
baseUrl?: string;
|
|
24
|
+
extractedCategories?: string[];
|
|
25
|
+
learningWtaResponse?: any;
|
|
26
|
+
setSendMessageInChat: React.Dispatch<React.SetStateAction<string>>;
|
|
27
|
+
editConflictingLearningTrigger?: any;
|
|
28
|
+
editSimilarLearningTrigger?: any;
|
|
29
|
+
onSetOperationStatus?: (status: {
|
|
30
|
+
status: 'success' | 'error';
|
|
31
|
+
message: string;
|
|
32
|
+
} | null) => void;
|
|
33
|
+
onDeleted?: (variantId: string) => void;
|
|
34
|
+
onMergeMessage?: (message: string) => void;
|
|
35
|
+
chatAssistantName?: string;
|
|
36
|
+
validationRecommendations: FormattedValidationRecommendation | null;
|
|
37
|
+
resetLearningTrigger?: boolean;
|
|
38
|
+
save: boolean;
|
|
39
|
+
setIsFormSavedClicked: React.Dispatch<React.SetStateAction<boolean>>;
|
|
40
|
+
}
|
|
41
|
+
declare const ContextualLearningForm: React.FC<ContextualLearningFormProps>;
|
|
42
|
+
export default ContextualLearningForm;
|
|
43
|
+
//# sourceMappingURL=ContextualLearningForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContextualLearningForm.d.ts","sourceRoot":"","sources":["../../../../../../src/features/InstantLearning/_components/ContextualLearningForm.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAgB,sBAAsB,EAA+C,MAAM,oBAAoB,CAAC;AAa5H,OAAO,EACL,iCAAiC,EAElC,MAAM,qCAAqC,CAAC;AAoB7C,UAAU,2BAA2B;IACnC,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAClD,eAAe,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IACtD,QAAQ,EAAE,CAAC,QAAQ,EAAE,sBAAsB,EAAE,SAAS,EAAE,QAAQ,KAAK,IAAI,CAAC;IACzE,QAAQ,EAAE,sBAAsB,CAAC;IACjC,WAAW,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,sBAAsB,CAAC,CAAC,CAAC;IAC1E,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,qBAAqB,CAAC,EAAE,GAAG,CAAC;IAC5B,wBAAwB,CAAC,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;IACrE,OAAO,CAAC,EAAG,MAAM,CAAC;IAClB,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC/B,mBAAmB,CAAC,EAAE,GAAG,CAAC;IAC1B,oBAAoB,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,CAAC;IACnE,8BAA8B,CAAC,EAAE,GAAG,CAAC;IACrC,0BAA0B,CAAC,EAAE,GAAG,CAAC;IACjC,oBAAoB,CAAC,EAAE,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,SAAS,GAAG,OAAO,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,KAAK,IAAI,CAAC;IACjG,SAAS,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,cAAc,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,yBAAyB,EAAE,iCAAiC,GAAG,IAAI,CAAC;IACpE,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,IAAI,EAAE,OAAO,CAAC;IACd,qBAAqB,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;CAEtE;AAsVD,QAAA,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CAqtDjE,CAAA;AAED,eAAe,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface TopicOption {
|
|
2
|
+
id: string | null;
|
|
3
|
+
label: string;
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Fetches the list of existing topics from the server.
|
|
7
|
+
* @returns A promise that resolves to an array of TopicOption objects.
|
|
8
|
+
*/
|
|
9
|
+
export declare const fetchExistingTopicsAPI: () => Promise<TopicOption[]>;
|
|
10
|
+
export declare const fetchScopes: (name: string, organizationName: string) => Promise<{
|
|
11
|
+
scopeOptions: any;
|
|
12
|
+
customScopeOptions: any;
|
|
13
|
+
}>;
|
|
14
|
+
export declare const fetchUserByEmail: (email: string) => Promise<any>;
|
|
15
|
+
//# sourceMappingURL=agentGenieAPI.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agentGenieAPI.d.ts","sourceRoot":"","sources":["../../../../src/utils/agentGenieAPI.ts"],"names":[],"mappings":"AAaA,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,GAAG,IAAI,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,eAAO,MAAM,sBAAsB,QAAa,QAAQ,WAAW,EAAE,CA6BpE,CAAC;AAEF,eAAO,MAAM,WAAW,SAAgB,MAAM,oBAAmB,MAAM;;;EA4CtE,CAAC;AAEF,eAAO,MAAM,gBAAgB,UAAiB,MAAM,iBAWnD,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface CategoryItem {
|
|
2
|
+
label: string;
|
|
3
|
+
value: string;
|
|
4
|
+
isCustom?: boolean;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Fetches suggested categories based on the user's "question".
|
|
8
|
+
* @param question The text from the "Question" field.
|
|
9
|
+
* @param baseUrl The base URL of your API.
|
|
10
|
+
* @returns A promise that resolves to an array of CategoryItem objects.
|
|
11
|
+
*/
|
|
12
|
+
export declare const fetchSuggestedCategories: (question: string, baseUrl: string) => Promise<CategoryItem[]>;
|
|
13
|
+
//# sourceMappingURL=instantLearningAPI.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instantLearningAPI.d.ts","sourceRoot":"","sources":["../../../../src/utils/instantLearningAPI.ts"],"names":[],"mappings":"AAMA,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IAEd,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAGD;;;;;GAKG;AACH,eAAO,MAAM,wBAAwB,aACzB,MAAM,WACP,MAAM,KACd,QAAQ,YAAY,EAAE,CA2ExB,CAAC"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{__awaiter as e,__generator as t}from"../node_modules/tslib/tslib.es6.mjs.js";import n from"../node_modules/axios/lib/axios.js";var o="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiI4MDU5NjU4Yy1hNjVjLTRlMTQtODlhYS1hNTE5NWY1ZDA5ZjUiLCJ1c2VybmFtZSI6IkthdGh5YXlhbmlNIiwibmFtZSI6Ik0gS2F0aHlheWFuaSIsImVtYWlsIjoibWFkdW1idS5rYXRoeWF5YW5pQHRlY2hvbHV0aW9uLmNvbSIsInJvbGUiOiJzdXBlcl9hZG1pbiIsInN0YXR1cyI6ImFjdGl2ZSIsImlhdCI6MTc1MzM4Mzg4N30.iF2nGYpBedIfeGasUNc7lhjStb_B_u1uz6NFEh0u6qI",r="https://dev-egpt.techo.camp",s="techolution-instantLearning-topics",i="techolution-instantLearning-variants",a=function(){return e(void 0,void 0,void 0,(function(){var e,a,c,u,l;return t(this,(function(t){switch(t.label){case 0:e={topic_table:s,variant_table:i},a="".concat(r,"/api/instant-learning/getExistingTopics"),c={Authorization:"Bearer ".concat(o)},t.label=1;case 1:return t.trys.push([1,3,,4]),[4,n.post(a,e,{headers:c})];case 2:return(u=t.sent()).data.response&&0!==Object.keys(u.data.response.response).length?[2,Object.entries(u.data.response.response).map((function(e){return{id:e[0],label:e[1].topic_name}}))]:[2,[]];case 3:return l=t.sent(),console.error("Error fetching existing topics:",l),[2,[]];case 4:return[2]}}))}))},c=function(s,i){return e(void 0,void 0,void 0,(function(){var e,a,c,u,l,d,h,p,g,I,b,m,v;return t(this,(function(t){switch(t.label){case 0:e={Authorization:"Bearer ".concat(o)},a="".concat(r,"/api/chatbot/getChatbot?name=").concat(s,"&organizationName=").concat(i),t.label=1;case 1:return t.trys.push([1,3,,4]),[4,n.get(a,{headers:e})];case 2:return h=t.sent(),c=h.data,[3,4];case 3:throw u=t.sent(),console.error("Error fetching chatbot details:",u),u;case 4:l="".concat(r,"/api/agent/getAgentSettings?agentSettingsId=").concat(c.agentSettingsId),t.label=5;case 5:return t.trys.push([5,7,,8]),[4,n.get(l,{headers:e})];case 6:return h=t.sent(),d=null===(v=h.data)||void 0===v?void 0:v.agentSettings,[3,8];case 7:throw p=t.sent(),console.error("Error fetching agent settings:",p),p;case 8:return g=(null==d?void 0:d.scopeMetrics)||[],I=g.filter((function(e){return e.isSelected})),b=I.find((function(e){return"Custom"===e.scope})),m=(null==b?void 0:b.id)&&Array.isArray(b.id)?b.id.map((function(e){return{scopeName:e.scopeName,scopeId:e.id}})):[],console.log("Scope options:",I),console.log("Custom scope options:",m),[2,{scopeOptions:I,customScopeOptions:m}]}}))}))},u=function(s){return e(void 0,void 0,void 0,(function(){var e,i,a;return t(this,(function(t){switch(t.label){case 0:e="".concat(r,"/api/users/getUserByEmail/").concat(s),i={Authorization:"Bearer ".concat(o)},t.label=1;case 1:return t.trys.push([1,3,,4]),[4,n.get(e,{headers:i})];case 2:return[2,t.sent().data];case 3:throw a=t.sent(),console.error("Error fetching user by email:",a),a;case 4:return[2]}}))}))};export{a as fetchExistingTopicsAPI,c as fetchScopes,u as fetchUserByEmail};
|
|
2
|
+
//# sourceMappingURL=agentGenieAPI.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agentGenieAPI.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{__awaiter as e,__generator as t}from"../node_modules/tslib/tslib.es6.mjs.js";var n=function(n,i){return e(void 0,void 0,void 0,(function(){var e,r,o,a,s,c,l,u,d,h;return t(this,(function(t){switch(t.label){case 0:if(!n.trim())return[2,[]];e="".concat(i,"/api/instant-learning/getSuggestedCategories"),r="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiI4MDU5NjU4Yy1hNjVjLTRlMTQtODlhYS1hNTE5NWY1ZDA5ZjUiLCJ1c2VybmFtZSI6IkthdGh5YXlhbmlNIiwibmFtZSI6Ik0gS2F0aHlheWFuaSIsImVtYWlsIjoibWFkdW1idS5rYXRoeWF5YW5pQHRlY2hvbHV0aW9uLmNvbSIsInJvbGUiOiJzdXBlcl9hZG1pbiIsInN0YXR1cyI6ImFjdGl2ZSIsImlhdCI6MTc1MzM4Mzg4N30.iF2nGYpBedIfeGasUNc7lhjStb_B_u1uz6NFEh0u6qI",o={llm_model:"gpt-4o",topics_config:{dbIndexName:"techolution-instantLearning-categories",dbType:"alloydb",embeddingModel:"mxbai-embed-large-v1",embedding_column:"category_embedding",similarity_threshold:.6},question:"".concat(n),prompt:'You are an intelligent classifier. Analyze the following question or conversation and extract the most relevant **categories** that describe its content. \nInclude:\n1. **Specific topics** (e.g., lung cancer, diabetes, neural networks).\n2. **General domains** (e.g., healthcare, education, technology).\n3. **Intent or task types** (e.g., treatment guidance, diagnosis, troubleshooting).\n\nInput:\nchat_data: The original query from the user\n\nOnly return the categories in this exact format:\n[\n {\n "categories": ["<category1>", "<category2>", "..."]\n }\n]'},t.label=1;case 1:return t.trys.push([1,4,,5]),[4,fetch(e,{method:"POST",headers:{"Content-Type":"application/json",accept:"application/json, text/plain, */*",Authorization:"Bearer ".concat(r)},body:JSON.stringify(o)})];case 2:if(!(a=t.sent()).ok)throw new Error("API request failed with status ".concat(a.status));return[4,a.json()];case 3:return s=t.sent(),(c=null===(d=null==s?void 0:s.response)||void 0===d?void 0:d.response)&&Array.isArray(c)&&c.length>0&&(l=null===(h=c[0])||void 0===h?void 0:h.categories)&&Array.isArray(l)?[2,l.map((function(e){return{label:e,value:e,isCustom:!1}}))]:(console.warn("Category API response was successful but did not match the expected structure.",s),[2,[]]);case 4:return u=t.sent(),console.error("Error fetching suggested categories:",u),[2,[]];case 5:return[2]}}))}))};export{n as fetchSuggestedCategories};
|
|
2
|
+
//# sourceMappingURL=instantLearningAPI.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"instantLearningAPI.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
|