@astryxdesign/richtext 0.7.5-canary.fd0aba8 → 0.7.5
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 +43 -0
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,48 @@
|
|
|
1
1
|
# @astryxdesign/richtext
|
|
2
2
|
|
|
3
|
+
# 0.7.5
|
|
4
|
+
|
|
5
|
+
#### New Features
|
|
6
|
+
|
|
7
|
+
- Status colors are readable everywhere they appear, and Info is a status of its own. Each status (info, success, warning, error) now has a strong fill (`--color-<status>`) with content on it (`--color-on-<status>`, at least 4.5:1), a pale fill (`--color-<status>-muted`) with its content (`--color-on-<status>-muted`), and readable text for the page and cards (`--color-text-<status>`). Status icons (`--color-icon-<status>`) and borders (`--color-border-<status>`) default to the readable text color. The Info roles (`--color-info`, `--color-on-info`, `--color-info-muted`, …) are new and no longer borrow your accent color.
|
|
8
|
+
|
|
9
|
+
`--color-success`, `--color-warning`, and `--color-error` and `bg-<status>` keep their meaning as the strong fills. In Tailwind, `bg-info`, `bg-info-muted`, `text-on-<status>`, `text-on-<status>-muted`, and `text-status-<status>` are new; `text-`, `decoration-`, `placeholder-`, and `caret-<status>` now use the readable text shade, and `border-`, `divide-`, `outline-`, and `ring-<status>` use the border shade, while `bg-`, `accent-`, `fill-`, `stroke-<status>`, shadows, and gradients keep the strong fill. For example, Core's light `text-warning` is now `#753F07` instead of `#E9AF08`. To keep the fill color on text, write `text-[var(--color-warning)]`.
|
|
10
|
+
|
|
11
|
+
What changes on screen:
|
|
12
|
+
|
|
13
|
+
- Core's dark Error content (`--color-on-error`) is now `#0A1317` instead of white, so text on dark-mode error fills reaches 4.5:1. Core's Info Badge uses `#0064E0` instead of the accent (`#2694FE` in dark mode).
|
|
14
|
+
- Status icons (Icon `color="info|success|warning|error"`), Stepper status glyphs, and Chat tool-call status icons use the readable shades. Core's light success icon is now `#09441F` instead of `#0D8626`.
|
|
15
|
+
- Input and FileInput status borders use the border shades. Core's light warning border is now `#753F07` instead of `#E9AF08`, and Butter's light success and warning input borders reach 3:1.
|
|
16
|
+
- Banner draws its title, description, icon, and controls in the on-muted colors, and fills Info with `--color-info-muted`.
|
|
17
|
+
- Status fills keep a visible edge in forced-colors mode.
|
|
18
|
+
- Content on Chocolate and Matcha success and error fills, and on Stone success, warning, and error fills, now reaches 4.5:1.
|
|
19
|
+
- Every first-party theme sets a blue Info. Chocolate and Matcha Info Badges move from the accent to that blue; Butter keeps its own Info Badge colors.
|
|
20
|
+
- Neutral's `--color-success`, `--color-warning`, and `--color-error` are now the fills its Badges already showed, and its `--color-info` is `#0074E2` (`#6D9CFE` in dark mode). Its Badges, StatusDots, progress fills, and Stepper badges look the same; its accent ProgressBar, StatusDot, and Stepper now use Neutral's accent instead of blue.
|
|
21
|
+
- Neutral no longer defines its undocumented local status tokens. Use the standard roles instead: `--astryx-theme-neutral-color-status-fill-success`, `-status-fill-warning`, and `-status-fill-error` → `--color-success`, `--color-warning`, `--color-error`; `-status-muted-accent` → `--color-info-muted`; `-on-tint-neutral` → `--color-neutral`; the `-on-tint-overlay-*` and `-destructive-overlay-*` tokens → `--color-overlay-hover` and `--color-overlay-pressed`. `--astryx-theme-neutral-color-status-fill-accent` keeps its value but is deprecated.
|
|
22
|
+
|
|
23
|
+
Custom themes get the content and text roles they don't set: they are derived from the theme's status fills. To keep a component's previous color, set the matching role, for example `--color-icon-success` to your old `--color-success`.
|
|
24
|
+
|
|
25
|
+
- `RichTextEditor` and `RichTextView` take `codeLanguages`, the same list `Markdown` takes, so code looks the same while reading and editing.
|
|
26
|
+
|
|
27
|
+
#### Fixes
|
|
28
|
+
|
|
29
|
+
- Type declarations resolve in projects that use `moduleResolution: NodeNext`.
|
|
30
|
+
- In `RichTextEditor` and `RichTextView`, a code block with no language leaves room for its Copy button, so long lines wrap before it. The block is as tall as in `Markdown`, so switching between reading and editing no longer shifts the page.
|
|
31
|
+
|
|
32
|
+
#### Documentation
|
|
33
|
+
|
|
34
|
+
- Package links now point to the project's GitHub home, `meta/astryx`.
|
|
35
|
+
|
|
36
|
+
#### Contributors
|
|
37
|
+
|
|
38
|
+
Thanks to everyone who contributed to this release:
|
|
39
|
+
|
|
40
|
+
- @cixzhang
|
|
41
|
+
- @harjothkhara
|
|
42
|
+
- @rubyycheung
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
3
46
|
# 0.7.4
|
|
4
47
|
|
|
5
48
|
---
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astryxdesign/richtext",
|
|
3
3
|
"displayName": "Rich Text",
|
|
4
|
-
"version": "0.7.5
|
|
4
|
+
"version": "0.7.5",
|
|
5
5
|
"description": "Astryx rich text — a Lexical-based rich text editor and viewer, styled with Astryx design tokens.",
|
|
6
6
|
"author": "Meta Open Source",
|
|
7
7
|
"license": "MIT",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
55
|
"@stylexjs/stylex": ">=0.10.0",
|
|
56
|
-
"@astryxdesign/core": "0.7.5
|
|
56
|
+
"@astryxdesign/core": "0.7.5",
|
|
57
57
|
"react": ">=19.0.0",
|
|
58
58
|
"react-dom": ">=19.0.0",
|
|
59
59
|
"lexical": "^0.52.0",
|
|
@@ -112,8 +112,6 @@
|
|
|
112
112
|
}
|
|
113
113
|
},
|
|
114
114
|
"devDependencies": {
|
|
115
|
-
"@astryxdesign/a11y-spec": "0.7.5-canary.fd0aba8",
|
|
116
|
-
"@astryxdesign/cli": "0.7.5-canary.fd0aba8",
|
|
117
115
|
"@babel/cli": "^7.29.7",
|
|
118
116
|
"@babel/core": "^7.29.7",
|
|
119
117
|
"@babel/preset-react": "^7.29.7",
|
|
@@ -132,7 +130,9 @@
|
|
|
132
130
|
"@lexical/utils": "^0.52.0",
|
|
133
131
|
"@stylexjs/babel-plugin": "^0.19.0",
|
|
134
132
|
"@testing-library/react": "^16.3.2",
|
|
135
|
-
"lexical": "^0.52.0"
|
|
133
|
+
"lexical": "^0.52.0",
|
|
134
|
+
"@astryxdesign/cli": "0.7.5",
|
|
135
|
+
"@astryxdesign/a11y-spec": "0.0.0"
|
|
136
136
|
},
|
|
137
137
|
"scripts": {
|
|
138
138
|
"build": "node ../../scripts/clean-dist.mjs && pnpm build:esm && tsc --project tsconfig.build.json && node ../../scripts/add-declaration-extensions.mjs && pnpm build:css && node ../../scripts/check-no-dev-jsx.mjs && node ../../scripts/check-fully-specified.mjs",
|