/* --------------------------------------------------------------------------- wave46 / field-panels.css — contract C6, W46-T31. The lane's own sheet for the two FIELD surfaces: the Hide-fields row's trailing actions menu (owner instruction 21) and the add-field type list's info mark (owner instruction 27). ⛔ IMPORTED FROM THE COMPONENTS, NEVER FROM index.css. `FieldsHidePanel.tsx` and `ColumnMenu.tsx` each `import "../styles/wave46/field-panels.css"`, so the bundler emits it AFTER index.css and these rules win their equal-specificity fights. An `@import` at the top of index.css would have been inlined at the top of the cascade and lost every one of them, silently. [[a-lane-stylesheet-cannot-override-index-css]] ⛔ TOKENS ONLY. No literal `font-size` (verify_ui.py's R5 sweeps every *.css under src/ and reds on one), no inline hex, no shadow that is not on an overlay. --------------------------------------------------------------------------- */ /* ---- the row's trailing actions slot ------------------------------------------------ ⭐ `margin-left: auto` IS THE TRAILING SLOT, and it moved here with the control. It used to live on `.cg-check-del`, the button this menu replaced; without it the trigger would sit tight against the last badge instead of at the row's end. On a row that also offers Remove from my fields, that button keeps its own auto margin and takes the gap, and this control follows it — which is the order the two belong in. */ .w46-field-actions { position: relative; flex: 0 0 auto; display: inline-flex; align-items: center; margin-left: auto; } /* The trigger is `.cg-field-edit-trigger` still, so it keeps the 18px box, the radius and the hover-reveal the manager list already gives it. What this adds is the OPEN state: a menu hanging off an invisible button reads as a bug, so an open row keeps its trigger painted whether or not the pointer is still on the row. ⛔ The four native-chrome resets are stated here in full rather than inherited, because this class is also mounted OUTSIDE `.cg-fields-manager` (the grid's own Fields panel), where none of wave 41's manager-scoped rules apply at all. */ .w46-field-actions-trigger { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; padding: 0; border: 0; border-radius: var(--lp-r-sm); background: transparent; font: inherit; color: inherit; cursor: pointer; } .cg-fields-manager .w46-field-actions.is-open .w46-field-actions-trigger, .w46-field-actions.is-open .w46-field-actions-trigger { opacity: 1; color: var(--lp-blue-deep); } .w46-field-actions-trigger:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } /* ---- the menu itself ---------------------------------------------------------------- ⭐ VIEWPORT-POSITIONED, ON PURPOSE. `.cg-pop-list` is a 320px `overflow-y: auto` box, so an absolutely positioned menu on one of the last rows would be clipped by its own parent. `position: fixed` escapes that clip (no ancestor here establishes a containing block: `.cg-pop` carries no transform, filter or containment), and the component closes the menu on any scroll so a detached menu can never point at the wrong row. ⚠ The `top`/`left` arrive as inline geometry from the trigger's measured rect. They are the only inline style on this control; every colour, size and radius is below. */ .w46-field-menu { position: fixed; z-index: var(--cg-z-menu); display: flex; flex-direction: column; gap: 2px; width: 168px; padding: 4px; border: 1px solid var(--lp-line); border-radius: var(--lp-r-md); background: var(--lp-surface); /* A tinted shadow, and only because this IS an overlay (DESIGN: hairlines elsewhere). */ box-shadow: 0 6px 18px color-mix(in srgb, var(--lp-blue-deep) 16%, transparent); animation: w46-field-menu-in 140ms ease-out; } /* Opacity and transform only: nothing here reflows the row underneath it. */ @keyframes w46-field-menu-in { from { opacity: 0; transform: translateY(-2px); } to { opacity: 1; transform: translateY(0); } } @media (prefers-reduced-motion: reduce) { .w46-field-menu { animation: none; } } /* A menu item is a short label, not a sentence: the impact wording stays in `title`, where W41-T29 put it, and the row's width budget is unaffected either way. */ .w46-field-menu-item { display: flex; align-items: center; width: 100%; padding: 6px 8px; border: 0; border-radius: var(--lp-r-sm); background: transparent; font: inherit; color: inherit; font-size: var(--lp-fs-xs); text-align: left; cursor: pointer; } .w46-field-menu-item:hover { background: var(--lp-blue-tint); color: var(--lp-blue-deep); } .w46-field-menu-item:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } /* ⭐ THE DESTRUCTIVE ITEM READS AS ONE, and it is the whole reason the two acts stopped being neighbours: a delete that looks like an edit is a delete you reach by accident. */ .w46-field-menu-item--danger { color: var(--lp-red-deep); } .w46-field-menu-item--danger:hover { background: var(--lp-red-tint); color: var(--lp-red-deep); } /* ---- the add-field type list's info mark (owner instruction 27) ---------------------- The glyph was the literal characters `(i)`, which a text baseline positioned; an SVG needs the box centred instead. Everything else about the button (its 32px hit area, its colours, its focus ring) stays exactly where wave 41 put it. ⛔ COLOUR IS DELIBERATELY ABSENT HERE. field-ui.css already states the resting tone and the hover / focus / expanded tones; restating the base one in a sheet that loads later would win the resting fight and leave the three state rules to fight back at higher specificity, which is how a mark ends up muted when it is meant to be lit. */ .cg-type-info { display: inline-flex; align-items: center; justify-content: center; } /* ---- the date cell: a plain date first, a repeat editor second (owner instruction 13) ---- W46-T32. The picker used to render the anchor block, the "Only when" conditions and every rule row at all times, with the plain-vs-repeating distinction implied only by `rules.length` and the way in marked by a quiet text link. Now the default state is a calendar plus ONE footer affordance, and the editor is a second step in the SAME overlay laid out one setting per labelled row, after reference/Google Calendar 1.png. The editor is wider than the bare calendar, so the width pinned at index.css's `.cg-date-picker` is restated here at higher specificity. This sheet is imported from the component, so it is emitted AFTER index.css and wins. [[a-lane-stylesheet-cannot-override-index-css]] */ .cg-pop.cg-date-picker { width: min(360px, calc(100vw - 24px)); } /* ---- step 1: the footer that carries the whole way in -------------------------------- The owner's complaint was that the way in was hard to see. It is a filled control on its own strip now, not a text link sharing a row with rule editors. */ .w46-date-footer { display: flex; align-items: center; gap: 8px; margin-top: 10px; padding-top: 8px; border-top: 1px solid var(--lp-line); } .w46-date-summary { flex: 1; min-width: 0; color: var(--lp-muted); font-size: var(--lp-fs-3xs); line-height: var(--lp-lh-tight); } .w46-date-repeat { border: 0; background: var(--lp-primary); font: inherit; color: var(--lp-surface); padding: 6px 14px; border-radius: var(--lp-r-pill); font-size: var(--lp-fs-2xs); cursor: pointer; transition: background 140ms ease-out; } .w46-date-repeat:hover { background: var(--lp-primary-hover); } .w46-date-repeat.is-set { background: var(--lp-primary-tint); color: var(--lp-blue-deep); flex: 0 0 auto; } .w46-date-repeat.is-set:hover { background: var(--lp-blue-tint); } .w46-date-repeat:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } /* ---- step 2: one setting per labelled row ------------------------------------------- */ .w46-recur { display: flex; flex-direction: column; gap: 12px; animation: w46-recur-in 140ms ease-out; } @keyframes w46-recur-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } } @media (prefers-reduced-motion: reduce) { .w46-recur { animation: none; } .w46-date-repeat { transition: none; } } .w46-recur-head { display: flex; align-items: center; gap: 6px; } .w46-recur-back { border: 0; background: transparent; font: inherit; color: inherit; width: 24px; height: 24px; border-radius: var(--lp-r-sm); font-size: var(--lp-fs-lg); line-height: 1; cursor: pointer; } .w46-recur-back:hover { background: var(--lp-surface-2); } .w46-recur-back:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } .w46-recur-card { display: flex; flex-direction: column; gap: 10px; padding: 10px; border: 1px solid var(--lp-line); border-radius: var(--lp-r-md); background: var(--lp-surface-2); } .w46-recur-row { display: flex; flex-direction: column; gap: 6px; } .w46-recur-label { color: var(--lp-muted); font-size: var(--lp-fs-3xs); line-height: var(--lp-lh-tight); } .w46-recur-controls { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; } .w46-recur-word { color: var(--lp-muted); font-size: var(--lp-fs-2xs); } .w46-recur-count { width: 64px; } /* ---- the seven day pills, filled when selected --------------------------------------- */ .w46-recur-pills { display: flex; gap: 6px; flex-wrap: wrap; } .w46-recur-pill { border: 0; background: var(--lp-wash); font: inherit; color: var(--lp-ink); width: 28px; height: 28px; border-radius: var(--lp-r-pill); font-size: var(--lp-fs-3xs); cursor: pointer; transition: background 140ms ease-out; } .w46-recur-pill:hover { background: var(--lp-blue-tint); } .w46-recur-pill.is-on { background: var(--lp-primary); color: var(--lp-surface); } .w46-recur-pill:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } @media (prefers-reduced-motion: reduce) { .w46-recur-pill { transition: none; } } /* ---- ends: a radio per line, its field beside it ------------------------------------- */ .w46-recur-ends { display: flex; flex-direction: column; gap: 8px; } .w46-recur-radio { display: flex; align-items: center; gap: 8px; font-size: var(--lp-fs-2xs); cursor: pointer; } .w46-recur-radio input[type="radio"] { accent-color: var(--lp-primary); } .w46-recur-radio input[type="radio"]:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } .w46-recur-radio span { min-width: 44px; } .w46-recur-date { flex: 1; min-width: 0; } /* ---- more options: the power controls leave the default path, they do not leave ------- */ .w46-recur-more > summary { list-style: none; cursor: pointer; color: var(--lp-blue-deep); font-size: var(--lp-fs-2xs); padding: 4px 0; } .w46-recur-more > summary::-webkit-details-marker { display: none; } .w46-recur-more > summary:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } .w46-recur-more[open] > summary { margin-bottom: 8px; } .w46-recur-preview-count { display: block; margin-top: 8px; color: var(--lp-muted); font-size: var(--lp-fs-3xs); } /* ---- the two secondary controls and the footer pair ---------------------------------- */ .w46-recur-add { border: 0; background: transparent; font: inherit; color: var(--lp-blue-deep); align-self: flex-start; padding: 4px 10px; border-radius: var(--lp-r-pill); border: 1px solid var(--lp-line); font-size: var(--lp-fs-2xs); cursor: pointer; } .w46-recur-add:hover { background: var(--lp-blue-tint); } .w46-recur-add:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } .w46-recur-card-foot { display: flex; justify-content: flex-end; } .w46-recur-foot { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding-top: 8px; border-top: 1px solid var(--lp-line); } .w46-recur-quiet { border: 0; background: transparent; font: inherit; color: var(--lp-muted); padding: 6px 8px; border-radius: var(--lp-r-sm); font-size: var(--lp-fs-2xs); cursor: pointer; } .w46-recur-quiet:hover { color: var(--lp-ink); background: var(--lp-surface-2); } .w46-recur-quiet.is-danger { color: var(--lp-red-deep); margin-right: auto; } .w46-recur-quiet.is-danger:hover { background: var(--lp-red-tint); color: var(--lp-red-deep); } .w46-recur-quiet:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; } .w46-recur-save { border: 0; background: var(--lp-primary); font: inherit; color: var(--lp-surface); padding: 6px 16px; border-radius: var(--lp-r-pill); font-size: var(--lp-fs-2xs); cursor: pointer; } .w46-recur-save:hover { background: var(--lp-primary-hover); } .w46-recur-save:focus-visible { outline: 2px solid var(--lp-primary); outline-offset: 2px; }