UNPKG

record-editor

Version:

Editor (used in inspirehep.net) for JSON documents with bibliographic metadata

2 lines 35.6 kB
webpackJsonp([4],{0:function(e,t,n){e.exports=n("cDNt")},"0Pg/":function(e,t,n){"use strict";n.d(t,"a",function(){return o});var r=n("TO51"),i=n("5q5V"),a=n("Pwb5"),o=function(){function e(){var e=this;this.jsonBeingEdited$=new i.a(1),this.pidValueBeingEdited$=this.jsonBeingEdited$.map(function(e){return e.control_number||e.metadata.control_number}).distinctUntilChanged(),this.pidTypeBeingEdited$=this.jsonBeingEdited$.map(function(e){var t=e.$schema||e.metadata.$schema,n=Object(a.a)(t);return"hep"===n?"literature":n}).distinctUntilChanged(),this.isJsonUpdated$=new r.a,this.validationProblems$=new r.a,this.hasAnyValidationProblem$=this.validationProblems$.map(function(t){return e.hasAnyValidationProblem(t)})}return e.prototype.hasAnyValidationProblem=function(e){return Object.keys(e).some(function(t){return e[t].length>0})},e}()},"2FwN":function(e,t,n){"use strict";var r={aa:"Afar",ab:"Abkhaz",ae:"Avestan",af:"Afrikaans",ak:"Akan",am:"Amharic",an:"Aragonese",ar:"Arabic",as:"Assamese",av:"Avaric",ay:"Aymara",az:"Azerbaijani",ba:"Bashkir",be:"Belarusian",bg:"Bulgarian",bh:"Bihari",bi:"Bislama",bm:"Bambara",bn:"Bengali",bo:"Tibetan Standard",br:"Breton",bs:"Bosnian",ca:"Catalan",ce:"Chechen",ch:"Chamorro",co:"Corsican",cr:"Cree",cs:"Czech",cu:"Old Church Slavonic",cv:"Chuvash",cy:"Welsh",da:"Danish",de:"German",dv:"Divehi",dz:"Dzongkha",ee:"Ewe",el:"Greek",en:"English",eo:"Esperanto",es:"Spanish",et:"Estonian",eu:"Basque",fa:"Persian",ff:"Fula",fi:"Finnish",fj:"Fijian",fo:"Faroese",fr:"French",fy:"Western Frisian",ga:"Irish",gd:"Scottish Gaelic",gl:"Galician",gn:"Guaran\xed",gu:"Gujarati",gv:"Manx",ha:"Hausa",he:"Hebrew",hi:"Hindi",ho:"Hiri Motu",hr:"Croatian",ht:"Haitian",hu:"Hungarian",hy:"Armenian",hz:"Herero",ia:"Interlingua",id:"Indonesian",ie:"Interlingue",ig:"Igbo",ii:"Nuosu",ik:"Inupiaq",io:"Ido",is:"Icelandic",it:"Italian",iu:"Inuktitut",ja:"Japanese",jv:"Javanese",ka:"Georgian",kg:"Kongo",ki:"Kikuyu",kj:"Kwanyama",kk:"Kazakh",kl:"Kalaallisut",km:"Khmer",kn:"Kannada",ko:"Korean",kr:"Kanuri",ks:"Kashmiri",ku:"Kurdish",kv:"Komi",kw:"Cornish",ky:"Kyrgyz",la:"Latin",lb:"Luxembourgish",lg:"Ganda",li:"Limburgish",ln:"Lingala",lo:"Lao",lt:"Lithuanian",lu:"Luba-Katanga",lv:"Latvian",mg:"Malagasy",mh:"Marshallese",mi:"M\u0101ori",mk:"Macedonian",ml:"Malayalam",mn:"Mongolian",mr:"Marathi",ms:"Malay",mt:"Maltese",my:"Burmese",na:"Nauru",nb:"Norwegian Bokm\xe5l",nd:"Northern Ndebele",ne:"Nepali",ng:"Ndonga",nl:"Dutch",nn:"Norwegian Nynorsk",no:"Norwegian",nr:"Southern Ndebele",nv:"Navajo",ny:"Chichewa",oc:"Occitan",oj:"Ojibwe",om:"Oromo",or:"Oriya",os:"Ossetian",pa:"Panjabi",pi:"P\u0101li",pl:"Polish",ps:"Pashto",pt:"Portuguese",qu:"Quechua",rm:"Romansh",rn:"Kirundi",ro:"Romanian",ru:"Russian",rw:"Kinyarwanda",sa:"Sanskrit",sc:"Sardinian",sd:"Sindhi",se:"Northern Sami",sg:"Sango",si:"Sinhala",sk:"Slovak",sl:"Slovene",sm:"Samoan",sn:"Shona",so:"Somali",sq:"Albanian",sr:"Serbian",ss:"Swati",st:"Southern Sotho",su:"Sundanese",sv:"Swedish",sw:"Swahili",ta:"Tamil",te:"Telugu",tg:"Tajik",th:"Thai",ti:"Tigrinya",tk:"Turkmen",tl:"Tagalog",tn:"Tswana",to:"Tonga",tr:"Turkish",ts:"Tsonga",tt:"Tatar",tw:"Twi",ty:"Tahitian",ug:"Uyghur",uk:"Ukrainian",ur:"Urdu",uz:"Uzbek",ve:"Venda",vi:"Vietnamese",vo:"Volap\xfck",wa:"Walloon",wo:"Wolof",xh:"Xhosa",yi:"Yiddish",yo:"Yoruba",za:"Zhuang",zh:"Chinese",zu:"Zulu"},i={AF:"Afghanistan",AX:"Aland Islands",AL:"Albania",DZ:"Algeria",AS:"American Samoa",AD:"Andorra",AO:"Angola",AI:"Anguilla",AQ:"Antarctica",AG:"Antigua And Barbuda",AR:"Argentina",AM:"Armenia",AW:"Aruba",AU:"Australia",AT:"Austria",AZ:"Azerbaijan",BS:"Bahamas",BH:"Bahrain",BD:"Bangladesh",BB:"Barbados",BY:"Belarus",BE:"Belgium",BZ:"Belize",BJ:"Benin",BM:"Bermuda",BT:"Bhutan",BO:"Bolivia",BA:"Bosnia And Herzegovina",BW:"Botswana",BV:"Bouvet Island",BR:"Brazil",IO:"British Indian Ocean Territory",BN:"Brunei Darussalam",BG:"Bulgaria",BF:"Burkina Faso",BI:"Burundi",KH:"Cambodia",CM:"Cameroon",CA:"Canada",CV:"Cape Verde",KY:"Cayman Islands",CF:"Central African Republic",TD:"Chad",CL:"Chile",CN:"China",CX:"Christmas Island",CC:"Cocos (Keeling) Islands",CO:"Colombia",KM:"Comoros",CG:"Congo",CD:"Congo, Democratic Republic",CK:"Cook Islands",CR:"Costa Rica",CI:"Cote D'Ivoire",HR:"Croatia",CU:"Cuba",CY:"Cyprus",CZ:"Czech Republic",DK:"Denmark",DJ:"Djibouti",DM:"Dominica",DO:"Dominican Republic",EC:"Ecuador",EG:"Egypt",SV:"El Salvador",GQ:"Equatorial Guinea",ER:"Eritrea",EE:"Estonia",ET:"Ethiopia",FK:"Falkland Islands (Malvinas)",FO:"Faroe Islands",FJ:"Fiji",FI:"Finland",FR:"France",GF:"French Guiana",PF:"French Polynesia",TF:"French Southern Territories",GA:"Gabon",GM:"Gambia",GE:"Georgia",DE:"Germany",GH:"Ghana",GI:"Gibraltar",GR:"Greece",GL:"Greenland",GD:"Grenada",GP:"Guadeloupe",GU:"Guam",GT:"Guatemala",GG:"Guernsey",GN:"Guinea",GW:"Guinea-Bissau",GY:"Guyana",HT:"Haiti",HM:"Heard Island & Mcdonald Islands",VA:"Holy See (Vatican City State)",HN:"Honduras",HK:"Hong Kong",HU:"Hungary",IS:"Iceland",IN:"India",ID:"Indonesia",IR:"Iran, Islamic Republic Of",IQ:"Iraq",IE:"Ireland",IM:"Isle Of Man",IL:"Israel",IT:"Italy",JM:"Jamaica",JP:"Japan",JE:"Jersey",JO:"Jordan",KZ:"Kazakhstan",KE:"Kenya",KI:"Kiribati",KR:"Korea",KW:"Kuwait",KG:"Kyrgyzstan",LA:"Lao People's Democratic Republic",LV:"Latvia",LB:"Lebanon",LS:"Lesotho",LR:"Liberia",LY:"Libyan Arab Jamahiriya",LI:"Liechtenstein",LT:"Lithuania",LU:"Luxembourg",MO:"Macao",MK:"Macedonia",MG:"Madagascar",MW:"Malawi",MY:"Malaysia",MV:"Maldives",ML:"Mali",MT:"Malta",MH:"Marshall Islands",MQ:"Martinique",MR:"Mauritania",MU:"Mauritius",YT:"Mayotte",MX:"Mexico",FM:"Micronesia, Federated States Of",MD:"Moldova",MC:"Monaco",MN:"Mongolia",ME:"Montenegro",MS:"Montserrat",MA:"Morocco",MZ:"Mozambique",MM:"Myanmar",NA:"Namibia",NR:"Nauru",NP:"Nepal",NL:"Netherlands",AN:"Netherlands Antilles",NC:"New Caledonia",NZ:"New Zealand",NI:"Nicaragua",NE:"Niger",NG:"Nigeria",NU:"Niue",NF:"Norfolk Island",MP:"Northern Mariana Islands",NO:"Norway",OM:"Oman",PK:"Pakistan",PW:"Palau",PS:"Palestinian Territory, Occupied",PA:"Panama",PG:"Papua New Guinea",PY:"Paraguay",PE:"Peru",PH:"Philippines",PN:"Pitcairn",PL:"Poland",PT:"Portugal",PR:"Puerto Rico",QA:"Qatar",RE:"Reunion",RO:"Romania",RU:"Russian Federation",RW:"Rwanda",BL:"Saint Barthelemy",SH:"Saint Helena",KN:"Saint Kitts And Nevis",LC:"Saint Lucia",MF:"Saint Martin",PM:"Saint Pierre And Miquelon",VC:"Saint Vincent And Grenadines",WS:"Samoa",SM:"San Marino",ST:"Sao Tome And Principe",SA:"Saudi Arabia",SN:"Senegal",RS:"Serbia",SC:"Seychelles",SL:"Sierra Leone",SG:"Singapore",SK:"Slovakia",SI:"Slovenia",SB:"Solomon Islands",SO:"Somalia",ZA:"South Africa",GS:"South Georgia And Sandwich Isl.",ES:"Spain",LK:"Sri Lanka",SD:"Sudan",SR:"Suriname",SJ:"Svalbard And Jan Mayen",SZ:"Swaziland",SE:"Sweden",CH:"Switzerland",SY:"Syrian Arab Republic",TW:"Taiwan",TJ:"Tajikistan",TZ:"Tanzania",TH:"Thailand",TL:"Timor-Leste",TG:"Togo",TK:"Tokelau",TO:"Tonga",TT:"Trinidad And Tobago",TN:"Tunisia",TR:"Turkey",TM:"Turkmenistan",TC:"Turks And Caicos Islands",TV:"Tuvalu",UG:"Uganda",UA:"Ukraine",AE:"United Arab Emirates",GB:"United Kingdom",US:"United States",UM:"United States Outlying Islands",UY:"Uruguay",UZ:"Uzbekistan",VU:"Vanuatu",VE:"Venezuela",VN:"Viet Nam",VG:"Virgin Islands, British",VI:"Virgin Islands, U.S.",WF:"Wallis And Futuna",EH:"Western Sahara",YE:"Yemen",ZM:"Zambia",ZW:"Zimbabwe"},a={t:["title","title"],j:["publication_info","journal_title"],d:["dois","-"],c:["collaborations","-"],i:["isbn"],k:["texkey"],o:["label"],u:["urls","-","value"],r:["report_numbers","-"],x:["arxiv_eprint"],v:["publication_info","journal_volume"],n:["publication_info","journal_issue"],y:["publication_info","year"],s:["publication_info","page_start"],e:["publication_info","page_end"],f:["publication_info","artid"],b:["publication_info","cnum"],p:["imprint","publisher"],a:["authors","-","full_name"],l:["authors","-","inspire_role"]},o={timeOut:0,extendedTimeOut:0,closeButton:!0,onActivateTick:!0},s={timeOut:0,onActivateTick:!0};n.d(t,"d",function(){return r}),n.d(t,"c",function(){return i}),n.d(t,"e",function(){return a}),n.d(t,"a",function(){return o}),n.d(t,"b",function(){return s})},"6jTL":function(e,t,n){"use strict";n.d(t,"a",function(){return r});var r=function(){function e(){}return e.prototype.cleanup=function(e){var t=this;if(Array.isArray(e))for(var n=e.length-1;n>=0;n--)"object"===typeof e[n]&&this.cleanup(e[n]),this.isEmpty(e[n])&&e.splice(n,1);else Object.keys(e).forEach(function(n){"object"===typeof e[n]&&t.cleanup(e[n]),t.isEmpty(e[n])&&delete e[n]})},e.prototype.isEmpty=function(e){if(void 0===e||null===e)return!0;var t=typeof e;return("string"===t||"object"===t)&&0===Object.keys(e).length},e}()},"7eGr":function(e,t,n){"use strict";n.d(t,"a",function(){return a});var r=n("5q5V"),i=n("bAhW"),a=function(){function e(e){this.apiService=e,this.resultCount$=new r.a(1),this.cursor$=new r.a(1)}return e.prototype.search=function(e,t){var n=this;return this.apiService.searchRecord(e,t).do(function(e){n.resultCount$.next(e.length),n.cursor$.next(0)})},e.prototype.setCursor=function(e){this.cursor$.next(e)},e.ctorParameters=function(){return[{type:i.a}]},e}()},DFJI:function(e,t,n){"use strict";var r=n("TO51"),i=function(){function e(){this.isDestroyed=new r.a}return e.prototype.ngOnDestroy=function(){this.isDestroyed.next(),this.isDestroyed.complete()},e}(),a=function(){function e(e,t){void 0===t&&(t=!0),this.status=e.status,this.body=t?e.json():Object.create(null)}return Object.defineProperty(e.prototype,"message",{get:function(){return this.body.message},enumerable:!0,configurable:!0}),e}();n.d(t,"b",function(){return i}),n.d(t,"a",function(){return a})},Pwb5:function(e,t,n){"use strict";t.a=function(e){var t=e.slice(e.lastIndexOf("/")+1,e.length);return t.slice(0,t.lastIndexOf("."))}},SajZ:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n("p5Ee"),i=function(){function e(){this.beforeUnloadHandler=function(e){return e.returnValue=!0,!0}}return e.prototype.fitEditorHeightFullPage=function(){var e=document.getElementById("editor-container"),t=(document.getElementById("editor-toolbar"),window.getComputedStyle(document.getElementById("editor-toolbar"),null).getPropertyValue("min-height"));e.style.height=window.innerHeight-parseInt(t,10)+"px"},e.prototype.fitEditorHeightFullPageOnResize=function(){var e=this;window.addEventListener("resize",function(){return e.fitEditorHeightFullPage()})},e.prototype.writeContentIntoIFrameById=function(e,t){var n=document.getElementById(t).contentWindow.document;n.open(),n.write(e),n.close()},e.prototype.registerBeforeUnloadPrompt=function(){r.a.production&&window.addEventListener("beforeunload",this.beforeUnloadHandler)},e.prototype.unregisterBeforeUnloadPrompt=function(){r.a.production&&window.removeEventListener("beforeunload",this.beforeUnloadHandler)},e.prototype.openHostRelativeUrlInNewTab=function(e){window.open(r.a.baseUrl+"/"+e,"_blank").focus()},e}()},V0P1:function(e,t,n){"use strict";n.d(t,"a",function(){return s});var r=n("AP4T"),i=n("XZoy"),a=n("vMga"),o=n("Pwb5"),s=function(){function e(){var e=this;this.configsByType=i.c,this.onConfigChange=r.a.from(a.e).map(function(t){return e.configsByType[t]||e.configsByType.hep})}return e.prototype.getConfigForRecord=function(e){var t=this.getRecordType(e);return"hep"===t?this.getConfigForHepRecord(e):this.configsByType[t]},e.prototype.getRecordType=function(e){var t=e.$schema;return Object(o.a)(t)},e.prototype.getConfigForHepRecord=function(e){if(e.document_type){var t=this.getHepType(e.document_type);if(t)return this.configsByType[t]}return this.configsByType.hep},e.prototype.getHepType=function(e){var t=this;return e.find(function(e){return void 0!==t.configsByType[e]})},e}()},XZoy:function(e,t,n){"use strict";var r=n("vMga"),i=n("qtzZ"),a={customFormatValidation:i.c},o=n("p5Ee"),s=n("2FwN"),u={customFormatValidation:i.c,menuMaxDepth:1,enableAdminModeSwitch:!0,schemaOptions:{alwaysShowRegExp:new RegExp("value"),alwaysShow:["titles","acronyms","addresses","cnum","opening_date","closing_date","series","urls","contact_details","short_description","public_notes","_private_notes","alternative_titles","inspire_categories","keywords","deleted"],order:["titles","acronyms","addresses","cnum","opening_date","closing_date","series","urls","contact_details","short_description","public_notes","_private_notes","alternative_titles","inspire_categories","keywords","core","deleted"],properties:{core:{toggleColor:"#27ae60"},deleted:{toggleColor:"#e74c3c"},titles:{items:{alwaysShow:["title"],order:["title","subtitle","source"]}},series:{items:{alwaysShow:["name"],order:["name","number"],properties:{name:{autocompletionConfig:{url:o.a.baseUrl+"/api/conferences/_suggest?series_name=",path:"/series_name/0/options",optionField:"/text",size:10}}}}},inspire_categories:{items:{alwaysShow:["term"],order:["term"]}},addresses:{items:{order:["cities","country_code","place_name","state"],properties:{country_code:{enumDisplayValueMap:s.c},postal_code:{hidden:!0},postal_address:{hidden:!0},longitude:{hidden:!0},latitude:{hidden:!0}}}},urls:{items:{order:["value","description"]}},contact_details:{items:{order:["email","name","curated_relation","hidden"]}},short_description:{order:["value"]},public_notes:{items:{order:["value"]}},_private_notes:{items:{order:["value"]}},alternative_titles:{items:{alwaysShow:["title"],order:["title","subtitle","source"]}},keywords:{items:{order:["value","schema"]}},cnum:{disabled:!0},$schema:{hidden:!0},self:{hidden:!0},control_number:{hidden:!0},external_system_identifiers:{hidden:!0},legacy_creation_date:{hidden:!0},legacy_version:{hidden:!0},new_record:{hidden:!0},deleted_record:{hidden:!0}}}},l=o.a.baseUrl+"/api",c=l+"/editor",d=l+"/holdingpen";n.d(t,"c",function(){return p}),n.d(t,"a",function(){return l}),n.d(t,"b",function(){return c}),n.d(t,"d",function(){return d});var p={hep:r.d,thesis:r.g,book:r.a,"book chapter":r.b,proceedings:r.f,"conference paper":r.c,authors:a,conferences:u}},bAhW:function(e,t,n){"use strict";n.d(t,"a",function(){return p});var r,i=n("CPp0"),a=n("5q5V"),o=n("AP4T"),s=n("p5Ee"),u=n("sWh4"),l=n("DFJI"),c=n("XZoy"),d=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),p=function(e){function t(t){var n=e.call(this,t)||this;return n.http=t,n.returnOnlyIdsHeaders=new i.d({Accept:"application/vnd+inspire.ids+json"}),n.newRecordFetched$=new a.a(1),n}return d(t,e),t.prototype.checkEditorPermission=function(e,t){return this.currentRecordEditorApiUrl=c.b+"/"+e+"/"+t,this.http.get(this.currentRecordEditorApiUrl+"/permission").toPromise()},t.prototype.fetchRecord=function(e,t){return this.currentRecordId=t,this.currentRecordApiUrl=c.a+"/"+e+"/"+t,this.currentRecordEditorApiUrl=c.b+"/"+e+"/"+t,this.newRecordFetched$.next(null),this.fetchUrl(this.currentRecordApiUrl)},t.prototype.saveRecord=function(e){return this.http.put(this.currentRecordApiUrl,e).catch(function(e){return o.a.throw(new l.a(e))})},t.prototype.searchRecord=function(e,t){return this.http.get(c.a+"/"+e+"/?q="+t+"&size=200",{headers:this.returnOnlyIdsHeaders}).map(function(e){return e.json()}).map(function(e){return e.hits.recids})},t.prototype.preview=function(e){return this.http.post(s.a.baseUrl+"/editor/preview",e).map(function(e){return e.text()}).toPromise()},t.prototype.manualMerge=function(e){var t={head_recid:this.currentRecordId,update_recid:e};return this.http.post(c.b+"/manual_merge",t).map(function(e){return e.json()}).map(function(e){return e.workflow_object_id})},t.ctorParameters=function(){return[{type:i.e}]},t}(u.a)},cDNt:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});n("GWWY"),n("f/CF"),n("KvE9"),n("zbpw"),n("NzKl"),n("ajBu"),n("feEK"),n("r24B"),n("pEMT"),n("jOBH"),n("Rjcp"),n("W8w6"),n("yJzT"),n("/wY1"),n("+iEx"),n("eFQL"),n("S0c/"),n("NdV9"),n("PSNg"),n("ivSB"),n("5dsq"),n("GQSG"),n("RSzd"),n("Hy2N"),n("7Wa7"),n("XD1n");var r=n("/oeL"),i=n("p5Ee"),a=n("uTHT");a.config(i.a.sentryPublicDSN,{release:i.a.version}).install();var o=function(){function e(){}return e.prototype.handleError=function(e){throw i.a.production&&a.captureException(e),e},e}(),s=function(){return function(){}}(),u=function(){return function(){}}(),l=n("XKG+"),c=n("BkNc"),d=[["#iframe-preview[_ngcontent-%COMP%]{width:100%;min-height:600px}"]],p=r._19({encapsulation:0,styles:d,data:{}});function h(e){return r._46(0,[(e()(),r._22(0,16777216,null,null,1,"router-outlet",[],null,null,null,null,null)),r._20(1,212992,null,0,c.m,[c.b,r._4,r.m,[8,null],r.j],null,null),(e()(),r._44(-1,null,["\n"]))],function(e,t){e(t,1,0)},null)}var f=r._17("re-app",u,function(e){return r._46(0,[(e()(),r._22(0,0,null,null,1,"re-app",[],null,null,null,h,p)),r._20(1,49152,null,0,u,[],null,null)],null,null)},{},{},[]),m=n("qbdv"),g=n("fc+i"),_=n("f9zQ"),y=n("fL27"),b=n("EyWH"),v=n("CPp0"),w=n("EW85"),S=n("sWh4"),C=n("ysRg"),k=n("bAhW"),A=n("V0P1"),T=n("6jTL"),P=n("SajZ"),M=n("7eGr"),I=n("sQaM"),j=n("0Pg/"),B=n("zxsQ"),E=n("DmCJ"),N=n("wvet"),R=function(){return function(){}}(),O=function(){return function(){}}(),F=n("x/Up"),x=n("G8gw"),G=r._18(s,[u],function(e){return r._33([r._34(512,r.m,r._14,[[8,[l.a,f]],[3,r.m],r.G]),r._34(5120,r.C,r._32,[[3,r.C]]),r._34(4608,m.n,m.m,[r.C]),r._34(5120,r.c,r._23,[]),r._34(5120,r.A,r._29,[]),r._34(5120,r.B,r._30,[]),r._34(4608,g.c,g.s,[m.d]),r._34(6144,r.T,null,[g.c]),r._34(4608,g.f,g.g,[]),r._34(5120,g.d,function(e,t,n,r){return[new g.l(e),new g.p(t),new g.o(n,r)]},[m.d,m.d,m.d,g.f]),r._34(4608,g.e,g.e,[g.d,r.I]),r._34(135680,g.n,g.n,[m.d]),r._34(4608,g.m,g.m,[g.e,g.n]),r._34(5120,_.a,y.d,[]),r._34(5120,_.c,y.e,[]),r._34(4608,_.b,y.c,[_.a,_.c]),r._34(5120,r.R,y.f,[g.m,_.b,r.I]),r._34(6144,g.q,null,[g.n]),r._34(4608,r._0,r._0,[r.I]),r._34(4608,g.h,g.h,[m.d]),r._34(4608,g.j,g.j,[m.d]),r._34(4608,b.b,y.b,[r.R,g.b]),r._34(4608,v.c,v.c,[]),r._34(4608,v.h,v.b,[]),r._34(5120,v.j,v.k,[]),r._34(4608,v.i,v.i,[v.c,v.h,v.j]),r._34(4608,v.g,v.a,[]),r._34(5120,v.e,v.l,[v.i,v.g]),r._34(5120,c.a,c.v,[c.k]),r._34(4608,c.d,c.d,[]),r._34(6144,c.f,null,[c.d]),r._34(135680,c.n,c.n,[c.k,r.F,r.k,r.y,c.f]),r._34(4608,c.e,c.e,[]),r._34(5120,c.h,c.y,[c.w]),r._34(5120,r.b,function(e){return[e]},[c.h]),r._34(4608,w.a,w.a,[]),r._34(4608,S.a,S.a,[v.e]),r._34(4608,C.a,C.a,[v.e]),r._34(4608,k.a,k.a,[v.e]),r._34(4608,A.a,A.a,[]),r._34(4608,T.a,T.a,[]),r._34(4608,P.a,P.a,[]),r._34(4608,M.a,M.a,[k.a]),r._34(4608,I.a,I.a,[]),r._34(4608,j.a,j.a,[]),r._34(4608,B.a,B.a,[w.a]),r._34(4608,E.a,E.a,[]),r._34(4608,N.b,N.b,[]),r._34(4608,N.a,N.a,[N.b,r.m,r.g]),r._34(4608,N.h,N.h,[N.c,N.a,r.y,g.c]),r._34(512,m.c,m.c,[]),r._34(512,r.q,o,[]),r._34(1024,r.H,function(){return[c.r()]},[]),r._34(512,c.w,c.w,[r.y]),r._34(1024,r.d,function(e,t,n){return[g.r(e,t),c.x(n)]},[[2,g.i],[2,r.H],c.w]),r._34(512,r.e,r.e,[[2,r.d]]),r._34(131584,r._21,r._21,[r.I,r._15,r.y,r.q,r.m,r.e]),r._34(2048,r.g,null,[r._21]),r._34(512,r.f,r.f,[r.g]),r._34(512,g.a,g.a,[[3,g.a]]),r._34(512,y.a,y.a,[]),r._34(512,v.f,v.f,[]),r._34(1024,c.q,c.t,[[3,c.k]]),r._34(512,c.p,c.c,[]),r._34(512,c.b,c.b,[]),r._34(256,m.a,"/editor",[]),r._34(256,c.g,{},[]),r._34(1024,m.i,c.s,[m.t,[2,m.a],c.g]),r._34(512,m.h,m.h,[m.i]),r._34(512,r.k,r.k,[]),r._34(512,r.F,r.X,[r.k,[2,r.Y]]),r._34(1024,c.i,function(){return[[{path:"holdingpen",loadChildren:"./holdingpen-editor/holdingpen-editor.module#HoldingpenEditorModule"},{path:"record",loadChildren:"./record-editor/record-editor.module#RecordEditorModule"},{path:"multieditor",loadChildren:"./multi-editor/multi-editor.module#MultiEditorModule"}]]},[]),r._34(1024,c.k,c.u,[r.g,c.p,c.b,m.h,r.y,r.F,r.k,c.i,c.g,[2,c.o],[2,c.j]]),r._34(512,c.l,c.l,[[2,c.q],[2,c.k]]),r._34(512,R,R,[]),r._34(512,O,O,[]),r._34(512,F.a,F.a,[]),r._34(512,x.a,x.a,[]),r._34(512,N.g,N.g,[[3,N.g]]),r._34(512,s,s,[]),r._34(256,N.c,{positionClass:"toast-bottom-right"},[])])});i.a.production&&Object(r._8)(),Object(g.k)().bootstrapModuleFactory(G)},gFIY:function(e,t,n){var r={"./holdingpen-editor/holdingpen-editor.module.ngfactory":["TSi0",0,3],"./multi-editor/multi-editor.module.ngfactory":["L4VK",0,2],"./record-editor/record-editor.module.ngfactory":["G9oL",0,1]};function i(e){var t=r[e];return t?Promise.all(t.slice(1).map(n.e)).then(function(){return n(t[0])}):Promise.reject(new Error("Cannot find module '"+e+"'."))}i.keys=function(){return Object.keys(r)},i.id="gFIY",e.exports=i},p5Ee:function(e,t,n){"use strict";n.d(t,"a",function(){return r});var r={production:!0,baseUrl:"",sentryPublicDSN:"https://ac471ee3b1ef4d1f884bfeaebaf6d007@sentry.inspirehep.net/7",version:"0.13.32"}},qtzZ:function(e,t,n){"use strict";var r=n("p5Ee"),i=n("2FwN");function a(e){return function(e,t,n){void 0===n&&(n="$$");for(var r=function(e,t){var n=t.replace(/./g,"\\$&"),r=e.join("");return new RegExp(n+"(["+r+"])")}(Object.keys(t),n),i=e.split(r),a=i.shift(),o=[],s=0;s<i.length;s+=2){var u=i[s],l=i[s+1];o.push({path:t[u],value:l})}return{splits:o,unsplitted:a}}(e,i.e)}n.d(t,"e",function(){return s}),n.d(t,"h",function(){return u}),n.d(t,"a",function(){return l}),n.d(t,"g",function(){return c}),n.d(t,"f",function(){return d}),n.d(t,"c",function(){return p}),t.d=function(e,t){return JSON.stringify(e).search(new RegExp(t,"i"))>-1},t.b=function(e){var t=e.split("/"),n=t[t.length-1],r=t[t.length-2];if("literature"!==r){var i="View "+r.slice(0,-1),a="//inspirehep.net/record/"+n;return{href:a,display:i}}var i="View literature",a=e.replace(/\/api\//,"/");return{href:a,display:i}},t.i=function(e,t,n,r){var i=a(t),o=e.slice(0,-2);if(i.splits.forEach(function(e){var t,r=e.path,i=r.findIndex(function(e){return"-"===e});if(i>-1){var a=void 0,s=i+1,u=r.slice(0,s);if(s<r.length){var l=r.slice(s),c={};c[l[l.length-1]]=e.value;for(var d=l.length-2;d>=0;d--)(t={})[l[d]]=c,c=t;a=c}else a=e.value;var p=o.concat(u);n.addIn(p,a)}else{var h=o.concat(e.path);n.setIn(h,e.value)}}),i.unsplitted)n.setIn(e,i.unsplitted);else{var s=e.slice(0,-1);Number.isInteger(e[e.length-1])&&n.getIn(s).size<=1?n.removeIn(s):n.removeIn(e)}r.buildKeysMapRecursivelyForPath(n.getIn(o),o)};var o=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},s=i.d,u=function(e,t,n){e.splice(-1,1,"record"),n.setIn(e,t._source.self),e.splice(-1,1,"curated_relation"),n.setIn(e,!0)},l={url:r.a.baseUrl+"/api/institutions/_suggest?affiliation=",path:"/affiliation/0/options",optionField:"/_source/legacy_ICN",size:20,itemTemplateName:"affiliationAutocompleteTemplate",onCompletionSelect:u},c={url:r.a.baseUrl+"/api/journals/_suggest?journal_title=",path:"/journal_title/0/options",optionField:"/_source/short_title",size:10},d=o({},c,{onCompletionSelect:function(e,t,n){e.splice(-1,1,"journal_record"),n.setIn(e,t._source.self),e.splice(-1,1,"curated_relation"),n.setIn(e,!0)}}),p={date:{formatChecker:function(e){return[/^\d{4}$/,/^\d{4}-\d{2}$/,/^\d{4}-\d{2}-\d{2}$/].some(function(t){return!!e.match(t)&&NaN!==Date.parse(e)})}},"date-time":{formatChecker:function(e){return!!e.match(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s][0-2]\d:[0-5]\d:[0-5]\d(?:\.\d+)?(?:z|[+-]\d\d:\d\d)?$/i)}}}},sQaM:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n("TO51"),i=function(){function e(){this.onPreview=new r.a}return e.prototype.displayModal=function(e){this.onPreview.next(e)},e}()},sWh4:function(e,t,n){"use strict";n.d(t,"a",function(){return s});var r=n("CPp0"),i=n("AP4T"),a=n("XZoy"),o=n("DFJI"),s=function(){function e(e){this.http=e}return e.prototype.fetchUrl=function(e){return this.http.get(e).map(function(e){return e.json()}).toPromise()},e.prototype.refExtract=function(e,t){var n,r=((n={})[t]=e,n);return this.http.post(a.b+"/refextract/"+t,r).map(function(e){return e.json()}).toPromise()},e.prototype.authorExtract=function(e){return this.http.post(a.b+"/authorlist/text",{text:e}).catch(function(e){return i.a.throw(new o.a(e))}).map(function(e){return e.json()})},e.prototype.uploadFile=function(e){var t=new FormData;return t.append("file",e,e.name),this.http.post(a.b+"/upload",t).map(function(e){return e.json()}).map(function(e){return e.path})},e.prototype.fetchRecordTickets=function(e){return this.fetchUrl(a.b+"/literature/"+e+"/rt/tickets")},e.prototype.createRecordTicket=function(e,t){return this.http.post(a.b+"/literature/"+e+"/rt/tickets/create",t).map(function(e){return e.json().data}).toPromise()},e.prototype.resolveTicket=function(e,t){return this.http.get(a.b+"/literature/"+e+"/rt/tickets/"+t+"/resolve").toPromise()},e.prototype.fetchRTUsers=function(){return this.http.get(a.b+"/rt/users").map(function(e){return e.json()}).map(function(e){return e.map(function(e){return e.name})})},e.prototype.fetchRTQueues=function(){return this.http.get(a.b+"/rt/queues").map(function(e){return e.json()}).map(function(e){return e.map(function(e){return e.name})})},e.prototype.getLinkedReferences=function(e){return e?this.http.post(a.b+"/linked_references",{references:e}).catch(function(e){return i.a.throw(new o.a(e))}).map(function(e){return e.json()}).map(function(e){return e.references}).toPromise():Promise.resolve()},e.prototype.fetchRevisions=function(e,t){return this.http.get(a.b+"/"+e+"/"+t+"/revisions").map(function(e){return e.json()}).toPromise()},e.prototype.fetchRevisionData=function(e,t,n){return this.http.get(a.b+"/literature/"+e+"/revision/"+n+"/"+t).map(function(e){return e.json()}).toPromise()},e.prototype.revertToRevision=function(e,t,n){return this.http.put(a.b+"/"+e+"/"+t+"/revisions/revert",{revision_id:n}).map(function(e){return e.json()}).toPromise()},e.ctorParameters=function(){return[{type:r.e}]},e}()},vMga:function(e,t,n){"use strict";var r=n("5q5V"),i=n("xrDH"),a=new r.a;function o(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Object(i.cloneDeep)(e);return i.mergeWith.apply(void 0,[r].concat(t,[function(e,t){if(Array.isArray(e)&&Array.isArray(t))return e.concat(t)}]))}var s=n("p5Ee"),u=n("qtzZ"),l={schemaOptions:{order:["document_type","publication_type","_collections","languages","titles","title_translations","dois","report_numbers","arxiv_eprints","inspire_categories","public_notes","number_of_pages","abstracts","publication_info","persistent_identifiers","external_system_identifiers","texkeys","isbns","book_series","thesis_info","preprint_date","imprints","keywords","energy_ranges","copyright","license","funding_info","_private_notes","urls","new_record","deleted_records","acquisition_source","legacy_creation_date","collaborations","accelerator_experiments","authors","corporate_author","curated","core","citeable","refereed","withdrawn","deleted"],alwaysShow:["_private_notes","abstracts","accelerator_experiments","authors","citeable","collaborations","curated","deleted","documents","dois","number_of_pages","public_notes","publication_info","urls","refereed","references","report_numbers","withdrawn"],alwaysShowRegExp:new RegExp("value"),properties:{deleted:{toggleColor:"#e74c3c"},citeable:{toggleColor:"#8e44ad"},core:{toggleColor:"#27ae60"},withdrawn:{toggleColor:"#f1c40f"},refereed:{toggleColor:"#34495e"},curated:{toggleColor:"#3498db"},$schema:{hidden:!0},control_number:{hidden:!0},self:{hidden:!0},_files:{hidden:!0},texkeys:{disabled:!0},document_type:{items:{onValueChange:function(e,t){a.next(t)}}},abstracts:{items:{properties:{value:{priority:1,columnWidth:80,latexPreviewEnabled:!0},source:{autocompletionConfig:{url:s.a.baseUrl+"/api/literature/_suggest?abstract_source=",path:"/abstract_source/0/options",size:10}}}}},accelerator_experiments:{items:{alwaysShow:["legacy_name","accelerator"],order:["legacy_name","institution","accelerator","experiment"],properties:{legacy_name:{autocompletionConfig:{url:s.a.baseUrl+"/api/experiments/_suggest?experiment=",path:"/experiment/0/options",size:10,optionField:"/_source/legacy_name",onCompletionSelect:u.h}},record:{refFieldConfig:{anchorBuilder:u.b}}}}},acquisition_source:{disabled:!0,order:["method","source","datetime","email","orcid"],properties:{internal_uid:{hidden:!0},submission_number:{hidden:!0}}},authors:{longListNavigatorConfig:{findMultiple:u.d,itemsPerPage:20,maxVisiblePageCount:5,headerItemTemplateName:"authorExtractTemplate"},sortable:!0,items:{order:["full_name","alternative_names","affiliations","raw_affiliations","emails","ids","inspire_roles","credit_roles"],alwaysShow:["affiliations","emails"],properties:{uuid:{hidden:!0},signature_block:{hidden:!0},affiliations:{items:{order:["value","record"],properties:{record:{refFieldConfig:{anchorBuilder:u.b}},value:{autocompletionConfig:u.a}}}},ids:{items:{anyOf:[{properties:{value:{priority:1}}}]}},record:{refFieldConfig:{anchorBuilder:u.b}}}}},arxiv_eprints:{disabled:!0,items:{order:["value"]}},collaborations:{items:{order:["value"],properties:{record:{refFieldConfig:{anchorBuilder:u.b}}}}},copyright:{items:{alwaysShow:["statement","url"]}},documents:{titleDropdownItemTemplateNames:["fileUploadButtonTemplate"]},dois:{items:{order:["value","material","source"]}},external_system_identifiers:{items:{order:["value"]}},_private_notes:{items:{order:["value"]}},imprints:{items:{alwaysShow:["date"],order:["publisher","place","date"]}},isbns:{items:{order:["value"]}},keywords:{items:{alwaysShow:["schema"],properties:{value:{priority:1}}}},license:{items:{alwaysShow:["license","url"]}},languages:{items:{enumDisplayValueMap:u.e}},persistent_identifiers:{items:{order:["value","schema","material","source"]}},publication_info:{items:{alwaysShow:["journal_title","journal_volume","journal_issue","artid","year","page_start"],order:["journal_title","journal_volume","journal_issue","year","page_start","page_end","artid"],properties:{journal_title:{autocompletionConfig:u.f},conference_record:{refFieldConfig:{anchorBuilder:u.b}},journal_record:{refFieldConfig:{anchorBuilder:u.b}},parent_record:{refFieldConfig:{anchorBuilder:u.b}}}}},record_affiliations:{items:{properties:{value:{autocompletionConfig:u.a}}}},references:{sortable:!0,longListNavigatorConfig:{findSingle:function(e,t){return e.getIn(["reference","label"])===t},findMultiple:u.d,itemsPerPage:40,maxVisiblePageCount:5,headerItemTemplateName:"refActionsTemplate"},viewTemplateConfig:{itemTemplateName:"referenceTemplate",showEditForm:function(e){return!e.hasIn(["record","$ref"])}},items:{alwaysShow:["reference"],properties:{record:{refFieldConfig:{anchorBuilder:u.b}},reference:{priority:1,order:["label","title","authors","arxiv_eprint"],alwaysShow:["dois","arxiv_eprint","publication_info","authors","title"],properties:{misc:{items:{onValueChange:u.i}},arxiv_eprint:{onValueChange:u.i},authors:{items:{alwaysShow:["full_name"],properties:{full_name:{onValueChange:u.i},inspire_role:{onValueChange:u.i}}}},imprint:{properties:{publisher:{onValueChange:u.i}}},title:{alwaysShow:["title"],properties:{title:{onValueChange:u.i}}},dois:{items:{onValueChange:u.i}},collaborations:{items:{onValueChange:u.i}},isbn:{onValueChange:u.i},report_numbers:{items:{onValueChange:u.i}},publication_info:{alwaysShow:["journal_title","journal_volume","page_start","page_end","artid","year"],order:["journal_title","journal_volume","journal_issue","year","page_start","page_end","artid"],properties:{journal_title:{onValueChange:u.i,autocompletionConfig:u.g},journal_volume:{onValueChange:u.i},journal_issue:{onValueChange:u.i},page_start:{onValueChange:u.i},page_end:{onValueChange:u.i},artid:{onValueChange:u.i},cnum:{onValueChange:u.i}}}}}}}},thesis_info:{alwaysShow:["date","defense_date","degree_type","institutions"],properties:{degree_type:{priority:1},institutions:{items:{properties:{name:{autocompletionConfig:u.a}}}}}},titles:{sortable:!0,items:{alwaysShow:["title"],order:["title"],properties:{title:{latexPreviewEnabled:!0},source:{columnWidth:12}}}},title_translations:{items:{alwaysShow:["title"],order:["title","subtitle","language","source"],properties:{language:{enumDisplayValueMap:u.e}}}},inspire_categories:{items:{properties:{term:{priority:1}}}},public_notes:{items:{order:["value"]}},report_numbers:{items:{order:["value"]}},urls:{items:{alwaysShow:["description"]}},new_record:{refFieldConfig:{anchorBuilder:u.b}}}},customFormatValidation:u.c,tabsConfig:{defaultTabName:"Main",tabs:[{name:"References",properties:["references"]},{name:"Authors",properties:["collaborations","accelerator_experiments","authors","corporate_author"]}]},menuMaxDepth:1,enableAdminModeSwitch:!0,previews:[{name:"pdf",type:"html",getUrl:function(e){var t=e.urls;if(t&&t.length>0){var n=t.map(function(e){return e.value}).find(function(e){return e.endsWith(".pdf")});return void 0!==n?n.replace("http://","//")+"#zoom=100":void 0}}},{name:"arXiv",type:"html",getUrl:function(e){var t=e.arxiv_eprints;return t&&t.length>0?"//arxiv.org/pdf/"+t[0].value+".pdf#zoom=100":void 0}},{name:"doi",type:"html",getUrl:function(e){var t=e.dois;return t&&t.length>0?"//doi.org/"+t[0].value:void 0}}]};n.d(t,"d",function(){return c}),n.d(t,"g",function(){return d}),n.d(t,"a",function(){return p}),n.d(t,"b",function(){return h}),n.d(t,"f",function(){return f}),n.d(t,"c",function(){return m}),n.d(t,"e",function(){return a});var c=l,d=o(l,{schemaOptions:{alwaysShow:["copyright","isbns","languages","license","title_translations","thesis_info","persistent_identifiers"],properties:{authors:{items:{alwaysShow:["inspire_roles"]}}}}}),p=o(l,{schemaOptions:{alwaysShow:["book_series","imprints","isbns","publication_info"],properties:{authors:{items:{alwaysShow:["inspire_roles"]}}}}}),h=o(l,{schemaOptions:{alwaysShow:["publication_info"],properties:{publication_info:{items:{alwaysShow:["parent_isbn","parent_record"]}}}}}),f=o(l,{schemaOptions:{alwaysShow:["book_series","imprints","isbns","publication_info"],properties:{authors:{items:{alwaysShow:["inspire_roles"]}},publication_info:{items:{alwaysShow:["cnum"]}}}}}),m=o(l,{schemaOptions:{alwaysShow:["publication_info"],properties:{publication_info:{items:{alwaysShow:["cnum"]}}}}})},ysRg:function(e,t,n){"use strict";n.d(t,"a",function(){return c});var r,i=n("CPp0"),a=n("AP4T"),o=n("sWh4"),s=n("XZoy"),u=n("DFJI"),l=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),c=function(e){function t(t){var n=e.call(this,t)||this;return n.http=t,n}return l(t,e),t.prototype.fetchWorkflowObject=function(e){return this.currentWorkflowObjectApiUrl=s.d+"/"+e,this.fetchUrl(this.currentWorkflowObjectApiUrl)},t.prototype.saveWorkflowObject=function(e){return this.http.put(this.currentWorkflowObjectApiUrl,e).catch(function(e){return a.a.throw(new u.a(e))}).map(function(e){return e.json()})},t.prototype.saveWorkflowObjectWithCallbackUrl=function(e,t){return this.http.put(t,e).catch(function(e){return a.a.throw(new u.a(e))}).map(function(e){return e.json()})},t.ctorParameters=function(){return[{type:i.e}]},t}(o.a)},zxsQ:function(e,t,n){"use strict";n.d(t,"a",function(){return i});var r=n("SIAm"),i=function(){function e(e){this.pathUtilsService=e}return e.prototype.toValidationProblems=function(e){var t=this,n={};return e.forEach(function(e){var r=t.pathUtilsService.toPathString(e.path),i={type:"Error",message:e.message};n[r]=n[r]||[],n[r].push(i)}),n},e.ctorParameters=function(){return[{type:r.c}]},e}()}},[0]); //# sourceMappingURL=main.bundle.js.map