summaryrefslogtreecommitdiffstats
path: root/application/basilisk/base/content/newtab/grid.js
diff options
context:
space:
mode:
authorNew Tobin Paradigm <email@mattatobin.com>2019-05-25 18:31:02 -0400
committerGitHub <noreply@github.com>2019-05-25 18:31:02 -0400
commit63d67703534b8af4b15d9fa53b3a19c6df17b263 (patch)
tree970ccd2c2cb3a6ef0a3e869b8eff06009bf39899 /application/basilisk/base/content/newtab/grid.js
parent104cd501aa42ccb1839be5c5b8338c83dacd97c6 (diff)
parent97477c1e96fded7c40534afa3ad0bfc3980658e3 (diff)
downloadUXP-63d67703534b8af4b15d9fa53b3a19c6df17b263.tar
UXP-63d67703534b8af4b15d9fa53b3a19c6df17b263.tar.gz
UXP-63d67703534b8af4b15d9fa53b3a19c6df17b263.tar.lz
UXP-63d67703534b8af4b15d9fa53b3a19c6df17b263.tar.xz
UXP-63d67703534b8af4b15d9fa53b3a19c6df17b263.zip
Merge pull request #1122 from adeshkp/remove-newtab-basilisk
Remove code for sponsored "enhanced" tiles in NewTab page
Diffstat (limited to 'application/basilisk/base/content/newtab/grid.js')
-rw-r--r--application/basilisk/base/content/newtab/grid.js15
1 files changed, 2 insertions, 13 deletions
diff --git a/application/basilisk/base/content/newtab/grid.js b/application/basilisk/base/content/newtab/grid.js
index b6f98fa17..726150a6c 100644
--- a/application/basilisk/base/content/newtab/grid.js
+++ b/application/basilisk/base/content/newtab/grid.js
@@ -9,7 +9,6 @@
*/
const GRID_BOTTOM_EXTRA = 7; // title's line-height extends 7px past the margin
const GRID_WIDTH_EXTRA = 1; // provide 1px buffer to allow for rounding error
-const SPONSORED_TAG_BUFFER = 2; // 2px buffer to clip off top of sponsored tag
/**
* This singleton represents the grid that contains all sites.
@@ -142,13 +141,9 @@ var gGrid = {
// Create sites.
let numLinks = Math.min(links.length, cells.length);
- let hasHistoryTiles = false;
for (let i = 0; i < numLinks; i++) {
if (links[i]) {
this.createSite(links[i], cells[i]);
- if (links[i].type == "history") {
- hasHistoryTiles = true;
- }
}
}
@@ -157,9 +152,6 @@ var gGrid = {
this._gridDefaultContent.nextSibling.remove();
}
this._node.appendChild(fragment);
-
- document.getElementById("topsites-heading").textContent =
- hasHistoryTiles ? "Your Top Sites" : "Top Sites";
},
/**
@@ -182,18 +174,15 @@ var gGrid = {
// Create the site's inner HTML code.
site.innerHTML =
- '<span class="newtab-sponsored">' + newTabString("sponsored.button") + '</span>' +
'<a class="newtab-link">' +
' <span class="newtab-thumbnail placeholder"/>' +
' <span class="newtab-thumbnail thumbnail"/>' +
- ' <span class="newtab-thumbnail enhanced-content"/>' +
' <span class="newtab-title"/>' +
'</a>' +
'<input type="button" title="' + newTabString("pin") + '"' +
' class="newtab-control newtab-control-pin"/>' +
'<input type="button" title="' + newTabString("block") + '"' +
- ' class="newtab-control newtab-control-block"/>' +
- '<span class="newtab-suggested"/>';
+ ' class="newtab-control newtab-control-block"/>';
this._siteFragment = document.createDocumentFragment();
this._siteFragment.appendChild(site);
@@ -274,6 +263,6 @@ var gGrid = {
this._node.style.maxWidth = gGridPrefs.gridColumns * this._cellWidth +
GRID_WIDTH_EXTRA + "px";
this._node.style.height = this._computeHeight() + "px";
- this._node.style.maxHeight = this._computeHeight(gridRows) - SPONSORED_TAG_BUFFER + "px";
+ this._node.style.maxHeight = this._computeHeight(gridRows) + "px";
}
};