@trimble-oss/modus-docs-hugo-theme 1.0.0-alpha27 → 1.0.0-alpha29

Sign up to get free protection for your applications and to get access to all the features.
@@ -7,6 +7,7 @@
7
7
  #TableOfContents ul ul,
8
8
  #TableOfContents ul ul li {
9
9
  list-style: none;
10
+ padding-left: 0 !important;
10
11
  text-indent: 10px;
11
12
  }
12
13
 
@@ -29,8 +29,8 @@
29
29
  /* SM */
30
30
  @media (max-width: 767px) {
31
31
  #sidebar.show {
32
- min-width: calc(100% - 68px) !important;
33
- width: calc(100% - 68px) !important;
32
+ min-width: 100%;
33
+ width: 100%
34
34
  }
35
35
 
36
36
  #sidebar.show + div {
@@ -40,7 +40,7 @@
40
40
  }
41
41
 
42
42
  .col-main {
43
- max-width: calc(100vw - 81px);
43
+ width: 100%;
44
44
  }
45
45
 
46
46
  .collapse-horizontal.collapse:not(.show) {
@@ -57,7 +57,7 @@
57
57
 
58
58
  #sidebar.collapsing + div,
59
59
  #sidebar.show + div {
60
- max-width: calc(100vw - 332px);
60
+ max-width: 100%;
61
61
  }
62
62
 
63
63
  .col-sidebar .sticky-offset {
@@ -3,11 +3,11 @@
3
3
  }
4
4
 
5
5
  .sun-and-moon > :is(.moon, .sun) {
6
- fill: var(--icon-fill);
6
+ fill: #fff;
7
7
  }
8
8
 
9
9
  .sun-and-moon > .sun-beams {
10
- stroke: var(--icon-fill);
10
+ stroke: #fff;
11
11
  stroke-width: 2px;
12
12
  }
13
13
 
@@ -44,10 +44,6 @@
44
44
  }
45
45
  }
46
46
 
47
- [data-bs-theme="dark"] .sun-and-moon > :is(.moon, .sun) {
48
- fill: rgb(255, 255, 255);
49
- }
50
-
51
47
  [data-bs-theme="dark"] .sun-and-moon > .sun {
52
48
  transform: scale(1.75);
53
49
  transition-duration: 0.25s;
@@ -66,8 +62,6 @@
66
62
  }
67
63
 
