dev-portfolio-blog 0.1.0 → 0.1.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bb46826c866abde66b8b3920bc6a62e6ef31a275ecb92ded2d405d4e8889ceb6
4
- data.tar.gz: 228535a8ef1be5aceaf689323346e44570922a2af4c29b15c900bab63d3e5131
3
+ metadata.gz: 46e9ba4bd273240d9841af909b08ac74e1df3ea67aefafd448346f9d3d991c6d
4
+ data.tar.gz: 28ec7ef34627bff4b694ce7ee4ff4156fa846ce10be273dd544d3796f0fdb89c
5
5
  SHA512:
6
- metadata.gz: 05b37c9a4742125f5dfbbf44b85207627061abe89987a11ca562d0c61a31f70e4faf9b875f13dd2f6f54e28331159039d0000ab0b589045dc9d8d5e4509bbb97
7
- data.tar.gz: 67bfd8135315351d5b9e3329fdf1d59352450061f622cac88d4889d951ffd4ee5ef7892fd917ed066d9bc88744161f3c639008822c3d480bcef21dd172b473e6
6
+ metadata.gz: 94bb983796d954ef0afa978d2c7355a82e6f1f568f3c62d5cfc07cf29133f838ff5ebd585aae0c544d2ab19a20509aa2dc00f9d199c7c546189f0f14139272a0
7
+ data.tar.gz: 595b955d07b1d96e5d8c1562b7930842d84e16cd3b6ac8c6430ba3b92151933455e4307f6eacfc6542c2951f664954863c3b2e183c4be309240505e505e0cd58
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2020 Rohit Jain
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,167 @@
1
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
2
+ [![Gem Version](https://badge.fury.io/rb/dev-portfolio-blog.svg)](https://badge.fury.io/rb/dev-portfolio-blog)
3
+ ![](https://ruby-gem-downloads-badge.herokuapp.com/dev-portfolio-blog)
4
+
5
+ [![CodeFactor](https://www.codefactor.io/repository/github/rohitjain00/dev-portfolio-blog/badge)](https://www.codefactor.io/repository/github/rohitjain00/dev-portfolio-blog)
6
+ [![Codacy Badge](https://api.codacy.com/project/badge/Grade/d0b9f1c23f564a8195a8588de7895c4c)](https://www.codacy.com/manual/rohitjain00/dev-portfolio-blog?utm_source=github.com&utm_medium=referral&utm_content=rohitjain00/dev-portfolio-blog&utm_campaign=Badge_Grade)
7
+
8
+ ## Home pagespeed
9
+
10
+ ![GitHub PageSpeed](https://api.speedbadge.io/v1?url=therohitjain.com&showStratLabel=true)
11
+ ![GitHub PageSpeed](https://api.speedbadge.io/v1?url=therohitjain.com&strat=desktop&showStratLabel=true)
12
+
13
+
14
+ ## Blog pagespeed
15
+
16
+ ![GitHub PageSpeed](https://api.speedbadge.io/v1?url=therohitjain.com/blog&showStratLabel=true)
17
+ ![GitHub PageSpeed](https://api.speedbadge.io/v1?url=therohitjain.com/blog&strat=desktop&showStratLabel=true)
18
+
19
+
20
+
21
+ # dev-portfolio-blog
22
+
23
+ This is a minimal jekyll theme for writing blogs and about yourself.
24
+
25
+ ## features
26
+ 1. Google Analytics
27
+ 2. Dark mode
28
+ 3. Disqus comments
29
+ 4. Categorization
30
+ 5. Highly optimized blog
31
+ #### PageSpeed Insights
32
+ * [Home](https://developers.google.com/speed/pagespeed/insights/?url=https%3A%2F%2Ftherohitjain.com)[(therohitjain.com)](https://therohitjain.com)
33
+ * [Blog](https://developers.google.com/speed/pagespeed/insights/?url=https%3A%2F%2Ftherohitjain.com/blog/)[(therohitjain.com/blog/)](https://therohitjain.com/blog/)
34
+ * [About](https://developers.google.com/speed/pagespeed/insights/?url=https%3A%2F%2Ftherohitjain.com/about/)[(therohitjain.com/about/)](https://therohitjain.com/about/)
35
+
36
+
37
+ ## Desktop Preview
38
+
39
+ ![Home Page](/screenshots/Home.png?raw=true "Home View of the website")
40
+
41
+ ![Blog List Page](/screenshots/Blog.png?raw=true "Blog List of the website")
42
+
43
+ ## Mobile Preview
44
+
45
+ ![Home Page](/screenshots/Home-Mobile.png?raw=true "Home View of the website")
46
+
47
+ ![Blog List Page](/screenshots/Blog-Mobile.png?raw=true "Blog List of the website")
48
+
49
+
50
+ ## Installation
51
+
52
+ Add this line to your Jekyll site's `Gemfile`:
53
+
54
+ ```ruby
55
+ gem "dev-portfolio-blog"
56
+ ```
57
+
58
+ And add this line to your Jekyll site's `_config.yml`:
59
+
60
+ ```yaml
61
+ theme: dev-portfolio-blog
62
+ ```
63
+
64
+ And then execute:
65
+
66
+ $ bundle
67
+
68
+ Or install it yourself as:
69
+
70
+ $ gem install dev-portfolio-blog
71
+
72
+ ## Usage
73
+
74
+ To start using the theme you need to follow these steps.
75
+
76
+ Assuming that you started your first website based on `minima` theme from [here](https://jekyllrb.com/docs/)
77
+
78
+ Add a `favicon.ico` to the root directory for favicon.
79
+
80
+ 1. Create `blog.md` in the root folder ans set its yaml parameters to
81
+
82
+ ```yaml
83
+ layout: blog
84
+ title: blog
85
+ permalink: /blog/
86
+ ```
87
+
88
+ 2. Change your `about.md` yaml parameters to following
89
+
90
+ ```yaml
91
+ layout: description
92
+ permalink: /about/
93
+ ```
94
+
95
+ 3. In the `index.md` file add
96
+
97
+ ```yaml
98
+ home_text : [Your Text]
99
+ ```
100
+
101
+ 4. Create a new `categories.md` file in root with following yaml parameters
102
+ ```yaml
103
+ layout: categories
104
+ ```
105
+
106
+ 4. In the `_congif.yml` file add following and change accordingly
107
+
108
+ Path is relative to the root directory
109
+ ```yaml
110
+ resume_url: [PATH_TO_RESUME]
111
+ author_name: [YOUR_NAME]
112
+ description: [SITE_DESCRIPTION]
113
+ url: [WEBSITE_URL]
114
+ google_analytics: '[google analytics Id]'
115
+ disqus:
116
+ shortname: [discus-shotname]
117
+ ```
118
+
119
+ ### Minifier
120
+
121
+ Visit [Jekyll-minifier](https://github.com/digitalsparky/jekyll-minifier) and add this to your `_config.yml` file to enable minifier.
122
+
123
+ ### Pagination
124
+
125
+ Visit [jekyll-paginate-v2](https://github.com/sverrirs/jekyll-paginate-v2/blob/master/README-GENERATOR.md#site-configuration) and add this to your `_config.yml` file to enable pagination.
126
+
127
+ ### Check [_config.yml](https://github.com/rohitjain00/dev-portfolio-blog/blob/master/_config.yml) for example config file.
128
+
129
+
130
+ ## Writing a new blog
131
+
132
+ Create a new folder `_posts` in root folder
133
+
134
+ 1. Create a new markdown file in the format `yyyy-mm-dd-postname.md`
135
+ 2. Make sure that disqus's shortname is valid.
136
+ 3. Add yaml configuartion to the post
137
+
138
+ ```yaml
139
+ ---
140
+ layout: post
141
+ comments: [true | false]
142
+ title: Hello World
143
+ categories: [category1, category2]
144
+ ---
145
+ Post Text.
146
+ ```
147
+
148
+
149
+ ## Contributing
150
+
151
+ Bug reports and pull requests are welcome on GitHub at <https://github.com/rohitjain00/dev-portfolio-blog/.> This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
152
+
153
+ ## Development
154
+
155
+ To set up your environment to develop this theme, run `bundle install`.
156
+
157
+ Your theme is setup just like a normal Jekyll site! To test your theme, run `bundle exec jekyll serve` and open your browser at `http://localhost:4000`. This starts a Jekyll server using your theme. Add pages, documents, data, etc. like normal to test your theme's contents. As you make modifications to your theme and to your content, your site will regenerate and you should see the changes in the browser after a refresh, just like normal.
158
+
159
+ When your theme is released, only the files in `_layouts`, `_includes`, `_sass` and `assets` tracked with Git will be bundled.
160
+ To add a custom directory to your theme-gem, please edit the regexp in `dev-portfolio-blog.gemspec` accordingly.
161
+
162
+ ### Read about the themes and how it's implemented [here](https://github.com/rohitjain00/dev-portfolio-blog/wiki/Theme-Management)
163
+
164
+ ## License
165
+
166
+ The theme is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
167
+
@@ -0,0 +1,9 @@
1
+ <!-- Global site tag (gtag.js) - Google Analytics -->
2
+ <script async src="https://www.googletagmanager.com/gtag/js?id={{ site.google_analytics }}"></script>
3
+ <script>
4
+ window.dataLayer = window.dataLayer || [];
5
+ function gtag(){dataLayer.push(arguments);}
6
+ gtag('js', new Date());
7
+
8
+ gtag('config', '{{ site.google_analytics }}');
9
+ </script>
@@ -0,0 +1,14 @@
1
+ <div id="disqus_thread"></div>
2
+ <script>
3
+ var disqus_config = function () {
4
+ this.page.url = '{{ page.url | absolute_url }}';
5
+ this.page.identifier = '{{ page.url | absolute_url }}';
6
+ };
7
+ (function() {
8
+ var d = document, s = d.createElement('script');
9
+ s.src = 'https://{{ site.disqus.shortname }}.disqus.com/embed.js';
10
+ s.setAttribute('data-timestamp', +new Date());
11
+ (d.head || d.body).appendChild(s);
12
+ })();
13
+ </script>
14
+ <noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript" rel="nofollow">comments powered by Disqus.</a></noscript>
@@ -0,0 +1,22 @@
1
+ <ul>
2
+ <li>
3
+ <a href = "{{ '/' | relative_url }}">
4
+ Home
5
+ </a>
6
+ </li>
7
+ <li>
8
+ <a href = "{{ 'about/' | relative_url }}">
9
+ About
10
+ </a>
11
+ </li>
12
+ <li>
13
+ <a href = "{{ 'blog/' | relative_url }}">
14
+ Blog
15
+ </a>
16
+ </li>
17
+ <li>
18
+ <a href = "{{ site.resume_url | relative_url }}">
19
+ Resume
20
+ </a>
21
+ </li>
22
+ </ul>
@@ -0,0 +1,2 @@
1
+ <select id='themeSelector' onchange="toggleTheme()" aria-label="Select theme">
2
+ </select>
@@ -0,0 +1,46 @@
1
+ ---
2
+ layout: description
3
+ title: Blog
4
+ pagetype: blog
5
+ ---
6
+ <!-- This loops through the paginated posts -->
7
+
8
+
9
+ {% if paginator.total_posts == 0 %}
10
+ <p>No posts right now.</p>
11
+ {% else %}
12
+ <div class="blogPage-categoryList">
13
+ <ul>
14
+ <li><a href="{{ "/categories/" | relative_url }}">Categories</a> : </li>
15
+ {% for category in site.categories %}
16
+ {% capture category_name %}{{ category | first }}{% endcapture %}
17
+ <li><a href="{{"/categories/#" | append: category_name | relative_url}}">{{category_name}}</a></li>
18
+ {% endfor %}
19
+ </ul>
20
+ </div>
21
+ <ul class="blog-list">
22
+ {% for post in paginator.posts %}
23
+ <li>
24
+ <a class="blog-heading" href="{{ post.url | relative_url }}">{{ post.title }}</a><span class="date">{{ post.date | date_to_string }}</span>
25
+ <div class="excerpt">{{ post.excerpt }}</div>
26
+ </li>
27
+ {% endfor %}
28
+ </ul>
29
+ {% endif %}
30
+
31
+ <hr>
32
+ {% if paginator.total_pages > 1 %}
33
+ <ul>
34
+
35
+ {% if paginator.previous_page %}
36
+ <li>
37
+ <a href="{{ paginator.previous_page_path | prepend: site.baseurl }}">Newer</a>
38
+ </li>
39
+ {% endif %}
40
+ {% if paginator.next_page %}
41
+ <li>
42
+ <a href="{{ paginator.next_page_path | prepend: site.baseurl }}">Older</a>
43
+ </li>
44
+ {% endif %}
45
+ </ul>
46
+ {% endif %}
@@ -0,0 +1,23 @@
1
+ ---
2
+ layout: description
3
+ permalink: /categories/
4
+ title: Categories
5
+ ---
6
+
7
+
8
+ <div id="archives">
9
+ {% for category in site.categories %}
10
+ <div class="archive-group">
11
+ {% capture category_name %}{{ category | first }}{% endcapture %}
12
+ <div id="#{{ category_name | slugize }}"></div>
13
+ <h3 class="category-head">{{ category_name }}</h3>
14
+ <a name="{{ category_name | slugize }}"></a>
15
+ {% for post in site.categories[category_name] %}
16
+ <article class="archive-item">
17
+ &nbsp;&nbsp;<a href="{{ post.url | relative_url }}">{{post.title}} - {{ post.date | date_to_string }}</a>
18
+ </article>
19
+ <br>
20
+ {% endfor %}
21
+ </div>
22
+ {% endfor %}
23
+ </div>
@@ -0,0 +1,49 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
+ <link rel="shortcut icon" href="{{"/favicon.ico" | relative_url }}" type="image/x-icon" />
7
+ <link rel="dns-prefetch" href="https://{{ site.disqus.shortname }}.disqus.com">
8
+ <meta
9
+ itemprop="description"
10
+ name="description"
11
+ content="
12
+ {% if page.description %}
13
+ {{ page.description | truncate: 160 }}
14
+ {% else %}
15
+ {{ site.description | truncate: 160 }}
16
+ {% endif %}"
17
+ />
18
+ <title>
19
+ {%if page.title %}
20
+ {{ page.title }}
21
+ {% else %}
22
+ {{ site.title }}
23
+ {% endif %}
24
+ </title>
25
+ <!-- async load css file -->
26
+ <link rel="stylesheet" href="{{"/assets/css/styles.css" | relative_url}}" media="none" onload="if(media!='all')media='all'">
27
+ <!-- Load css when script is disabled -->
28
+ <noscript><link rel="stylesheet" href="{{"/assets/css/styles.css" | relative_url}}"></noscript>
29
+
30
+ <!-- Dns Prefetch the google analytics -->
31
+ <link rel="dns-prefetch" href="www.googletagmanager.com">
32
+ <link rel="dns-prefetch" href="www.google-analytics.com">
33
+
34
+
35
+
36
+ <!-- Load the script async and wait for the page to render for script to execute -->
37
+ <script defer src="{{"/assets/js/theme.js" | relative_url }}"></script>
38
+ <script defer src="{{"/assets/js/script.js" | relative_url }}"></script>
39
+
40
+ {% include analytics.html %}
41
+ {% feed_meta %}
42
+ {% seo %}
43
+
44
+ </head>
45
+ <body onload="onLoad()">
46
+ {% include themeSelector.html %}
47
+ {{ content }}
48
+ </body>
49
+ </html>
@@ -0,0 +1,12 @@
1
+ ---
2
+ layout: default
3
+ ---
4
+ <div class="mid-section-cover">
5
+ <nav>
6
+ <h1>{{ site.author_name }}</h1>
7
+ {% include navigation.html %}
8
+ </nav>
9
+ <main class="sub-mid-section-cover">
10
+ {{ content }}
11
+ </main>
12
+ </div>
@@ -0,0 +1,15 @@
1
+ ---
2
+ title: Rohit Jain
3
+ layout: default
4
+ ---
5
+ <div class="mid-section-home">
6
+ <h1><span>I am </span>{{ site.author_name }}</h1>
7
+ <div class="row sub-heading">
8
+ <div class="summary-about-me">
9
+ <p>{{ page.home_text }}</p>
10
+ </div>
11
+ <div class="nav-link">
12
+ {% include navigation.html %}
13
+ </div>
14
+ </div>
15
+ </div>
@@ -0,0 +1,22 @@
1
+ ---
2
+ layout: description
3
+ ---
4
+ <ul>
5
+ {% if page.contenttype == project %}
6
+ {% for post in paginator.posts %}
7
+ <li>
8
+ <h2><a href="{{ post.url }}">{{ post.title }}</a></h2>
9
+ <p>{{ post.excerpt }}</p>
10
+ </li>
11
+ {% endfor %}
12
+ {% elsif page.contenttype == project %}
13
+ {% for post in site.posts %}
14
+ {% if post.contenttype == page.pagetype %}
15
+ <li>
16
+ <h2><a href="{{ post.url }}">{{ post.title }}</a></h2>
17
+ <p>{{ post.excerpt }}</p>
18
+ </li>
19
+ {% endif %}
20
+ {% endfor %}
21
+ {% endif %}
22
+ </ul>
@@ -0,0 +1,5 @@
1
+ ---
2
+ layout: default
3
+ ---
4
+
5
+ {{ content }}
@@ -0,0 +1,24 @@
1
+ ---
2
+ layout: description
3
+ ---
4
+ <h2>{{ page.title }}</h2>
5
+ <small>{{ post.date | date_to_string }}</small>
6
+ {{content}}
7
+
8
+ <div class="post-categories">
9
+ Categories :
10
+ {% if post %}
11
+ {% assign categories = post.categories %}
12
+ {% else %}
13
+ {% assign categories = page.categories %}
14
+ {% endif %}
15
+ {% for category in categories %}
16
+ <a href="{{site.url}}/categories/#{{category|slugize}}">{{category}}</a>
17
+ {% unless forloop.last %}&nbsp;{% endunless %}
18
+ {% endfor %}
19
+ </div>
20
+
21
+ {% if site.disqus.shortname and page.comments %}
22
+ <hr>
23
+ {% include disqus_comments.html %}
24
+ {% endif %}
@@ -0,0 +1,220 @@
1
+ @mixin mediaQuery($point) {
2
+ @if $point == phone-width {
3
+ @media (max-width: 480px) { @content; }
4
+ }
5
+ @else if $point == tablet-width {
6
+ @media (max-width: 768px) { @content; }
7
+ }
8
+ }
9
+ html {
10
+ --primary-background-color: white;
11
+ --primary-text-color: #222;
12
+ padding: 0;
13
+ margin: 0;
14
+ }
15
+
16
+ body {
17
+ background-color: var(--primary-background-color);
18
+ color: var(--primary-text-color);
19
+ transition: background 0.1s ease-in, color 0.1s ease-in;
20
+ // font-size: 120%;
21
+ }
22
+ .mid-section-home {
23
+ text-align: center;
24
+ display: inline-block;
25
+ position: fixed;
26
+ top: 0;
27
+ bottom: 0;
28
+ left: 0;
29
+ right: 0;
30
+ width: 400px;
31
+ height: 350px;
32
+ margin: auto;
33
+ font-size: 1.5rem;
34
+ @include mediaQuery(phone-width) {
35
+ font-size: 1 rem;
36
+ height: 350px;
37
+ width: 100%;
38
+ span {
39
+ display: none;
40
+ }
41
+ }
42
+ h1 {
43
+ font-size: 3.5rem;
44
+ font-weight: 600;
45
+ }
46
+
47
+ }
48
+ .sub-heading {
49
+ width: 80%;
50
+ margin: 0 auto;
51
+ display: flex;
52
+
53
+ @include mediaQuery(phone-width) {
54
+ width: 60%;
55
+ min-width: 270px;
56
+ }
57
+ }
58
+ .summary-about-me {
59
+ width: 50%;
60
+ text-align: right;
61
+ padding-right: 20px;
62
+ }
63
+ .nav-link {
64
+ ul {
65
+ padding-inline-start: 0;
66
+ }
67
+ li {
68
+ display: block;
69
+ text-align: left;
70
+ a {
71
+ text-decoration : none;
72
+ color: var(--primary-text-color);
73
+ &:hover {
74
+ border-bottom: 2px solid var(--primary-text-color);
75
+ color: var(--primary-text-color);
76
+
77
+ }
78
+ }
79
+ }
80
+ border-left: 2px solid var(--primary-text-color);
81
+ width: 50%;
82
+ padding-left: 20px;
83
+ // .toNav {
84
+ // }
85
+ @include mediaQuery(phone-width) {
86
+ li {
87
+ display: block;
88
+ margin-left: 10px;
89
+ }
90
+ }
91
+ }
92
+ .mid-section-cover {
93
+ width: 60%;
94
+ margin: 0 auto;
95
+ margin-top: 50px;
96
+ @include mediaQuery(tablet-width) {
97
+ width: 70%;
98
+ }
99
+ @include mediaQuery(phone-width) {
100
+ width: 95%;
101
+ }
102
+ nav {
103
+ display: flex;
104
+ flex-direction: row;
105
+ justify-content: space-between;
106
+ flex-wrap: wrap;
107
+ border-bottom: 2px solid var(--primary-text-color);
108
+ h1 {
109
+ // align-self: flex-start;
110
+ font-size: 40px;
111
+ flex-grow: 2;
112
+ text-align: left;
113
+ margin: 10px;
114
+ }
115
+ ul {
116
+ display: flex;
117
+ flex-direction: row;
118
+ flex-wrap: wrap;
119
+ justify-content: end;
120
+ align-items: center;
121
+ flex-grow: 5;
122
+ li {
123
+ padding: 0 20px;
124
+ list-style-type: none;
125
+ a {
126
+ text-decoration : none;
127
+ color: var(--primary-text-color);
128
+ &:hover {
129
+ border-bottom: 2px solid var(--primary-text-color);
130
+ color: var(--primary-text-color);
131
+ }
132
+ }
133
+ @include mediaQuery(phone-width) {
134
+ text-align: center;
135
+ padding: 0 10px;
136
+ }
137
+ }
138
+ }
139
+ @include mediaQuery(tablet-width) {
140
+ flex-direction: column;
141
+ justify-content: center;
142
+ align-items: center;
143
+ ul {
144
+ justify-content: center;
145
+ }
146
+ h1 {
147
+ text-align: center;
148
+ }
149
+ }
150
+ }
151
+ .sub-mid-section-cover {
152
+ width: 100%;
153
+ margin: 0 auto;
154
+ overflow: hidden;
155
+ img {
156
+ max-width: 100%;
157
+ }
158
+ a {
159
+ color: var(--primary-text-color);
160
+ }
161
+ }
162
+ }
163
+
164
+
165
+ // .blog-section-list {
166
+ // a {
167
+ // color: var(--primary-text-color);
168
+ // }
169
+ // }
170
+ // .container-404 {
171
+ // text-align: center;
172
+ // }
173
+
174
+ #themeSelector {
175
+ position: fixed;
176
+ top: 5px;
177
+ right: 5px;
178
+ background: var(--primary-background-color);
179
+ color: var(--primary-text-color);
180
+ border-radius: 5px;
181
+ border: 0;
182
+ }
183
+
184
+ .post-categories {
185
+ text-align: right;
186
+ }
187
+ .blog-list {
188
+ list-style: none;
189
+ padding-left: 0;
190
+ li {
191
+ margin-bottom: 50px;
192
+ .excerpt {
193
+ font-size: 15px;
194
+ }
195
+ .blog-heading {
196
+ font-size: 25px;
197
+ font-weight: 800;
198
+ }
199
+ .date {
200
+ font-size: 15px;
201
+ opacity: 0.8;
202
+ margin-left: 20px;
203
+ }
204
+ }
205
+
206
+ }
207
+ .blogPage-categoryList {
208
+ ul {
209
+ list-style-type: none;
210
+ display: flex;
211
+ flex-wrap: wrap;
212
+ padding-left: 0;
213
+ li {
214
+ margin: 10px 10px;
215
+ }
216
+ li:first-child {
217
+ margin-left: 0;
218
+ }
219
+ }
220
+ }
@@ -0,0 +1,3 @@
1
+ ---
2
+ ---
3
+ @import "main";
@@ -0,0 +1,29 @@
1
+ function onLoad() {
2
+ var themeSelector = document.getElementById('themeSelector');
3
+ for (var themeName in themeMap) {
4
+ var opt = document.createElement('option');
5
+ opt.value = themeName;
6
+ opt.innerHTML = capitalizeFirstLetter(themeName);
7
+ themeSelector.appendChild(opt);
8
+ }
9
+ if (localStorage.getItem('theme') != null) {
10
+ themeSelector.value = localStorage.getItem('theme');
11
+ toggleTheme();
12
+ }
13
+ }
14
+
15
+ function toggleTheme() {
16
+ var themeName = themeSelector.value;
17
+ localStorage.setItem('theme', themeName);
18
+ var element = document.getElementsByTagName('html')[0];
19
+ changeTheme(element, themeMap[themeName]);
20
+ }
21
+
22
+ function changeTheme(element, theme) {
23
+ element.style.setProperty("--primary-background-color", theme['background-color']);
24
+ element.style.setProperty("--primary-text-color", theme['text-color']);
25
+ }
26
+
27
+ function capitalizeFirstLetter(string) {
28
+ return string.charAt(0).toUpperCase() + string.slice(1);
29
+ }
@@ -0,0 +1,10 @@
1
+ const themeMap = {
2
+ 'default': {
3
+ 'background-color': 'white',
4
+ 'text-color': '#222'
5
+ },
6
+ 'dark': {
7
+ 'background-color': '#222',
8
+ 'text-color': 'white'
9
+ }
10
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dev-portfolio-blog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rohit Jain
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-02-19 00:00:00.000000000 Z
11
+ date: 2020-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '3.8'
19
+ version: 3.8.7
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '3.8'
26
+ version: 3.8.7
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: jekyll-seo-tag
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -67,45 +67,133 @@ dependencies:
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
69
  - !ruby/object:Gem::Dependency
70
- name: bundler
70
+ name: jekyll-paginate-v2
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: '0'
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: '0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: jekyll-minifier
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '0'
90
+ type: :runtime
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: jekyll-assets
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '0'
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: sprockets
71
113
  requirement: !ruby/object:Gem::Requirement
72
114
  requirements:
73
115
  - - "~>"
74
116
  - !ruby/object:Gem::Version
75
- version: '1.16'
76
- type: :development
117
+ version: '3.7'
118
+ type: :runtime
77
119
  prerelease: false
78
120
  version_requirements: !ruby/object:Gem::Requirement
79
121
  requirements:
80
122
  - - "~>"
81
123
  - !ruby/object:Gem::Version
82
- version: '1.16'
124
+ version: '3.7'
125
+ - !ruby/object:Gem::Dependency
126
+ name: autoprefixer-rails
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :runtime
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
139
+ - !ruby/object:Gem::Dependency
140
+ name: bundler
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - ">="
144
+ - !ruby/object:Gem::Version
145
+ version: '0'
146
+ type: :development
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ version: '0'
83
153
  - !ruby/object:Gem::Dependency
84
154
  name: rake
85
155
  requirement: !ruby/object:Gem::Requirement
86
156
  requirements:
87
- - - "~>"
157
+ - - ">="
88
158
  - !ruby/object:Gem::Version
89
- version: '12.0'
159
+ version: '0'
90
160
  type: :development
91
161
  prerelease: false
92
162
  version_requirements: !ruby/object:Gem::Requirement
93
163
  requirements:
94
- - - "~>"
164
+ - - ">="
95
165
  - !ruby/object:Gem::Version
96
- version: '12.0'
97
- description:
166
+ version: '0'
167
+ description:
98
168
  email:
99
169
  - rohitjain18005@gmail.com
100
170
  executables: []
101
171
  extensions: []
102
172
  extra_rdoc_files: []
103
- files: []
173
+ files:
174
+ - LICENSE.txt
175
+ - README.md
176
+ - _includes/analytics.html
177
+ - _includes/disqus_comments.html
178
+ - _includes/navigation.html
179
+ - _includes/themeSelector.html
180
+ - _layouts/blog.html
181
+ - _layouts/categories.html
182
+ - _layouts/default.html
183
+ - _layouts/description.html
184
+ - _layouts/home.html
185
+ - _layouts/list.html
186
+ - _layouts/page.html
187
+ - _layouts/post.html
188
+ - _sass/main.scss
189
+ - assets/css/styles.scss
190
+ - assets/js/script.js
191
+ - assets/js/theme.js
104
192
  homepage: https://github.com/rohitjain00/dev-portfolio-blog
105
193
  licenses:
106
194
  - MIT
107
195
  metadata: {}
108
- post_install_message:
196
+ post_install_message:
109
197
  rdoc_options: []
110
198
  require_paths:
111
199
  - lib
@@ -121,7 +209,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
121
209
  version: '0'
122
210
  requirements: []
123
211
  rubygems_version: 3.0.3
124
- signing_key:
212
+ signing_key:
125
213
  specification_version: 4
126
214
  summary: This is a simple efficient blog and portfolio
127
215
  test_files: []