@almadar/patterns 2.1.0 → 2.3.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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": "1.0.0",
3
- "exportedAt": "2026-03-06T07:07:47.853Z",
3
+ "exportedAt": "2026-03-09T08:08:00.655Z",
4
4
  "patterns": {
5
5
  "entity-table": {
6
6
  "type": "entity-table",
@@ -95,7 +95,8 @@
95
95
  "types": [
96
96
  "unknown"
97
97
  ],
98
- "description": "Fields to display - accepts string[] or Column[] for unified interface. Alias for columns"
98
+ "description": "Fields to display - accepts string[] or Column[] for unified interface. Alias for columns",
99
+ "required": true
99
100
  },
100
101
  "columns": {
101
102
  "types": [
@@ -318,7 +319,8 @@
318
319
  "types": [
319
320
  "unknown"
320
321
  ],
321
- "description": "Fields to display - accepts string[] or {key, header}[] for unified interface"
322
+ "description": "Fields to display - accepts string[] or {key, header}[] for unified interface",
323
+ "required": true
322
324
  },
323
325
  "fieldNames": {
324
326
  "types": [
@@ -451,7 +453,8 @@
451
453
  "types": [
452
454
  "unknown"
453
455
  ],
454
- "description": "Fields to display - accepts string[] or {key, header}[] for unified interface"
456
+ "description": "Fields to display - required for schema-driven rendering",
457
+ "required": true
455
458
  },
456
459
  "fieldNames": {
457
460
  "types": [
@@ -488,6 +491,12 @@
488
491
  "string"
489
492
  ],
490
493
  "description": "Visual variant for the card grid"
494
+ },
495
+ "imageField": {
496
+ "types": [
497
+ "string"
498
+ ],
499
+ "description": "Entity field name containing an image URL to display as card thumbnail"
491
500
  }
492
501
  }
493
502
  },
@@ -632,7 +641,8 @@
632
641
  "types": [
633
642
  "unknown"
634
643
  ],
635
- "description": "Fields to display - accepts string[], {key, header}[], or DetailField[]"
644
+ "description": "Fields to display - accepts string[], {key, header}[], or DetailField[]",
645
+ "required": true
636
646
  },
