swedbank-pay-design-guide-jekyll-theme 2.2.7 → 2.3.0

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: 2f469a5d1e7e89425acdf58a0be1430e8d93a95b986b2da7a15ee776bdd2cd56
4
- data.tar.gz: af4fc1aba809b6ccbf6e913ce3a6bec4b1981419ce6ba3858d3a77c746d4c313
3
+ metadata.gz: 604c15e76c253760308c63d9789afad74fd517a2a162270b8e7406a181b95ca4
4
+ data.tar.gz: 31c3e0a519633818d1518d382846712ec724dce33d72f36e9074ba471f30dd4f
5
5
  SHA512:
6
- metadata.gz: b1eae6bc4ab2c636715ac1a96ff0a8c10d311ada204f6cdb56132ec0840df7b76bab49d57dad8241d46e74ae7797f7390b7c21ca15a260b944dff4ad46285017
7
- data.tar.gz: 301925810c1e8a2daa211e106df4492162d66336ade001148dd653f6521686738a5beff74619f1ee4c11c91cb2a4045f917b86acd213a8d382f9e1b024043427
6
+ metadata.gz: 61eb8bf12a53876a869ffd01225cd43199a8a8f0389ba913f11d6f61b7e594284dffcfcc54660f26b74ab0b6b59280b97dac8f33726f6eb18a8fa82eca2f767e
7
+ data.tar.gz: 7441e15601c4a655cca63ef9583d16a3446d3f2d715ac1e7c68e236544410c67139832bdde896bc7373ddec8bf1e6bc8a957144364d9ed65e401248610f873d4
data/README.md CHANGED
@@ -20,14 +20,13 @@ like to host it locally on your computer, you have two options, manual install
20
20
  or [Docker][docker].
21
21
  The Docker installation is the one we recommend to use for its simplicity.
22
22
 
23
- After either a Docker or manual installation Jekyll should be fired up with this theme. You can now add pages, documents,
24
- data, etc. like normal to test your theme's contents. As you make modifications to your theme and to your content, the site will regenerate and you should see
23
+ After either a Docker or manual installation Jekyll should be fired up with this theme. You can now add pages, documents, data, etc.
24
+ to test your theme's contents. As you make modifications to your theme and to your content, the site will regenerate and you should see
25
25
  the changes in the browser after a refresh, just like normal.
26
26
 
27
27
  When the theme is released, only the files in `_layouts`, `_includes`, `_sass` and `assets` tracked with Git will be bundled. To add a custom directory to your
28
28
  theme-gem, please edit the regexp in `swedbankpay.gemspec` accordingly.
29
29
 
30
-
31
30
  ### Docker (recommended)
32
31
 
33
32
  1. [Clone this repository][clone].
@@ -35,7 +34,6 @@ theme-gem, please edit the regexp in `swedbankpay.gemspec` accordingly.
35
34
  3. Open a console window at the root of the repository and run `docker-compose up`.
36
35
  This will create a docker container and spin it up with everything that's specified in the repository gemfile.
37
36
  4. Open `http://localhost:4000` in a browser.
38
-
39
37
 
40
38
  ### Manual install
41
39
 
@@ -45,19 +43,17 @@ theme-gem, please edit the regexp in `swedbankpay.gemspec` accordingly.
45
43
  that.
46
44
  Note: If you're installing on Windows, choose Ruby+Devkit Installers.
47
45
  4. Open VSC and open the repository
48
- 5. Verify that Git is installed by running `git status` in VSC terminal.
46
+ 5. Verify that Git is installed by running `git status` in VSC terminal.
49
47
  If Git is not properly installed, you will see an error message like the one below. Just [download Git][git] and install.
50
48
  ![Alt text](image.png)
51
49
  6. Type `bundle install` inside the root folder of this repository.
52
50
  7. Run `bundle exec jekyll serve` to start the website.
53
51
  8. Open in a browser.
54
52
 
55
-
56
53
  ### Visual Studio Code plugins
57
54
 
58
55
  You might want to install plugins for Graphviz, JSON, Liquid, Markdown and Mermaid as this will enhance your coding experience.
59
56
 
60
-
61
57
  ## Contributing
62
58
 
63
59
  Bug reports and pull requests are welcome on [GitHub][github]. This project is
@@ -82,15 +78,11 @@ agreement][cla].
82
78
  [design-guide]: <https://design.swedbankpay.com/>
83
79
  [developer-portal]: <https://developer.swedbankpay.com/>
84
80
  [docker]: <https://www.docker.com/>
85
- [gems]: <https://rubygems.org/>
86
81
  [git]: <https://git-scm.com/downloads>
87
82
  [github]: <https://github.com/SwedbankPay/swedbank-pay-design-guide-jekyll-theme>
