namecard 0.1.0 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +3 -4
- data/_includes/dark_mode.html +20 -9
- data/_layouts/main.html +0 -20
- data/assets/namecard.png +0 -0
- data/assets/style.scss +0 -6
- metadata +10 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7954c28fe07eb178e5875ea8d9b8ff743bc3112a51d0d4f970200cc1fc7b11c7
|
4
|
+
data.tar.gz: c574b3a429f8daacdfc3adca98210079d83097d63b1394258788b0a9d96f5f1e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1028214b6331ee5a0d3fed88f1ecc93df8385a00f27e9642100a4daf1afd17f194d3ec2f144abefe8838a469606b7d5fe928d99efd47d8b9383eafbf38c6cf7b
|
7
|
+
data.tar.gz: d7d42fd0206e1593ed1d80e295d94dea752f98d782ee6227860e12b64513b83d005beaddb7bf31072f7a43752f4201ca0a356d6334cbca463564477433c43257
|
data/README.md
CHANGED
@@ -1,12 +1,11 @@
|
|
1
1
|
# namecard
|
2
|
+
### *namecard* is a markdown-driven, single page CV
|
2
3
|
|
3
4
|

|
4
5
|
|
5
|
-
|
6
|
-
|
7
|
-
**markdown-driven**: all of the content and most of the styling on the site can be edited with markdown - this grants flexibility without compromising ease of use
|
6
|
+
**markdown-driven**: all of the content and most of the styling on the site can be edited with markdown, which is flexible and easy to use
|
8
7
|
|
9
|
-
**single page**: a single page is concise and doesn't overwhelm visitors - see the [*KISS*](https://en.wikipedia.org/wiki/KISS_principle) principle
|
8
|
+
**single page**: a single page is concise and doesn't overwhelm visitors - see the [*KISS*](https://en.wikipedia.org/wiki/KISS_principle) principle
|
10
9
|
|
11
10
|
## Usage
|
12
11
|
|
data/_includes/dark_mode.html
CHANGED
@@ -2,15 +2,26 @@
|
|
2
2
|
const darkModeQuery = '(prefers-color-scheme: dark)';
|
3
3
|
const darkModeClass = 'dark-mode'
|
4
4
|
|
5
|
-
|
6
|
-
|
7
|
-
}
|
5
|
+
{% assign dark_mode = site.dark_mode | default: "system" %}
|
6
|
+
|
7
|
+
{% if dark_mode == "system" %}
|
8
|
+
// set initial theme based on system preferences
|
9
|
+
if (window.matchMedia && window.matchMedia(darkModeQuery).matches) {
|
10
|
+
document.body.classList.add(darkModeClass);
|
11
|
+
}
|
8
12
|
|
9
|
-
|
10
|
-
|
11
|
-
|
13
|
+
// watch for changes in system preferences
|
14
|
+
window.matchMedia(darkModeQuery).addEventListener('change', e => {
|
15
|
+
document.body.classList.toggle(darkModeClass);
|
16
|
+
});
|
17
|
+
{% endif %}
|
18
|
+
|
19
|
+
{% if dark_mode == "always" %}
|
20
|
+
// set dark mode
|
21
|
+
document.body.classList.add(darkModeClass);
|
22
|
+
{% endif %}
|
12
23
|
|
13
|
-
|
14
|
-
|
15
|
-
}
|
24
|
+
{% if dark_mode == "never" %}
|
25
|
+
// do nothing, since dark mode is off by default
|
26
|
+
{% endif %}
|
16
27
|
</script>
|
data/_layouts/main.html
CHANGED
@@ -68,23 +68,3 @@
|
|
68
68
|
<!-- dark mode -->
|
69
69
|
{%- include dark_mode.html -%}
|
70
70
|
</html>
|
71
|
-
|
72
|
-
<!-- // <button onclick="toggleDarkMode()"> </button>
|
73
|
-
// // auto-id generation
|
74
|
-
// // see: https://kramdown.gettalong.org/converter/html.html
|
75
|
-
// function getSectionId(name) {
|
76
|
-
// // remove all characters except letters, numbers, spaces and dashes
|
77
|
-
// var res = name.replace(/[^a-zA-Z0-9 -]/g,'');
|
78
|
-
// // remove all characters from the start of the line until the first letter
|
79
|
-
// res = /[a-zA-Z](.+)/.exec(res)[0];
|
80
|
-
// // convert everything except letters and numbers to dashes
|
81
|
-
// res = res.replace(/[^a-zA-Z0-9]/g, "-");
|
82
|
-
// // lowercase
|
83
|
-
// res = res.toLowerCase();
|
84
|
-
// // if nothing is left, use "section"
|
85
|
-
// if (res.length === 0) {
|
86
|
-
// res = "section";
|
87
|
-
// }
|
88
|
-
// // name-collision omitted, all section headers assumed to be unique
|
89
|
-
// return res;
|
90
|
-
// } -->
|
data/assets/namecard.png
CHANGED
Binary file
|
data/assets/style.scss
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: namecard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- afterdusk
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-04-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: jekyll
|
@@ -16,14 +16,20 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 3.8
|
19
|
+
version: '3.8'
|
20
|
+
- - ">="
|
21
|
+
- !ruby/object:Gem::Version
|
22
|
+
version: 3.8.6
|
20
23
|
type: :runtime
|
21
24
|
prerelease: false
|
22
25
|
version_requirements: !ruby/object:Gem::Requirement
|
23
26
|
requirements:
|
24
27
|
- - "~>"
|
25
28
|
- !ruby/object:Gem::Version
|
26
|
-
version: 3.8
|
29
|
+
version: '3.8'
|
30
|
+
- - ">="
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: 3.8.6
|
27
33
|
- !ruby/object:Gem::Dependency
|
28
34
|
name: jekyll-seo-tag
|
29
35
|
requirement: !ruby/object:Gem::Requirement
|