637
647
  "fieldNames": {
638
648
  "types": [
@@ -842,7 +852,8 @@
842
852
  "entity": {
843
853
  "types": [
844
854
  "string",
845
- "orbitalentity"
855
+ "orbitalentity",
856
+ "unknown"
846
857
  ],
847
858
  "description": "Schema-based props"
848
859
  },
@@ -856,7 +867,8 @@
856
867
  "types": [
857
868
  "unknown"
858
869
  ],
859
- "description": "Fields definition (schema format) - accepts readonly for generated const arrays"
870
+ "description": "Fields definition (schema format) - accepts readonly for generated const arrays",
871
+ "required": true
860
872
  },
861
873
  "initialData": {
862
874
  "types": [
@@ -913,6 +925,12 @@
913
925
  ],
914
926
  "description": "Event to dispatch on cancel (defaults to 'CANCEL')"
915
927
  },
928
+ "entityId": {
929
+ "types": [
930
+ "string"
931
+ ],
932
+ "description": "Entity ID binding for edit mode (triggers initialData from selectedEntity in compiled code)"
933
+ },
916
934
  "relationsData": {
917
935
  "types": [
918
936
  "object"
@@ -1029,7 +1047,8 @@
1029
1047
  "entity": {
1030
1048
  "types": [
1031
1049
  "string",
1032
- "orbitalentity"
1050
+ "orbitalentity",
1051
+ "unknown"
1033
1052
  ],
1034
1053
  "description": "Schema-based props"
1035
1054
  },
@@ -1043,7 +1062,8 @@
1043
1062
  "types": [
1044
1063
  "unknown"
1045
1064
  ],
1046
- "description": "Fields definition (schema format) - accepts readonly for generated const arrays"
1065
+ "description": "Fields definition (schema format) - accepts readonly for generated const arrays",
1066
+ "required": true
1047
1067
  },
1048
1068
  "initialData": {
1049
1069
  "types": [
@@ -1100,6 +1120,12 @@
1100
1120
  ],
1101
1121
  "description": "Event to dispatch on cancel (defaults to 'CANCEL')"
1102
1122
  },
1123
+ "entityId": {
1124
+ "types": [
1125
+ "string"
1126
+ ],
1127
+ "description": "Entity ID binding for edit mode (triggers initialData from selectedEntity in compiled code)"
1128
+ },
1103
1129
  "relationsData": {
1104
1130
  "types": [
1105
1131
  "object"
@@ -3428,15 +3454,17 @@
3428
3454
  },
3429
3455
  "icon": {
3430
3456
  "types": [
3431
- "icon"
3457
+ "icon",
3458
+ "string"
3432
3459
  ],
3433
- "description": "Left icon as Lucide icon component (convenience prop, renders with default size)"
3460
+ "description": "Left icon as Lucide icon component or string name (e.g. \"plus\", \"trash\")"
3434
3461
  },
3435
3462
  "iconRight": {
3436
3463
  "types": [
3437
- "icon"
3464
+ "icon",
3465
+ "string"
3438
3466
  ],
3439
- "description": "Right icon as Lucide icon component (convenience prop)"
3467
+ "description": "Right icon as Lucide icon component or string name"
3440
3468
  },
3441
3469
  "action": {
3442
3470
  "types": [
@@ -3486,6 +3514,12 @@
3486
3514
  "number"
3487
3515
  ],
3488
3516
  "description": "Numeric count or amount to display in badge"
3517
+ },
3518
+ "label": {
3519
+ "types": [
3520
+ "string"
3521
+ ],
3522
+ "description": "Badge label text (alternative to children for schema-driven rendering)"
3489
3523
  }
3490
3524
  }
3491
3525
  },
@@ -8084,7 +8118,8 @@
8084
8118
  "types": [
8085
8119
  "unknown"
8086
8120
  ],
8087
- "description": "Fields to display"
8121
+ "description": "Fields to display",
8122
+ "required": true
8088
8123
  },
8089
8124
  "itemActions": {
8090
8125
  "types": [
@@ -13506,6 +13541,638 @@
13506
13541
  }
13507
13542
  }
13508
13543
  },
