@rcarls/rc-markdown-editor 0.5.0 → 0.7.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 CHANGED
@@ -1,5 +1,232 @@
1
1
  # @rcarls/rc-markdown-editor
2
2
 
3
+ ## 0.7.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 079e025: Standardize component styling contracts for the breaking 0.7 release.
8
+
9
+ BREAKING CHANGE: Rename the Markdown editor's `--rme-*` properties to
10
+ `--rc-markdown-editor-*`, `--rc-app-bar-background` to `--rc-app-bar-bg`,
11
+ `--rc-textarea-radius` to `--rc-textarea-border-radius`, the transfer-list
12
+ `--rc-transfer-list-panel-*` properties to `--rc-transfer-list-listbox-*`,
13
+ `--rc-chip-group-webkit-scrollbar-display` to
14
+ `--rc-chip-group-scrollbar-display`, and `--rc-text` to `--rc-field-text`.
15
+ Compatibility aliases are intentionally not provided.
16
+
17
+ BREAKING CHANGE: Replace `--rc-select-chip-padding-inline` and
18
+ `--rc-combobox-chip-padding-inline` with explicit `*-padding-inline-start` and
19
+ `*-padding-inline-end` tokens. Generated removable chips now reserve the full
20
+ remove target and its edge offset, so their indicator cannot overlap label text.
21
+
22
+ Add canonical app-bar elevation, transfer-list listbox radius, and textarea
23
+ line-action tokens. Add logical `rc-chip` inline-padding properties so themes
24
+ can implement Material's icon-aware spacing without overriding authored child
25
+ styles. Make `rc-field` consume the shared semantic token layer,
26
+ and place the `rc-chip` and `rc-search-bar` light-DOM structural styles in the
27
+ `rc-base` cascade layer so normal consumer rules override them.
28
+
29
+ Prevent decorative, `aria-hidden` trailing list content from intercepting a
30
+ whole-row action target, and keep segmented-list item geometry from leaking
31
+ into nested standard lists.
32
+
33
+ Remove unused Material navigation-rail toggle tokens and obsolete list-item
34
+ theme tokens. Register the segmented-button private theme seam and enforce
35
+ token ownership, documentation, removed-name, selector-budget, and cascade
36
+ layer contracts through the component architecture audit.
37
+
38
+ - 54d9ead: Localize every component's built-in text. Button names, role
39
+ descriptions, announcements, and default labels now resolve per key from
40
+ the element's `messages` property, then from text registered with
41
+ `registerMessages(locale, catalog)` in `@rcarls/rc-common`, then from the
42
+ English defaults. The locale is the element's own `lang`, else
43
+ `<html lang>`; an ancestor's `lang` is ignored, because it usually marks
44
+ content rather than the interface. Components re-render when that locale
45
+ changes or new text is registered. `RcMessageCatalog` types the catalog,
46
+ and each package adds its scope to it.
47
+
48
+ Numbers a component formats as text follow the same locale:
49
+ `rc-progress`'s default percentage and `rc-splitter`'s `aria-valuetext`
50
+ use `Intl.NumberFormat`. `TypeaheadController` matches prefixes with an
51
+ `Intl.Collator`, so case and accents are ignored the way the locale
52
+ ignores them, and takes a `locale` option. `ItemsCollectionController`'s
53
+ `setCreateOption(text, label?)` takes the option's visible text from its
54
+ caller.
55
+
56
+ `rc-transfer-list`'s direction arrows are now decorative: screen readers
57
+ read only the action name, and the arrows turn over in RTL.
58
+
59
+ **Breaking:** chrome-text properties are replaced by `messages`. Migrate:
60
+
61
+ - `rc-search-bar` `clear-label` / `clearLabel` → `messages.clear`
62
+ - `rc-adaptive-menu` `overflow-label` / `overflowLabel` → `messages.overflow`
63
+ - `rc-chip-group` `show-all-label` / `showAllLabel` and `show-less-label` /
64
+ `showLessLabel` → `messages.showAll` and `messages.showLess`
65
+ - `rc-select` and `rc-combobox` `dialog-confirm-label` /
66
+ `dialogConfirmLabel` and `dialog-cancel-label` / `dialogCancelLabel` →
67
+ `messages.done` and `messages.cancel`
68
+ - `rc-editor-toolbar` `label` → `messages.toolbar`
69
+
70
+ Per-instance names stay attributes, but now default to `undefined` and fall
71
+ back to a message: `label` on `rc-adaptive-menu`, `rc-chip-group`,
72
+ `rc-menubar`, and `rc-splitter`; `available-label` and `selected-label`
73
+ on `rc-transfer-list`; `low-label` and `high-label` on `rc-range-slider`.
74
+ Read the resolved name from the rendered `aria-label` instead of the
75
+ property.
76
+
77
+ - 3325191: **Breaking:** take `rc-textarea`'s read-only state from the slotted `<textarea readonly>` and
78
+ remove the `read-only` attribute and its display styling without border or padding. A read-only
79
+ editor keeps the enabled field appearance, stays focusable and selectable, announces `aria-
80
+ readonly` with the native control's label, and rejects edits. The host reflects `data-readonly`,
81
+ and `readOnly` is now a getter. The plugin `transform()` hook runs while the textarea is
82
+ `readonly`.
83
+
84
+ `rc-markdown-editor` passes its `read-only` state to a native textarea in its source editor.
85
+ Material and Substrate fields skip the hover affordance for a read-only control and keep its
86
+ focus indicator.
87
+
88
+ Migration: replace `<rc-textarea read-only>` with `readonly` on the slotted textarea, for
89
+ example `<rc-textarea><textarea aria-label="Notes" readonly></textarea></rc-textarea>`. Replace
90
+ `editor.readOnly = value` with `textarea.readOnly = value`. Read-only content that is not a form
91
+ value belongs in ordinary text or list markup instead.
92
+
93
+ ### Patch Changes
94
+
95
+ - 5c006de: Ship component CSS minified. Package builds now run the CSS in Lit `css` styles
96
+ and light-DOM structural styles through Lightning CSS, removing comments and
97
+ whitespace while keeping source maps that resolve to each template. Rendered
98
+ styles are unchanged.
99
+
100
+ `@rcarls/rc-common` adds `cssText`, an identity tag that marks a plain CSS
101
+ string for minification. `rc-chip`, `rc-disclosure`, and `rc-accordion` now
102
+ depend on `@rcarls/rc-common` for it.
103
+
104
+ - ec6ebc6: Load dialog move and resize behavior on demand. `rc-dialog` now imports its
105
+ drag and resize controllers only the first time `movable`, `move-handle`, or
106
+ `resize` enables them, so dialogs that never move or resize, including the
107
+ popups inside `rc-select`, `rc-combobox`, and `rc-markdown-editor`, no longer
108
+ ship that code. The new `@rcarls/rc-dialog/geometry` entry exports
109
+ `DialogGeometry` for subclasses that always resize; `rc-bottom-sheet` uses it,
110
+ so its resize stays available immediately.
111
+
112
+ Breaking changes and migration:
113
+
114
+ - `rc-dialog` and `rc-bottom-sheet` remove `light-dismiss` / `lightDismiss`.
115
+ Use `closed-by="any"`, which closes on Escape or a backdrop click and now
116
+ falls back to a backdrop click listener where the browser has no native
117
+ `closedby`.
118
+ - `rc-bottom-sheet` now defaults `closed-by` to `any` instead of defaulting
119
+ `light-dismiss` to true. Set `closed-by="closerequest"` to keep backdrop
120
+ clicks from closing a sheet, or `closed-by="none"` to allow only explicit
121
+ actions.
122
+
123
+ - b764a3c: Observe interface locale changes through containing shadow roots and the host's own document.
124
+ An explicit empty `lang` now means an unknown locale rather than falling back to `<html lang>`.
125
+ Typeahead compares complete grapheme prefixes, including decomposed accents and collation
126
+ expansions. Default interpolating messages format numeric positions in the interface locale
127
+ while translation callbacks continue to receive numbers and can accept an optional locale.
128
+ Default messages isolate consumer text whose direction is unknown. Textarea content direction
129
+ uses the native LTR fallback for neutral `dir="auto"` content, recognizes Arabic Letter Mark and
130
+ isolate controls, and reruns plugins when the native textarea's `lang` or `dir` changes.
131
+ - cc0205d: Use logical CSS properties so layout follows the reading direction and
132
+ writing mode: the textarea gutter border and alignment, line-action and
133
+ diagnostic-message spacing, the markdown editor's block quote and list
134
+ indents, and block-axis scrolling for listbox, select, combobox, and markdown
135
+ panes, each keeping its physical declaration as a fallback.
136
+ - bdb8753: Position link popovers from selection viewport measurements in the popover's
137
+ local CSS pixels under zoom, including right-edge alignment in RTL.
138
+ - 253ba66: Correct package dependency declarations and prevent bundled Markdown implementation types from
139
+ leaking into the editor declarations.
140
+
141
+ BREAKING CHANGE: `@rcarls/rc-textarea-adapters` now treats `@rcarls/rc-textarea` as a peer instead
142
+ of installing it as a runtime dependency. Both textarea extension packages require a compatible
143
+ pre-1 `@rcarls/rc-textarea` release; install it alongside either extension package when upgrading.
144
+
145
+ - 50c0657: Align the line-actions popover and the markdown editor's link popover to the
146
+ inline start of what they belong to, so they sit under the right edge in RTL
147
+ instead of the left.
148
+ - f0d0fba: Load the select dialog popup and selected-value chips on first use.
149
+ `rc-select` and `rc-combobox` now import `rc-dialog` only for
150
+ `popup-mode="dialog"` and `rc-chip-group` only for `multiple`, so a popover
151
+ single select ships neither. The markdown editor toolbar picks the heading level
152
+ with a native `<select>`, styled by the existing
153
+ `--rc-markdown-editor-toolbar-select-*` properties, and no longer depends on
154
+ `rc-select`.
155
+
156
+ Breaking change and migration:
157
+
158
+ - Importing `@rcarls/rc-select/define` or `@rcarls/rc-combobox/define` no
159
+ longer registers `rc-dialog`, `rc-chip-group`, or `rc-chip`. Import their own
160
+ `define` entries where the page uses those elements directly.
161
+
162
+ - Updated dependencies [e3dfa59]
163
+ - Updated dependencies [50d5610]
164
+ - Updated dependencies [9ee769c]
165
+ - Updated dependencies [1179f24]
166
+ - Updated dependencies [9f590f2]
167
+ - Updated dependencies [fbf240b]
168
+ - Updated dependencies [595fe37]
169
+ - Updated dependencies [38cd00c]
170
+ - Updated dependencies [5c006de]
171
+ - Updated dependencies [079e025]
172
+ - Updated dependencies [a6553ff]
173
+ - Updated dependencies [2205478]
174
+ - Updated dependencies [4341311]
175
+ - Updated dependencies [899bb5e]
176
+ - Updated dependencies [25fcfe0]
177
+ - Updated dependencies [51f6403]
178
+ - Updated dependencies [9caca6b]
179
+ - Updated dependencies [b764a3c]
180
+ - Updated dependencies [cc0205d]
181
+ - Updated dependencies [54d9ead]
182
+ - Updated dependencies [b9175e9]
183
+ - Updated dependencies [c8b762b]
184
+ - Updated dependencies [55e1e7f]
185
+ - Updated dependencies [50c0657]
186
+ - Updated dependencies [f1ca82d]
187
+ - Updated dependencies [b87f27b]
188
+ - Updated dependencies [32ebead]
189
+ - Updated dependencies [bfefedd]
190
+ - Updated dependencies [c130173]
191
+ - Updated dependencies [11680b6]
192
+ - Updated dependencies [223d36c]
193
+ - Updated dependencies [7b91a44]
194
+ - Updated dependencies [aa04ead]
195
+ - Updated dependencies [ac65b5b]
196
+ - Updated dependencies [afcfef8]
197
+ - Updated dependencies [905083b]
198
+ - Updated dependencies [6b99ced]
199
+ - Updated dependencies [8387c20]
200
+ - Updated dependencies [c328259]
201
+ - Updated dependencies [f1433a9]
202
+ - Updated dependencies [d3fc2f3]
203
+ - Updated dependencies [3325191]
204
+ - Updated dependencies [4617b45]
205
+ - Updated dependencies [0e2d878]
206
+ - Updated dependencies [54067cc]
207
+ - Updated dependencies [57d6371]
208
+ - Updated dependencies [11ef1ad]
209
+ - @rcarls/rc-common@0.7.0
210
+ - @rcarls/rc-button@0.7.0
211
+ - @rcarls/rc-textarea@0.7.0
212
+ - @rcarls/rc-toolbar@0.7.0
213
+
214
+ ## 0.6.0
215
+
216
+ ### Patch Changes
217
+
218
+ - Updated dependencies [ffcbf11]
219
+ - Updated dependencies [7adbd76]
220
+ - Updated dependencies [30eb232]
221
+ - Updated dependencies [53baa54]
222
+ - Updated dependencies [53baa54]
223
+ - Updated dependencies [985067e]
224
+ - Updated dependencies [57370e4]
225
+ - @rcarls/rc-select@0.6.0
226
+ - @rcarls/rc-button@0.6.0
227
+ - @rcarls/rc-textarea@0.6.0
228
+ - @rcarls/rc-toolbar@0.6.0
229
+
3
230
  ## 0.5.0
4
231
 
5
232
  ### Patch Changes
package/README.md CHANGED
@@ -6,6 +6,14 @@ Docs: [https://richardcarls.github.io/rc-webcomponents/components/rc-markdown-ed
6
6
 
7
7
  Part of the [rc-webcomponents](https://github.com/richardcarls/rc-webcomponents) library.
8
8
 
9
+ ## Localization
10
+
11
+ Built-in text follows the element's own `lang`, else `<html lang>`, and never an
12
+ ancestor's `lang`, which usually marks content. Override it per element with the
13
+ `messages` property, or for every instance with `registerMessages()` from
14
+ `@rcarls/rc-common` under `rc-markdown-editor`. Keys: `source`, `linkPopover`, `url`, `applyLink`, `openLink`, `removeLink`, `shortcut`. The toolbar resolves `rc-editor-toolbar` (`toolbar`, `bold`, `heading`, and the other button names) and takes the editor's `lang`. See the
15
+ [rc-common Localization section](https://github.com/richardcarls/rc-webcomponents/tree/develop/packages/rc-common#localization).
16
+
9
17
  ## Documentation
10
18
 
11
19
  Full API, usage examples, and keyboard/accessibility notes are on the