68
64
  .theme-toggle {
69
- --icon-fill: rgb(0, 0, 0);
70
-
71
65
  aspect-ratio: 1;
72
66
  cursor: pointer;
73
67
  -webkit-tap-highlight-color: transparent;
@@ -4,7 +4,6 @@
4
4
  @import "autocomplete"; // search autocomplete dropdown
5
5
  @import "article";
6
6
  @import "cards";
7
- @import "col-sidebar"; // 1st column
8
7
  @import "codefences"; // code syntax highlighting
9
8
  @import "codefences-dark"; // code syntax highlighting
10
9
  @import "javascript-disabled"; // display message at top if JS is disabled
@@ -1,4 +1,4 @@
1
1
  <a href="{{- .Destination | safeURL -}}" {{ with .Title}} title="{{- . -}}"
2
2
  {{- end -}}{{ if strings.HasPrefix .Destination "http" }} target="_blank" rel="noopener" {{- end -}}>
3
3
  {{- .Text | safeHTML -}}
4
- </a>
4
+ </a>{{- /* trim whitespace */ -}}
@@ -2,30 +2,13 @@
2
2
 
3
3
  <div class="container-fluid">
4
4
  <div class="row row-main px-0">
5
-
6
- <div class="col-1 col-sidebar px-0 bg-body shadow-sm">
7
- {{ partial "col-sidebar" . }}
8
- </div>
9
-
10
5
  <div class="col col-auto px-0 collapse collapse-horizontal bg-dark bg-opacity-10" id="sidebar">
11
6
  <div id="sidebar-menu" class="z-2 sticky-top sticky-offset shadow-sm overflow-auto w-100">
12
7
  {{ partial "col-sidebar-menu" . }}
13
8
  </div>
14
9
  </div>
15
10
 
16
- <div class="col col-auto col-12 col-main border-start border-secondary border-opacity-10 p-0 overflow-x-hidden">
17
-
18
- <script>
19
- function _calculateScrollbarWidth() {
20
- document.documentElement.style.setProperty('--scrollbar-width', (window.innerWidth - document.documentElement.clientWidth) + "px");
21
- }
22
- // recalculate on resize
23
- window.addEventListener('resize', _calculateScrollbarWidth, false);
24
- // recalculate on dom load
25
- document.addEventListener('DOMContentLoaded', _calculateScrollbarWidth, false);
26
- // recalculate on load (assets loaded as well)
27
- window.addEventListener('load', _calculateScrollbarWidth);
28
- </script>
11
+ <div class="col col-main border-start border-secondary border-opacity-10 p-0 overflow-x-hidden">
29
12
 
30
13
  <main id="main" class="container">
31
14
 
@@ -2,11 +2,6 @@
2
2
 
3
3
  <div class="container-fluid">
4
4
  <div class="row row-main px-0">
5
-
6
- <div class="col-1 col-sidebar px-0 bg-body shadow-sm">
7
- {{ partial "col-sidebar" . }}
8
- </div>
9
-
10
5
  <div class="col col-auto px-0 collapse collapse-horizontal bg-dark bg-opacity-10 show" id="sidebar">
11
6
  <div id="sidebar-menu" class="sticky-top sticky-offset shadow-sm overflow-auto"
12
7
  style="min-height: calc(100vh - 66px);max-height: calc(100vh - 66px);">
@@ -14,7 +9,7 @@
14
9
  </div>
15
10
  </div>
16
11
 
17
- <div class="col col-auto col-12 col-main border-start border-secondary border-opacity-10 p-0">
12
+ <div class="col col-main border-start border-secondary border-opacity-10 p-0">
18
13
  <div class="mx-auto mw-100">
19
14
 
20
15
  {{ partial "header" . }}
@@ -2,18 +2,13 @@
2
2
 
3
3
  <div class="container-fluid">
4
4
  <div class="row row-main px-0">
5
-
6
- <div class="col-1 col-sidebar px-0 bg-body shadow-sm">
7
- {{ partial "col-sidebar" . }}
8
- </div>
9
-
10
5
  <div class="col col-auto px-0 collapse collapse-horizontal bg-dark bg-opacity-10" id="sidebar">
11
6
  <div id="sidebar-menu" class="z-2 sticky-top sticky-offset shadow-sm overflow-auto w-100">
12
7
  {{ partial "col-sidebar-menu" . }}
13
8
  </div>
14
9
  </div>
15
10
 
16
- <div class="col col-auto col-12 col-main border-start border-secondary border-opacity-10 p-0 overflow-y-hidden">
11
+ <div class="col col-main border-start border-secondary border-opacity-10 p-0 overflow-y-hidden">
17
12
 
18
13
  {{ partial "header" . }}
19
14
 
@@ -1,16 +1,17 @@
1
1
  <div class="sticky-top sticky-offset">
2
2
  {{ if and (gt .WordCount 200 ) (not .Params.hideToc) }}
3
- <div class="h5 pt-2 ml-3 on-this-page">
3
+ <div class="h5 pt-2 ms-1 on-this-page">
4
4
  On this page
5
5
  </div>
6
6
  {{- .TableOfContents -}}
7
7
  <script>
8
8
  document.addEventListener('DOMContentLoaded', function () {
9
9
  document.querySelectorAll('#TableOfContents ul').forEach(function (ul) {
10
- ul.classList.add('list-unstyled', 'pl-0', 'ml-0');
10
+ ul.classList.add('list-unstyled', 'ps-1');
11
11
  });
12
12
  document.querySelectorAll('#TableOfContents a').forEach(function (a) {
13
13
  a.classList.add('nav-link');
14
+ a.classList.add('ps-1');
14
15
  });
15
16
  });
16
17
  </script>
@@ -23,6 +23,8 @@
23
23
  {{ partial "navbar-search" . }}
24
24
  {{ end }}
25
25
 
26
+ {{ partial "navbar-theme-toggle" . }}
27
+
26
28
  {{- with .Site.Params.RemoveSearch -}}{{else}}
27
29
  <div class="dropdown">
28
30
  <button type="button" class="btn btn-lg btn-primary bg-transparent btn-icon-only"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trimble-oss/modus-docs-hugo-theme",
3
- "version": "1.0.0-alpha27",
3
+ "version": "1.0.0-alpha29",
4
4
  "description": "A Documentation theme for Hugo built by Trimble",
5
5
  "homepage": "https://github.com/trimble-oss/modus-docs-hugo-theme",
6
6
  "bugs": {
@@ -28,20 +28,20 @@
28
28
  "svgo": "npx svgo --folder=\"static/img/icons/\""
29
29
  },
30
30
  "dependencies": {
31
- "@trimble-oss/modus-bootstrap": "^2.0.2",
32
- "@trimble-oss/modus-icons": "^1.15.0"
31
+ "@trimble-oss/modus-bootstrap": "^2.0.7",
32
+ "@trimble-oss/modus-icons": "^1.16.0"
33
33
  },
34
34
  "devDependencies": {
35
35
  "autoprefixer": "10.4.20",
36
36
  "eslint": "8.57.1",
37
37
  "eslint-config-prettier": "9.1.0",
38
38
  "htmlhint": "1.1.4",
39
- "hugo-bin": "0.131.3",
40
- "postcss": "8.4.47",
39
+ "hugo-bin": "0.140.1",
40
+ "postcss": "8.5.1",
41
41
  "postcss-cli": "11.0.0",
42
- "prettier": "3.3.3",
43
- "stylelint": "16.9.0",
44
- "stylelint-config-standard-scss": "13.1.0",
42
+ "prettier": "3.4.2",
43
+ "stylelint": "16.14.1",
44
+ "stylelint-config-standard-scss": "14.0.0",
45
45
  "stylelint-order": "6.0.4"
46
46
  },
47
47
  "hugo-bin": {
@@ -57,6 +57,6 @@
57
57
  "node": ">=18.0.0"
58
58
  },
59
59
  "volta": {
60
- "node": "20.17.0"
60
+ "node": "20.18.1"
61
61
  }
62
62
  }
