Skip to content

Commit

Permalink
Merge branch 'main' into Pinterest-Polska-1
Browse files Browse the repository at this point in the history
  • Loading branch information
mikolajroszak authored Aug 13, 2024
2 parents ceef1ee + f7ba820 commit 0472051
Show file tree
Hide file tree
Showing 43 changed files with 1,832 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/14287-908297ff4ca6fa96.mjs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .github/workflows/18011.pl_PL-a45685ef361d0672.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
"use strict";(self.__LOADABLE_LOADED_CHUNKS__=self.__LOADABLE_LOADED_CHUNKS__||[]).push([[18011],{242227:(e,t,r)=>{r.d(t,{Z:()=>i});var n=r(619013),E=r(983946),A=r(13882);function i(e){(0,A.Z)(1,arguments);var t=(0,E.Z)(e);return(0,n.Z)(1e3*t)}},428401:(e,t,r)=>{r.d(t,{Z:()=>A});var n=r(619013),E=r(13882);function A(e){return(0,E.Z)(1,arguments),Math.floor(function(e){return(0,E.Z)(1,arguments),(0,n.Z)(e).getTime()}(e)/1e3)}},500313:(e,t,r)=>{r.d(t,{Z:()=>A});var n=r(619013),E=r(13882);function A(e,t){(0,E.Z)(2,arguments);var r=(0,n.Z)(e),A=(0,n.Z)(t);return r.getTime()<A.getTime()}},911946:(e,t,r)=>{r.d(t,{J:()=>E,Z:()=>A});var n=r(662267);let E=e=>e===n.b$.TRAFFIC?n.jE.CONSIDERATION:e,A=e=>e===n.LN.TRAFFIC?n.mE.CONSIDERATION:e},449508:(e,t,r)=>{r.d(t,{Em:()=>i,K1:()=>E,VP:()=>T,aJ:()=>s,es:()=>D,rO:()=>a,rq:()=>A,sx:()=>o});var n=r(662267);let E=100,A={ADD_TO_CART_CPA:"9",CHECKOUT_CPA:"5",LEAD_CPA:"11",SIGNUP_CPA:"4",CPC:"1",CPCV:"18",CPM:"2",CPV:"17",CTR:"13",ENGAGEMENT_RATE:"14",ROAS:"0",VIDEO_COMPLETION_RATE:"16"},i={ROAS:2,SIGNUP:1,CHECKOUT:2,ADD_TO_CART:6,LEAD:8},a={[A.ROAS]:i.ROAS,[A.SIGNUP_CPA]:i.SIGNUP,[A.CHECKOUT_CPA]:i.CHECKOUT,[A.ADD_TO_CART_CPA]:i.ADD_TO_CART,[A.LEAD_CPA]:i.LEAD},o={[n.mE.CONSIDERATION]:[A.CPC],[n.LN.TRAFFIC]:[A.CPC],[n.mE.WEB_CONVERSION]:[A.CHECKOUT_CPA,A.ADD_TO_CART_CPA,A.LEAD_CPA,A.SIGNUP_CPA]},D=[A.ROAS,A.CHECKOUT_CPA,A.ADD_TO_CART_CPA,A.LEAD_CPA,A.SIGNUP_CPA],T={PERCENTAGE:1,RATIO:2,CURRENCY:3},s={[A.ADD_TO_CART_CPA]:T.CURRENCY,[A.CHECKOUT_CPA]:T.CURRENCY,[A.LEAD_CPA]:T.CURRENCY,[A.SIGNUP_CPA]:T.CURRENCY,[A.CPC]:T.CURRENCY,[A.CPCV]:T.CURRENCY,[A.CPM]:T.CURRENCY,[A.CPV]:T.CURRENCY,[A.CTR]:T.PERCENTAGE,[A.ENGAGEMENT_RATE]:T.PERCENTAGE,[A.ROAS]:T.RATIO,[A.VIDEO_COMPLETION_RATE]:T.PERCENTAGE}},839714:(e,t,r)=>{r.d(t,{H:()=>i,Z:()=>a});let n=Object.freeze({ALPHA:"ALPHA",GA:"GA"}),E=[n.ALPHA,n.GA],A=(e,t)=>{switch(e){case n.ALPHA:return t.checkExperiment("aid_exp_targeting_profiles_alpha").anyEnabled;case n.GA:return t.checkExperiment("aid_exp_targeting_profiles_ga").anyEnabled;default:return!1}},i=e=>A(n.GA,e),a=e=>E.some(t=>A(t,e))},392557:(e,t,r)=>{r.d(t,{$d:()=>E,Bc:()=>d,C5:()=>s,H2:()=>C,Hu:()=>_,Pf:()=>o,SZ:()=>I,TS:()=>n,Te:()=>c,Ut:()=>R,bs:()=>u,cH:()=>A,cl:()=>l,d9:()=>i,de:()=>S,eW:()=>a,nD:()=>D,yJ:()=>T,yR:()=>P,yV:()=>O,zL:()=>N});let n={NEW_ACTIVE_AUTO_CAMPAIGN_CREATED:"NEW_ACTIVE_AUTO_CAMPAIGN_CREATED",NEW_PAUSED_AUTO_CAMPAIGN_CREATED:"NEW_PAUSED_AUTO_CAMPAIGN_CREATED",NEW_UNKNOWN_AUTO_CAMPAIGN_CREATED:"NEW_UNKNOWN_AUTO_CAMPAIGN_CREATED",NEW_CAMPAIGN_CREATED:"NEW_CAMPAIGN_CREATED",NEW_CAMPAIGN_CLONES_CREATED:"NEW_CAMPAIGN_CLONES_CREATED",NEW_AD_GROUP_CLONES_CREATED:"NEW_AD_GROUP_CLONES_CREATED",NEW_DUPLICATES_CREATED:"NEW_DUPLICATES_CREATED",EDITS_SAVED:"EDITS_SAVED",NEW_ACTIVE_CAMPAIGN_CREATED:"NEW_ACTIVE_CAMPAIGN_CREATED",NEW_PAUSED_CAMPAIGN_CREATED:"NEW_PAUSED_CAMPAIGN_CREATED"},E={RUNNING:"RUNNING",PAUSED:"PAUSED",NOT_STARTED:"NOT_STARTED",COMPLETED:"COMPLETED",ARCHIVED:"ARCHIVED",ADVERTISER_DISABLED:"ADVERTISER_DISABLED",DRAFT:"DRAFT",DELETED_DRAFT:"DELETED_DRAFT"},A={RUNNING:"RUNNING",PAUSED:"PAUSED",NOT_STARTED:"NOT_STARTED",COMPLETED:"COMPLETED",ARCHIVED:"ARCHIVED",ADVERTISER_DISABLED:"ADVERTISER_DISABLED",DRAFT:null,DELETED_DRAFT:null},i={RUNNING:"RUNNING",PAUSED:"PAUSED",NOT_STARTED:"NOT_STARTED",COMPLETED:"COMPLETED",ARCHIVED:"ARCHIVED",ADVERTISER_DISABLED:"ADVERTISER_DISABLED"},a={APPROVED:"APPROVED",PENDING:"PENDING",PAUSED:"PAUSED",REJECTED:"REJECTED",ARCHIVED:"ARCHIVED",ADVERTISER_DISABLED:"ADVERTISER_DISABLED"},o={RUNNING:"RUNNING",PAUSED:"PAUSED",EXCLUDED:"EXCLUDED",ARCHIVED:"ARCHIVED"},D={ACTIVE:"ACTIVE",PAUSED:"PAUSED",ARCHIVED:"ARCHIVED",DRAFT:"DRAFT",DELETED_DRAFT:"DELETED_DRAFT"},T={ACTIVE:"ACTIVE",PAUSED:"PAUSED",ARCHIVED:"ARCHIVED",DRAFT:"DRAFT",DELETED_DRAFT:"DELETED_DRAFT"},s={ACTIVE:"ACTIVE",PAUSED:"PAUSED",ARCHIVED:"ARCHIVED",DRAFT:"DRAFT",DELETED_DRAFT:"DELETED_DRAFT"},C={ACTIVE:"ACTIVE",PAUSED:"PAUSED",DRAFT:"DRAFT",DELETED_DRAFT:"DELETED_DRAFT"},_={ACTIVE:"ACTIVE",ARCHIVED:"ARCHIVED"},l="createNewCampaign",u={userPackages:"userPackages",advertiserPackages:"advertiserPackages"},R=Object.freeze({ALL_INGESTION_SOURCES:"ALL_INGESTION_SOURCES",TAG:"TAG",MMP:"MMP",FILE_UPLOAD:"FILE_UPLOAD",CONVERSIONS_API:"CONVERSIONS_API",NATIVE:"NATIVE"}),c={ALL_INGESTION_SOURCES:null,TAG:"TAG",MMP:"MMP",FILE_UPLOAD:"FILE_UPLOAD",CONVERSIONS_API:"CONVERSIONS_API",NATIVE:"NATIVE"},I={AD_EVENT:"TIME_OF_AD_ACTION",CONVERSION_EVENT:"TIME_OF_CONVERSION"},N={INDIVIDUAL:"INDIVIDUAL",HOUSEHOLD:"HOUSEHOLD"},d={DETERMINISTIC:"DETERMINISTIC",MODELED:"MODELED"},O={CLOSEUP:"CLOSEUP",DIRECT_TO_DESTINATION:"DIRECT_TO_DESTINATION"},P=Object.freeze({FILTER_NO_DELIVERY:"filterNoDelivery"}),S=Object.freeze({TOTAL:1,IMAGE:2,VIDEO:3,APP_LINK:4})},52363:(e,t,r)=>{r.d(t,{default:()=>_});var n=r(288673),E=r(562967);function A(e,t,r){var n;return(t="symbol"==typeof(n=function(e,t){if("object"!=typeof e||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!=typeof n)return n;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"))?n:String(n))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let i=Object.freeze(["click","engagement","view"].sort());function a(e){return"number"==typeof e?e:(0,E.k)(e)?e:Number.parseInt(e,10)}function o(e,t,r){return 3!==e.length?t():e.some(E.k)?r():e.map(String).join("/")}function D(e){return i.map(t=>e[t])}function T(e,t){return e.some(E.k)?t():e.map(String).join("/")}let s=Object.freeze(["60/60/60","60/60/30","60/60/7","60/60/1","60/30/30","60/30/7","60/30/1","60/7/7","60/7/1","60/1/1","30/30/30","30/30/7","30/30/1","30/7/7","30/7/1","30/1/1","7/7/7","7/7/1","7/1/1","1/1/1"]),C=Object.freeze(["60/60/60","30/30/1","30/30/30","7/7/7","7/7/1","1/1/1"]);class _{static stringToAttributionWindowOrThrow(e){return _.fromValuesArray(_.stringToValuesArrayOrThrow(e))}static extractWindowComponents(e,t=!1){let r=e.split("/"),n=t?e=>parseInt(e,10):e=>e;return{click:n(r[0]),engagement:n(r[1]),view:n(r[2])}}static toStringOrThrow(e){return T(_.toStringableValuesArray(e),()=>{throw Error("some values do not exist")})}static toStringOrNull(e){return T(_.toStringableValuesArray(e),()=>null)}static valuesArrayToStringOrNull(e){let t=()=>null;return o(e,t,t)}static valuesArrayToStringOrThrow(e){return o(e,()=>{throw Error("values array must have length == 3")},()=>{throw Error("some elements did not exist")})}static async getRecommendedWindows(e,t){let{recommended_windows:r,average_tto:E}=await (0,n.pw)({advertiser_id:e},{conversion_type:t.toString()});return r&&E?{recommendedWindows:[r.click,r.engagement,r.view],averageTTO:Math.round(E)}:{recommendedWindows:null,averageTTO:null}}static async getAttributionWindowCoverage(e,t,r){if(r.click&&r.engagement&&r.view){let E=await (0,n.e)({advertiser_id:e},{conversion_type:t.toString(),conversion_window:{click:r.click?.toString(),engagement:r.engagement?.toString(),view:r.view?.toString()}});if(E.conversion_coverage)return Math.round(100*E.conversion_coverage)}return null}static compareAttributionWindows(e,t){if(!e)return -1;if(!t)return 1;let r=e.view??0,n=t.view??0;if(r!==n)return r-n;let E=e.engagement??0,A=t.engagement??0;if(E!==A)return E-A;let i=e.click??0,a=t.click??0;return i!==a?i-a:0}static equalAttributionWindows(e,t){return 0===_.compareAttributionWindows(e,t)}static toStringableValuesArray(e){return D(e)}static toValuesArray(e){return D(e)}static stringToValuesArrayOrThrow(e){return function(e,t){let r=e.split("/");return 3!==r.length?t(r.length):r.map(e=>Number.parseInt(e,10))}(e,e=>{throw Error(`string split into ${e<3?"less":"more"} than 3 elements`)})}static fromValuesArrayUnparsed(e){return{click:e[0],engagement:e[1],view:e[2]}}static fromValuesArray(e){return _.parsedValues(_.fromValuesArrayUnparsed(e))}static parsedValues({click:e,engagement:t,view:r}){return{click:a(e),engagement:a(t),view:a(r)}}static mapAttributionWindowWithoutEngagement(e){return e.map(e=>{let{click:t,view:r}=_.extractWindowComponents(e.value,!0);return{label:`${t}/${r}`,value:0===r?`${t}/0/0`:`${t}/${t}/${r}`}})}}A(_,"constants",{windowsDeprecatedInQ12017:Object.freeze(new Set(["30/60/1","1/1/14","30/1/14","60/1/14","1/30/14","30/30/14","60/30/14","1/60/14","30/60/14","60/60/14"])),windowsAddedInQ12017:Object.freeze(new Set(["7/1/1","7/7/1","30/7/1","60/7/1","30/7/7","60/7/7","60/30/7","60/60/7","30/30/30","60/30/30","60/60/30","60/60/60"])),defaultWindow:"30/30/30",lastClickAttributionWindow:"1/0/0",defaultRoasAttributionWindow:"7/7/1",windowUpdateDate:Object.freeze(new Date("2017-03-01")),OCPMAttributionWindows:Object.freeze(["30/30/1","7/7/1","7/0/0","1/1/1","1/0/0"]),ExtendedOCPMAttributionWindows:Object.freeze(["30/30/30","30/30/7","30/30/1","7/7/7","7/7/1","7/0/0","1/1/1","1/0/0"]),deprecatedAttributionWindows:Object.freeze(["1/30/1","1/60/1"]),adsReportingConversionType:2,attributionWindowAllNull:Object.freeze({click:null,engagement:null,view:null})}),A(_,"getWindowOptions",(e,t,r)=>{let n=r?C:s;if(e&&(n=e.concat(n.filter(t=>!e.includes(t)))),t){let e=n.findIndex(e=>"7/1/1"===e)+1;n=n.slice(0,e).concat(["7/0/0"],n.slice(e,n.length),["1/0/0"])}return n.map(e=>({label:e,value:e}))}),A(_,"getValidationMessage",(e,t,r,n)=>{let{constants:E}=_,A=r>=E.windowUpdateDate,i=t<E.windowUpdateDate;return A&&E.windowsDeprecatedInQ12017.has(e)?n.bt("Ta kombinacja przedziałów czasowych przypisania jest obsługiwana tylko do 1 marca 2017 r.", "This attribution window combination is only supported before March 1, 2017.", "[m10n]", undefined, true):i&&E.windowsAddedInQ12017.has(e)?n.bt("Ta kombinacja przedziałów czasowych przypisania jest obsługiwana tylko od 1 marca 2017 r.", "This attribution window combination is only supported starting from March 1, 2017.", "[m10n]", undefined, true):""}),A(_,"isValidWindow",(e,t,r=!1,n=!1)=>r?t&&t.includes(e)||_.getWindowOptions(null,!1,n).some(t=>t.value===e)||_.constants.OCPMAttributionWindows.includes(e):t&&t.includes(e)||_.getWindowOptions(null,!1,n).some(t=>t.value===e)),A(_,"isDeprecatedWindow",e=>_.constants.deprecatedAttributionWindows.includes(e)),A(_,"isDeprecatedWindowForDifferentialPrivacy",e=>s.filter(e=>!C.includes(e)).includes(e)),A(_,"packAttributionWindow",e=>{let{clickWindowDays:t,engagementWindowDays:r,viewWindowDays:n}=e;return`${t}/${r}/${n}`}),A(_,"unpackAttributionWindow",e=>{let t=_.extractWindowComponents(e,!0);return{clickWindowDays:t.click,engagementWindowDays:t.engagement,viewWindowDays:t.view}}),A(_,"getAttributionWindowWithoutEngagement",e=>{let{click:t,view:r}=_.extractWindowComponents(e,!0);return`${t}/${r}`}),A(_,"getMappedAttributionWindowWithEngagement",(e,t,r)=>{let{click:n,view:E}=_.extractWindowComponents(e,!0),A=0===E?`${n}/0/0`:`${n}/${n}/${E}`;return _.isValidWindow(A,t,r,!0)?A:_.constants.defaultWindow})},562967:(e,t,r)=>{function n(e){return null==e}function E(e){return!n(e)}r.d(t,{G:()=>E,k:()=>n})},115694:(e,t,r)=>{r.d(t,{b:()=>n});class n{constructor(e=5,t=0){this.sliceSize=e,this.delay=t}sliceRequests(e){let t=[],r=Object.keys(e).map(t=>({key:t,func:e[t]}));for(;r.length>0;)t.push(r.splice(0,this.sliceSize));return t}delayPromise(e=0){return 0===e?e=>e:t=>new Promise(r=>{setTimeout(()=>{r(t)},e)})}process(e){let t=this.sliceRequests(e),r={},n={},E=()=>{let e=t.shift();return e?Promise.all(e.map(({key:e,func:t})=>t().then(t=>{r[e]=t}).catch(t=>{n[e]=t}))).then(this.delayPromise(this.delay)).then(()=>E()):Promise.resolve({rejected:n,resolved:r})};return E()}}},983983:(e,t,r)=>{r.d(t,{L1:()=>i,NW:()=>D,Rz:()=>T,WZ:()=>a,cI:()=>A,fe:()=>o,hu:()=>E});var n=r(883119);let E=64,A=80,i=22,a="HeaderContent",o=671,D=new n.Ry(o),T={boxShadow:"0px 8px 8px -8px rgba(0, 0, 0, 0.1)",transition:"box-shadow 300ms ease-in-out"}}}]);
//# sourceMappingURL=https://sm.pinimg.com/webapp/18011.pl_PL-a45685ef361d0672.mjs.map
2 changes: 2 additions & 0 deletions .github/workflows/19114.pl_PL-1ea9243f7b639b4b.mjs

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions .github/workflows/26296.pl_PL-7a78b8e16c64c5ec.mjs

Large diffs are not rendered by default.

Loading

0 comments on commit 0472051

Please sign in to comment.