13544
+ "day-cell": {
13545
+ "type": "day-cell",
13546
+ "category": "component",
13547
+ "description": "DayCell component",
13548
+ "suggestedFor": [
13549
+ "day",
13550
+ "cell",
13551
+ "day cell"
13552
+ ],
13553
+ "typicalSize": "small",
13554
+ "propsSchema": {
13555
+ "date": {
13556
+ "types": [
13557
+ "date"
13558
+ ],
13559
+ "description": "The date this cell represents",
13560
+ "required": true
13561
+ },
13562
+ "isToday": {
13563
+ "types": [
13564
+ "boolean"
13565
+ ],
13566
+ "description": "Whether this date is today"
13567
+ },
13568
+ "onClick": {
13569
+ "types": [
13570
+ "function"
13571
+ ],
13572
+ "description": "Called when the day is clicked"
13573
+ },
13574
+ "className": {
13575
+ "types": [
13576
+ "string"
13577
+ ],
13578
+ "description": "Additional CSS classes"
13579
+ }
13580
+ }
13581
+ },
13582
+ "flip-container": {
13583
+ "type": "flip-container",
13584
+ "category": "layout",
13585
+ "description": "FlipContainer component",
13586
+ "suggestedFor": [
13587
+ "flip",
13588
+ "container",
13589
+ "flip container"
13590
+ ],
13591
+ "typicalSize": "small",
13592
+ "propsSchema": {
13593
+ "flipped": {
13594
+ "types": [
13595
+ "boolean"
13596
+ ],
13597
+ "description": "Whether the container is flipped (rotateY 180deg)",
13598
+ "required": true
13599
+ },
13600
+ "className": {
13601
+ "types": [
13602
+ "string"
13603
+ ],
13604
+ "description": "Optional className for the outer wrapper"
13605
+ },
13606
+ "children": {
13607
+ "types": [
13608
+ "node"
13609
+ ],
13610
+ "description": "The two face elements (front and back)",
13611
+ "required": true
13612
+ },
13613
+ "onClick": {
13614
+ "types": [
13615
+ "function"
13616
+ ],
13617
+ "description": "Click handler on the outer wrapper"
13618
+ }
13619
+ }
13620
+ },
13621
+ "time-slot-cell": {
13622
+ "type": "time-slot-cell",
13623
+ "category": "layout",
13624
+ "description": "TimeSlotCell component",
13625
+ "suggestedFor": [
13626
+ "time",
13627
+ "slot",
13628
+ "cell",
13629
+ "time slot cell"
13630
+ ],
13631
+ "typicalSize": "small",
13632
+ "propsSchema": {
13633
+ "time": {
13634
+ "types": [
13635
+ "string"
13636
+ ],
13637
+ "description": "Time label for this slot (e.g. \"09:00\")",
13638
+ "required": true
13639
+ },
13640
+ "onClick": {
13641
+ "types": [
13642
+ "function"
13643
+ ],
13644
+ "description": "Called when the slot is clicked"
13645
+ },
13646
+ "className": {
13647
+ "types": [
13648
+ "string"
13649
+ ],
13650
+ "description": "Additional CSS classes"
13651
+ },
13652
+ "children": {
13653
+ "types": [
13654
+ "node"
13655
+ ],
13656
+ "description": "Event content placed inside the slot"
13657
+ },
13658
+ "isOccupied": {
13659
+ "types": [
13660
+ "boolean"
13661
+ ],
13662
+ "description": "Whether this slot contains an event"
13663
+ }
13664
+ }
13665
+ },
13666
+ "calendar-grid": {
13667
+ "type": "calendar-grid",
13668
+ "category": "display",
13669
+ "description": "CalendarGrid component",
13670
+ "suggestedFor": [
13671
+ "calendar",
13672
+ "grid",
13673
+ "calendar grid"
13674
+ ],
13675
+ "typicalSize": "medium",
13676
+ "propsSchema": {
13677
+ "weekStart": {
13678
+ "types": [
13679
+ "date"
13680
+ ],
13681
+ "description": "Start of the week (defaults to current week's Monday)"
13682
+ },
13683
+ "timeSlots": {
13684
+ "types": [
13685
+ "array"
13686
+ ],
13687
+ "description": "Time slot labels (defaults to 09:00-17:00)"
13688
+ },
13689
+ "events": {
13690
+ "types": [
13691
+ "array"
13692
+ ],
13693
+ "description": "Events to display on the grid"
13694
+ },
13695
+ "onSlotClick": {
13696
+ "types": [
13697
+ "function"
13698
+ ],
13699
+ "description": "Called when a time slot is clicked"
13700
+ },
13701
+ "onDayClick": {
13702
+ "types": [
13703
+ "function"
13704
+ ],
13705
+ "description": "Called when a day header is clicked"
13706
+ },
13707
+ "onEventClick": {
13708
+ "types": [
13709
+ "function"
13710
+ ],
13711
+ "description": "Called when an event is clicked"
13712
+ },
13713
+ "className": {
13714
+ "types": [
13715
+ "string"
13716
+ ],
13717
+ "description": "Additional CSS classes"
13718
+ }
13719
+ }
13720
+ },
13721
+ "chart-legend": {
13722
+ "type": "chart-legend",
13723
+ "category": "display",
13724
+ "description": "ChartLegend component",
13725
+ "suggestedFor": [
13726
+ "chart",
13727
+ "legend",
13728
+ "chart legend"
13729
+ ],
13730
+ "typicalSize": "medium",
13731
+ "propsSchema": {
13732
+ "items": {
13733
+ "types": [
13734
+ "array"
13735
+ ],
13736
+ "description": "Legend items with label and color",
13737
+ "required": true
13738
+ },
13739
+ "className": {
13740
+ "types": [
13741
+ "string"
13742
+ ],
13743
+ "description": "Additional CSS classes"
13744
+ },
13745
+ "direction": {
13746
+ "types": [
13747
+ "string"
13748
+ ],
13749
+ "description": "Layout direction"
13750
+ }
13751
+ }
13752
+ },
13753
+ "date-range-selector": {
13754
+ "type": "date-range-selector",
13755
+ "category": "form",
13756
+ "description": "DateRangeSelector component",
13757
+ "suggestedFor": [
13758
+ "date",
13759
+ "range",
13760
+ "selector",
13761
+ "date range selector"
13762
+ ],
13763
+ "typicalSize": "medium",
13764
+ "propsSchema": {
13765
+ "options": {
13766
+ "types": [
13767
+ "array"
13768
+ ],
13769
+ "description": "Available range options"
13770
+ },
13771
+ "selected": {
13772
+ "types": [
13773
+ "string"
13774
+ ],
13775
+ "description": "Currently selected value"
13776
+ },
13777
+ "onSelect": {
13778
+ "types": [
13779
+ "function"
13780
+ ],
13781
+ "description": "Callback when a range is selected"
13782
+ },
13783
+ "className": {
13784
+ "types": [
13785
+ "string"
13786
+ ],
13787
+ "description": "Additional CSS classes"
13788
+ }
13789
+ }
13790
+ },
13791
+ "flip-card": {
13792
+ "type": "flip-card",
13793
+ "category": "display",
13794
+ "description": "FlipCard component",
13795
+ "suggestedFor": [
13796
+ "flip",
13797
+ "card",
13798
+ "flip card"
13799
+ ],
13800
+ "typicalSize": "medium",
13801
+ "propsSchema": {
13802
+ "front": {
13803
+ "types": [
13804
+ "node"
13805
+ ],
13806
+ "description": "Content rendered on the front face",
13807
+ "required": true
13808
+ },
13809
+ "back": {
13810
+ "types": [
13811
+ "node"
13812
+ ],
13813
+ "description": "Content rendered on the back face",
13814
+ "required": true
13815
+ },
13816
+ "flipped": {
13817
+ "types": [
13818
+ "boolean"
13819
+ ],
13820
+ "description": "Controlled flip state"
13821
+ },
13822
+ "onFlip": {
13823
+ "types": [
13824
+ "function"
13825
+ ],
13826
+ "description": "Callback when the card is clicked to flip"
13827
+ },
13828
+ "className": {
13829
+ "types": [
13830
+ "string"
13831
+ ],
13832
+ "description": "Optional className for the outer container"
13833
+ },
13834
+ "height": {
13835
+ "types": [
13836
+ "string"
13837
+ ],
13838
+ "description": "Card height as a Tailwind class (default: 'h-64')"
13839
+ }
13840
+ }
13841
+ },
13842
+ "graph-view": {
13843
+ "type": "graph-view",
13844
+ "category": "component",
13845
+ "description": "GraphView component",
13846
+ "suggestedFor": [
13847
+ "graph",
13848
+ "view",
13849
+ "graph view"
13850
+ ],
13851
+ "typicalSize": "medium",
13852
+ "propsSchema": {
13853
+ "nodes": {
13854
+ "types": [
13855
+ "array"
13856
+ ],
13857
+ "description": "Graph nodes",
13858
+ "required": true
13859
+ },
13860
+ "edges": {
13861
+ "types": [
13862
+ "array"
13863
+ ],
13864
+ "description": "Graph edges",
13865
+ "required": true
13866
+ },
13867
+ "onNodeClick": {
13868
+ "types": [
13869
+ "function"
13870
+ ],
13871
+ "description": "Callback when a node is clicked"
13872
+ },
13873
+ "onNodeHover": {
13874
+ "types": [
13875
+ "function"
13876
+ ],
13877
+ "description": "Callback when a node is hovered (null on leave)"
13878
+ },
13879
+ "width": {
13880
+ "types": [
13881
+ "number"
13882
+ ],
13883
+ "description": "Width in pixels"
13884
+ },
13885
+ "height": {
13886
+ "types": [
13887
+ "number"
13888
+ ],
13889
+ "description": "Height in pixels"
13890
+ },
13891
+ "className": {
13892
+ "types": [
13893
+ "string"
13894
+ ],
13895
+ "description": "Additional CSS classes"
13896
+ },
13897
+ "showLabels": {
13898
+ "types": [
13899
+ "boolean"
13900
+ ],
13901
+ "description": "Show node labels (default true)"
13902
+ },
13903
+ "zoomToFit": {
13904
+ "types": [
13905
+ "boolean"
13906
+ ],
13907
+ "description": "Auto zoom-to-fit after layout settles (default true)"
13908
+ }
13909
+ }
13910
+ },
13911
+ "line-chart": {
13912
+ "type": "line-chart",
13913
+ "category": "display",
13914
+ "description": "LineChart component",
13915
+ "suggestedFor": [
13916
+ "line",
13917
+ "chart",
13918
+ "line chart"
13919
+ ],
13920
+ "typicalSize": "medium",
13921
+ "propsSchema": {
13922
+ "data": {
13923
+ "types": [
13924
+ "array"
13925
+ ],
13926
+ "description": "Data points to plot",
13927
+ "required": true
13928
+ },
13929
+ "width": {
13930
+ "types": [
13931
+ "number"
13932
+ ],
13933
+ "description": "SVG viewBox width"
13934
+ },
13935
+ "height": {
13936
+ "types": [
13937
+ "number"
13938
+ ],
13939
+ "description": "SVG viewBox height"
13940
+ },
13941
+ "showGrid": {
13942
+ "types": [
13943
+ "boolean"
13944
+ ],
13945
+ "description": "Show horizontal grid lines at 25/50/75%"
13946
+ },
13947
+ "showValues": {
13948
+ "types": [
13949
+ "boolean"
13950
+ ],
13951
+ "description": "Show value labels near data points"
13952
+ },
13953
+ "showArea": {
13954
+ "types": [
13955
+ "boolean"
13956
+ ],
13957
+ "description": "Fill area under line with gradient"
13958
+ },
13959
+ "lineColor": {
13960
+ "types": [
13961
+ "string"
13962
+ ],
13963
+ "description": "Line stroke color"
13964
+ },
13965
+ "areaColor": {
13966
+ "types": [
13967
+ "string"
13968
+ ],
13969
+ "description": "Area fill color (used for gradient)"
13970
+ },
13971
+ "className": {
13972
+ "types": [
13973
+ "string"
13974
+ ],
13975
+ "description": "Additional CSS classes"
13976
+ }
13977
+ }
13978
+ },
13979
+ "progress-dots": {
13980
+ "type": "progress-dots",
13981
+ "category": "component",
13982
+ "description": "ProgressDots component",
13983
+ "suggestedFor": [
13984
+ "progress",
13985
+ "dots",
13986
+ "progress dots"
13987
+ ],
13988
+ "typicalSize": "medium",
13989
+ "propsSchema": {
13990
+ "count": {
13991
+ "types": [
13992
+ "number"
13993
+ ],
13994
+ "description": "Total number of dots",
13995
+ "required": true
13996
+ },
13997
+ "currentIndex": {
13998
+ "types": [
13999
+ "number"
14000
+ ],
14001
+ "description": "Current active index (0-based)",
14002
+ "required": true
14003
+ },
14004
+ "getState": {
14005
+ "types": [
14006
+ "function"
14007
+ ],
14008
+ "description": "Custom state resolver per dot index"
14009
+ },
14010
+ "onDotClick": {
14011
+ "types": [
14012
+ "function"
14013
+ ],
14014
+ "description": "Callback when a dot is clicked"
14015
+ },
14016
+ "className": {
14017
+ "types": [
14018
+ "string"
14019
+ ],
14020
+ "description": "Additional CSS classes"
14021
+ },
14022
+ "size": {
14023
+ "types": [
14024
+ "dotsize"
14025
+ ],
14026
+ "description": "Dot size"
14027
+ }
14028
+ }
14029
+ },
14030
+ "data-grid": {
14031
+ "type": "data-grid",
14032
+ "category": "display",
14033
+ "description": "DataGrid component",
14034
+ "suggestedFor": [
14035
+ "data",
14036
+ "grid",
14037
+ "data grid"
14038
+ ],
14039
+ "typicalSize": "medium",
14040
+ "propsSchema": {
14041
+ "entity": {
14042
+ "types": [
14043
+ "unknown"
14044
+ ],
14045
+ "description": "Entity data array"
14046
+ },
14047
+ "fields": {
14048
+ "types": [
14049
+ "unknown"
14050
+ ],
14051
+ "description": "Field definitions for rendering each card"
14052
+ },
14053
+ "columns": {
14054
+ "types": [
14055
+ "unknown"
14056
+ ],
14057
+ "description": "Alias for fields (compiler generates `columns` for field definitions)"
14058
+ },
14059
+ "itemActions": {
14060
+ "types": [
14061
+ "unknown"
14062
+ ],
14063
+ "description": "Per-item action buttons"
14064
+ },
14065
+ "cols": {
14066
+ "types": [
14067
+ "number"
14068
+ ],
14069
+ "description": "Number of columns (uses auto-fit if omitted)"
14070
+ },
14071
+ "gap": {
14072
+ "types": [
14073
+ "string"
14074
+ ],
14075
+ "description": "Gap between cards"
14076
+ },
14077
+ "minCardWidth": {
14078
+ "types": [
14079
+ "number"
14080
+ ],
14081
+ "description": "Minimum card width in pixels (used when cols is not set, default 280)"
14082
+ },
14083
+ "className": {
14084
+ "types": [
14085
+ "string"
14086
+ ],
14087
+ "description": "Additional CSS classes"
14088
+ },
14089
+ "isLoading": {
14090
+ "types": [
14091
+ "boolean"
14092
+ ],
14093
+ "description": "Loading state"
14094
+ },
14095
+ "error": {
14096
+ "types": [
14097
+ "error"
14098
+ ],
14099
+ "description": "Error state"
14100
+ },
14101
+ "imageField": {
14102
+ "types": [
14103
+ "string"
14104
+ ],
14105
+ "description": "Entity field name containing an image URL for card thumbnails"
14106
+ }
14107
+ }
14108
+ },
14109
+ "data-list": {
14110
+ "type": "data-list",
14111
+ "category": "display",
14112
+ "description": "DataList component",
14113
+ "suggestedFor": [
14114
+ "data",
14115
+ "list",
14116
+ "data list"
14117
+ ],
14118
+ "typicalSize": "medium",
14119
+ "propsSchema": {
14120
+ "entity": {
14121
+ "types": [
14122
+ "unknown"
14123
+ ],
14124
+ "description": "Entity data array"
14125
+ },
14126
+ "fields": {
14127
+ "types": [
14128
+ "unknown"
14129
+ ],
14130
+ "description": "Field definitions for rendering each row"
14131
+ },
14132
+ "columns": {
14133
+ "types": [
14134
+ "unknown"
14135
+ ],
14136
+ "description": "Alias for fields (compiler may generate `columns` for field definitions)"
14137
+ },
14138
+ "itemActions": {
14139
+ "types": [
14140
+ "unknown"
14141
+ ],
14142
+ "description": "Per-item action buttons"
14143
+ },
14144
+ "gap": {
14145
+ "types": [
14146
+ "string"
14147
+ ],
14148
+ "description": "Gap between rows"
14149
+ },
14150
+ "variant": {
14151
+ "types": [
14152
+ "string"
14153
+ ],
14154
+ "description": "Visual variant"
14155
+ },
14156
+ "className": {
14157
+ "types": [
14158
+ "string"
14159
+ ],
14160
+ "description": "Additional CSS classes"
14161
+ },
14162
+ "isLoading": {
14163
+ "types": [
14164
+ "boolean"
14165
+ ],
14166
+ "description": "Loading state"
14167
+ },
14168
+ "error": {
14169
+ "types": [
14170
+ "error"
14171
+ ],
14172
+ "description": "Error state"
14173
+ }
14174
+ }
14175
+ },
13509
14176
  "heading": {
13510
14177
  "type": "heading",
13511
14178
  "category": "component",