88
- [graphviz]: <https://graphviz.org/download/>
89
83
  [license-badge]: https://img.shields.io/github/license/SwedbankPay/swedbank-pay-design-guide-jekyll-theme
90
84
  [license]: <https://opensource.org/licenses/MIT>
91
- [liquid]: <https://jekyllrb.com/docs/liquid/>
92
85
  [opengraph-image]: <https://repository-images.githubusercontent.com/209270355/36818080-53ee-11ea-896c-082addb851a6>
93
86
  [ruby]: <https://rubyinstaller.org/downloads/archives>
94
87
  [swedbankpay]: <https://swedbankpay.github.io/swedbank-pay-design-guide-jekyll-theme/>
95
88
  [test-badge]: <https://github.com/SwedbankPay/swedbank-pay-design-guide-jekyll-theme/workflows/Test/badge.svg>
96
- [vsc-ruler]: <https://stackoverflow.com/questions/29968499/vertical-rulers-in-visual-studio-code>
data/_includes/alert.html CHANGED
@@ -4,8 +4,7 @@
4
4
  {% assign header = include.header | markdownify | remove: '<p>' | remove: '</p>' | strip %}
5
5
  {% assign body = include.body | markdownify | remove: '<p>' | remove: '</p>' | strip %}
6
6
 
7
- <div
8
- class="alert {{ type_class }}">
7
+ <div class="alert {{ type_class }}">
9
8
  {% if icon != blank and icon != empty and icon != nil %}
10
9
  <i class="material-icons alert-icon mr-3">{{ icon }}</i>
11
10
  {% endif %}
@@ -1,19 +1,23 @@
1
1
  {% capture max_width_class %}
2
- {% if page.layout == 'front-page' %}
3
- no-padding
4
- {% elsif page.card_overview %}
5
- normal-padding max-width-card-overview
6
- {% else %}
7
- normal-padding max-width
8
- {% endif %}
2
+ {% if page.layout == 'front-page' %}
3
+ no-padding
4
+ {% elsif page.card_overview %}
5
+ normal-padding max-width-card-overview
6
+ {% elsif page.release_notes %}
7
+ dg-front-page py-0
8
+ {% else %}
9
+ normal-padding max-width
10
+ {% endif %}
9
11
  {% endcapture %}
10
12
 
11
13
  <div class="doc-container {{ max_width_class | strip }}">
12
14
  <article>
13
15
  {% if page.card_overview %}
14
16
  {% include card-overview.html %}
17
+ {% elsif page.release_notes %}
18
+ {% include release_notes.html num_of_releases_to_display=5 release_notes_title="What's new in " %}
15
19
  {% else %}
16
20
  {% include anchor_headings.html html=content anchorClass='header-anchor' %}
17
21
  {% endif %}
18
22
  </article>
