@trimble-oss/modus-docs-hugo-theme 1.0.0-alpha1 → 1.0.0-alpha11

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.
Files changed (92) hide show
  1. package/README.md +7 -7
  2. package/assets/{styles → css}/_article.scss +24 -11
  3. package/assets/css/_navbar-search.scss +54 -0
  4. package/assets/{styles → css}/_navbar.scss +4 -0
  5. package/assets/{styles → css}/_skippy.scss +2 -2
  6. package/assets/css/_tables.scss +34 -0
  7. package/assets/{styles → css}/_was-this-page-helpful.scss +3 -3
  8. package/assets/js/theme-toggle.js +1 -0
  9. package/assets/js/was-this-page-helpful.js +10 -3
  10. package/data/navbar_apps.yml +8 -4
  11. package/layouts/_default/_markup/render-link.html +3 -3
  12. package/layouts/_default/baseof.html +6 -3
  13. package/layouts/_default/redirect.html +1 -1
  14. package/layouts/_default/single.html +4 -4
  15. package/layouts/index.json +1 -1
  16. package/layouts/partials/analytics.html +6 -3
  17. package/layouts/partials/blog-brief.html +4 -4
  18. package/layouts/partials/blog-share.html +6 -6
  19. package/layouts/partials/btn-theme-toggle.html +3 -2
  20. package/layouts/partials/col-sidebar-menu.html +1 -1
  21. package/layouts/partials/col-sidebar.html +13 -10
  22. package/layouts/partials/header.html +2 -2
  23. package/layouts/partials/icons/brands/codepen.svg +1 -1
  24. package/layouts/partials/icons/brands/facebook-square.svg +1 -1
  25. package/layouts/partials/icons/brands/github-alt.svg +1 -1
  26. package/layouts/partials/icons/brands/github.svg +1 -1
  27. package/layouts/partials/icons/brands/linkedin.svg +1 -1
  28. package/layouts/partials/icons/brands/vimeo-square.svg +1 -1
  29. package/layouts/partials/icons/modus-outlined/accessibility-circle.svg +1 -1
  30. package/layouts/partials/icons/modus-outlined/arrow-up.svg +1 -1
  31. package/layouts/partials/icons/modus-outlined/bar-graph-square.svg +1 -1
  32. package/layouts/partials/icons/modus-outlined/code.svg +3 -0
  33. package/layouts/partials/icons/modus-outlined/launch.svg +1 -1
  34. package/layouts/partials/icons/modus-outlined/menu.svg +1 -1
  35. package/layouts/partials/icons/modus-outlined/more-vertical.svg +1 -1
  36. package/layouts/partials/icons/modus-outlined/person-account.svg +1 -1
  37. package/layouts/partials/icons/modus-outlined/search.svg +1 -1
  38. package/layouts/partials/icons/modus-outlined/sync.svg +1 -1
  39. package/layouts/partials/icons/modus-outlined/thumbs-down.svg +1 -1
  40. package/layouts/partials/icons/modus-outlined/thumbs-up.svg +1 -1
  41. package/layouts/partials/icons/modus-outlined/web.svg +1 -1
  42. package/layouts/partials/icons/modus-solid/code.svg +3 -0
  43. package/layouts/partials/icons/modus-solid/email.svg +1 -1
  44. package/layouts/partials/icons/modus-solid/menu.svg +3 -0
  45. package/layouts/partials/icons/modus-solid/palette.svg +1 -1
  46. package/layouts/partials/icons/modus-solid/thumbs-down.svg +3 -0
  47. package/layouts/partials/icons/modus-solid/thumbs-up.svg +3 -0
  48. package/layouts/partials/icons/modus-solid/trimble-logo.svg +3 -0
  49. package/layouts/partials/icons/modus-solid/user-guide.svg +3 -0
  50. package/layouts/partials/icons/transportation/truck.svg +1 -1
  51. package/layouts/partials/logos/trimble.svg +1 -1
  52. package/layouts/partials/meta.html +26 -16
  53. package/layouts/partials/navbar-dropdown.html +4 -2
  54. package/layouts/partials/navbar-search.html +3 -3
  55. package/layouts/partials/navbar.html +14 -10
  56. package/layouts/partials/skippy.html +4 -4
  57. package/layouts/partials/was-this-page-helpful.html +8 -4
  58. package/layouts/shortcodes/example.html +2 -2
  59. package/package.json +21 -14
  60. package/static/img/icons/check-circle-outlined.svg +1 -0
  61. package/static/img/icons/code.svg +1 -0
  62. package/static/img/icons/github.svg +1 -0
  63. package/static/img/icons/trimble.svg +1 -0
  64. package/static/img/icons/web-components.svg +1 -0
  65. package/assets/styles/_navbar-search.scss +0 -53
  66. package/assets/styles/_tables.scss +0 -5
  67. package/layouts/index.rss.xml +0 -49
  68. package/layouts/partials/icons/trimble-logo.svg +0 -1
  69. package/static/js/theme-toggle.js +0 -48
  70. package/assets/{styles → css}/_autocomplete.scss +11 -11
  71. package/assets/{styles → css}/_cards.scss +3 -3
  72. package/assets/{styles → css}/_codefences-dark.scss +0 -0
  73. package/assets/{styles → css}/_codefences.scss +0 -0
  74. package/assets/{styles → css}/_col-sidebar.scss +0 -0
  75. package/assets/{styles → css}/_font-open-sans.scss +0 -0
  76. package/assets/{styles → css}/_footer.scss +0 -0
  77. package/assets/{styles → css}/_javascript-disabled.scss +3 -3
  78. package/assets/{styles → css}/_list-js.scss +6 -6
  79. package/assets/{styles → css}/_menu-right.scss +5 -5
  80. package/assets/{styles → css}/_mobile.scss +2 -2
  81. package/assets/{styles → css}/_news.scss +1 -1
  82. package/assets/{styles → css}/_onetrust-cookie-banner.scss +9 -9
  83. package/assets/{styles → css}/_posts.scss +2 -2
  84. package/assets/{styles → css}/_print.scss +0 -0
  85. package/assets/{styles → css}/_scroll-to-top-btn.scss +5 -5
  86. package/assets/{styles → css}/_sidebar.scss +0 -0
  87. package/assets/{styles → css}/_theme-dark.scss +0 -0
  88. package/assets/{styles → css}/_theme-light.scss +0 -0
  89. package/assets/{styles → css}/_theme-toggle.scss +3 -3
  90. /package/assets/{styles → css}/_utilities.scss +0 -0
  91. /package/assets/{styles → css}/_xxl.scss +0 -0
  92. /package/assets/{styles/styles.scss → css/modus-docs.scss} +0 -0
@@ -1,48 +0,0 @@
1
- // script adapted from Adam Argyle's tutorial: https://web.dev/building-a-theme-switch-component/
2
-
3
- const storageKey = 'theme-preference';
4
-
5
- const onClick = () => {
6
- theme.value = theme.value === 'light' ? 'dark' : 'light';
7
-
8
- setPreference();
9
- };
10
-
11
- const getColorPreference = () => {
12
- if (localStorage.getItem(storageKey)) return localStorage.getItem(storageKey);
13
- else
14
- return window.matchMedia('(prefers-color-scheme: dark)').matches
15
- ? 'dark'
16
- : 'light';
17
- };
18
-
19
- const setPreference = () => {
20
- localStorage.setItem(storageKey, theme.value);
21
- reflectPreference();
22
- };
23
-
24
- const reflectPreference = () => {
25
- document.firstElementChild.setAttribute('data-bs-theme', theme.value);
26
-
27
- document
28
- .querySelector('#theme-toggle')
29
- ?.setAttribute('aria-label', theme.value);
30
- };
31
-
32
- const theme = {
33
- value: getColorPreference(),
34
- };
35
-
36
- reflectPreference();
37
-
38
- window.onload = () => {
39
- reflectPreference();
40
- document.querySelector('#theme-toggle').addEventListener('click', onClick);
41
- };
42
-
43
- window
44
- .matchMedia('(prefers-color-scheme: dark)')
45
- .addEventListener('change', ({ matches: isDark }) => {
46
- theme.value = isDark ? 'dark' : 'light';
47
- setPreference();
48
- });
@@ -1,17 +1,17 @@
1
1
  /*! purgecss start ignore */
2
2
  .autocomplete-suggestions {
3
- cursor: default;
3
+ background-color: #fff;
4
4
  border: 1px solid #cbcdd6;
5
5
  border-top: 0;
6
- background-color: #fff;
7
6
  box-shadow: -1px 1px 3px rgba(0, 0, 0, 0.1);
8
- position: absolute;
7
+ box-sizing: border-box;
8
+ cursor: default;
9
9
  display: none;
10
- z-index: 33333; // higher than navbar
11
10
  max-height: 254px;
12
11
  overflow: hidden;
13
12
  overflow-y: auto;
14
- box-sizing: border-box;
13
+ position: absolute;
14
+ z-index: 33333; // higher than navbar
15
15
  }
16
16
 
17
17
  [data-bs-theme="dark"] {
@@ -26,19 +26,19 @@
26
26
  }
27
27
 
28
28
  .autocomplete-suggestion {
29
- position: relative;
29
+ color: #353a40;
30
30
  cursor: pointer;
31
- padding: 7px;
32
31
  line-height: 23px;
33
- white-space: nowrap;
34
32
  overflow: hidden;
33
+ padding: 7px;
34
+ position: relative;
35
35
  text-overflow: ellipsis;
36
- color: #353a40;
36
+ white-space: nowrap;
37
37
  }
38
38
 
39
39
  .autocomplete-suggestion b {
40
- font-weight: 400;
41
40
  color: #1f8dd6;
41
+ font-weight: 400;
42
42
  }
43
43
 
44
44
  .autocomplete-suggestion.selected {
@@ -52,8 +52,8 @@
52
52
  }
53
53
 
54
54
  .autocomplete-suggestion > .context {
55
- font-size: 12px;
56
55
  color: #7d808d;
56
+ font-size: 12px;
57
57
  }
58
58
 
59
59
  .autocomplete-suggestion.selected > .context {
@@ -18,8 +18,8 @@
18
18
  }
19
19
 
20
20
  .card-post .card-header {
21
- min-height: 89px;
22
- background-size: cover;
23
- background-position: center;
24
21
  aspect-ratio: 4 / 1;
22
+ background-position: center;
23
+ background-size: cover;
24
+ min-height: 89px;
25
25
  }
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1,7 +1,7 @@
1
1
  .no-js input,
2
2
  .no-js a[data-toggle] {
3
- pointer-events: none !important;
4
3
  opacity: 0.65;
4
+ pointer-events: none !important;
5
5
  }
6
6
 
7
7
  .no-js nav.navbar {
@@ -9,12 +9,12 @@
9
9
  }
10
10
 
11
11
  .no-js body::before {
12
- height: 32px;
13
12
  background-color: #e0e1e9;
14
- text-align: center;
15
13
  content: "⚠️ JavaScript is disabled. This site requires JavaScript to be enabled ⚠️";
16
14
  display: block;
15
+ height: 32px;
17
16
  position: fixed;
17
+ text-align: center;
18
18
  top: 0;
19
19
  width: 100%;
20
20
  z-index: 1;
@@ -1,13 +1,13 @@
1
1
  .list:empty::before {
2
+ background-color: rgba(133, 133, 133, 0.1);
3
+ border-radius: 0.5rem;
4
+ content: "Nothing found, try searching again.";
2
5
  display: block;
3
- width: 100%;
4
- padding: 100px 2rem;
5
- margin-right: 15px;
6
6
  margin-left: 15px;
7
+ margin-right: 15px;
8
+ padding: 100px 2rem;
7
9
  text-align: center;
8
- content: "Nothing found, try searching again.";
9
- background-color: rgba(133, 133, 133, 0.1);
10
- border-radius: 0.5rem;
10
+ width: 100%;
11
11
  }
12
12
 
13
13
  [data-bs-theme="dark"] {
@@ -12,15 +12,15 @@
12
12
 
13
13
  // right menu
14
14
  #TableOfContents li a {
15
- padding-top: 0.3rem;
16
- padding-bottom: 0.3rem;
17
- font-size: 13px;
18
15
  border-left: 1px solid transparent;
16
+ font-size: 13px;
17
+ padding-bottom: 0.3rem;
18
+ padding-top: 0.3rem;
19
19
  }
20
20
 
21
21
  .menu-right a {
22
- font-size: 13px;
23
22
  color: #171c1e;
23
+ font-size: 13px;
24
24
  }
25
25
 
26
26
  [data-bs-theme="dark"] {
@@ -50,6 +50,6 @@ hr {
50
50
 
51
51
  // scrollspy color
52
52
  .menu-right #TableOfContents li .active {
53
- color: #000 !important;
54
53
  border-left: 1px solid #0d6aa8 !important;
54
+ color: #000 !important;
55
55
  }
@@ -29,8 +29,8 @@
29
29
  /* SM */
30
30
  @media (max-width: 767px) {
31
31
  #sidebar.show {
32
- width: calc(100% - 68px) !important;
33
32
  min-width: calc(100% - 68px) !important;
33
+ width: calc(100% - 68px) !important;
34
34
  }
35
35
 
36
36
  #sidebar.show + div {
@@ -46,7 +46,7 @@
46
46
  /* SM Only */
47
47
  @media (min-width: 575px) and (max-width: 767px) {
48
48
  #sidebar-menu .list-unstyled li {
49
- width: 50%;
50
49
  display: inline-block;
50
+ width: 50%;
51
51
  }
52
52
  }
@@ -1,6 +1,6 @@
1
1
  body[data-url^="/news/"] header {
2
2
  aspect-ratio: 4 / 1;
3
- background-size: cover;
4
3
  background-position: center;
4
+ background-size: cover;
5
5
  min-height: 200px;
6
6
  }
@@ -16,25 +16,25 @@
16
16
  #onetrust-accept-btn-handler {
17
17
  background-color: #0063a3 !important;
18
18
  border-color: #0063a3 !important;
19
- padding: 0.1875rem 1rem !important;
20
19
  font-size: 0.8rem !important;
21
20
  font-weight: 600 !important;
22
- user-select: none !important;
23
21
  line-height: 1.75 !important;
22
+ padding: 0.1875rem 1rem !important;
24
23
  text-transform: lowercase !important;
24
+ user-select: none !important;
25
25
  }
