{% extends "home_base.html" %}
{% load seahub_tags i18n %}

{% block sub_title %}{% trans "Libraries" %} - {% endblock %}

{% block extra_style %}
{% if need_guide %}
<style type="text/css">
#guide-for-new {
    padding: 0 20px;
    width: 450px;
}
#guide-for-new .icon-lightbulb {
    font-size:6em;
    color:#feac74;
}
#guide-for-new .txt {
    margin-left:6.4em;
}
</style>
{% endif %}
{% endblock %}

{% block cur_my_lib %}tab-cur{% endblock %}

{% block right_panel %}
<!--mine shared stared -->
{% include "snippets/my_owned_repos.html" %}

{% url 'share_repo' as repo_share_url %}
{% with post_url=repo_share_url groups=joined_groups %}
{% include "snippets/repo_share_form.html" %}
{% endwith %}

{% include "snippets/repo_create_form.html" %}

{% if need_guide %}
<div id="guide-for-new" class="hide">
    <span class="icon-lightbulb fleft"></span>
    <div class="txt">
        <h3>{% trans "Welcome to Seafile!" %}</h3>
        <p>{% trans "Seafile organizes files into libraries. Each library can be synced and shared separately. We have created a personal library for you. You can create more libraries later." %}</p>
        <button class="simplemodal-close" style="margin:8px 0 0 0;">{% trans "Close" %}</button>
    </div>
</div>
{% endif %}
{% endblock %}

{% block extra_script %}{{block.super}}
{% include 'snippets/repo_create_js_files.html' %}
<script type="text/javascript">
{% include "snippets/myhome_extra_script.html" with groups=autocomp_groups %}

{% include "snippets/repo_create_js.html" with post_url=repo_create_url %}

{% if need_guide %}
$(function() {$('#guide-for-new').modal({appendTo: '#main', focus:false});});
{% endif %}
</script>
{% endblock %}
