Input number field spin buttons hides the actual value

LiteCart Fan
من Germany
عضو منذ يناير 2023

Could we not remove the arrows of the fields "Weight", "Dimensions" and "Quantities" in the catalog at the Stocktab, because they make the input very difficult?

With my resolution 1920x1080 and window display normal in the browser I can enter nothing at all, because the field content is simply not visible. If I zoom out, it works a bit, but it has happened to me several times that I had four digits instead of 3-digit input, because only 2 digits are visible and consequently the product weight is not correct at all.

The arrows themselves I could never use with my inputs.

tim
Founder
من Sweden
عضو منذ مايو 2013
tim

Zoom out, toggle the menu. That's what I would do if I was on a small screen.

If you are looking for a permanent solution, swap [b]form_draw_decimal_field[/b] with [b]form_draw_text_field[/b] or you can add a psuedo style:


input[type="number"]::-webkit-inner-spin-button {
  display: none;
}```

https://github.com/litecart/litecart/blob/2.5.2/public_html/admin/catalog.app/edit_product.inc.php#L758-L777
LiteCart Fan
من Germany
عضو منذ يناير 2023

Thank you for the quick and good answer.
Of course, I would prefer the permanent solution, because I really have never used the "spin buttons", although I have now filled dozens of products in the store.
Since I know nearly nothing about programming, I am not quite clear whether all calculations in the program or modules (i.e. shipping) still works correct when I make text fields from the decimal fields.
To me the solution would be much better if I knew where in the file [i]edit_product.inc.php[/i]
I would have to put these lines.

tim
Founder
من Sweden
عضو منذ مايو 2013
tim

You can put them anywhere you like in the file if you wrap them around a <style> element.
Or put them in your framework.min.css to do this globally allover the entire backend.

What is your screen size and resolution? From the looks of your screenshot it could be a 7" Raspberry Pi display.

LiteCart Fan
من Germany
عضو منذ يناير 2023

Thank you very much, I will try to integrate it that way in framework.css.
 
My screen is 27" with 1920x1080 resolution, but the browser only gets about 3/4 of the screen.

May I ask once quite stupidly, who or for what one uses these "adjustment arrows"? In a new entry I have to insert valid numbers anyway and if they are have (most) 2-3 digits, I would have to press an arrow for a very long time?

tim
Founder
من Sweden
عضو منذ مايو 2013
tim

[quote]May I ask once quite stupidly, who or for what one uses these "adjustment arrows"?[/quote]
This is a browser component implemented by the browser vendor. This is not the right forum for this question.

This is the community help forum for Chrome users regarding questions about the Chrome web browser:
https://support.google.com/chrome/thread/new

LiteCart Fan
من Germany
عضو منذ يناير 2023

I would need help again please.

I am definitely too stupid/unknowledgeable to correctly incorporate the suggestion into framework.css.

So I tried in edit_product.inc.php to include the lines:
<style>
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
display: none;
}
</style>

But I don't see any change in my admin/catalog.
What am I doing wrong?

LiteCart Fan
من Germany
عضو منذ يناير 2023

I have inserted it after line 153.
The old line 154 is now 163, because I also inserted a blank line before and after the new section.

tim
Founder
من Sweden
عضو منذ مايو 2013
tim

Sorry I have no idea what you are doing differently. Those are the lines that remove the spinner for webkit users. Are you using Firefox maybe?

Firefox users do this:


  -moz-appearance: textfield;
}```
LiteCart Fan
من Germany
عضو منذ يناير 2023

Thank you very much for the great help.
That was the solution, because I actually use Firefox.
Since I could have searched / tried for a long time without your help.

تم إغلاق هذا الموضوع بسبب عدم النشاط لفترة طويلة، ولا يمكن إرسال المشاركات إليه.
This website uses no cookies and no third party tracking technology. We think we can do better than others and really think about your privacy.