Skip to content

Commit ec74509

Browse files
committed
docs: add info about the naming algorithm
1 parent 11c6d3e commit ec74509

File tree

1 file changed

+23
-3
lines changed

1 file changed

+23
-3
lines changed

docs/content/main.css

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -351,7 +351,27 @@ Styleguide: concepts
351351
/*
352352
Naming algorithm
353353
354-
Almost all abbreviations in mlut are compiled by one algorithm. Below will be a simplified algorithm for compiling the abbreviations of the utilities names. Later it will be supplemented
354+
Almost all abbreviations in mlut are compiled by one algorithm.
355+
356+
Weight: 0
357+
358+
Styleguide: concepts.naming
359+
*/
360+
361+
/*
362+
TL;DR
363+
364+
The more popular a CSS property (or value, state, etc) is, the shorter and simpler its abbreviation will be. For example, `D` stands for `display`, and `Ctn` stands for `container`.
365+
366+
Weight: 0
367+
368+
Styleguide: concepts.naming.tldr
369+
*/
370+
371+
/*
372+
Full version
373+
374+
Below is a slightly simplified algorithm for composing abbreviations of utility names. It will be supplemented in the future.
355375
356376
1. get all CSS properties that starts with one letter
357377
1. make ranking of them by popularity or alphabet if the popularity is not possible to calculate. Popularity for properties is calculated based on [Chrome platforf statistic](https://chromestatus.com/metrics/css/popularity)
@@ -378,9 +398,9 @@ The order of adding the letter:
378398
379399
Examples you can see in the [utils reference](section-utils-reference.html). More visual examples here will appear later.
380400
381-
Weight: 0
401+
Weight: 1
382402
383-
Styleguide: concepts.naming
403+
Styleguide: concepts.naming.full
384404
*/
385405

386406
/*

0 commit comments

Comments
 (0)