codesandbox / codesandbox/codesandbox-client

fl, fi in the code editor are not of expected width

Open
#8,456 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
13.6k
Forks
2.4k
Avg merge
6d 19h
Merged PRs (30d)
2

Description

🐛 bug report

Preflight Checklist

  • I have read the Contributing Guidelines for this project.
  • I agree to follow the Code of Conduct that this project
    adheres to.
  • I have searched the issue tracker for an issue that matches the one I want
    to file, without success.

Description of the problem

fi and fl occupy 1 space when expected to take up 2 spaces. Looking at issue #728, this was resolved a long time ago, but I am running into this currently.

How has this issue affected you? What are you trying to accomplish?

Just a visual bug thats a bit annoying to the eye :), nothing impeding work.

To Reproduce
  • in a default React codesandbox
  • Type fi or fl and notice that the character width changes

https://github.com/codesandbox/codesandbox-client/assets/79128454/da05781a-75a9-4747-9aa8-0c4be3974e58

Your Environment
Software Name/Version
Сodesandbox Version: 0.0.316/Sandbox: l82xlj
Browser Chrome Version 123.0.6312.124
Operating System MacOS 14.4.1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue in a default React CodeSandbox using Chrome on macOS, then inspect the code editor entry point responsible for character measurement and ligatures. Verify the behavior for both fi and fl; done means each occupies the expected two-space width without changing other character rendering.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.