@rdna/radiants 0.1.4 → 0.1.6
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/components/core/AppWindow/AppWindow.tsx +61 -61
- package/fonts/.gitkeep +0 -0
- package/fonts/Mondwest-Bold.woff2 +0 -0
- package/fonts/Mondwest.woff2 +0 -0
- package/fonts/PixeloidSans-Bold.woff2 +0 -0
- package/fonts/PixeloidSans.woff2 +0 -0
- package/fonts/WavesBlackletterCPC-Base.woff2 +0 -0
- package/fonts/WavesBlackletterCPC-Inline.woff2 +0 -0
- package/fonts/WavesBlackletterCPC-Shadow.woff2 +0 -0
- package/fonts/WavesTinyCPC-Extended.woff2 +0 -0
- package/fonts-editorial.css +16 -0
- package/fonts.css +2 -0
- package/package.json +2 -3
- package/patterns/pretext-type-scale.ts +1 -1
|
@@ -216,60 +216,35 @@ function AppWindowTitleBar({
|
|
|
216
216
|
|
|
217
217
|
return (
|
|
218
218
|
<div
|
|
219
|
-
className="flex items-center gap-3 pl-
|
|
219
|
+
className="flex items-center gap-3 pl-1 pr-2 py-1.5 h-fit cursor-move select-none"
|
|
220
220
|
data-drag-handle={presentation === 'window' ? '' : undefined}
|
|
221
221
|
style={presentation === 'window' ? { touchAction: 'none' } : undefined}
|
|
222
222
|
>
|
|
223
|
-
<
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
>
|
|
227
|
-
{title}
|
|
228
|
-
</span>
|
|
229
|
-
|
|
230
|
-
{/* Portal slot for app-injected title bar content */}
|
|
231
|
-
<div id={`window-titlebar-slot-${id}`} className="contents" />
|
|
232
|
-
|
|
233
|
-
<div className="flex-1">
|
|
234
|
-
<Separator />
|
|
235
|
-
</div>
|
|
236
|
-
|
|
237
|
-
<div className="flex items-center gap-1 text-head pr-1.5">
|
|
238
|
-
{showActionButton && actionButton ? (
|
|
239
|
-
actionButton.href ? (
|
|
240
|
-
<Button
|
|
241
|
-
mode="pattern"
|
|
242
|
-
size="sm"
|
|
243
|
-
icon={actionButton.iconName ?? undefined}
|
|
244
|
-
className="shrink-0"
|
|
245
|
-
href={actionButton.href}
|
|
246
|
-
target={actionButton.target}
|
|
247
|
-
rel={actionButton.target === '_blank' ? 'noopener noreferrer' : undefined}
|
|
248
|
-
onClick={actionButton.onClick}
|
|
249
|
-
>
|
|
250
|
-
{actionButton.text}
|
|
251
|
-
</Button>
|
|
252
|
-
) : (
|
|
223
|
+
<div className="flex items-center gap-1 text-head pl-1.5">
|
|
224
|
+
{showCloseButton && onClose ? (
|
|
225
|
+
<Tooltip content="Close">
|
|
253
226
|
<Button
|
|
254
|
-
|
|
227
|
+
tone="danger"
|
|
255
228
|
size="sm"
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
{
|
|
261
|
-
|
|
262
|
-
|
|
229
|
+
rounded="sm"
|
|
230
|
+
iconOnly
|
|
231
|
+
icon="close"
|
|
232
|
+
onClick={onClose}
|
|
233
|
+
aria-label={`Close ${title}`}
|
|
234
|
+
/>
|
|
235
|
+
</Tooltip>
|
|
263
236
|
) : null}
|
|
264
237
|
|
|
265
|
-
{
|
|
266
|
-
<Tooltip content={
|
|
238
|
+
{showFullscreenButton && onFullscreen ? (
|
|
239
|
+
<Tooltip content={presentation === 'fullscreen' ? 'Exit fullscreen' : 'Enter fullscreen'}>
|
|
267
240
|
<Button
|
|
241
|
+
tone="accent"
|
|
268
242
|
size="sm"
|
|
243
|
+
rounded="sm"
|
|
269
244
|
iconOnly
|
|
270
|
-
icon=
|
|
271
|
-
onClick={
|
|
272
|
-
aria-label={`${
|
|
245
|
+
icon={presentation === 'fullscreen' ? 'collapse' : 'expand'}
|
|
246
|
+
onClick={onFullscreen}
|
|
247
|
+
aria-label={`${presentation === 'fullscreen' ? 'Exit' : 'Enter'} fullscreen ${title}`}
|
|
273
248
|
/>
|
|
274
249
|
</Tooltip>
|
|
275
250
|
) : null}
|
|
@@ -288,34 +263,59 @@ function AppWindowTitleBar({
|
|
|
288
263
|
</Tooltip>
|
|
289
264
|
) : null}
|
|
290
265
|
|
|
291
|
-
{
|
|
292
|
-
<Tooltip content={
|
|
266
|
+
{showWidgetButton && onWidget ? (
|
|
267
|
+
<Tooltip content={widgetActive ? 'Exit widget mode' : 'Widget mode'}>
|
|
293
268
|
<Button
|
|
294
|
-
tone="accent"
|
|
295
269
|
size="sm"
|
|
296
|
-
rounded="sm"
|
|
297
270
|
iconOnly
|
|
298
|
-
icon=
|
|
299
|
-
onClick={
|
|
300
|
-
aria-label={`${
|
|
271
|
+
icon="picture-in-picture"
|
|
272
|
+
onClick={onWidget}
|
|
273
|
+
aria-label={`${widgetActive ? 'Exit' : 'Enter'} widget mode for ${title}`}
|
|
301
274
|
/>
|
|
302
275
|
</Tooltip>
|
|
303
276
|
) : null}
|
|
304
277
|
|
|
305
|
-
{
|
|
306
|
-
|
|
278
|
+
{showActionButton && actionButton ? (
|
|
279
|
+
actionButton.href ? (
|
|
307
280
|
<Button
|
|
308
|
-
|
|
281
|
+
mode="pattern"
|
|
309
282
|
size="sm"
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
283
|
+
icon={actionButton.iconName ?? undefined}
|
|
284
|
+
className="shrink-0"
|
|
285
|
+
href={actionButton.href}
|
|
286
|
+
target={actionButton.target}
|
|
287
|
+
rel={actionButton.target === '_blank' ? 'noopener noreferrer' : undefined}
|
|
288
|
+
onClick={actionButton.onClick}
|
|
289
|
+
>
|
|
290
|
+
{actionButton.text}
|
|
291
|
+
</Button>
|
|
292
|
+
) : (
|
|
293
|
+
<Button
|
|
294
|
+
mode="pattern"
|
|
295
|
+
size="sm"
|
|
296
|
+
icon={actionButton.iconName ?? undefined}
|
|
297
|
+
className="shrink-0"
|
|
298
|
+
onClick={actionButton.onClick}
|
|
299
|
+
>
|
|
300
|
+
{actionButton.text}
|
|
301
|
+
</Button>
|
|
302
|
+
)
|
|
317
303
|
) : null}
|
|
318
304
|
</div>
|
|
305
|
+
|
|
306
|
+
<span
|
|
307
|
+
id={`window-title-${id}`}
|
|
308
|
+
className="absolute left-1/2 -translate-x-1/2 font-joystix text-xs uppercase tracking-tight text-head whitespace-nowrap pointer-events-none bg-page px-2 py-0.5"
|
|
309
|
+
>
|
|
310
|
+
{title}
|
|
311
|
+
</span>
|
|
312
|
+
|
|
313
|
+
<div className="flex-1">
|
|
314
|
+
<Separator />
|
|
315
|
+
</div>
|
|
316
|
+
|
|
317
|
+
{/* Portal slot for app-injected title bar content */}
|
|
318
|
+
<div id={`window-titlebar-slot-${id}`} className="contents" />
|
|
319
319
|
</div>
|
|
320
320
|
);
|
|
321
321
|
}
|
package/fonts/.gitkeep
ADDED
|
File without changes
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/fonts-editorial.css
CHANGED
|
@@ -14,6 +14,22 @@
|
|
|
14
14
|
font-display: optional;
|
|
15
15
|
}
|
|
16
16
|
|
|
17
|
+
@font-face {
|
|
18
|
+
font-family: 'Waves Blackletter CPC Shadow';
|
|
19
|
+
src: url('./fonts/WavesBlackletterCPC-Shadow.woff2') format('woff2');
|
|
20
|
+
font-weight: 400;
|
|
21
|
+
font-style: normal;
|
|
22
|
+
font-display: optional;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
@font-face {
|
|
26
|
+
font-family: 'Waves Blackletter CPC Inline';
|
|
27
|
+
src: url('./fonts/WavesBlackletterCPC-Inline.woff2') format('woff2');
|
|
28
|
+
font-weight: 400;
|
|
29
|
+
font-style: normal;
|
|
30
|
+
font-display: optional;
|
|
31
|
+
}
|
|
32
|
+
|
|
17
33
|
/* Waves Tiny CPC - Decorative pixel caption
|
|
18
34
|
----------------------------------------------------------------------------- */
|
|
19
35
|
|
package/fonts.css
CHANGED
|
@@ -30,6 +30,8 @@
|
|
|
30
30
|
--font-joystix: 'Joystix Monospace', monospace;
|
|
31
31
|
--font-pixel-code: 'PixelCode', monospace;
|
|
32
32
|
--font-blackletter: 'Waves Blackletter CPC', serif;
|
|
33
|
+
--font-blackletter-shadow: 'Waves Blackletter CPC Shadow', serif;
|
|
34
|
+
--font-blackletter-inline: 'Waves Blackletter CPC Inline', serif;
|
|
33
35
|
--font-pixeloid: 'Pixeloid Sans', sans-serif;
|
|
34
36
|
--font-waves-tiny: 'Waves Tiny CPC', serif;
|
|
35
37
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rdna/radiants",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "Radiants theme package for DNA - retro pixel aesthetic",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -48,8 +48,7 @@
|
|
|
48
48
|
"components/",
|
|
49
49
|
"icons/",
|
|
50
50
|
"schemas/",
|
|
51
|
-
"fonts/
|
|
52
|
-
"fonts/PixelCode*.woff2",
|
|
51
|
+
"fonts/",
|
|
53
52
|
"assets/",
|
|
54
53
|
"dna.config.json",
|
|
55
54
|
"LICENSE",
|
|
@@ -101,7 +101,7 @@ export const spacing = {
|
|
|
101
101
|
/** Between paragraphs in the same section */
|
|
102
102
|
paragraph: 0.75,
|
|
103
103
|
/** Before a heading (establishes new section) */
|
|
104
|
-
headingBefore:
|
|
104
|
+
headingBefore: 0.75,
|
|
105
105
|
/** After a heading (ties heading to its content) */
|
|
106
106
|
headingAfter: 0.5,
|
|
107
107
|
/** Around horizontal rules */
|