Skip to content

fix: show full value on hover for truncated single-line fields#10273

Merged
fiosman merged 10 commits into
developfrom
fix/ins-3041
Jul 23, 2026
Merged

fix: show full value on hover for truncated single-line fields#10273
fiosman merged 10 commits into
developfrom
fix/ins-3041

Conversation

@fiosman

@fiosman fiosman commented Jul 17, 2026

Copy link
Copy Markdown
Contributor
  • Adds logic to display a tooltip when hovering over a code mirror line editor. The tooltip is only displayed when the text in the code mirror cell is truncated. Handles cases when there is a combination of nunjucks tags and plain text in a cell.
  • Update native tooltip text for environment variables nunjucks tags

Jira

@github-actions

github-actions Bot commented Jul 17, 2026

Copy link
Copy Markdown

✅ Circular References Report

Generated at: 2026-07-23T17:37:22.467Z
Status: ✅ NO CHANGE

Summary

Metric Base (develop) PR Change
Total Circular References 9 9 0 (0.00%)
Click to view all circular references in PR (9)
insomnia-inso/src/db/models/types.ts -> insomnia-inso/src/db/types.ts
insomnia/src/main/prompt-bridge.ts -> insomnia/src/main/window-utils.ts -> insomnia/src/main/plugin-window.ts
insomnia/src/main/window-utils.ts -> insomnia/src/main/plugin-window.ts
insomnia/src/network/network.ts -> insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts
insomnia/src/ui/components/settings/import-export.tsx -> insomnia/src/ui/components/modals/export-requests-modal.tsx
insomnia/src/ui/components/tabs/tab-list.tsx -> insomnia/src/ui/components/tabs/tab.tsx
insomnia/src/ui/components/templating/tag-editor-arg-sub-form.tsx -> insomnia/src/ui/components/templating/external-vault/external-vault-form.tsx
insomnia/src/ui/components/viewers/response-viewer.tsx -> insomnia/src/ui/components/viewers/response-multipart-viewer.tsx
Click to view all circular references in base branch (9)
insomnia-inso/src/db/models/types.ts -> insomnia-inso/src/db/types.ts
insomnia/src/main/prompt-bridge.ts -> insomnia/src/main/window-utils.ts -> insomnia/src/main/plugin-window.ts
insomnia/src/main/window-utils.ts -> insomnia/src/main/plugin-window.ts
insomnia/src/network/network.ts -> insomnia-scripting-environment/src/objects/index.ts -> insomnia-scripting-environment/src/objects/collection.ts -> insomnia-scripting-environment/src/objects/response.ts
insomnia/src/network/network.ts -> insomnia/src/common/render.ts
insomnia/src/ui/components/settings/import-export.tsx -> insomnia/src/ui/components/modals/export-requests-modal.tsx
insomnia/src/ui/components/tabs/tab-list.tsx -> insomnia/src/ui/components/tabs/tab.tsx
insomnia/src/ui/components/templating/tag-editor-arg-sub-form.tsx -> insomnia/src/ui/components/templating/external-vault/external-vault-form.tsx
insomnia/src/ui/components/viewers/response-viewer.tsx -> insomnia/src/ui/components/viewers/response-multipart-viewer.tsx

Analysis

No Change: This PR does not introduce or remove any circular references.


This report was generated automatically by comparing against the develop branch.

@fiosman
fiosman marked this pull request as ready for review July 22, 2026 18:18
Copilot AI review requested due to automatic review settings July 22, 2026 18:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves UX for truncated single-line inputs by showing the full value in a tooltip on hover, and enhances templating tooltips to show variable source context more clearly.

Changes:

  • Extend the shared Tooltip to support conditional display (shouldShow) and cursor-anchored positioning (followCursor), with a custom dwell timer to avoid cross-tooltip “warmup” behavior.
  • Wrap OneLineEditor with a tooltip that only appears when the editor content is horizontally truncated.
  • Adjust Nunjucks variable tooltip formatting and update render-context key source labels to use environment names.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

File Description
packages/insomnia/src/ui/components/tooltip.tsx Adds cursor-following + conditional tooltip display and replaces react-stately hover delay behavior with a custom dwell timer.
packages/insomnia/src/ui/components/.client/codemirror/one-line-editor.tsx Wraps the one-line editor with a tooltip that shows full content on hover only when truncated.
packages/insomnia/src/ui/components/.client/codemirror/extensions/nunjucks-tags.ts Updates variable tooltip text formatting to append key source context.
packages/insomnia/src/common/render.ts Changes key source labeling from internal identifiers to environment names for tooltip context.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/insomnia/src/ui/components/tooltip.tsx Outdated
Comment thread packages/insomnia/src/common/render.ts Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 3 comments.

Comments suppressed due to low confidence (1)

packages/insomnia/src/common/render.ts:447

  • The keyContext labels for root/global environments only include “(Project)”/“(Collection)” in the fallback string, but not when the environment has a name. Since base environments are often named "Base Environment" in both scopes, this can make the rendered {source} ambiguous. Consider always suffixing the scope regardless of whether name is present (matching the sub-environment labels).
  if (rootGlobalEnvironment) {
    getKeySource(rootGlobalEnvironment.data || {}, inKey, rootGlobalEnvironment.name || 'Base Environment (Project)');
  }

  if (subGlobalEnvironment) {
    getKeySource(
      subGlobalEnvironment.data || {},
      inKey,
      `${subGlobalEnvironment.name || 'Environment'} (Project Sub-Environment)`,
    );
  }

  // Get Keys from root environment
  getKeySource((rootEnvironment || {}).data, inKey, rootEnvironment?.name || 'Base Environment (Collection)');

Comment thread packages/insomnia/src/ui/components/tooltip.tsx
Comment thread packages/insomnia/src/ui/components/tooltip.tsx
Comment thread packages/insomnia/src/ui/components/.client/codemirror/one-line-editor.tsx Outdated
@fiosman
fiosman requested a review from a team July 22, 2026 20:36
ryan-willis
ryan-willis previously approved these changes Jul 22, 2026
state.close(true);
};

useEffect(() => clearDwellTimeout, []);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clever

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

Comment thread packages/insomnia/src/ui/components/tooltip.tsx
@fiosman
fiosman requested a review from ryan-willis July 23, 2026 17:30
@fiosman
fiosman merged commit ca34795 into develop Jul 23, 2026
21 checks passed
@fiosman
fiosman deleted the fix/ins-3041 branch July 23, 2026 18:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants