@adecore/editor-react 0.53.3 → 0.54.1
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/AnchoredPopup.d.ts +1 -1
- package/dist/AnchoredPopup.js +27 -12
- package/dist/AttributionCard.d.ts +1 -1
- package/dist/BaselineStatus.js +1 -1
- package/dist/CallHierarchyPanel.js +11 -10
- package/dist/ChangeReview.d.ts +1 -1
- package/dist/CodeAuthorsCard.js +2 -2
- package/dist/CompletionPopup.js +18 -14
- package/dist/DiffView.d.ts +2 -2
- package/dist/DiffView.js +159 -143
- package/dist/EditorContextMenu.js +1 -1
- package/dist/EditorView.d.ts +2 -2
- package/dist/EditorView.js +97 -81
- package/dist/FindReplace.js +3 -3
- package/dist/HoverCard.d.ts +3 -3
- package/dist/HoverCard.js +3 -3
- package/dist/HoverSections.js +1 -1
- package/dist/LanguagePopups.js +1 -1
- package/dist/Markdown.js +15 -3
- package/dist/PeekPanel.js +124 -103
- package/dist/PickPopup.js +8 -4
- package/dist/RenameCard.js +7 -7
- package/dist/RenderedDocs.d.ts +1 -1
- package/dist/RenderedDocs.js +1 -1
- package/dist/SplitDiffView.js +21 -4
- package/dist/SymbolPicker.js +93 -89
- package/dist/WrapCard.js +1 -1
- package/dist/call-hierarchy.d.ts +1 -1
- package/dist/call-hierarchy.js +3 -3
- package/dist/code-actions.js +2 -2
- package/dist/code-vision.d.ts +1 -1
- package/dist/completion-model.d.ts +1 -1
- package/dist/completion-model.js +2 -2
- package/dist/completion.d.ts +1 -1
- package/dist/completion.js +12 -12
- package/dist/diagnostics.d.ts +1 -1
- package/dist/diagnostics.js +1 -1
- package/dist/diff-overlays.js +2 -2
- package/dist/editor-language.d.ts +12 -12
- package/dist/editor-language.js +10 -10
- package/dist/editor-react.css +4 -4
- package/dist/highlights.d.ts +1 -1
- package/dist/highlights.js +2 -2
- package/dist/host-types.d.ts +4 -4
- package/dist/hover.js +1 -1
- package/dist/inlay-hints.js +1 -1
- package/dist/live-templates.js +1 -1
- package/dist/markup.js +1 -1
- package/dist/navigation.d.ts +1 -1
- package/dist/navigation.js +3 -3
- package/dist/peek.js +1 -1
- package/dist/popups.d.ts +5 -5
- package/dist/project-language.d.ts +4 -4
- package/dist/project-language.js +5 -5
- package/dist/rename.js +1 -1
- package/dist/rendered-docs.d.ts +1 -1
- package/dist/rendered-docs.js +1 -1
- package/dist/shortcut-keys.d.ts +1 -1
- package/dist/signature.js +1 -1
- package/dist/snippet-field-transforms.d.ts +2 -2
- package/dist/snippet-insert.js +3 -3
- package/dist/snippet-session.d.ts +2 -2
- package/dist/snippet-session.js +5 -5
- package/dist/snippet-transform-queue.d.ts +1 -1
- package/dist/surround.js +1 -1
- package/dist/symbol-picker.js +2 -2
- package/dist/templates.js +1 -1
- package/dist/use-problem-counts.d.ts +1 -1
- package/package.json +6 -6
- package/src/AnchoredPopup.tsx +7 -3
- package/src/AttributionCard.tsx +1 -1
- package/src/BaselineStatus.tsx +1 -1
- package/src/CallHierarchyPanel.tsx +13 -12
- package/src/ChangeReview.tsx +1 -1
- package/src/CodeAuthorsCard.tsx +2 -2
- package/src/CompletionPopup.tsx +16 -13
- package/src/DiffView.tsx +12 -6
- package/src/EditorContextMenu.tsx +2 -2
- package/src/EditorView.tsx +14 -6
- package/src/FindReplace.tsx +3 -3
- package/src/HoverCard.tsx +7 -7
- package/src/HoverSections.tsx +1 -1
- package/src/LanguagePopups.tsx +3 -3
- package/src/Markdown.tsx +13 -2
- package/src/PeekPanel.tsx +13 -13
- package/src/PickPopup.tsx +6 -5
- package/src/RenameCard.tsx +8 -8
- package/src/RenderedDocs.tsx +3 -3
- package/src/SplitDiffView.tsx +14 -5
- package/src/SymbolPicker.tsx +6 -6
- package/src/WrapCard.tsx +2 -2
- package/src/call-hierarchy.ts +5 -5
- package/src/code-actions.ts +3 -3
- package/src/code-authors.ts +1 -1
- package/src/code-vision.ts +3 -3
- package/src/completion-model.ts +3 -3
- package/src/completion.ts +15 -15
- package/src/diagnostics.ts +4 -4
- package/src/diff-overlays.tsx +4 -4
- package/src/editor-language.ts +13 -13
- package/src/editor-react.css +4 -4
- package/src/format-on-type.ts +1 -1
- package/src/highlights.ts +3 -3
- package/src/host-types.ts +4 -4
- package/src/hover.ts +3 -3
- package/src/inlay-hints.ts +1 -1
- package/src/line-edits.ts +1 -1
- package/src/live-templates.ts +2 -2
- package/src/markup.ts +2 -2
- package/src/navigation.ts +5 -5
- package/src/patch-decorations.ts +1 -1
- package/src/peek.ts +3 -3
- package/src/pick.ts +1 -1
- package/src/popups.ts +5 -5
- package/src/postfix.ts +1 -1
- package/src/project-language.ts +7 -7
- package/src/proposal-model.ts +1 -1
- package/src/rename.ts +3 -3
- package/src/rendered-docs.ts +2 -2
- package/src/shortcut-keys.ts +1 -1
- package/src/signature.ts +3 -3
- package/src/snippet-field-transforms.ts +2 -2
- package/src/snippet-insert.ts +3 -3
- package/src/snippet-session.ts +7 -7
- package/src/snippet-transform-queue.ts +1 -1
- package/src/surround.ts +1 -1
- package/src/symbol-picker-model.ts +1 -1
- package/src/symbol-picker.ts +3 -3
- package/src/templates.ts +1 -1
- package/src/use-problem-counts.ts +1 -1
- package/src/workspace-edit.ts +1 -1
package/dist/AnchoredPopup.d.ts
CHANGED
package/dist/AnchoredPopup.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
+
import { ScrollArea } from '@adecore/ui';
|
|
2
3
|
import { useLayoutEffect, useRef } from 'react';
|
|
3
4
|
import { createPortal } from 'react-dom';
|
|
4
5
|
import { placePopup } from './popup-placement.js';
|
|
@@ -8,7 +9,7 @@ import { placePopup } from './popup-placement.js';
|
|
|
8
9
|
*/
|
|
9
10
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
11
|
export function AnchoredPopup(t0) {
|
|
11
|
-
const $ = _c(
|
|
12
|
+
const $ = _c(13);
|
|
12
13
|
const {
|
|
13
14
|
rect,
|
|
14
15
|
className,
|
|
@@ -48,7 +49,8 @@ export function AnchoredPopup(t0) {
|
|
|
48
49
|
t2 = $[2];
|
|
49
50
|
}
|
|
50
51
|
useLayoutEffect(t2);
|
|
51
|
-
const
|
|
52
|
+
const scrolls = overflow === "scroll";
|
|
53
|
+
const t3 = `fixed top-0 left-0 z-(--z-popup) overflow-hidden rounded-lg border border-border bg-surface-raised text-text shadow-(--float-shadow) ${scrolls ? "flex flex-col" : className ?? ""}`;
|
|
52
54
|
let t4;
|
|
53
55
|
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
54
56
|
t4 = {
|
|
@@ -59,22 +61,35 @@ export function AnchoredPopup(t0) {
|
|
|
59
61
|
t4 = $[3];
|
|
60
62
|
}
|
|
61
63
|
let t5;
|
|
62
|
-
if ($[4] !== children || $[5] !==
|
|
63
|
-
t5 =
|
|
64
|
+
if ($[4] !== children || $[5] !== className || $[6] !== scrolls) {
|
|
65
|
+
t5 = scrolls ? /*#__PURE__*/_jsx(ScrollArea, {
|
|
66
|
+
viewportClassName: className,
|
|
67
|
+
children: children
|
|
68
|
+
}) : children;
|
|
69
|
+
$[4] = children;
|
|
70
|
+
$[5] = className;
|
|
71
|
+
$[6] = scrolls;
|
|
72
|
+
$[7] = t5;
|
|
73
|
+
} else {
|
|
74
|
+
t5 = $[7];
|
|
75
|
+
}
|
|
76
|
+
let t6;
|
|
77
|
+
if ($[8] !== onPointerEnter || $[9] !== onPointerLeave || $[10] !== t3 || $[11] !== t5) {
|
|
78
|
+
t6 = createPortal(/*#__PURE__*/_jsx("div", {
|
|
64
79
|
ref: element,
|
|
65
80
|
className: t3,
|
|
66
81
|
style: t4,
|
|
67
82
|
onPointerEnter: onPointerEnter,
|
|
68
83
|
onPointerLeave: onPointerLeave,
|
|
69
|
-
children:
|
|
84
|
+
children: t5
|
|
70
85
|
}), document.body);
|
|
71
|
-
$[
|
|
72
|
-
$[
|
|
73
|
-
$[
|
|
74
|
-
$[
|
|
75
|
-
$[
|
|
86
|
+
$[8] = onPointerEnter;
|
|
87
|
+
$[9] = onPointerLeave;
|
|
88
|
+
$[10] = t3;
|
|
89
|
+
$[11] = t5;
|
|
90
|
+
$[12] = t6;
|
|
76
91
|
} else {
|
|
77
|
-
|
|
92
|
+
t6 = $[12];
|
|
78
93
|
}
|
|
79
|
-
return
|
|
94
|
+
return t6;
|
|
80
95
|
}
|
package/dist/BaselineStatus.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
-
import { CircleCheck, Sparkles, TriangleAlert } from 'lucide-react';
|
|
3
2
|
import { Icon } from '@adecore/ui';
|
|
3
|
+
import { CircleCheck, Sparkles, TriangleAlert } from 'lucide-react';
|
|
4
4
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
5
5
|
const BASELINE_MARKS = {
|
|
6
6
|
widely: {
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
+
import { fileUriToPath } from '@adecore/lsp';
|
|
3
|
+
import { Icon, IconButton, ScrollArea, Segmented, Spinner, Tooltip } from '@adecore/ui';
|
|
4
|
+
import { formatNumber } from '@adecore/ui/format';
|
|
5
|
+
import { ChevronDown, ChevronLeft, ChevronRight, X } from 'lucide-react';
|
|
2
6
|
import { useEffect, useId, useRef } from 'react';
|
|
3
7
|
import { createPortal } from 'react-dom';
|
|
4
8
|
import { useTranslation } from 'react-i18next';
|
|
5
|
-
import {
|
|
6
|
-
import { fileUriToPath } from '@adecore/lsp';
|
|
7
|
-
import { Icon, IconButton, Segmented, Spinner, Tooltip } from '@adecore/ui';
|
|
8
|
-
import { formatNumber } from '@adecore/ui/format';
|
|
9
|
+
import { CALL_LEVEL_LIMIT, isTypeDirection } from './call-hierarchy-model.js';
|
|
9
10
|
import { CALL_HIERARCHY_HEIGHT } from './call-hierarchy.js';
|
|
10
|
-
import { PanelResizeHandle } from "./PanelResizeHandle.js";
|
|
11
|
-
import { usePanelBody } from './use-panel-body.js';
|
|
12
11
|
import { PANEL_BODY_HEIGHT } from './panel-size.js';
|
|
13
|
-
import {
|
|
12
|
+
import { PanelResizeHandle } from "./PanelResizeHandle.js";
|
|
14
13
|
import { basenameOf, relativeTo } from './paths.js';
|
|
15
14
|
import { PathText } from "./PathText.js";
|
|
16
15
|
import { Preview } from "./PeekPanel.js";
|
|
17
|
-
import { SymbolBadge } from "./SymbolPicker.js";
|
|
18
16
|
import { useInputPopup } from './popup-focus.js';
|
|
17
|
+
import { SymbolBadge } from "./SymbolPicker.js";
|
|
18
|
+
import { usePanelBody } from './use-panel-body.js';
|
|
19
19
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
20
20
|
const INDENT = 14;
|
|
21
21
|
const BASE_INDENT = 8;
|
|
@@ -500,11 +500,12 @@ function Tree(t0) {
|
|
|
500
500
|
}
|
|
501
501
|
let t8;
|
|
502
502
|
if ($[21] !== t6 || $[22] !== t7 || $[23] !== treeId) {
|
|
503
|
-
t8 = /*#__PURE__*/_jsx(
|
|
503
|
+
t8 = /*#__PURE__*/_jsx(ScrollArea, {
|
|
504
504
|
id: treeId,
|
|
505
505
|
role: "tree",
|
|
506
506
|
"aria-label": t6,
|
|
507
|
-
className: "w-1/2 shrink-0
|
|
507
|
+
className: "w-1/2 shrink-0 border-r border-border",
|
|
508
|
+
viewportClassName: "py-1",
|
|
508
509
|
children: t7
|
|
509
510
|
});
|
|
510
511
|
$[21] = t6;
|
package/dist/ChangeReview.d.ts
CHANGED
package/dist/CodeAuthorsCard.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
-
import { useTranslation } from 'react-i18next';
|
|
3
|
-
import { GitCommitHorizontal, User, Users } from 'lucide-react';
|
|
4
2
|
import { Button, Icon, Popover, Separator, Tooltip, useNow } from '@adecore/ui';
|
|
5
3
|
import { formatAge, formatNumber } from '@adecore/ui/format';
|
|
4
|
+
import { GitCommitHorizontal, User, Users } from 'lucide-react';
|
|
5
|
+
import { useTranslation } from 'react-i18next';
|
|
6
6
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
7
7
|
const MINUTE_MS = 60_000;
|
|
8
8
|
/* The newest commit that touched the declaration. Its clock ticks here, so a minute redraws this block and not the card. */
|
package/dist/CompletionPopup.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { c as _c } from "react/compiler-runtime";
|
|
2
|
+
import { formatShortcut, ScrollArea } from '@adecore/ui';
|
|
2
3
|
import { useId, useLayoutEffect, useRef, useState } from 'react';
|
|
3
4
|
import { createPortal } from 'react-dom';
|
|
4
5
|
import { useTranslation } from 'react-i18next';
|
|
5
|
-
import { formatShortcut } from '@adecore/ui';
|
|
6
6
|
import { kindLetterOf, kindToneOf, rowWindow } from './completion-model.js';
|
|
7
7
|
import { SourceLine, SymbolSections } from "./HoverSections.js";
|
|
8
8
|
import { PathText } from "./PathText.js";
|
|
@@ -335,10 +335,11 @@ export function CompletionPopup(t0) {
|
|
|
335
335
|
}
|
|
336
336
|
let t19;
|
|
337
337
|
if ($[35] !== listId || $[36] !== t15 || $[37] !== t16 || $[38] !== t18) {
|
|
338
|
-
t19 = /*#__PURE__*/_jsxs(
|
|
338
|
+
t19 = /*#__PURE__*/_jsxs(ScrollArea, {
|
|
339
339
|
id: listId,
|
|
340
340
|
role: "listbox",
|
|
341
|
-
className: "w-0 min-w-full
|
|
341
|
+
className: "w-0 min-w-full",
|
|
342
|
+
viewportClassName: "p-1",
|
|
342
343
|
style: t12,
|
|
343
344
|
onScroll: t13,
|
|
344
345
|
children: [t15, t16, t18]
|
|
@@ -443,22 +444,25 @@ export function CompletionPopup(t0) {
|
|
|
443
444
|
}
|
|
444
445
|
let t28;
|
|
445
446
|
if ($[63] !== view.detailsOpen || $[64] !== view.docs || $[65] !== view.highlightLanguage) {
|
|
446
|
-
t28 = view.detailsOpen && view.docs !== null && /*#__PURE__*/
|
|
447
|
+
t28 = view.detailsOpen && view.docs !== null && /*#__PURE__*/_jsx("div", {
|
|
447
448
|
ref: docs,
|
|
448
|
-
className: `${CARD} flex w-[360px] flex-col
|
|
449
|
+
className: `${CARD} flex w-[360px] flex-col`,
|
|
449
450
|
style: {
|
|
450
451
|
visibility: "hidden"
|
|
451
452
|
},
|
|
452
453
|
onPointerDown: _temp4,
|
|
453
|
-
children:
|
|
454
|
-
|
|
455
|
-
children: /*#__PURE__*/_jsx(
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
454
|
+
children: /*#__PURE__*/_jsxs(ScrollArea, {
|
|
455
|
+
viewportClassName: "flex flex-col divide-y divide-border select-text",
|
|
456
|
+
children: [view.docs.source !== "" && /*#__PURE__*/_jsx("div", {
|
|
457
|
+
className: "px-3 py-2",
|
|
458
|
+
children: /*#__PURE__*/_jsx(SourceLine, {
|
|
459
|
+
text: view.docs.source,
|
|
460
|
+
language: view.highlightLanguage
|
|
461
|
+
})
|
|
462
|
+
}), /*#__PURE__*/_jsx(SymbolSections, {
|
|
463
|
+
text: view.docs.text
|
|
464
|
+
})]
|
|
465
|
+
})
|
|
462
466
|
});
|
|
463
467
|
$[63] = view.detailsOpen;
|
|
464
468
|
$[64] = view.docs;
|
package/dist/DiffView.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { type Ref } from 'react';
|
|
2
1
|
import type { Editor, EditorEngine, EditorTheme } from '@adecore/editor';
|
|
3
2
|
import { type DiffDocument, type DiffSourceLine } from '@adecore/merge';
|
|
4
|
-
import { type
|
|
3
|
+
import { type Ref } from 'react';
|
|
5
4
|
import { type DiffLimits } from './diff-expansion.ts';
|
|
5
|
+
import { type DiffSourceTokens } from './diff-syntax.ts';
|
|
6
6
|
export interface DiffViewProps {
|
|
7
7
|
engine: EditorEngine;
|
|
8
8
|
document: DiffDocument;
|