Compare commits

...

6 commits

Author SHA1 Message Date
28670096c8 release: 2020-12-18-5 2020-12-18 14:40:53 +05:00
f24a751f50 release: 2020-12-18-4 2020-12-18 14:36:28 +05:00
62ce3c4cd6 release: 2020-12-18-3 2020-12-18 14:33:01 +05:00
e031a519fd release: 2020-12-18-2 2020-12-18 14:28:25 +05:00
64ea49334e release: 2020-12-18-1 2020-12-18 14:14:55 +05:00
062779c4b3 release: 2020-12-18 2020-12-18 13:51:02 +05:00
37 changed files with 188 additions and 7 deletions

1
docs/200.html Normal file
View file

@ -0,0 +1 @@
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><title>huge-link</title><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Fira+Code&amp;family=Open+Sans+Condensed:wght@700&amp;family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&amp;display=swap"><link rel="manifest" href="/huge-link/manifest.json"><meta name="theme-color" content="#333333"><style>html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}html{font:112.5%/1.5 Open Sans,sans-serif;box-sizing:border-box;overflow-y:scroll}*{box-sizing:inherit}body{color:rgba(0,0,0,.8);font-family:Open Sans,sans-serif;font-weight:400;word-wrap:break-word;-webkit-font-kerning:normal;font-kerning:normal;-ms-font-feature-settings:"kern","liga","clig","calt";-webkit-font-feature-settings:"kern","liga","clig","calt";font-feature-settings:"kern","liga","clig","calt"}noscript{padding:0;margin:0 0 1.5rem}</style><link href="/huge-link/bundle.47ed9.css" rel="stylesheet" media="only x" onload="this.media='all'"><noscript><link rel="stylesheet" href="/huge-link/bundle.47ed9.css"></noscript></head><body><script type="__PREACT_CLI_DATA__">%7B%22preRenderData%22:%7B%22url%22:%22/200.html%22%7D%7D</script><script nomodule="">!function(){var e=document,t=e.createElement("script");if(!("noModule"in t)&&"onbeforeload"in t){var n=!1;e.addEventListener("beforeload",function(e){if(e.target===t)n=!0;else if(!e.target.hasAttribute("nomodule")||!n)return;e.preventDefault()},!0),t.type="module",t.src=".",e.head.appendChild(t),t.remove()}}();</script><script crossorigin="anonymous" src="/huge-link/bundle.ba53f.esm.js" type="module"></script><script nomodule="" src="/huge-link/polyfills.dd476.js"></script><script nomodule="" defer="defer" src="/huge-link/bundle.25769.js"></script></body></html>

1
docs/404.html Normal file
View file

@ -0,0 +1 @@
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><title>huge-link</title><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Fira+Code&amp;family=Open+Sans+Condensed:wght@700&amp;family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&amp;display=swap"><link rel="manifest" href="/huge-link/manifest.json"><meta name="theme-color" content="#333333"><style>html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}main{display:block}html{font:112.5%/1.5 Open Sans,sans-serif;box-sizing:border-box;overflow-y:scroll}*{box-sizing:inherit}body{color:rgba(0,0,0,.8);font-family:Open Sans,sans-serif;font-weight:400;word-wrap:break-word;-webkit-font-kerning:normal;font-kerning:normal;-ms-font-feature-settings:"kern","liga","clig","calt";-webkit-font-feature-settings:"kern","liga","clig","calt";font-feature-settings:"kern","liga","clig","calt"}noscript{padding:0;margin:0 0 1.5rem}main{box-sizing:content-box;max-width:45rem;padding:3% 5%}</style><link href="/huge-link/bundle.47ed9.css" rel="stylesheet" media="only x" onload="this.media='all'"><noscript><link rel="stylesheet" href="/huge-link/bundle.47ed9.css"></noscript></head><body><main></main><script type="__PREACT_CLI_DATA__">%7B%22preRenderData%22:%7B%22url%22:%22/%22%7D%7D</script><script nomodule="">!function(){var e=document,t=e.createElement("script");if(!("noModule"in t)&&"onbeforeload"in t){var n=!1;e.addEventListener("beforeload",function(e){if(e.target===t)n=!0;else if(!e.target.hasAttribute("nomodule")||!n)return;e.preventDefault()},!0),t.type="module",t.src=".",e.head.appendChild(t),t.remove()}}();</script><script crossorigin="anonymous" src="/huge-link/bundle.ba53f.esm.js" type="module"></script><script nomodule="" src="/huge-link/polyfills.dd476.js"></script><script nomodule="" defer="defer" src="/huge-link/bundle.25769.js"></script></body></html>