19
- </div>
23
+ </div>
@@ -1,30 +1,85 @@
1
- {% assign num_dates = include.num_dates %}
2
- {% for page in site.pages %}
3
- {% assign release_notes_url = '/resources/release-notes' %}
4
- {% if page.url contains release_notes_url %}
5
- <div class="release-notes-container">
6
- {% assign dates = page.content | markdownify | split: '<h2' | slice: 1, num_dates %}
7
-
8
- {% for date in dates %}
9
- <div class="row">
10
- {% assign versions = date | split: '<h3' %}
11
- {% assign date_id = date | regex_capture: 'id="([^"]+)"' | first %}
12
- <div class="col-md-2 release-notes-date">
13
- {% assign date_value = versions[0] | remove: '</h2>' | split: '>' %}
14
- <a href="{{ release_notes_url }}#{{ date_id }}">{{ date_value[1] | strip }}</a>
1
+ {% assign num_of_releases_to_display = include.num_of_releases_to_display %}
2
+ {% assign release_notes_title = include.release_notes_title %}
3
+ {% if page.url contains '/release-notes' %}
4
+ {% for sitePage in site.pages %}
5
+ {% if sitePage.url == page.url %}
6
+ {% assign min_cnt = num_of_releases_to_display | plus: 1 %}
7
+ {% assign max_cnt = sitePage.content | split: '</h2>' | size %}
8
+ {% assign releases = sitePage.content | markdownify | split: '<h2' | slice: 1, num_of_releases_to_display %}
9
+ {% assign archive = sitePage.content | markdownify | split: '<h2' | slice: min_cnt, max_cnt %}
10
+ <section class="dg-changelog-container d-flex flex-column mb-0">
11
+ <div class="container dg-changelog-content">
12
+ <div class="row mt-3">
13
+ <span class="dg-changlelog-title">
14
+ {{ release_notes_title | append: sitePage.lead_title }}
15
+ <div class="dg-changelog-divider my-2"></div>
16
+ </span>
17
+ {% include alert.html type="informative" icon="info" header="Version numbers"
18
+ body="The version numbers used in headers on this page refers to the version of
19
+ this very documentation, not to a version of any APIs described by it." %}
20
+ </div>
21
+ {% for release in releases %}
22
+ {% if forloop.length > 0 %}
23
+ {% if forloop.last %}
24
+ <div class="row pb-2 mt-4">
25
+ {% else %}
26
+ <div class="row border-bottom pb-2 mt-4">
27
+ {% endif %}
28
+ {% endif %}
29
+ {% assign versions = release | split: '<h3' %}
30
+ {% assign release_id = release | regex_capture: 'id="([^"]+)"' | first %}
31
+ <div class="col-md-2 px-0 pb-2">
32
+ {% assign release_value = versions[0] | remove: '</h2>' | split: '>' %}
33
+ {{ release_value[1] | strip }}
15
34
  </div>
16
- {% assign version_list = versions | shift %}
17
- <div class="col-md-10">
35
+ {% assign version_list = versions | shift %}
36
+ <div class="dg-changelog-description px-0">
18
37
  {% for version in version_list %}
19
38
  {% assign version_parts = version | split: '</h3>' %}
20
39
  {% assign version_value = version_parts[0] | split: '>' %}
21
40
  {% assign version_id = version | regex_capture: 'id="([^"]+)"' | first %}
22
- <p class="h4"><a href="{{ release_notes_url }}#{{ version_id }}">{{ version_value[1] }}</a></p>
23
- {{ version_parts[1] }}
41
+ <h4 class="h4">{{ version_value[1] }}</h4>
42
+ <p class="mt-2">{{ version_parts[1] }}</p>
24
43
  {% endfor %}
25
44
  </div>
26
45
  </div>
46
+ {% endfor %}
47
+ </div>
48
+
49
+ {% if archive.size > 0 %}
50
+ <div class="mb-3">
51
+ <div class="accordion ">
52
+ <button type="button" class="accordion-header" aria-expanded="false" aria-controls="archive">Archive</button>
53
+ <div class="accordion-body" id="archive">
54
+ <div class="container dg-changelog-content my-auto">
55
+ {% for archive_release in archive %}
56
+ {% assign archive_versions = archive_release | split: '<h3' %}
57
+ {% assign archive_release_id = archive_release | regex_capture: 'id="([^"]+)"' | first %}
58
+ {% assign archive_release_value = archive_versions[0] | remove: '</h2>' | split: '>' %}
59
+ {% assign archive_version_list = archive_versions | shift %}
60
+ <div class="row border-bottom pb-2 mt-4">
61
+ <div class="col-md-2 px-0 pb-2">
62
+ {{ archive_release_value[1] | strip }}
63
+ </div>
64
+ <div class="dg-changelog-description px-0">
65
+ {% for archive_version in archive_version_list %}
66
+ {% assign archive_version_parts = archive_version | split: '</h3>' %}
67
+ {% assign archive_version_value = archive_version_parts[0] | split: '>' %}
68
+ {% assign archive_version_id = archive_version | regex_capture: 'id="([^"]+)"' | first %}
69
+ <h4 class="h4">{{ archive_version_value[1] }}</h4>
70
+ <p class="mt-2">{{ version_parts[1] }}</p>
71
+ {% endfor %}
72
+ </div>
73
+ </div>
74
+ {% endfor %}
75
+ </div>
76
+ </div>
77
+ </div>
78
+ </div>
79
+ {% endif %}
80
+
81
+ </section>
82
+ {% endif %}
83
+
27
84
  {% endfor %}
28
- </div>
29
85
  {% endif %}
30
- {% endfor %}
data/lib/gem_version.rb CHANGED
@@ -4,7 +4,7 @@ module Gem
4
4
  # Gem Specification
5
5
  class Specification
6
6
  def self.gem_version
7
- '2.2.7'
7
+ '2.3.0'
8
8
  end
9
9
  end
10
10
  end
@@ -116,7 +116,7 @@ module SwedbankPay
116
116
 
117
117
  "<ul class=\"#{page.level.zero? ? 'secondary-nav-ul' : ''}\">
118
118
  #{if page.level.positive? && page.children?
119
- "<a href=\"../\" class=\"previous-nav\">
119
+ "<a href=\"#{page.path}..\" title=\"test4\" class=\"previous-nav\">
120
120
  <i class=\"material-icons\" aria-hidden=\"true\">arrow_back_ios</i>
121
121
  <span>Back to #{page.parent.title}</span>
122
122
  </a>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: swedbank-pay-design-guide-jekyll-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.7
4
+ version: 2.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Swedbank Pay
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-22 00:00:00.000000000 Z
11
+ date: 2024-04-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday