Giter VIP home page Giter VIP logo

Comments (11)

paulirish avatar paulirish commented on May 2, 2024

from lighthouse.

addyosmani avatar addyosmani commented on May 2, 2024

Yep!

from lighthouse.

paullewis avatar paullewis commented on May 2, 2024

@mounirlamouri might know!

from lighthouse.

mounirlamouri avatar mounirlamouri commented on May 2, 2024

I do not think we do any kind of significant trimming in Chrome (there is a 4Ki limit but not what you are asking I think :)).

@addyosmani where do you see the trim? Is it in the home screen? or the Chrome UI?

from lighthouse.

paullewis avatar paullewis commented on May 2, 2024

I think it's more the visual wrangling you do to make sure it's not truncated on the home screen.

from lighthouse.

addyosmani avatar addyosmani commented on May 2, 2024

@mounirlamouri I see it in the homescreen. I'll see if I can put together a repro.

from lighthouse.

paulirish avatar paulirish commented on May 2, 2024

This is a smart check to have, yeah.

I am pretty sure i've seen quite different results on a Nexus 6 vs a smaller phone for this number.

@addyosmani have you gotten a sense of what string lengths work?

from lighthouse.

paulirish avatar paulirish commented on May 2, 2024

From my homescreen.. here's what is and isn't truncated, along with string lengths:

HackerWeb # 9
Play Store  # 9
Pocket Cas… # 10
Chrome Ca… # 9
Popcorn Ti… # 10
What’s my…  # 9
Flipkart Lite   # 13
Guitar Tuner # 12
Trained To… # 10
Inbox Attack # 12
Get Kana! # 9
BusRouter… #9

By now, you can tell that Roboto doesn't use the same width for all letters. :)
An app called iiiiiiiiiiiiiiiii (with 17 i's) will fit, but wwwwwwww (with 8 w's) won't (and will get truncated to 7 plus an ellipsis).

from lighthouse.

paullewis avatar paullewis commented on May 2, 2024

If we know widths and fonts we can guess pretty well with a measureText. We could ask the page to do it in JS as a gather once we have a manifest. It's messy.

from lighthouse.

samccone avatar samccone commented on May 2, 2024

Let me follow up with the android UI team... and see if I can get a real answer on this.

from lighthouse.

paulirish avatar paulirish commented on May 2, 2024

fixed by #145

from lighthouse.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.