Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@
document.addEventListener('DOMContentLoaded', function(){
document.getElementById("plaintext").focus();

document.getElementById("plaintext").placeholder = "Enter text here.";

if (matches = /(?:^|\;)invert\=([01])(?:\;|$)/.exec(document.cookie)) {
if (matches[1] === '1') {
document.body.classList.add("invert");
Expand Down Expand Up @@ -163,7 +165,7 @@
</script>
</head>
<body>
<div id="plaintext-wrapper"><textarea id="plaintext" spellcheck="false"></textarea></div>
<div id="plaintext-wrapper"><textarea id="plaintext" spellcheck="false" placeholder="Please enable JavaScript."></textarea></div>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I support the idea, but the canonical way is to use noscript element.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To change placeholder? I would not know how to without using js.

<div id="nav"><span class="nav-default"><a class="nav-left" href="https://github.com/topaz/paste">[github]</a><a class="nav-left" onclick="invert()">[invert colors]</a><a onclick="url_generate('raw')">[generate url]</a><a onclick="url_generate('markdown')">[generate markdown link]</a></span><span class="nav-text-offer"><input id="text-offer-value"/><a onclick="text_offer_copy()">[copy]</a><a onclick="text_offer_cancel()">[cancel]</a></span></div>
</body>
</html>