Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Text shadow appears behind the entered text that disrupts readability #386

Closed
2 tasks done
maximbaz opened this issue Sep 3, 2017 · 8 comments
Closed
2 tasks done

Comments

@maximbaz
Copy link
Contributor

maximbaz commented Sep 3, 2017

  • I am on the latest Cerebro.app version
  • I have searched the issues of this repo and believe that this is not a duplicate
  • OS version and name: ArchLinux
  • Cerebro.app version: 0.3.1
  • Relevant information from devtools (See above how to open it): N/A

Issue

With the update to 0.3.1 there is now a weird text shadow showing behind the entered text. Basic apps seem to be not affected, but other plugins are. Better see the gif:

cerebro-fonts

Another picture that shows how bad the readability has become:

image

@LuckyLukert
Copy link

LuckyLukert commented Sep 26, 2017

Hi,

I have the same problem.
The autocompletion has an other font than the typed text.

Best regards,
Lucky

@maximbaz
Copy link
Contributor Author

maximbaz commented Nov 9, 2017

The problem is that this line gets overridden by some css-reset file for <input> elements:

https://github.com/KELiON/cerebro/blob/adba0769998a9769454d80e75ebeb1119a9ebb77/app/main/css/global.css#L16

I believe the fix is to append font-family: var(--main-font); after the following line:

https://github.com/KELiON/cerebro/blob/b01acaf6d4159e63cab361c821f90433afbff77a/app/main/components/MainInput/styles.css#L6

@KELiON
Copy link
Collaborator

KELiON commented Nov 10, 2017

@maximbaz can you try your fix? I can't reproduce it on mac(

@maximbaz
Copy link
Contributor Author

I can confirm this just in devtools:

cerebro-font

But repo cloning from scratch is broken again, these commands:

$ git clone https://github.com/KELiON/cerebro.git cerebro
$ cd cerebro && yarn && cd ./app && yarn && cd ../
$ yarn run dev

Result into this error when running $ yarn run dev:

Uncaught Exception:
Error: Cannot find module '../tray'
    at Module._resolveFilename (module.js:470:15)
    at Function.Module._resolveFilename (/home/maximbaz/private/cerebro/node_modules/electron/dist/resources/electron.asar/common/reset-search-paths.js:35:12)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.get [as Tray] (/home/maximbaz/private/cerebro/node_modules/electron/dist/resources/electron.asar/browser/api/exports/electron.js:11:16)
    at AppTray.show (/home/maximbaz/private/cerebro/app/main.js:1795:24)
    at App._electron.app.on (/home/maximbaz/private/cerebro/app/main.js:653:10)
    at emitTwo (events.js:111:20)
    at App.emit (events.js:191:7)

Wanna have a separate bug for that? 🙂

@lawgsy
Copy link
Contributor

lawgsy commented Nov 30, 2017

I can confirm this bug and the proposed fix as working. Windows 10, clean install/compile.

The underlying issue is the dependency normalize.css, which at some point overwrites the input field CSS, but not the autocomplete one, with font-family: sans-serif;

This same module is causing issues on Windows (10, at least), as it sets the line-height for everything:
html { line-height: 1.15; ...
This causes every result row to display vertical scrollbars (or arrows at least, because the height is too little for an entire bar):

One way of fixing this would be adding overflow-y: hidden; to .title and .subtitle of main/components/ResultList/Row/styles.css (it currently already and only contains an overflow-x: hidden for that component.

Commenting out overflow-x: hidden; for both .title and .subtitle elements in main/components/ResultList/Row/styles.css appears to work just as well.

@lawgsy
Copy link
Contributor

lawgsy commented Dec 2, 2017

Pull request to possible fix: #421

@maximbaz
Copy link
Contributor Author

maximbaz commented Dec 4, 2017

@KELiON planning a release soon? #426 blocks me from testing this bug fix, but it will also block the next release for Arch Linux (because we always recompile from source).

@KELiON
Copy link
Collaborator

KELiON commented Dec 5, 2017

@maximbaz just released version 0.3.2

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

No branches or pull requests

4 participants