@astronox/core 0.4.10 → 0.4.12

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@astronox/core",
3
- "version": "0.4.10",
3
+ "version": "0.4.12",
4
4
  "description": "Reusable Astro components, patterns, styles, and infrastructure for AstroNox sites.",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -9,8 +9,31 @@ type Props = {
9
9
  const { config }: Props = Astro.props;
10
10
  const clientId = toAdsenseClientId(config.publisherId);
11
11
  const scriptSource = `https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=${encodeURIComponent(clientId)}`;
12
+ const adBlockingRecoverySource = `https://fundingchoicesmessages.google.com/i/${encodeURIComponent(config.publisherId)}?ers=1`;
12
13
  ---
13
14
 
15
+ <script is:inline async src={adBlockingRecoverySource}></script>
16
+ <script is:inline>
17
+ (() => {
18
+ const signalGooglefcPresent = () => {
19
+ if (window.frames['googlefcPresent']) return;
20
+
21
+ if (!document.body) {
22
+ setTimeout(signalGooglefcPresent, 0);
23
+ return;
24
+ }
25
+
26
+ const frame = document.createElement('iframe');
27
+ frame.name = 'googlefcPresent';
28
+ frame.style.cssText =
29
+ 'display: none; width: 0; height: 0; border: none; z-index: -1000; left: -1000px; top: -1000px;';
30
+ document.body.appendChild(frame);
31
+ };
32
+
33
+ signalGooglefcPresent();
34
+ })();
35
+ </script>
36
+
14
37
  <meta name="google-adsense-account" content={clientId} />
15
38
  <script is:inline async crossorigin="anonymous" src={scriptSource}></script>
16
39
 
@@ -1,3 +1,9 @@
1
+ .site-shell:has(> .scroll-to-top) {
2
+ --site-floating-control-reserve: calc(
3
+ var(--nox-section-compact-block-size) + var(--nox-space-5)
4
+ );
5
+ }
6
+
1
7
  .scroll-to-top.nox-button {
2
8
  position: fixed;
3
9
  z-index: 45;
@@ -12,7 +12,7 @@
12
12
  justify-items: center;
13
13
  gap: var(--nox-space-1);
14
14
  padding-block-end: calc(
15
- var(--nox-section-compact-block-size) + var(--nox-space-7)
15
+ var(--site-content-gap) + var(--site-floating-control-reserve, 0px)
16
16
  );
17
17
  font-size: var(--nox-font-size-sm);
18
18
  line-height: 1.25;
@@ -25,6 +25,7 @@
25
25
  align-items: center;
26
26
  justify-content: center;
27
27
  flex-wrap: wrap;
28
+ row-gap: var(--nox-space-1);
28
29
  }
29
30
 
30
31
  .site-footer__content[data-footer-columns='2'] {
@@ -148,6 +149,12 @@
148
149
  }
149
150
 
150
151
  @media (width < 48rem) {
152
+ .site-footer__content {
153
+ --site-footer-item-gap: var(--nox-space-1);
154
+
155
+ font-size: var(--nox-font-size-xs);
156
+ }
157
+
151
158
  .site-footer__content[data-footer-columns='2'] {
152
159
  grid-template-columns: minmax(0, 1fr);
153
160
  column-gap: 0;
@@ -53,6 +53,8 @@ html {
53
53
  }
54
54
 
55
55
  body {
56
+ height: 100%;
57
+ min-height: 100%;
56
58
  margin: 0;
57
59
  overflow: hidden;
58
60
  background: var(--nox-page-background);
@@ -64,14 +66,22 @@ body {
64
66
  height: 100vh;
65
67
  min-height: 100vh;
66
68
  grid-template-rows: auto minmax(0, 1fr);
69
+ padding-block-end: inherit;
67
70
  overflow: hidden;
68
71
  background: var(--nox-page-background);
69
72
  }
70
73
 
71
- @supports (height: 100dvh) {
74
+ @supports (height: 100svh) {
75
+ .site-shell {
76
+ height: 100svh;
77
+ min-height: 100svh;
78
+ }
79
+ }
80
+
81
+ @media (width >= 48rem) {
72
82
  .site-shell {
73
- height: 100dvh;
74
- min-height: 100dvh;
83
+ height: 100vh;
84
+ min-height: 100vh;
75
85
  }
76
86
  }
77
87
 
@@ -123,6 +133,8 @@ p {
123
133
  }
124
134
 
125
135
  .site-viewport {
136
+ --site-content-gap: var(--nox-space-5);
137
+
126
138
  min-width: 0;
127
139
  min-height: 0;
128
140
  overflow-x: hidden;
@@ -132,12 +144,10 @@ p {
132
144
  }
133
145
 
134
146
  .site-main {
135
- --site-main-content-gap: var(--nox-space-5);
136
-
137
147
  display: grid;
138
148
  width: var(--nox-page-width);
139
149
  margin: 0 auto;
140
- padding-block: var(--site-main-content-gap);
150
+ padding-block: var(--site-content-gap);
141
151
  align-content: start;
142
152
  }
143
153
 
@@ -145,11 +155,11 @@ p {
145
155
  display: grid;
146
156
  min-width: 0;
147
157
  align-content: start;
148
- gap: var(--site-main-content-gap);
158
+ gap: var(--site-content-gap);
149
159
  }
150
160
 
151
161
  .site-main:has(> .site-main__content > .breadcrumbs) {
152
- padding-block: 0 var(--site-main-content-gap);
162
+ padding-block: 0 var(--site-content-gap);
153
163
  }
154
164
 
155
165
  .site-main__content:has(> .breadcrumbs) {
@@ -157,8 +167,8 @@ p {
157
167
  }
158
168
 
159
169
  @media (width < 48rem) {
160
- .site-main {
161
- --site-main-content-gap: var(--nox-space-4);
170
+ .site-viewport {
171
+ --site-content-gap: var(--nox-space-4);
162
172
  }
163
173
  }
164
174