Commit Graph
10 Commits
Author SHA1 Message Date
waozi 7ff4ea1111 Read linear gradients at any angle with up to six stops
linear-gradient() in background and background-image takes an angle (deg,
turn, rad or grad) or to a side or corner, and two to six color stops with
optional percentage positions, which fill in as in CSS. Top to bottom with
two end stops stays the two-color face every widget paints; anything else
is a box gradient Row, Column and Grid paint, with the direction computed
here, while other widgets paint the first and last colors top to bottom and
css_tool check says so. Radial, conic and repeating gradients are refused
natively with the reason.

The pack format is 101 words a rule. Pins Kryon d0711324.
2026-11-22 23:50:24 -03:00
waozi 79210326ef Read ancestor, parent, :first-child and :not() selectors natively
One ancestor compound, matched by its class or id, may come before the
styled compound: '.card Text' for any ancestor, '.card > Text' for the
parent. :first-child, :not(.class) and :not(:state) add tree context, also
in nested & rules, and the DOM export writes all of them as browser
selectors. :last-child, :nth-child(), typed or second ancestors and sibling
combinators fail with the native idiom.

The pack format is 87 words a rule. Pins Kryon 56777c65, which matches the
context while the frame builds.
2026-11-22 23:28:44 -03:00
waozi 8cc92b4e52 Read per-side borders and outline natively
border-top, border-right, border-bottom, border-left and the logical
block and inline sides, each with -width, -color and -style, become box
fields on Row, Column and Grid, var() values included; a uniform border
later in the same rule clears earlier sides. With a border radius a box
paints its uniform border, and css_tool check reports it. Border widths
take thin, medium and thick.

outline, outline-width and outline-offset size the native focus ring;
outline: none keeps it, which css_tool check says. The pack format is 82
words a rule and the README table lists the new properties. Pins Kryon
d97c19e8.
2026-11-22 23:17:16 -03:00
waozi b8c8eb3439 Read percentage sizes natively
width, height, min-width, max-width, max-height and their logical aliases
take a percentage on Row, Column and Grid, as does min-height there, and
flex-basis takes one directly or through flex. The parser keeps the
percentage with a percent mask; Kryon layout resolves it against the
parent's content box. A percentage inside calc(), min(), max() or clamp(),
or on another widget's size, fails a plain native parse with the reason.

The pack format gains the style, flex and box masks (72 words a rule), the
committed style packs are regenerated, and the README table lists the new
values. Pins Kryon 60f081a4.
2026-11-22 22:46:12 -03:00
waozi 3effc75222 Resolve calc(), min(), max(), clamp(), em, vw and vh natively
Lengths read through one expression reader. Without viewport units an
expression folds to pixels as the sheet is read, so box, size and flex
lengths take calc() and em too (em is the rule's own font-size, else
16px). With vw or vh it stays a clamp of linear forms the install
evaluates against the environment's viewport; packs carry them in an
exprs table, and CssSheetSameMedia reports a change when a new viewport
changes an active rule's length. A var() fallback may hold one more
var(), and var(--kryon-NAME) reads the installed theme palette.
2026-11-22 18:54:17 -03:00
waozi d8044da394 Test painted, stretched and self-sizing containers; pin Kryon a04a3ba1
The layout pack now covers a content-sized card that paints its CSS box
beneath its child, a fixed-width column that stretches to its row, an
auto-width column that takes what the row left, flex: 1 taking a
column's remaining height, margin-left: auto, and Text sizing itself
where a container places it. The raster stub provides RasterTriangles
for the Text import.
2026-11-22 18:40:55 -03:00
waozi 82398790ca Lower CSS box properties to native layout and use one pack layout
margin (with auto), min-width, max-width, max-height, overflow and
text-align now compile to Kryon's StyleBoxData instead of passing to
the browser. Compiled packs use a single 69-word rule and 22-word
condition layout; a pack in an older layout is refused as stale, and
the five rule formats and the old condition format are gone. The
layout test checks centering, margins, clamps and clipping at 550 and
1200 px. Tests import kryon/Frame. Pins Kryon 28453c71.
2026-11-22 17:32:59 -03:00
waozi 834f60cff8 Compile native flex styles and responsive layout packs 2026-11-22 16:32:02 -03:00
waozi 7dd9fff21b Enable native viewport grids in CSS 2026-11-21 17:08:31 -03:00
waozi eba580e376 Compile native width and height for retained layouts 2026-11-20 12:19:41 -03:00