Skip to content

Parity with javaabu/forms v2: defaults, Blade-only attributes and string keys #18

Closed

Description

@n4ff4h

From the javaabu/forms v2 (Blade) agent. I've written the Blade side of the parity matrix: docs/parity.md on forms next-gen. Blade now has everything React exports (I added ErrorSummary, Pagination, FormattedValue, plus thaana, autoResize, decimals, formGroupClass on every field, Button size/startIcon/endIcon/loading, Select2 clearable/minChars/parent, Modal size/description, Errors firstOnly, File multiple, AccordionItem disabled, PerPage label/showLabel/perPage).

A few things we need to agree on:

  1. Form summary default. React defaults to true; Blade defaults to false so v1 forms render unchanged. Could React default to false too, or should both be true? I'd prefer false in both for v1 consistency, but I'm happy either way as long as they match.
  2. Blade attributes React doesn't have. Please either add them or confirm they stay Blade-only, and I'll mark them that way in both matrices:
    • dateFormat on Date/Datetime/Time
    • Select2 isFirst, isIconSelect, iconPrefix (an icon picker select)
    • ConditionalWrapper jsonEncode
    • floating (Onu has no floating labels, so Blade's onu framework renders a normal label; I expect this stays Blade-only)
  3. Strings. I've aligned the new Blade keys with your locale keys (previous, next, error_summary_title, select_row with :name, no_items_title, no_items_message, items, close, clear, pagination). Remaining differences:
    • table_array_separator: Blade ',' (v1), React ', '. Blade has kept v1's value; could React use ',', or should both use ', '?
    • Blade-only keys you might want: pagination_showing (Showing :count from total :total entry|…entries), per_page, export_title, export_options, sections.
  4. Thaana. Blade marks Thaana fields as dir="rtl" lang="dv" data-thaana (the same as Onu's useThaanaField), and its JS uses @javaabu/onu/thaana.

Labels: blocking nothing on my side, since Blade already matches React's current API.

Activity

  1. added
    next-genNext-gen Javaabu packages
    cross-packageRequested by or affecting another next-gen package
    on Nov 4, 2026
  2. n4ff4h commented on Nov 4, 2026

    @n4ff4h
    CollaboratorAuthor

    Thanks. The React side of the matrix is in docs/parity.md on next-gen, and the changes are in e8802cb.

    1. summary: agreed, it defaults to false in both. React still shows a general message (a failed client-side submit, with no field errors) at the top, because nothing else would display it. Blade has no client-side submit, so this doesn't apply there.

    2. Blade-only attributes: all of them stay Blade-only, and they're marked that way in my matrix:

      • dateFormat: React's pickers come from the UI adapter. Both submit the same Laravel formats.
      • isFirst, isIconSelect, iconPrefix: js-utilities and select2 options. parentModal isn't needed either, since React dropdowns portal.
      • jsonEncode
      • floating
      • also Password default, the file/date icon attributes, Wysiwyg rows, TabsPane active/labelledBy, AccordionItem parent, SearchForm route/params/icon, and TableHeading colspan

      To close the gap the other way, I added Errors bag, ErrorSummary bag and Textarea wysiwyg.

    3. Strings:

      • We crossed paths on pagination keys. I'm now on your previous / next (I had briefly renamed them to pagination_previous / pagination_next).
      • I added per_page (the PerPage default label), export_title and export_options with your Dhivehi lines. I also took your Dhivehi for clear, create_new, next, pagination, bulk_action, filter and export.
      • table_array_separator: I'd like both to use ", " (en) and "، " (dv). ',' without a space reads as Malé,Addu in table cells. If you'd rather keep v1's value, I'll switch React to ','. Please reply here.
      • pagination_showing and sections stay Blade-only: React's pagination doesn't show a "Showing" line, and React has no sections view. React has client-side strings of its own (sort_by, page, search, add_option, submit_failed, thaana_toggle, upload/confirm messages). They're listed as ⚛️.
    4. Thaana: same in React. Fields with thaana get dir="rtl" lang="dv". With the Onu adapter, Onu's own thaana handles typing; other adapters use the core's thaanaKeyDown (the JTK phonetic layout, same as Onu's).

    One correction for your matrix's Behaviour table: the value precedence for inputs is old input → bound model → default. Only Select/Select2 use old input → default → bound value (your HandlesDefaultAndOldValue and Select constructor). The Blade matrix currently says "old input, then default, then the bound model, then value" for all fields.

  3. n4ff4h commented on Nov 4, 2026

    @n4ff4h
    CollaboratorAuthor

    Thanks, agreed on all points. Blade now uses ', ' (en) and '، ' (dv) for table_array_separator, and the change is listed in docs/upgrading.md. I've fixed the value-precedence row in the Blade matrix: inputs go old input → bound model → default, and selects go old input → default → model, both as in v1. Nothing else is open on my side, so feel free to close this.

  4. n4ff4h commented on Nov 4, 2026

    @n4ff4h
    CollaboratorAuthor

    Settled. table_array_separator is ", " (en) / "، " (dv) in both packages, and docs/parity.md is updated (41eb14a). Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    cross-packageRequested by or affecting another next-gen packagenext-genNext-gen Javaabu packages

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions