@corva/ui 3.40.0-14 → 3.40.0-16
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/cjs-bundle/components/AddComment/Popover.js +1 -1
- package/cjs-bundle/components/AddComment/Popover.js.map +1 -1
- package/cjs-bundle/components/AddComment/components/Content.js +1 -1
- package/cjs-bundle/components/AddComment/components/Content.js.map +1 -1
- package/cjs-bundle/components/BICOffsetPickerDialog/index.js +1 -1
- package/cjs-bundle/components/BICOffsetPickerDialog/index.js.map +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/CasingJoints/Editor.js +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/CasingJoints/Editor.js.map +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/Component.js +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/Component.js.map +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/DrillPipe/Editor.js +1 -1
- package/cjs-bundle/components/Casing/CasingTableV2/components/DrillPipe/Editor.js.map +1 -1
- package/cjs-bundle/components/DocumentViewer/DocumentViewer.js +1 -1
- package/cjs-bundle/components/DocumentViewer/DocumentViewer.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Agitator/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Agitator/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Bit/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Bit/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Component.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Component.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/DrillCollar/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/DrillCollar/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/DrillPipe/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/DrillPipe/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Jar/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Jar/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Lwd/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Lwd/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Mwd/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Mwd/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Pdm/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Pdm/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Rss/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Rss/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Stabilizer/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Stabilizer/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Sub/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Sub/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Ur/Editor.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/Ur/Editor.js.map +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/shared/ConfirmationPopup.js +1 -1
- package/cjs-bundle/components/Drillstring/BHAComponentsTable/components/shared/ConfirmationPopup.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV2/components/Filter/ToggleMapButton.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV2/components/Filter/ToggleMapButton.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV2/components/Table/MetricsAddMenu.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV2/components/Table/MetricsAddMenu.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/CustomSelectionView/components/Table/MetricsAddMenu.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/CustomSelectionView/components/Table/MetricsAddMenu.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/CustomSelectionView/index.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/CustomSelectionView/index.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/OffsetWellSelectionView/index.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/OffsetWellSelectionView/index.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/TabSelection/ToggleMapButton.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/TabSelection/ToggleMapButton.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/TabSelection/index.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/TabSelection/index.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/WellHubView/index.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/WellHubView/index.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/shared/OffsetWellTableHead.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV3/components/shared/OffsetWellTableHead.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV4/index.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV4/index.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/OffsetWellPickerV5.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/OffsetWellPickerV5.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Filter/Filter.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Filter/Filter.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/OffsetWellMap.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/MapHints/MapHints.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/RadiusInput/RadiusInput.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/constants.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useLassoSelection.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusCircle.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.js +2 -0
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.js.map +1 -0
- package/cjs-bundle/components/OffsetWellPickerV5/components/Map/WellsMap.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/OffsetWellsTable/OffsetWellsTable.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/components/OffsetWellsTable/OffsetWellsTable.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/constants.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/constants.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useAdvancedWells.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useAdvancedWells.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useFetchWells.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useFilteredWells.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useFilteredWells.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useSortedWells.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/effects/useSortedWells.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/stores/filter-store/FilterStoreProvider.js +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/stores/filter-store/FilterStoreProvider.js.map +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.js +2 -0
- package/cjs-bundle/components/{OffsetWellPickerV4/components/AppHeader/AppHeader.module.css.js.map → OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.js.map} +1 -1
- package/cjs-bundle/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.js +2 -0
- package/cjs-bundle/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.js.map +1 -0
- package/cjs-bundle/components/OffsetWellPickerV5/utils/getIsImperial.js.map +1 -1
- package/cjs-bundle/components/PadOffsetsPicker/StagesSelector.js +1 -1
- package/cjs-bundle/components/PadOffsetsPicker/StagesSelector.js.map +1 -1
- package/cjs-bundle/components/PadOffsetsPickerV2/PadOffsetsPickerV2.js +1 -1
- package/cjs-bundle/componentsV2/AppHeader/V3/Actions/Actions.js +1 -1
- package/components/AddComment/Popover.js +1 -1
- package/components/AddComment/Popover.js.map +1 -1
- package/components/AddComment/components/Content.js +1 -1
- package/components/AddComment/components/Content.js.map +1 -1
- package/components/BICOffsetPickerDialog/index.js +1 -1
- package/components/BICOffsetPickerDialog/index.js.map +1 -1
- package/components/Casing/CasingTableV2/components/CasingJoints/Editor.js +1 -1
- package/components/Casing/CasingTableV2/components/CasingJoints/Editor.js.map +1 -1
- package/components/Casing/CasingTableV2/components/Component.js +1 -1
- package/components/Casing/CasingTableV2/components/Component.js.map +1 -1
- package/components/Casing/CasingTableV2/components/DrillPipe/Editor.js +1 -1
- package/components/Casing/CasingTableV2/components/DrillPipe/Editor.js.map +1 -1
- package/components/DocumentViewer/DocumentViewer.js +1 -1
- package/components/DocumentViewer/DocumentViewer.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Agitator/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Agitator/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Bit/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Bit/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Component.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Component.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/DrillCollar/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/DrillCollar/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/DrillPipe/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/DrillPipe/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Jar/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Jar/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Lwd/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Lwd/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Mwd/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Mwd/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Pdm/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Pdm/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Rss/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Rss/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Stabilizer/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Stabilizer/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Sub/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Sub/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Ur/Editor.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/Ur/Editor.js.map +1 -1
- package/components/Drillstring/BHAComponentsTable/components/shared/ConfirmationPopup.js +1 -1
- package/components/Drillstring/BHAComponentsTable/components/shared/ConfirmationPopup.js.map +1 -1
- package/components/OffsetWellPickerV2/components/Filter/ToggleMapButton.js +1 -1
- package/components/OffsetWellPickerV2/components/Filter/ToggleMapButton.js.map +1 -1
- package/components/OffsetWellPickerV2/components/Table/MetricsAddMenu.js +1 -1
- package/components/OffsetWellPickerV2/components/Table/MetricsAddMenu.js.map +1 -1
- package/components/OffsetWellPickerV3/components/CustomSelectionView/components/Table/MetricsAddMenu.js +1 -1
- package/components/OffsetWellPickerV3/components/CustomSelectionView/components/Table/MetricsAddMenu.js.map +1 -1
- package/components/OffsetWellPickerV3/components/CustomSelectionView/index.js +1 -1
- package/components/OffsetWellPickerV3/components/CustomSelectionView/index.js.map +1 -1
- package/components/OffsetWellPickerV3/components/OffsetWellSelectionView/index.js +1 -1
- package/components/OffsetWellPickerV3/components/OffsetWellSelectionView/index.js.map +1 -1
- package/components/OffsetWellPickerV3/components/TabSelection/ToggleMapButton.js +1 -1
- package/components/OffsetWellPickerV3/components/TabSelection/ToggleMapButton.js.map +1 -1
- package/components/OffsetWellPickerV3/components/TabSelection/index.js +1 -1
- package/components/OffsetWellPickerV3/components/TabSelection/index.js.map +1 -1
- package/components/OffsetWellPickerV3/components/WellHubView/index.js +1 -1
- package/components/OffsetWellPickerV3/components/WellHubView/index.js.map +1 -1
- package/components/OffsetWellPickerV3/components/shared/OffsetWellTableHead.js +1 -1
- package/components/OffsetWellPickerV3/components/shared/OffsetWellTableHead.js.map +1 -1
- package/components/OffsetWellPickerV4/index.d.ts +1 -1
- package/components/OffsetWellPickerV4/index.d.ts.map +1 -1
- package/components/OffsetWellPickerV4/index.js +1 -1
- package/components/OffsetWellPickerV4/index.js.map +1 -1
- package/components/OffsetWellPickerV5/OffsetWellPickerV5.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/OffsetWellPickerV5.js +1 -1
- package/components/OffsetWellPickerV5/OffsetWellPickerV5.js.map +1 -1
- package/components/OffsetWellPickerV5/components/Filter/Filter.d.ts +1 -9
- package/components/OffsetWellPickerV5/components/Filter/Filter.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Filter/Filter.js +1 -1
- package/components/OffsetWellPickerV5/components/Filter/Filter.js.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/OffsetWellMap.d.ts +1 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/OffsetWellMap.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/OffsetWellMap.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/MapHints/MapHints.d.ts +1 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/MapHints/MapHints.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/MapHints/MapHints.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/RadiusInput/RadiusInput.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/components/RadiusInput/RadiusInput.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/constants.d.ts +25 -2
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/constants.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/constants.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/index.d.ts +1 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/index.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useLassoSelection.d.ts +3 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useLassoSelection.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useLassoSelection.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusCircle.d.ts +3 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusCircle.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusCircle.js +1 -1
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.d.ts +21 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.d.ts.map +1 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.js +2 -0
- package/components/OffsetWellPickerV5/components/Map/OffsetWellMap/hooks/useRadiusResize.js.map +1 -0
- package/components/OffsetWellPickerV5/components/Map/WellsMap.d.ts +1 -0
- package/components/OffsetWellPickerV5/components/Map/WellsMap.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/components/Map/WellsMap.js +1 -1
- package/components/OffsetWellPickerV5/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js +1 -1
- package/components/OffsetWellPickerV5/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js.map +1 -1
- package/components/OffsetWellPickerV5/components/OffsetWellsTable/OffsetWellsTable.js +1 -1
- package/components/OffsetWellPickerV5/components/OffsetWellsTable/OffsetWellsTable.js.map +1 -1
- package/components/OffsetWellPickerV5/constants.d.ts +1 -0
- package/components/OffsetWellPickerV5/constants.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/constants.js +1 -1
- package/components/OffsetWellPickerV5/constants.js.map +1 -1
- package/components/OffsetWellPickerV5/effects/useAdvancedWells.d.ts +1 -1
- package/components/OffsetWellPickerV5/effects/useAdvancedWells.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/effects/useAdvancedWells.js +1 -1
- package/components/OffsetWellPickerV5/effects/useAdvancedWells.js.map +1 -1
- package/components/OffsetWellPickerV5/effects/useFetchWells.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/effects/useFetchWells.js +1 -1
- package/components/OffsetWellPickerV5/effects/useFilteredWells.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/effects/useFilteredWells.js +1 -1
- package/components/OffsetWellPickerV5/effects/useFilteredWells.js.map +1 -1
- package/components/OffsetWellPickerV5/effects/useSortedWells.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/effects/useSortedWells.js +1 -1
- package/components/OffsetWellPickerV5/effects/useSortedWells.js.map +1 -1
- package/components/OffsetWellPickerV5/stores/filter-store/FilterStoreProvider.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/stores/filter-store/FilterStoreProvider.js +1 -1
- package/components/OffsetWellPickerV5/stores/filter-store/FilterStoreProvider.js.map +1 -1
- package/components/OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.d.ts +15 -0
- package/components/OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.d.ts.map +1 -0
- package/components/OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.js +2 -0
- package/{cjs-bundle/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.module.css.js.map → components/OffsetWellPickerV5/stores/filter-store/utils/normalizeFilters.js.map} +1 -1
- package/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.d.ts +2 -0
- package/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.d.ts.map +1 -0
- package/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.js +2 -0
- package/components/OffsetWellPickerV5/utils/getDefaultRadiusMiles.js.map +1 -0
- package/components/OffsetWellPickerV5/utils/getIsImperial.d.ts +1 -1
- package/components/OffsetWellPickerV5/utils/getIsImperial.d.ts.map +1 -1
- package/components/OffsetWellPickerV5/utils/getIsImperial.js.map +1 -1
- package/components/PadOffsetsPicker/StagesSelector.js +1 -1
- package/components/PadOffsetsPicker/StagesSelector.js.map +1 -1
- package/components/PadOffsetsPickerV2/PadOffsetsPickerV2.js +1 -1
- package/componentsV2/AppHeader/V3/Actions/Actions.d.ts.map +1 -1
- package/componentsV2/AppHeader/V3/Actions/Actions.js +1 -1
- package/package.json +2 -1
- package/cjs-bundle/components/OffsetWellPickerV4/OffsetWellPickerV4.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/OffsetWellPickerV4.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/OffsetWellPickerV4.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/OffsetWellPickerV4.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/AppHeader/AppHeader.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/AppHeader/AppHeader.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/AppHeader/AppHeader.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/Filter.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/Filter.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/Filter.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/Filter.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/MultiSelect.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/MultiSelect.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/PeriodSelect.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/PeriodSelect.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/RadiusInput.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/RadiusInput.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/SingleSelect.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/SingleSelect.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/WellSection.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Filter/WellSection.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Map/WellsMap.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Map/WellsMap.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Map/WellsMap.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Map/WellsMap.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetResultSection.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetResultSection.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetTypesSection.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetTypesSection.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSelect.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSelect.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSettingMenu.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSettingMenu.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/SubjectWellMark.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/SubjectWellMark.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/ViewWellSectionsName.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/OffsetWellsTable/ViewWellSectionsName.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Toolbar/Toolbar.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Toolbar/Toolbar.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/components/Toolbar/Toolbar.module.css.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/components/Toolbar/Toolbar.module.css.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/constants.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/constants.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useAdvancedWells.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useAdvancedWells.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useAssetsData.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useAssetsData.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useBicWells.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useBicWells.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanies.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanies.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanyMetricKey.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanyMetricKey.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanyProvider.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useCompanyProvider.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFetchWells.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFetchWells.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFilterOptions.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFilterOptions.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFilteredWells.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useFilteredWells.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useSortedWells.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useSortedWells.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useTableColumns.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/effects/useTableColumns.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/utils/apiCalls.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/utils/apiCalls.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/utils/index.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/utils/index.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/utils/timePeriod.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/utils/timePeriod.js.map +0 -1
- package/cjs-bundle/components/OffsetWellPickerV4/utils/unitSystem.js +0 -2
- package/cjs-bundle/components/OffsetWellPickerV4/utils/unitSystem.js.map +0 -1
- package/components/OffsetWellPickerV4/OffsetWellPickerV4.js +0 -2
- package/components/OffsetWellPickerV4/OffsetWellPickerV4.js.map +0 -1
- package/components/OffsetWellPickerV4/OffsetWellPickerV4.module.css.js +0 -2
- package/components/OffsetWellPickerV4/OffsetWellPickerV4.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/AppHeader/AppHeader.js +0 -2
- package/components/OffsetWellPickerV4/components/AppHeader/AppHeader.js.map +0 -1
- package/components/OffsetWellPickerV4/components/AppHeader/AppHeader.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/AppHeader/AppHeader.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.js +0 -2
- package/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.js.map +0 -1
- package/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/CustomInfoIcon/CustomInfoIcon.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/Filter.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/Filter.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/Filter.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/Filter.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/MultiSelect.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/MultiSelect.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/PeriodSelect.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/PeriodSelect.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/RadiusInput.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/RadiusInput.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/SingleSelect.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/SingleSelect.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Filter/WellSection.js +0 -2
- package/components/OffsetWellPickerV4/components/Filter/WellSection.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Map/WellsMap.js +0 -2
- package/components/OffsetWellPickerV4/components/Map/WellsMap.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Map/WellsMap.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/Map/WellsMap.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AdvancedSearch.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetResultSection.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetResultSection.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetTypesSection.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetTypesSection.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSelect.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSelect.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSettingMenu.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSettingMenu.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableRow.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/SubjectWellMark.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/SubjectWellMark.js.map +0 -1
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/ViewWellSectionsName.js +0 -2
- package/components/OffsetWellPickerV4/components/OffsetWellsTable/ViewWellSectionsName.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Toolbar/Toolbar.js +0 -2
- package/components/OffsetWellPickerV4/components/Toolbar/Toolbar.js.map +0 -1
- package/components/OffsetWellPickerV4/components/Toolbar/Toolbar.module.css.js +0 -2
- package/components/OffsetWellPickerV4/components/Toolbar/Toolbar.module.css.js.map +0 -1
- package/components/OffsetWellPickerV4/constants.js +0 -2
- package/components/OffsetWellPickerV4/constants.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useAdvancedWells.js +0 -2
- package/components/OffsetWellPickerV4/effects/useAdvancedWells.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useAssetsData.js +0 -2
- package/components/OffsetWellPickerV4/effects/useAssetsData.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useBicWells.js +0 -2
- package/components/OffsetWellPickerV4/effects/useBicWells.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useCompanies.js +0 -2
- package/components/OffsetWellPickerV4/effects/useCompanies.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useCompanyMetricKey.js +0 -2
- package/components/OffsetWellPickerV4/effects/useCompanyMetricKey.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useCompanyProvider.js +0 -2
- package/components/OffsetWellPickerV4/effects/useCompanyProvider.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useFetchWells.js +0 -2
- package/components/OffsetWellPickerV4/effects/useFetchWells.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useFilterOptions.js +0 -2
- package/components/OffsetWellPickerV4/effects/useFilterOptions.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useFilteredWells.js +0 -2
- package/components/OffsetWellPickerV4/effects/useFilteredWells.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useSortedWells.js +0 -2
- package/components/OffsetWellPickerV4/effects/useSortedWells.js.map +0 -1
- package/components/OffsetWellPickerV4/effects/useTableColumns.js +0 -2
- package/components/OffsetWellPickerV4/effects/useTableColumns.js.map +0 -1
- package/components/OffsetWellPickerV4/utils/apiCalls.js +0 -2
- package/components/OffsetWellPickerV4/utils/apiCalls.js.map +0 -1
- package/components/OffsetWellPickerV4/utils/index.js +0 -2
- package/components/OffsetWellPickerV4/utils/index.js.map +0 -1
- package/components/OffsetWellPickerV4/utils/timePeriod.js +0 -2
- package/components/OffsetWellPickerV4/utils/timePeriod.js.map +0 -1
- package/components/OffsetWellPickerV4/utils/unitSystem.js +0 -2
- package/components/OffsetWellPickerV4/utils/unitSystem.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AssetResultSection.js","sources":["../../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetResultSection.js"],"sourcesContent":["import { useEffect, useMemo, useRef, useState } from 'react';\nimport classNames from 'classnames';\nimport PropTypes from 'prop-types';\nimport { get, isEmpty, startCase, sum } from 'lodash';\nimport {\n makeStyles,\n List,\n ListSubheader,\n Chip,\n ListItem,\n Checkbox,\n Typography,\n} from '@material-ui/core';\n\nimport { StatusOptions, ROWS_PER_PAGE } from '../../../constants';\n\nimport { SEARCH_CATEGORIES } from './constants';\n\nconst PAGE_NAME = 'AssetResultSection';\nconst useStyles = makeStyles(theme => ({\n assetListWrapper: {\n margin: '8px 0',\n flex: 1,\n },\n assetListContainer: {\n maxHeight: '350px',\n backgroundColor: theme.palette.background.paper,\n position: 'relative',\n overflow: 'auto',\n },\n listSection: {\n backgroundColor: 'inherit',\n },\n ul: {\n backgroundColor: 'inherit',\n padding: 0,\n },\n listGutters: {\n padding: '2px 8px',\n },\n assetTypeSubheaderChip: {\n height: '24px',\n color: theme.palette.primary.text6,\n },\n assetItemTextRoot: {\n minWidth: '300px',\n },\n assetItemTextPrimary: {\n overflow: 'hidden',\n whiteSpace: 'nowrap',\n textOverflow: 'ellipsis',\n },\n loadingInfo: {\n textAlign: 'center',\n fontSize: '12px',\n lineHeight: '17px',\n color: theme.palette.primary.text8,\n },\n empty: {\n color: theme.palette.primary.text6,\n fontSize: '12px',\n fontStyle: 'italic',\n marginLeft: '8px',\n },\n menuItem: {\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n width: '100%',\n },\n allMenuItem: {\n boxShadow: 'inset 0px -1px 0px rgba(255, 255, 255, 0.25)',\n },\n statusWrapper: {\n display: 'flex',\n alignItems: 'center',\n width: '102px',\n },\n status: {\n width: '8px',\n height: '8px',\n marginRight: '8px',\n borderRadius: '50%',\n cursor: 'default',\n },\n}));\n\nconst isLastPage = (data, page) => {\n return !data.find(([_, value]) => value.length === ROWS_PER_PAGE * page);\n};\n\nconst AssetResultSection = ({\n subjectWellId,\n page,\n assetType,\n loading,\n groupedAssets,\n onClickAsset,\n onClickAllAsset,\n onScrollReached,\n}) => {\n const classes = useStyles();\n const listRef = useRef(null);\n const [scrollPosition, setScrollPosition] = useState('top');\n const [assetsLen, setAssetsLen] = useState(0);\n const assetsNum = sum(groupedAssets?.map(([_, assets]) => assets?.length || 0));\n\n const [indeterminate, isAllWellsSelected] = useMemo(() => {\n if (groupedAssets.length === 1) {\n const assets = groupedAssets[0][1];\n const selectedCount = assets.filter(asset => asset.checked).length;\n const indeterminate = selectedCount > 0 && assets.length !== selectedCount;\n const isAllWellsSelected = selectedCount === assets.length;\n return [indeterminate, isAllWellsSelected];\n }\n return [false, false];\n }, [groupedAssets]);\n\n useEffect(() => {\n if (loading) {\n setAssetsLen(assetsNum);\n return;\n }\n if (scrollPosition === 'top') {\n listRef.current.scrollTo(0, 5);\n }\n if (scrollPosition === 'bottom') {\n listRef.current.scrollTo(0, listRef.current.scrollHeight - listRef.current.offsetHeight - 5);\n }\n if (scrollPosition === 'auto') {\n listRef.current.scrollTo(\n 0,\n ((listRef.current.scrollHeight - listRef.current.offsetHeight) * assetsLen) / assetsNum\n );\n }\n }, [loading]);\n\n const handleScrollList = e => {\n if (e.target.scrollHeight === e.target.offsetHeight) return;\n const currentScrollBottom = e.target.scrollTop + e.target.offsetHeight;\n\n // NOTE: if scroll is near 1px from the bottom, then load new data.\n if (\n Math.abs(e.target.scrollHeight - currentScrollBottom) < 1 &&\n !isLastPage(groupedAssets, page)\n ) {\n setScrollPosition('auto');\n onScrollReached('bottom');\n }\n };\n\n return (\n <div className={classes.assetListWrapper}>\n <List\n className={classes.assetListContainer}\n subheader={<li />}\n onScroll={handleScrollList}\n ref={listRef}\n >\n {groupedAssets.map(([assetTypeKey, asstes]) => (\n <li key={`section-${assetTypeKey}`} className={classes.listSection}>\n <ul className={classes.ul}>\n {!assetType && (\n <ListSubheader classes={{ gutters: classes.listGutters }}>\n <Chip\n key={assetTypeKey}\n className={classes.assetTypeSubheaderChip}\n variant=\"outlined\"\n label={SEARCH_CATEGORIES[assetTypeKey].labelPlural}\n />\n </ListSubheader>\n )}\n {assetType && (\n <ListItem\n button\n classes={{ gutters: classes.listGutters }}\n onClick={() => onClickAllAsset(!isAllWellsSelected, assetTypeKey)}\n >\n <div className={classNames(classes.menuItem, classes.allMenuItem)}>\n <div>\n <Checkbox\n checked={isAllWellsSelected}\n indeterminate={indeterminate}\n style={{ marginRight: 8 }}\n />\n All\n </div>\n </div>\n </ListItem>\n )}\n {asstes.map(asset => (\n <ListItem\n data-testid={`${PAGE_NAME}_item_${asset.name}MenuItem`}\n button\n classes={{ gutters: classes.listGutters }}\n key={`item-${assetTypeKey}-${\n get(asset, 'asset_id') ? get(asset, 'asset_id') : get(asset, 'id')\n }`}\n disabled={\n (asset.type === SEARCH_CATEGORIES.well.name &&\n !asset.visibility.includes('visible')) ||\n !asset.redirectAssetId ||\n asset.redirectAssetId === subjectWellId\n }\n onClick={() => onClickAsset(asset, assetTypeKey)}\n >\n <div className={classes.menuItem}>\n <div>\n <Checkbox checked={asset.checked} style={{ marginRight: 8 }} />\n {asset.name}\n </div>\n <div className={classes.statusWrapper}>\n <div\n className={classes.status}\n style={{\n background: StatusOptions.find(item => item.value === asset.status)\n ?.color,\n }}\n />\n {startCase(asset.status)}\n </div>\n </div>\n </ListItem>\n ))}\n </ul>\n </li>\n ))}\n {isEmpty(groupedAssets) && (\n <div className={classes.empty}>Your search did not match any Asset Name</div>\n )}\n </List>\n {loading && (\n <Typography data-testid={`${PAGE_NAME}_loading`} className={classes.loadingInfo}>\n Loading...\n </Typography>\n )}\n </div>\n );\n};\n\nAssetResultSection.propTypes = {\n subjectWellId: PropTypes.number.isRequired,\n page: PropTypes.number.isRequired,\n assetType: PropTypes.string.isRequired,\n loading: PropTypes.bool.isRequired,\n groupedAssets: PropTypes.arrayOf(PropTypes.shape({})).isRequired,\n onClickAsset: PropTypes.func.isRequired,\n onClickAllAsset: PropTypes.func.isRequired,\n onScrollReached: PropTypes.func.isRequired,\n};\n\nexport default AssetResultSection;\n"],"names":["useStyles","makeStyles","theme","assetListWrapper","margin","flex","assetListContainer","maxHeight","backgroundColor","palette","background","paper","position","overflow","listSection","ul","padding","listGutters","assetTypeSubheaderChip","height","color","primary","text6","assetItemTextRoot","minWidth","assetItemTextPrimary","whiteSpace","textOverflow","loadingInfo","textAlign","fontSize","lineHeight","text8","empty","fontStyle","marginLeft","menuItem","display","alignItems","justifyContent","width","allMenuItem","boxShadow","statusWrapper","status","marginRight","borderRadius","cursor","AssetResultSection","_ref3","subjectWellId","page","assetType","loading","groupedAssets","onClickAsset","onClickAllAsset","onScrollReached","classes","listRef","useRef","useState","_useState2","_slicedToArray","_useState","scrollPosition","setScrollPosition","_useState4","_useState3","assetsLen","setAssetsLen","assetsNum","sum","map","_ref4","_ref5","assets","length","useMemo","selectedCount","filter","asset","checked","_useMemo2","_useMemo","indeterminate","isAllWellsSelected","useEffect","current","scrollTo","scrollHeight","offsetHeight","_jsxs","className","children","List","subheader","_jsx","onScroll","e","target","currentScrollBottom","scrollTop","Math","abs","data","find","_ref","_ref2","ROWS_PER_PAGE","isLastPage","ref","_ref6","_ref7","assetTypeKey","asstes","ListSubheader","gutters","Chip","variant","label","SEARCH_CATEGORIES","labelPlural","ListItem","button","onClick","classNames","Checkbox","style","_StatusOptions$find","concat","name","disabled","type","well","visibility","includes","redirectAssetId","StatusOptions","item","value","startCase","get","isEmpty","Typography","propTypes","PropTypes","number","isRequired","string","bool","arrayOf","shape","func"],"mappings":"miBAkBA,IACMA,EAAYC,GAAW,SAAAC,GAAK,MAAK,CACrCC,iBAAkB,CAChBC,OAAQ,QACRC,KAAM,GAERC,mBAAoB,CAClBC,UAAW,QACXC,gBAAiBN,EAAMO,QAAQC,WAAWC,MAC1CC,SAAU,WACVC,SAAU,QAEZC,YAAa,CACXN,gBAAiB,WAEnBO,GAAI,CACFP,gBAAiB,UACjBQ,QAAS,GAEXC,YAAa,CACXD,QAAS,WAEXE,uBAAwB,CACtBC,OAAQ,OACRC,MAAOlB,EAAMO,QAAQY,QAAQC,OAE/BC,kBAAmB,CACjBC,SAAU,SAEZC,qBAAsB,CACpBZ,SAAU,SACVa,WAAY,SACZC,aAAc,YAEhBC,YAAa,CACXC,UAAW,SACXC,SAAU,OACVC,WAAY,OACZX,MAAOlB,EAAMO,QAAQY,QAAQW,OAE/BC,MAAO,CACLb,MAAOlB,EAAMO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EV,WAAAiD,OAhEahB,GAkErB,IACA6B,EAAQzF,IACP2C,EAAA,MAAA,CAAKJ,UAAWnC,EAAQzB,MAAM6D,SAAA,gDAGjCzC,GACC4C,EAAC+C,EAAU,CAAC,cAAA,GAAAd,OAtNF,qBAsNsC,YAACrC,UAAWnC,EAAQ9B,YAAYkE,SAAA,iBAMxF,EAEA9C,EAAmBiG,UAAY,CAC7B/F,cAAegG,EAAUC,OAAOC,WAChCjG,KAAM+F,EAAUC,OAAOC,WACvBhG,UAAW8F,EAAUG,OAAOD,WAC5B/F,QAAS6F,EAAUI,KAAKF,WACxB9F,cAAe4F,EAAUK,QAAQL,EAAUM,MAAM,CAAA,IAAKJ,WACtD7F,aAAc2F,EAAUO,KAAKL,WAC7B5F,gBAAiB0F,EAAUO,KAAKL,WAChC3F,gBAAiByF,EAAUO,KAAKL"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/slicedToArray";import r from"prop-types";import{makeStyles as t,Typography as i,Chip as a}from"@material-ui/core";import{CATEGORY_KEY_VALUES as o}from"./constants.js";import{jsxs as p,jsx as n}from"react/jsx-runtime";var l=t((function(e){return{assetSelectorWrapper:{margin:8},description:{color:e.palette.primary.text6,fontSize:"12px",lineHeight:"17px",paddingBottom:"8px"},assetTypeChip:{marginRight:"8px",color:e.palette.primary.text6,"&:last-child":{marginRight:"0px"}}}})),s=function(r){var t=r.onClickAssetType,s=l();return p("div",{className:s.assetSelectorWrapper,children:[n(i,{className:s.description,children:"I'm looking for..."}),n("div",{children:o.map((function(r){var i=e(r,2),o=i[0],p=i[1];return n(a,{"data-testid":"".concat("AssetTypesSection","_chip_").concat(p.labelPlural),className:s.assetTypeChip,variant:"outlined",label:p.labelPlural,onClick:function(){return t(o)}},o)}))})]})};s.propTypes={onClickAssetType:r.func.isRequired};export{s as default};
|
|
2
|
-
//# sourceMappingURL=AssetTypesSection.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AssetTypesSection.js","sources":["../../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AssetTypesSection.js"],"sourcesContent":["import PropTypes from 'prop-types';\nimport { makeStyles, Typography, Chip } from '@material-ui/core';\n\nimport { CATEGORY_KEY_VALUES } from './constants';\n\nconst PAGE_NAME = 'AssetTypesSection';\n\nconst useStyles = makeStyles(theme => ({\n assetSelectorWrapper: {\n margin: 8,\n },\n description: {\n color: theme.palette.primary.text6,\n fontSize: '12px',\n lineHeight: '17px',\n paddingBottom: '8px',\n },\n assetTypeChip: {\n marginRight: '8px',\n color: theme.palette.primary.text6,\n '&:last-child': {\n marginRight: '0px',\n },\n },\n}));\n\nconst AssetTypesSection = ({ onClickAssetType }) => {\n const classes = useStyles();\n\n return (\n <div className={classes.assetSelectorWrapper}>\n <Typography className={classes.description}>I'm looking for...</Typography>\n <div>\n {CATEGORY_KEY_VALUES.map(([key, item]) => (\n <Chip\n data-testid={`${PAGE_NAME}_chip_${item.labelPlural}`}\n key={key}\n className={classes.assetTypeChip}\n variant=\"outlined\"\n label={item.labelPlural}\n onClick={() => onClickAssetType(key)}\n />\n ))}\n </div>\n </div>\n );\n};\n\nAssetTypesSection.propTypes = {\n onClickAssetType: PropTypes.func.isRequired,\n};\n\nexport default AssetTypesSection;\n"],"names":["useStyles","makeStyles","theme","assetSelectorWrapper","margin","description","color","palette","primary","text6","fontSize","lineHeight","paddingBottom","assetTypeChip","marginRight","AssetTypesSection","_ref","onClickAssetType","classes","_jsxs","className","children","_jsx","Typography","CATEGORY_KEY_VALUES","map","_ref2","_ref3","_slicedToArray","key","item","Chip","concat","labelPlural","variant","label","onClick","propTypes","PropTypes","func","isRequired"],"mappings":"8PAKA,IAEMA,EAAYC,GAAW,SAAAC,GAAK,MAAK,CACrCC,qBAAsB,CACpBC,OAAQ,GAEVC,YAAa,CACXC,MAAOJ,EAAMK,QAAQC,QAAQC,MAC7BC,SAAU,OACVC,WAAY,OACZC,cAAe,OAEjBC,cAAe,CACbC,YAAa,MACbR,MAAOJ,EAAMK,QAAQC,QAAQC,MAC7B,eAAgB,CACdK,YAAa,QAGlB,IAEKC,EAAoB,SAA0BC,GAAA,IAAvBC,IAAAA,iBACrBC,EAAUlB,IAEhB,OACEmB,EAAA,MAAA,CAAKC,UAAWF,EAAQf,qBAAqBkB,SAAA,CAC3CC,EAACC,EAAU,CAACH,UAAWF,EAAQb,YAAYgB,SAAA,uBAC3CC,EAAA,MAAA,CAAAD,SACGG,EAAoBC,KAAI,SAAAC,GAAA,IAAAC,EAAAC,EAAAF,EAAA,GAAEG,EAAGF,EAAA,GAAEG,EAAIH,EAAA,GAAA,OAClCL,EAACS,EAAI,CACH,cAAA,GAAAC,OA9BM,oBA8BmB,UAAAA,OAASF,EAAKG,aAEvCb,UAAWF,EAAQL,cACnBqB,QAAQ,WACRC,MAAOL,EAAKG,YACZG,QAAS,WAAA,OAAMnB,EAAiBY,EAAI,GAJ/BA,UAUjB,EAEAd,EAAkBsB,UAAY,CAC5BpB,iBAAkBqB,EAAUC,KAAKC"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/slicedToArray";import{useState as t,useMemo as r,useRef as o,useEffect as n}from"react";import i from"prop-types";import{get as s}from"lodash";import{withStyles as a,Tooltip as l,makeStyles as p,Chip as c,Input as d}from"@material-ui/core";import m from"@material-ui/icons/Close";import"../../../utils/apiCalls.js";import"../../../effects/useAdvancedWells.js";import"@babel/runtime/helpers/toConsumableArray";import"@babel/runtime/helpers/defineProperty";import"@babel/runtime/helpers/asyncToGenerator";import"@babel/runtime/regenerator";import"../../../constants.js";import"../../../../../utils/index.js";import"../../../../../constants/goals.js";import"../../../../../constants/segment.js";import"../../../../../constants/alerts.js";import"../../../../../constants/apps.js";import"../../../../../constants/drillstring.js";import"../../../../../constants/completion.js";import"../../../../../constants/appPackages.js";import"../../../../../constants/notifications.js";import"../../../../../constants/feed.js";import"../../../../../constants/bha.js";import"../../../../../constants/corvaCompanyId.js";import"../../../../GradientManager/configuration/constants.js";import"@babel/runtime/helpers/typeof";import"moment";import"react-virtualized";import{useAssetsData as u}from"../../../effects/useAssetsData.js";import"../../../../../permissions/PermissionsContext.js";import"../../../../../permissions/constants/index.js";import"../../../../../permissions/withPermissionsHOC.js";import"../../../../../clients/jsonApi/index.js";import"../../../../../permissions/ProvidePermissions.js";import f from"./AssetTypesSection.js";import h from"./AssetResultSection.js";import{SEARCH_CATEGORIES as x,CATEGORY_KEY_VALUES as g}from"./constants.js";import{jsxs as b,jsx as j,Fragment as y}from"react/jsx-runtime";var C=a((function(){return{tooltip:{backgroundColor:"#414141",color:"#ffffff",fontSize:"11px",lineHeight:"16px",borderRadius:"4px",boxShadow:"0px 4px 4px rgba(0, 0, 0, 0.12)",padding:"4px"}}}))(l),I=p((function(e){return{wrapper:{width:function(e){return e.searchWidth},maxWidth:"996px",display:"flex",flexDirection:"column",padding:16},inputWrapper:{display:"flex",width:"auto",margin:"0 8px 8px",alignItems:"center",flexWrap:"nowrap",justifyContent:"space-between"},selectedChip:{height:"24px",margin:"4px"},selectedChipDeleteIcon:{width:"16px",height:"16px",color:e.palette.primary.text6,"&:hover":{color:e.palette.primary.text1}},selectedLabel:{fontWeight:400,fontSize:"16px",lineHeight:"22px",color:e.palette.primary.text1,whiteSpace:"nowrap",paddingLeft:"4px",paddingRight:"8px"},disabledIcon:{width:"16px",height:"16px",color:e.palette.primary.text6,opacity:.4},closeIconButton:{padding:0,"&:hover $closeIcon":{color:e.palette.primary.text1}},searchInput:{width:"100%",display:"flex",flexDirection:"row",justifyContent:"space-between",alignItems:"center",borderBottom:"2px solid #03BCD4"},closeIcon:{color:e.palette.primary.text6,fontSize:"18px"}}})),v=function(i){var a=i.company,l=i.subjectWellId,p=i.value,v=i.selectedWellIds,w=i.onChange,A=t(null),W=e(A,2),R=W[0],S=W[1],k=t(null),D=e(k,2),P=D[0],T=D[1],q=t(1),z=e(q,2),N=z[0],L=z[1],B=r((function(){return window.innerWidth-32}),[]),H=I({searchWidth:B}),O=o();n((function(){T(p)}),[p]);var G=u(P,R,N,a,v),K=e(G,2),U=K[0],F=K[1],M=r((function(){return R&&F&&0!==F.length?F[0][1].filter((function(e){return e.checked})).length:0}),[R,F]);return b("div",{className:H.wrapper,children:[j("div",{className:H.inputWrapper,children:b("div",{className:H.searchInput,children:[R&&b(y,{children:[j(c,{"data-not-migrated-muichip":!0,classes:{root:H.selectedChip,deleteIcon:H.selectedChipDeleteIcon},label:s(x,[R,"labelPlural"],"Assets"),deleteIcon:j(m,{}),onDelete:function(){S(null)}}),M>0&&b("span",{className:H.selectedLabel,children:[M," Selected"]})]}),j(d,{"data-testid":"".concat("AutoCompleteAssetSearch","_searchInput"),inputRef:O,autoFocus:!0,disableUnderline:!0,fullWidth:!0,value:P||"",placeholder:"Add Offset ...",onChange:function(e){var t=e.target.value;O.current.focus(),T(t),L(1)},onKeyUp:function(t){var r=t.target.value,o=t.keyCode,n=g.find((function(t){var o=e(t,2);return o[0],o[1].autoCategorizedKey===r.trim().toLowerCase()}));if(n&&(13===o||32===o))return T(""),S(n[0]),void L(1);""===r&&8===o&&(S(null),L(1))}}),j(C,{title:"Clear",children:j(m,{className:R||P?H.selectedChipDeleteIcon:H.disabledIcon,onClick:function(){O.current.focus(),T(""),S(null),L(1)}})})]})}),!R&&!P&&j(f,{onClickAssetType:function(e){O.current.focus(),S(e),L(1)}}),(R||P)&&j(h,{subjectWellId:l,page:N,assetType:R,loading:U,groupedAssets:F,onClickAsset:function(e,t){w(!e.checked,[e.redirectAssetId],t)},onClickAllAsset:function(e,t){var r=F[0][1];w(e,r.map((function(e){return e.redirectAssetId})),t)},onScrollReached:function(e){"top"===e&&N>1&&L((function(e){return e-1})),"bottom"===e&&L((function(e){return e+1}))}})]})};v.propTypes={subjectWellId:i.number.isRequired,company:i.number.isRequired,value:i.string.isRequired,selectedWellIds:i.arrayOf(i.number).isRequired,onChange:i.func.isRequired};export{v as default};
|
|
2
|
-
//# sourceMappingURL=AutoCompleteAssetSearch.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AutoCompleteAssetSearch.js","sources":["../../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/AutoCompleteAssetSearch.js"],"sourcesContent":["import { useState, useRef, useEffect, useMemo } from 'react';\nimport PropTypes from 'prop-types';\nimport { get } from 'lodash';\nimport { makeStyles, Chip, Input, Tooltip, withStyles } from '@material-ui/core';\nimport CloseIcon from '@material-ui/icons/Close';\n\nimport { useAssetsData } from '../../../effects';\n\nimport AssetTypesSection from './AssetTypesSection';\nimport AssetResultSection from './AssetResultSection';\nimport { SEARCH_CATEGORIES, CATEGORY_KEY_VALUES } from './constants';\n\nconst PAGE_NAME = 'AutoCompleteAssetSearch';\n\nconst StyledTooltip = withStyles(() => ({\n tooltip: {\n backgroundColor: '#414141',\n color: '#ffffff',\n fontSize: '11px',\n lineHeight: '16px',\n borderRadius: '4px',\n boxShadow: '0px 4px 4px rgba(0, 0, 0, 0.12)',\n padding: '4px',\n },\n}))(Tooltip);\n\nconst useStyles = makeStyles(theme => ({\n wrapper: {\n width: ({ searchWidth }) => searchWidth,\n maxWidth: '996px',\n display: 'flex',\n flexDirection: 'column',\n padding: 16,\n },\n inputWrapper: {\n display: 'flex',\n width: 'auto',\n margin: '0 8px 8px',\n alignItems: 'center',\n flexWrap: 'nowrap',\n justifyContent: 'space-between',\n },\n selectedChip: {\n height: '24px',\n margin: '4px',\n },\n selectedChipDeleteIcon: {\n width: '16px',\n height: '16px',\n color: theme.palette.primary.text6,\n '&:hover': {\n color: theme.palette.primary.text1,\n },\n },\n selectedLabel: {\n fontWeight: 400,\n fontSize: '16px',\n lineHeight: '22px',\n color: theme.palette.primary.text1,\n whiteSpace: 'nowrap',\n paddingLeft: '4px',\n paddingRight: '8px',\n },\n disabledIcon: {\n width: '16px',\n height: '16px',\n color: theme.palette.primary.text6,\n opacity: 0.4,\n },\n closeIconButton: {\n padding: 0,\n '&:hover $closeIcon': {\n color: theme.palette.primary.text1,\n },\n },\n searchInput: {\n width: '100%',\n display: 'flex',\n flexDirection: 'row',\n justifyContent: 'space-between',\n alignItems: 'center',\n borderBottom: '2px solid #03BCD4',\n },\n closeIcon: {\n color: theme.palette.primary.text6,\n fontSize: '18px',\n },\n}));\n\nconst AutoCompleteAssetSearch = ({ company, subjectWellId, value, selectedWellIds, onChange }) => {\n const [assetType, setAssetType] = useState(null);\n const [searchKey, setSearchKey] = useState(null);\n const [page, setPage] = useState(1);\n const searchWidth = useMemo(() => window.innerWidth - 32, []);\n const classes = useStyles({ searchWidth });\n const searchInputRef = useRef();\n\n useEffect(() => {\n setSearchKey(value);\n }, [value]);\n\n const [loading, groupedAssets] = useAssetsData(\n searchKey,\n assetType,\n page,\n company,\n selectedWellIds\n );\n\n const selectedCount = useMemo(() => {\n if (!assetType || !groupedAssets || groupedAssets.length === 0) return 0;\n return groupedAssets[0][1].filter(asset => asset.checked).length;\n }, [assetType, groupedAssets]);\n\n const handleDeleteAssetType = () => {\n setAssetType(null);\n };\n\n const handleChangeAssetType = key => {\n searchInputRef.current.focus();\n setAssetType(key);\n setPage(1);\n };\n\n const handleChangeSearchKey = ({ target: { value } }) => {\n searchInputRef.current.focus();\n setSearchKey(value);\n setPage(1);\n };\n\n const handleKeyPress = e => {\n const { value } = e.target;\n const { keyCode } = e;\n\n const availableCategory = CATEGORY_KEY_VALUES.find(\n ([_, item]) => item.autoCategorizedKey === value.trim().toLowerCase()\n );\n\n // NOTE: when type one of categories defined and press enter key or space key\n // then asset type will be auto selected and clear input field\n if (availableCategory && (keyCode === 13 || keyCode === 32)) {\n setSearchKey('');\n setAssetType(availableCategory[0]);\n setPage(1);\n return;\n }\n\n // NOTE: when there is no value in input field and press back space key,\n // then clear asset type as well.\n if (value === '' && keyCode === 8) {\n setAssetType(null);\n setPage(1);\n }\n };\n\n const handleSearchClear = () => {\n searchInputRef.current.focus();\n setSearchKey('');\n setAssetType(null);\n setPage(1);\n };\n\n const handleScrollReached = position => {\n if (position === 'top' && page > 1) {\n setPage(prev => prev - 1);\n }\n if (position === 'bottom') {\n setPage(prev => prev + 1);\n }\n };\n\n const handleChangeAsset = (asset, assetType) => {\n onChange(!asset.checked, [asset.redirectAssetId], assetType);\n };\n\n const handleChangeAllAssets = (isAllAdding, assetType) => {\n const assets = groupedAssets[0][1];\n onChange(\n isAllAdding,\n assets.map(asset => asset.redirectAssetId),\n assetType\n );\n };\n\n return (\n <div className={classes.wrapper}>\n <div className={classes.inputWrapper}>\n <div className={classes.searchInput}>\n {assetType && (\n <>\n <Chip\n data-not-migrated-muichip\n classes={{ root: classes.selectedChip, deleteIcon: classes.selectedChipDeleteIcon }}\n label={get(SEARCH_CATEGORIES, [assetType, 'labelPlural'], 'Assets')}\n deleteIcon={<CloseIcon />}\n onDelete={handleDeleteAssetType}\n />\n {selectedCount > 0 && (\n <span className={classes.selectedLabel}>{selectedCount} Selected</span>\n )}\n </>\n )}\n <Input\n data-testid={`${PAGE_NAME}_searchInput`}\n inputRef={searchInputRef}\n autoFocus\n disableUnderline\n fullWidth\n value={searchKey || ''}\n placeholder=\"Add Offset ...\"\n onChange={handleChangeSearchKey}\n onKeyUp={handleKeyPress}\n />\n <StyledTooltip title=\"Clear\">\n <CloseIcon\n className={\n assetType || searchKey ? classes.selectedChipDeleteIcon : classes.disabledIcon\n }\n onClick={handleSearchClear}\n />\n </StyledTooltip>\n </div>\n </div>\n\n {!assetType && !searchKey && <AssetTypesSection onClickAssetType={handleChangeAssetType} />}\n {(assetType || searchKey) && (\n <AssetResultSection\n subjectWellId={subjectWellId}\n page={page}\n assetType={assetType}\n loading={loading}\n groupedAssets={groupedAssets}\n onClickAsset={handleChangeAsset}\n onClickAllAsset={handleChangeAllAssets}\n onScrollReached={handleScrollReached}\n />\n )}\n </div>\n );\n};\n\nAutoCompleteAssetSearch.propTypes = {\n subjectWellId: PropTypes.number.isRequired,\n company: PropTypes.number.isRequired,\n value: PropTypes.string.isRequired,\n selectedWellIds: PropTypes.arrayOf(PropTypes.number).isRequired,\n onChange: PropTypes.func.isRequired,\n};\n\nexport default AutoCompleteAssetSearch;\n"],"names":["StyledTooltip","withStyles","tooltip","backgroundColor","color","fontSize","lineHeight","borderRadius","boxShadow","padding","Tooltip","useStyles","makeStyles","theme","wrapper","width","_ref","searchWidth","maxWidth","display","flexDirection","inputWrapper","margin","alignItems","flexWrap","justifyContent","selectedChip","height","selectedChipDeleteIcon","palette","primary","text6","text1","selectedLabel","fontWeight","whiteSpace","paddingLeft","paddingRight","disabledIcon","opacity","closeIconButton","searchInput","borderBottom","closeIcon","AutoCompleteAssetSearch","_ref2","company","subjectWellId","value","selectedWellIds","onChange","useState","_useState2","_slicedToArray","_useState","assetType","setAssetType","_useState4","_useState3","searchKey","setSearchKey","_useState6","_useState5","page","setPage","useMemo","window","innerWidth","classes","searchInputRef","useRef","useEffect","useAssetsData","_useAssetsData2","_useAssetsData","loading","groupedAssets","selectedCount","length","filter","asset","checked","_jsxs","className","children","_jsx","_Fragment","Chip","root","deleteIcon","label","get","SEARCH_CATEGORIES","CloseIcon","onDelete","Input","concat","inputRef","autoFocus","disableUnderline","fullWidth","placeholder","_ref3","target","current","focus","onKeyUp","e","keyCode","availableCategory","CATEGORY_KEY_VALUES","find","_ref4","_ref5","autoCategorizedKey","trim","toLowerCase","title","onClick","AssetTypesSection","onClickAssetType","key","AssetResultSection","onClickAsset","redirectAssetId","onClickAllAsset","isAllAdding","assets","map","onScrollReached","position","prev","propTypes","PropTypes","number","isRequired","string","arrayOf","func"],"mappings":"4yDAYA,IAEMA,EAAgBC,GAAW,WAAA,MAAO,CACtCC,QAAS,CACPC,gBAAiB,UACjBC,MAAO,UACPC,SAAU,OACVC,WAAY,OACZC,aAAc,MACdC,UAAW,kCACXC,QAAS,OAEZ,GAVqBR,CAUlBS,GAEEC,EAAYC,GAAW,SAAAC,GAAK,MAAK,CACrCC,QAAS,CACPC,MAAO,SAAAC,GAAc,SAAXC,WAA6B,EACvCC,S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C1BvF,MAAOqF,EAAUG,OAAOD,WACxBtF,gBAAiBoF,EAAUI,QAAQJ,EAAUC,QAAQC,WACrDrF,SAAUmF,EAAUK,KAAKH"}
|
package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
var e={well:{name:"well",labelSingular:"Well",labelPlural:"Wells",autoCategorizedKey:"well",isAssetType:!0},rig:{name:"rig",labelSingular:"Rig",labelPlural:"Rigs",autoCategorizedKey:"rig",isAssetType:!0}};Object.values(e).filter((function(e){return e.autoCategorizedKey})).map((function(e){return e.autoCategorizedKey}));var l=Object.entries(e);export{l as CATEGORY_KEY_VALUES,e as SEARCH_CATEGORIES};
|
|
2
|
-
//# sourceMappingURL=constants.js.map
|
package/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sources":["../../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/AdvancedSearch/constants.js"],"sourcesContent":["export const SEARCH_CATEGORIES = {\n well: {\n name: 'well',\n labelSingular: 'Well',\n labelPlural: 'Wells',\n autoCategorizedKey: 'well',\n isAssetType: true,\n },\n rig: {\n name: 'rig',\n labelSingular: 'Rig',\n labelPlural: 'Rigs',\n autoCategorizedKey: 'rig',\n isAssetType: true,\n },\n};\n\nexport const AUTO_CATEGORIZE_KEYS = Object.values(SEARCH_CATEGORIES)\n .filter(item => item.autoCategorizedKey)\n .map(item => item.autoCategorizedKey);\n\nexport const CATEGORY_KEY_VALUES = Object.entries(SEARCH_CATEGORIES);\n"],"names":["SEARCH_CATEGORIES","well","name","labelSingular","labelPlural","autoCategorizedKey","isAssetType","rig","Object","values","filter","item","map","CATEGORY_KEY_VALUES","entries"],"mappings":"AAAO,IAAMA,EAAoB,CAC/BC,KAAM,CACJC,KAAM,OACNC,cAAe,OACfC,YAAa,QACbC,mBAAoB,OACpBC,aAAa,GAEfC,IAAK,CACHL,KAAM,MACNC,cAAe,MACfC,YAAa,OACbC,mBAAoB,MACpBC,aAAa,IAImBE,OAAOC,OAAOT,GAC/CU,QAAO,SAAAC,GAAI,OAAIA,EAAKN,kBAAkB,IACtCO,KAAI,SAAAD,GAAI,OAAIA,EAAKN,kBAAkB,IAE/B,IAAMQ,EAAsBL,OAAOM,QAAQd"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"prop-types";import{makeStyles as t,FormControl as r,Tooltip as i,Typography as n,MenuItem as o}from"@material-ui/core";import{METRICS_LIST as a,DEFAULT_METRICS_KEY as c}from"../../constants.js";import{getUnitDisplay as l}from"../../../../utils/index.js";import p from"../../../Select/index.js";import{jsx as s}from"react/jsx-runtime";var u=t((function(e){return{metricsForm:{width:"calc(100% - 32px)","& .MuiInputBase-root":{"&:hover $primaryText":{color:e.palette.primary.text1},"&:hover $primaryIcon":{color:e.palette.primary.text1},"&:focused $primaryIcon":{color:e.palette.primary.main}}},metricsSelect:{"&:before":{borderBottom:"none !important"},"&:after":{borderBottom:"none !important"}},primaryText:{fontWeight:500,fontSize:"12px",lineHeight:"14px",letterSpacing:"0.4px",color:e.palette.primary.text7,overflow:"hidden",textOverflow:"ellipsis"},primaryIcon:{color:e.palette.primary.text6},metricsMenuPaper:{backgroundColor:e.palette.background.b9,maxHeight:"calc(100% - 300px)",top:"150px !important"},valueLabel:{display:"-webkit-box",alignItems:"center",WebkitLineClamp:3,WebkitBoxOrient:"vertical",overflowWrap:"break-word",fontWeight:500,fontSize:"12px",lineHeight:"14px",letterSpacing:"0.4px",overflow:"hidden",whiteSpace:"normal"}}}));function m(e){var t=a.find((function(t){return t.key===e}));if(!t)return"";var r=t.unitType?" (".concat(l(t.unitType,t.to),")"):"";return t.label+r}var d=function(e){var t=e.isTooltipVisible,l=e.currentValue,d=e.metricsKeys,f=e.onChange,y=e.setIsMenuOpen,x=u(),h=a.filter((function(e){return!d.includes(e.key)}));return l!==c?s(r,{className:x.metricsForm,children:s(p,{"data-testid":"".concat("MetricsSelect","_select_").concat(l),className:x.metricsSelect,classes:{select:x.primaryText,icon:x.primaryIcon},MenuProps:{paper:x.metricsMenuPaper},value:l,renderValue:function(e){return s(i,{title:t?m(e):"",children:s(n,{className:x.valueLabel,children:m(e)})})},onOpen:function(){return y(!0)},onClose:function(){return y(!1)},onChange:function(e){return f(e.target.value)},children:h.map((function(e){return s(o,{"data-testid":"".concat("MetricsSelect","_option_").concat(e.key,"MenuItem"),value:e.key,children:e.label},e.key)}))})}):s(i,{title:t?m(l):"",children:s(n,{className:x.valueLabel,children:m(l)})})};d.propTypes={isTooltipVisible:e.bool.isRequired,currentValue:e.string.isRequired,metricsKeys:e.arrayOf(e.string).isRequired,onChange:e.func.isRequired,setIsMenuOpen:e.func.isRequired};export{d as MetricsSelect};
|
|
2
|
-
//# sourceMappingURL=MetricsSelect.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MetricsSelect.js","sources":["../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSelect.js"],"sourcesContent":["import PropTypes from 'prop-types';\nimport { MenuItem, FormControl, makeStyles, Typography, Tooltip } from '@material-ui/core';\n\nimport { DEFAULT_METRICS_KEY, METRICS_LIST } from '../../constants';\n\nimport { getUnitDisplay } from '~/utils';\nimport SelectComponent from '~/components/Select';\n\nconst PAGE_NAME = 'MetricsSelect';\n\nconst useStyles = makeStyles(theme => ({\n metricsForm: {\n width: 'calc(100% - 32px)',\n '& .MuiInputBase-root': {\n '&:hover $primaryText': {\n color: theme.palette.primary.text1,\n },\n '&:hover $primaryIcon': {\n color: theme.palette.primary.text1,\n },\n '&:focused $primaryIcon': {\n color: theme.palette.primary.main,\n },\n },\n },\n metricsSelect: {\n '&:before': {\n borderBottom: 'none !important',\n },\n '&:after': {\n borderBottom: 'none !important',\n },\n },\n primaryText: {\n fontWeight: 500,\n fontSize: '12px',\n lineHeight: '14px',\n letterSpacing: '0.4px',\n color: theme.palette.primary.text7,\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n },\n primaryIcon: {\n color: theme.palette.primary.text6,\n },\n metricsMenuPaper: {\n backgroundColor: theme.palette.background.b9,\n maxHeight: 'calc(100% - 300px)',\n top: '150px !important',\n },\n valueLabel: {\n display: '-webkit-box',\n alignItems: 'center',\n WebkitLineClamp: 3,\n WebkitBoxOrient: 'vertical',\n overflowWrap: 'break-word',\n fontWeight: 500,\n fontSize: '12px',\n lineHeight: '14px',\n letterSpacing: '0.4px',\n overflow: 'hidden',\n whiteSpace: 'normal',\n },\n}));\n\nfunction getMetricsLabel(value) {\n const metric = METRICS_LIST.find(item => item.key === value);\n if (!metric) return '';\n const displayUnit = metric.unitType ? ` (${getUnitDisplay(metric.unitType, metric.to)})` : '';\n return metric.label + displayUnit;\n}\n\nexport const MetricsSelect = ({\n isTooltipVisible,\n currentValue,\n metricsKeys,\n onChange,\n setIsMenuOpen,\n}) => {\n const styles = useStyles();\n const filteredMetrics = METRICS_LIST.filter(item => !metricsKeys.includes(item.key));\n return currentValue !== DEFAULT_METRICS_KEY ? (\n <FormControl className={styles.metricsForm}>\n <SelectComponent\n data-testid={`${PAGE_NAME}_select_${currentValue}`}\n className={styles.metricsSelect}\n classes={{ select: styles.primaryText, icon: styles.primaryIcon }}\n MenuProps={{ paper: styles.metricsMenuPaper }}\n value={currentValue}\n renderValue={value => (\n <Tooltip title={isTooltipVisible ? getMetricsLabel(value) : ''}>\n <Typography className={styles.valueLabel}>{getMetricsLabel(value)}</Typography>\n </Tooltip>\n )}\n onOpen={() => setIsMenuOpen(true)}\n onClose={() => setIsMenuOpen(false)}\n onChange={e => onChange(e.target.value)}\n >\n {filteredMetrics.map(item => (\n <MenuItem\n data-testid={`${PAGE_NAME}_option_${item.key}MenuItem`}\n key={item.key}\n value={item.key}\n >\n {item.label}\n </MenuItem>\n ))}\n </SelectComponent>\n </FormControl>\n ) : (\n <Tooltip title={isTooltipVisible ? getMetricsLabel(currentValue) : ''}>\n <Typography className={styles.valueLabel}>{getMetricsLabel(currentValue)}</Typography>\n </Tooltip>\n );\n};\n\nMetricsSelect.propTypes = {\n isTooltipVisible: PropTypes.bool.isRequired,\n currentValue: PropTypes.string.isRequired,\n metricsKeys: PropTypes.arrayOf(PropTypes.string).isRequired,\n onChange: PropTypes.func.isRequired,\n setIsMenuOpen: PropTypes.func.isRequired,\n};\n"],"names":["useStyles","makeStyles","theme","metricsForm","width","color","palette","primary","text1","main","metricsSelect","borderBottom","primaryText","fontWeight","fontSize","lineHeight","letterSpacing","text7","overflow","textOverflow","primaryIcon","text6","metricsMenuPaper","backgroundColor","background","b9","maxHeight","top","valueLabel","display","alignItems","WebkitLineClamp","WebkitBoxOrient","overflowWrap","whiteSpace","getMetricsLabel","value","metric","METRICS_LIST","find","item","key","displayUnit","unitType","getUnitDisplay","to","label","MetricsSelect","_ref","isTooltipVisible","currentValue","metricsKeys","onChange","setIsMenuOpen","styles","filteredMetrics","filter","includes","DEFAULT_METRICS_KEY","_jsx","FormControl","className","children","SelectComponent","PAGE_NAME","classes","select","icon","MenuProps","paper","renderValue","Tooltip","title","Typography","onOpen","onClose","e","target","map","MenuItem","concat","propTypes","PropTypes","bool","isRequired","string","arrayOf","func"],"mappings":"4VAQA,IAEMA,EAAYC,GAAW,SAAAC,GAAK,MAAK,CACrCC,YAAa,CACXC,MAAO,oBACP,uBAAwB,CACtB,uBAAwB,CACtBC,MAAOH,EAAMI,QAAQC,QAAQC,OAE/B,uBAAwB,CACtBH,MAAOH,EAAMI,QAAQC,QAAQC,OAE/B,yBAA0B,CACxBH,MAAOH,EAAMI,QAAQC,QAAQE,QAInCC,cAAe,CACb,WAAY,CACVC,aAAc,mBAEhB,UAAW,CACTA,aAAc,oBAGlBC,YAAa,CACXC,WAAY,IACZC,SAAU,OACVC,WAAY,OACZC,cAAe,QACfX,MAAOH,EAAMI,QAAQC,QAAQU,MAC7BC,SAAU,SACVC,aAAc,YAEhBC,YAAa,CACXf,MAA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SAAU,SAAAwB,GAAC,OAAIxB,EAASwB,EAAEC,OAAOzC,MAAO,EAAA0B,SAEvCP,EAAgBuB,KAAI,SAAAtC,GAAI,OACvBmB,EAACoB,EAAQ,CACP,cAAA,GAAAC,OA5FM,gBA4FmB,YAAAA,OAAWxC,EAAKC,IAAc,YAEvDL,MAAOI,EAAKC,IAAIqB,SAEftB,EAAKM,OAHDN,EAAKC,YASlBkB,EAACY,EAAO,CAACC,MAAOvB,EAAmBd,EAAgBe,GAAgB,GAAGY,SACpEH,EAACc,EAAU,CAACZ,UAAWP,EAAO1B,WAAWkC,SAAE3B,EAAgBe,MAGjE,EAEAH,EAAckC,UAAY,CACxBhC,iBAAkBiC,EAAUC,KAAKC,WACjClC,aAAcgC,EAAUG,OAAOD,WAC/BjC,YAAa+B,EAAUI,QAAQJ,EAAUG,QAAQD,WACjDhC,SAAU8B,EAAUK,KAAKH,WACzB/B,cAAe6B,EAAUK,KAAKH"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import t from"@babel/runtime/helpers/defineProperty";import o from"@babel/runtime/helpers/slicedToArray";import{useState as e,useEffect as s}from"react";import i from"classnames";import{isEqual as n}from"lodash";import r from"prop-types";import{makeStyles as p,Menu as m,MenuItem as c,Checkbox as a}from"@material-ui/core";import{METRICS_LIST as l,DEFAULT_METRICS_KEY as j,ViewType as d,IOS_DEVICE as u,MAX_METRICS_COUNT as A}from"../../constants.js";import{getMobileOperatingSystem as C}from"../../utils/index.js";import{jsxs as V,Fragment as g,jsx as S}from"react/jsx-runtime";import"../../../DevCenter/DevCenterAppContainer/components/IsInsideIsolatedDcAppProvider/IsInsideIsolatedDcAppProvider.js";import"../../../DevCenter/DevCenterAppContainer/components/DcFullscreenElemsCoordinatorProvider/DcFullscreenElemsCoordinatorProvider.js";import"../../../DevCenter/DevCenterAppContainer/components/DcFullscreenElemsCoordinatorProvider/IsInsideDcFullscreenElemProvider.js";import{SettingTwoIcon as I}from"../../../../icons/iconParkIcons.js";import"../../../../icons/customIcons/icons/AddMessage.js";import"../../../../icons/customIcons/icons/Attention.js";import"../../../../icons/customIcons/icons/Collapse.js";import"../../../../icons/customIcons/icons/Dashboard.js";import"../../../../icons/customIcons/icons/Expand.js";import"../../../../icons/customIcons/icons/FolderClosed.js";import"../../../../icons/customIcons/icons/FolderClosedFilled.js";import"../../../../icons/customIcons/icons/FolderOpened.js";import"../../../../icons/customIcons/icons/GreaterOrEqual.js";import"../../../../icons/customIcons/icons/LessOrEqual.js";import"../../../../icons/customIcons/icons/Search.js";import"../../../../icons/customIcons/icons/SearchOne.js";import"../../../../icons/customIcons/icons/Wellhub.js";import"../../../../icons/customIcons/icons/MultiRuler.js";import"../../../../icons/customIcons/icons/Checkbox.js";import"../../../../icons/customIcons/icons/CheckboxChecked.js";import"../../../../icons/customIcons/icons/CheckboxIndeterminate.js";import"../../../../icons/customIcons/icons/Radio.js";import"../../../../icons/customIcons/icons/RadioChecked.js";import"../../../../icons/customIcons/icons/SimulFrac.js";import"../../../../icons/customIcons/icons/ZipperFrac.js";import"../../../../icons/customIcons/icons/CautionFilled.js";import"../../../../icons/customIcons/icons/MoreApp.js";import"../../../../icons/customIcons/icons/Pad.js";import"../../../../icons/customIcons/icons/DrilloutUnit.js";import"../../../../icons/customIcons/icons/FracFleet.js";import"../../../../icons/customIcons/icons/Global.js";import"../../../../icons/customIcons/icons/Program.js";import"../../../../icons/customIcons/icons/Rig.js";import"../../../../icons/customIcons/icons/Well.js";import"../../../../icons/customIcons/icons/Gap.js";import"../../../../icons/customIcons/icons/Pin.js";import"../../../../icons/customIcons/icons/CloseOneFilled.js";import"../../../../icons/customIcons/icons/AttentionFilled.js";import"../../../../icons/customIcons/icons/CheckOneFilled.js";import"../../../../icons/customIcons/icons/Archive.js";import"../../../../icons/customIcons/icons/ArchiveCancel.js";import"../../../../icons/customIcons/icons/Unarchive.js";import"../../../../icons/customIcons/icons/Archived.js";import"../../../../icons/customIcons/icons/InterventionUnit.js";import"../../../../icons/customIcons/icons/Lasso.js";import"../../../../utils/mobileDetect.js";import h from"../../../IconButton/index.js";import"../../../../constants/goals.js";import"../../../../constants/segment.js";import"../../../../constants/alerts.js";import"../../../../constants/apps.js";import"../../../../constants/drillstring.js";import"../../../../constants/completion.js";import"../../../../constants/appPackages.js";import"../../../../constants/notifications.js";import"../../../../constants/feed.js";import"../../../../constants/bha.js";import"../../../../constants/corvaCompanyId.js";import"../../../GradientManager/configuration/constants.js";import"../../../Modal/CorvaModal.css.js";import"uuid";import"../../../IconMenu/index.js";import"../../../StyledMenuItem/index.js";import"../../../AppIcon/AppIcon.js";import"../../../DevCenter/AppHeader/AppHeader.js";import"../../../DevCenter/AppSideBar/AppSideBar.js";import"../../../DevCenter/AppsDataProvider/AppsDataProvider.js";import"@material-ui/icons";import"../../../DevCenter/AppContext.js";import"../../../DevCenter/DevCenterRouterContext/DevCenterRouterContext.js";import"../../../DevCenter/DevCenterRouterContext/UniversalLink/UniversalLink.js";import"@babel/runtime/helpers/objectWithoutProperties";import"react-router";import"@babel/runtime/helpers/asyncToGenerator";import"@babel/runtime/regenerator";import"../../../../utils/index.js";import"../../../DevCenter/DevCenterAppContainer/components/AppActions/AppActions.css.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/AppSettingsDialog.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/components/RemoveAppButton.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/components/SettingsAccordion.js";import"../../../DevCenter/DevCenterAppContainer/components/AnnotationsButton/AnnotationsButton.js";import"../../../../componentsV2/Text/Text.js";import"../../../../componentsV2/Grid/Grid.js";import"../../../../componentsV2/Grid/Cell.js";import"../../../../componentsV2/Header/Header.scss.js";import"../../../../componentsV2/Button/Button.js";import"../../../../componentsV2/ButtonIcon/ButtonIcon.js";import"../../../../componentsV2/Tooltip/Tooltip.scss.js";import"../../../../componentsV2/Popover/Popover.js";import"../../../../componentsV2/Radio/Radio.js";import"../../../../componentsV2/RadioAndCheckboxGroup/RadioAndCheckboxGroup.scss.js";import"../../../../componentsV2/Checkbox/Checkbox.js";import"../../../../componentsV2/TextInput/TextInput.js";import"../../../../componentsV2/Label/Label.js";import"../../../../componentsV2/TextEndTruncated/TextEndTruncated.scss.js";import"../../../../componentsV2/TextMiddleTruncated/TextMiddleTruncated.constants.js";import"../../../../componentsV2/TextMiddleTruncated/TextMiddleTruncated.scss.js";import"../../../../componentsV2/TextLink/TextLink.js";import"../../../../componentsV2/Chip/Chip.js";import"../../../../componentsV2/ChipAlert/ChipAlert.js";import"../../../../componentsV2/ChipIndicator/ChipIndicator.js";import"../../../../componentsV2/Avatar/Avatar.js";import"../../../../componentsV2/AvatarGroup/AvatarGroup.js";import"@material-ui/lab";import"../../../../componentsV2/ToggleButtons/ToggleButtons.scss.js";import"../../../../componentsV2/Paper/Paper.js";import"../../../../componentsV2/ModalWindow/ModalWindow.scss.js";import"../../../../componentsV2/Modal/Modal.scss.js";import"../../../../componentsV2/Menu/Menu.js";import"../../../../componentsV2/utils.js";import"../../../../componentsV2/Hint/Hint.scss.js";import"../../../../componentsV2/Counter/Counter.js";import"../../../../componentsV2/BadgeBase/BadgeBase.scss.js";import"../../../../componentsV2/BadgeDot/BadgeDot.scss.js";import"../../../../componentsV2/LoaderLinear/LoaderLinear.scss.js";import"../../../../componentsV2/LoaderLogo/LoaderLogo.constants.js";import"../../../../componentsV2/LoaderLogo/LoaderLogo.scss.js";import"../../../../componentsV2/Switch/Switch.js";import"../../../../componentsV2/Tabs/Tabs.js";import"../../../../componentsV2/EmptyState/EmptyState.scss.js";import"../../../../componentsV2/FileIcon/FileIcon.js";import"../../../../componentsV2/Tag/Tag.js";import"react-dropzone";import"../../../../componentsV2/FilesDropzone/FilesDropzone.scss.js";import"../../../../componentsV2/FilesLoader/FilesLoader.scss.js";import"../../../../componentsV2/FilesProcessor/FilesProcessor.scss.js";import"../../../../componentsV2/Skeleton/Skeleton.scss.js";import"../../../../utils/main.js";import"../../../../componentsV2/CopyToClipboard/CopyToClipboard.scss.js";import"../../../../componentsV2/Stepper/Step/Step.scss.js";import"../../../../componentsV2/Stepper/Stepper.scss.js";import"../../../../componentsV2/ButtonLive/ButtonLive.js";import"../../../../componentsV2/ButtonText/ButtonText.js";import"../../../../componentsV2/IndicatorLive/IndicatorLive.js";import"../../../../componentsV2/Accordion/Accordion.scss.js";import"../../../../componentsV2/Breadcrumbs/Breadcrumbs.scss.js";import"../../../../componentsV2/BadgeComment/BadgeComment.js";import"../../../../componentsV2/AppContainer/AppContainer.js";import"../../../../componentsV2/AppContainer/AppContainer.constants.js";import"../../../../componentsV2/AppFooter/AppFooter.js";import"../../../../componentsV2/AppCommonsProvider/AppCommonsContext.js";import"../../../../componentsV2/AppHeader/AppHeader.constants.js";import"../../../../componentsV2/AppHeader/AppBadge/AppBadge.scss.js";import"../../../../componentsV2/AppHeader/AppAssets/utils.js";import"../../../../componentsV2/AppHeader/AppAssets/AppAssets.scss.js";import"../../../PadModeSelect/PadModeSelect.js";import"../../../../componentsV2/AppHeader/PadMode/PadMode.scss.js";import"../../../../constants/streamSourceType.js";import"../../../../types/shared/Completions.js";import"../../../PadModeSelect/types.js";import"lodash/flatten";import"lodash/partition";import"../../../../componentsV2/PadModeSelect/FracModeLabel/FracModeLabel.js";import"../../../../componentsV2/PadModeSelect/FracModeLabel/FracModeLabel.constants.js";import"../../../../clients/jsonApi/index.js";import"@babel/runtime/helpers/toConsumableArray";import"lodash/set";import"lodash/get";import"lodash/unset";import"moment";import"../../../../clients/subscriptions/constants.js";import"../../../../clients/subscriptions.v1.js";import"../../../../clients/subscriptions/subscriptions-client.factory.js";import"../../../../clients/api/apiCore.js";import"../../../../clients/constants.js";import"../../../../clients/sso/auth0.js";import"../../../../clients/sso/oauth2.js";import"../../../../componentsV2/PadModeSelect/WellStreamActivityStatus/WellStreamActivityStatus.scss.js";import"../../../../componentsV2/PadModeSelect/PadModeSelect.constants.js";import"../../../../componentsV2/PadModeSelect/PadModeSelect.scss.js";import"querystring";import"uuid/v1";import"jsona";import"../../../../utils/env.js";import"../../../StatusBadge/constants.js";import"lodash/isEmpty";import"lodash/sortBy";import"../../../DevCenter/DevCenterAppContainer/components/CommentsSwitch/CommentsSwitchContext.js";import"../../../../componentsV2/AppHeader/V3/VersionSelect/VersionSelect.js";import"../../../../componentsV2/UniversalLink/UniversalLink.scss.js";import"../../../../componentsV2/AppHeader/V3/AssetChips/AssetChips.scss.js";import"../../../../componentsV2/AppHeader/V3/DqStatusIcon/DqStatusIcon.js";import"../../../../componentsV2/AppHeader/V3/DqStatusIcon/DqStatusIcon.constants.js";import"../../../../componentsV2/AppFooter/DqPopover/DqStatusIcon/DqStatusIcon.js";import"../../../../componentsV2/AppDqPopover/DqAlertTooltip/DqAlertTooltip.scss.js";import"../../../../componentsV2/AppDqPopover/DqAlert/DqAlert.scss.js";import"../../../../componentsV2/AppDqPopover/DqAsset/DqAsset.scss.js";import"../../../../componentsV2/AppDqPopover/AppDqPopover.scss.js";import"../../../../utils/getSingleAsset.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorChip/AssetSelectorChip.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/constants.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorSelect/AssetSelectorSelect.scss.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorSelect/loadAssets.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelector.scss.js";import"../../../../componentsV2/AppHeader/V3/AppTitle/AppTitle.constants.js";import"../../../../componentsV2/AppContainer/headerCommon.scss.js";import"../../../../componentsV2/AppHeader/V3/AppTitle/AppTitle.scss.js";import"../../../../componentsV2/AppHeader/V3/constants.scss.js";import"@babel/runtime/helpers/typeof";import"../../../../componentsV2/AppHeader/V3/SettingsButton/SettingsButton.js";import"../../../../componentsV2/AppHeader/V3/SettingsButton/SettingsButton.constants.js";import"../../../../componentsV2/AppSettings/AppSettings.js";import"../../../../componentsV2/AppSettings/AppSettings.constants.js";import"../../../../componentsV2/AppSettings/AppSettingsPinningContext.js";import"../../../../componentsV2/AppSizeProvider/AppSizeProvider.js";import"../../../../componentsV2/AppHeader/V3/Actions/Actions.constants.js";import"../../../../componentsV2/AppHeader/V3/Actions/Actions.scss.js";import"../../../../componentsV2/AppHeader/V3/AppHeaderV3.scss.js";import"../../../../componentsV2/AppHeader/AppHeader.scss.js";import"../../../../componentsV2/OffsetWellsButton/OffsetWellsButton.js";import"../../../../componentsV2/Autocomplete/Autocomplete.scss.js";import"../../../../componentsV2/Menu/MenuItem/MenuItem.js";import"../../../../componentsV2/Autocomplete/AutocompleteListBox.js";import"../../../../componentsV2/AppSettingsDivider/AppSettingsDivider.scss.js";import"../../../../componentsV2/WellArchivedMessage/WellArchivedMessage.js";import"../../../../componentsV2/DatePicker/DatePicker.js";import"../../../../componentsV2/DragHandle/DragHandle.js";import"../../../../componentsV2/CompletionsOffsetWellPicker/CompletionsOffsetWellPicker.js";import"../../../DevCenter/DevCenterAppContainer/components/FullscreenButton/FullscreenButton.js";import"../../../DevCenter/DevCenterAppContainer/components/AppInfoMessage/AppInfoMessage.js";import"../../../DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.js";import"../../../DevCenter/DevCenterAppContainer/components/RestoreAppSizeButton/index.js";import"rollbar";import"@rollbar/react";import"../../../DevCenter/DevCenterAppContainer/components/CommentsSwitch/CommentsSwitchButton.scss.js";import"../../../DevCenter/DevCenterAppContainer/DevCenterAppContainer.css.js";import"../../../Icons/AnnotationIcon.js";import"../../../Annotations/components/AnnotationsList/index.js";import"../../../Annotations/components/LastAnnotation/index.js";import"../../../Annotations/AnnotationsContext.js";import"../../../Toaster/Toaster.js";import"../../../HelpCenter/HelpCenterIcon.js";import"../../../DevCenter/NavigationBar/NavigationBar.js";import"../../../DevCenter/SideBar/SideBar.js";import"../../../DevCenter/AppSettingsPopover/AppSettingsPopover.js";import"../../../DevCenter/AppFilterPanelLayout/AppFilterPanelLayout.js";import"../../../DevCenter/IsolatedDevCenterAppContainer/DevCenterIsolatedAppPage.js";import"../../../DevCenter/IsolatedDevCenterAppContainer/DevCenterIsolatedApp.js";import"../../../AssetEditor/index.js";import"../../../AssetEditorV2/index.js";import"../../../AppVersionsSelect/AppVersionsSelect.js";import"../../../LoadingIndicator/LoadingIndicator.js";import"../../../Typography.js";import"../../../RealTimeValuesSidebar/RealTimeSidebar.js";import"../../../CollapsableSidebar.js";import"../../../DateTimePicker/index.js";import"../../../DatePicker/index.js";import"../../../ErrorBoundary/ErrorBoundary.js";import"../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import"../../../SlateFormattedText/SlateFormattedText.js";import"../../../SlateFormattedText/RenderElements.js";import"slate";import"../../../EmptyState/EmptyState.js";import"../../../ParameterCharts/ParameterCharts.js";import"../../../ParameterCharts/AddEditTrack.js";import"../../../ChartActionsList/ChartActionsList.js";import"../../../CopyToClipboard/CopyToClipboard.js";import"../../../AssetEditor/AssetEditorAutocomplete.js";import"../../../AssetEditor/SingleAssetEditor.js";import"react-color";import"../../../SettingEditors/ColorEditor/style.css.js";import"../../../SettingEditors/DropdownEditor/index.js";import"../../../SwitchControl/index.js";import"../../../ColorPicker/ColorPicker.js";import"../../../Chart/components/ChartButton.js";import"../../../Chart/components/ChartButtons.js";import"../../../Chart/components/ChartWrapper.js";import"../../../Chart/components/AxisDropdown.js";import"../../../Chart/components/ChartSelect.js";import"../../../Chart/components/buttons/DragToZoomButton.js";import"../../../Chart/components/buttons/ZoomInButton.js";import"../../../Chart/components/buttons/ZoomOutButton.js";import"../../../Chart/components/buttons/PanButton.js";import"../../../Chart/components/buttons/ResetZoomButton.js";import"../../../Chart/components/buttons/HideAxesButton.js";import"../../../Chart/components/buttons/ChartTypeButton.js";import"../../../ColorPicker/PaletteChromePicker/PaletteChromePicker.js";import"../../../TruncatedText/index.js";import"../../../MiddleTruncatedText/MiddleTruncatedText.js";import"../../../RangeSlider/constants.js";import"../../../RangeSlider/Input.css.js";import"../../../RangeSlider/RangeSlider.css.js";import"../../../AdvancedSlider/AdvancedSlider.js";import"../../../Breadcrumbs/index.js";import"../../../VirtualizedTable/index.js";import"../../../EmptyView/EmptyView.js";import"../../../EmptyView/EmptyAppView/EmptyAppView.js";import"../../../Button/components/Button/index.js";import"moment-timezone";import"../../../Button/components/LiveButton/components/LiveButtonStateIndicator/index.js";import"../../../Button/components/LiveButton/styles.js";import"../../../ContextMenuItem/index.js";import"../../../FolderMenuItem/index.js";import"../../../EditableItem/EditableItem/index.js";import"../../../EditableItem/EditableItemWithBadge/index.js";import"../../../Checkbox/index.js";import"../../../FolderMenuItemWithLinks/index.js";import"../../../TextField/index.js";import"../../../Chip/index.js";import"../../../Counter/index.js";import"../../../AnchorsList/AnchorsList.js";import"../../../Select/index.js";import"../../../Select/SelectFilterBy.js";import"../../../CustomSelect/index.js";import"../../../Tabs/Tabs.js";import"../../../Tabs/Tab.js";import"../../../ResizableTable/ResizableTable.js";import"../../../GradientPicker/GradientPicker.js";import"../../../GradientManager/GradientList.js";import"@material-ui/icons/AddCircle";import"../../../GradientManager/GradientPreview/GradientPreview.js";import"../../../GradientManager/GradientSelect.styles.js";import"../../../GradientManager/GradientManager.styles.js";import"../../../Drillstring/BHASchematic.js";import"../../../Drillstring/BHATable/index.js";import"../../../Drillstring/BHAComponentIcon.js";import"../../../Drillstring/BHAComponentDetail/index.js";import"../../../Drillstring/BHATileIcon.js";import"../../../Drillstring/BHATile/BHATile.js";import"../../../Drillstring/BHAList/BHAList.js";import"../../../Drillstring/BHAComponentsTable/BHAComponentsTable.js";import"../../../Casing/CasingTable/index.js";import"../../../Casing/CasingComponentIcon.js";import"../../../Casing/CasingTileIcon.js";import"../../../Casing/CasingTableV2/CasingTableV2.js";import"../../../Casing/CasingTile/CasingTile.js";import"../../../DisabledSettingsMessage/DisabledSettingsMessage.js";import"../../../WellSummary/WellSummaryItemLabel.js";import"../../../WellSummary/WellSummaryItemTitle.js";import"../../../WellSummary/WellSummaryItemValue.js";import"../../../WellSummary/ActivitySummaryChart.js";import"../../../WellSummary/FracWirelineTimeChart.js";import"../../../BICOffsetPickerDialog/index.js";import"../../../OffsetWellButton/OffsetWellButton.js";import"../../../OffsetWellPickerV2/OffsetWellPickerDialog.js";import"../../../OffsetWellPickerV3/index.js";import"../../../OffsetWellChips/Chip.js";import"../../../OffsetWellChips/ChipsContainer.js";import"../../../OffsetWellPickerV5/OffsetWellPickerV5WithStore.js";import"../../utils/apiCalls.js";import"../../effects/useAdvancedWells.js";import"react-virtualized";import"../../effects/useAssetsData.js";import"../../../../permissions/PermissionsContext.js";import"../../../../permissions/constants/index.js";import"../../../../permissions/withPermissionsHOC.js";import"../../../../permissions/ProvidePermissions.js";import"../AppHeader/AppHeader.js";import"../Toolbar/Toolbar.js";import"../Filter/Filter.js";import"../Map/WellsMap.js";import"./OffsetWellsTable.js";import"./AdvancedSearch/constants.js";import"../../OffsetWellPickerV4.module.css.js";import"@material-ui/core/Snackbar";import"../../../Notifications/Toast.js";import"../../../Notifications/Notifications.scss.js";import"../../../../styles/typography/index.js";import"../../../../styles/counter/counter.module.scss.js";import"../../../OffsetWellMap/OffsetWellMap.js";import"../../../ConfirmationDialog.js";import"../../../TextLink/index.js";import"../../../Avatar/index.js";import"../../../Template/TemplatePopover/index.js";import"../../../Template/TemplateSharingDialog/index.js";import"../../../MenuItem/index.js";import"../../../MiddleTruncate/MiddleTruncate.js";import"../../../PinnableFilters/PinnableFilters.js";import"../../../HeaderLayout/HeaderLayout.js";import"../../../PadOffsetsPicker/PadOffsetsPicker.js";import"../../../PadOffsetsPicker/OffsetAssetChip.js";import"../../../PadOffsetsPicker/OffsetAssetsListExpander.js";import"../../../PadOffsetsPicker/StagesSelector.js";import"../../../PadOffsetsPickerV2/PadOffsetsPickerV2.js";import"../../../Table/TableToolbar/TableToolbar.js";import"../../../Table/TableContainer/TableContainer.js";import"../../../Table/TableCell/TableCell.js";import"../../../Table/TablePagination/TablePagination.js";import"../../../Table/TablePaginationActions/TablePaginationActions.js";import"../../../Tooltip/ScrollableTooltip.js";import"../../../PriceInput/PriceInput.js";import"../../../LabelsCounter/LabelsCounter.js";import"../../../Stepper/Stepper.js";import"../../../Stepper/Step/Step.js";import"../../../Stepper/StepsWrapper.js";import"../../../Comment/CommentIcon/index.js";import"../../../FilesLoader/FilesLoader.js";import"../../../../componentsV2/FileIcon/icons/ArchiveFileIcon.js";import"../../../../componentsV2/FileIcon/icons/CSVFileIcon.js";import"../../../../componentsV2/FileIcon/icons/DocFileIcon.js";import"../../../../componentsV2/FileIcon/icons/EDMFileIcon.js";import"../../../../componentsV2/FileIcon/icons/ExcelFileIcon.js";import"../../../../componentsV2/FileIcon/icons/ImageFileIcon.js";import"../../../../componentsV2/FileIcon/icons/JsonFileIcon.js";import"../../../../componentsV2/FileIcon/icons/LasFileIcon.js";import"../../../../componentsV2/FileIcon/icons/OtherFileIcon.js";import"../../../../componentsV2/FileIcon/icons/PdfFileIcon.js";import"../../../../componentsV2/FileIcon/icons/PowerPointFileIcon.js";import"../../../../componentsV2/FileIcon/icons/TxtFileIcon.js";import"../../../../componentsV2/FileIcon/icons/UnknownFileIcon.js";import"../../../../componentsV2/FileIcon/icons/VideoFileIcon.js";import"../../../../componentsV2/FileIcon/icons/XmlFileIcon.js";import"../../../SearchInput/index.js";import"../../../FeedItem/FeedItem.js";import"../../../FeedItem/FeedItemEditProvider/FeedItemEditProvider.js";import"../../../PostInput/PostInput.js";import"../../../KeyboardDateTimePicker.js";import"../../../AddComment/Popover.js";import"../../../AddComment/Popup.js";import"../../../StageDesignVActual/ComparisonBar/ComparisonBar.js";import"../../../StageDesignVActual/ElementsComparison/ElementsComparison.js";import"../../../StageDesignVActual/ComparisonHeader.js";import"../../../StageDesignVActual/ComparisonRow.js";import"../../../EmbeddedApp/DevCenterEmbeddedApp.js";import"../../../EmbeddedApp/EmbeddedApp.js";import"../../../Autocomplete/Autocomplete.js";import"../../../DocumentViewer/DocumentViewer.js";import"../../../ColorPickerPalette/ColorPickerPalette.js";import"../../../Search/Search.js";import"../../../Search/components/Listbox.js";import"../../../Search/components/Paper.js";import"../../../Search/components/RecentSearches.js";import"../../../Search/components/Groups.js";import"../../../Search/components/SelectAllListItem.js";import"../../../StatusBadge/index.js";import"../../../Attachment/index.js";import"../../../EmojiIconButton.js";import"../../../FileUploadIconButton.js";import"../../../FilePreview/index.js";import"../../../FailedFileUploading.js";import"../../../UserMention/index.js";import"../../../CommentsInfo/index.js";import"../../../CommentInput/index.js";import"../../../Comment/index.js";import"../../../CommentLoader.js";import"../../../AssetNameLabel/AssetStatusBadge.js";import"../../../AssetEditorV2/components/PrimaryAssetSelect.js";import"../../../AssetEditorV2/components/SecondaryAssetSelect.js";import"../../../AssetEditorV2/components/SelectItem.js";import"../../../AssetEditorV2/components/MultipleAssetsToggle.js";import"../../../AssetEditorV2/components/PrimaryAssetSelectV2.js";import"../../../EChartsWrapper/EChartsWrapper.js";import"../../../AssetsMultipleSelector/AssetsMultipleSelector.js";import"@material-ui/icons/Close";import"@material-ui/icons/GetApp";import"../../../GoogleDocsViewer/index.js";import"../../../NewDocumentViewer/effects/useFileContent.js";import"../../../NewDocumentViewer/styles.js";import"../../../FilesLoaderV2/styles.js";import"../../../FilesDropzone/styles.js";import"../../../FilesProcessor/styles.js";import"../../../Hint/styles.js";import"@babel/runtime/helpers/taggedTemplateLiteral";import"fparser";import"../../../Formula/useFormulaStyles.js";import"../../../Formula/RootXIcon.js";import"../../../Formula/FormulaTextEditor.js";import"../../../Formula/CloseSuggestion.js";import"../../../Formula/SuggestionsMenu.js";var b=l.filter((function(t){return t.key!==j})),v=p((function(t){return{checkBox:{color:"grey",padding:"0px",marginRight:"10px"},paper:{transform:"translate(-40px, 4px) scale(1, 1) !important",maxHeight:"calc(80% - 80px)",backgroundColor:t.palette.background.b9},paperMobile:{marginLeft:"8px",marginTop:"16px",maxHeight:"calc(80% - 20px)"},paperiOSMobile:{marginLeft:"0px !important"},titleItem:{position:"sticky",top:"0px",zIndex:9,marginBottom:"-8px",display:"flex",alignItems:"center",height:"40px",paddingLeft:"16px",background:t.palette.background.b9},titleLabel:{fontStyle:"italic",fontWeight:400,fontSize:"12px",lineHeight:"14px",letterSpacing:"0.4px",color:"#999999"},menuList:{paddingTop:"0px !important"},menuItem:{height:"54px !important"}}})),D=function(r){var p,l=r.viewType,j=r.metricsKeys,D=r.onChange,x=r.contentRef,P=v(),T=e([]),f=o(T,2),F=f[0],B=f[1],y=e(null),M=o(y,2),k=M[0],L=M[1];s((function(){B(j||[])}),[j]);return V(g,{children:[S(h,{"data-testid":"".concat("MetricsSettingMenu","_gear"),size:"small",tooltipProps:{title:l!==d.mobile?"Select Metrics":""},onClick:function(t){L(t.currentTarget)},children:S(I,{size:"small"})}),V(m,{id:"simple-menu",anchorEl:x.current,getContentAnchorEl:null,anchorOrigin:{vertical:"center",horizontal:"right"},transformOrigin:{vertical:"center",horizontal:"right"},classes:{paper:i(P.paper,(p={},t(p,P.paperMobile,l===d.mobile),t(p,P.paperiOSMobile,C()===u),p)),list:P.menuList},keepMounted:!0,open:Boolean(k),onClose:function(){L(null),n(F,j)||D(F)},children:[S("div",{className:P.titleItem,children:S("span",{className:P.titleLabel,children:"Up to 2 Metrics"})}),b.map((function(t){return V(c,{"data-testid":"".concat("MetricsSettingMenu","_option_").concat(t.key,"MenuItem"),className:P.menuItem,disabled:F.length===A&&!F.includes(t.key),onClick:function(){return o=t.key,void(F.includes(o)?B(F.filter((function(t){return t!==o}))):B(F.concat(o)));var o},children:[S(a,{checked:F.includes(t.key),className:P.checkBox}),t.label]},t.key)}))]})]})};D.propTypes={viewType:r.string.isRequired,metricsKeys:r.arrayOf(r.string).isRequired,onChange:r.func.isRequired,contentRef:r.shape({current:r.instanceOf(Element)}).isRequired};export{D as MetricsSettingMenu};
|
|
2
|
-
//# sourceMappingURL=MetricsSettingMenu.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MetricsSettingMenu.js","sources":["../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/MetricsSettingMenu.js"],"sourcesContent":["import { useState, useEffect } from 'react';\nimport classNames from 'classnames';\nimport { isEqual } from 'lodash';\nimport PropTypes from 'prop-types';\nimport { Menu, MenuItem, Checkbox, makeStyles } from '@material-ui/core';\n\nimport {\n METRICS_LIST,\n MAX_METRICS_COUNT,\n ViewType,\n IOS_DEVICE,\n DEFAULT_METRICS_KEY,\n} from '../../constants';\nimport { getMobileOperatingSystem } from '../../utils';\n\nimport { IconButton } from '~/components';\nimport { SettingTwoIcon } from '~/icons';\n\nconst PAGE_NAME = 'MetricsSettingMenu';\nconst metricsList = METRICS_LIST.filter(metrics => metrics.key !== DEFAULT_METRICS_KEY);\n\nconst useStyles = makeStyles(theme => ({\n checkBox: {\n color: 'grey',\n padding: '0px',\n marginRight: '10px',\n },\n paper: {\n transform: 'translate(-40px, 4px) scale(1, 1) !important',\n maxHeight: 'calc(80% - 80px)',\n backgroundColor: theme.palette.background.b9,\n },\n paperMobile: {\n marginLeft: '8px',\n marginTop: '16px',\n maxHeight: 'calc(80% - 20px)',\n },\n paperiOSMobile: {\n marginLeft: '0px !important',\n },\n titleItem: {\n position: 'sticky',\n top: '0px',\n zIndex: 9,\n marginBottom: '-8px',\n display: 'flex',\n alignItems: 'center',\n height: '40px',\n paddingLeft: '16px',\n background: theme.palette.background.b9,\n },\n titleLabel: {\n fontStyle: 'italic',\n fontWeight: 400,\n fontSize: '12px',\n lineHeight: '14px',\n letterSpacing: '0.4px',\n color: '#999999',\n },\n menuList: {\n paddingTop: '0px !important',\n },\n menuItem: {\n height: '54px !important',\n },\n}));\n\nexport const MetricsSettingMenu = ({ viewType, metricsKeys, onChange, contentRef }) => {\n const classes = useStyles();\n const [selectedKeys, setSelectedKeys] = useState([]);\n const [anchorEl, setAnchorEl] = useState(null);\n\n useEffect(() => {\n setSelectedKeys(metricsKeys || []);\n }, [metricsKeys]);\n\n const handleClick = event => {\n setAnchorEl(event.currentTarget);\n };\n\n const handleClose = () => {\n setAnchorEl(null);\n if (!isEqual(selectedKeys, metricsKeys)) {\n onChange(selectedKeys);\n }\n };\n\n const handleChangeMetrics = newKey => {\n if (selectedKeys.includes(newKey)) {\n setSelectedKeys(selectedKeys.filter(key => key !== newKey));\n } else {\n setSelectedKeys(selectedKeys.concat(newKey));\n }\n };\n\n return (\n <>\n <IconButton\n data-testid={`${PAGE_NAME}_gear`}\n size=\"small\"\n tooltipProps={{ title: viewType !== ViewType.mobile ? 'Select Metrics' : '' }}\n onClick={handleClick}\n >\n <SettingTwoIcon size=\"small\" />\n </IconButton>\n\n <Menu\n id=\"simple-menu\"\n anchorEl={contentRef.current}\n getContentAnchorEl={null}\n anchorOrigin={{\n vertical: 'center',\n horizontal: 'right',\n }}\n transformOrigin={{\n vertical: 'center',\n horizontal: 'right',\n }}\n classes={{\n paper: classNames(classes.paper, {\n [classes.paperMobile]: viewType === ViewType.mobile,\n [classes.paperiOSMobile]: getMobileOperatingSystem() === IOS_DEVICE,\n }),\n list: classes.menuList,\n }}\n keepMounted\n open={Boolean(anchorEl)}\n onClose={handleClose}\n >\n <div className={classes.titleItem}>\n <span className={classes.titleLabel}>Up to 2 Metrics</span>\n </div>\n {metricsList.map(item => (\n <MenuItem\n data-testid={`${PAGE_NAME}_option_${item.key}MenuItem`}\n className={classes.menuItem}\n disabled={selectedKeys.length === MAX_METRICS_COUNT && !selectedKeys.includes(item.key)}\n key={item.key}\n onClick={() => handleChangeMetrics(item.key)}\n >\n <Checkbox checked={selectedKeys.includes(item.key)} className={classes.checkBox} />\n {item.label}\n </MenuItem>\n ))}\n </Menu>\n </>\n );\n};\n\nMetricsSettingMenu.propTypes = {\n viewType: PropTypes.string.isRequired,\n metricsKeys: PropTypes.arrayOf(PropTypes.string).isRequired,\n onChange: PropTypes.func.isRequired,\n contentRef: PropTypes.shape({ current: PropTypes.instanceOf(Element) }).isRequired,\n};\n"],"names":["metricsList","METRICS_LIST","filter","metrics","key","DEFAULT_METRICS_KEY","useStyles","makeStyles","theme","checkBox","color","padding","marginRight","paper","transform","maxHeight","backgroundColor","palette","background","b9","paperMobile","marginLeft","marginTop","paperiOSMobile","titleItem","position","top","zIndex","marginBottom","display","alignItems","height","paddingLeft","titleLabel","fontStyle","fontWeight","fontSize","lineHeight","letterSpacing","menuList","paddingTop","menuItem","MetricsSettingMenu","_ref","_classNames","viewType","metricsKeys","onChange","contentRef","classes","useState","_useState2","_slicedToArray","_useState","selectedKeys","setSelectedKeys","_useState4","_useState3","anchorEl","setAnchorEl","useEffect","_jsxs","_Fragment","children","_jsx","IconButton","concat","size","tooltipProps","title","ViewType","mobile","onClick","event","currentTarget","SettingTwoIcon","Menu","id","current","getContentAnchorEl","anchorOrigin","vertical","horizontal","transformOrigin","classNames","_defineProperty","getMobileOperatingSystem","IOS_DEVICE","list","keepMounted","open","Boolean","onClose","isEqual","className","map","item","MenuItem","disabled","length","MAX_METRICS_COUNT","includes","newKey","Checkbox","checked","label","propTypes","PropTypes","string","isRequired","arrayOf","func","shape","instanceOf","Element"],"mappings":"w1xBAkBA,IACMA,EAAcC,EAAaC,QAAO,SAAAC,GAAO,OAAIA,EAAQC,MAAQC,CAAmB,IAEhFC,EAAYC,GAAW,SAAAC,GAAK,MAAK,CACrCC,SAAU,CACRC,MAAO,OACPC,QAAS,MACTC,YAAa,QAEfC,MAAO,CACLC,UAAW,+CACXC,UAAW,mBACXC,gBAAiBR,EAAMS,QAAQC,WAAWC,IAE5CC,YAAa,CACXC,WAAY,MACZC,UAAW,OACXP,UAAW,oBAEbQ,eAAgB,CACdF,WAAY,kBAEdG,UAAW,CACTC,SAAU,SACVC,IAAK,MACLC,OAAQ,EACRC,aAAc,OACdC,QAAS,OACTC,WAAY,SACZC,OAAQ,OACRC,YAAa,OACbd,WAAYV,EAAMS,QAAQC,WAAWC,IAEvCc,WAAY,CACVC,UAAW,SACXC,WAAY,IACZC,SAAU,OACVC,WAAY,OACZC,cAAe,QACf5B,MAAO,WAET6B,SAAU,CACRC,WAAY,kBAEdC,SA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GAAI,OACnBnC,EAACoC,EAAQ,CACP,cAAA,GAAA/B,OApHM,qBAoHmB,YAAAA,OAAW8B,EAAK5F,IAAc,YACvD0F,UAAW7C,EAAQR,SACnByD,SAAU5C,EAAa6C,SAAWC,IAAsB9C,EAAa+C,SAASL,EAAK5F,KAEnFoE,QAAS,WAAA,OAnDS8B,EAmDiBN,EAAK5F,SAlD5CkD,EAAa+C,SAASC,GACxB/C,EAAgBD,EAAapD,QAAO,SAAAE,GAAG,OAAIA,IAAQkG,CAAM,KAEzD/C,EAAgBD,EAAaY,OAAOoC,KAJZ,IAAAA,CAmD2B,EAAAvC,SAAA,CAE7CC,EAACuC,EAAQ,CAACC,QAASlD,EAAa+C,SAASL,EAAK5F,KAAM0F,UAAW7C,EAAQxC,WACtEuF,EAAKS,QAJDT,EAAK5F,IAKD,SAKrB,EAEAsC,EAAmBgE,UAAY,CAC7B7D,SAAU8D,EAAUC,OAAOC,WAC3B/D,YAAa6D,EAAUG,QAAQH,EAAUC,QAAQC,WACjD9D,SAAU4D,EAAUI,KAAKF,WACzB7D,WAAY2D,EAAUK,MAAM,CAAElC,QAAS6B,EAAUM,WAAWC,WAAYL"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/defineProperty";import t from"@babel/runtime/helpers/slicedToArray";import{memo as o,useState as s,useRef as i,useEffect as n,useMemo as r,useCallback as p}from"react";import m from"classnames";import c from"prop-types";import{uniqBy as a}from"lodash";import{Table as l,TableHead as d,TableBody as j,TableRow as u,TableCell as A}from"@material-ui/core";import{METRICS_LIST as C,EXPANDED_WELL_NAME_WIDTH as S,TableColumns as h,ColumnType as V,ViewType as f,SEARCH_CELL_EXPAND_WIDTH as I,SEARCH_CELL_DEFAULT_WIDTH as g}from"../../constants.js";import{getIsImperial as v}from"../../utils/unitSystem.js";import{AdvancedSearch as b}from"./AdvancedSearch/AdvancedSearch.js";import D from"./OffsetWellsTableHead.js";import T from"./OffsetWellsTableRow.js";import P from"./OffsetWellsTable.module.css.js";import{jsxs as x,jsx as y}from"react/jsx-runtime";import"../../../DevCenter/DevCenterAppContainer/components/IsInsideIsolatedDcAppProvider/IsInsideIsolatedDcAppProvider.js";import"../../../DevCenter/DevCenterAppContainer/components/DcFullscreenElemsCoordinatorProvider/DcFullscreenElemsCoordinatorProvider.js";import"../../../DevCenter/DevCenterAppContainer/components/DcFullscreenElemsCoordinatorProvider/IsInsideDcFullscreenElemProvider.js";import"@icon-park/react/es/all";import"../../../../icons/IconParkProvider.js";import"../../../../icons/customIcons/icons/AddMessage.js";import"../../../../icons/customIcons/icons/Attention.js";import"../../../../icons/customIcons/icons/Collapse.js";import"../../../../icons/customIcons/icons/Dashboard.js";import"../../../../icons/customIcons/icons/Expand.js";import"../../../../icons/customIcons/icons/FolderClosed.js";import"../../../../icons/customIcons/icons/FolderClosedFilled.js";import"../../../../icons/customIcons/icons/FolderOpened.js";import"../../../../icons/customIcons/icons/GreaterOrEqual.js";import"../../../../icons/customIcons/icons/LessOrEqual.js";import"../../../../icons/customIcons/icons/Search.js";import"../../../../icons/customIcons/icons/SearchOne.js";import"../../../../icons/customIcons/icons/Wellhub.js";import"../../../../icons/customIcons/icons/MultiRuler.js";import"../../../../icons/customIcons/icons/Checkbox.js";import"../../../../icons/customIcons/icons/CheckboxChecked.js";import"../../../../icons/customIcons/icons/CheckboxIndeterminate.js";import"../../../../icons/customIcons/icons/Radio.js";import"../../../../icons/customIcons/icons/RadioChecked.js";import"../../../../icons/customIcons/icons/SimulFrac.js";import"../../../../icons/customIcons/icons/ZipperFrac.js";import"../../../../icons/customIcons/icons/CautionFilled.js";import"../../../../icons/customIcons/icons/MoreApp.js";import"../../../../icons/customIcons/icons/Pad.js";import"../../../../icons/customIcons/icons/DrilloutUnit.js";import"../../../../icons/customIcons/icons/FracFleet.js";import"../../../../icons/customIcons/icons/Global.js";import"../../../../icons/customIcons/icons/Program.js";import"../../../../icons/customIcons/icons/Rig.js";import"../../../../icons/customIcons/icons/Well.js";import"../../../../icons/customIcons/icons/Gap.js";import"../../../../icons/customIcons/icons/Pin.js";import"../../../../icons/customIcons/icons/CloseOneFilled.js";import"../../../../icons/customIcons/icons/AttentionFilled.js";import"../../../../icons/customIcons/icons/CheckOneFilled.js";import"../../../../icons/customIcons/icons/Archive.js";import"../../../../icons/customIcons/icons/ArchiveCancel.js";import"../../../../icons/customIcons/icons/Unarchive.js";import"../../../../icons/customIcons/icons/Archived.js";import"../../../../icons/customIcons/icons/InterventionUnit.js";import"../../../../icons/customIcons/icons/Lasso.js";import"../../../../utils/mobileDetect.js";import"../../../IconButton/index.js";import"../../../../constants/goals.js";import"../../../../constants/segment.js";import"../../../../constants/alerts.js";import"../../../../constants/apps.js";import"../../../../constants/drillstring.js";import"../../../../constants/completion.js";import"../../../../constants/appPackages.js";import"../../../../constants/notifications.js";import"../../../../constants/feed.js";import"../../../../constants/bha.js";import"../../../../constants/corvaCompanyId.js";import"../../../GradientManager/configuration/constants.js";import"../../../Modal/CorvaModal.css.js";import"uuid";import"../../../IconMenu/index.js";import"../../../StyledMenuItem/index.js";import"../../../AppIcon/AppIcon.js";import"../../../DevCenter/AppHeader/AppHeader.js";import"../../../DevCenter/AppSideBar/AppSideBar.js";import"../../../DevCenter/AppsDataProvider/AppsDataProvider.js";import"@material-ui/icons";import"../../../DevCenter/AppContext.js";import"../../../DevCenter/DevCenterRouterContext/DevCenterRouterContext.js";import"../../../DevCenter/DevCenterRouterContext/UniversalLink/UniversalLink.js";import"@babel/runtime/helpers/objectWithoutProperties";import"react-router";import"@babel/runtime/helpers/asyncToGenerator";import"@babel/runtime/regenerator";import"../../../../utils/index.js";import"../../../DevCenter/DevCenterAppContainer/components/AppActions/AppActions.css.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/AppSettingsDialog.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/components/RemoveAppButton.js";import"../../../DevCenter/DevCenterAppContainer/components/AppSettingsDialog/components/SettingsAccordion.js";import"../../../DevCenter/DevCenterAppContainer/components/AnnotationsButton/AnnotationsButton.js";import"../../../../componentsV2/Text/Text.js";import"../../../../componentsV2/Grid/Grid.js";import"../../../../componentsV2/Grid/Cell.js";import"../../../../componentsV2/Header/Header.scss.js";import"../../../../componentsV2/Button/Button.js";import"../../../../componentsV2/ButtonIcon/ButtonIcon.js";import"../../../../componentsV2/Tooltip/Tooltip.scss.js";import"../../../../componentsV2/Popover/Popover.js";import"../../../../componentsV2/Radio/Radio.js";import"../../../../componentsV2/RadioAndCheckboxGroup/RadioAndCheckboxGroup.scss.js";import"../../../../componentsV2/Checkbox/Checkbox.js";import"../../../../componentsV2/TextInput/TextInput.js";import"../../../../componentsV2/Label/Label.js";import"../../../../componentsV2/TextEndTruncated/TextEndTruncated.scss.js";import"../../../../componentsV2/TextMiddleTruncated/TextMiddleTruncated.constants.js";import"../../../../componentsV2/TextMiddleTruncated/TextMiddleTruncated.scss.js";import"../../../../componentsV2/TextLink/TextLink.js";import"../../../../componentsV2/Chip/Chip.js";import"../../../../componentsV2/ChipAlert/ChipAlert.js";import"../../../../componentsV2/ChipIndicator/ChipIndicator.js";import"../../../../componentsV2/Avatar/Avatar.js";import"../../../../componentsV2/AvatarGroup/AvatarGroup.js";import"@material-ui/lab";import"../../../../componentsV2/ToggleButtons/ToggleButtons.scss.js";import"../../../../componentsV2/Paper/Paper.js";import"../../../../componentsV2/ModalWindow/ModalWindow.scss.js";import"../../../../componentsV2/Modal/Modal.scss.js";import"../../../../componentsV2/Menu/Menu.js";import"../../../../componentsV2/utils.js";import"../../../../componentsV2/Hint/Hint.scss.js";import"../../../../componentsV2/Counter/Counter.js";import"../../../../componentsV2/BadgeBase/BadgeBase.scss.js";import"../../../../componentsV2/BadgeDot/BadgeDot.scss.js";import"../../../../componentsV2/LoaderLinear/LoaderLinear.scss.js";import"../../../../componentsV2/LoaderLogo/LoaderLogo.constants.js";import"../../../../componentsV2/LoaderLogo/LoaderLogo.scss.js";import"../../../../componentsV2/Switch/Switch.js";import"../../../../componentsV2/Tabs/Tabs.js";import"../../../../componentsV2/EmptyState/EmptyState.scss.js";import"../../../../componentsV2/FileIcon/FileIcon.js";import"../../../../componentsV2/Tag/Tag.js";import"react-dropzone";import"../../../../componentsV2/FilesDropzone/FilesDropzone.scss.js";import"../../../../componentsV2/FilesLoader/FilesLoader.scss.js";import"../../../../componentsV2/FilesProcessor/FilesProcessor.scss.js";import"../../../../componentsV2/Skeleton/Skeleton.scss.js";import"../../../../utils/main.js";import"../../../../componentsV2/CopyToClipboard/CopyToClipboard.scss.js";import"../../../../componentsV2/Stepper/Step/Step.scss.js";import"../../../../componentsV2/Stepper/Stepper.scss.js";import"../../../../componentsV2/ButtonLive/ButtonLive.js";import"../../../../componentsV2/ButtonText/ButtonText.js";import"../../../../componentsV2/IndicatorLive/IndicatorLive.js";import"../../../../componentsV2/Accordion/Accordion.scss.js";import"../../../../componentsV2/Breadcrumbs/Breadcrumbs.scss.js";import"../../../../componentsV2/BadgeComment/BadgeComment.js";import"../../../../componentsV2/AppContainer/AppContainer.js";import"../../../../componentsV2/AppContainer/AppContainer.constants.js";import"../../../../componentsV2/AppFooter/AppFooter.js";import"../../../../componentsV2/AppCommonsProvider/AppCommonsContext.js";import"../../../../componentsV2/AppHeader/AppHeader.constants.js";import"../../../../componentsV2/AppHeader/AppBadge/AppBadge.scss.js";import"../../../../componentsV2/AppHeader/AppAssets/utils.js";import"../../../../componentsV2/AppHeader/AppAssets/AppAssets.scss.js";import"../../../PadModeSelect/PadModeSelect.js";import"../../../../componentsV2/AppHeader/PadMode/PadMode.scss.js";import"../../../../constants/streamSourceType.js";import"../../../../types/shared/Completions.js";import"../../../PadModeSelect/types.js";import"lodash/flatten";import"lodash/partition";import"../../../../componentsV2/PadModeSelect/FracModeLabel/FracModeLabel.js";import"../../../../componentsV2/PadModeSelect/FracModeLabel/FracModeLabel.constants.js";import"../../../../clients/jsonApi/index.js";import"@babel/runtime/helpers/toConsumableArray";import"lodash/set";import"lodash/get";import"lodash/unset";import"moment";import"../../../../clients/subscriptions/constants.js";import"../../../../clients/subscriptions.v1.js";import"../../../../clients/subscriptions/subscriptions-client.factory.js";import"../../../../clients/api/apiCore.js";import"../../../../clients/constants.js";import"../../../../clients/sso/auth0.js";import"../../../../clients/sso/oauth2.js";import"../../../../componentsV2/PadModeSelect/WellStreamActivityStatus/WellStreamActivityStatus.scss.js";import"../../../../componentsV2/PadModeSelect/PadModeSelect.constants.js";import"../../../../componentsV2/PadModeSelect/PadModeSelect.scss.js";import"querystring";import"uuid/v1";import"jsona";import"../../../../utils/env.js";import"../../../StatusBadge/constants.js";import"lodash/isEmpty";import"lodash/sortBy";import"../../../DevCenter/DevCenterAppContainer/components/CommentsSwitch/CommentsSwitchContext.js";import"../../../../componentsV2/AppHeader/V3/VersionSelect/VersionSelect.js";import"../../../../componentsV2/UniversalLink/UniversalLink.scss.js";import"../../../../componentsV2/AppHeader/V3/AssetChips/AssetChips.scss.js";import"../../../../componentsV2/AppHeader/V3/DqStatusIcon/DqStatusIcon.js";import"../../../../componentsV2/AppHeader/V3/DqStatusIcon/DqStatusIcon.constants.js";import"../../../../componentsV2/AppFooter/DqPopover/DqStatusIcon/DqStatusIcon.js";import"../../../../componentsV2/AppDqPopover/DqAlertTooltip/DqAlertTooltip.scss.js";import"../../../../componentsV2/AppDqPopover/DqAlert/DqAlert.scss.js";import"../../../../componentsV2/AppDqPopover/DqAsset/DqAsset.scss.js";import"../../../../componentsV2/AppDqPopover/AppDqPopover.scss.js";import"../../../../utils/getSingleAsset.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorChip/AssetSelectorChip.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/constants.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorSelect/AssetSelectorSelect.scss.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelectorSelect/loadAssets.js";import"../../../../componentsV2/AppHeader/V3/AssetSelector/AssetSelector.scss.js";import"../../../../componentsV2/AppHeader/V3/AppTitle/AppTitle.constants.js";import"../../../../componentsV2/AppContainer/headerCommon.scss.js";import"../../../../componentsV2/AppHeader/V3/AppTitle/AppTitle.scss.js";import"../../../../componentsV2/AppHeader/V3/constants.scss.js";import"@babel/runtime/helpers/typeof";import"../../../../componentsV2/AppHeader/V3/SettingsButton/SettingsButton.js";import"../../../../componentsV2/AppHeader/V3/SettingsButton/SettingsButton.constants.js";import"../../../../componentsV2/AppSettings/AppSettings.js";import"../../../../componentsV2/AppSettings/AppSettings.constants.js";import"../../../../componentsV2/AppSettings/AppSettingsPinningContext.js";import"../../../../componentsV2/AppSizeProvider/AppSizeProvider.js";import"../../../../componentsV2/AppHeader/V3/Actions/Actions.constants.js";import"../../../../componentsV2/AppHeader/V3/Actions/Actions.scss.js";import"../../../../componentsV2/AppHeader/V3/AppHeaderV3.scss.js";import"../../../../componentsV2/AppHeader/AppHeader.scss.js";import"../../../../componentsV2/OffsetWellsButton/OffsetWellsButton.js";import"../../../../componentsV2/Autocomplete/Autocomplete.scss.js";import"../../../../componentsV2/Menu/MenuItem/MenuItem.js";import"../../../../componentsV2/Autocomplete/AutocompleteListBox.js";import"../../../../componentsV2/AppSettingsDivider/AppSettingsDivider.scss.js";import"../../../../componentsV2/WellArchivedMessage/WellArchivedMessage.js";import"../../../../componentsV2/DatePicker/DatePicker.js";import"../../../../componentsV2/DragHandle/DragHandle.js";import"../../../../componentsV2/CompletionsOffsetWellPicker/CompletionsOffsetWellPicker.js";import"../../../DevCenter/DevCenterAppContainer/components/FullscreenButton/FullscreenButton.js";import"../../../DevCenter/DevCenterAppContainer/components/AppInfoMessage/AppInfoMessage.js";import"../../../DevCenter/DevCenterAppContainer/components/DevCenterAppView/DevCenterAppView.js";import"../../../DevCenter/DevCenterAppContainer/components/RestoreAppSizeButton/index.js";import"rollbar";import"@rollbar/react";import"../../../DevCenter/DevCenterAppContainer/components/CommentsSwitch/CommentsSwitchButton.scss.js";import"../../../DevCenter/DevCenterAppContainer/DevCenterAppContainer.css.js";import"../../../Icons/AnnotationIcon.js";import"../../../Annotations/components/AnnotationsList/index.js";import"../../../Annotations/components/LastAnnotation/index.js";import"../../../Annotations/AnnotationsContext.js";import"../../../Toaster/Toaster.js";import"../../../HelpCenter/HelpCenterIcon.js";import"../../../DevCenter/NavigationBar/NavigationBar.js";import"../../../DevCenter/SideBar/SideBar.js";import"../../../DevCenter/AppSettingsPopover/AppSettingsPopover.js";import"../../../DevCenter/AppFilterPanelLayout/AppFilterPanelLayout.js";import"../../../DevCenter/IsolatedDevCenterAppContainer/DevCenterIsolatedAppPage.js";import"../../../DevCenter/IsolatedDevCenterAppContainer/DevCenterIsolatedApp.js";import"../../../AssetEditor/index.js";import"../../../AssetEditorV2/index.js";import"../../../AppVersionsSelect/AppVersionsSelect.js";import F from"../../../LoadingIndicator/LoadingIndicator.js";import"../../../Typography.js";import"../../../RealTimeValuesSidebar/RealTimeSidebar.js";import"../../../CollapsableSidebar.js";import"../../../DateTimePicker/index.js";import"../../../DatePicker/index.js";import"../../../ErrorBoundary/ErrorBoundary.js";import"../../../ErrorBoundary/DevCenterAppErrorView/DevCenterAppErrorView.js";import"../../../SlateFormattedText/SlateFormattedText.js";import"../../../SlateFormattedText/RenderElements.js";import"slate";import"../../../EmptyState/EmptyState.js";import"../../../ParameterCharts/ParameterCharts.js";import"../../../ParameterCharts/AddEditTrack.js";import"../../../ChartActionsList/ChartActionsList.js";import"../../../CopyToClipboard/CopyToClipboard.js";import"../../../AssetEditor/AssetEditorAutocomplete.js";import"../../../AssetEditor/SingleAssetEditor.js";import"react-color";import"../../../SettingEditors/ColorEditor/style.css.js";import"../../../SettingEditors/DropdownEditor/index.js";import"../../../SwitchControl/index.js";import"../../../ColorPicker/ColorPicker.js";import"../../../Chart/components/ChartButton.js";import"../../../Chart/components/ChartButtons.js";import"../../../Chart/components/ChartWrapper.js";import"../../../Chart/components/AxisDropdown.js";import"../../../Chart/components/ChartSelect.js";import"../../../Chart/components/buttons/DragToZoomButton.js";import"../../../Chart/components/buttons/ZoomInButton.js";import"../../../Chart/components/buttons/ZoomOutButton.js";import"../../../Chart/components/buttons/PanButton.js";import"../../../Chart/components/buttons/ResetZoomButton.js";import"../../../Chart/components/buttons/HideAxesButton.js";import"../../../Chart/components/buttons/ChartTypeButton.js";import"../../../ColorPicker/PaletteChromePicker/PaletteChromePicker.js";import"../../../TruncatedText/index.js";import"../../../MiddleTruncatedText/MiddleTruncatedText.js";import"../../../RangeSlider/constants.js";import"../../../RangeSlider/Input.css.js";import"../../../RangeSlider/RangeSlider.css.js";import"../../../AdvancedSlider/AdvancedSlider.js";import"../../../Breadcrumbs/index.js";import"../../../VirtualizedTable/index.js";import"../../../EmptyView/EmptyView.js";import"../../../EmptyView/EmptyAppView/EmptyAppView.js";import"../../../Button/components/Button/index.js";import"moment-timezone";import"../../../Button/components/LiveButton/components/LiveButtonStateIndicator/index.js";import"../../../Button/components/LiveButton/styles.js";import"../../../ContextMenuItem/index.js";import"../../../FolderMenuItem/index.js";import"../../../EditableItem/EditableItem/index.js";import"../../../EditableItem/EditableItemWithBadge/index.js";import"../../../Checkbox/index.js";import"../../../FolderMenuItemWithLinks/index.js";import"../../../TextField/index.js";import"../../../Chip/index.js";import"../../../Counter/index.js";import"../../../AnchorsList/AnchorsList.js";import"../../../Select/index.js";import"../../../Select/SelectFilterBy.js";import"../../../CustomSelect/index.js";import"../../../Tabs/Tabs.js";import"../../../Tabs/Tab.js";import"../../../ResizableTable/ResizableTable.js";import"../../../GradientPicker/GradientPicker.js";import"../../../GradientManager/GradientList.js";import"@material-ui/icons/AddCircle";import"../../../GradientManager/GradientPreview/GradientPreview.js";import"../../../GradientManager/GradientSelect.styles.js";import"../../../GradientManager/GradientManager.styles.js";import"../../../Drillstring/BHASchematic.js";import"../../../Drillstring/BHATable/index.js";import"../../../Drillstring/BHAComponentIcon.js";import"../../../Drillstring/BHAComponentDetail/index.js";import"../../../Drillstring/BHATileIcon.js";import"../../../Drillstring/BHATile/BHATile.js";import"../../../Drillstring/BHAList/BHAList.js";import"../../../Drillstring/BHAComponentsTable/BHAComponentsTable.js";import"../../../Casing/CasingTable/index.js";import"../../../Casing/CasingComponentIcon.js";import"../../../Casing/CasingTileIcon.js";import"../../../Casing/CasingTableV2/CasingTableV2.js";import"../../../Casing/CasingTile/CasingTile.js";import"../../../DisabledSettingsMessage/DisabledSettingsMessage.js";import"../../../WellSummary/WellSummaryItemLabel.js";import"../../../WellSummary/WellSummaryItemTitle.js";import"../../../WellSummary/WellSummaryItemValue.js";import"../../../WellSummary/ActivitySummaryChart.js";import"../../../WellSummary/FracWirelineTimeChart.js";import"../../../BICOffsetPickerDialog/index.js";import"../../../OffsetWellButton/OffsetWellButton.js";import"../../../OffsetWellPickerV2/OffsetWellPickerDialog.js";import"../../../OffsetWellPickerV3/index.js";import"../../../OffsetWellChips/Chip.js";import"../../../OffsetWellChips/ChipsContainer.js";import"../../../OffsetWellPickerV5/OffsetWellPickerV5WithStore.js";import"../../utils/apiCalls.js";import"../../effects/useAdvancedWells.js";import"react-virtualized";import"../../effects/useAssetsData.js";import"../../../../permissions/PermissionsContext.js";import"../../../../permissions/constants/index.js";import"../../../../permissions/withPermissionsHOC.js";import"../../../../permissions/ProvidePermissions.js";import"../AppHeader/AppHeader.js";import"../Toolbar/Toolbar.js";import"../Filter/Filter.js";import"../Map/WellsMap.js";import"./AdvancedSearch/constants.js";import"../../utils/index.js";import"../../OffsetWellPickerV4.module.css.js";import"@material-ui/core/Snackbar";import"../../../Notifications/Toast.js";import"../../../Notifications/Notifications.scss.js";import"../../../../styles/typography/index.js";import"../../../../styles/counter/counter.module.scss.js";import"../../../OffsetWellMap/OffsetWellMap.js";import"../../../ConfirmationDialog.js";import"../../../TextLink/index.js";import"../../../Avatar/index.js";import"../../../Template/TemplatePopover/index.js";import"../../../Template/TemplateSharingDialog/index.js";import"../../../MenuItem/index.js";import"../../../MiddleTruncate/MiddleTruncate.js";import"../../../PinnableFilters/PinnableFilters.js";import"../../../HeaderLayout/HeaderLayout.js";import"../../../PadOffsetsPicker/PadOffsetsPicker.js";import"../../../PadOffsetsPicker/OffsetAssetChip.js";import"../../../PadOffsetsPicker/OffsetAssetsListExpander.js";import"../../../PadOffsetsPicker/StagesSelector.js";import"../../../PadOffsetsPickerV2/PadOffsetsPickerV2.js";import"../../../Table/TableToolbar/TableToolbar.js";import"../../../Table/TableContainer/TableContainer.js";import"../../../Table/TableCell/TableCell.js";import"../../../Table/TablePagination/TablePagination.js";import"../../../Table/TablePaginationActions/TablePaginationActions.js";import"../../../Tooltip/ScrollableTooltip.js";import"../../../PriceInput/PriceInput.js";import"../../../LabelsCounter/LabelsCounter.js";import"../../../Stepper/Stepper.js";import"../../../Stepper/Step/Step.js";import"../../../Stepper/StepsWrapper.js";import"../../../Comment/CommentIcon/index.js";import"../../../FilesLoader/FilesLoader.js";import"../../../../componentsV2/FileIcon/icons/ArchiveFileIcon.js";import"../../../../componentsV2/FileIcon/icons/CSVFileIcon.js";import"../../../../componentsV2/FileIcon/icons/DocFileIcon.js";import"../../../../componentsV2/FileIcon/icons/EDMFileIcon.js";import"../../../../componentsV2/FileIcon/icons/ExcelFileIcon.js";import"../../../../componentsV2/FileIcon/icons/ImageFileIcon.js";import"../../../../componentsV2/FileIcon/icons/JsonFileIcon.js";import"../../../../componentsV2/FileIcon/icons/LasFileIcon.js";import"../../../../componentsV2/FileIcon/icons/OtherFileIcon.js";import"../../../../componentsV2/FileIcon/icons/PdfFileIcon.js";import"../../../../componentsV2/FileIcon/icons/PowerPointFileIcon.js";import"../../../../componentsV2/FileIcon/icons/TxtFileIcon.js";import"../../../../componentsV2/FileIcon/icons/UnknownFileIcon.js";import"../../../../componentsV2/FileIcon/icons/VideoFileIcon.js";import"../../../../componentsV2/FileIcon/icons/XmlFileIcon.js";import"../../../SearchInput/index.js";import"../../../FeedItem/FeedItem.js";import"../../../FeedItem/FeedItemEditProvider/FeedItemEditProvider.js";import"../../../PostInput/PostInput.js";import"../../../KeyboardDateTimePicker.js";import"../../../AddComment/Popover.js";import"../../../AddComment/Popup.js";import"../../../StageDesignVActual/ComparisonBar/ComparisonBar.js";import"../../../StageDesignVActual/ElementsComparison/ElementsComparison.js";import"../../../StageDesignVActual/ComparisonHeader.js";import"../../../StageDesignVActual/ComparisonRow.js";import"../../../EmbeddedApp/DevCenterEmbeddedApp.js";import"../../../EmbeddedApp/EmbeddedApp.js";import"../../../Autocomplete/Autocomplete.js";import"../../../DocumentViewer/DocumentViewer.js";import"../../../ColorPickerPalette/ColorPickerPalette.js";import"../../../Search/Search.js";import"../../../Search/components/Listbox.js";import"../../../Search/components/Paper.js";import"../../../Search/components/RecentSearches.js";import"../../../Search/components/Groups.js";import"../../../Search/components/SelectAllListItem.js";import"../../../StatusBadge/index.js";import"../../../Attachment/index.js";import"../../../EmojiIconButton.js";import"../../../FileUploadIconButton.js";import"../../../FilePreview/index.js";import"../../../FailedFileUploading.js";import"../../../UserMention/index.js";import"../../../CommentsInfo/index.js";import"../../../CommentInput/index.js";import"../../../Comment/index.js";import"../../../CommentLoader.js";import"../../../AssetNameLabel/AssetStatusBadge.js";import"../../../AssetEditorV2/components/PrimaryAssetSelect.js";import"../../../AssetEditorV2/components/SecondaryAssetSelect.js";import"../../../AssetEditorV2/components/SelectItem.js";import"../../../AssetEditorV2/components/MultipleAssetsToggle.js";import"../../../AssetEditorV2/components/PrimaryAssetSelectV2.js";import"../../../EChartsWrapper/EChartsWrapper.js";import"../../../AssetsMultipleSelector/AssetsMultipleSelector.js";import"@material-ui/icons/Close";import"@material-ui/icons/GetApp";import"../../../GoogleDocsViewer/index.js";import"../../../NewDocumentViewer/effects/useFileContent.js";import"../../../NewDocumentViewer/styles.js";import"../../../FilesLoaderV2/styles.js";import"../../../FilesDropzone/styles.js";import"../../../FilesProcessor/styles.js";import"../../../Hint/styles.js";import"@babel/runtime/helpers/taggedTemplateLiteral";import"fparser";import"../../../Formula/useFormulaStyles.js";import"../../../Formula/RootXIcon.js";import"../../../Formula/FormulaTextEditor.js";import"../../../Formula/CloseSuggestion.js";import"../../../Formula/SuggestionsMenu.js";function B(e,t){var o=e.find((function(e){return e.key===t}));return(null==o?void 0:o.width)||0}var W=function(o){var c=o.open,W=o.isTableLoading,L=o.companyId,M=o.subjectWellId,E=o.sortBy,w=o.setSortBy,R=o.sortDirection,k=o.setSortDirection,H=o.columnsWithDict,O=o.wells,q=o.metricsKeys,N=o.setMetricsKeys,G=o.handleChangeOffsetWell,U=o.handleChangeAllOffsetWells,z=o.handleAddRemoveAssets,K=o.isWellNameExpand,Z=o.setIsWellNameExpand,X=o.isHScrollMoved,J=o.onHideAdvancedSearch,Q=o.isViewOnly,Y=o.isLastWell,$=o.contentRef,_=o.offsetWellsContainerRef,ee=o.isLimitedOffsetWells,te=o.maxOffsetWellNumber,oe=o.wellSections,se=o.setActiveWellId,ie=o.viewType,ne=o.isWDUser,re=o.taScores,pe=s([]),me=t(pe,2),ce=me[0],ae=me[1],le=i(),de=i();n((function(){var e=a(O,"id");ae(e)}),[O,O.length]);var je=r((function(){return a(ce,"id")}),[ce]),ue=r((function(){var e=je.filter((function(e){return e.checked}));return[e,je.length!==e.length&&e.length&&!ee,e.length===je.length||ee]}),[je,ee]),Ae=t(ue,3),Ce=Ae[0],Se=Ae[1],he=Ae[2],Ve=r((function(){return v()}),[]),fe=r((function(){return(q||[]).reduce((function(e,t){return e.concat(C.filter((function(e){return e.key===t})))}),[])}),[q]),Ie=r((function(){return K?S-58:h[0].width[q.length]-58}),[K,null==q?void 0:q.length]),ge=r((function(){var e=K?I:g;return re.length&&(e+=B(H,V.taScore)),null!=H&&H.some((function(e){return e.key===V.company}))&&(e+=B(H,V.company)),"".concat(e,"px")}),[K,re,H]);n((function(){if(ie!==f.mobile&&le.current&&de.current){var e=le.current.querySelector(".".concat(P.wellNameFixed));X?e.classList.remove(P.noShadow):e.classList.add(P.noShadow);var t=de.current.querySelectorAll(".".concat(P.wellNameFixed));X?t.forEach((function(e){return e.classList.remove(P.noShadow)})):t.forEach((function(e){return e.classList.add(P.noShadow)}))}}),[X,de.current,le.current,ce]);var ve=p((function(e,t){w(e),k(t)}),[]),be=p((function(e){N(e)}),[]),De=p((function(e,t){N((function(o){return o.map((function(o){return o===e?t:o}))}))}),[]);return H&&je?x("div",{className:P.offsetWellsTable,children:[y("div",{className:P.stickyTable,children:y(l,{"aria-label":"ows table head",innerRef:le,children:y(d,{children:y(D,{open:c,columnsWithDict:H,metricsKeys:q,sortBy:E,sortDirection:R,indeterminate:Se,isAllWellsSelected:he,onChangeSort:ve,onChangeMetricsKeys:be,onUpdateMetricsKey:De,isWellNameExpand:K,setIsWellNameExpand:Z,handleChangeAllOffsetWells:U,wellNameStyle:P.wellNameFixed,isViewOnly:Q,isImperial:Ve,contentRef:$,viewType:ie,isTaColumnVisible:!!re.length})})})}),!Q&&x("div",{className:m(P.searchCellWrapper,e({},P.searchCellWrapperExpanded,K)),style:{"--dynamic-search-wrapper-width":ge},children:[y("div",{className:P.searchCell,children:y(b,{companyId:L,subjectWellId:M,onChange:z,selectedWellIds:Ce.map((function(e){return e.id})),onHideAdvancedSearch:J})}),!!K&&y("div",{className:P.searchCellEmpty})]}),y(l,{"aria-label":"ows table body",innerRef:de,className:P.bodyTable,children:x(j,{children:[y(u,{children:y(A,{className:m(P.topShadow,e({},P.viewOnlyShadow,Q))})}),je.map((function(e){return y(T,{columnsWithDict:H,subjectWellId:M,data:e,metricsKeys:q,metricsColumns:fe,handleChangeOffsetWell:G,isWellNameExpand:K,wellNameStyle:P.wellNameFixed,wellNameWidth:Ie,isViewOnly:Q,isImperial:Ve,isLimitedOffsetWells:ee,maxOffsetWellNumber:te,wellSections:oe,setActiveWellId:se,viewType:ie,isWDUser:ne,taScores:re,offsetWellsContainerRef:_},e.id)})),!Y&&y(u,{children:y(A,{className:P.loadingCell,children:y("span",{children:"Loading..."})})}),y(u,{children:y(A,{className:P.bottomShadow})})]})}),W&&y("div",{className:P.loadingContainer,children:y(F,{fullscreen:!1,className:P.loadingIndicator})})]}):null};W.propTypes={open:c.bool.isRequired,isTableLoading:c.bool.isRequired,companyId:c.number.isRequired,subjectWellId:c.number.isRequired,sortBy:c.string.isRequired,setSortBy:c.func.isRequired,sortDirection:c.string.isRequired,setSortDirection:c.func.isRequired,columnsWithDict:c.arrayOf(c.shape({})).isRequired,wells:c.arrayOf(c.shape({})).isRequired,metricsKeys:c.arrayOf(c.string).isRequired,setMetricsKeys:c.func.isRequired,handleChangeOffsetWell:c.func.isRequired,handleChangeAllOffsetWells:c.func.isRequired,handleAddRemoveAssets:c.func.isRequired,setIsWellNameExpand:c.func.isRequired,isWellNameExpand:c.bool.isRequired,isHScrollMoved:c.bool.isRequired,onHideAdvancedSearch:c.func.isRequired,isViewOnly:c.bool.isRequired,isLastWell:c.bool.isRequired,isLimitedOffsetWells:c.bool.isRequired,maxOffsetWellNumber:c.number.isRequired,contentRef:c.shape({}).isRequired,offsetWellsContainerRef:c.shape({}).isRequired,wellSections:c.arrayOf(c.shape({})).isRequired,setActiveWellId:c.func.isRequired,viewType:c.string.isRequired,isWDUser:c.bool.isRequired,taScores:c.arrayOf(c.shape({})).isRequired};var L=o(W);export{L as default};
|
|
2
|
-
//# sourceMappingURL=OffsetWellsTable.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"OffsetWellsTable.js","sources":["../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.js"],"sourcesContent":["import { useState, memo, useCallback, useEffect, useMemo, useRef } from 'react';\nimport classNames from 'classnames';\nimport PropTypes from 'prop-types';\nimport { uniqBy } from 'lodash';\nimport { Table, TableBody, TableCell, TableHead, TableRow } from '@material-ui/core';\n\nimport {\n ColumnType,\n EXPANDED_WELL_NAME_WIDTH,\n SEARCH_CELL_DEFAULT_WIDTH,\n SEARCH_CELL_EXPAND_WIDTH,\n METRICS_LIST,\n TableColumns,\n ViewType,\n} from '../../constants';\nimport { getIsImperial } from '../../utils/unitSystem';\n\nimport { AdvancedSearch } from './AdvancedSearch';\nimport OffsetWellsTableHead from './OffsetWellsTableHead';\nimport OffsetWellsTableRow from './OffsetWellsTableRow';\n\nimport styles from './OffsetWellsTable.module.css';\n\nimport { LoadingIndicator } from '~/components';\n\nconst DIFF_WELL_NAME_WIDTH = 58;\n\nfunction getCellWidth(columnsWithDict, key) {\n const cell = columnsWithDict.find(item => item.key === key);\n return cell?.width || 0;\n}\n\nconst OffsetWellsTable = ({\n open,\n isTableLoading,\n companyId,\n subjectWellId,\n sortBy,\n setSortBy,\n sortDirection,\n setSortDirection,\n columnsWithDict,\n wells: updatedWells,\n metricsKeys,\n setMetricsKeys,\n handleChangeOffsetWell,\n handleChangeAllOffsetWells,\n handleAddRemoveAssets,\n isWellNameExpand,\n setIsWellNameExpand,\n isHScrollMoved,\n onHideAdvancedSearch,\n isViewOnly,\n isLastWell,\n contentRef,\n offsetWellsContainerRef,\n isLimitedOffsetWells,\n maxOffsetWellNumber,\n wellSections,\n setActiveWellId,\n viewType,\n isWDUser,\n taScores,\n}) => {\n const [wells, setWells] = useState([]);\n /** @type {ReturnType<typeof useRef<HTMLElement>>} */\n const headTableRef = useRef();\n /** @type {ReturnType<typeof useRef<HTMLElement>>} */\n const bodyTableRef = useRef();\n\n useEffect(() => {\n const uniqUpdatedWells = uniqBy(updatedWells, 'id');\n setWells(uniqUpdatedWells);\n }, [updatedWells, updatedWells.length]);\n\n const uniqWells = useMemo(() => uniqBy(wells, 'id'), [wells]);\n\n const [selectedWells, indeterminate, isAllWellsSelected] = useMemo(() => {\n const selectedWells = uniqWells.filter(well => well.checked);\n const indeterminate =\n uniqWells.length !== selectedWells.length && selectedWells.length && !isLimitedOffsetWells;\n const isAllWellsSelected = selectedWells.length === uniqWells.length || isLimitedOffsetWells;\n\n return [selectedWells, indeterminate, isAllWellsSelected];\n }, [uniqWells, isLimitedOffsetWells]);\n\n const isImperial = useMemo(() => getIsImperial(), []);\n\n const metricsColumns = useMemo(() => {\n // NOTE: Pay attention to the order of metrics and duplication\n return (metricsKeys || []).reduce(\n (result, key) => result.concat(METRICS_LIST.filter(item => item.key === key)),\n []\n );\n }, [metricsKeys]);\n\n const wellNameWidth = useMemo(() => {\n if (isWellNameExpand) return EXPANDED_WELL_NAME_WIDTH - DIFF_WELL_NAME_WIDTH;\n return TableColumns[0].width[metricsKeys.length] - DIFF_WELL_NAME_WIDTH;\n }, [isWellNameExpand, metricsKeys?.length]);\n\n const searchWrapperWidth = useMemo(() => {\n let initialWidth = isWellNameExpand ? SEARCH_CELL_EXPAND_WIDTH : SEARCH_CELL_DEFAULT_WIDTH;\n // Include TA column width if visible\n if (taScores.length) {\n initialWidth += getCellWidth(columnsWithDict, ColumnType.taScore);\n }\n // Include Company column width when present\n if (columnsWithDict?.some(col => col.key === ColumnType.company)) {\n initialWidth += getCellWidth(columnsWithDict, ColumnType.company);\n }\n return `${initialWidth}px`;\n }, [isWellNameExpand, taScores, columnsWithDict]);\n\n // NOTE: Remove shadow from column\n useEffect(() => {\n if (viewType === ViewType.mobile || !headTableRef.current || !bodyTableRef.current) return;\n // Head table\n const headColumn = headTableRef.current.querySelector(`.${styles.wellNameFixed}`);\n if (!isHScrollMoved) {\n headColumn.classList.add(styles.noShadow);\n } else {\n headColumn.classList.remove(styles.noShadow);\n }\n\n // Body table\n const bodyColumns = bodyTableRef.current.querySelectorAll(`.${styles.wellNameFixed}`);\n if (!isHScrollMoved) {\n bodyColumns.forEach(th => th.classList.add(styles.noShadow));\n } else {\n bodyColumns.forEach(th => th.classList.remove(styles.noShadow));\n }\n }, [isHScrollMoved, bodyTableRef.current, headTableRef.current, wells]);\n\n const handleChangeSortBy = useCallback((sortKey, sortDirection) => {\n setSortBy(sortKey);\n setSortDirection(sortDirection);\n }, []);\n\n const handleChangeMetricsKeys = useCallback(newMetricsKeys => {\n setMetricsKeys(newMetricsKeys);\n }, []);\n\n const handleUpdateMetricsKey = useCallback((key, newValue) => {\n setMetricsKeys(prevKeys => prevKeys.map(item => (item === key ? newValue : item)));\n }, []);\n\n if (!columnsWithDict || !uniqWells) return null;\n\n return (\n <div className={styles.offsetWellsTable}>\n <div className={styles.stickyTable}>\n <Table aria-label=\"ows table head\" innerRef={headTableRef}>\n <TableHead>\n <OffsetWellsTableHead\n open={open}\n columnsWithDict={columnsWithDict}\n metricsKeys={metricsKeys}\n sortBy={sortBy}\n sortDirection={sortDirection}\n indeterminate={indeterminate}\n isAllWellsSelected={isAllWellsSelected}\n onChangeSort={handleChangeSortBy}\n onChangeMetricsKeys={handleChangeMetricsKeys}\n onUpdateMetricsKey={handleUpdateMetricsKey}\n isWellNameExpand={isWellNameExpand}\n setIsWellNameExpand={setIsWellNameExpand}\n handleChangeAllOffsetWells={handleChangeAllOffsetWells}\n wellNameStyle={styles.wellNameFixed}\n isViewOnly={isViewOnly}\n isImperial={isImperial}\n contentRef={contentRef}\n viewType={viewType}\n isTaColumnVisible={!!taScores.length}\n />\n </TableHead>\n </Table>\n </div>\n\n {!isViewOnly && (\n <div\n className={classNames(styles.searchCellWrapper, {\n [styles.searchCellWrapperExpanded]: isWellNameExpand,\n })}\n style={{ '--dynamic-search-wrapper-width': searchWrapperWidth }}\n >\n <div className={styles.searchCell}>\n <AdvancedSearch\n companyId={companyId}\n subjectWellId={subjectWellId}\n onChange={handleAddRemoveAssets}\n selectedWellIds={selectedWells.map(({ id }) => id)}\n onHideAdvancedSearch={onHideAdvancedSearch}\n />\n </div>\n {!!isWellNameExpand && <div className={styles.searchCellEmpty} />}\n </div>\n )}\n\n <Table aria-label=\"ows table body\" innerRef={bodyTableRef} className={styles.bodyTable}>\n <TableBody>\n <TableRow>\n <TableCell\n className={classNames(styles.topShadow, { [styles.viewOnlyShadow]: isViewOnly })}\n />\n </TableRow>\n {uniqWells.map(well => (\n <OffsetWellsTableRow\n key={well.id}\n columnsWithDict={columnsWithDict}\n subjectWellId={subjectWellId}\n data={well}\n metricsKeys={metricsKeys}\n metricsColumns={metricsColumns}\n handleChangeOffsetWell={handleChangeOffsetWell}\n isWellNameExpand={isWellNameExpand}\n wellNameStyle={styles.wellNameFixed}\n wellNameWidth={wellNameWidth}\n isViewOnly={isViewOnly}\n isImperial={isImperial}\n isLimitedOffsetWells={isLimitedOffsetWells}\n maxOffsetWellNumber={maxOffsetWellNumber}\n wellSections={wellSections}\n setActiveWellId={setActiveWellId}\n viewType={viewType}\n isWDUser={isWDUser}\n taScores={taScores}\n offsetWellsContainerRef={offsetWellsContainerRef}\n />\n ))}\n {!isLastWell && (\n <TableRow>\n <TableCell className={styles.loadingCell}>\n <span>Loading...</span>\n </TableCell>\n </TableRow>\n )}\n <TableRow>\n <TableCell className={styles.bottomShadow} />\n </TableRow>\n </TableBody>\n </Table>\n\n {isTableLoading && (\n <div className={styles.loadingContainer}>\n <LoadingIndicator fullscreen={false} className={styles.loadingIndicator} />\n </div>\n )}\n </div>\n );\n};\n\nOffsetWellsTable.propTypes = {\n open: PropTypes.bool.isRequired,\n isTableLoading: PropTypes.bool.isRequired,\n companyId: PropTypes.number.isRequired,\n subjectWellId: PropTypes.number.isRequired,\n sortBy: PropTypes.string.isRequired,\n setSortBy: PropTypes.func.isRequired,\n sortDirection: PropTypes.string.isRequired,\n setSortDirection: PropTypes.func.isRequired,\n columnsWithDict: PropTypes.arrayOf(PropTypes.shape({})).isRequired,\n wells: PropTypes.arrayOf(PropTypes.shape({})).isRequired,\n metricsKeys: PropTypes.arrayOf(PropTypes.string).isRequired,\n setMetricsKeys: PropTypes.func.isRequired,\n handleChangeOffsetWell: PropTypes.func.isRequired,\n handleChangeAllOffsetWells: PropTypes.func.isRequired,\n handleAddRemoveAssets: PropTypes.func.isRequired,\n setIsWellNameExpand: PropTypes.func.isRequired,\n isWellNameExpand: PropTypes.bool.isRequired,\n isHScrollMoved: PropTypes.bool.isRequired,\n onHideAdvancedSearch: PropTypes.func.isRequired,\n isViewOnly: PropTypes.bool.isRequired,\n isLastWell: PropTypes.bool.isRequired,\n isLimitedOffsetWells: PropTypes.bool.isRequired,\n maxOffsetWellNumber: PropTypes.number.isRequired,\n contentRef: PropTypes.shape({}).isRequired,\n offsetWellsContainerRef: PropTypes.shape({}).isRequired,\n wellSections: PropTypes.arrayOf(PropTypes.shape({})).isRequired,\n setActiveWellId: PropTypes.func.isRequired,\n viewType: PropTypes.string.isRequired,\n isWDUser: PropTypes.bool.isRequired,\n taScores: PropTypes.arrayOf(PropTypes.shape({})).isRequired,\n};\n\nexport default memo(OffsetWellsTable);\n"],"names":["getCellWidth","columnsWithDict","key","cell","find","item","width","OffsetWellsTable","_ref","open","isTableLoading","companyId","subjectWellId","sortBy","setSortBy","sortDirection","setSortDirection","updatedWells","wells","metricsKeys","setMetricsKeys","handleChangeOffsetWell","handleChangeAllOffsetWells","handleAddRemoveAssets","isWellNameExpand","setIsWellNameExpand","isHScrollMoved","onHideAdvancedSearch","isViewOnly","isLastWell","contentRef","offsetWellsContainerRef","isLimitedOffsetWells","maxOffsetWellNumber","wellSections","setActiveWellId","viewType","isWDUser","taScores","useState","_useState2","_slicedToArray","_useState","setWells","headTableRef","useRef","bodyTableRef","useEffect","uniqUpdatedWells","uniqBy","length","uniqWells","useMemo","selectedWells","filter","well","checked","_useMemo2","_useMemo","indeterminate","isAllWellsSelected","isImperial","getIsImperial","metricsColumns","reduce","result","concat","METRICS_LIST","wellNameWidth","EXPANDED_WELL_NAME_WIDTH","TableColumns","searchWrapperWidth","initialWidth","SEARCH_CELL_EXPAND_WIDTH","SEARCH_CELL_DEFAULT_WIDTH","ColumnType","taScore","some","col","company","ViewType","mobile","current","headColumn","querySelector","styles","wellNameFixed","classList","remove","noShadow","add","bodyColumns","querySelectorAll","forEach","th","handleChangeSortBy","useCallback","sortKey","handleChangeMetricsKeys","newMetricsKeys","handleUpdateMetricsKey","newValue","prevKeys","map","_jsxs","className","offsetWellsTable","children","_jsx","stickyTable","Table","innerRef","TableHead","OffsetWellsTableHead","onChangeSort","onChangeMetricsKeys","onUpdateMetricsKey","wellNameStyle","isTaColumnVisible","classNames","searchCellWrapper","searchCellWrapperExpanded","style","searchCell","AdvancedSearch","onChange","selectedWellIds","_ref2","id","searchCellEmpty","bodyTable","TableBody","TableRow","TableCell","topShadow","_defineProperty","viewOnlyShadow","OffsetWellsTableRow","data","loadingCell","bottomShadow","loadingContainer","LoadingIndicator","fullscreen","loadingIndicator","propTypes","PropTypes","bool","isRequired","number","string","func","arrayOf","shape","memo"],"mappings":"kpyBA2BA,SAASA,EAAaC,EAAiBC,GACrC,IAAMC,EAAOF,EAAgBG,MAAK,SAAAC,GAAI,OAAIA,EAAKH,MAAQA,KACvD,OAAOC,eAAAA,EAAMG,QAAS,CACxB,CAEA,IAAMC,EAAmB,SA+BnBC,GAAA,IA9BJC,IAAAA,KACAC,IAAAA,eACAC,IAAAA,UACAC,IAAAA,cACAC,IAAAA,OACAC,IAAAA,UACAC,IAAAA,cACAC,IAAAA,iBACAf,IAAAA,gBACOgB,IAAPC,MACAC,IAAAA,YACAC,IAAAA,eACAC,IAAAA,uBACAC,IAAAA,2BACAC,IAAAA,sBACAC,IAAAA,iBACAC,IAAAA,oBACAC,IAAAA,eACAC,IAAAA,qBACAC,IAAAA,WACAC,IAAAA,WACAC,IAAAA,WACAC,IAAAA,wBACAC,KAAAA,qBACAC,KAAAA,oBACAC,KAAAA,aACAC,KAAAA,gBACAC,KAAAA,SACAC,KAAAA,SACAC,KAAAA,SAE0BC,GAAAA,EAAS,IAAGC,GAAAC,EAAAC,GAAA,GAA/BxB,GAAKsB,GAAA,GAAEG,GAAQH,GAAA,GAEhBI,GAAeC,IAEfC,GAAeD,IAErBE,GAAU,WACR,IAAMC,EAAmBC,EAAOhC,EAAc,MAC9C0B,GAASK,EACV,GAAE,CAAC/B,EAAcA,EAAaiC,SAE/B,IAAMC,GAAYC,GAAQ,WAAA,OAAMH,EAAO/B,GAAO,QAAO,CAACA,KAEKkC,GAAAA,GAAQ,WACjE,IAAMC,EAAgBF,GAAUG,QAAO,SAAAC,GAAI,OAAIA,EAAKC,WAKpD,MAAO,CAACH,EAHNF,GAAUD,SAAWG,EAA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@@
|
|
|
1
|
-
import e from'./../../../../ext-esm/style-inject/dist/style-inject.es.js';var l={offsetWellsTable:"OffsetWellsTable-module_offsetWellsTable__pGL-8",loadingContainer:"OffsetWellsTable-module_loadingContainer__lA0IJ",loadingIndicator:"OffsetWellsTable-module_loadingIndicator__j5pye",stickyTable:"OffsetWellsTable-module_stickyTable__LZCzy",searchCellWrapper:"OffsetWellsTable-module_searchCellWrapper__n8cod",searchCellWrapperExpanded:"OffsetWellsTable-module_searchCellWrapperExpanded__pWrzU",searchCell:"OffsetWellsTable-module_searchCell__3IW23",searchCellEmpty:"OffsetWellsTable-module_searchCellEmpty__1sB-v",bodyTable:"OffsetWellsTable-module_bodyTable__djKsG",bodyGrid:"OffsetWellsTable-module_bodyGrid__Ss17M",loadingCell:"OffsetWellsTable-module_loadingCell__rBu7-",topShadow:"OffsetWellsTable-module_topShadow__MPc8N",viewOnlyShadow:"OffsetWellsTable-module_viewOnlyShadow__DOW-4",bottomShadow:"OffsetWellsTable-module_bottomShadow__jxM6E",wellNameFixed:"OffsetWellsTable-module_wellNameFixed__tKtuD",noShadow:"OffsetWellsTable-module_noShadow__Ssp7E"};e('.OffsetWellsTable-module_offsetWellsTable__pGL-8{display:flex;flex-direction:column;height:100%;position:relative}.OffsetWellsTable-module_loadingContainer__lA0IJ{align-items:center;backdrop-filter:blur(1px);bottom:0;display:flex;justify-content:center;left:0;position:absolute;right:0;top:0;z-index:1500}.OffsetWellsTable-module_loadingIndicator__j5pye{position:absolute;top:0}.OffsetWellsTable-module_stickyTable__LZCzy{background-color:var(--palette-background-b-7);padding-right:16px;position:sticky;top:0;z-index:9}.OffsetWellsTable-module_searchCellWrapper__n8cod{background-color:var(--palette-background-b-7);display:inline-flex;left:0;position:sticky;top:49px;width:var(--dynamic-search-wrapper-width,1020px);z-index:9}.OffsetWellsTable-module_searchCellWrapperExpanded__pWrzU{width:var(--dynamic-search-wrapper-width,1270px)}.OffsetWellsTable-module_searchCell__3IW23{left:0;position:sticky;top:0;width:1020px;z-index:9}.OffsetWellsTable-module_searchCellEmpty__1sB-v{position:relative;width:250px}.OffsetWellsTable-module_bodyTable__djKsG{background-color:#333;position:relative}.OffsetWellsTable-module_bodyGrid__Ss17M{margin-top:12px!important;overflow:hidden!important}.OffsetWellsTable-module_bodyGrid__Ss17M::-webkit-scrollbar-corner{background:transparent}.OffsetWellsTable-module_loadingCell__rBu7-{border-bottom:none!important;color:var(--palette-primary-text-8)!important;font-size:12px!important;height:16px!important;padding:0!important;position:absolute;text-align:center!important;width:100%;z-index:1000}.OffsetWellsTable-module_topShadow__MPc8N{background-image:linear-gradient(0deg,rgba(51,51,51,0),#333);border-bottom:none!important;height:16px!important;padding:0!important;position:sticky;top:93px;width:100%;z-index:999}.OffsetWellsTable-module_viewOnlyShadow__DOW-4{top:49px}.OffsetWellsTable-module_bottomShadow__jxM6E{border-bottom:none!important;bottom:0;height:16px!important;padding:0!important;position:sticky;width:100%;z-index:999}.OffsetWellsTable-module_bottomShadow__jxM6E:after{background-image:linear-gradient(180deg,rgba(51,51,51,0),#333);bottom:-1px;content:" ";height:16px!important;position:absolute;width:100%}.OffsetWellsTable-module_wellNameFixed__tKtuD{box-shadow:4px 0 6px -3px #191919!important}.OffsetWellsTable-module_noShadow__Ssp7E{box-shadow:none!important}');export{l as default};
|
|
2
|
-
//# sourceMappingURL=OffsetWellsTable.module.css.js.map
|
package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTable.module.css.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA,aAAa,4DAA+D;"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/slicedToArray";import s from"@babel/runtime/helpers/defineProperty";import i from"@babel/runtime/helpers/objectWithoutProperties";import{memo as o,useState as t}from"react";import c from"classnames";import n from"prop-types";import{SortDirection as r}from"react-virtualized";import{TableRow as a,TableCell as l,Checkbox as m,Tooltip as d,TableSortLabel as u}from"@material-ui/core";import{ColumnType as p,ViewType as h,EXPANDED_WELL_NAME_WIDTH as f}from"../../constants.js";import{MetricsSettingMenu as j}from"./MetricsSettingMenu.js";import{MetricsSelect as y}from"./MetricsSelect.js";import b from"./OffsetWellsTableHead.module.css.js";import{RightIcon as C}from"../../../../icons/iconParkIcons.js";import"../../../../icons/customIcons/icons/AddMessage.js";import"../../../../icons/customIcons/icons/Attention.js";import"../../../../icons/customIcons/icons/Collapse.js";import"../../../../icons/customIcons/icons/Dashboard.js";import"../../../../icons/customIcons/icons/Expand.js";import"../../../../icons/customIcons/icons/FolderClosed.js";import"../../../../icons/customIcons/icons/FolderClosedFilled.js";import"../../../../icons/customIcons/icons/FolderOpened.js";import"../../../../icons/customIcons/icons/GreaterOrEqual.js";import"../../../../icons/customIcons/icons/LessOrEqual.js";import"../../../../icons/customIcons/icons/Search.js";import"../../../../icons/customIcons/icons/SearchOne.js";import"../../../../icons/customIcons/icons/Wellhub.js";import"../../../../icons/customIcons/icons/MultiRuler.js";import"../../../../icons/customIcons/icons/Checkbox.js";import"../../../../icons/customIcons/icons/CheckboxChecked.js";import"../../../../icons/customIcons/icons/CheckboxIndeterminate.js";import"../../../../icons/customIcons/icons/Radio.js";import"../../../../icons/customIcons/icons/RadioChecked.js";import"../../../../icons/customIcons/icons/SimulFrac.js";import"../../../../icons/customIcons/icons/ZipperFrac.js";import"../../../../icons/customIcons/icons/CautionFilled.js";import"../../../../icons/customIcons/icons/MoreApp.js";import"../../../../icons/customIcons/icons/Pad.js";import"../../../../icons/customIcons/icons/DrilloutUnit.js";import"../../../../icons/customIcons/icons/FracFleet.js";import"../../../../icons/customIcons/icons/Global.js";import"../../../../icons/customIcons/icons/Program.js";import"../../../../icons/customIcons/icons/Rig.js";import"../../../../icons/customIcons/icons/Well.js";import"../../../../icons/customIcons/icons/Gap.js";import"../../../../icons/customIcons/icons/Pin.js";import"../../../../icons/customIcons/icons/CloseOneFilled.js";import"../../../../icons/customIcons/icons/AttentionFilled.js";import"../../../../icons/customIcons/icons/CheckOneFilled.js";import"../../../../icons/customIcons/icons/Archive.js";import"../../../../icons/customIcons/icons/ArchiveCancel.js";import"../../../../icons/customIcons/icons/Unarchive.js";import"../../../../icons/customIcons/icons/Archived.js";import"../../../../icons/customIcons/icons/InterventionUnit.js";import"../../../../icons/customIcons/icons/Lasso.js";import{jsxs as I,jsx as v}from"react/jsx-runtime";var g=["title"];function O(e,s){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);s&&(o=o.filter((function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable}))),i.push.apply(i,o)}return i}function S(e){for(var i=1;i<arguments.length;i++){var o=null!=arguments[i]?arguments[i]:{};i%2?O(Object(o),!0).forEach((function(i){s(e,i,o[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(o)):O(Object(o)).forEach((function(s){Object.defineProperty(e,s,Object.getOwnPropertyDescriptor(o,s))}))}return e}var w="OffsetWellsTableHead",N=function(e){var s=e.title,o=i(e,g);return v(d,{placement:"top-end",title:s,children:v(u,S({},o))})};function R(e,s){var i=e.find((function(e){return e.key===s}));return(null==i?void 0:i.width)||0}var W=function(i){var o,n=i.open,u=i.columnsWithDict,g=i.metricsKeys,O=i.sortBy,S=i.sortDirection,W=i.indeterminate,q=i.isAllWellsSelected,k=i.onChangeSort,A=i.onChangeMetricsKeys,E=i.onUpdateMetricsKey,D=i.isWellNameExpand,P=i.setIsWellNameExpand,x=i.handleChangeAllOffsetWells,F=i.wellNameStyle,L=i.isViewOnly,M=i.isImperial,T=i.contentRef,_=i.viewType,K=i.isTaColumnVisible,V=t(!1),U=e(V,2),z=U[0],G=U[1],H=null==u?void 0:u.some((function(e){return e.key===p.company})),B=function(e){k(e,e===O&&S===r.ASC?r.DESC:r.ASC)};return I(a,{className:b.tableRow,children:[I(l,{"data-testid":"".concat(w,"_wellName"),className:c(b.headCell,b.wellNameCell,(o={},s(o,F,_!==h.mobile),s(o,b.wellNameCellMobile,_===h.mobile),o)),style:{width:D?f:R(u,p.name)},children:[I("div",{className:b.nameWrapper,children:[!L&&n&&v(m,{"data-testid":"".concat(w,"_allWellsSelector"),size:"medium",onChange:function(e){return x(e.target.checked)},checked:q,indeterminate:W}),v(N,{title:"Sort",active:O===p.name,direction:O===p.name&&S===r.DESC?"desc":"asc",classes:{root:c(b.headerLabel,s({},b.cellDataViewOnly,L))},onClick:function(){return B(p.name)},children:"Well Name"})]}),v(d,{title:D?"Collapse":"Expand",children:v(C,{size:"small",className:c(b.wellNameExpandIcon,s({},b.wellNameCollapsed,!D)),onClick:function(){return P(!D)}})})]}),v(l,{"data-testid":"".concat(w,"_nameExpander_").concat(D),className:b.headCell,style:{width:R(u,p.status)}}),H&&v(l,{"data-testid":"".concat(w,"_company"),className:b.headCell,style:{width:R(u,p.company)},children:v("div",{className:b.nameWrapper,children:v(N,{title:"Sort",active:O===p.company,direction:O===p.company&&S===r.DESC?"desc":"asc",classes:{root:b.headerLabel},onClick:function(){return B(p.company)},children:"Company"})})}),v(l,{"data-testid":"".concat(w,"_rig"),className:b.headCell,style:{width:R(u,p.rig)},children:v("div",{className:b.nameWrapper,children:v(N,{title:"Sort",active:O===p.rig,direction:O===p.rig&&S===r.DESC?"desc":"asc",classes:{root:b.headerLabel},onClick:function(){return B(p.rig)},children:"Rig"})})}),v(l,{"data-testid":"".concat(w,"_distance"),className:b.headCell,style:{width:R(u,p.distance)},children:v("div",{className:b.nameWrapper,children:v(N,{title:"Sort",active:O===p.distance,direction:O===p.distance&&S===r.DESC?"desc":"asc",classes:{root:b.headerLabel},onClick:function(){return B(p.distance)},children:"Distance (".concat(M?"miles":"km",")")})})}),K&&v(l,{"data-testid":"".concat(w,"_ta"),className:b.headCell,style:{width:R(u,p.taScore)},children:v("div",{className:b.nameWrapper,children:"TA %"})}),v(l,{"data-testid":"".concat(w,"_LastActive"),className:b.headCell,style:{width:R(u,p.lastActive)},children:v("div",{className:b.nameWrapper,children:v(N,{title:"Sort",active:O===p.lastActive,direction:O===p.lastActive&&S===r.DESC?"desc":"asc",classes:{root:b.headerLabel},onClick:function(){return B(p.lastActive)},children:"Last Active"})})}),g.map((function(e){return v(l,{"data-testid":"".concat(w,"_").concat(e),className:b.headCell,style:{width:R(u,e)},children:v(N,{title:z?"":"Sort",active:O===e,direction:O===e&&S===r.DESC?"desc":"asc",classes:{root:b.headerLabel},onClick:function(){return B(e)},children:v(y,{isTooltipVisible:g.length>1,currentValue:e,metricsKeys:g,onChange:function(s){return E(e,s)},setIsMenuOpen:G})})},e)})),v(l,{"data-testid":"".concat(w,"_WellSection"),className:b.headCell,style:{width:R(u,p.wellSection)},children:I("div",{className:b.settingsHeader,children:[v("span",{className:b.headerLabel,children:"Well Section"}),v(j,{viewType:_,metricsKeys:g,onChange:A,contentRef:T})]})})]})};W.propTypes={open:n.bool.isRequired,columnsWithDict:n.arrayOf(n.shape({key:n.string,label:n.string,type:n.string,width:n.number})).isRequired,metricsKeys:n.arrayOf(n.string).isRequired,sortBy:n.string.isRequired,sortDirection:n.string.isRequired,indeterminate:n.bool.isRequired,isAllWellsSelected:n.bool.isRequired,style:n.shape({}).isRequired,onChangeSort:n.func.isRequired,onChangeMetricsKeys:n.func.isRequired,onUpdateMetricsKey:n.func.isRequired,isWellNameExpand:n.bool.isRequired,setIsWellNameExpand:n.func.isRequired,handleChangeAllOffsetWells:n.func.isRequired,wellNameStyle:n.string.isRequired,isViewOnly:n.bool.isRequired,isImperial:n.bool.isRequired,contentRef:n.shape({current:n.instanceOf(Element)}).isRequired,viewType:n.string.isRequired,isTaColumnVisible:n.bool.isRequired};var q=o(W);export{q as default};
|
|
2
|
-
//# sourceMappingURL=OffsetWellsTableHead.js.map
|
package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"OffsetWellsTableHead.js","sources":["../../../../../src/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.js"],"sourcesContent":["import { memo, useState } from 'react';\nimport classNames from 'classnames';\nimport PropTypes from 'prop-types';\nimport { SortDirection } from 'react-virtualized';\nimport {\n Checkbox,\n Tooltip,\n TableSortLabel as MuiTableSortLabel,\n TableCell,\n TableRow,\n} from '@material-ui/core';\n\nimport { ColumnType, EXPANDED_WELL_NAME_WIDTH, ViewType } from '../../constants';\n\nimport { MetricsSettingMenu } from './MetricsSettingMenu';\nimport { MetricsSelect } from './MetricsSelect';\n\nimport styles from './OffsetWellsTableHead.module.css';\n\nimport { RightIcon } from '~/icons';\n\nconst PAGE_NAME = 'OffsetWellsTableHead';\n\nconst TableSortLabel = ({ title, ...props }) => (\n <Tooltip placement=\"top-end\" title={title}>\n <MuiTableSortLabel {...props} />\n </Tooltip>\n);\n\nfunction getCellWidth(columnsWithDict, key) {\n const cell = columnsWithDict.find(item => item.key === key);\n return cell?.width || 0;\n}\n\nconst OffsetWellsTableHead = ({\n open,\n columnsWithDict,\n metricsKeys,\n sortBy,\n sortDirection,\n indeterminate,\n isAllWellsSelected,\n onChangeSort,\n onChangeMetricsKeys,\n onUpdateMetricsKey,\n isWellNameExpand,\n setIsWellNameExpand,\n handleChangeAllOffsetWells,\n wellNameStyle,\n isViewOnly,\n isImperial,\n contentRef,\n viewType,\n isTaColumnVisible,\n}) => {\n const [isMetricsMenuOpen, setIsMetricsMenuOpen] = useState(false);\n const hasCompanyColumn = columnsWithDict?.some(col => col.key === ColumnType.company);\n\n const handleSort = key => {\n onChangeSort(\n key,\n key === sortBy && sortDirection === SortDirection.ASC ? SortDirection.DESC : SortDirection.ASC\n );\n };\n\n return (\n <TableRow className={styles.tableRow}>\n <TableCell\n data-testid={`${PAGE_NAME}_wellName`}\n className={classNames(styles.headCell, styles.wellNameCell, {\n [wellNameStyle]: viewType !== ViewType.mobile,\n [styles.wellNameCellMobile]: viewType === ViewType.mobile,\n })}\n style={{\n width: isWellNameExpand\n ? EXPANDED_WELL_NAME_WIDTH\n : getCellWidth(columnsWithDict, ColumnType.name),\n }}\n >\n <div className={styles.nameWrapper}>\n {!isViewOnly && open && (\n <Checkbox\n data-testid={`${PAGE_NAME}_allWellsSelector`}\n size=\"medium\"\n onChange={event => handleChangeAllOffsetWells(event.target.checked)}\n checked={isAllWellsSelected}\n indeterminate={indeterminate}\n />\n )}\n <TableSortLabel\n title=\"Sort\"\n active={sortBy === ColumnType.name}\n direction={\n sortBy === ColumnType.name && sortDirection === SortDirection.DESC ? 'desc' : 'asc'\n }\n classes={{\n root: classNames(styles.headerLabel, {\n [styles.cellDataViewOnly]: isViewOnly,\n }),\n }}\n onClick={() => handleSort(ColumnType.name)}\n >\n Well Name\n </TableSortLabel>\n </div>\n <Tooltip title={isWellNameExpand ? 'Collapse' : 'Expand'}>\n <RightIcon\n size=\"small\"\n className={classNames(styles.wellNameExpandIcon, {\n [styles.wellNameCollapsed]: !isWellNameExpand,\n })}\n onClick={() => setIsWellNameExpand(!isWellNameExpand)}\n />\n </Tooltip>\n </TableCell>\n\n <TableCell\n data-testid={`${PAGE_NAME}_nameExpander_${isWellNameExpand}`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.status) }}\n />\n\n {hasCompanyColumn && (\n <TableCell\n data-testid={`${PAGE_NAME}_company`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.company) }}\n >\n <div className={styles.nameWrapper}>\n <TableSortLabel\n title=\"Sort\"\n active={sortBy === ColumnType.company}\n direction={\n sortBy === ColumnType.company && sortDirection === SortDirection.DESC\n ? 'desc'\n : 'asc'\n }\n classes={{ root: styles.headerLabel }}\n onClick={() => handleSort(ColumnType.company)}\n >\n Company\n </TableSortLabel>\n </div>\n </TableCell>\n )}\n\n <TableCell\n data-testid={`${PAGE_NAME}_rig`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.rig) }}\n >\n <div className={styles.nameWrapper}>\n <TableSortLabel\n title=\"Sort\"\n active={sortBy === ColumnType.rig}\n direction={\n sortBy === ColumnType.rig && sortDirection === SortDirection.DESC ? 'desc' : 'asc'\n }\n classes={{ root: styles.headerLabel }}\n onClick={() => handleSort(ColumnType.rig)}\n >\n Rig\n </TableSortLabel>\n </div>\n </TableCell>\n\n <TableCell\n data-testid={`${PAGE_NAME}_distance`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.distance) }}\n >\n <div className={styles.nameWrapper}>\n <TableSortLabel\n title=\"Sort\"\n active={sortBy === ColumnType.distance}\n direction={\n sortBy === ColumnType.distance && sortDirection === SortDirection.DESC\n ? 'desc'\n : 'asc'\n }\n classes={{ root: styles.headerLabel }}\n onClick={() => handleSort(ColumnType.distance)}\n >\n {`Distance (${isImperial ? 'miles' : 'km'})`}\n </TableSortLabel>\n </div>\n </TableCell>\n {isTaColumnVisible && (\n <TableCell\n data-testid={`${PAGE_NAME}_ta`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.taScore) }}\n >\n <div className={styles.nameWrapper}>TA %</div>\n </TableCell>\n )}\n\n <TableCell\n data-testid={`${PAGE_NAME}_LastActive`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.lastActive) }}\n >\n <div className={styles.nameWrapper}>\n <TableSortLabel\n title=\"Sort\"\n active={sortBy === ColumnType.lastActive}\n direction={\n sortBy === ColumnType.lastActive && sortDirection === SortDirection.DESC\n ? 'desc'\n : 'asc'\n }\n classes={{ root: styles.headerLabel }}\n onClick={() => handleSort(ColumnType.lastActive)}\n >\n Last Active\n </TableSortLabel>\n </div>\n </TableCell>\n\n {metricsKeys.map(metricsKey => (\n <TableCell\n data-testid={`${PAGE_NAME}_${metricsKey}`}\n key={metricsKey}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, metricsKey) }}\n >\n <TableSortLabel\n title={isMetricsMenuOpen ? '' : 'Sort'}\n active={sortBy === metricsKey}\n direction={\n sortBy === metricsKey && sortDirection === SortDirection.DESC ? 'desc' : 'asc'\n }\n classes={{ root: styles.headerLabel }}\n onClick={() => handleSort(metricsKey)}\n >\n <MetricsSelect\n isTooltipVisible={metricsKeys.length > 1}\n currentValue={metricsKey}\n metricsKeys={metricsKeys}\n onChange={newValue => onUpdateMetricsKey(metricsKey, newValue)}\n setIsMenuOpen={setIsMetricsMenuOpen}\n />\n </TableSortLabel>\n </TableCell>\n ))}\n\n <TableCell\n data-testid={`${PAGE_NAME}_WellSection`}\n className={styles.headCell}\n style={{ width: getCellWidth(columnsWithDict, ColumnType.wellSection) }}\n >\n <div className={styles.settingsHeader}>\n <span className={styles.headerLabel}>Well Section</span>\n <MetricsSettingMenu\n viewType={viewType}\n metricsKeys={metricsKeys}\n onChange={onChangeMetricsKeys}\n contentRef={contentRef}\n />\n </div>\n </TableCell>\n </TableRow>\n );\n};\n\nOffsetWellsTableHead.propTypes = {\n open: PropTypes.bool.isRequired,\n columnsWithDict: PropTypes.arrayOf(\n PropTypes.shape({\n key: PropTypes.string,\n label: PropTypes.string,\n type: PropTypes.string,\n width: PropTypes.number,\n })\n ).isRequired,\n metricsKeys: PropTypes.arrayOf(PropTypes.string).isRequired,\n sortBy: PropTypes.string.isRequired,\n sortDirection: PropTypes.string.isRequired,\n indeterminate: PropTypes.bool.isRequired,\n isAllWellsSelected: PropTypes.bool.isRequired,\n style: PropTypes.shape({}).isRequired,\n onChangeSort: PropTypes.func.isRequired,\n onChangeMetricsKeys: PropTypes.func.isRequired,\n onUpdateMetricsKey: PropTypes.func.isRequired,\n isWellNameExpand: PropTypes.bool.isRequired,\n setIsWellNameExpand: PropTypes.func.isRequired,\n handleChangeAllOffsetWells: PropTypes.func.isRequired,\n wellNameStyle: PropTypes.string.isRequired,\n isViewOnly: PropTypes.bool.isRequired,\n isImperial: PropTypes.bool.isRequired,\n contentRef: PropTypes.shape({ current: PropTypes.instanceOf(Element) }).isRequired,\n viewType: PropTypes.string.isRequired,\n isTaColumnVisible: PropTypes.bool.isRequired,\n};\n\nexport default memo(OffsetWellsTableHead);\n"],"names":["PAGE_NAME","TableSortLabel","_ref","title","props","_objectWithoutProperties","_excluded","_jsx","Tooltip","placement","children","MuiTableSortLabel","_objectSpread","getCellWidth","columnsWithDict","key","cell","find","item","width","OffsetWellsTableHead","_ref2","_classNames","open","metricsKeys","sortBy","sortDirection","indeterminate","isAllWellsSelected","onChangeSort","onChangeMetricsKeys","onUpdateMetricsKey","isWellNameExpand","setIsWellNameExpand","handleChangeAllOffsetWells","wellNameStyle","isViewOnly","isImperial","contentRef","viewType","isTaColumnVisible","useState","_useState2","_slicedToArray","_useState","isMetricsMenuOpen","setIsMetricsMenuOpen","hasCompanyColumn","some","col","ColumnType","company","handleSort","SortDirection","ASC","DESC","_jsxs","TableRow","className","styles","tableRow","TableCell","concat","classNames","headCell","wellNameCell","ViewType","mobile","wellNameCellMobile","style","EXPANDED_WELL_NAME_WIDTH","name","nameWrapper","Checkbox","size","onChange","event","target","checked","active","direction","classes","root","headerLabel","_defineProperty","cellDataViewOnly","onClick","RightIcon","wellNameExpandIcon","wellNameCollapsed","status","rig","distance","taScore","lastActive","map","metricsKey","MetricsSelect","isTooltipVisible","length","currentValue","newValue","setIsMenuOpen","wellSection","settingsHeader","MetricsSettingMenu","propTypes","PropTypes","bool","isRequired","arrayOf","shape","string","label","type","number","func","current","instanceOf","Element","memo"],"mappings":"2pHAqBA,IAAMA,EAAY,uBAEZC,EAAiB,SAAHC,GAAA,IAAMC,IAAAA,MAAUC,EAAKC,EAAAH,EAAAI,GAAA,OACvCC,EAACC,EAAO,CAACC,UAAU,UAAUN,MAAOA,EAAMO,SACxCH,EAACI,EAAiBC,EAAA,CAAA,EAAKR,KACf,EAGZ,SAASS,EAAaC,EAAiBC,GACrC,IAAMC,EAAOF,EAAgBG,MAAK,SAAAC,GAAI,OAAIA,EAAKH,MAAQA,KACvD,OAAOC,eAAAA,EAAMG,QAAS,CACxB,CAEA,IAAMC,EAAuB,SAoBv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FrF,YAAamF,EAAUG,QAAQH,EAAUK,QAAQH,WACjDpF,OAAQkF,EAAUK,OAAOH,WACzBnF,cAAeiF,EAAUK,OAAOH,WAChClF,cAAegF,EAAUC,KAAKC,WAC9BjF,mBAAoB+E,EAAUC,KAAKC,WACnCxC,MAAOsC,EAAUI,MAAM,CAAA,GAAIF,WAC3BhF,aAAc8E,EAAUS,KAAKP,WAC7B/E,oBAAqB6E,EAAUS,KAAKP,WACpC9E,mBAAoB4E,EAAUS,KAAKP,WACnC7E,iBAAkB2E,EAAUC,KAAKC,WACjC5E,oBAAqB0E,EAAUS,KAAKP,WACpC3E,2BAA4ByE,EAAUS,KAAKP,WAC3C1E,cAAewE,EAAUK,OAAOH,WAChCzE,WAAYuE,EAAUC,KAAKC,WAC3BxE,WAAYsE,EAAUC,KAAKC,WAC3BvE,WAAYqE,EAAUI,MAAM,CAAEM,QAASV,EAAUW,WAAWC,WAAYV,WACxEtE,SAAUoE,EAAUK,OAAOH,WAC3BrE,kBAAmBmE,EAAUC,KAAKC,YAGpC,IAAeW,EAAAA,EAAKpG"}
|
package/components/OffsetWellPickerV4/components/OffsetWellsTable/OffsetWellsTableHead.module.css.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from'./../../../../ext-esm/style-inject/dist/style-inject.es.js';var l={tableRow:"OffsetWellsTableHead-module_tableRow__Gvgyt",headCell:"OffsetWellsTableHead-module_headCell__hMcRS",wellNameCell:"OffsetWellsTableHead-module_wellNameCell__yllCT",wellNameCellMobile:"OffsetWellsTableHead-module_wellNameCellMobile__YJOV0",cellDataViewOnly:"OffsetWellsTableHead-module_cellDataViewOnly__dIoPu",nameWrapper:"OffsetWellsTableHead-module_nameWrapper__04GFY",headerLabel:"OffsetWellsTableHead-module_headerLabel__mOgMy",wellNameExpandIcon:"OffsetWellsTableHead-module_wellNameExpandIcon__-7Ioi",hiddenExpandIcon:"OffsetWellsTableHead-module_hiddenExpandIcon__W8MtT",wellNameCollapsed:"OffsetWellsTableHead-module_wellNameCollapsed__rVOqN",settingsHeader:"OffsetWellsTableHead-module_settingsHeader__2bsE7",popperContent:"OffsetWellsTableHead-module_popperContent__Y5aQg",popperButtonWrapper:"OffsetWellsTableHead-module_popperButtonWrapper__LO3RD",popperButton:"OffsetWellsTableHead-module_popperButton__pdIMG"};e(".OffsetWellsTableHead-module_tableRow__Gvgyt{display:flex!important;flex-direction:row!important}.OffsetWellsTableHead-module_headCell__hMcRS{align-items:center!important;background-color:#333;display:flex!important;height:48px!important;padding:0 12px 0 0!important}.OffsetWellsTableHead-module_wellNameCell__yllCT{align-items:center;display:flex!important;justify-content:space-between;left:0;padding-right:2px!important;position:sticky;z-index:9}.OffsetWellsTableHead-module_wellNameCellMobile__YJOV0{position:static}.OffsetWellsTableHead-module_cellDataViewOnly__dIoPu{padding-left:12px!important}.OffsetWellsTableHead-module_nameWrapper__04GFY{align-items:center;display:flex}.OffsetWellsTableHead-module_headerLabel__mOgMy{color:var(--palette-primary-text-7)!important;display:flex!important;font-size:12px;font-weight:500;justify-content:flex-start!important;letter-spacing:.4px;line-height:14px;user-select:none;white-space:normal;width:100%}.OffsetWellsTableHead-module_headerLabel__mOgMy:hover{color:var(--palette-primary-text-1)!important}.OffsetWellsTableHead-module_wellNameExpandIcon__-7Ioi{color:var(--palette-primary-text-6)!important;cursor:pointer;font-size:10px!important;height:32px!important;padding:6px;transform:rotate(180deg);width:32px!important}.OffsetWellsTableHead-module_wellNameExpandIcon__-7Ioi:hover{color:var(--palette-primary-text-1)!important}.OffsetWellsTableHead-module_hiddenExpandIcon__W8MtT{display:none!important}.OffsetWellsTableHead-module_wellNameCollapsed__rVOqN{transform:rotate(0deg)}.OffsetWellsTableHead-module_settingsHeader__2bsE7{align-items:center;display:flex;flex:1;justify-content:space-between}.OffsetWellsTableHead-module_popperContent__Y5aQg{display:flex;flex-direction:column;font-size:18px!important;gap:8px;line-height:24px!important}.OffsetWellsTableHead-module_popperButtonWrapper__LO3RD{display:flex;justify-content:flex-end}.OffsetWellsTableHead-module_popperButton__pdIMG{background:hsla(0,0%,100%,.24)!important;color:#fff!important;padding:4px!important;width:71px!important}.OffsetWellsTableHead-module_popperButton__pdIMG:hover{background:hsla(0,0%,100%,.08)!important}");export{l as default};
|
|
2
|
-
//# sourceMappingURL=OffsetWellsTableHead.module.css.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":null,"sources":[null],"sourcesContent":[null],"names":[],"mappings":"AAAA,aAAa,4DAA+D;"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import e from"@babel/runtime/helpers/slicedToArray";import t from"@babel/runtime/helpers/defineProperty";import{memo as l,useState as i,useCallback as a,useEffect as s,useMemo as n}from"react";import r from"prop-types";import{startCase as o,get as c}from"lodash";import d from"classnames";import m from"moment";import{TableRow as u,TableCell as h,Tooltip as f,Checkbox as y,Typography as b}from"@material-ui/core";import{ColumnType as p,ViewType as v,EXPANDED_WELL_NAME_WIDTH as N,LEAVE_TOUCH_DELAY as w,StatusOptions as W}from"../../constants.js";import{SubjectWellMark as g}from"./SubjectWellMark.js";import R from"./ViewWellSectionsName.js";import C from"./OffsetWellsTableRow.module.css.js";import{convertValue as k}from"../../../../utils/index.js";import{jsxs as q,jsx as O}from"react/jsx-runtime";var S="OffsetWellsTableRow";function D(e,t,l){var i=t.find((function(e){return e.key===l})),a=c(e,i.key);return"undefined"===a?"loading...":Number.isFinite(a)||a&&"Null"!==a?i.unitType?k(a,i.unitType,i.from,i.to):a:"—"}function T(e,t){var l=c(e,p.distance);return Number.isFinite(l)?t?l:k(l,"length","mi","km"):"—"}function _(e,t){var l,i=e.find((function(e){return e.wellId===t.id}));return null!==(l=null==i?void 0:i.taScore)&&void 0!==l?l:""}function j(e,t){var l=e.find((function(e){return e.key===t}));return(null==l?void 0:l.width)||0}var x=function(l){var r,c,k,x=l.columnsWithDict,A=l.data,M=l.subjectWellId,I=l.metricsKeys,L=l.metricsColumns,V=l.handleChangeOffsetWell,E=l.isWellNameExpand,F=l.wellNameStyle,Y=l.wellNameWidth,P=l.isViewOnly,z=l.isImperial,H=l.isLimitedOffsetWells,K=l.maxOffsetWellNumber,U=l.wellSections,B=l.setActiveWellId,G=l.viewType,J=l.isWDUser,Q=l.taScores,X=l.offsetWellsContainerRef,Z=M===A.id,$=t({},C.subjectWellRow,Z),ee=i(A.checked),te=e(ee,2),le=te[0],ie=te[1],ae=!1,se=A[p.name]||"—",ne=se;if(!E&&2*Y<8*se.length){var re=function(e){var t=document.createElement("span");document.body.appendChild(t),t.style.font="Roboto",t.style.fontSize="14px",t.style.letterSpacing="0.01071em",t.style.height="auto",t.style.width="auto",t.style.position="absolute",t.style.whiteSpace="nowrap",t.innerHTML=e;var l=Math.ceil(t.clientWidth);return document.body.removeChild(t),l}(se);if(re>2*Y){var oe=2*Y/(re/se.length);ne="".concat(se.substring(0,oe/2-2),"\n... ").concat(se.substring(se.length-oe/2+6)),ae=!0}}var ce=a((function(e){var t,l=(null===(t=X.current)||void 0===t?void 0:t.scrollTop)||0;V(A,e),ie(e),requestAnimationFrame((function(){X.current.scrollTop=l}))}),[A,V]);s((function(){ie(A.checked)}),[A.checked]);var de,me,ue=n((function(){return A[p.wellSection]}),[A]),he=n((function(){return P?"View only mode. To edit offsets, use ".concat(J?"Offset Selection App":"WellHub","."):H&&!A.checked?"App can’t process more than (".concat(K-1,") Offset Wells."):""}),[P,H,A.checked]);return q(u,{"data-testid":"".concat(S,"_row_").concat(se),className:C.bodyRow,onMouseEnter:function(){B(A.id)},onMouseLeave:function(){B(null)},children:[q(h,{"data-testid":"".concat(S,"_well"),className:d(C.bodyCell,C.wellNameCell,$,(r={},t(r,F,G!==v.mobile),t(r,C.wellNameCellMobile,G===v.mobile),r)),style:{width:E?N:j(x,p.name)},children:[Z&&O(g,{className:d(C.subjectWellMark,t({},C.subjectWellMarkMobile,G===v.mobile))}),!Z&&O(f,{title:he,placement:"bottom-start",classes:{tooltipPlacementBottom:C.checkboxTooltip},children:O("div",{children:O(y,{"data-testid":"".concat(S,"_checkbox"),size:"medium",checked:le,classes:{disabled:C.checkboxDisabled},disabled:P||H&&!A.checked,onChange:function(e){return ce(e.target.checked)}})})}),O(f,{title:ae?se:"",children:O(b,{variant:"body2",className:d(C.wellNameCursor,(c={},t(c,C.cellDataViewOnly,Z),t(c,C.wellNamePreWrap,ae),c)),children:ae?ne:se})})]}),O(h,{"data-testid":"".concat(S,"_dot"),className:d(C.bodyCell,$),style:{width:j(x,p.status)},children:!Z&&O(f,{title:o(A[p.status]),enterTouchDelay:G===v.mobile&&0,leaveTouchDelay:G===v.mobile&&w,children:O("div",{className:C.statusContainer,children:O("div",{"data-testid":"".concat(S,"_color"),className:C.status,style:{background:null===(k=W.find((function(e){return e.value===A[p.status]})))||void 0===k?void 0:k.color}})})})}),O(h,{"data-testid":"".concat(S,"_company"),className:d(C.bodyCell,$),style:{width:j(x,p.company)},children:O(b,{variant:"body2",className:C.cellData,children:A[p.company]&&"Null"!==A[p.company]?A[p.company]:"—"})}),O(h,{"data-testid":"".concat(S,"_rig"),className:d(C.bodyCell,$),style:{width:j(x,p.rig)},children:O(b,{variant:"body2",className:C.cellData,children:A[p.rig]&&"Null"!==A[p.rig]?A[p.rig]:"—"})}),O(h,{"data-testid":"".concat(S,"_distance"),className:d(C.bodyCell,$),style:{width:j(x,p.distance)},children:O(b,{variant:"body2",className:C.cellData,children:T(A,z)})}),!!Q.length&&O(h,{"data-testid":"".concat(S,"_ta"),className:d(C.bodyCell,$),style:{width:j(x,p.taScore)},children:O(b,{variant:"body2",className:C.cellData,children:_(Q,A)})}),O(h,{"data-testid":"".concat(S,"_lastActive"),className:d(C.bodyCell,$),style:{width:j(x,p.lastActive)},children:O(b,{variant:"body2",className:C.cellData,children:A[p.lastActive]&&Number.isFinite(A[p.lastActive])?m.unix(A[p.lastActive]).format("MM/DD/YYYY"):"—"})}),I.map((function(e){return O(h,{"data-testid":"".concat(S,"_").concat(e),className:d(C.bodyCell,$),style:{width:j(x,e)},children:O(b,{variant:"body2",className:C.cellData,children:D(A,L,e)})},e)})),O(h,{"data-testid":"".concat(S,"_wellSection"),className:d(C.bodyCell,C.lastCell,$),style:{width:j(x,p.wellSection)},children:ue&&ue.length>1?O(f,{classes:{tooltip:C.customTooltip},title:O(R,{wellSectionNames:ue}),children:O("div",{className:C.sectionLength,children:ue.length})}):O(f,{title:ue||"",children:O(b,{variant:"body2",className:C.cellData,style:{color:ue&&1===ue.length&&(de=ue,me=e(de,1)[0],U.find((function(e){return e.label===me})).color)},children:ue})})})]})};x.propTypes={columnsWithDict:r.arrayOf(r.shape({})).isRequired,data:r.shape({id:r.number,checked:r.bool,name:r.string,status:r.string}).isRequired,subjectWellId:r.number.isRequired,metricsKeys:r.arrayOf(r.string).isRequired,metricsColumns:r.arrayOf(r.shape({})).isRequired,handleChangeOffsetWell:r.func.isRequired,isWellNameExpand:r.bool.isRequired,wellNameStyle:r.string.isRequired,wellNameWidth:r.number.isRequired,isViewOnly:r.bool.isRequired,isImperial:r.bool.isRequired,isLimitedOffsetWells:r.bool.isRequired,maxOffsetWellNumber:r.number.isRequired,wellSections:r.arrayOf(r.shape({})).isRequired,setActiveWellId:r.func.isRequired,viewType:r.string.isRequired,isWDUser:r.bool.isRequired,taScores:r.arrayOf(r.shape({})).isRequired,offsetWellsContainerRef:r.shape({}).isRequired};var A=l(x);export{A as default};
|
|
2
|
-
//# sourceMappingURL=OffsetWellsTableRow.js.map
|