2
docs/bundle.25769.js Normal file

File diff suppressed because one or more lines are too long

1
docs/bundle.25769.js.map Normal file

File diff suppressed because one or more lines are too long

1
docs/bundle.47ed9.css Normal file

File diff suppressed because one or more lines are too long

2
docs/bundle.ba53f.esm.js Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

1
docs/index.html Normal file
View file

@ -0,0 +1 @@
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><title>huge-link</title><meta name="viewport" content="width=device-width,initial-scale=1"><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Fira+Code&amp;family=Open+Sans+Condensed:wght@700&amp;family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&amp;display=swap"><link rel="manifest" href="/huge-link/manifest.json"><meta name="theme-color" content="#333333"><style>html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}main{display:block}html{font:112.5%/1.5 Open Sans,sans-serif;box-sizing:border-box;overflow-y:scroll}*{box-sizing:inherit}body{color:rgba(0,0,0,.8);font-family:Open Sans,sans-serif;font-weight:400;word-wrap:break-word;-webkit-font-kerning:normal;font-kerning:normal;-ms-font-feature-settings:"kern","liga","clig","calt";-webkit-font-feature-settings:"kern","liga","clig","calt";font-feature-settings:"kern","liga","clig","calt"}noscript{padding:0;margin:0 0 1.5rem}main{box-sizing:content-box;max-width:45rem;padding:3% 5%}</style><link href="/huge-link/bundle.47ed9.css" rel="stylesheet" media="only x" onload="this.media='all'"><noscript><link rel="stylesheet" href="/huge-link/bundle.47ed9.css"></noscript></head><body><main></main><script type="__PREACT_CLI_DATA__">%7B%22preRenderData%22:%7B%22url%22:%22/%22%7D%7D</script><script nomodule="">!function(){var e=document,t=e.createElement("script");if(!("noModule"in t)&&"onbeforeload"in t){var n=!1;e.addEventListener("beforeload",function(e){if(e.target===t)n=!0;else if(!e.target.hasAttribute("nomodule")||!n)return;e.preventDefault()},!0),t.type="module",t.src=".",e.head.appendChild(t),t.remove()}}();</script><script crossorigin="anonymous" src="/huge-link/bundle.ba53f.esm.js" type="module"></script><script nomodule="" src="/huge-link/polyfills.dd476.js"></script><script nomodule="" defer="defer" src="/huge-link/bundle.25769.js"></script></body></html>

10
docs/manifest.json Normal file
View file

