@l3mpire/ui 2.21.0 → 2.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/USAGE.md +11 -1
- package/dist/index.d.mts +7 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.js +375 -258
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +379 -262
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/USAGE.md
CHANGED
|
@@ -937,7 +937,7 @@ import {
|
|
|
937
937
|
| `FilterBar` / `FilterBarLeft` / `FilterBarRight` | Layout container |
|
|
938
938
|
| `SortButton` | Sort by dropdown (field list + asc/desc) |
|
|
939
939
|
| `FilterBarButton` | "Filters" trigger with optional badge count |
|
|
940
|
-
| `FilterChip` | Presentational segmented chip |
|
|
940
|
+
| `FilterChip` | Presentational segmented chip (value segment truncates at 160px with tooltip on overflow) |
|
|
941
941
|
| `InteractiveFilterChip` | FilterChip with per-segment popovers (property, operator, value, kebab) |
|
|
942
942
|
| `PropertySelector` | 2-level popover: categories → properties with search |
|
|
943
943
|
| `AdvancedChip` | Split button "Advanced filters (N)" + close (outlined neutral) |
|
|
@@ -963,6 +963,16 @@ import {
|
|
|
963
963
|
|
|
964
964
|
**Advanced filter shortcut:** the PropertySelector footer shows an "Advanced filter · N rule(s)" item. Clicking it closes the property selector and opens the advanced popover directly in its initial empty state — where the user picks the first property inline via a "Where | [Select property ▾]" draft row. When no advanced filters exist yet, clicking this shortcut makes the AdvancedChip appear with the popover already open; closing without adding a filter removes the chip automatically.
|
|
965
965
|
|
|
966
|
+
**Pinned groups (hoist a group to root):** mark a property group as "primary" so its properties render flat at the top of the `PropertySelector` popover — no category click needed. Set `groupPinned: true` on any property and the entire group is hoisted; remaining groups stay nested as categories below. Search works across everything (pinned + nested). The popover has a max-height and the "Advanced filter" footer stays sticky at the bottom when the list scrolls. The same flattening is applied in `AdvancedRow`'s property-swap popover and in `InteractiveFilterChip`'s swap popover.
|
|
967
|
+
|
|
968
|
+
```tsx
|
|
969
|
+
{ id: "status", label: "Status", type: "enum", icon: faCircleOutline, group: "task", groupLabel: "Task", groupPinned: true, ... },
|
|
970
|
+
{ id: "priority", label: "Priority", type: "enum", icon: faFlagOutline, group: "task", groupLabel: "Task", groupPinned: true, ... },
|
|
971
|
+
{ id: "due_date", label: "Due date", type: "date", icon: faCalendarOutline, group: "task", groupLabel: "Task", groupPinned: true, ... },
|
|
972
|
+
// Other groups stay nested — click "Contact" to see its properties.
|
|
973
|
+
{ id: "contact_name", label: "Contact name", type: "text", icon: faUserOutline, group: "contact", groupLabel: "Contact", ... },
|
|
974
|
+
```
|
|
975
|
+
|
|
966
976
|
**Dynamic options ("Me", "Unassigned", …):** enum/tags/relation properties accept a `dynamicOptions` array. Each entry is `{ value, label, description?, icon? }` and is rendered at the top of the SingleSelect / MultiSelect dropdown with a divider separating it from the regular options. The `value` is a sentinel string stored on `FilterCondition.value` — the DS only renders, the consuming app resolves it at query time (e.g. `"__me__"` → `currentUser.id`). This keeps session/business logic out of the DS while still getting a consistent visual treatment.
|
|
967
977
|
|
|
968
978
|
```tsx
|
package/dist/index.d.mts
CHANGED
|
@@ -733,6 +733,13 @@ interface PropertyDefinition {
|
|
|
733
733
|
icon: _l3mpire_icons.IconDefinition;
|
|
734
734
|
group: string;
|
|
735
735
|
groupLabel: string;
|
|
736
|
+
/**
|
|
737
|
+
* When true, this property's entire group is hoisted to the root of the
|
|
738
|
+
* PropertySelector popover (no category click needed). All properties in the
|
|
739
|
+
* same group share this behavior — setting it on any one property pins the
|
|
740
|
+
* whole group. Useful for "primary" groups that hold the most-used filters.
|
|
741
|
+
*/
|
|
742
|
+
groupPinned?: boolean;
|
|
736
743
|
options?: string[];
|
|
737
744
|
/**
|
|
738
745
|
* Dynamic/smart options rendered at the top of the value selector with a
|
package/dist/index.d.ts
CHANGED
|
@@ -733,6 +733,13 @@ interface PropertyDefinition {
|
|
|
733
733
|
icon: _l3mpire_icons.IconDefinition;
|
|
734
734
|
group: string;
|
|
735
735
|
groupLabel: string;
|
|
736
|
+
/**
|
|
737
|
+
* When true, this property's entire group is hoisted to the root of the
|
|
738
|
+
* PropertySelector popover (no category click needed). All properties in the
|
|
739
|
+
* same group share this behavior — setting it on any one property pins the
|
|
740
|
+
* whole group. Useful for "primary" groups that hold the most-used filters.
|
|
741
|
+
*/
|
|
742
|
+
groupPinned?: boolean;
|
|
736
743
|
options?: string[];
|
|
737
744
|
/**
|
|
738
745
|
* Dynamic/smart options rendered at the top of the value selector with a
|