Comments (4)
Thanks for the research. Maybe for now we just need to bump the font size down to 18px for Italian.
from dim.
@liamdebeasi would you want to take a peek at this one? Adding the account-wide drop power definitely crowds out the vault label, but I wonder if we could use container queries or something to scale fonts to fit inside their space.
from dim.
Sure! I'll take a look and send over some ideas for how we can solve this.
from dim.
The text overflow here is a bit tricky due to the nameplate's sizing constraints. I don't know if we'll be able to devise a solution that ensures all characters are visible and legible while also keeping the nameplate dimensions the same.
You run into a couple potential issues by dynamically scaling the font size:
- Nameplates could have different class font sizes with longer class names having smaller font sizes (See image below). This could make the design look a bit inconsistent.
This could be somewhat mitigated by reducing the class font size by a fixed amount on each nameplate to maintain consistency.
- Really long class names could result in the text being so small it is no longer readable.
This could be somewhat mitigated by enforcing a minimum font size. Alternatively, if we instead reduced the class font size by a fixed amount then this would not be an issue.
Changing the font size from 20px to 18px for the class text is a quick fix. You could also maybe change the width of the nameplates on desktop. However, this likely will not resolve the issue for all scenarios. Additionally, this will almost certainly become an issue again when implementing font scaling features.
A different user interface may be necessary to properly solve this problem. For example, the nameplate may need to be larger overall to allow for both longer and larger text. Rough idea of what that could look like:
Other options I explored that did not work for various reasons
Scale both width and height
In order to preserve the proportions of the nameplate while showing all the text we'd need to scale both the width and the height. While this would ensure all text was visible the result looks a bit odd. Additionally, this may cause issues on smaller screens (such as small mobile phones) where it would be possible for the nameplate to extend beyond the bounds of the screen. As a result, I don't recommend this approach.
Wrap Text
Wrapping the text to the next line ensures that all the text is visible. However, the dimensions of the nameplate make this solution not practical. The class text would run into the player's title. We could change the height to accommodate, but then we run into the same problem as the previous approach.
Just scaling the width
This runs into the same issue as above where it would be possible for the nameplate to extend beyond the bounds of the screen. Additionally, the background image would not span the full width of the nameplate.
from dim.
Related Issues (20)
- Xur inventory refresh timer is very wrong HOT 3
- Perks inside Weapon Cards are marked as wishlisted even if there is no wishlist with such perks HOT 4
- Dupe exotic class items HOT 2
- Please move grouping options into the inventory screen HOT 1
- Loadout search field shouldn't autocomplete HOT 1
- Increase/remove max note length HOT 2
- Show equipped super information on hover from the loadouts page
- exotic class item - when comparing, add an option to sort alphabetically HOT 1
- Community Insight display is too large on iOS HOT 2
- Europa Theme un-masterworked weapons "thumbs up" not visible; blends with white icon color
- Max LL gear issue per character HOT 2
- Add search option to filter by Deepsight Pattern Progress? HOT 3
- Keep selected character in URL between Loadouts and Loadout Optimizer
- Keep search alive when moving between Inventory and Organizer, Records
- Ergo sum compare should be groupable by intrinsic perk HOT 1
- Performing an action from compare window in Organizer blocks input HOT 2
- Unable to preview/insert Sect mods on Aeon Armor in DIM HOT 1
- Reused Saved Searches using insaved: HOT 3
- change enhanced weapons' polaroid icon HOT 1
- Unrecognized Content-Security-Policy directive 'prefetch-src' HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dim.