26
26
 
27
27
  /** 'Cookie Settings' button **/
28
28
  #onetrust-pc-btn-handler {
29
- color: #0063a3 !important;
30
29
  border: 1px solid #0063a3 !important;
30
+ color: #0063a3 !important;
31
31
  font-size: 0.8rem !important;
32
32
  font-weight: 600 !important;
33
- padding: 0.1875rem 1rem !important;
34
- user-select: none !important;
35
33
  line-height: 1.75 !important;
34
+ padding: 0.1875rem 1rem !important;
36
35
  text-decoration: none !important;
37
36
  text-transform: lowercase !important;
37
+ user-select: none !important;
38
38
  }
39
39
 
40
40
  /** capitalize first letter of button **/
@@ -57,9 +57,9 @@
57
57
 
58
58
  /* stylelint-disable-next-line */
59
59
  #onetrust-banner-sdk.otFlat {
60
- max-width: 998px;
61
60
  margin-left: auto !important;
62
61
  margin-right: auto !important;
62
+ max-width: 998px;
63
63
  overflow-y: hidden !important;
64
64
  }
65
65
 
@@ -87,8 +87,8 @@
87
87
  }
88
88
 
89
89
  .ot-table-header {
90
- position: static !important;
91
90
  border-bottom-width: 2px !important;
91
+ position: static !important;
92
92
  }
93
93
 
94
94
  #ot-sdk-cookie-policy-v2 table,
@@ -140,17 +140,17 @@
140
140
 
141
141
  .ot-acc-txt,
142
142
  .ot-acc-txt p {
143
- color: #252a2e !important;
144
143
  background-color: #f1f1f6 !important;
144
+ color: #252a2e !important;
145
145
  }
146
146
 
147
147
  #ot-sdk-btn {
148
148
  border-color: #0063a3 !important;
149
149
  font-size: 14px !important;
150
+ line-height: 1.75 !important;
150
151
  padding: 0.1875rem 1rem !important;
151
152
  text-transform: lowercase;
152
153
  user-select: none !important;
153
- line-height: 1.75 !important;
154
154
  }
155
155
 
156
156
  #ot-sdk-btn::first-letter {
@@ -1,11 +1,11 @@
1
1
  // blog posts
2
2
  header.header-blog {
3
- background-size: cover;
4
- min-height: 90px;
5
3
  aspect-ratio: 21/9;
6
4
  background-position: center;
5
+ background-size: cover;
7
6
  border-radius: 8px;
8
7
  max-height: 600px;
8
+ min-height: 90px;
9
9
  }
10
10
 
11
11
  .share svg {
File without changes
@@ -1,14 +1,14 @@
1
1
  .btn-to-top {
2
- font-size: 18px;
3
- line-height: 48px !important;
4
2
  background-color: #353a40 !important;
5
- width: 48px;
6
3
  bottom: 20px;
7
- right: 20px;
8
- z-index: 6000;
4
+ font-size: 18px;
5
+ line-height: 48px !important;
9
6
  opacity: 0;
7
+ right: 20px;
10
8
  transform: translateY(100px);
11
9
  transition: all 1s ease;
10
+ width: 48px;
11
+ z-index: 6000;
12
12
  }
13
13
 
14
14
  .btn-to-top-show {
File without changes
File without changes
File without changes
@@ -50,8 +50,8 @@
50
50
 
51
51
  [data-bs-theme="dark"] .sun-and-moon > .sun {
52
52
  transform: scale(1.75);
53
- transition-timing-function: cubic-bezier(0.25, 0, 0.3, 1);
54
53
  transition-duration: 0.25s;
54
+ transition-timing-function: cubic-bezier(0.25, 0, 0.3, 1);
55
55
  }
56
56
 
57
57
  [data-bs-theme="dark"] .sun-and-moon > .sun-beams {
@@ -70,13 +70,13 @@
70
70
 
71
71
  aspect-ratio: 1;
72
72
  cursor: pointer;
73
- touch-action: manipulation;
74
73
  -webkit-tap-highlight-color: transparent;
74
+ touch-action: manipulation;
75
75
  }
76
76
 
77
77
  .theme-toggle > svg {
78
- inline-size: 100%;
79
78
  block-size: 100%;
79
+ inline-size: 100%;
80
80
  max-height: 18px;
81
81
  max-width: 18px;
82
82
  stroke-linecap: round;
File without changes
File without changes