Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UI Refinement #193

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
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
85 changes: 43 additions & 42 deletions src/youtube2zim/templates/article.html
Original file line number Diff line number Diff line change
@@ -1,44 +1,45 @@
<!DOCTYPE html><html><head><meta charset="utf-8">
<title>{{ title }}</title>
<meta content="utf-8" http-equiv="encoding">
<meta content="text/html;charset=utf-8" http-equiv="Content-Type">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="assets/videojs/video-js.min.css" rel="stylesheet">
<link href="assets/article.css" rel="stylesheet" type="text/css">
<style type="text/css">
body {background: {{ background_color }};}
</style>
<link id="favicon" rel="shortcut icon" href="profile.jpg" type="image/jpeg">
<script src="assets/videojs/video.min.js"></script>
<script src="assets/ogvjs/ogv-support.js"></script>
<script src="assets/ogvjs/ogv.js"></script>
<script src="assets/videojs-ogvjs.js"></script>
<script src="assets/polyfills.js"></script>
<script src="assets/webp-hero.bundle.js"></script>
</head>
<body>
<div id="content">
<a href="home.html"><img id="backtolist" src="channels/{{ author.channelId }}/profile.jpg" title="Back to the list" /></a>
<p id="speaker">{{ author.channelTitle }}</p>
<p id="title">{{ title }}</p>
<video class="video-js vjs-default-skin"
id="video_container"
poster="videos/{{ video_id }}/video.webp"
width="480px" height="270px"
controls="true"
{% if autoplay %}autoplay="true"{% endif %}
preload="true"
data-setup='{"techOrder": ["html5", "ogvjs"], "ogvjs": {"base": "assets/ogvjs"}, "autoplay": {% if autoplay %}true{% else %}false{% endif %}, "preload": true, "controls": true, "controlBar": {"pictureInPictureToggle":false}}'>
<source src="videos/{{ video_id }}/video.{{ video_format }}" type="video/{{ video_format }}" />{% if subtitles %}
{% for language in subtitles %}<track kind="subtitles" src="videos/{{ video_id }}/video.{{ language.code }}.vtt" srclang="{{ language.code }}" label="{{ language.name }}" />
{% endfor %}{% endif %}
</video>
<div id="description">
<p>{{ description }}</p>
</div>
<div id="date">{{ date }}</div>
<!DOCTYPE html>
<html>

<head>
<meta charset="utf-8">
<title>{{ title }}</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="assets/videojs/video-js.min.css" rel="stylesheet">
<link href="assets/article.css" rel="stylesheet" type="text/css">
<style type="text/css">
body {
background: {{ background_color }};
}
</style>
<link id="favicon" rel="shortcut icon" href="profile.jpg" type="image/jpeg">
<script src="assets/videojs/video.min.js"></script>
<script src="assets/ogvjs/ogv-support.js"></script>
<script src="assets/ogvjs/ogv.js"></script>
<script src="assets/videojs-ogvjs.js"></script>
<script src="assets/polyfills.js"></script>
<script src="assets/webp-hero.bundle.js"></script>
</head>

<body>
<div id="content">
<a href="home.html">
<img id="backtolist" src="channels/{{ author.channelId }}/profile.jpg" title="Back to the list" />
</a>
<p id="speaker">{{ author.channelTitle }}</p>
<p id="title">{{ title }}</p>
<video class="video-js vjs-default-skin" id="video_container" poster="videos/{{ video_id }}/video.webp" width="480px" height="270px" controls="true" {% if autoplay %}autoplay="true"{% endif %} preload="true" data-setup='{"techOrder": ["html5", "ogvjs"], "ogvjs": {"base": "assets/ogvjs"}, "autoplay": {% if autoplay %}true{% else %}false{% endif %}, "preload": true, "controls": true, "controlBar": {"pictureInPictureToggle":false}}'>
<source src="videos/{{ video_id }}/video.{{ video_format }}" type="video/{{ video_format }}" />{% if subtitles %}
{% for language in subtitles %}<track kind="subtitles" src="videos/{{ video_id }}/video.{{ language.code }}.vtt" srclang="{{ language.code }}" label="{{ language.name }}" />
{% endfor %}{% endif %}
</video>
<div id="description">
<p>{{ description }}</p>
</div>
<script src="assets/jquery.min.js" type="text/javascript"></script>
<script src="assets/webp-trigger.js"></script>
</body>
<div id="date">{{ date }}</div>
</div>
<script src="assets/jquery.min.js" type="text/javascript"></script>
<script src="assets/webp-trigger.js"></script>
</body>

</html>
19 changes: 8 additions & 11 deletions src/youtube2zim/templates/assets/article.css
Original file line number Diff line number Diff line change
Expand Up @@ -25,34 +25,34 @@

body {
background: #fafafa;
font-family: Helvetica, Arial, sans-serif;
font-family: "RobotoRegular", Helvetica, Arial, sans-serif;
font-weight: 400;
margin-top: 30px;
max-width: 100%;
}

hr {
margin-top: 25px;
margin-left: 0;
text-align: left;
width: 480px;
width: 100%;
}

#content {
margin: 0 auto;
width: 480px;
width: 100%;
max-width: 480px;
text-align: justify;
text-justify: inter-word;
max-width:100%;
}

#description {
font-family: 'RobotoLight';
color: #333;
width: 480px;
width: 100%;
font-size: 18px;
text-align: justify;
text-justify: inter-word;
max-width:100%;
}

#description p {
Expand All @@ -63,7 +63,6 @@ hr {
font-family: "RobotoLight";
font-size: 20px;
margin: 0;
max-width:100%;
}

#title {
Expand All @@ -72,7 +71,6 @@ hr {
font-size: 30px;
text-align: left;
text-justify: none;
max-width:100%;
}

#views {
Expand Down Expand Up @@ -106,15 +104,14 @@ hr {
}

#speaker_desc {
width: 480px;
width: 100%;
margin: 0;
font-family: "RobotoLight";
}

#date {
text-align: right;
width: 480px;
max-width:100%;
width: 100%;
}

#backtolist {
Expand Down
Loading
Loading