Skip to content

Commit

Permalink
Merge pull request #19 from ImproveDigital/razr-fix
Browse files Browse the repository at this point in the history
Fix RAZR related code
  • Loading branch information
cciocov authored Mar 2, 2023
2 parents 2124ce5 + 7f5c36f commit 2a92881
Show file tree
Hide file tree
Showing 454 changed files with 44,782 additions and 12,971 deletions.
2 changes: 2 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
ARG VARIANT="12"
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:${VARIANT}

RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | gpg --dearmor > /usr/share/keyrings/yarn-archive-keyring.gpg

# [Optional] Uncomment this section to install additional OS packages.
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
# && apt-get -y install --no-install-recommends <your-package-list-here>
Expand Down
3 changes: 2 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@

// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"nickdodd79.gulptasks"
"nickdodd79.gulptasks",
"dbaeumer.vscode-eslint"
],

// 9999 is web server, 9876 is karma
Expand Down
43 changes: 27 additions & 16 deletions .github/workflows/issue_tracker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
steps:
- name: Generate token
id: generate_token
uses: tibdex/github-app-token@f717b5ecd4534d3c4df4ce9b5c1c2214f0f7cd06
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.ISSUE_APP_ID }}
private_key: ${{ secrets.ISSUE_APP_PEM }}
Expand All @@ -29,21 +29,30 @@ jobs:
gh api graphql -f query='
query($org: String!, $number: Int!) {
organization(login: $org){
projectNext(number: $number) {
projectV2(number: $number) {
id
fields(first:100) {
nodes {
id
name
settings
... on ProjectV2Field {
id
name
}
... on ProjectV2SingleSelectField {
id
name
options {
id
name
}
}
}
}
}
}
}' -f org=$ORGANIZATION -F number=$PROJECT_NUMBER > project_data.json
echo 'PROJECT_ID='$(jq '.data.organization.projectNext.id' project_data.json) >> $GITHUB_ENV
echo 'DATE_FIELD_ID='$(jq '.data.organization.projectNext.fields.nodes[] | select(.name== "'"$DATE_FIELD"'") | .id' project_data.json) >> $GITHUB_ENV
echo 'PROJECT_ID='$(jq '.data.organization.projectV2.id' project_data.json) >> $GITHUB_ENV
echo 'DATE_FIELD_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name=="'"$DATE_FIELD"'") | .id' project_data.json) >> $GITHUB_ENV
- name: Add issue to project
env:
Expand All @@ -52,9 +61,9 @@ jobs:
run: |
gh api graphql -f query='
mutation($project:ID!, $issue:ID!) {
addProjectNextItem(input: {projectId: $project, contentId: $issue}) {
projectNextItem {
id,
addProjectV2ItemById(input: {projectId: $project, contentId: $issue}) {
item {
id
content {
... on Issue {
createdAt
Expand All @@ -67,8 +76,8 @@ jobs:
}
}' -f project=$PROJECT_ID -f issue=$ISSUE_ID > issue_data.json
echo 'ITEM_ID='$(jq '.data.addProjectNextItem.projectNextItem.id' issue_data.json) >> $GITHUB_ENV
echo 'ITEM_CREATION_DATE='$(jq '.data.addProjectNextItem.projectNextItem.content.createdAt' issue_data.json) >> $GITHUB_ENV
echo 'ITEM_ID='$(jq '.data.addProjectV2ItemById.item.id' issue_data.json) >> $GITHUB_ENV
echo 'ITEM_CREATION_DATE='$(jq '.data.addProjectV2ItemById.item.content.createdAt' issue_data.json | cut -c 2-11) >> $GITHUB_ENV
- name: Set fields
env:
Expand All @@ -79,15 +88,17 @@ jobs:
$project: ID!
$item: ID!
$date_field: ID!
$date_value: String!
$date_value: Date!
) {
set_creation_date: updateProjectNextItemField(input: {
set_creation_date: updateProjectV2ItemFieldValue(input: {
projectId: $project
itemId: $item
fieldId: $date_field
value: $date_value
value: {
date: $date_value
}
}) {
projectNextItem {
projectV2Item {
id
}
}
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
[![Build Status](https://circleci.com/gh/prebid/Prebid.js.svg?style=svg)](https://circleci.com/gh/prebid/Prebid.js)
[![Percentage of issues still open](http://isitmaintained.com/badge/open/prebid/Prebid.js.svg)](http://isitmaintained.com/project/prebid/Prebid.js "Percentage of issues still open")
[![Coverage Status](https://coveralls.io/repos/github/prebid/Prebid.js/badge.svg)](https://coveralls.io/github/prebid/Prebid.js)
[![Total Alerts](https://img.shields.io/lgtm/alerts/g/prebid/Prebid.js.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/prebid/Prebid.js/alerts/)

# Prebid.js

Expand Down
5 changes: 5 additions & 0 deletions integrationExamples/gpt/adloox.html
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,13 @@
realTimeData: {
auctionDelay: AUCTION_DELAY,
dataProviders: [
{
name: 'intersection',
waitForIt: true
},
{
name: 'adloox',
waitForIt: true,
params: { // optional, defaults shown
thresholds: [ 50, 60, 70, 80, 90 ],
slotinpath: false
Expand Down
167 changes: 167 additions & 0 deletions integrationExamples/gpt/captifyRtdProvider_example.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,167 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name=viewport content="width=device-width, initial-scale=1">
<script type="text/javascript" src="https://cache.consentframework.com/js/pa/1020/c/Y1Dhs/stub" charset="utf-8"></script>
<script type="text/javascript" async src="https://choices.consentframework.com/js/pa/1020/c/Y1Dhs/cmp" charset="utf-8"></script>
</head>
<body>

<script async src="https://pagead2.googlesyndication.com/tag/js/gpt.js"></script>
<script src="prebid.js" async></script>

<script>
var pbjs = pbjs || {};
pbjs.que = pbjs.que || [];

pbjs.que.push(function() {
pbjs.setConfig({
debug: true,
realTimeData: {
auctionDelay: 1000,
dataProviders: [
{
name: "CaptifyRTDModule",
waitForIt: true,
params: {
pubId: 11287,
bidders: ['appnexus'],
}
}
]
},
consentManagement: {
usp: {
cmpApi: 'iab',
timeout: 100 // US Privacy timeout 100ms
},
gdpr: {
cmpApi: 'iab',
timeout: 8000,
defaultGdprScope: true,
getTCData: {
tcString: 'COwK6gaOwK6gaFmAAAENAPCAAAAAAAAAAAAAAAAAAAAA.IFoEUQQgAIQwgIwQABAEAAAAOIAACAIAAAAQAIAgEAACEAAAAAgAQBAAAAAAAGBAAgAAAAAAAFAAECAAAgAAQARAEQAAAAAJAAIAAgAAAYQEAAAQmAgBC3ZAYzUw',
gdprApplies: true,
purpose: {
consents: {
0: true,
},
legitimateInterests: {
0: true,
}
},
vendor: {
consents: {
00: true,
},
legitimateInterests: {
0: true,
}
}
},
rules: [{
purpose: "storage",
enforcePurpose: true,
enforceVendor: true,
vendorExceptions: ["appnexus"] //Can work without consent for cookies
},{
purpose: "basicAds",
enforcePurpose: true,
enforceVendor: true,
vendorExceptions: ["appnexus"]
}]
},
}
});
});

</script>
<script>
var div_1_sizes = [
[728, 90]
];

var PREBID_TIMEOUT = 3500;
var FAILSAFE_TIMEOUT = 4000;

var adUnits = [
{
code: '/19968336/header-bid-tag-0',
mediaTypes: {
banner: {
sizes: div_1_sizes
}
},
bids: [{
bidder: 'appnexus',
params: {
placementId: 27445767
}
}]
}
];

// ======== DO NOT EDIT BELOW THIS LINE =========== //
var googletag = googletag || {};
googletag.cmd = googletag.cmd || [];
googletag.cmd.push(function() {
googletag.pubads().disableInitialLoad();
});

var pbjs = pbjs || {};
pbjs.que = pbjs.que || [];

pbjs.que.push(function() {
pbjs.addAdUnits(adUnits);
pbjs.requestBids({
bidsBackHandler: initAdserver,
timeout: PREBID_TIMEOUT
});
});

function initAdserver() {
if (pbjs.initAdserverSet) return;
pbjs.initAdserverSet = true;
googletag.cmd.push(function() {
pbjs.que.push(function() {
pbjs.setTargetingForGPTAsync();
googletag.pubads().refresh();
});
});
}


// in case PBJS doesn't load
setTimeout(function() {
initAdserver();
}, FAILSAFE_TIMEOUT);

googletag.cmd.push(function() {
googletag.defineSlot('/19968336/header-bid-tag-0', div_1_sizes, 'div-1').addService(googletag.pubads());
googletag.pubads().enableSingleRequest();
googletag.enableServices();
});

</script>

<article>
<p>
Module will add key/value pairs in ad calls.
Check out for captify_segments key in the payload sent to Xandr to endpoint https://ib.adnxs.com/ut/v3/prebid : keywords.key[captify_segments] should have an array of string as value.
This array will have Xandr RTSS segment ids.
</p>
</article>
<h2>Basic Prebid.js Example with CaptifyRTD </h2>
<h5>Div-1</h5>
<div id='div-1'>
<script type='text/javascript'>
googletag.cmd.push(function() {
googletag.display('div-1');
});

</script>
</div>

</body>
</html>
Loading

0 comments on commit 2a92881

Please sign in to comment.