anentrypoint-design 0.0.316 → 0.0.317
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/dist/247420.js +10 -10
- package/package.json +1 -1
- package/src/components/chat.js +9 -0
- package/src/components/content.js +1 -1
- package/src/components/shell.js +1 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "anentrypoint-design",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.317",
|
|
4
4
|
"description": "247420 design system SDK — webjsx + modified ripple-ui, single-file ESM bundle for reproducible use of the AnEntrypoint design.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/247420.js",
|
package/src/components/chat.js
CHANGED
|
@@ -224,6 +224,15 @@ function CodeNode(p) {
|
|
|
224
224
|
const codeKey = (p.lang || '') + '|' + (p.code || '');
|
|
225
225
|
if (el.dataset.codeKey === codeKey) return;
|
|
226
226
|
el.dataset.codeKey = codeKey;
|
|
227
|
+
// Same in-progress-selection guard as MdNode.refSink: don't wipe an
|
|
228
|
+
// active text selection inside this block mid-stream-settle. Defer
|
|
229
|
+
// the highlight swap once, until the selection changes.
|
|
230
|
+
const sel = typeof window !== 'undefined' ? window.getSelection() : null;
|
|
231
|
+
if (sel && sel.anchorNode && el.contains(sel.anchorNode)) {
|
|
232
|
+
const onSelChange = () => { document.removeEventListener('selectionchange', onSelChange); highlightCodeBlockCached(el); };
|
|
233
|
+
document.addEventListener('selectionchange', onSelChange, { once: true });
|
|
234
|
+
return;
|
|
235
|
+
}
|
|
227
236
|
highlightCodeBlockCached(el);
|
|
228
237
|
};
|
|
229
238
|
// Copy the raw code (not the highlighted DOM) for the structured CodeNode.
|
|
@@ -110,7 +110,7 @@ export function Row({ code, rank, title, sub, meta, active, state = 'default', o
|
|
|
110
110
|
return h(isLink ? 'a' : 'div', props,
|
|
111
111
|
railWord ? h('span', { class: 'sr-only' }, railWord) : null,
|
|
112
112
|
leading != null ? leading : (codeVal != null ? h('span', { class: 'code' }, codeVal) : null),
|
|
113
|
-
h('span', { class: 'title' }, titleNode, sub ? h('span', { class: 'sub' }, sub) : null),
|
|
113
|
+
h('span', { class: 'title' }, titleNode, sub ? h('span', { class: 'sub', title: typeof sub === 'string' ? sub : undefined }, sub) : null),
|
|
114
114
|
trailing != null ? trailing : (meta != null ? h('span', { class: 'meta' }, meta) : null),
|
|
115
115
|
actionRow,
|
|
116
116
|
detail != null ? h('pre', { class: 'ds-row-detail' }, detail) : null);
|
package/src/components/shell.js
CHANGED
|
@@ -145,6 +145,7 @@ export const ICON_PATHS = {
|
|
|
145
145
|
square: '<rect x="4" y="4" width="16" height="16" rx="2"/>',
|
|
146
146
|
activity: '<path d="M3 12h4l3 8 4-16 3 8h4"/>',
|
|
147
147
|
info: '<circle cx="12" cy="12" r="9"/><path d="M12 11v5M12 8h.01"/>',
|
|
148
|
+
help: '<circle cx="12" cy="12" r="9"/><path d="M9.5 9a2.5 2.5 0 0 1 4.9.8c0 1.7-2.4 2-2.4 3.7M12 17h.01"/>',
|
|
148
149
|
warn: '<path d="M10.3 4 2.7 17a2 2 0 0 0 1.7 3h15.2a2 2 0 0 0 1.7-3L13.7 4a2 2 0 0 0-3.4 0z"/><path d="M12 9v4M12 17h.01"/>',
|
|
149
150
|
// file-type icons (replace the FILE_GLYPHS unicode set)
|
|
150
151
|
'file-pdf': '<path d="M6 3h8l5 5v13a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1z"/><path d="M14 3v5h5"/><path d="M9 13h6M9 17h6"/>',
|