Conversation
|
@nikolai-shabalin вот вам ещё один |
… в отдельный файл
|
@meritt , давай в прод? |
| color: oklch(60% 0.15 240); | ||
| } | ||
|
|
||
| &__element { |
There was a problem hiding this comment.
В CSS файле?
@firefoxic не, тут промахнулся. Надо под widely available перепроверить тесты.
There was a problem hiding this comment.
Я даже не про available скорее, а про разрезание класса — в CSS не работает же так)
А на счёт widely — добавьте к нему в конфиге отсечку почти нулевой аудитории:
# .browserslistrc
baseline widely available and > 0.05%
Тогда хром и сафари почти все 2.5 года так и остаются, а вот у лисы ESR только (сейчас 140), а на версиях старше нет пользователей — ждать не зачем ≈полтора года. К примеру сейчас @property без отсечки нельзя, с ней можно. Та же история скоро (или уже) будет со @scope, anchor positioning, style queries и тд.
There was a problem hiding this comment.
А и ещё: widely нестингу не страшен же, если lightningcss использовать — он грамотно раскладывает его в :is(), если есть версии без поддержки.
Major update of Stylelint config aligned with htmlacademy/codeguide#75.
Config format migrated from
.stylelintrc(JSON) tostylelint.config.js(ESM).extends: "stylelint-config-htmlacademy"keeps working — resolved throughpackage.json#exports.Dependencies
@stylistic/stylelint-plugin4.0.0^5.1.0stylelint-order^8.1.1postcss-less6.0.0^6.0.0postcss-scss4.0.9^4.0.9stylelint(peer)^16.25.0>=17>=24Added
order/order[custom-properties, declarations, rules]order/properties-orderselector-no-deprecatedtrue:-webkit-anyselector-anb-no-unmatchabletrue:nth-child(0)selector-no-invalidtrue[0foo],:nth-child(2n+)no-unknown-custom-mediatrue@custom-mediaat-rule-disallowed-list["import"]@importin CSSdeclaration-block-single-line-max-declarations0selector-max-compound-selectors2.a.b.cselector-max-class2.a.b.cclass chainsselector-max-combinators2.a .b .c .dselector-max-type2.x section article ptime-min-milliseconds100transition: 50mscolor-function-alias-notation"without-alpha"rgba(),hsla()alpha-value-notation"percentage"opacity: 0.5,rgb(0 0 0 / 0.5)(auto-fix)lightness-notation"percentage"oklch(0.6 ...)media-feature-range-notation"context"(min-width: 768px)syntax (auto-fix)keyframes-name-pattern@keyframes slideIncustom-media-pattern@custom-media --bpMobilecustom-property-pattern--colorPrimaryselector-id-pattern#mainContentselector-nested-pattern"&"&(native CSS Nesting + SCSS/LESS)Property order
7 semantic groups (
custom-properties→positioning→box-model→typography→decoration→animation→interactivity) covering ~430 modern CSS properties: container queries, anchor positioning, view transitions, full logical properties, scroll API, masks,field-sizing,corner-shape. Lives in a separateproperties-order.js.Changed
selector-class-pattern^[a-z0-9-_]+$block__element--modifierwithresolveNestedSelectors: trueselector-not-notation"simple"(:not(.a):not(.b))"complex"(:not(.a, .b)) (auto-fix)color-function-notationnull"modern"(rgb(255 0 0)instead ofrgb(255, 0, 0))declaration-no-importantfont-family-no-duplicate-namestrueignoreFontFamilyNames: ["monospace"]Removed
value-keyword-caseoptioncamelCaseSvgKeywords: true— fixed false positives incolor-mix(in srgb, ...)and similar modern CSS functions.