summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
Diffstat (limited to 'views')
-rw-r--r--views/docs/syndication.php8
-rw-r--r--views/new-post.php13
-rw-r--r--views/privacy.php2
-rw-r--r--views/settings.php30
-rw-r--r--views/twitter.php83
5 files changed, 3 insertions, 133 deletions
diff --git a/views/docs/syndication.php b/views/docs/syndication.php
index 3452173..aaa695d 100644
--- a/views/docs/syndication.php
+++ b/views/docs/syndication.php
@@ -18,10 +18,6 @@ Content-type: application/json
{
"syndicate-to": [
{
- "uid": "https://twitter.com/aaronpk",
- "name": "twitter.com/aaronpk"
- },
- {
"uid": "https://news.indieweb.org/en",
"name": "IndieNews"
}
@@ -29,10 +25,10 @@ Content-type: application/json
}
</code></pre>
- <p>The specific values of names and uids are up to your Micropub endpoint, but a good convention is to use the domain name of the service (e.g. https://twitter.com), or domain name and username (e.g. https://twitter.com/aaronpk) for the uid, and a friendly name like "Twitter" or "twitter.com/aaronpk" as the name.</p>
+ <p>The specific values of names and uids are up to your Micropub endpoint, but a good convention is to use the domain name of the service (e.g. https://news.indieweb.org), or domain name and username (e.g. https://mastodon.social/@aaronpk) for the uid, and a friendly name like "IndieNews" or "mastodon.social/@aaronpk" as the name.</p>
<p>Quill will check for your supported syndication targets when you sign in, but there is also a link on the new post screen to manually re-check if you'd like.</p>
- <p>When you create a post and tap one of the syndication options, the value of <code>uid</code> is sent in a property called <code>mp-syndicate-to</code>, which instructs your endpoint to syndicate to that target. Note that Quill doesn't know whether the target is Twitter, Facebook, or something else, and doesn't talk to the service directly. It's just an instruction to your endpoint to syndicate to that destination.</p>
+ <p>When you create a post and tap one of the syndication options, the value of <code>uid</code> is sent in a property called <code>mp-syndicate-to</code>, which instructs your endpoint to syndicate to that target. Note that Quill doesn't know whether the target is Mastodon, IndieNews, or something else, and doesn't talk to the service directly. It's just an instruction to your endpoint to syndicate to that destination.</p>
</div>
diff --git a/views/new-post.php b/views/new-post.php
index ea8eb78..2190752 100644
--- a/views/new-post.php
+++ b/views/new-post.php
@@ -622,7 +622,7 @@ $(function(){
$("#note_content").on('change keyup', function(e){
var text = $("#note_content").val();
var tweet_length = tw_text_proxy(text).length;
- var tweet_check = tw_length_check(text, 280, "<?= $this->user->twitter_username ?>");
+ var tweet_check = tw_length_check(text, 280, "");
var remaining = 280 - tweet_length;
$("#note_content_remaining span").text(remaining);
$("#note_content_remaining").removeClass("pcheck200 pcheck206 pcheck207 pcheck208 pcheck413");
@@ -683,17 +683,6 @@ $(function(){
// }
// $("#note_category").val(category.join(", "));
- /*
- // stop auto-populating usernames in replies, since Twitter no longer requires it
- if($("#note_content").val() == "" && data.mentions) {
- var mentions = '';
- for(var i in data.mentions) {
- mentions += '@'+data.mentions[i]+' ';
- }
- $("#note_content").val(mentions);
- }
- */
-
if(data.entry) {
$(".reply-context .content").text(data.entry.content.text);
if(data.entry.name) {
diff --git a/views/privacy.php b/views/privacy.php
index 40ce393..c870f99 100644
--- a/views/privacy.php
+++ b/views/privacy.php
@@ -7,6 +7,4 @@
<p>Quill does not store your posts itself, but does cache the last response from your website and provides it to you for debugging purposes.</p>
- <p>If you connect Quill to your Twitter account, Quill can favorite tweets on your behalf when you favorite a Twitter URL. Quill will never post anything to your accounts without an explicit action on your part.</p>
-
</div>
diff --git a/views/settings.php b/views/settings.php
index f51e69c..a479924 100644
--- a/views/settings.php
+++ b/views/settings.php
@@ -123,13 +123,6 @@
- <?php if(!Config::$twitterClientID): ?>
- <h3>Twitter</h3>
- <p>Connecting a Twitter account will automatically "favorite" and "retweet" tweets on Twitter when you favorite and retweet a Twitter URL in Quill.</p>
- <input type="button" id="twitter-button" value="Checking" class="btn">
- <?php endif ?>
-
-
<h3>Backwards Compatibility</h3>
<p>You can customize some of the properties that are sent in the Micropub request to work with older software.</p>
@@ -168,29 +161,6 @@
<script>
$(function(){
- <?php if(!Config::$twitterClientID): ?>
- $.getJSON("/auth/twitter", function(data){
- // Check if we're already authorized with twitter
- if(data && data.result == 'ok') {
- $("#twitter-button").val("Connected").addClass("btn-success");
- } else if(data && data.url) {
- $("#twitter-button").val("Sign In").data("url", data.url).addClass("btn-warning");
- } else {
- $("#twitter-button").val("Error").addClass("btn-danger");
- }
- });
-
- $("#twitter-button").click(function(){
- if($(this).data('url')) {
- window.location = $(this).data('url');
- } else {
- $.getJSON("/auth/twitter", {login: 1}, function(data){
- window.location = data.url;
- });
- }
- });
- <?php endif ?>
-
$("#send-html-content").click(function(){
var enabled = $(this).attr("checked") == "checked";
$.post("/settings/save", {
diff --git a/views/twitter.php b/views/twitter.php
deleted file mode 100644
index d9682e8..0000000
--- a/views/twitter.php
+++ /dev/null
@@ -1,83 +0,0 @@
- <div class="narrow">
- <?= partial('partials/header') ?>
-
- <div style="clear: both;" class="notice-pad">
- <div class="alert alert-success hidden" id="test_success"><strong>Success! </strong><a href="" id="post_href">View your post</a></div>
- <div class="alert alert-danger hidden" id="test_error"><strong>Something went wrong!</strong><br>Your Micropub endpoint indicated that something went wrong creating the post.</div>
- </div>
-
- <form role="form" style="margin-top: 20px;" id="note_form">
-
- <div class="form-group">
- <label for="tweet_url">Tweet to Import</label>
- <input type="text" id="tweet_url" value="<?= $this->tweet_url ?>" class="form-control">
- </div>
-
-
- <div style="float: right; margin-top: 6px;">
- <button class="btn btn-success" id="btn_post">Import</button>
- </div>
-
- <div style="float: right; margin-top: 6px; margin-right: 6px;">
- <button class="btn btn-default" id="btn_preview">Preview</button>
- </div>
-
- </form>
-
- <div style="clear: both;"></div>
-
- <div id="preview_data" class="hidden">
- <pre></pre>
- </div>
-
- </div>
-
-<script>
-$(function(){
-
- $("#btn_preview").click(function(e){
-
- $("#btn_preview").addClass("loading disabled");
-
- $.post("/twitter/preview", {
- tweet_url: $("#tweet_url").val(),
- }, function(response){
- $("#preview_data pre").text(response.json);
- $("#preview_data").removeClass("hidden");
- $("#btn_preview").removeClass("loading disabled");
- });
-
- return false;
- });
-
- $("#btn_post").click(function(){
- $("#btn_post").addClass("loading disabled");
-
- $.post("/twitter", {
- tweet_url: $("#tweet_url").val(),
- }, function(response){
-
- if(response.location != false) {
-
- $("#test_success").removeClass('hidden');
- $("#test_error").addClass('hidden');
- $("#post_href").attr("href", response.location);
- $("#note_form").addClass('hidden');
-
- window.location = response.location;
- } else {
- $("#test_success").addClass('hidden');
- $("#test_error").removeClass('hidden');
- if(response.error_details) {
- $("#test_error").text(response.error_details);
- }
- $("#btn_post").removeClass("loading disabled");
- }
-
- });
- return false;
- });
-
-});
-
-</script>