// Licensed Materials - Property of IBM // IBM Cognos Products: rs // (C) Copyright IBM Corp. 2003, 2022. // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. define(["text!reportstyles/palettes.json"],function(_myc){var _5ia=JSON.parse(_myc)['ColorPalette'].map(function(_ial){var _dwm=_ial.label&&_ial.label!='unused'?_frh._c6j(_ial.label):null;return {id: _ial.id,systemPalette: true,content: {fills: _ial.fills,fillType: _ial.fillType,label: _dwm||_ial.id}};});function _mcb(){this._kjj=null;};_mcb._03g=function(_2xa){this._l2f=_2xa.paletteType;var _0um=Q.defer();_2xa.glassContext.getSvc('.Palette').then(function(service){return service.getPalettes(_2xa.paletteType).then(function(response){response.system=_5ia.filter(function(_ial){return _2xa.paletteType==null||_ial.content.fillType==_2xa.paletteType;});var _hyb=_2xa.paletteIds.filter(function(_d0j){var _stj=function(_ial){ return _ial.id==_d0j; };var _xpj=_5ia.filter(_stj).length>0;var _jpj=response['my'].filter(_stj).length>0;var _opj=response['public'].filter(_stj).length>0;return !_xpj&&!_jpj&&!_opj; });if(_hyb.length==0){_0um.resolve(response);}else{_hyb=_hyb.filter(function(_ial,_5qm){ return _hyb.indexOf(_ial)==_5qm; });response.local=[];Q.allSettled(_hyb.map(function(_d0j){ return service.getPalette(_d0j);})).then(function(_jvk){for(var i=0;i<_jvk.length;i++){if(_jvk[i].state==="fulfilled"&&(_2xa.paletteType==null||_jvk[i].value.content.fillType==_2xa.paletteType)){response.local.push(_jvk[i].value);}}_0um.resolve(response);});}});});return _0um.promise;};_mcb._jg8=function(_2xa){return _mcb._03g(_2xa).then(function(response){var _y5m={};["system", "my", "public", "local"].forEach(function(_pen){if(response[_pen]){for(var i=0;i