@@ -1,27 +0,0 @@
1
- .col-sidebar {
2
- width: 64px !important;
3
- }
4
-
5
- .col-sidebar .list-group {
6
- height: calc(100dvh - 66px);
7
- }
8
-
9
- [data-bs-theme="light"] {
10
- .col-sidebar a.btn:hover,
11
- .col-sidebar button:hover {
12
- background-color: #e0e1e9 !important;
13
- }
14
- }
15
-
16
- [data-bs-theme="dark"] {
17
- .col-sidebar a.btn:hover,
18
- .col-sidebar button:hover {
19
- background-color: #424649 !important;
20
- }
21
- }
22
-
23
- .col-sidebar button.list-group-item {
24
- height: 48px;
25
- margin-left: 6px;
26
- width: 48px;
27
- }
@@ -1,21 +0,0 @@
1
- <div
2
- class="list-group d-block border-0 text-center sticky-top sticky-offset d-flex flex-column align-items-start justify-content-between">
3
-
4
- <div class="mx-auto w-100">
5
- </div>
6
-
7
- <div>
8
- {{- with .Site.Params.GitHubRepo -}}
9
- <a href="{{- . -}}"
10
- class="btn btn-lg btn-outline-secondary text-body bg-transparent btn-icon-only border-0 mx-1 p-1" target="_blank"
11
- rel="noopener" data-bs-toggle="tooltip" title="GitHub">
12
- {{ partial "icons/brands/github.svg" (dict "class" "mt-2" "width" "24" "height" "24") }}
13
- </a>
14
- {{ end }}
15
-
16
- {{- if not .Site.Params.disableThemeToggle -}}
17
- {{ partial "btn-theme-toggle" . }}
18
- {{ end }}
19
- </div>
20
-
21
- </div>