Commit 5a733859 authored by Aral Balkan's avatar Aral Balkan
Browse files

Renamed companies section to whitelist.

parent 176c60bc
Pipeline #221 skipped
......@@ -199,7 +199,7 @@ class App
home: fs.readFileSync (path.join dataTemplatesDirectory, 'home.html'), 'utf-8'
sites: fs.readFileSync (path.join dataTemplatesDirectory, 'sites/index.html'), 'utf-8'
trackers: fs.readFileSync (path.join dataTemplatesDirectory, 'trackers/index.html'), 'utf-8'
companies: fs.readFileSync (path.join dataTemplatesDirectory, 'companies/index.html'), 'utf-8'
whitelist: fs.readFileSync (path.join dataTemplatesDirectory, 'whitelist/index.html'), 'utf-8'
graph: fs.readFileSync (path.join dataTemplatesDirectory, 'sites/graph.html'), 'utf-8'
table: fs.readFileSync (path.join dataTemplatesDirectory, 'sites/table.html'), 'utf-8'
......@@ -210,7 +210,7 @@ class App
home: fs.readFileSync (path.join siteTemplatesDirectory, 'home.html'), 'utf-8'
sites: fs.readFileSync (path.join siteTemplatesDirectory, 'sites/index.html'), 'utf-8'
trackers: fs.readFileSync (path.join siteTemplatesDirectory, 'trackers/index.html'), 'utf-8'
companies: fs.readFileSync (path.join dataTemplatesDirectory, 'companies/index.html'), 'utf-8'
whitelist: fs.readFileSync (path.join dataTemplatesDirectory, 'whitelist/index.html'), 'utf-8'
graph: fs.readFileSync (path.join siteTemplatesDirectory, 'sites/graph.html'), 'utf-8'
table: fs.readFileSync (path.join siteTemplatesDirectory, 'sites/table.html'), 'utf-8'
......
......@@ -235,7 +235,7 @@ class Blockdown
indexContent =
sites: ''
trackers: ''
companies: ''
whitelist: ''
(globAsync "#{contentPath}/**/*.md", {})
.map (file) =>
......@@ -247,7 +247,7 @@ class Blockdown
fileComponents = file.split('/')
categoryIndex = ('sites' in fileComponents and fileComponents.indexOf('sites')) or ('trackers' in fileComponents and fileComponents.indexOf('trackers')) or ('companies' in fileComponents and fileComponents.indexOf('companies'))
categoryIndex = ('sites' in fileComponents and fileComponents.indexOf('sites')) or ('trackers' in fileComponents and fileComponents.indexOf('trackers')) or ('whitelist' in fileComponents and fileComponents.indexOf('whitelist'))
category = if categoryIndex then fileComponents[categoryIndex] else 'none'
pageDomain = if categoryIndex then fileComponents[categoryIndex+1] else 'none'
......@@ -326,8 +326,8 @@ class Blockdown
# Render /trackers index.
@renderPage 'trackers', dataPath, '/trackers/index.html', {list: indexContent.trackers}
.then =>
# Render /companies index.
@renderPage 'companies', dataPath, '/companies/index.html', {list: indexContent.companies}
# Render /whitelist index.
@renderPage 'whitelist', dataPath, '/whitelist/index.html', {list: indexContent.whitelist}
.then =>
# Render home page.
homePageStatistics = GlobalStatistics.homePageStatistics()
......@@ -363,7 +363,7 @@ class Blockdown
{ class: 'home', link: '/', label: 'Home', selected: false}
{ class: 'sites', link: '/sites', label: 'Sites', selected: false}
{ class: 'trackers', link: '/trackers', label: 'Trackers', selected: false}
{ class: 'companies', link: '/companies', label: 'Companies', selected: false}
{ class: 'whitelist', link: '/whitelist', label: 'Whitelist', selected: false}
]
for i in [0...navigationList.length]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment