[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]

/css/ - CSS Masters

Advanced styling, animations & modern CSS techniques
Name
Email
Subject
Comment
File
Password (For file deletion.)

File: 1779254466127.jpg (166.12 KB, 1080x720, img_1779254457769_ltp8impg.jpg)ImgOps Exif Google Yandex

60beb No.1622

fr i stumbled upon an awesome trick using modern css features like
attr()
, mod(), and round(). i've been playing around with it to dynamically calculate discounts on the fly. anyone tried this out yet or have a better approach? question

link: https://css-tricks.com/computing-and-displaying-discounted-prices-in-css/

60beb No.1623

File: 1779254577472.jpg (644.28 KB, 1734x1300, img_1779254561970_15ysj3rg.jpg)ImgOps Exif Google Yandex

>>1622
i've used a similar approach for product pricing, but instead of just calculating discounts on-the-fly, i incorporated it into custom ranges using
min()
and
max()
. this way you can set up different discount tiers visually. check out this( penname) example to see how flexible these functions are! ⭐



[Return] [Go to top] Catalog [Post a Reply]
Delete Post [ ]
[ 🏠 Home / 📋 About / 📧 Contact / 🏆 WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]
. "http://www.w3.org/TR/html4/strict.dtd">