Merge pull request #1015 from wallabag/savewithtags

Savewithtags
This commit is contained in:
Thomas Citharel 2015-02-10 22:23:48 +01:00
commit d7d88631e1
7 changed files with 33 additions and 1 deletions

View file

@ -11,6 +11,8 @@
$errors = array();
$successes = array();
$final = false;
require_once('install_functions.php');
if (isset($_GET['clean'])) {
@ -49,7 +51,6 @@ else if (isset($_POST['install'])) {
$errors[] = 'You must install twig before.';
} else {
$continue = true;
$final = false;
$salt = generate_salt();
$content = file_get_contents('inc/poche/config.inc.default.php');

View file

@ -4,6 +4,8 @@ $.fn.ready(function() {
$bagitForm = $('#bagit-form'),
$bagitFormForm = $('#bagit-form-form');
$("#tags2add").hide();
/* ==========================================================================
bag it link and close button
========================================================================== */
@ -78,6 +80,14 @@ $.fn.ready(function() {
event.preventDefault();
});
$('#showtaginput').click(function(){
$('#tags2add').toggle();
$('#plainurl').toggle();
$('#showtaginput').toggleClass('icon-tags');
$('#showtaginput').toggleClass('icon-check');
});
/* ==========================================================================
Keyboard gestion
========================================================================== */

View file

@ -4,6 +4,10 @@
<a href="javascript: void(null);" id="bagit-form-close" class="close-button--popup close-button">&times;</a>
<input type="hidden" name="autoclose" value="1" />
<input required placeholder="example.com/article" class="addurl" id="plainurl" name="plainurl" type="url" />
<div style="display:inline-block;cursor: pointer;" title="{% trans "Edit tags" %}" id="showtaginput" class="tool icon icon-tags">
<span>Add tags</span>
</div>
<input placeholder="tags, with commas" class="addurl" id="tags2add" name="tags" type="text"/>
<span id="add-link-result"></span>
<input type="submit" value="{% trans "save link!" %}" />
</form>

View file

@ -745,6 +745,9 @@ a.add-to-wallabag-link-after:after {
.icon-evernote:before {
content: "\e603";
}
.icon-tags:before {
content: "\e936";
}
/* .icon-image class, for image-based icons

View file

@ -2,6 +2,10 @@
<a href="javascript: void(null);" id="bagit-form-close">&nbsp;</a>
<form method="get" action="index.php" id="bagit-form-form">
<input required placeholder="example.com/article" class="addurl" id="plainurl" name="plainurl" type="url" />
<div style="display:inline-block;cursor: pointer;" title="{% trans "Edit tags" %}" id="showtaginput" class="edit-tags">
<span id="showtaginput">Add tags</span>
</div>
<input placeholder="tags, with commas" class="addurl" id="tags2add" name="tags" type="text"/>
<input type="submit" value="{% trans "save link!" %}" />
<div id="add-link-result"></div>
</form>

View file

@ -75,3 +75,13 @@ a.print span {
a.reload span {
background-image: url('../img/default/reload.png');
}
.edit-tags span {
background-image: url('../img/default/tags.png');
display: inline-block;
width: 16px;
height: 16px;
/* Hide textual content */
overflow: hidden;
text-align: left;
text-indent: -9999px;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 332 B