This repository has been archived by the owner on Jan 17, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 128
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #5247, put shutdown placeholder page in place
This uses /hosting-shutdown, to try to make it clear that only the server is going away, not the other aspects of the product. The text isn't localized because it isn't written yet, but localization routines are commented-out in the code.
- Loading branch information
Showing
5 changed files
with
71 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
exports.createModel = function(req) { | ||
return { | ||
title: "shutdown" /* req.getText("shutdownPageTitle") */, | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
const { Page } = require("../../reactruntime"); | ||
const viewModule = require("./view"); | ||
|
||
exports.page = new Page({ | ||
dir: __dirname, | ||
viewModule, | ||
noBrowserJavascript: true, | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
const reactrender = require("../../reactrender"); | ||
|
||
exports.app = function(req, res) { | ||
const page = require("./page").page; | ||
reactrender.render(req, res, page); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
const reactruntime = require("../../reactruntime"); | ||
const { Footer } = require("../../footer-view.js"); | ||
// const { Localized } = require("fluent-react/compat"); | ||
const React = require("react"); | ||
const PropTypes = require("prop-types"); | ||
const { Header } = require("../../header.js"); | ||
|
||
class Head extends React.Component { | ||
render() { | ||
return ( | ||
<reactruntime.HeadTemplate {...this.props}> | ||
<link rel="stylesheet" href={this.props.staticLink("/static/css/shot-index.css")} /> | ||
</reactruntime.HeadTemplate> | ||
); | ||
} | ||
} | ||
|
||
Head.propTypes = { | ||
staticLink: PropTypes.func, | ||
}; | ||
|
||
class Body extends React.Component { | ||
|
||
render() { | ||
return ( | ||
<reactruntime.BodyTemplate {...this.props}> | ||
<div className="column-space full-height"> | ||
<Header hasLogo={true} hasFxa={this.props.hasFxa} /> | ||
<div id="shot-index" className="flex-1"> | ||
<div className="no-shots" key="no-shots-found"> | ||
{ /* <Localized id="shutdownPageIntro"> */ } | ||
<h1>Hosting shutdown notice.</h1> | ||
{ /* </Localized> */ } | ||
{ /* <Localized id="shutdownPageDescription"> */ } | ||
<p>We will be discontinuing hosted screenshots. You will still be able to download and copy screenshots in Firefox.</p> | ||
{ /* </Localized> */ } | ||
</div> | ||
</div> | ||
<Footer {...this.props} /> | ||
</div> | ||
</reactruntime.BodyTemplate> | ||
); | ||
} | ||
} | ||
|
||
Body.propTypes = { | ||
}; | ||
|
||
exports.HeadFactory = React.createFactory(Head); | ||
exports.BodyFactory = React.createFactory(Body); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters