Browse Source

Added sharing options

main
Lakshmi Vyasarajan 14 years ago
parent
commit
5a2fd30a0d
17 changed files with 43 additions and 167 deletions
  1. +0
    -2
      hyde/layouts/basic/content/about.html
  2. +19
    -2
      hyde/layouts/basic/content/media/css/site.css
  3. +22
    -8
      hyde/layouts/basic/layout/blog.j2
  4. +2
    -2
      hyde/layouts/basic/site.yaml
  5. +0
    -22
      hyde/layouts/test/content/404.html
  6. +0
    -7
      hyde/layouts/test/content/about.html
  7. BIN
      hyde/layouts/test/content/apple-touch-icon.png
  8. +0
    -9
      hyde/layouts/test/content/blog/2010/december/merry-christmas.html
  9. +0
    -25
      hyde/layouts/test/content/crossdomain.xml
  10. BIN
      hyde/layouts/test/content/favicon.ico
  11. +0
    -5
      hyde/layouts/test/content/robots.txt
  12. +0
    -4
      hyde/layouts/test/info.yaml
  13. +0
    -57
      hyde/layouts/test/layout/base.html
  14. +0
    -10
      hyde/layouts/test/layout/blog/post.html
  15. +0
    -1
      hyde/layouts/test/layout/root.html
  16. +0
    -4
      hyde/layouts/test/media/css/site.css
  17. +0
    -9
      hyde/layouts/test/site.yaml

+ 0
- 2
hyde/layouts/basic/content/about.html View File

@@ -4,5 +4,3 @@ default_block: main
title: About BASIC
description: The default hyde template
---

Ha Ha

+ 19
- 2
hyde/layouts/basic/content/media/css/site.css View File

@@ -336,8 +336,8 @@ h1 a, h2 a, h3 a{
nav.post_nav{
background-color: #efefef;
position: fixed;
width: 102px;
margin-left: -164px;
width: 124px;
margin-left: -186px;
font-size: 12px;
padding: 12px;
padding-right: 24px;
@@ -375,6 +375,7 @@ a.prev,
a.next{
display: block;
float: left;
margin-bottom: 12px;
}

a.next{ float: right };
@@ -383,8 +384,24 @@ a.backlink:hover, a.prev:hover, a.next:hover{
color: #222;
}

.post_nav a.disabled{
color: #ccc;
}

.post_nav a{
color: #666;
text-decoration: none;
text-shadow: 0px 2px 0px #fff;
}

.post_nav div{
display: block;
float: left;
width: 58px;
overflow: hidden;
margin-left: 4px;
}

#facebook_like{
margin-top: 1px;
}

+ 22
- 8
hyde/layouts/basic/layout/blog.j2 View File

@@ -4,22 +4,36 @@
<article class="post">
<nav class="post_nav">
<a class="backlink" href="{{ content_url(resource.node.url) }}">Back to list</a>
{% if resource.prev_by_time %}
<a class="prev"
<a class="prev{{' disabled' if not resource.prev_by_time }}"
title="{{ resource.prev_by_time.meta.title }}"
href="{{ content_url(resource.prev_by_time.url) }}">
{% if resource.prev_by_time %}
href="{{ content_url(resource.prev_by_time.url) }}"{% endif %}>
Previous
</a>
{% endif %}

{% if resource.next_by_time %}
<a class="next"
<a class="next{{' disabled' if not resource.next_by_time }}"
title="{{ resource.next_by_time.meta.title }}"
href="{{ content_url(resource.next_by_time.url) }}">
{% if resource.next_by_time %}
href="{{ content_url(resource.next_by_time.url) }}"{% endif %}>
Next
</a>
{% endif %}

<br>
<div id="twitter_share">
<a href="http://twitter.com/share"
class="twitter-share-button"
data-count="vertical"
data-via="{{ tweet_via }}">Tweet</a>
<script type="text/javascript"
src="http://platform.twitter.com/widgets.js"></script>
</div>
<div id="facebook_like">
<iframe src="http://www.facebook.com/plugins/like.php?href&amp;layout=box_count&amp;show_faces=false&amp;width=450&amp;action=like&amp;font=arial&amp;colorscheme=light&amp;height=65"
scrolling="no"
frameborder="0"
style="border:none; overflow:hidden; width:450px; height:65px;"
allowTransparency="true"></iframe>
</div>
</nav>
<h1 class="title">
<a href="{{ content_url(resource.url) }}">


+ 2
- 2
hyde/layouts/basic/site.yaml View File

@@ -11,6 +11,7 @@ plugins:
- hyde.ext.plugins.textlinks.TextlinksPlugin
context:
data:
tweet_via: ringce
menu:
-
name: Home
@@ -46,5 +47,4 @@ sorter:
reverse: true
filters:
source.kind: html
meta.listable: true

meta.listable: true

+ 0
- 22
hyde/layouts/test/content/404.html View File

@@ -1,22 +0,0 @@
<!doctype html>
<title>not found</title>

<style>
body { text-align: center;}
h1 { font-size: 50px; }
body { font: 20px Constantia, 'Hoefler Text', "Adobe Caslon Pro", Baskerville, Georgia, Times, serif; color: #999; text-shadow: 2px 2px 2px rgba(200, 200, 200, 0.5); }
::-moz-selection{ background:#FF5E99; color:#fff; }
::selection { background:#FF5E99; color:#fff; }
details { display:block; }
a { color: rgb(36, 109, 56); text-decoration:none; }
a:hover { color: rgb(96, 73, 141) ; text-shadow: 2px 2px 2px rgba(36, 109, 56, 0.5); }
span[frown] { transform: rotate(90deg); display:inline-block; color: #bbb; }
</style>




<details>
<summary><h1>Not found</h1></summary>
<p><span frown>:(</span></p>
</details>

+ 0
- 7
hyde/layouts/test/content/about.html View File

@@ -1,7 +0,0 @@
{% extends "base.html" %}

{% block main %}
Hi!
I am a test template to make sure jinja2 generation works well with hyde.
{% endblock %}

BIN
hyde/layouts/test/content/apple-touch-icon.png View File

Before After
Width: 57  |  Height: 57  |  Size: 1.8 KiB

+ 0
- 9
hyde/layouts/test/content/blog/2010/december/merry-christmas.html View File

@@ -1,9 +0,0 @@
{% extends "blog/post.html" %}

{% block article %}
{{ lipsum() }}
{% endblock %}

{% block aside %}
{{ lipsum() }}
{% endblock %}

+ 0
- 25
hyde/layouts/test/content/crossdomain.xml View File

@@ -1,25 +0,0 @@
<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.adobe.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
<!-- Read this: www.adobe.com/devnet/articles/crossdomain_policy_file_spec.html -->

<!-- Most restrictive policy: -->
<site-control permitted-cross-domain-policies="none"/>
<!-- Least restrictive policy: -->
<!--
<site-control permitted-cross-domain-policies="all"/>
<allow-access-from domain="*" to-ports="*" secure="false"/>
<allow-http-request-headers-from domain="*" headers="*" secure="false"/>
-->
<!--
If you host a crossdomain.xml file with allow-access-from domain=“*”
and don’t understand all of the points described here, you probably
have a nasty security vulnerability. ~ simon willison
-->

</cross-domain-policy>

BIN
hyde/layouts/test/content/favicon.ico View File

Before After

+ 0
- 5
hyde/layouts/test/content/robots.txt View File

@@ -1,5 +0,0 @@
# www.robotstxt.org/
# www.google.com/support/webmasters/bin/answer.py?hl=en&answer=156449

User-agent: *


+ 0
- 4
hyde/layouts/test/info.yaml View File

@@ -1,4 +0,0 @@
author: Lakshmi Vyasarajan
description: A test layout for hyde.
template: jinja2 (2.6)
version: 0.1

+ 0
- 57
hyde/layouts/test/layout/base.html View File

@@ -1,57 +0,0 @@
{% extends "root.html" %}
{% block all %}
<!doctype html>
<html lang="en">
<head>
{% block starthead %}{% endblock starthead %}
<meta charset="{{resource.meta.charset|default('utf-8')}}">
<meta http-equiv="X-UA-Compatible" content="{{resource.meta.compatibility|default('IE=edge,chrome=1')}}">

<title>{% block title %}{{resource.meta.title}}{% endblock %}</title>
<meta name="description" content="{{resource.meta.description}}">
<meta name="author" content="{{resource.meta.author}}">

<!-- Mobile viewport optimized: j.mp/bplateviewport -->
<meta name="viewport" content="{{resource.meta.viewport|default('width=device-width, initial-scale=1.0')}}">

{% block favicons %}
<!-- Place favicon.ico & apple-touch-icon.png in the root of your domain and delete these references -->
<link rel="shortcut icon" href="{{ media_url('/favicon.ico') }}">
<link rel="apple-touch-icon" href="{{ media_url('/apple-touch-icon.png') }}">
{% endblock favicons %}

{% block css %}
<link rel="stylesheet" href="{{ media_url('css/site.css') }}">
{% endblock css %}
{% block endhead %}{% endblock endhead %}
</head>
<body id="{{resource.id if resource.id else resource.name_without_extension}}">
{% block content %}
<div id="container">
{% block container %}
<header>
{% block header %}{% endblock header %}
</header>
<div id="main" role="main">
{% block main %}{% endblock main %}
</div>
<footer>
{% block footer %}{% endblock %}
</footer>
{% endblock container%}
</div> <!--! end of #container -->
{% endblock content%}

{% block js %}
<!-- Javascript at the bottom for fast page loading -->
{% block jquery %}
<!-- Grab Google CDN's jQuery. fall back to local if necessary -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.js"></script>
{% endblock jquery %}

{% block scripts %}{% endblock scripts %}
{%endblock js %}

</body>
</html>
{% endblock all %}

+ 0
- 10
hyde/layouts/test/layout/blog/post.html View File

@@ -1,10 +0,0 @@
{% extends "base.html" %}

{% block main %}
<article>
{% block article %}{% endblock %}
</article>
<aside>
{% block aside %}{% endblock %}
</aside>
{% endblock %}

+ 0
- 1
hyde/layouts/test/layout/root.html View File

@@ -1 +0,0 @@
{% block all %}{% endblock all %}

+ 0
- 4
hyde/layouts/test/media/css/site.css View File

@@ -1,4 +0,0 @@
body{
margin: 0 auto;
width: 960px;
}

+ 0
- 9
hyde/layouts/test/site.yaml View File

@@ -1,9 +0,0 @@
mode: development
media_root:: media # Relative path from site root (the directory where this file exists)
media_url: /media
template: hyde.ext.jinja2
plugins:
- hyde.ext.plugins.meta.MetaPlugin
- hyde.ext.plugins.auto_extend.AutoExtendPlugin
- hyde.ext.plugins.less.LessCSSPlugin
- hyde.ext.plugins.blockdown.BlockdownPlugin

Loading…
Cancel
Save