chore(docker): bump node from 25-bookworm-slim to 26-bookworm-slim in /apps/portal-api in the docker-api group across 1 directory#164
Open
dependabot[bot] wants to merge 1 commit into
Conversation
Bumps the docker-api group with 1 update in the /apps/portal-api directory: node. Updates `node` from 25-bookworm-slim to 26-bookworm-slim --- updated-dependencies: - dependency-name: node dependency-version: 26-bookworm-slim dependency-type: direct:production dependency-group: docker-api ... Signed-off-by: dependabot[bot] <support@github.com>
9b2de98 to
8a71882
Compare
terenceng2010
pushed a commit
to terenceng2010/gratis-gis
that referenced
this pull request
Jun 19, 2026
…, disambiguated pickers (palavido-dev#162) (palavido-dev#38) Slice 1 of the form expression builder series (palavido-dev#162-palavido-dev#166). Mirrors the patterns from the Survey123 Designer reference project but keeps GratisGIS's existing AST data model -- the runtime evaluator already speaks AST, no parser to maintain, no string format to keep in sync. Authors edit visually; we produce AST directly. Three things shipped in one slice: 1. Disambiguated field pickers. Symptom: a form with two groups labeled "Group" and two photos labeled "Photo" rendered an unusable Visible-If dropdown -- four identical-looking entries with no way to tell them apart. Fix: the picker now shows label + type pill + id, grouped by parent path via <optgroup>. So a photo inside "Site B / Group 2" is visually scoped to its parent, and even when labels collide the id ("photo_2") is right there in the row. New `collectFieldRefs(form)` returns id + label + type + parentPath; the older `collectIdLabelPairs` is gone since nothing else needed the slimmer shape. 2. Inline expression editor (replaces the bare "field = value" widget). Each condition is one row: question | operator | value. Operators covered: eq, neq, gt, gte, lt, lte, in, between -- the full comparison subset of the AST. Multiple rows join with AND ("all match") or OR ("any match"); the combinator selector only appears when there are 2+ rows. "+ Add condition" / per-row remove button. Empty state ("No conditions. Always shown.") and complex- expression fallback (when the persisted Expression uses shapes the inline editor can't round-trip, like nested groups or function calls). Decompose / compose are best-effort: we never silently rewrite an expression we can't faithfully render. The fallback shows an amber banner with a "Clear and start over" button instead. `coerceLiteral` parses input strings into typed AST literals: numeric strings round-trip as numbers, "true"/"false" as booleans, everything else as strings. The runtime evaluator does its own coercions, so this is mostly cosmetic -- but it keeps the persisted JSON clean. 3. Constraint expression on every question. The schema has supported `constraint?: Expression` on QuestionBase for a while; the designer just never exposed it. Now it sits below Visible-If in the same Conditional Logic section, wired to the same row-based editor. Self-reference is allowed here (a constraint of course reads its own field's value). Foundation for the next four slices: - Slice 2 (palavido-dev#163): modal Expression Builder with Fields / Operators / Functions tabs, slot-based wizards, search. Reachable via a "Builder" button next to each ExpressionEditor heading. - Slice 3 (palavido-dev#164): calculate / defaultValue / readOnly: Expression on every QuestionBase + a dedicated Logic section in Properties. - Slice 4 (palavido-dev#165): quick-start shortcuts (Today's date, Concat, Range, Must be positive, Regex pattern, etc.) + BUILTINS expansion to ~20 functions to match Survey123 coverage. - Slice 5 (palavido-dev#166): guidance hint field + Properties grouping polish (Basic / Validation / Logic / Appearance) + reverse-dep panel ("this field is referenced by X"). Quality gate: pnpm typecheck, pnpm lint clean.
terenceng2010
pushed a commit
to terenceng2010/gratis-gis
that referenced
this pull request
Jun 19, 2026
…tabs (palavido-dev#163) (palavido-dev#40) Slice 2 of the expression builder series. The inline editor handles flat lists of comparison rows joined by AND or OR; the new modal unlocks nested groups -- the (A or B) and (C or D) shape -- which the AST evaluator already supports but the inline could not visualise without losing structure. A new "Builder" link sits next to each ExpressionEditor heading (both Visible-If and Valid-If). Clicking opens a modal: - Left column: a recursive RuleTreeEditor. Each tree level shows its own combinator (all match / any match), a list of rules, and two "+ Condition" / "+ Group" buttons. A Rule is either a comparison row (rendered via the existing ConditionRowEditor) or a nested RuleTree, indented and outlined so the structure reads at a glance. Removing a rule (or group) is a per-row Minus button. - Right column: tabbed reference panel. - **Fields** tab: search-filterable list of every field in the form, each with a type pill, label, id, and parent path. Helps authors find a field without fishing through the row's dropdown. Click-to-insert lands in Slice 4. - **Operators** tab: comparison + logical reference. Pure informational for now. - **Functions** tab: lists the eight existing BUILTINS (today, now, len, sum, count, coalesce, lower, upper) with signatures. A note explains Slice 4 expands the registry and makes them clickable. - Footer: Cancel / Save. Save round-trips through decomposeExpression on the way back out: if the new tree fits the inline editor (no nested groups, no calls), the inline view takes over; otherwise the inline shows a "complex expression" banner with a "Open Builder" link so the author can edit it visually. Tree <-> AST mapping: - treeFromExpression: and/or -> tree groups; comparisons -> rows; unsupported shapes (calls, arithmetic, concat, if) become an empty placeholder row rather than getting silently dropped. - treeToExpression: filters rows whose ref is empty (same rule as inline composeExpression), folds single-rule groups, otherwise emits { op: combinator, operands: [...] }. The "complex expression" banner now points to the Builder instead of forcing a clear -- authors with a manually-crafted expression import can edit it visually rather than starting over. Slice 3-5 follow-ups: - palavido-dev#164: calculate / defaultValue / readOnly: Expression on every QuestionBase, hosted in a new Logic section. - palavido-dev#165: BUILTINS expansion (regex, contains, substr, selected, …) + click-to-insert in the Operators / Functions tabs + quick-start shortcuts (Today's date, Concatenate text, Range, Must be positive, Regex pattern). - palavido-dev#166: guidance hint field + Properties grouping polish + reverse- dep panel. Quality gate: pnpm typecheck, pnpm lint clean.
terenceng2010
pushed a commit
to terenceng2010/gratis-gis
that referenced
this pull request
Jun 19, 2026
…vido-dev#164) (palavido-dev#41) Slice 3 of the expression builder series. The dedicated `calculated` question type already accepted a `calculate: Expression`; palavido-dev#164 broadens that capability so any question type can opt into being computed -- a number field with `sum(score_a, score_b)`, a text field with `concat(first_name, ' ', last_name)`, a date field with `today()`, and so on -- without forcing the author to switch the question's type. Schema (packages/form-schema/src/index.ts): - New optional `calculate?: Expression` on QuestionBase. The `calculated` type's required `calculate` is unaffected. - `applyCalculations` now picks up any question carrying a `calculate`, not just the `calculated` type. Existing forms with the dedicated type continue to work; new forms can sprinkle computed values across any type. Runtime (apps/portal-web/src/components/form-runtime.tsx): - `isReadOnly` returns true for any question with `calculate` set, regardless of the explicit `readOnly` flag. The respondent isn't meant to override a derived value; if they edited it, applyCalculations would just overwrite their input on the next render. - Drive-by: the "calculated" empty-state placeholder used an em dash; switched to a hyphen to match the no-em-dash project rule. Designer (apps/portal-web/src/app/items/[id]/form/designer.tsx): - New "Calculate (computed value)" expression editor in the Conditional Logic section, hosted by the same row-based ExpressionEditor introduced in Slice 1. Hidden for layout / display-only types since they don't carry a value. - Field picker excludes the current question (a calculate that reads its own value would loop). Authors who really want self- reference can use the Builder modal which doesn't filter. What's still pending in the slicing plan: - defaultValue on QuestionBase + UI: deferred to Slice 5 polish. The runtime doesn't currently use `defaultValue` even on HiddenQuestion (where it's declared today), so adding the designer surface without runtime support would be misleading. - readOnly: Expression UI: schema already supports it; surfacing in Properties is a one-line addition that lands in Slice 5 alongside Default value and the guidance hint. Quality gate: pnpm typecheck, pnpm lint clean.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bumps the docker-api group with 1 update in the /apps/portal-api directory: node.
Updates
nodefrom 25-bookworm-slim to 26-bookworm-slim