@ -0,0 +1,10 @@
{
"name": "huge-link",
"short_name": "huge-link",
"start_url": "/huge-link/",
"display": "standalone",
"orientation": "portrait",
"background_color": "#fff",
"theme_color": "#333333"
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
docs/polyfills.dd476.js Normal file

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
{"url":"/"}

1
docs/push-manifest.json Normal file
View file

@ -0,0 +1 @@
{"/":{"bundle.47ed9.css":{"type":"style","weight":1},"bundle.ba53f.esm.js":{"type":"script","weight":1}},"/editor":{"bundle.47ed9.css":{"type":"style","weight":1},"bundle.ba53f.esm.js":{"type":"script","weight":1},"route-editor.chunk.6c9ac.esm.js":{"type":"script","weight":0.9},"route-editor.chunk.e8d99.css":{"type":"style","weight":0.9}},"/post":{"bundle.47ed9.css":{"type":"style","weight":1},"bundle.ba53f.esm.js":{"type":"script","weight":1},"route-post.chunk.95b49.esm.js":{"type":"script","weight":0.9}}}

View file

@ -0,0 +1,2 @@
(window.webpackJsonp=window.webpackJsonp||[]).push([[2],{TqeA:function(t,e,n){"use strict";n.r(e);var r=n("hosL"),o=n("ox/y"),a=n("tP7B"),i=n.n(a);e.default=({markdown:t,setMarkdown:e})=>Object(r.h)("section",null,Object(r.h)("h1",null,"Huge link"),Object(r.h)("p",null,"A minimalist serverless publishing tool that allows you to create markdown posts and push them to the Web by sharing the link."),Object(r.h)("textarea",{class:i.a.textarea,placeholder:"Write a post using markdown and click Preview",onInput:({target:t})=>e(t.value)},t),Object(r.h)("nav",null,Object(r.h)(o.Link,{href:"/huge-link/preview"},"Preview")))},"ox/y":function(t,e,n){"use strict";function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}Object.defineProperty(e,"__esModule",{value:!0}),e.Link=e.Match=void 0;var o=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},a=n("hosL"),i=n("Y3FI"),s=e.Match=function(t){function e(){for(var e,n,o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return e=n=r(this,t.call.apply(t,[this].concat(a))),n.update=function(t){n.nextUrl=t,n.setState({})},r(n,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.componentDidMount=function(){i.subscribers.push(this.update)},e.prototype.componentWillUnmount=function(){i.subscribers.splice(i.subscribers.indexOf(this.update)>>>0,1)},e.prototype.render=function(t){var e=this.nextUrl||(0,i.getCurrentUrl)(),n=e.replace(/\?.+$/,"");return this.nextUrl=null,t.children({url:e,path:n,matches:!1!==(0,i.exec)(n,t.path,{})})},e}(a.Component),c=function(t){var e=t.activeClassName,n=t.path,r=function(t,e){var n={};for(var r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}(t,["activeClassName","path"]);return(0,a.h)(s,{path:n||r.href},(function(t){return(0,a.h)(i.Link,o({},r,{class:[r.class||r.className,t.matches&&e].filter(Boolean).join(" ")}))}))};e.Link=c,e.default=s,s.Link=c},tP7B:function(t){t.exports={textarea:"textarea__1UKFm"}}}]);
//# sourceMappingURL=route-editor.chunk.6c9ac.esm.js.map

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1 @@
.textarea__1UKFm{font-family:Fira Code,monospace;display:block;resize:vertical;min-height:50vh;width:100%;box-sizing:border-box;outline:none;border:4px solid rgba(0,0,0,.7);padding:.7em 1em;margin-bottom:1.5em}

View file

@ -0,0 +1,2 @@
(window.webpackJsonp=window.webpackJsonp||[]).push([[2],{TqeA:function(t,e,n){"use strict";n.r(e);var r=n("hosL"),o=n("ox/y"),a=n("tP7B"),i=n.n(a);e.default=function(t){var e=t.markdown,n=t.setMarkdown;return Object(r.h)("section",null,Object(r.h)("h1",null,"Huge link"),Object(r.h)("p",null,"A minimalist serverless publishing tool that allows you to create markdown posts and push them to the Web by sharing the link."),Object(r.h)("textarea",{class:i.a.textarea,placeholder:"Write a post using markdown and click Preview",onInput:function(t){return n(t.target.value)}},e),Object(r.h)("nav",null,Object(r.h)(o.Link,{href:"/huge-link/preview"},"Preview")))}},"ox/y":function(t,e,n){"use strict";function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}Object.defineProperty(e,"__esModule",{value:!0}),e.Link=e.Match=void 0;var o=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},a=n("hosL"),i=n("Y3FI"),c=e.Match=function(t){function e(){for(var e,n,o=arguments.length,a=Array(o),i=0;i<o;i++)a[i]=arguments[i];return e=n=r(this,t.call.apply(t,[this].concat(a))),n.update=function(t){n.nextUrl=t,n.setState({})},r(n,e)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.componentDidMount=function(){i.subscribers.push(this.update)},e.prototype.componentWillUnmount=function(){i.subscribers.splice(i.subscribers.indexOf(this.update)>>>0,1)},e.prototype.render=function(t){var e=this.nextUrl||(0,i.getCurrentUrl)(),n=e.replace(/\?.+$/,"");return this.nextUrl=null,t.children({url:e,path:n,matches:!1!==(0,i.exec)(n,t.path,{})})},e}(a.Component),s=function(t){var e=t.activeClassName,n=t.path,r=function(t,e){var n={};for(var r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}(t,["activeClassName","path"]);return(0,a.h)(c,{path:n||r.href},(function(t){return(0,a.h)(i.Link,o({},r,{class:[r.class||r.className,t.matches&&e].filter(Boolean).join(" ")}))}))};e.Link=s,e.default=c,c.Link=s},tP7B:function(t){t.exports={textarea:"textarea__1UKFm"}}}]);
//# sourceMappingURL=route-editor.chunk.fda69.js.map

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

2
docs/sw-esm.js Normal file

File diff suppressed because one or more lines are too long

1
docs/sw-esm.js.map Normal file

File diff suppressed because one or more lines are too long

2
docs/sw.js Normal file

File diff suppressed because one or more lines are too long

1
docs/sw.js.map Normal file

File diff suppressed because one or more lines are too long

3
preact.config.js Normal file
View file

@ -0,0 +1,3 @@
export default (config) => {
config.output.publicPath = '/huge-link/';
};

View file

@ -14,16 +14,16 @@ const App = () => {
return (<main> return (<main>
<Router> <Router>
<Editor <Editor
path='/' path='/huge-link/'
markdown={ markdown } markdown={ markdown }
{ ...{setMarkdown} } /> { ...{setMarkdown} } />
<Post <Post
path='/preview/' path='/huge-link/preview/'
mode='preview' mode='preview'
payload={ markdown } payload={ markdown }
{ ...{setMarkdown} } /> { ...{setMarkdown} } />
<Post <Post
path='/p/:payload' path='/huge-link/p/:payload'
mode='post' mode='post'
{ ...{setMarkdown} } /> { ...{setMarkdown} } />
</Router> </Router>

10
src/manifest.json Normal file
View file

@ -0,0 +1,10 @@
{
"name": "huge-link",
"short_name": "huge-link",
"start_url": "/huge-link/",
"display": "standalone",
"orientation": "portrait",
"background_color": "#fff",
"theme_color": "#333333"
}

View file

@ -19,7 +19,7 @@ const Editor = ({markdown, setMarkdown}) => (
</textarea> </textarea>
<nav> <nav>
<Link href='/preview'> <Link href='/huge-link/preview'>
Preview Preview
</Link> </Link>
</nav> </nav>

View file

@ -13,10 +13,10 @@ const ident = _ => _
const previewContorls = content => ( const previewContorls = content => (
<header><nav> <header><nav>
<ul> <ul>
<li><Link href='/'> <li><Link href='/huge-link/'>
Edit Edit
</Link></li> </Link></li>
<li><Link href={ `/p/${content}` }> <li><Link href={ `/huge-link/p/${content}` }>
Publish Publish
</Link></li> </Link></li>
</ul> </ul>
@ -42,7 +42,7 @@ const Post = ({mode, payload, setMarkdown}) => {
</ReactMarkdown> </ReactMarkdown>
</article> </article>
<Link href='/'> <Link href='/huge-link/'>
Edit post Edit post
</Link> </Link>
</section>) </section>)