"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("lodash"),t=require("../../../types/shared/Completions.js"),i=require("../../../utils/completion.js"),s=require("../../../constants/completion.js"),o=require("./selectMenuKey.js");exports.getActiveAsset=function(o){var d=o.assets,l=o.padModeSetting,n=o.completionAppType;return(null==l?void 0:l.mode)===t.PadMode.padLine?null:(n===s.COMPLETION_APP_TYPES.wirelineMultiWellApp?i.resolveActiveWirelineAsset:i.resolveActiveFracAsset)(d)||e.first(d)},exports.getSelectValue=function(i){var s,d=i.fracFleetLines,l=i.padModeSetting,n=i.enableSimulFracInPadSelect,r=l.mode;if(l.mode===t.PadMode.custom)r=o.getMenuItemKey(t.PadMode.custom,null!==(s=e.first(l.selectedAssets))&&void 0!==s?s:"");else if(n){var u,a,c=(null===(u=d.find((function(e){return e.id===l.selectedLine})))||void 0===u?void 0:u.id)||(null===(a=d[0])||void 0===a?void 0:a.id);r=d.length?o.getMenuItemKey(t.PadMode.padLine,c):t.PadMode.pad}return r};
//# sourceMappingURL=resolveCurrentConfig.js.map
