Code Monkey home page Code Monkey logo

Comments (4)

r-renato avatar r-renato commented on July 28, 2024

you need to change the .temp and .tempc css classes.
For example:

            style: |
              .temp {
                ....
              }
              .tempc {
                ....
              }

See: https://github.com/r-renato/ha-card-weather-conditions/blob/master/src/ha-style-summary.ts

from ha-card-weather-conditions.

mfabiani53 avatar mfabiani53 commented on July 28, 2024

Ok, can you give me some hints about how to make that number more visible? I am not so good with css...
I also tried your examples, but without changing nothing, my card is always the same... Surely i am wrong in something, but don't know where to check...

from ha-card-weather-conditions.

r-renato avatar r-renato commented on July 28, 2024

You need to adjust the font size (e.g.: 49px -> 39px -> ...)

          style: |
              .temp {
                font-size: calc(49px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
              }
              .tempc {
                ....
              }

from ha-card-weather-conditions.

mfabiani53 avatar mfabiani53 commented on July 28, 2024

Sorry, but i changed the style in this way:

          - type: custom:ha-card-weather-conditions
            style: |
              ha-card {
                font-size: 14px;
                font-family: 'Georgia';
                font-weight: normal;
              }
              .icon.bigger {
                width: 10em;
                height: 10em;
                margin-top: -4em;
                position: absolute;
                left: 0em;
              } 
              .title {
                position: absolute;
                left: calc(140px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                top: 0.6em;
                font-weight: 300;
                font-size: calc(14px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                color: var(--primary-text-color);
              }
              .moon {
                position: absolute;
                left: calc(115px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                top: calc(63px - (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                font-weight: 300;
                font-size: calc(14px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                color: var(--primary-text-color);
                line-height:20px;
                display: inline-block;
              }
              .temp {
                position: absolute;
                // top: 0.65em;
                font-weight: 300;
                font-size: calc(39px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                color: var(--primary-text-color);
                right: 1em;
                margin-top: 2px;
              }
              .tempc {
                position: absolute;
                font-weight: 300;
                font-size: calc(12px + (26 - 14) * ((100vw - 300px) / (1600 - 300)));
                // font-size: 1.5em;
                vertical-align: super;
                color: var(--primary-text-color);
                right: 1em;
                margin-top: -11px;
                margin-right: 7px;
              } 

But nothing changed i have always the same big number... i tried 39px, 29px, 19px but no way...
Maybe it's my fault as i told you about my knowledge in css styiling...

This is what i get when changing font-size to 39 from 49px

Schermata 2020-06-11 alle 11 32 53
Same as before...

from ha-card-weather-conditions.

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.