@eduardoalvarez/arrecife 0.8.0 → 0.10.0
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/CHANGELOG.md +50 -0
- package/README.md +99 -69
- package/dist/brand/index.js +2 -3
- package/dist/chart/index.cjs +34 -8
- package/dist/chart/index.d.cts +25 -3
- package/dist/chart/index.d.ts +25 -3
- package/dist/chart/index.js +34 -9
- package/dist/chunk-ZSCSKCTY.js +26 -0
- package/dist/form/index.js +0 -1
- package/dist/icons/index.d.cts +19 -10
- package/dist/icons/index.d.ts +19 -10
- package/dist/icons/index.js +2 -27
- package/dist/index.cjs +210 -384
- package/dist/index.d.cts +67 -12
- package/dist/index.d.ts +67 -12
- package/dist/index.js +153 -189
- package/dist/og/index.js +0 -1
- package/dist/shiki/index.js +0 -1
- package/dist/theme/index.js +0 -1
- package/dist/tokens/index.js +0 -1
- package/dist/tokens/theme.css +21 -1
- package/dist/variants/index.js +0 -1
- package/llms.txt +70 -134
- package/package.json +18 -30
- package/dist/chunk-HOADZ6GS.js +0 -72
- package/dist/chunk-LXRGQKMG.js +0 -145
- package/dist/chunk-MLKGABMK.js +0 -7
- package/dist/index-BbRplw_B.d.cts +0 -58
- package/dist/index-BbRplw_B.d.ts +0 -58
- package/dist/social/data.cjs +0 -161
- package/dist/social/data.d.cts +0 -161
- package/dist/social/data.d.ts +0 -161
- package/dist/social/data.js +0 -2
- package/dist/social/index.cjs +0 -153
- package/dist/social/index.d.cts +0 -2
- package/dist/social/index.d.ts +0 -2
- package/dist/social/index.js +0 -3
- package/dist/{chunk-MPZBF2TZ.js → chunk-IIT3YLYN.js} +1 -1
package/dist/form/index.js
CHANGED
|
@@ -4,7 +4,6 @@ import { Text } from '../chunk-TRPBID2W.js';
|
|
|
4
4
|
import '../chunk-ODBFN44D.js';
|
|
5
5
|
import { cn } from '../chunk-FAAGZG7A.js';
|
|
6
6
|
import '../chunk-FGFNK72B.js';
|
|
7
|
-
import '../chunk-MLKGABMK.js';
|
|
8
7
|
import { createContext, useContext, useId } from 'react';
|
|
9
8
|
import { FormProvider, Controller, useFormContext, useFormState } from 'react-hook-form';
|
|
10
9
|
import { Slot } from '@radix-ui/react-slot';
|
package/dist/icons/index.d.cts
CHANGED
|
@@ -2,14 +2,20 @@ import * as react from 'react';
|
|
|
2
2
|
import { IconWeight, IconProps as IconProps$1, Icon as Icon$1 } from '@phosphor-icons/react';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
|
-
* The system adopts `@phosphor-icons/react`, and
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* The system adopts `@phosphor-icons/react`, and since 0.10.0 «adopts» means
|
|
6
|
+
* ALL of it: a required peer dependency, one place that fixes what a call site
|
|
7
|
+
* was getting wrong on its own, and no second set anywhere in the library.
|
|
8
|
+
*
|
|
9
|
+
* It was optional for three releases, and what made it required is that the
|
|
10
|
+
* library stopped keeping a set of its own to fall back on. That is the trade
|
|
11
|
+
* and it is worth naming: the two consumers that draw no icons of their own now
|
|
12
|
+
* install Phosphor anyway, because the `Alert` and the `Select` they DO draw are
|
|
13
|
+
* drawn with it.
|
|
8
14
|
*
|
|
9
15
|
* WHY IT IS HERE AT ALL. The position used to be that the system has no icons.
|
|
10
|
-
* That was right for what the library was — five reading sites, where
|
|
11
|
-
* `lib/glyphs.tsx`
|
|
12
|
-
* right when an admin panel arrived. Measured across the four consumers, the one
|
|
16
|
+
* That was right for what the library was — five reading sites, where a
|
|
17
|
+
* hand-drawn `lib/glyphs.tsx` covered everything a primitive needed — and it
|
|
18
|
+
* stopped being right when an admin panel arrived. Measured across the four consumers, the one
|
|
13
19
|
* admin app imports 89 distinct icons in 229 places and the other three import
|
|
14
20
|
* 9, 0 and 0. Seventy-seven of the 89 are domain icons for a course admin —
|
|
15
21
|
* `GraduationCap`, `TicketPercent`, `Webhook` — and no design system was ever
|
|
@@ -39,10 +45,13 @@ import { IconWeight, IconProps as IconProps$1, Icon as Icon$1 } from '@phosphor-
|
|
|
39
45
|
* because Phosphor's other three — `thin`, `bold`, `duotone` — say nothing this
|
|
40
46
|
* system means. See `TONE_WEIGHT` below and `docs/decisions/0.7.md` § 35.
|
|
41
47
|
*
|
|
42
|
-
*
|
|
43
|
-
* 1.75 on a 16 grid
|
|
44
|
-
* document and this
|
|
45
|
-
*
|
|
48
|
+
* IT IS NOW THE ONLY LINE THE LIBRARY DRAWS, which is what 0.10.0 changed.
|
|
49
|
+
* `lib/glyphs.tsx` drew at 1.75 on a 16 grid — 0.109em, three quarters heavier
|
|
50
|
+
* than both the document and this — and `./social` drew ten brand marks in a
|
|
51
|
+
* third hand. 0.7.0 left both alone because reconciling them restyles every
|
|
52
|
+
* primitive in the library; that is exactly what 0.10.0 did, and both files are
|
|
53
|
+
* gone. There is one description of what a line looks like here, and it is
|
|
54
|
+
* Phosphor's. See `docs/decisions/0.10.md` § 51.
|
|
46
55
|
*
|
|
47
56
|
* IN NEXT, IMPORT FROM `@phosphor-icons/react/ssr` inside a Server Component.
|
|
48
57
|
* Phosphor's default build reads `IconContext` through `useContext`, and a hook
|
package/dist/icons/index.d.ts
CHANGED
|
@@ -2,14 +2,20 @@ import * as react from 'react';
|
|
|
2
2
|
import { IconWeight, IconProps as IconProps$1, Icon as Icon$1 } from '@phosphor-icons/react';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
|
-
* The system adopts `@phosphor-icons/react`, and
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* The system adopts `@phosphor-icons/react`, and since 0.10.0 «adopts» means
|
|
6
|
+
* ALL of it: a required peer dependency, one place that fixes what a call site
|
|
7
|
+
* was getting wrong on its own, and no second set anywhere in the library.
|
|
8
|
+
*
|
|
9
|
+
* It was optional for three releases, and what made it required is that the
|
|
10
|
+
* library stopped keeping a set of its own to fall back on. That is the trade
|
|
11
|
+
* and it is worth naming: the two consumers that draw no icons of their own now
|
|
12
|
+
* install Phosphor anyway, because the `Alert` and the `Select` they DO draw are
|
|
13
|
+
* drawn with it.
|
|
8
14
|
*
|
|
9
15
|
* WHY IT IS HERE AT ALL. The position used to be that the system has no icons.
|
|
10
|
-
* That was right for what the library was — five reading sites, where
|
|
11
|
-
* `lib/glyphs.tsx`
|
|
12
|
-
* right when an admin panel arrived. Measured across the four consumers, the one
|
|
16
|
+
* That was right for what the library was — five reading sites, where a
|
|
17
|
+
* hand-drawn `lib/glyphs.tsx` covered everything a primitive needed — and it
|
|
18
|
+
* stopped being right when an admin panel arrived. Measured across the four consumers, the one
|
|
13
19
|
* admin app imports 89 distinct icons in 229 places and the other three import
|
|
14
20
|
* 9, 0 and 0. Seventy-seven of the 89 are domain icons for a course admin —
|
|
15
21
|
* `GraduationCap`, `TicketPercent`, `Webhook` — and no design system was ever
|
|
@@ -39,10 +45,13 @@ import { IconWeight, IconProps as IconProps$1, Icon as Icon$1 } from '@phosphor-
|
|
|
39
45
|
* because Phosphor's other three — `thin`, `bold`, `duotone` — say nothing this
|
|
40
46
|
* system means. See `TONE_WEIGHT` below and `docs/decisions/0.7.md` § 35.
|
|
41
47
|
*
|
|
42
|
-
*
|
|
43
|
-
* 1.75 on a 16 grid
|
|
44
|
-
* document and this
|
|
45
|
-
*
|
|
48
|
+
* IT IS NOW THE ONLY LINE THE LIBRARY DRAWS, which is what 0.10.0 changed.
|
|
49
|
+
* `lib/glyphs.tsx` drew at 1.75 on a 16 grid — 0.109em, three quarters heavier
|
|
50
|
+
* than both the document and this — and `./social` drew ten brand marks in a
|
|
51
|
+
* third hand. 0.7.0 left both alone because reconciling them restyles every
|
|
52
|
+
* primitive in the library; that is exactly what 0.10.0 did, and both files are
|
|
53
|
+
* gone. There is one description of what a line looks like here, and it is
|
|
54
|
+
* Phosphor's. See `docs/decisions/0.10.md` § 51.
|
|
46
55
|
*
|
|
47
56
|
* IN NEXT, IMPORT FROM `@phosphor-icons/react/ssr` inside a Server Component.
|
|
48
57
|
* Phosphor's default build reads `IconContext` through `useContext`, and a hook
|
package/dist/icons/index.js
CHANGED
|
@@ -1,28 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
export { ICON_WEIGHT, Icon, TONE_WEIGHT } from '../chunk-ZSCSKCTY.js';
|
|
2
|
+
import '../chunk-FAAGZG7A.js';
|
|
2
3
|
import '../chunk-FGFNK72B.js';
|
|
3
|
-
import '../chunk-MLKGABMK.js';
|
|
4
|
-
import { jsx } from 'react/jsx-runtime';
|
|
5
|
-
|
|
6
|
-
var ICON_WEIGHT = "regular";
|
|
7
|
-
var TONE_WEIGHT = {
|
|
8
|
-
action: ICON_WEIGHT,
|
|
9
|
-
current: "fill",
|
|
10
|
-
quiet: "light"
|
|
11
|
-
};
|
|
12
|
-
function Icon({ as: Glyph, tone = "action", label, className, ...props }) {
|
|
13
|
-
return /* @__PURE__ */ jsx(
|
|
14
|
-
Glyph,
|
|
15
|
-
{
|
|
16
|
-
size: "1em",
|
|
17
|
-
weight: TONE_WEIGHT[tone],
|
|
18
|
-
"aria-hidden": label ? void 0 : true,
|
|
19
|
-
"aria-label": label,
|
|
20
|
-
role: label ? "img" : void 0,
|
|
21
|
-
focusable: "false",
|
|
22
|
-
className: cn("shrink-0", className),
|
|
23
|
-
...props
|
|
24
|
-
}
|
|
25
|
-
);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export { ICON_WEIGHT, Icon, TONE_WEIGHT };
|