Commit 991c9189 authored by Julian Foad's avatar Julian Foad 💬
Browse files

Save old work: j-old-work-2020

parent 2da720b8
img/matrix-to.png

7.51 KB

img/matrix-uri.png

7.6 KB

......@@ -7,6 +7,6 @@
</head>
<body>
<div id="site"></div>
<script src="bundle.js"></script>
<script src="out/index.js"></script>
</body>
</html>
{
"name": "matrix-to",
"version": "0.0.1",
"name": "jf-matrix-to",
"version": "0.5.0",
"description": "Stateless privacy-protecting URL redirecting service for the Matrix.org ecosystem",
"main": "src/index.js",
"scripts": {
"build": "cross-env NODE_ENV=production webpack -p src/index.js bundle.js",
"start": "webpack -w src/index.js bundle.js",
"babel-debug": "babel src --out-dir out --presets=@babel/env --presets=@babel/react",
"build": "webpack -p",
"build-debug": "webpack -d",
"start": "webpack -d -w",
"deploy": "cross-env rsync -irt --links --safe-links --delete-delay --exclude='.*.swp' index.html site.css bundle.js img $HOME/Sites/matrix/matrix-to/www/",
"deploy-debug": "cross-env rsync -irt --links --safe-links --delete-delay --exclude='.*.swp' index.html site.css img out node_modules $HOME/Sites/matrix/matrix-to/www/",
"test": "echo \"Error: no test specified\" && exit 1",
"clean": "rm bundle.js bundle.js.map"
},
"repository": {
"type": "git",
"url": "git+https://github.com/matrix-org/matrix.to.git"
"url": "git+https://gitlab.com/julianfoad/matrix.to.git"
},
"author": "Matrix.org",
"author": "Matrix.org; Julian Foad",
"license": "Apache-2.0",
"bugs": {
"url": "https://github.com/matrix-org/matrix.to/issues"
"url": "https://gitlab.com/julianfoad/matrix.to/issues"
},
"homepage": "https://matrix.to",
"dependencies": {
......@@ -24,12 +28,16 @@
"react-dom": "^15.0.2"
},
"devDependencies": {
"babel-core": "^6.8.0",
"babel-loader": "^6.2.4",
"babel-preset-es2015": "^6.6.0",
"babel-preset-react": "^6.5.0",
"@babel/cli": "^7.8.4",
"@babel/core": "^7.9.0",
"@babel/preset-env": "^7.9.0",
"@babel/preset-react": "^7.9.4",
"babel-core": "^7.0.0-bridge.0",
"babel-loader": "^8.1.0",
"cross-env": "^5.0.5",
"source-map-loader": "^0.1.5",
"webpack": "^1.13.0"
"webpack": "^4.42.1",
"webpack-cli": "^1.5.3",
"webpack-dev-server": "^3.10.3"
}
}
......@@ -25,9 +25,17 @@ body {
}
.mxt_Header {
text-align: center;
}
.mxt_Footer {
.mxt_Header_logo {
padding-top: 50px;
padding-bottom: 50px;
max-width: 50%;
height: 4em;
width: auto;
display: block;
margin: auto;
}
.mxt_HomePage {
......@@ -35,13 +43,6 @@ body {
max-width: 1000px;
}
.mxt_HomePage_logo {
padding-top: 50px;
padding-bottom: 50px;
display: block;
margin: auto;
}
.mxt_HomePage_cta {
padding: 50px;
padding-bottom: 30px;
......@@ -57,16 +58,19 @@ body {
.mxt_HomePage_inputBox_prompt {
display: inline;
border: 1px solid;
border-radius: 5px;
font-size: 24px;
font-family: "Open Sans", Helvetica, Arial, sans-serif;
margin-right: 5px;
padding: 6px 14px 6px 14px;
margin: 5px;
}
.mxt_HomePage_inputBox_button {
display: inline;
border: 0px solid;
border-radius: 5px;
font-size: 20px;
font-size: 24px;
font-family: "Open Sans", Helvetica, Arial, sans-serif;
padding: 7px 14px 7px 14px;
margin: 5px;
......@@ -87,10 +91,13 @@ body {
}
.mxt_HomePage_links {
margin-top: 50px;
}
margin: 2em;
border: 1px solid;
border-radius: 5px;
padding: 1em;
}
.mxt_HomePage_links_intro {
.mxt_HomePage_intro {
font-size: 16px;
}
......@@ -98,18 +105,8 @@ body {
display: table-row;
}
.mxt_HomePage_link_title {
font-size: 12px;
font-weight: bold;
}
.mxt_HomePage_link_logo,
.mxt_HomePage_link_name,
.mxt_HomePage_link_author,
.mxt_HomePage_link_maturity,
.mxt_HomePage_link_link,
.mxt_HomePage_link_instructions,
.mxt_HomePage_link_comments {
.mxt_HomePage_link_instructions {
display: table-cell;
padding: 5px;
}
......@@ -120,34 +117,43 @@ body {
padding-right: 15px;
}
.mxt_HomePage_link_name {
.mxt_HomePage_link_logo img {
height: 4em;
width: auto;
}
.mxt_HomePage_link_author {
}
.mxt_HomePage_link_homepage {
font-size: 12px;
}
.mxt_HomePage_link_maturity {
.mxt_HomePage_info {
margin: 2em;
border: 1px solid;
border-radius: 5px;
padding: 1em;
}
.mxt_HomePage_link_link {
.mxt_HomePage_info details summary {
font-size: 20px;
}
.mxt_HomePage_link_instructions {
.mxt_Footer {
margin-top: 50px;
margin-bottom: 10px;
text-align: center;
font-size: 12px;
}
.mxt_HomePage_link_comments {
.mxt_Footer_about {
margin: 2em;
border: 1px solid;
border-radius: 5px;
padding: 1em;
}
.mxt_HomePage_info {
.mxt_Footer_about details summary {
font-size: 20px;
}
.mxt_Footer {
margin-top: 50px;
margin-bottom: 10px;
text-align: center;
font-size: 12px;
code {
white-space: nowrap;
font-family: monospace, monospace;
border: 1px solid;
padding: 2px;
}
\ No newline at end of file
......@@ -17,12 +17,58 @@ limitations under the License.
import React from 'react'
export default React.createClass({
export default class extends React.Component {
render() {
return (
<div className="mxt_Footer">
Copyright 2016 - 2019 <a href="https://matrix.org">Matrix.org</a>
<div className="mxt_Footer_about">
<details>
<summary>About matrix clients</summary>
<p>
Learn more about Matrix clients at <a href="https://matrix.org/clients/">https://matrix.org/clients/</a>.
</p>
</details>
<details>
<summary>About matrix.to links</summary>
<p>
matrix.to links let users share links to rooms, users or messages in the <a href="https://matrix.org">Matrix.org
</a> ecosystem without being tied to any specific app. This lets users choose their own favourite
Matrix client to participate in conversations rather than being forced to use the same app as
whoever sent the link.
</p>
<p>
Links are designed to be human-friendly, both for reading and constructing, and are
essentially a compatibility step in the journey towards
a ubiquitous <a href="https://github.com/matrix-org/matrix-doc/pull/2312">matrix:// URL scheme</a>.
</p>
</details>
<details>
<summary>About this matrix.to web site</summary>
<p>
Matrix.to is a simple stateless URL redirecting service for matrix.to links.
The service preserves user privacy by not
sharing any information about the links being followed with the Matrix.to server - the
redirection is calculated entirely clientside using JavaScript.
</p>
<p>
To add clients to this list, <a href="https://matrix.to/#/#matrix-dev:matrix.org">please contact us</a> or
send us a pull request <a href="https://github.com/matrix-org/matrix.to">on github</a>!
</p>
<p>
As with all of Matrix, Matrix.to is released as open source under the terms of
the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License v2.0</a> - get the source
from <a href="https://github.com/matrix-org/matrix.to">Github</a>.
</p>
</details>
</div>
<p>
<a href="https://matrix.org">Matrix</a> is an ecosystem for open and interoperable communication.
</p>
<p>
Copyright 2016 - 2019 <a href="https://matrix.org">Matrix.org</a>
</p>
</div>
);
}
})
}
......@@ -17,11 +17,14 @@ limitations under the License.
import React from 'react'
export default React.createClass({
export default class extends React.Component {
render() {
return (
<div className="mxt_Header">
<a href="#">
<img className="mxt_Header_logo" src="img/matrix-logo.svg" width="352" height="150" alt="[matrix]"/>
</a>
</div>
);
}
})
}
This diff is collapsed.
......@@ -21,12 +21,12 @@ import Footer from './Footer'
import HomePage from './HomePage'
export default React.createClass({
export default class extends React.Component {
getInitialState() {
return {
page: <HomePage/>,
}
},
}
render() {
return (
......@@ -37,4 +37,4 @@ export default React.createClass({
</div>
);
}
})
}
var path = require('path');
var webpack = require('webpack');
const path = require('path');
module.exports = {
entry: './src/index.js',
output: {
filename: 'index.js',
path: path.resolve(__dirname, 'out'),
},
module: {
preLoaders: [
{ test: /\.js$/, loader: "source-map-loader" }
],
loaders: [
{ test: /\.json$/, loader: "json" },
{ test: /\.js$/, loader: "babel-loader?presets[]=es2015&presets[]=react", include: path.resolve('./src') },
rules: [
{ test: /\.js$/, loader: "source-map-loader", enforce: "pre" },
{ test: /\.js$/, loader: "babel-loader?presets[]=@babel/env&presets[]=@babel/react", include: path.resolve(__dirname, './src') },
],
},
plugins: [
new webpack.DefinePlugin({
'process.env': {
NODE_ENV: JSON.stringify(process.env.NODE_ENV)
}
}),
],
devtool: 'source-map',
node: {
Buffer: false,
}
};
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